Avoid thread_local on MacOS to prevent issues with hot reload#1594
Merged
dsnopek merged 1 commit intogodotengine:masterfrom Oct 29, 2024
Merged
Avoid thread_local on MacOS to prevent issues with hot reload#1594dsnopek merged 1 commit intogodotengine:masterfrom
thread_local on MacOS to prevent issues with hot reload#1594dsnopek merged 1 commit intogodotengine:masterfrom
Conversation
cdea1ad to
08ba2d8
Compare
thread_local on MacOS to prevent issues with hot reloadthread_local on MacOS to prevent issues with hot reload
08ba2d8 to
91833c8
Compare
Collaborator
Author
|
Now that PR #1590 is merged, taking this one out of draft! |
paddy-exe
approved these changes
Oct 29, 2024
Contributor
paddy-exe
left a comment
There was a problem hiding this comment.
Discussed in the GDExtension meeting and tested by user who created the issue with success.
Collaborator
Author
|
Cherry-picked for 4.3 in PR #1695 |
|
FYI, this PR broke my GDExtension code on macOS, causing the following linker errors: I've resolved the issue for now by passing the option "use_hot_reload=no" to scons when building godot-cpp. |
Collaborator
Author
MacOS builds with hot reload are still working for me. Perhaps doing a |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1573
This isn't quite right yet. I think thelock_guardfor reload is in the right place, but the one inWrapped::_set_construct_info()is wrong. We need to lock around the wholememnew()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