-
Notifications
You must be signed in to change notification settings - Fork 3.4k
[wasm64] Fix window system/graphics JS libraries #20276
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this!
lgtm % a couple of comments.
Normally I would want to see some new tests passing under wasm64 but maybe thats not currently an easy option?
4c7f0be
to
407e28c
Compare
I think a new workflow is needed for wasm64 on browsers? It appears that the workflows which run wasm64 tests only install node canary. |
We have the |
Thanks! I think the SDL2 tests will fail because the port will not compile. Let me try that for unit tests which use low level html5 api. |
sdl1 tests should maybe work too? |
@sbc100 I'm making progress with wasm64 tests inside |
Just to add |
c902bf9
to
8e65611
Compare
@sbc100 I've enabled wasm64 for a few simple tests. Just checked the "Run tests" section in circleci and it looks like both firefox and chrome ran the newly enabled wasm64 tests successfully. There is more work to do for webgl and proxied contexts. We don't use proxied contexts in our library, but I'd love to explore that. I think it's a good idea to make those changes in follow up PRs. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm with the final comment fixed.
8e65611
to
1cb9eab
Compare
The webidl `long` type is defined to be a 32-bit type: https://webidl.spec.whatwg.org/#idl-long https://webidl.spec.whatwg.org/#idl-unsigned-long Using `long` on the native side works find for wasm32 but breaks under wasm64 where `long` is 64-bit. Using `int` instead means the type is the same under wasm32 and wasm64 which more accurately represents the html5/webidl type. See emscripten-core#20276
Actually, I think we should fix the types using html5.h.. which should allow you revert certain parts of this change: #20290 |
That is much better imo. I'll revert those after that is merged. |
The webidl `long` type is defined to be a 32-bit type: https://webidl.spec.whatwg.org/#idl-long https://webidl.spec.whatwg.org/#idl-unsigned-long Using `long` on the native side works find for wasm32 but breaks under wasm64 where `long` is 64-bit. Using `int` instead means the type is the same under wasm32 and wasm64 which more accurately represents the html5/webidl type. See emscripten-core#20276
The webidl `long` type is defined to be a 32-bit type: https://webidl.spec.whatwg.org/#idl-long https://webidl.spec.whatwg.org/#idl-unsigned-long Using `long` on the native side works find for wasm32 but breaks under wasm64 where `long` is 64-bit. Using `int` instead means the type is the same under wasm32 and wasm64 which more accurately represents the html5/webidl type. See emscripten-core#20276
The webidl `long` type is defined to be a 32-bit type: https://webidl.spec.whatwg.org/#idl-long https://webidl.spec.whatwg.org/#idl-unsigned-long Using `long` on the native side works find for wasm32 but breaks under wasm64 where `long` is 64-bit. Using `int` instead means the type is the same under wasm32 and wasm64 which more accurately represents the html5/webidl type. See emscripten-core#20276
The webidl `long` type is defined to be a 32-bit type: https://webidl.spec.whatwg.org/#idl-long https://webidl.spec.whatwg.org/#idl-unsigned-long Using `long` on the native side works find for wasm32 but breaks under wasm64 where `long` is 64-bit. Using `int` instead means the type is the same under wasm32 and wasm64 which more accurately represents the html5/webidl type. See #20276
Upon rebasing against |
0c1db5f
to
e880b4d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Almost ready to land.
5af5ee6
to
75a9a6c
Compare
cb384b5
to
0643efc
Compare
I just fixed the code size failures on main.. can you try rebasing/merging one more time? |
- set the value of `config` as a pointer type in eglChooseConfig.
- update dynamic call signatures to `p` where the parameter type is a pointer. - proxied events needs additional work.
0643efc
to
13e5d2c
Compare
Closes #20274
These changes got some amount of webgl, webgpu and event processing for wasm64 working in Chromium Version 119.0.6011.0 (Developer Build) custom (64-bit). Had to enable experimental Webassembly flags.