Skip to content

object_create benchmark: close the last 1ms gap vs Node #21

Description

@proggeramlug

Description

Perry scores 9ms vs Node's 8ms on the object_create benchmark (1M new Point(x,y) allocations). This is the only benchmark where Node leads.

The inline bump allocator (v0.5.2) brought this from 318ms to 9ms. The remaining gap is structural:

  • Perry's arena allocator has an 8-byte GcHeader per object
  • V8 uses hidden classes with direct-mapped field access

Possible approaches:

  • Profile to find the remaining per-alloc overhead
  • Experiment with smaller GcHeader (4 bytes? type+flags only)
  • Batch field initialization with wider stores (write 2 fields per i128 store)

Metadata

Metadata

Assignees

No one assigned

    Labels

    performanceRuntime, compile-time, build-size, or memory performance

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions