phosek added a comment.

This was already on my list of build system features I'd like to implement and 
I'm glad someone else is already looking into it, thank you! I have two high 
level comments about your approach.

The first one is related to the use of Clang build as the training data. I 
think that Clang build is both unnecessarily heavyweight, but also not 
particularly representative of typical workloads (most Clang users don't use it 
to build Clang). Ideally, we would give vendors the flexibility to supply their 
own training data. I'd prefer reusing the existing perf-training 
<https://github.com/llvm/llvm-project/tree/main/clang/utils/perf-training> 
setup to do so. In fact, I'd imagine most vendors would likely use the same 
training data for both PGO and BOLT and that use case should be supported.

The second one is related to applicability. I don't think this mechanism should 
be limited only to Clang. Ideally, it should be possible to instrument and 
optimize other tools in the toolchain distribution as well; LLD is likely going 
to be the most common one after Clang.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D132975/new/

https://reviews.llvm.org/D132975

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to