Skip to content

Wasm global declared in inline assembly fail to link at LTO time. #25555

@sbc100

Description

@sbc100

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions