Closed
Description
wasm-ld: /b/s/w/ir/cache/builder/emscripten-releases/llvm-project/lld/wasm/SyntheticSections.cpp:522: virtual void lld::wasm::GlobalSection::writeBody(): Assertion `isa<UndefinedData>(sym)' failed.
More context and details here, including steps to reproduce:
emscripten-core/emscripten#22008 (comment)
As mentioned there this is a regression, and bisection leads to it likely caused by one of these:
2024-01-20 sbc@chromium.org [lld][WebAssembly] Fix regression in function signature checking (#78831)
2024-01-20 sbc@chromium.org [lld][WebAssembly] Match the ELF linker in transitioning away from archive indexes. (#78658)
2024-01-19 sbc@chromium.org [lld][WebAssembly] Use the archive offset with --whole-archive (#78791)
2024-01-19 sbc@chromium.org [lld][WebAssembly] Reset context object after each link (#78770)
2024-01-19 sbc@chromium.org [lld][ELF] Simplify handleLibcall. NFC (#78659)
I'll also email @sbc100 with the output of -Wl,--reproduce
as requested (too big to attach here).