Unfortunately I'm running into a problem with check-all, where it fails to link XRayTest-x86_64-Test:
[100%] Generating XRayTest-x86_64-Test
/home/dim/llvm/8.0.0/rc1/Phase3/Release/llvmCore-8.0.0-rc1.obj/./lib/libLLVMSupport.a(Signals.cpp.o): In function `llvm::sys::PrintStackTrace(llvm::raw_ostream&)':
Signals.cpp:(.text._ZN4llvm3sys15PrintStackTraceERNS_11raw_ostreamE+0x24): undefined reference to `backtrace'
Signals.cpp:(.text._ZN4llvm3sys15PrintStackTraceERNS_11raw_ostreamE+0x254): undefined reference to `llvm::itaniumDemangle(char const*, char*, unsigned long*, int*)'
clang-8: error: linker command failed with exit code 1 (use -v to see invocation)
gmake[3]: *** [projects/compiler-rt/lib/xray/tests/unit/CMakeFiles/TXRayTest-x86_64-Test.dir/build.make:73: projects/compiler-rt/lib/xray/tests/unit/XRayTest-x86_64-Test] Error 1
gmake[3]: Target 'projects/compiler-rt/lib/xray/tests/unit/CMakeFiles/TXRayTest-x86_64-Test.dir/build' not remade because of errors.
gmake[2]: *** [CMakeFiles/Makefile2:33513: projects/compiler-rt/lib/xray/tests/unit/CMakeFiles/TXRayTest-x86_64-Test.dir/all] Error 2
gmake[2]: Target 'CMakeFiles/check-all.dir/all' not remade because of errors.
gmake[1]: *** [CMakeFiles/Makefile2:737: CMakeFiles/check-all.dir/rule] Error 2
gmake[1]: Target 'check-all' not remade because of errors.
gmake: *** [Makefile:277: check-all] Error 2
[Release Phase3] check-all failed
It appears this is because -lexecinfo is not passed to the link command line, but I'm unsure why this only seems to affect the XRay test. I'm investigating, but if anybody has a cluestick, please hit me.
We've been having similar issue on NetBSD in the past. Long story
short, the code around there is not using CMake rules to build stuff but
a custom compiler invocation, and therefore it does not inherit library
dependencies from CMake.
Short-term solution is to figure out what's missing and add it, with
appropriate conditionals.
Long-term solution (which is probably not suitable for 8.0.0) is to
rewrite that whole stuff. Probably could work by creating a custom
language for CMake that's like C but uses just-built clang, etc.
However, that's just my theory and I'm not 100% sure it'll work or how
much work it'd involve.
# Look for terminfo library, used in unittests that depend on LLVMSupport.
if(LLVM_ENABLE_TERMINFO)
--- llvm.src/projects/compiler-rt/lib/xray/tests/CMakeLists.txt
+++ llvm.src/projects/compiler-rt/lib/xray/tests/CMakeLists.txt
@@ -71,13 +71,14 @@ if (NOT APPLE)
endforeach()
# We also add the actual libraries to link as dependencies.
- list(APPEND XRAY_UNITTEST_LINK_FLAGS -lLLVMXRay -lLLVMSupport -lLLVMTestingSupport)
+ list(APPEND XRAY_UNITTEST_LINK_FLAGS -lLLVMXRay -lLLVMSupport -lLLVMDemangle -lLLVMTestingSupport)
endif()
Hi,
working without immediately obvious regressions on OpenMandriva x86-64, x86, aarch64 and armv7hnl.
Since our 4.0 release is imminent, 8.0 won’t go in there, but it will be our main compiler the day after the release and been cut.
Would be nice to get the admin goto patches in to enable building the Linux kernel, but unfortunately that may be too big a change after RC?
Hi,
working without immediately obvious regressions on OpenMandriva x86-64, x86, aarch64 and armv7hnl.
Since our 4.0 release is imminent, 8.0 won't go in there, but it will be our main compiler the day after the release and been cut.
Would be nice to get the admin goto patches in to enable building the Linux kernel, but unfortunately that may be too big a change after RC?
I'm definitely still open to considering those for llvm 8. I think it
depends on what they look like in the end, and when they land. But
they'll have to land on trunk first
Alex, ping? There was a thread about moving Risc-V out of experimental
but I think it didn't go anywhere?
I think it would make most sense to move RISC-V out of experimental to
become a standard target for the 9.0 release. It would have been nice
to be at that point prior to the 8.0 branch, but it hasn't been
possible with the resources I've had.
Separately, do the listed patches sound okay for merging?
I'm not fully sure what your policy is in merging patches for
experimental targets. It would be nice to merge r352169 and r352171 as
Bruce suggests though.
>
> Alex, ping? There was a thread about moving Risc-V out of experimental
> but I think it didn't go anywhere?
I think it would make most sense to move RISC-V out of experimental to
become a standard target for the 9.0 release. It would have been nice
to be at that point prior to the 8.0 branch, but it hasn't been
possible with the resources I've had.
Okay, thanks for the update.
> Separately, do the listed patches sound okay for merging?
I'm not fully sure what your policy is in merging patches for
experimental targets. It would be nice to merge r352169 and r352171 as
Bruce suggests though.
I tried merging r352169 but there merge conflicts in
lib/Target/RISCV/RISCVInstrInfo.td,
test/CodeGen/RISCV/atomic-cmpxchg.ll and
test/CodeGen/RISCV/atomic-rmw.ll.
I didn't actually look at the conflicts, but since the target is still
in experimental and the merge isn't trivial, maybe it's not worth it?
I'm still happy to take them if someone wants to help me resolve the
conflicts though.