1 //===-- llvm/CodeGen/Spiller.h - Spiller -*- C++ -*------------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef LLVM_CODEGEN_SPILLER_H
11 #define LLVM_CODEGEN_SPILLER_H
20 class MachineFunction
;
25 /// Spiller interface.
27 /// Implementations are utility classes which insert spill or remat code on
31 virtual ~Spiller() = 0;
33 /// Spill the given live range. The method used will depend on the Spiller
34 /// implementation selected.
35 virtual std::vector
<LiveInterval
*> spill(LiveInterval
*li
) = 0;
37 /// Intra-block split.
38 virtual std::vector
<LiveInterval
*> intraBlockSplit(LiveInterval
*li
,
43 /// Create and return a spiller object, as specified on the command line.
44 Spiller
* createSpiller(MachineFunction
*mf
, LiveIntervals
*li
,
45 LiveStacks
*ls
, VirtRegMap
*vrm
);