[llvm-bugs] [Bug 42565] New: Internal error compiling 32-bit i386 -march=atom kernel
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Jul 10 08:34:39 PDT 2019
https://bugs.llvm.org/show_bug.cgi?id=42565
Bug ID: 42565
Summary: Internal error compiling 32-bit i386 -march=atom
kernel
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: arnd at linaro.org
CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org,
neeilans at live.com, richard-llvm at metafoo.co.uk
Building randconfig Linux kernels, I came across an internal error, which I
reduced to this input:
https://godbolt.org/z/Cjq8VC
void HUF_writeCTable_wksp()
{
unsigned n;
char *bitsToWeight = 0;
n = 1;
for (; n + 1; n++)
bitsToWeight[n] = -n;
}
$ clang-9 -c -O2 -mno-sse -march=atom -fno-delete-null-pointer-checks
huf_compress.c
Stack dump:
0. Program arguments:
/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9 -cc1 -triple
x86_64-unknown-linux-gnu -S -disable-free -disable-llvm-verifier
-discard-value-names -main-file-name example.c -mrelocation-model static
-mthread-model posix -fno-delete-null-pointer-checks -fmath-errno -masm-verbose
-mconstructor-aliases -munwind-tables -fuse-init-array -target-cpu atom
-target-feature -sse -dwarf-column-info -debug-info-kind=limited
-dwarf-version=4 -debugger-tuning=gdb -momit-leaf-frame-pointer
-coverage-notes-file /home/ubuntu/./output.gcno -resource-dir
/opt/compiler-explorer/clang-trunk-20190710/lib/clang/9.0.0 -internal-isystem
/usr/local/include -internal-isystem
/opt/compiler-explorer/clang-trunk-20190710/lib/clang/9.0.0/include
-internal-externc-isystem /usr/include/x86_64-linux-gnu
-internal-externc-isystem /include -internal-externc-isystem /usr/include -O2
-fdebug-compilation-dir /home/ubuntu -ferror-limit 19 -fmessage-length 0
-fobjc-runtime=gcc -fdiagnostics-show-option -fcolor-diagnostics
-vectorize-loops -vectorize-slp -mllvm --x86-asm-syntax=intel -faddrsig -o
./output.s -x c <source>
1. <eof> parser at end of file
2. Code generation
3. Running pass 'Function Pass Manager' on module '<source>'.
4. Running pass 'Live DEBUG_VALUE analysis' on function
'@HUF_writeCTable_wksp'
#0 0x000055d3dda1a46a llvm::sys::PrintStackTrace(llvm::raw_ostream&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x27ca46a)
#1 0x000055d3dda18234 llvm::sys::RunSignalHandlers()
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x27c8234)
#2 0x000055d3dda18372 SignalHandler(int)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x27c8372)
#3 0x00007fdec6a0e890 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x12890)
#4 0x000055d3dd04bddc (anonymous
namespace)::LiveDebugValues::transferRegisterCopy(llvm::MachineInstr&,
(anonymous namespace)::LiveDebugValues::OpenRangesSet&,
llvm::UniqueVector<(anonymous namespace)::LiveDebugValues::VarLoc>&,
llvm::SmallVector<(anonymous namespace)::LiveDebugValues::TransferDebugPair,
4u>&) (/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x1dfbddc)
#5 0x000055d3dd052854 (anonymous
namespace)::LiveDebugValues::ExtendRanges(llvm::MachineFunction&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x1e02854)
#6 0x000055d3dd0e30d0
llvm::MachineFunctionPass::runOnFunction(llvm::Function&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x1e930d0)
#7 0x000055d3dd40f3d8 llvm::FPPassManager::runOnFunction(llvm::Function&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x21bf3d8)
#8 0x000055d3dd40f493 llvm::FPPassManager::runOnModule(llvm::Module&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x21bf493)
#9 0x000055d3dd40e731 llvm::legacy::PassManagerImpl::run(llvm::Module&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x21be731)
#10 0x000055d3ddc3f74e (anonymous
namespace)::EmitAssemblyHelper::EmitAssembly(clang::BackendAction,
std::unique_ptr<llvm::raw_pwrite_stream,
std::default_delete<llvm::raw_pwrite_stream> >)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x29ef74e)
#11 0x000055d3ddc413c7 clang::EmitBackendOutput(clang::DiagnosticsEngine&,
clang::HeaderSearchOptions const&, clang::CodeGenOptions const&,
clang::TargetOptions const&, clang::LangOptions const&, llvm::DataLayout
const&, llvm::Module*, clang::BackendAction,
std::unique_ptr<llvm::raw_pwrite_stream,
std::default_delete<llvm::raw_pwrite_stream> >)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x29f13c7)
#12 0x000055d3de76d361
clang::BackendConsumer::HandleTranslationUnit(clang::ASTContext&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x351d361)
#13 0x000055d3def3e439 clang::ParseAST(clang::Sema&, bool, bool)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x3cee439)
#14 0x000055d3de76adb7 clang::CodeGenAction::ExecuteAction()
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x351adb7)
#15 0x000055d3de0e9ea9 clang::FrontendAction::Execute()
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x2e99ea9)
#16 0x000055d3de0ad5a5
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x2e5d5a5)
#17 0x000055d3de1ad393
clang::ExecuteCompilerInvocation(clang::CompilerInstance*)
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0x2f5d393)
#18 0x000055d3dbf67a10 cc1_main(llvm::ArrayRef<char const*>, char const*,
void*) (/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0xd17a10)
#19 0x000055d3dbec6672 main
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0xc76672)
#20 0x00007fdec58ccb97 __libc_start_main
(/lib/x86_64-linux-gnu/libc.so.6+0x21b97)
#21 0x000055d3dbf6502a _start
(/opt/compiler-explorer/clang-trunk-20190710/bin/clang-9+0xd1502a)
clang-9: error: unable to execute command: Segmentation fault (core dumped)
clang-9: error: clang frontend command failed due to signal (use -v to see
invocation)
Compiler returned: 254
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190710/bdf36a5e/attachment.html>
More information about the llvm-bugs
mailing list