emscripten-core / emscripten-core/emscripten
Wasm global declared in inline assembly fail to link at LTO time.
Open
- Dominant language
- C++
- Stars
- 27.6k
- Forks
- 3.6k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 105
Description
It seems like the bitcode object that contains the declaration doesn't know the correct type and is calling it a function:
```
test_wasm_global_dylink (test_core.lto0.test_wasm_global_dylink) ... wasm-ld: error: symbol type mismatch: my_global
>>> defined as WASM_SYMBOL_TYPE_FUNCTION in /tmp/emscripten_temp_40r12q15/test_wasm_global.o
>>> defined as WASM_SYMBOL_TYPE_GLOBAL in test_wasm_global.wasm.lto.o
```
Contributor guide
Assessment
This issue has not been assessed yet.