Add test to reproduce multi-threading issue of computing extent and relationship
Description of Change(s)
We found a very strange behavior that ComputeExtent along with GetForwardedTargets in a multi-threading way would influence the behavior of getting material binding with API UsdRelationship::GetForwardedTargets. See the changes of this PR about the test to reproduce this. In this test, it's trying to traverse the whole stage with multi-threads. All operations are supposed to be read-only to the stage, and the test should be successful. However, it fails unexpectedly sometimes. Adding TfRegistryManager::GetInstance().SubscribeTo<UsdGeomBoundable>(); to the first line of main() will pass the test, which we still have no idea why.
You need to run the test with --repeat until-fail:1000 to increase the possibility of failure.
Fixes Issue(s)
https://github.com/PixarAnimationStudios/OpenUSD/issues/3529
Checklist
[x] I have created this PR based on the dev branch
[x] I have followed the coding conventions
[ ] I have added unit tests that exercise this functionality (Reference: testing guidelines)
[ ] I have verified that all unit tests pass with the proposed changes
[x] I have submitted a signed Contributor License Agreement (Reference: Contributor License Agreement instructions)
@nvmkuruc for vis.
It was a little harder to reproduce on Linux, but I was able to reproduce with --repeat-until-fail 10000.
/AzurePipelines run
Azure Pipelines successfully started running 1 pipeline(s).
@matthewcpp Now that #3529 has been closed, should we close this?