LLVMTableGen is broken on SDK 18.08 (worked on 1.6)
Context
Describe the background for the issue/task.
The LLVM TableGen library isn't available in the fd.o SDK 18.08.
- The headers are present.
- llvm-config said the tablegen functions should be available in libLLVM-6.0.so.
- An nm (and some failed links in a project) confirm it's not there.
- There are no other tablegen libraries that could potentially be used.
[📦 org.freedesktop.Sdk ldc-0.17.6-src]$ grep -R TableGenMain /usr/include/ # TableGen functions are in the headers
/usr/include/llvm/TableGen/Main.h:using TableGenMainFn = bool (raw_ostream &OS, RecordKeeper &Records);
/usr/include/llvm/TableGen/Main.h:int TableGenMain(char *argv0, TableGenMainFn *MainFn);
[📦 org.freedesktop.Sdk ldc-0.17.6-src]$ llvm-config --libs tablegen # and llvm-config says it's in libLLVM-6.0
-lLLVM-6.0
[📦 org.freedesktop.Sdk ldc-0.17.6-src]$ nm -DC /usr/lib/x86_64-linux-gnu/libLLVM-6.0.so | grep TableGenMain # ...but it's not
[📦 org.freedesktop.Sdk ldc-0.17.6-src]$ nm -DC /usr/lib/x86_64-linux-gnu/libLLVM-6.0.so | grep llvm:: | head # proof that the other symbols are present
0000000002b0f198 u guard variable for llvm::BranchProbabilityInfo::getBranchProbStackProtector(bool)::LikelyProb
0000000002b03970 u guard variable for llvm::hashing::detail::get_execution_seed()::seed
00000000008f9550 T llvm::addLiveIns(llvm::MachineBasicBlock&, llvm::LivePhysRegs const&)
0000000000781de0 T llvm::AllocaInst::setAlignment(unsigned int)
0000000000781f30 T llvm::AllocaInst::AllocaInst(llvm::Type*, unsigned int, llvm::Value*, unsigned int, llvm::Twine const&, llvm::BasicBlock*)
0000000000781e20 T llvm::AllocaInst::AllocaInst(llvm::Type*, unsigned int, llvm::Value*, unsigned int, llvm::Twine const&, llvm::Instruction*)
0000000000782000 T llvm::AllocaInst::AllocaInst(llvm::Type*, unsigned int, llvm::Value*, llvm::Twine const&, llvm::BasicBlock*)
0000000000781ef0 T llvm::AllocaInst::AllocaInst(llvm::Type*, unsigned int, llvm::Value*, llvm::Twine const&, llvm::Instruction*)
0000000000782020 T llvm::AllocaInst::AllocaInst(llvm::Type*, unsigned int, llvm::Twine const&, llvm::BasicBlock*)
0000000000781f10 T llvm::AllocaInst::AllocaInst(llvm::Type*, unsigned int, llvm::Twine const&, llvm::Instruction*)
grep: write error: Broken pipe
[📦 org.freedesktop.Sdk ldc-0.17.6-src]$ find /usr/lib -iname '*tablegen*' # and there's no libraries mentioning it
/usr/lib/x86_64-linux-gnu/cmake/llvm/TableGen.cmake
[📦 org.freedesktop.Sdk ldc-0.17.6-src]$
Description
Describe the implementation plan. A check list should be used.
- Fix the issue.
- ??
- Profit!
Acceptance Criteria
Identify how this is to be 'proven'. Use links here to the MR, to the documentation, to the demo location, whatever it is that is that is being delivered.
Magic, I guess?
Maybe make one issue template for contributors like this one and another one for external users