-
Notifications
You must be signed in to change notification settings - Fork 8
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
Use C++ callbacks #8
base: main
Are you sure you want to change the base?
Conversation
@kainino0x I'm looking at using C++ callbacks in this app and while it's working natively with Dawn ToT, it fails with Emscripten ToT with the following error:
Do you know what are the steps to fix this issue? Or are you already working on this by any chance? |
3bed672
to
9f63856
Compare
Emscripten doesn't implement any of the Futures-enabled async stuff yet. I'm supposed to implement it but my higher priority right now is temporarily forking the Emscripten bindings so we can deal with the necessary breaking changes without breaking Emscripten users continually. |
@lokokung With https://dawn-review.googlesource.com/c/dawn/+/202176 now landed, is it a good time to revisit this PR? |
Almost! That CL only landed changes for |
@lokokung I assume https://dawn-review.googlesource.com/c/dawn/+/203421 is the CL you mentioned. |
Yup! I'm hoping to land that sometime this week! |
@lokokung @kainino0x I'd like to create a I assume I'd need to follow steps in https://dawn.googlesource.com/dawn/+/refs/heads/main/src/emdawnwebgpu/README.md but I'm not sure how this applies to the context of this app. Can you explain how to do that properly? |
FYI Here's what I'm stuck for now:
And despite this, I get the following when running
|
Hmm, so it seems like right now the CMake config is trying to build Dawn via the gn build and then using CMake to use the results to build the demo. I haven't ever tried this path so I wouldn't be surprised if it doesn't actually work... My immediate suggestion to see if it would work would be to try using the CMake version of the build for Emscripten for now so something like:
Note that the |
@lokokung FWIW The instructions for "Building Dawn Emscripten bindings and samples with CMake" don't work as well:
I'd appreciate any help you may offer as I'm stuck now. |
@beaufortfrancois I put up a fix for that here: https://dawn-review.googlesource.com/c/dawn/+/205614 |
You'll also need this https://dawn-review.googlesource.com/c/dawn/+/205814 after https://dawn-review.googlesource.com/c/dawn/+/197476 was landed. |
One more important fix to land: https://dawn-review.googlesource.com/c/dawn/+/205874 Please see https://github.com/kainino0x/webgpu-cross-platform-demo/tree/dawnwasm for how I've made the emdawnwebgpu build work. It's a little messy to set up but it is working! (No longer using the gn build, now using the cmake build since Loko set that up) |
Thank you both for landing all the necessary changes! I'll give it a try! |
No description provided.