Status: Accepted
Owner: [email protected]
CC: [email protected],  [email protected]
Labels: Type-Defect Priority-Medium

New issue 358 by [email protected]: A number of ASan tests fail in UAR mode
https://code.google.com/p/address-sanitizer/issues/detail?id=358

Do we support running ASan lit tests with ASAN_OPTIONS=detect_stack_use_after_return=1 ? It seems like they worked at some point in the past, because this mode is exercised on the bootstrap bot. The bot was down for a long time, and now we've got the following failures:

    AddressSanitizer32 :: TestCases/contiguous_container.cc
    AddressSanitizer32 :: TestCases/longjmp.cc
    AddressSanitizer32 :: TestCases/stack-overflow.cc
    AddressSanitizer32 :: TestCases/throw_catch.cc
    AddressSanitizer64 :: TestCases/contiguous_container.cc
    AddressSanitizer64 :: TestCases/longjmp.cc
    AddressSanitizer64 :: TestCases/stack-overflow.cc
    AddressSanitizer64 :: TestCases/throw_catch.cc

stack-overflow is quite obvious - it expects that the stack grows down.

The rest seem to be related to the way setjmp + longjmp clears stack shadow - it seems to be less aggressive in UAR mode.

I'll disable UAR testing on the bot for now.



******************** TEST 'AddressSanitizer64 :: TestCases/throw_catch.cc' FAILED ********************
Script:
--
/code/llvm/build-asan2/./bin/clang --driver-mode=g++ -fsanitize=address -mno-omit-leaf-frame-pointer -fno-omit-frame-pointer -fno-optimize-sibling-calls -gline-tables-only -m64 -O /code/llvm/projects/compiler-rt/test/asan/TestCases/throw_catch.cc -o /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/throw_catch.cc.tmp && /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/throw_catch.cc.tmp
--
Exit Code: 134

Command Output (stderr):
--
Before: 0x7f8d23c00020 poisoned: 1
Throw:  0x7f8d23b00020
Catch
After:  0x7f8d23c00020 poisoned: 1
throw_catch.cc.tmp: /code/llvm/projects/compiler-rt/test/asan/TestCases/throw_catch.cc:54: void TestThrowInline(): Assertion `!__asan_address_is_poisoned(x + 32)' failed. /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/throw_catch.cc.script: line 1: 32528 Aborted (core dumped) /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/throw_catch.cc.tmp


******************** TEST 'AddressSanitizer64 :: TestCases/longjmp.cc' FAILED ********************
Script:
--
/code/llvm/build-asan2/./bin/clang --driver-mode=g++ -fsanitize=address -mno-omit-leaf-frame-pointer -fno-omit-frame-pointer -fno-optimize-sibling-calls -gline-tables-only -m64 -O /code/llvm/projects/compiler-rt/test/asan/TestCases/longjmp.cc -o /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/longjmp.cc.tmp && /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/longjmp.cc.tmp
--
Exit Code: 134

Command Output (stderr):
--

TestLongJmp
Before: 0x7fa542900020 poisoned: 1
After:  0x7fa542900020 poisoned: 1
longjmp.cc.tmp: /code/llvm/projects/compiler-rt/test/asan/TestCases/longjmp.cc:22: int main(): Assertion `!__asan_address_is_poisoned(x + 32)' failed. /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/longjmp.cc.script: line 1: 30303 Aborted (core dumped) /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/longjmp.cc.tmp


******************** TEST 'AddressSanitizer64 :: TestCases/contiguous_container.cc' FAILED ********************
Script:
--
/code/llvm/build-asan2/./bin/clang --driver-mode=g++ -fsanitize=address -mno-omit-leaf-frame-pointer -fno-omit-frame-pointer -fno-optimize-sibling-calls -gline-tables-only -m64 -O /code/llvm/projects/compiler-rt/test/asan/TestCases/contiguous_container.cc -o /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/contiguous_container.cc.tmp && /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/contiguous_container.cc.tmp
--
Exit Code: 134

Command Output (stderr):
--
contiguous_container.cc.tmp: /code/llvm/projects/compiler-rt/test/asan/TestCases/contiguous_container.cc:62: void TestThrow(): Assertion `!__asan_address_is_poisoned(x + 14)' failed. /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/contiguous_container.cc.script: line 1: 27664 Aborted (core dumped) /code/llvm/build-asan2/projects/compiler-rt/test/asan/64bitConfig/TestCases/Output/contiguous_container.cc.tmp



--
You received this message because this project is configured to send all issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

--
You received this message because you are subscribed to the Google Groups 
"address-sanitizer" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to