Index: include/llvm/Target/TargetMachine.h =================================================================== --- include/llvm/Target/TargetMachine.h +++ include/llvm/Target/TargetMachine.h @@ -217,6 +217,11 @@ /// uses this to answer queries about the IR. virtual TargetIRAnalysis getTargetIRAnalysis(); + /// Add target-specific function passes that should be run as early as + /// possible in the optimization pipeline. Most TargetMachines have no such + /// passes. + virtual void addEarlyAsPossiblePasses(PassManagerBase &) {} + /// These enums are meant to be passed into addPassesToEmitFile to indicate /// what type of file to emit, and returned by it to indicate what type of /// file could actually be made.