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

Avoid thread_local on MacOS to prevent issues with hot reload #1594

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dsnopek
Copy link
Collaborator

@dsnopek dsnopek commented Sep 17, 2024

Fixes #1573

This isn't quite right yet. I think the lock_guard for reload is in the right place, but the one in Wrapped::_set_construct_info() is wrong. We need to lock around the whole memnew() operation, not just the part where we set those variables. I'm not sure the best way to do that yet.

UPDATE: This might be OK now. I need to get a good test.

This depends on PR #1590 because it adds another thread_local, and this way we can address that one too

@dsnopek dsnopek added bug This has been identified as a bug platform:macos labels Sep 17, 2024
@dsnopek dsnopek added this to the 4.x milestone Sep 17, 2024
@dsnopek dsnopek requested a review from a team as a code owner September 17, 2024 20:46
@dsnopek dsnopek marked this pull request as draft September 17, 2024 20:46
@dsnopek dsnopek changed the title [DRAFT] Avoid thread_local on MacOS to prevent issues with hot reload Avoid thread_local on MacOS to prevent issues with hot reload Oct 17, 2024
@dsnopek dsnopek marked this pull request as ready for review October 17, 2024 14:07
@dsnopek
Copy link
Collaborator Author

dsnopek commented Oct 17, 2024

Now that PR #1590 is merged, taking this one out of draft!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Problems with hot reload
1 participant