LoopModels
LoopModels copied to clipboard
Asan Failures
We apparently weren't actually using the sanitizers. We pass ubsan, but asan...
[0/1] Running tests...
Test project /home/chriselrod/Documents/progwork/cxx/LoopModels/builddirasan/test
Start 1: BitSetTest.BasicAssertions
1/41 Test #1: BitSetTest.BasicAssertions ................... Passed 0.03 sec
Start 2: BasicCompare.BasicAssertions
2/41 Test #2: BasicCompare.BasicAssertions ................. Passed 0.03 sec
Start 3: V2Matrix.BasicAssertions
3/41 Test #3: V2Matrix.BasicAssertions ..................... Passed 0.03 sec
Start 4: ConstantTest.BasicAssertions
4/41 Test #4: ConstantTest.BasicAssertions ................. Passed 0.03 sec
Start 5: ConstantTest2.BasicAssertions
5/41 Test #5: ConstantTest2.BasicAssertions ................ Passed 0.03 sec
Start 6: EqTest.BasicAssertions
6/41 Test #6: EqTest.BasicAssertions ....................... Passed 0.03 sec
Start 7: TestEmpty.BasicAssertions
7/41 Test #7: TestEmpty.BasicAssertions .................... Passed 0.03 sec
Start 8: FourierMotzkin.BasicAssertions
8/41 Test #8: FourierMotzkin.BasicAssertions ............... Passed 0.03 sec
Start 9: TrivialPruneBounds.BasicAssertions
9/41 Test #9: TrivialPruneBounds.BasicAssertions ...........***Failed 0.15 sec
Running main() from /home/chriselrod/.cache/CPM/googletest/a36d6fcbd7356d396ea479e6b11f4b9760ad0c04/googletest/src/gtest_main.cc
Note: Google Test filter = TrivialPruneBounds.BasicAssertions
[==========] Running 1 test from 1 test suite.
[----------] Global test environment set-up.
[----------] 1 test from TrivialPruneBounds
[ RUN ] TrivialPruneBounds.BasicAssertions
Loop 0 lower bounds: i_0 >= 0
Loop 0 upper bounds: i_0 <= -2 + %value_0
aff.A =
[ -2 1 -1 ]
[ OK ] TrivialPruneBounds.BasicAssertions (2 ms)
[----------] 1 test from TrivialPruneBounds (2 ms total)
[----------] Global test environment tear-down
[==========] 1 test from 1 test suite ran. (2 ms total)
[ PASSED ] 1 test.
=================================================================
==49002==ERROR: LeakSanitizer: detected memory leaks
Direct leak of 24 byte(s) in 1 object(s) allocated from:
#0 0x7f507cabb1a8 in operator new(unsigned long) (/lib64/libasan.so.8+0xbb1a8)
#1 0x7f5076c18455 in llvm::Value::setNameImpl(llvm::Twine const&) (/lib64/libLLVM-15.so+0xe18455)
#2 0x7ffc1b4884ef ([stack]+0x1d4ef)
Indirect leak of 96 byte(s) in 1 object(s) allocated from:
#0 0x7f507cabb1a8 in operator new(unsigned long) (/lib64/libasan.so.8+0xbb1a8)
#1 0x7f5076c16bb9 in llvm::User::operator new(unsigned long, unsigned int) (/lib64/libLLVM-15.so+0xe16bb9)
SUMMARY: AddressSanitizer: 120 byte(s) leaked in 2 allocation(s).
Start 10: TrivialPruneBounds2.BasicAssertions
10/41 Test #10: TrivialPruneBounds2.BasicAssertions ..........***Failed 0.16 sec
Running main() from /home/chriselrod/.cache/CPM/googletest/a36d6fcbd7356d396ea479e6b11f4b9760ad0c04/googletest/src/gtest_main.cc
Note: Google Test filter = TrivialPruneBounds2.BasicAssertions
[==========] Running 1 test from 1 test suite.
[----------] Global test environment set-up.
[----------] 1 test from TrivialPruneBounds2
[ RUN ] TrivialPruneBounds2.BasicAssertions
Loop 1 lower bounds: i_1 >= 0
i_1 >= 1
Loop 1 upper bounds: i_1 <= -1 + %value_1
Loop 0 lower bounds: i_0 >= 0
Loop 0 upper bounds: aff.A =
[ -1 0 0 0 1 0
-1 1 0 0 0 0
-1 0 1 0 -1 0 ]
[ OK ] TrivialPruneBounds2.BasicAssertions (2 ms)
[----------] 1 test from TrivialPruneBounds2 (2 ms total)
[----------] Global test environment tear-down
[==========] 1 test from 1 test suite ran. (2 ms total)
[ PASSED ] 1 test.
=================================================================
==49004==ERROR: LeakSanitizer: detected memory leaks
Direct leak of 48 byte(s) in 2 object(s) allocated from:
#0 0x7f4a658bb1a8 in operator new(unsigned long) (/lib64/libasan.so.8+0xbb1a8)
#1 0x7f4a5fa18455 in llvm::Value::setNameImpl(llvm::Twine const&) (/lib64/libLLVM-15.so+0xe18455)
#2 0x7ffdf5bc410f ([stack]+0x1c10f)
Direct leak of 24 byte(s) in 1 object(s) allocated from:
#0 0x7f4a658bb1a8 in operator new(unsigned long) (/lib64/libasan.so.8+0xbb1a8)
#1 0x7f4a5fa18455 in llvm::Value::setNameImpl(llvm::Twine const&) (/lib64/libLLVM-15.so+0xe18455)
#2 0x7ffdf5bc427f ([stack]+0x1c27f)
Indirect leak of 288 byte(s) in 3 object(s) allocated from:
#0 0x7f4a658bb1a8 in operator new(unsigned long) (/lib64/libasan.so.8+0xbb1a8)
#1 0x7f4a5fa16bb9 in llvm::User::operator new(unsigned long, unsigned int) (/lib64/libLLVM-15.so+0xe16bb9)
SUMMARY: AddressSanitizer: 360 byte(s) leaked in 6 allocation(s).
# I truncated the output
# as it was very long
Start 38: LexMinSimplexTest.BasicAssertions
38/41 Test #38: LexMinSimplexTest.BasicAssertions ............ Passed 0.85 sec
Start 39: LexMinSimplexTest2.BasicAssertions
39/41 Test #39: LexMinSimplexTest2.BasicAssertions ........... Passed 0.08 sec
Start 40: StringParse.BasicAssertions
40/41 Test #40: StringParse.BasicAssertions .................. Passed 0.03 sec
Start 41: UnimodularizationTest.BasicAssertions
41/41 Test #41: UnimodularizationTest.BasicAssertions ........ Passed 0.03 sec
61% tests passed, 16 tests failed out of 41
Total Test time (real) = 9.24 sec
The following tests FAILED:
9 - TrivialPruneBounds.BasicAssertions (Failed)
10 - TrivialPruneBounds2.BasicAssertions (Failed)
11 - LessTrivialPruneBounds.BasicAssertions (Failed)
12 - AffineTest0.BasicAssertions (Failed)
13 - NonUnimodularExperiment.BasicAssertions (Failed)
14 - DependenceTest.BasicAssertions (Failed)
15 - SymmetricIndependentTest.BasicAssertions (Failed)
16 - RankDeficientLoad.BasicAssertions (Failed)
17 - TimeHidingInRankDeficiency.BasicAssertions (Failed)
18 - TriangularExampleTest.BasicAssertions (Failed)
19 - MeanStDevTest0.BasicAssertions (Failed)
20 - DoubleDependenceTest.BasicAssertions (Failed)
21 - ConvReversePass.BasicAssertions (Failed)
33 - OrthogonalizeTest.BasicAssertions (Failed)
34 - BadMul.BasicAssertions (Failed)
36 - Remarks.BasicAssertions (Failed)
These all seem to be in LLVM.
Ideas for tests other than remarks
:
- Manually
free
what we allocate ininclude/TestUtilities.hpp
- Allocate them using an RAII type that'll leave scope at the same time, freeing them.
- Disable leak sanitizer?
- Silence it for LLVM?
I'd have to look more into what's possible.
For remarks, the failure was
==49060==ASan runtime does not come first in initial library list; you should either link runtime to your application or manually preload it with LD_PRELOAD.
So I'll have to try that first. It calls opt and loads the plugin...