Skip to content

Conversation

@MasterJH5574
Copy link
Contributor

This PR fixes a bug where metal runtime cannot be accessed from multiple threads. This is because the ThreadLocal entry initialization happens during global workspace initialization, meaning other threads that tries to use metal runtime later cannot have the thread local entry correctly initialized.

This PR fixes the problem by always use nullptr fallback and lookup at the global workspace for default stream.


Co-authored-by: Tianqi Chen [email protected]

This PR fixes a bug where metal runtime cannot be accessed from multiple threads.
This is because the ThreadLocal entry initialization happens during global workspace
initialization, meaning other threads that tries to use metal runtime later cannot
have the thread local entry correctly initialized.

This PR fixes the problem by always use nullptr fallback and lookup at the
global workspace for default stream.
@tqchen tqchen merged commit f0c28a0 into apache:main Feb 18, 2024
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