-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tests: Increase robustness of context creation testing
To ensure that no cuda calls occur prior to device selection, an always run method in the test suite previously used timing and a cutoff threshold to make sure a new context was being established. This was quite flakey, as new driver updates could improve context creation times, requiring a lower threshold. Instead, getting the current context via the driver api is used, and it should return null (or a cuda error) if no context yet exists. This should be a much more robust testing mechanism. This is still created per run of the test suite, regardless of if the specific test is requested or not, which is wasted time if running with a filter (one more context creation than needed, so extra time). We may wish to move this test to a separate ctest orcestrated test binary, to ensure it is the first to run (Google test has no way to enforce test order as a feature)
- Loading branch information
Showing
4 changed files
with
38 additions
and
26 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
1 change: 0 additions & 1 deletion
1
tests/test_cases/simulation/test_cuda_simulation_concurrency.cu
This file contains 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