Skip to content

API for custom native stack registration #3816

Closed
@mkokryashkin

Description

Feature

Currently my application runs WASM modules withing custom C fibers. These fibers have their own stacks, different from their thread stack. WAMR, on the other hand, heavilly relies on pthread API for native stack boundary checking.
It would be nice to have a handle like

wasm_runtime_register_native_stack_boundary(uint8_t *stack_boundary)

So it is possible to register your own native stack boundary and use WAMR within a fiber.

Implementation

We just need to set exec_env->native_stack_boundary to a custom value.

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions