emscripten-core/emscripten

Make use of Asyncify for pthread_join

オープン

#9,910 opened on 2019/11/27

 (25 件のコメント) (1 件のリアクション) (0 人の担当者)C++ (3,519 件のフォーク)batch import
asyncifygood first bughelp wantedmultithreading

Repository metrics

Stars
 (27,361 個のスター)
PR merge metrics
 (平均マージ 19d 10h) (30d で 147 merged PRs)

説明

[Forked from discussion in #9579]

Rather than disallowing blocking on the main thread and giving an escape hatch in form of a setting that still allows it, we could transform pthread_join and friends via Asyncify instead and use Atomics.waitAsync under the hood.

This way the main browser thread wouldn't really be blocked, but the code would be still backwards-compatible and properly wait for thread to finish execution as user expects.

コントリビューターガイド