Skip to content
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

library_pthread.js: Ensure transferredCanvasNames is iterable #22623

Merged
merged 1 commit into from
Sep 26, 2024

Conversation

sbc100
Copy link
Collaborator

@sbc100 sbc100 commented Sep 25, 2024

This was first broken back in #17577 and then fixed in #17752.

I then broke it again in #22545 (yay!) (see #22620).

This time I will include a test to ensure this doesn't happen again.

Copy link
Member

@kripken kripken left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm % question

@@ -12080,6 +12080,14 @@ def test_pthread_reuse(self):
self.set_setting('PTHREAD_POOL_SIZE', 1)
self.do_other_test('test_pthread_reuse.c')

@parameterized({
'': ([],),
'offscreen_canvas': (['-sOFFSCREENCANVAS_SUPPORT', '-sDEFAULT_LIBRARY_FUNCS_TO_INCLUDE=$GL'],),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is GL needed? I don't see it used in the test.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From library_pthread.js:

#if ASSERTIONS                                                                   
        assert(typeof GL == 'object', 'OFFSCREENCANVAS_SUPPORT assumes GL is in use (you can force-include it with \'-sDEFAULT_LIBRARY_FUNCS_TO_INCLUDE=$GL\')');
#endif  

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see, thanks.

@sbc100 sbc100 force-pushed the transferredCanvasNames branch from d491736 to 78f8f55 Compare September 25, 2024 22:11
This was first broken back in emscripten-core#17577 and then fixed in emscripten-core#17752.

I then broke it again in emscripten-core#22545 (yay!) (see emscripten-core#22620).

This time I will include a test to ensure this doesn't happen again.
@sbc100 sbc100 force-pushed the transferredCanvasNames branch from 78f8f55 to 2586e23 Compare September 25, 2024 22:57
@sbc100 sbc100 merged commit ef0efd2 into emscripten-core:main Sep 26, 2024
26 of 28 checks passed
@sbc100 sbc100 deleted the transferredCanvasNames branch September 26, 2024 15:44
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