Skip to content

Releases: toyobayashi/emnapi

v1.9.0

12 Mar 09:42

Choose a tag to compare

What's Changed

  • fix data race and use-after-free in napi_threadsafe_function by @toyobayashi in #199
    • fix tsfn not work in JS based async_work workers
    • fix pthread_create not work in JS based async_work workers
    • emnapi_basic[-mt].a includes libuv symbols now
  • refactor: dispatch async work queue in shared memory by @toyobayashi in #200
    • Avoids deadlock when main thread block on waiting queued async work starting. Completed work can not be dispatched to main thread that cause no new worker available, then queued work never start.
    • wasm32-wasip1-threads target spawn async worker in JS will use pthread_create, no longer maintain a separate worker pool.
  • rename node_api_create_object_with_properties by @toyobayashi in #193
  • fix: execute tsfn finalizer after queue drains when aborted
  • feat: add required config hint in package entry
    const { requiredConfig } = require('emnapi')
    console.log(requiredConfig.clang.wasmld)
    [
      '--import-memory',
      '--shared-memory',
      '--export-table',
      '--export=malloc',
      '--export=free',
      '--export=napi_register_wasm_v1',
      '--export-if-defined=node_api_module_get_api_version_v1',
      '--export=emnapi_thread_crashed',
      '--export-if-defined=emnapi_async_worker_create',
      '--export-if-defined=emnapi_async_worker_init'
    ]
    

Full Changelog: v1.8.1...v1.9.0

v1.8.1

04 Jan 12:55

Choose a tag to compare

What's Changed

Full Changelog: v1.8.0...v1.8.1

v1.8.0

03 Jan 13:14

Choose a tag to compare

What's Changed

Full Changelog: v1.7.1...v1.8.0

v1.7.1

14 Nov 06:58

Choose a tag to compare

What's Changed

Full Changelog: v1.7.0...v1.7.1

v1.7.0

03 Nov 09:28

Choose a tag to compare

What's Changed

Full Changelog: v1.6.0...v1.7.0

v1.6.0

21 Oct 02:28

Choose a tag to compare

What's Changed

Full Changelog: v1.5.0...v1.6.0

v1.5.0

29 Aug 03:39

Choose a tag to compare

What's Changed

Prebuilt libraries are built by LLVM clang 20.

  • fix: env undefined after emitting beforeExit event by @toyobayashi in #162
  • fix(wasi): avoid deadlock caused by child thread abort when the main thread is in Atomics.wait and allow blocking calls on browser main thread (requires wasi-sdk 26+ and --export=emnapi_thread_crashed) by @toyobayashi in #163
  • build: backport emscripten parse tools changes to v1 by @toyobayashi in #165

Full Changelog: v1.4.5...v1.5.0

v1.4.5

18 Jul 09:04

Choose a tag to compare

What's Changed

  • fix(wasm32-wasip1-threads): process never exit if trap in threads (#156)

Full Changelog: v1.4.4...v1.4.5

v1.4.4

16 Jul 10:17

Choose a tag to compare

What's Changed

  • fix: worker.onerror may receive an Event (92d5bba)

Full Changelog: v1.4.3...v1.4.4

v1.4.3

15 Apr 16:20

Choose a tag to compare

What's Changed

  • update @emnapi/wasi-threads@1.0.2 in the package.json dependency of @emnapi/core

Full Changelog: v1.4.2...v1.4.3