Closed tmarkettos closed 8 years ago
Please attach the preprocessed C file as a gist to the bug report.
This is from SPEC CPU2006, which is under a restrictive licence. While the upstream source files themselves are open source, the preprocessed output contains SPEC copyright code which we cannot make public (ditto also bug #94 ). The files can be found on vica in the path I pointed to.
Are you intentionally compiling for hardware floating point? This works fine with -msoft-float
.
Either we're doing something wrong in the CHERI back end, or we're doing something that triggers a bug in the register allocator. Generating a reduced test case is proving problematic, as llc
is able to assemble the function that causes the failure in isolation, but not when it is part of the module that contains everything else.
I get a segfault when building sre_random.c from Squid:
/home/atm26/micro/sdk256/sdk/bin/cheri-unknown-freebsd-clang -integrated-as -mabi=sandbox -cheri-linker -lc -lmalloc_simple --sysroot=/home/atm26/micro/sdk256/sdk/sysroot/ -B/home/atm26/micro/sdk256/sdk/bin -c -o sre_random.o -DSPEC_CPU -DNDEBUG -O2 -fno-strict-aliasing -DSPEC_CPU_MACOSX sre_random.c clang-3.8: warning: -lc: 'linker' input unused clang-3.8: warning: -lmalloc_simple: 'linker' input unused clang-3.8: error: unable to execute command: Segmentation fault (core dumped) clang-3.8: error: clang frontend command failed due to signal (use -v to see invocation) clang version 3.8.0 (https://github.com/CTSRD-CHERI/clang 473591c52d2160071616e8574dc80305abfdda52) (http://github.com/CTSRD-CHERI/llvm 388f6926b8f9bb0557c65b74badb8a34734f13dc) Target: cheri-unknown-freebsd Thread model: posix InstalledDir: /home/atm26/micro/sdk256/sdk/bin clang-3.8: note: diagnostic msg: PLEASE submit a bug report to http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and associated run script. clang-3.8: note: diagnostic msg:
PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT: Preprocessed source(s) and associated run script(s) are located at: clang-3.8: note: diagnostic msg: /tmp/sre_random-c0349f.c clang-3.8: note: diagnostic msg: /tmp/sre_random-c0349f.sh clang-3.8: note: diagnostic msg:
make: *\ [sre_random.o] Error 254
Sources in vica:/home/atm26/micro/github-bug/sre_random-c0349f.c and sre_random-c0349f.sh