Skip to content

Conversation

@sbc100
Copy link
Collaborator

@sbc100 sbc100 commented Mar 21, 2024

Followup to #21555

In addition to helping avoid symbol collisions this has the great side effect that we can now completely remove the WASM_SYSTEM_EXPORTS special casing which simplifies the code in bunch of places.

@sbc100 sbc100 changed the title Use _emscripten_ prefix for getTempRet0/setTempRet0. NFC Use _emscripten_ prefix for getTempRet0/setTempRet0 exports. NFC Mar 22, 2024
@sbc100 sbc100 force-pushed the getTempRet0 branch 3 times, most recently from ff75099 to ee7bcc1 Compare March 22, 2024 03:00
sbc100 added a commit to sbc100/emscripten that referenced this pull request Mar 22, 2024
`wasm-emscripten-finalize` will always performs some amount of type
legalization unless WASM_BIGINT is enabled.  The logic in
`finalize_wasm` was getting this wrong.

I'm not sure exactly what the side effects of this are today but I'm
working on change to `getTempRet0`/`setTempRet0` handling where this
becomes a problem because `js_legalization_pass_flags` was not being
passed to `wasm-emscripten-finalize` even though some amount of
legalization was happening.  This was only effecting the `WASM_BIGINT=0`
+ `LEGALIZE_JS_FFI=0` case in which partial legalization occurs.

See: emscripten-core#21579
sbc100 added a commit to sbc100/emscripten that referenced this pull request Mar 22, 2024
`wasm-emscripten-finalize` will always performs some amount of type
legalization unless WASM_BIGINT is enabled.  The logic in
`finalize_wasm` was getting this wrong.

I'm not sure exactly what the side effects of this are today but I'm
working on change to `getTempRet0`/`setTempRet0` handling where this
becomes a problem because `js_legalization_pass_flags` was not being
passed to `wasm-emscripten-finalize` even though some amount of
legalization was happening.  This was only effecting the `WASM_BIGINT=0`
+ `LEGALIZE_JS_FFI=0` case in which partial legalization occurs.

See: emscripten-core#21579
@sbc100 sbc100 force-pushed the getTempRet0 branch 3 times, most recently from 36988cf to 3422236 Compare March 23, 2024 23:13
@sbc100 sbc100 requested a review from kripken March 24, 2024 01:00
Followup to emscripten-core#21555

In addition to helping avoid symbol collisions this has the great
side effect that we can now completely remove the `WASM_SYSTEM_EXPORTS`
special casing which simplifies the code in bunch of places.
@sbc100 sbc100 enabled auto-merge (squash) March 25, 2024 20:33
@sbc100 sbc100 merged commit fe2cedf into emscripten-core:main Mar 25, 2024
@sbc100 sbc100 deleted the getTempRet0 branch March 25, 2024 23:30
sbc100 added a commit to sbc100/emscripten that referenced this pull request Jan 3, 2025
`wasm-emscripten-finalize` will always performs some amount of type
legalization unless WASM_BIGINT is enabled.  The logic in
`finalize_wasm` was getting this wrong.

I'm not sure exactly what the side effects of this are today but I'm
working on change to `getTempRet0`/`setTempRet0` handling where this
becomes a problem because `js_legalization_pass_flags` was not being
passed to `wasm-emscripten-finalize` even though some amount of
legalization was happening.  This was only effecting the `WASM_BIGINT=0`
+ `LEGALIZE_JS_FFI=0` case in which partial legalization occurs.

See: emscripten-core#21579
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants