Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Results of llvm-tblgen are not reused in incremental compilation #91117

Open
ZelinMa557 opened this issue May 5, 2024 · 2 comments
Open

Results of llvm-tblgen are not reused in incremental compilation #91117

ZelinMa557 opened this issue May 5, 2024 · 2 comments

Comments

@ZelinMa557
Copy link
Contributor

I notice that every time I compile the clang & LLVM, the following things will be rebuilt whether or not relative code is changed:

[ 40%] Building ARMGenAsmMatcher.inc...
[ 40%] Building ARMGenAsmWriter.inc...
[ 40%] Building ARMGenCallingConv.inc...
[ 40%] Building ARMGenDisassemblerTables.inc...
[ 40%] Building ARMGenFastISel.inc...
[ 40%] Building ARMGenGlobalISel.inc...
[ 40%] Building ARMGenInstrInfo.inc...
[ 40%] Building ARMGenMCCodeEmitter.inc...
[ 40%] Building ARMGenMCPseudoLowering.inc...
[ 41%] Building ARMGenRegisterBank.inc...
[ 41%] Building ARMGenRegisterInfo.inc...
[ 41%] Building ARMGenSubtargetInfo.inc...
[ 41%] Building ARMGenSystemRegister.inc...
[ 43%] Building BPFGenAsmMatcher.inc...
[ 43%] Building BPFGenAsmWriter.inc...
[ 43%] Building BPFGenCallingConv.inc...
[ 43%] Building BPFGenDisassemblerTables.inc...
[ 43%] Building BPFGenGlobalISel.inc...
[ 43%] Building BPFGenInstrInfo.inc...
[ 43%] Building BPFGenMCCodeEmitter.inc...
[ 43%] Building BPFGenRegisterBank.inc...
[ 43%] Building BPFGenRegisterInfo.inc...
[ 43%] Building BPFGenSubtargetInfo.inc...

This costs a lot of time. Is there any chance to improve that?

@zero9178
Copy link
Member

zero9178 commented May 5, 2024

Are you using the Makefiles generator by any chance rather than ninja (-G Ninja with the cmake command line)? Last I recall make is not as capable in reading in the dep files produced by TableGen as well as pruning the build graph if the output didn't change. Ninja is generally much better than make

@ZelinMa557
Copy link
Contributor Author

Yes, I was using Make to build clang/llvm. But I think we can do something to improve it since many people use Make to build llvm.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants