Add unit tests to show Tree_Hdagg bug for certain input matrices #10
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.
A more clear demonstration of #9
example/SpTRSV_runtime.cpp
so it throws error as reported in Invalid vector size bug during Tree-HDagg partitioning for certain input matrices #9Catch_tests/hdagg_tests.cpp
to sweep over many input random matrices. 36 out of 768 test cases fail.To run:
The test sweeps over combinations of
(n, density, seed, use_metis, nthreads, bin_pack)
via Catch generators:The failed ones are:
In summary, failed cases are
(n, density, seed, use_metis) =
:(20, 0.5, 2, false/true)
(50, 0.5, 1, false/true)
(50, 0.5, 3, false)
(100, 0.2, 2, false)
(100, 0.5, 1/2, false)
(200, 0.5, 2, false)
So it seems like, denser patterns are more likely to trigger bugs (no bugs for
density = 0.05 or 0.1
); and the cases with Metis are less likely to trigger bugs than without Metis. The choice ofnthreads
andbin_pack
does not affect the bug (except thatnthreads = 1
will fail due to #5 (comment)).This PR is not intended to be merged right away. It is aimed as an example for fixing #9. After the bug is fixed, the unit tests can be added to enhance code robustness.