discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: llvm crashes while building libobjc2


From: David Chisnall
Subject: Re: llvm crashes while building libobjc2
Date: Fri, 3 Aug 2018 14:17:59 +0100

Please build with tests disabled.  This is a regression tests for a compiler 
bug, which is fixed in clang trunk.  It is not fixed in your compiler, so you 
are seeing a build failure.

David

> On 3 Aug 2018, at 12:45, Andreas Fink <afink@list.fink.org> wrote:
> 
> Hello all,
> I'm rebuilding the latest version on libobj2 under debian8 and debian9 and I 
> run into crashes of llvm. I have never seen this before with the same 
> compiler. And its blocking the whole thing.
> 
> I've tried llvm-5.0 and llvm-6.0 and also the llvm-5.0 I compiled from source 
> before which I used before to compile all just fine.
> 
> Anyhow having a clue on how to work around this?
> 
> 
> It happens here:
> 
> Scanning dependencies of target ForwardDeclareProtocolAccess_legacy
> [ 19%] Building C object 
> Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/ForwardDeclareProtocolAccess.m.o
> [ 19%] Building C object 
> Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/ForwardDeclareProtocol.m.o
> #0 0x0000564c7f0c57ca llvm::sys::PrintStackTrace(llvm::raw_ostream&) 
> (/usr/local/bin/clang-5.0+0x1dc07ca)
> #1 0x0000564c7f0c38ee llvm::sys::RunSignalHandlers() 
> (/usr/local/bin/clang-5.0+0x1dbe8ee)
> #2 0x0000564c7f0c3a12 SignalHandler(int) (/usr/local/bin/clang-5.0+0x1dbea12)
> #3 0x00007f8ccb4fe0c0 __restore_rt 
> (/lib/x86_64-linux-gnu/libpthread.so.0+0x110c0)
> #4 0x0000564c7f427a50 llvm::IRBuilder<llvm::ConstantFolder, 
> clang::CodeGen::CGBuilderInserter>::CreateCast(llvm::Instruction::CastOps, 
> llvm::Value*, llvm::Type*, llvm::Twine const&) [clone .constprop.407] 
> (/usr/local/bin/clang-5.0+0x2122a50)
> #5 0x0000564c7f4283b7 (anonymous 
> namespace)::CGObjCGNU::GenerateProtocolRef(clang::CodeGen::CodeGenFunction&, 
> clang::ObjCProtocolDecl const*) (/usr/local/bin/clang-5.0+0x21233b7)
> #6 0x0000564c7f413b9e (anonymous 
> namespace)::ScalarExprEmitter::Visit(clang::Expr*) 
> (/usr/local/bin/clang-5.0+0x210eb9e)
> #7 0x0000564c7f414c30 
> clang::CodeGen::CodeGenFunction::EmitScalarExpr(clang::Expr const*, bool) 
> (/usr/local/bin/clang-5.0+0x210fc30)
> #8 0x0000564c7f297495 
> clang::CodeGen::CodeGenFunction::EmitReturnStmt(clang::ReturnStmt const&) 
> (/usr/local/bin/clang-5.0+0x1f92495)
> #9 0x0000564c7f29946f 
> clang::CodeGen::CodeGenFunction::EmitCompoundStmtWithoutScope(clang::CompoundStmt
>  const&, bool, clang::CodeGen::AggValueSlot) 
> (/usr/local/bin/clang-5.0+0x1f9446f)
> #10 0x0000564c7f2c64d8 
> clang::CodeGen::CodeGenFunction::EmitFunctionBody(clang::CodeGen::FunctionArgList&,
>  clang::Stmt const*) (/usr/local/bin/clang-5.0+0x1fc14d8)
> #11 0x0000564c7f2cda85 
> clang::CodeGen::CodeGenFunction::GenerateCode(clang::GlobalDecl, 
> llvm::Function*, clang::CodeGen::CGFunctionInfo const&) 
> (/usr/local/bin/clang-5.0+0x1fc8a85)
> #12 0x0000564c7f2e6e35 
> clang::CodeGen::CodeGenModule::EmitGlobalFunctionDefinition(clang::GlobalDecl,
>  llvm::GlobalValue*) (/usr/local/bin/clang-5.0+0x1fe1e35)
> #13 0x0000564c7f2f7299 
> clang::CodeGen::CodeGenModule::EmitGlobalDefinition(clang::GlobalDecl, 
> llvm::GlobalValue*) (/usr/local/bin/clang-5.0+0x1ff2299)
> #14 0x0000564c7f2f8218 
> clang::CodeGen::CodeGenModule::EmitGlobal(clang::GlobalDecl) 
> (/usr/local/bin/clang-5.0+0x1ff3218)
> #15 0x0000564c7f2f8859 
> clang::CodeGen::CodeGenModule::EmitTopLevelDecl(clang::Decl*) [clone 
> .part.5457] (/usr/local/bin/clang-5.0+0x1ff3859)
> #16 0x0000564c7f8df3c3 (anonymous 
> namespace)::CodeGeneratorImpl::HandleTopLevelDecl(clang::DeclGroupRef) 
> (/usr/local/bin/clang-5.0+0x25da3c3)
> #17 0x0000564c7f8d60d2 
> clang::BackendConsumer::HandleTopLevelDecl(clang::DeclGroupRef) 
> (/usr/local/bin/clang-5.0+0x25d10d2)
> #18 0x0000564c7fc5bfd6 clang::ParseAST(clang::Sema&, bool, bool) 
> (/usr/local/bin/clang-5.0+0x2956fd6)
> #19 0x0000564c7f8dd151 clang::CodeGenAction::ExecuteAction() 
> (/usr/local/bin/clang-5.0+0x25d8151)
> #20 0x0000564c7f5db016 clang::FrontendAction::Execute() 
> (/usr/local/bin/clang-5.0+0x22d6016)
> #21 0x0000564c7f5aa7f6 
> clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) 
> (/usr/local/bin/clang-5.0+0x22a57f6)
> #22 0x0000564c7f66c13b 
> clang::ExecuteCompilerInvocation(clang::CompilerInstance*) 
> (/usr/local/bin/clang-5.0+0x236713b)
> #23 0x0000564c7dcdf3b8 cc1_main(llvm::ArrayRef<char const*>, char const*, 
> void*) (/usr/local/bin/clang-5.0+0x9da3b8)
> #24 0x0000564c7dc64af3 main (/usr/local/bin/clang-5.0+0x95faf3)
> #25 0x00007f8cca0812e1 __libc_start_main 
> (/lib/x86_64-linux-gnu/libc.so.6+0x202e1)
> #26 0x0000564c7dcdce2a _start (/usr/local/bin/clang-5.0+0x9d7e2a)
> Stack dump:
> 0.    Program arguments: /usr/local/bin/clang-5.0 -cc1 -triple 
> x86_64-unknown-linux-gnu -emit-obj -mrelax-all -disable-free 
> -disable-llvm-verifier -discard-value-names -main-file-name 
> ForwardDeclareProtocol.m -mrelocation-model static -mthread-model posix 
> -mdisable-fp-elim -fmath-errno -masm-verbose -mconstructor-aliases 
> -munwind-tables -fuse-init-array -target-cpu x86-64 -dwarf-column-info 
> -debug-info-kind=limited -dwarf-version=4 -debugger-tuning=gdb 
> -coverage-notes-file 
> /Users/afink/development/gnustep/libobjc2/Build/Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/ForwardDeclareProtocol.m.gcno
>  -resource-dir /usr/local/lib/clang/5.0.0 -D GC_DEBUG -D GNUSTEP -D NO_LEGACY 
> -D OLDABI_COMPAT=1 -D TYPE_DEPENDENT_DISPATCH -I 
> /Users/afink/development/gnustep/libobjc2 -U NDEBUG -internal-isystem 
> /usr/local/include -internal-isystem /usr/local/lib/clang/5.0.0/include 
> -internal-externc-isystem /usr/include/x86_64-linux-gnu 
> -internal-externc-isystem /include -internal-externc-isystem /usr/include -O0 
> -fdebug-compilation-dir /Users/afink/development/gnustep/libobjc2/Build/Test 
> -ferror-limit 19 -fmessage-length 172 -fobjc-runtime=gnustep-1.7 
> -fobjc-dispatch-method=non-legacy -fobjc-exceptions -fexceptions 
> -fdiagnostics-show-option -fcolor-diagnostics -fexceptions -fobjc-exceptions 
> -fblocks -o 
> CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/ForwardDeclareProtocol.m.o 
> -x objective-c 
> /Users/afink/development/gnustep/libobjc2/Test/ForwardDeclareProtocol.m
> 1.    <eof> parser at end of file
> 2.    
> /Users/afink/development/gnustep/libobjc2/Test/ForwardDeclareProtocol.m:4:11: 
> LLVM IR generation of declaration 'getProtocol'
> 3.    
> /Users/afink/development/gnustep/libobjc2/Test/ForwardDeclareProtocol.m:4:11: 
> Generating code for declaration 'getProtocol'
> clang-5.0: error: unable to execute command: Segmentation fault
> clang-5.0: error: clang frontend command failed due to signal (use -v to see 
> invocation)
> clang version 5.0.0 (tags/RELEASE_500/final 320467)
> Target: x86_64-unknown-linux-gnu
> Thread model: posix
> InstalledDir: /usr/local/bin
> clang-5.0: 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-5.0: note: diagnostic msg:
> ********************
> 
> PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
> Preprocessed source(s) and associated run script(s) are located at:
> clang-5.0: note: diagnostic msg: /tmp/ForwardDeclareProtocol-e5f47b.m
> clang-5.0: note: diagnostic msg: /tmp/ForwardDeclareProtocol-e5f47b.sh
> clang-5.0: note: diagnostic msg:
> 
> ********************
> Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/build.make:86: recipe 
> for target 
> 'Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/ForwardDeclareProtocol.m.o'
>  failed
> make[2]: *** 
> [Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/ForwardDeclareProtocol.m.o]
>  Error 254
> CMakeFiles/Makefile2:670: recipe for target 
> 'Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/all' failed
> make[1]: *** [Test/CMakeFiles/ForwardDeclareProtocolAccess_legacy.dir/all] 
> Error 2
> Makefile:162: recipe for target 'all' failed
> make: *** [all] Error 2
> 
> _______________________________________________
> Discuss-gnustep mailing list
> Discuss-gnustep@gnu.org
> https://lists.gnu.org/mailman/listinfo/discuss-gnustep




reply via email to

[Prev in Thread] Current Thread [Next in Thread]