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

Add performance test to TSAN build #1285

Merged
merged 11 commits into from
Sep 29, 2024
Merged

Conversation

jrouwe
Copy link
Owner

@jrouwe jrouwe commented Sep 29, 2024

No description provided.

TSAN detects a race between BodyManager::AddBodyToActiveBodies coming from PhysicsSystem::ProcessBodyPair and Body::GetIndexInActiveBodiesInternal, however we process the active bodies in batches using an atomic BodyManager::mNumActiveBodies with memory order acquire, so we know that the body is in a consistent state by the time we read the active index. Workaround is to use an atomic for mIndexInActiveBodies that we always read/write in relaxed mode.
Copy link

sonarcloud bot commented Sep 29, 2024

@jrouwe jrouwe merged commit 366da8b into master Sep 29, 2024
70 checks passed
@jrouwe jrouwe deleted the feature/performance_test_tsan branch September 29, 2024 16:29
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.

1 participant