• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1if (DEFINED LLVM_HAVE_TF_AOT OR LLVM_HAVE_TFLITE)
2  include(TensorFlowCompile)
3  set(LLVM_RAEVICT_MODEL_PATH_DEFAULT "models/regalloc-eviction")
4
5  set(LLVM_RAEVICT_MODEL_CURRENT_URL "<UNSPECIFIED>" CACHE STRING "URL to download the LLVM register allocator eviction model")
6
7  if (DEFINED LLVM_HAVE_TF_AOT)
8    tf_find_and_compile(
9      ${LLVM_RAEVICT_MODEL_PATH}
10      ${LLVM_RAEVICT_MODEL_CURRENT_URL}
11      ${LLVM_RAEVICT_MODEL_PATH_DEFAULT}
12      "../Analysis/models/gen-regalloc-eviction-test-model.py"
13      serve
14      action
15      RegallocEvictModel
16      llvm::RegallocEvictModel
17    )
18  endif()
19
20  if (LLVM_HAVE_TFLITE)
21    list(APPEND MLLinkDeps ${tensorflow_c_api} ${tensorflow_fx})
22  endif()
23endif()
24
25add_llvm_component_library(LLVMCodeGen
26  AggressiveAntiDepBreaker.cpp
27  AllocationOrder.cpp
28  Analysis.cpp
29  AssignmentTrackingAnalysis.cpp
30  AtomicExpandPass.cpp
31  BasicTargetTransformInfo.cpp
32  BranchFolding.cpp
33  BranchRelaxation.cpp
34  BreakFalseDeps.cpp
35  BasicBlockSections.cpp
36  BasicBlockSectionsProfileReader.cpp
37  CalcSpillWeights.cpp
38  CallingConvLower.cpp
39  CFGuardLongjmp.cpp
40  CFIFixup.cpp
41  CFIInstrInserter.cpp
42  CodeGen.cpp
43  CodeGenCommonISel.cpp
44  CodeGenPassBuilder.cpp
45  CodeGenPrepare.cpp
46  CommandFlags.cpp
47  ComplexDeinterleavingPass.cpp
48  CriticalAntiDepBreaker.cpp
49  DeadMachineInstructionElim.cpp
50  DetectDeadLanes.cpp
51  DFAPacketizer.cpp
52  DwarfEHPrepare.cpp
53  EarlyIfConversion.cpp
54  EdgeBundles.cpp
55  EHContGuardCatchret.cpp
56  ExecutionDomainFix.cpp
57  ExpandLargeDivRem.cpp
58  ExpandLargeFpConvert.cpp
59  ExpandMemCmp.cpp
60  ExpandPostRAPseudos.cpp
61  ExpandReductions.cpp
62  ExpandVectorPredication.cpp
63  FaultMaps.cpp
64  FEntryInserter.cpp
65  FinalizeISel.cpp
66  FixupStatepointCallerSaved.cpp
67  FuncletLayout.cpp
68  GCMetadata.cpp
69  GCMetadataPrinter.cpp
70  GCRootLowering.cpp
71  GlobalMerge.cpp
72  HardwareLoops.cpp
73  IfConversion.cpp
74  ImplicitNullChecks.cpp
75  IndirectBrExpandPass.cpp
76  InlineSpiller.cpp
77  InterferenceCache.cpp
78  InterleavedAccessPass.cpp
79  InterleavedLoadCombinePass.cpp
80  IntrinsicLowering.cpp
81  JMCInstrumenter.cpp
82  LatencyPriorityQueue.cpp
83  LazyMachineBlockFrequencyInfo.cpp
84  LexicalScopes.cpp
85  LiveDebugVariables.cpp
86  LiveIntervals.cpp
87  LiveInterval.cpp
88  LiveIntervalUnion.cpp
89  LivePhysRegs.cpp
90  LiveRangeCalc.cpp
91  LiveIntervalCalc.cpp
92  LiveRangeEdit.cpp
93  LiveRangeShrink.cpp
94  LiveRegMatrix.cpp
95  LiveRegUnits.cpp
96  LiveStacks.cpp
97  LiveVariables.cpp
98  LLVMTargetMachine.cpp
99  LocalStackSlotAllocation.cpp
100  LoopTraversal.cpp
101  LowLevelType.cpp
102  LowerEmuTLS.cpp
103  MachineBasicBlock.cpp
104  MachineBlockFrequencyInfo.cpp
105  MachineBlockPlacement.cpp
106  MachineBranchProbabilityInfo.cpp
107  MachineCFGPrinter.cpp
108  MachineCombiner.cpp
109  MachineCopyPropagation.cpp
110  MachineCSE.cpp
111  MachineCheckDebugify.cpp
112  MachineCycleAnalysis.cpp
113  MachineDebugify.cpp
114  MachineDominanceFrontier.cpp
115  MachineDominators.cpp
116  MachineFrameInfo.cpp
117  MachineFunction.cpp
118  MachineFunctionPass.cpp
119  MachineFunctionPrinterPass.cpp
120  MachineFunctionSplitter.cpp
121  MachineInstrBundle.cpp
122  MachineInstr.cpp
123  MachineLateInstrsCleanup.cpp
124  MachineLICM.cpp
125  MachineLoopInfo.cpp
126  MachineLoopUtils.cpp
127  MachineModuleInfo.cpp
128  MachineModuleInfoImpls.cpp
129  MachineModuleSlotTracker.cpp
130  MachineOperand.cpp
131  MachineOptimizationRemarkEmitter.cpp
132  MachineOutliner.cpp
133  MachinePassManager.cpp
134  MachinePipeliner.cpp
135  MachinePostDominators.cpp
136  MachineRegionInfo.cpp
137  MachineRegisterInfo.cpp
138  MachineScheduler.cpp
139  MachineSink.cpp
140  MachineSizeOpts.cpp
141  MachineSSAContext.cpp
142  MachineSSAUpdater.cpp
143  MachineStripDebug.cpp
144  MachineTraceMetrics.cpp
145  MachineUniformityAnalysis.cpp
146  MachineVerifier.cpp
147  MIRFSDiscriminator.cpp
148  MIRSampleProfile.cpp
149  MIRYamlMapping.cpp
150  MLRegallocEvictAdvisor.cpp
151  MLRegallocPriorityAdvisor.cpp
152  ModuloSchedule.cpp
153  MultiHazardRecognizer.cpp
154  PatchableFunction.cpp
155  MBFIWrapper.cpp
156  MIRPrinter.cpp
157  MIRPrintingPass.cpp
158  MacroFusion.cpp
159  NonRelocatableStringpool.cpp
160  OptimizePHIs.cpp
161  ParallelCG.cpp
162  PeepholeOptimizer.cpp
163  PHIElimination.cpp
164  PHIEliminationUtils.cpp
165  PostRAHazardRecognizer.cpp
166  PostRASchedulerList.cpp
167  PreISelIntrinsicLowering.cpp
168  ProcessImplicitDefs.cpp
169  PrologEpilogInserter.cpp
170  PseudoProbeInserter.cpp
171  PseudoSourceValue.cpp
172  RDFGraph.cpp
173  RDFLiveness.cpp
174  RDFRegisters.cpp
175  ReachingDefAnalysis.cpp
176  RegAllocBase.cpp
177  RegAllocBasic.cpp
178  RegAllocEvictionAdvisor.cpp
179  RegAllocFast.cpp
180  RegAllocGreedy.cpp
181  RegAllocPBQP.cpp
182  RegAllocPriorityAdvisor.cpp
183  RegAllocScore.cpp
184  RegisterClassInfo.cpp
185  RegisterCoalescer.cpp
186  RegisterPressure.cpp
187  RegisterScavenging.cpp
188  RemoveRedundantDebugValues.cpp
189  RenameIndependentSubregs.cpp
190  MachineStableHash.cpp
191  MIRVRegNamerUtils.cpp
192  MIRNamerPass.cpp
193  MIRCanonicalizerPass.cpp
194  RegisterUsageInfo.cpp
195  RegUsageInfoCollector.cpp
196  RegUsageInfoPropagate.cpp
197  ReplaceWithVeclib.cpp
198  ResetMachineFunctionPass.cpp
199  RegisterBank.cpp
200  RegisterBankInfo.cpp
201  SafeStack.cpp
202  SafeStackLayout.cpp
203  SanitizerBinaryMetadata.cpp
204  ScheduleDAG.cpp
205  ScheduleDAGInstrs.cpp
206  ScheduleDAGPrinter.cpp
207  ScoreboardHazardRecognizer.cpp
208  SelectOptimize.cpp
209  ShadowStackGCLowering.cpp
210  ShrinkWrap.cpp
211  SjLjEHPrepare.cpp
212  SlotIndexes.cpp
213  SpillPlacement.cpp
214  SplitKit.cpp
215  StackColoring.cpp
216  StackFrameLayoutAnalysisPass.cpp
217  StackMapLivenessAnalysis.cpp
218  StackMaps.cpp
219  StackProtector.cpp
220  StackSlotColoring.cpp
221  SwiftErrorValueTracking.cpp
222  SwitchLoweringUtils.cpp
223  TailDuplication.cpp
224  TailDuplicator.cpp
225  TargetFrameLoweringImpl.cpp
226  TargetInstrInfo.cpp
227  TargetLoweringBase.cpp
228  TargetLoweringObjectFileImpl.cpp
229  TargetOptionsImpl.cpp
230  TargetPassConfig.cpp
231  TargetRegisterInfo.cpp
232  TargetSchedule.cpp
233  TargetSubtargetInfo.cpp
234  TwoAddressInstructionPass.cpp
235  TypePromotion.cpp
236  UnreachableBlockElim.cpp
237  ValueTypes.cpp
238  VLIWMachineScheduler.cpp
239  VirtRegMap.cpp
240  WasmEHPrepare.cpp
241  WinEHPrepare.cpp
242  XRayInstrumentation.cpp
243  ${GeneratedMLSources}
244
245  LiveDebugValues/LiveDebugValues.cpp
246  LiveDebugValues/VarLocBasedImpl.cpp
247  LiveDebugValues/InstrRefBasedImpl.cpp
248
249  ADDITIONAL_HEADER_DIRS
250  ${LLVM_MAIN_INCLUDE_DIR}/llvm/CodeGen
251  ${LLVM_MAIN_INCLUDE_DIR}/llvm/CodeGen/PBQP
252
253  LINK_LIBS ${LLVM_PTHREAD_LIB} ${MLLinkDeps}
254
255  DEPENDS
256  intrinsics_gen
257  ${MLDeps}
258
259  LINK_COMPONENTS
260  Analysis
261  BitReader
262  BitWriter
263  Core
264  MC
265  ObjCARC
266  ProfileData
267  Scalar
268  Support
269  Target
270  TargetParser
271  TransformUtils
272  )
273
274add_subdirectory(SelectionDAG)
275add_subdirectory(AsmPrinter)
276add_subdirectory(MIRParser)
277add_subdirectory(GlobalISel)
278