Skip to content

JSC/Bun segfault with high-volume N-API addon — SCI-specific? #409

@robert-johansson

Description

@robert-johansson

We encounter a segfault when running nbb on Bun (but not Node.js) with a library that creates thousands of N-API-wrapped objects per second (https://github.com/robert-johansson/genmlx).

We've ruled out the native addon (ASAN clean, disabling C++ finalizers doesn't help). We can't reproduce without nbb — pure JS with the same addon at higher scale works fine on Bun.

I wonder if SCI's evaluation model creates any object patterns that interact differently with JSC vs V8 — e.g., closure scoping, interpreter stack management, or how SCI holds references to externally-wrapped values during interpretation.

I'm trying to track down where the issue can be - any thoughts are welcome.

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