Skip to content

ABI: implement exact FFI 64-bit slow conversions #192

Description

@chrisbbreuer

Parent: #140
Tracks: #163, #164
Depends on: #170, #175

Implement the two shared FFI slow-path symbols without conflating them with the separate low-level JSFunctionCall/CallFrame bridge in the same pinned source.

Exact scope:

  • JSVALUE_TO_INT64_SLOW
  • JSVALUE_TO_UINT64_SLOW

Acceptance:

  • Decode pinned JSC64 cell words through validated private handles rather than zig-js internal NaN-box bits.
  • Match JSC BigInt.asIntN/asUintN modulo-2^64 semantics for positive, negative, boundary, and arbitrary-size heap BigInts.
  • Preserve the pinned numeric fallback behavior for directly invoked int32/exact-number inputs while returning deterministic zero for invalid, nonnumeric, exception, empty, and deleted values.
  • Cover signed minimum/maximum, unsigned maximum, -1n, 2^64 wraparound, values beyond i128, and invalid cells in the combined compile-link-runtime fixture.
  • Regenerate both inventories, update README/API/ABI/Home evidence, and preserve public/extension accounting.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions