1//===-- llvm/CodeGen/Spiller.h - Spiller -*- C++ -*------------------------===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9 10#ifndef LLVM_CODEGEN_SPILLER_H 11#define LLVM_CODEGEN_SPILLER_H 12
| 1//===-- llvm/CodeGen/Spiller.h - Spiller -*- C++ -*------------------------===// 2// 3// The LLVM Compiler Infrastructure 4// 5// This file is distributed under the University of Illinois Open Source 6// License. See LICENSE.TXT for details. 7// 8//===----------------------------------------------------------------------===// 9 10#ifndef LLVM_CODEGEN_SPILLER_H 11#define LLVM_CODEGEN_SPILLER_H 12
|
| 13#include "llvm/ADT/SmallVector.h"
|
13#include <vector> 14 15namespace llvm { 16 17 class LiveInterval; 18 class LiveIntervals; 19 class LiveStacks; 20 class MachineFunction; 21 class MachineInstr;
| 14#include <vector> 15 16namespace llvm { 17 18 class LiveInterval; 19 class LiveIntervals; 20 class LiveStacks; 21 class MachineFunction; 22 class MachineInstr;
|
| 23 class MachineLoopInfo;
|
22 class VirtRegMap; 23 class VNInfo; 24 25 /// Spiller interface. 26 /// 27 /// Implementations are utility classes which insert spill or remat code on 28 /// demand. 29 class Spiller { 30 public: 31 virtual ~Spiller() = 0; 32 33 /// Spill the given live range. The method used will depend on the Spiller 34 /// implementation selected.
| 24 class VirtRegMap; 25 class VNInfo; 26 27 /// Spiller interface. 28 /// 29 /// Implementations are utility classes which insert spill or remat code on 30 /// demand. 31 class Spiller { 32 public: 33 virtual ~Spiller() = 0; 34 35 /// Spill the given live range. The method used will depend on the Spiller 36 /// implementation selected.
|
35 virtual std::vector<LiveInterval*> spill(LiveInterval *li) = 0;
| 37 virtual std::vector<LiveInterval*> spill(LiveInterval *li, 38 SmallVectorImpl<LiveInterval*> &spillIs) = 0;
|
36
| 39
|
37 /// Intra-block split. 38 virtual std::vector<LiveInterval*> intraBlockSplit(LiveInterval *li, 39 VNInfo *valno) = 0; 40
| |
41 }; 42 43 /// Create and return a spiller object, as specified on the command line. 44 Spiller* createSpiller(MachineFunction *mf, LiveIntervals *li,
| 40 }; 41 42 /// Create and return a spiller object, as specified on the command line. 43 Spiller* createSpiller(MachineFunction *mf, LiveIntervals *li,
|
45 LiveStacks *ls, VirtRegMap *vrm);
| 44 LiveStacks *ls, const MachineLoopInfo *loopInfo, 45 VirtRegMap *vrm);
|
46} 47 48#endif
| 46} 47 48#endif
|