It failed on bots:
https://green.lab.llvm.org/green//job/clang-stage1-RA/25954/consoleFull#-1417328700a1ca8a51-895e-46c6-af87-ce24fa4cd561
and it doesn't provide the test output.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
Maybe Darwin kernel behaves a little differently here and crashes the program?
Maybe yln@ knows?
Comment Actions
Also failed on clang-s390x-linux-lnt with similar symptoms.
I am not sure kernel must behave "atomically" here and either fail or unmap the whole range. Maybe on some arches it starts unmapping things and then realizes the range is bogus?...
I see mmap_stress.cpp says:
test/tsan/mmap_stress.cpp:// REQUIRES: linux, x86_64-target-arch
maybe we should do the same?
https://lab.llvm.org/buildbot#builders/45/builds/5224
******************** TEST 'ThreadSanitizer-s390x :: munmap_invalid.cpp' FAILED ******************** Script: -- : 'RUN: at line 1'; /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/stage1/./bin/clang -fsanitize=thread -Wall -gline-tables-only -I/home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/llvm/compiler-rt/test/tsan/../ -O1 /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/llvm/compiler-rt/test/tsan/munmap_invalid.cpp -o /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/stage1/projects/compiler-rt/test/tsan/S390XConfig/Output/munmap_invalid.cpp.tmp && /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/stage1/projects/compiler-rt/test/tsan/S390XConfig/Output/munmap_invalid.cpp.tmp 2>&1 | FileCheck /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/llvm/compiler-rt/test/tsan/munmap_invalid.cpp -- Exit Code: 137 Command Output (stderr): -- /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/stage1/projects/compiler-rt/test/tsan/S390XConfig/Output/munmap_invalid.cpp.script: line 1: 1719558 Broken pipe /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/stage1/projects/compiler-rt/test/tsan/S390XConfig/Output/munmap_invalid.cpp.tmp 2>&1 1719559 Killed | FileCheck /home/uweigand/sandbox/buildbot/clang-s390x-linux-lnt/llvm/compiler-rt/test/tsan/munmap_invalid.cpp -- ********************
Comment Actions
Maybe yln@ knows?
Noticed this by accident! ;)
For this test we crash on Darwin even without TSan on this line:
void *p = mmap(0, 4096, PROT_READ | PROT_WRITE, MAP_ANON | MAP_PRIVATE, -1, 0); munmap(p, (1ull << 60)); << we crash here; if commented out test succeeds munmap(p, -10000);
lldb is not able to provide the stack trace.
It's probably easiest to leave this test disabled on Darwin for now.