Revert r129518, "Change ELF systems to use CFI for producing the EH tables. This...
[oota-llvm.git] / lib / CodeGen / Spiller.h
index 12506fe4dec88a961b02c22d48af1f1f5bc5de4c..41f1727da43921b102c79ea94b91508f785425e8 100644 (file)
 #ifndef LLVM_CODEGEN_SPILLER_H
 #define LLVM_CODEGEN_SPILLER_H
 
-#include <vector>
-
 namespace llvm {
-  struct LiveInterval;
+
+  class LiveRangeEdit;
+  class MachineFunction;
+  class MachineFunctionPass;
+  class VirtRegMap;
 
   /// Spiller interface.
   ///
@@ -22,12 +24,23 @@ namespace llvm {
   class Spiller {
   public:
     virtual ~Spiller() = 0;
-    virtual std::vector<LiveInterval*> spill(class LiveInterval *li) = 0;
+
+    /// spill - Spill the LRE.getParent() live interval.
+    virtual void spill(LiveRangeEdit &LRE) = 0;
+
   };
 
   /// Create and return a spiller object, as specified on the command line.
-  Spiller* createSpiller(class MachineFunction *mf, class LiveIntervals *li,
-                         class VirtRegMap *vrm);
+  Spiller* createSpiller(MachineFunctionPass &pass,
+                         MachineFunction &mf,
+                         VirtRegMap &vrm);
+
+  /// Create and return a spiller that will insert spill code directly instead
+  /// of deferring though VirtRegMap.
+  Spiller *createInlineSpiller(MachineFunctionPass &pass,
+                               MachineFunction &mf,
+                               VirtRegMap &vrm);
+
 }
 
 #endif