This remove the dependency from the RISCV TableGen target definitions
for builds that do not build the RISCV target.
Details
Details
- Reviewers
craig.topper asb jrtc27
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
I'd say ~0.75x speedup when building LLVMTargetParser. Mostly because the build of LLVMTargetParser now requires less dependencies (in my specific case, from 188 to 165).
Of course this does not reflect on a full compiler build...
% cmake ../llvm-project/llvm -G Ninja -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_ASSERTIONS=ON -DLLVM_TARGETS_TO_BUILD="AArch64;ARM;X86" % time ninja -j1 LLVMTargetParser [165/165] Linking CXX static library lib/libLLVMTargetParser.a ninja -j1 LLVMTargetParser 44.86s user 4.55s system 98% cpu 50.027 total
% cmake ../llvm-project/llvm -G Ninja -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_ASSERTIONS=ON -DLLVM_TARGETS_TO_BUILD="AArch64;ARM;X86;RISCV" % time ninja -j1 LLVMTargetParser [188/188] Linking CXX static library lib/libLLVMTargetParser.a ninja -j1 LLVMTargetParser 56.60s user 5.70s system 98% cpu 1:03.45 total
llvm/lib/TargetParser/RISCVTargetParser.cpp | ||
---|---|---|
42 | Will this cause invalid to show up in -mcpu=help? ISTM it would be better if the list were empty when it's not enabled. |
Comment Actions
Doesn't this change the behaviour of clang -emit-llvm, which is supposed to work the same regardless of what targets you have enabled? If so, NAK.
Comment Actions
Ah - very good point! I didn't know about this. I will abandon the change.
Thanks,
Francesco
Will this cause invalid to show up in -mcpu=help? ISTM it would be better if the list were empty when it's not enabled.