webmachinelearning/webnn-native

[Node] App crashed on Windows with TFLite WebNN delegate multi-threading build

Closed this issue · 0 comments

Reported by @Honry , thanks!

Test: https://honry.github.io/webnn-samples/semantic_segmentation/ + Electron.js + WebNN OV/DML

Relevant PR: Honry/webnn-samples#14

The root cause is related to upstream issue for building node.js addon against electron on Windows: electron/electron#29893. We rely accessing v8::SharedArrayBuffer::GetBackingStore() in fix #107. However, it turns out it doesn't work on Electron 13+ on Windows because it is built by clang/libc++. Eventually, we should use N-API to access SharedArrayBuffer, however that capability depends on nodejs/node#23276.

For short term, I would suggest to disable the SharedArrayBuffer support till it is officially supported by N-API.