mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-24 06:30:19 +00:00
Factory methods for FunctionPasses now return type FunctionPass *.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7823 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
fb0ef2e82c
commit
19df3876e6
@ -17,15 +17,15 @@
|
||||
|
||||
class Function;
|
||||
class TargetMachine;
|
||||
class Pass;
|
||||
class FunctionPass;
|
||||
class SSARegMap;
|
||||
class MachineFunctionInfo;
|
||||
class MachineFrameInfo;
|
||||
class MachineConstantPool;
|
||||
|
||||
Pass *createMachineCodeConstructionPass(TargetMachine &TM);
|
||||
Pass *createMachineCodeDestructionPass();
|
||||
Pass *createMachineFunctionPrinterPass();
|
||||
FunctionPass *createMachineCodeConstructionPass(TargetMachine &TM);
|
||||
FunctionPass *createMachineCodeDestructionPass();
|
||||
FunctionPass *createMachineFunctionPrinterPass();
|
||||
|
||||
class MachineFunction : private Annotation {
|
||||
const Function *Fn;
|
||||
|
@ -8,7 +8,7 @@
|
||||
#ifndef LLVM_CODEGEN_PASSES_H
|
||||
#define LLVM_CODEGEN_PASSES_H
|
||||
|
||||
class Pass;
|
||||
class FunctionPass;
|
||||
class PassInfo;
|
||||
|
||||
// PHIElimination pass - This pass eliminates machine instruction PHI nodes by
|
||||
@ -22,17 +22,17 @@ extern const PassInfo *PHIEliminationID;
|
||||
/// from SSA form to use explicit registers by spilling every register. Wow,
|
||||
/// great policy huh?
|
||||
///
|
||||
Pass *createSimpleRegisterAllocator();
|
||||
FunctionPass *createSimpleRegisterAllocator();
|
||||
|
||||
/// LocalRegisterAllocation Pass - This pass register allocates the input code a
|
||||
/// basic block at a time, yielding code better than the simple register
|
||||
/// allocator, but not as good as a global allocator.
|
||||
///
|
||||
Pass *createLocalRegisterAllocator();
|
||||
FunctionPass *createLocalRegisterAllocator();
|
||||
|
||||
/// PrologEpilogCodeInserter Pass - This pass inserts prolog and epilog code,
|
||||
/// and eliminates abstract frame references.
|
||||
///
|
||||
Pass *createPrologEpilogCodeInserter();
|
||||
FunctionPass *createPrologEpilogCodeInserter();
|
||||
|
||||
#endif
|
||||
|
@ -9,6 +9,7 @@
|
||||
#define LLVM_TRANSFORMS_SCALAR_H
|
||||
|
||||
class Pass;
|
||||
class FunctionPass;
|
||||
class GetElementPtrInst;
|
||||
class PassInfo;
|
||||
class TerminatorInst;
|
||||
@ -244,7 +245,7 @@ Pass *createRaiseAllocationsPass();
|
||||
// This pass converts SwitchInst instructions into a sequence of chained binary
|
||||
// branch instructions.
|
||||
//
|
||||
Pass *createLowerSwitchPass();
|
||||
FunctionPass *createLowerSwitchPass();
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
//
|
||||
|
@ -80,15 +80,15 @@ namespace {
|
||||
};
|
||||
}
|
||||
|
||||
Pass *createMachineCodeConstructionPass(TargetMachine &Target) {
|
||||
FunctionPass *createMachineCodeConstructionPass(TargetMachine &Target) {
|
||||
return new ConstructMachineFunction(Target);
|
||||
}
|
||||
|
||||
Pass *createMachineCodeDestructionPass() {
|
||||
FunctionPass *createMachineCodeDestructionPass() {
|
||||
return new DestroyMachineFunction();
|
||||
}
|
||||
|
||||
Pass *createMachineFunctionPrinterPass() {
|
||||
FunctionPass *createMachineFunctionPrinterPass() {
|
||||
return new Printer();
|
||||
}
|
||||
|
||||
|
@ -62,7 +62,7 @@ namespace {
|
||||
/// createPrologEpilogCodeInserter - This function returns a pass that inserts
|
||||
/// prolog and epilog code, and eliminates abstract frame references.
|
||||
///
|
||||
Pass *createPrologEpilogCodeInserter() { return new PEI(); }
|
||||
FunctionPass *createPrologEpilogCodeInserter() { return new PEI(); }
|
||||
|
||||
|
||||
/// saveCallerSavedRegisters - Scan the function for modified caller saved
|
||||
|
@ -643,6 +643,6 @@ bool RA::runOnMachineFunction(MachineFunction &Fn) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Pass *createLocalRegisterAllocator() {
|
||||
FunctionPass *createLocalRegisterAllocator() {
|
||||
return new RA();
|
||||
}
|
||||
|
@ -224,6 +224,6 @@ bool RegAllocSimple::runOnMachineFunction(MachineFunction &Fn) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Pass *createSimpleRegisterAllocator() {
|
||||
FunctionPass *createSimpleRegisterAllocator() {
|
||||
return new RegAllocSimple();
|
||||
}
|
||||
|
@ -117,7 +117,7 @@ namespace {
|
||||
};
|
||||
}
|
||||
|
||||
Pass *createX86FloatingPointStackifierPass() { return new FPS(); }
|
||||
FunctionPass *createX86FloatingPointStackifierPass() { return new FPS(); }
|
||||
|
||||
/// runOnMachineFunction - Loop over all of the basic blocks, transforming FP
|
||||
/// register references into FP stack references.
|
||||
|
@ -112,6 +112,6 @@ void ISel::expandArguments(SelectionDAG &SD, MachineFunction &F) {
|
||||
/// into a machine code representation using pattern matching and a machine
|
||||
/// description file.
|
||||
///
|
||||
Pass *createX86PatternInstructionSelector(TargetMachine &TM) {
|
||||
FunctionPass *createX86PatternInstructionSelector(TargetMachine &TM) {
|
||||
return new ISel(TM);
|
||||
}
|
||||
|
@ -2105,6 +2105,6 @@ void ISel::visitFreeInst(FreeInst &I) {
|
||||
/// into a machine code representation is a very simple peep-hole fashion. The
|
||||
/// generated code sucks but the implementation is nice and simple.
|
||||
///
|
||||
Pass *createX86SimpleInstructionSelector(TargetMachine &TM) {
|
||||
FunctionPass *createX86SimpleInstructionSelector(TargetMachine &TM) {
|
||||
return new ISel(TM);
|
||||
}
|
||||
|
@ -19,7 +19,7 @@ namespace {
|
||||
};
|
||||
}
|
||||
|
||||
Pass *createX86PeepholeOptimizerPass() { return new PH(); }
|
||||
FunctionPass *createX86PeepholeOptimizerPass() { return new PH(); }
|
||||
|
||||
bool PH::runOnMachineFunction(MachineFunction &MF) {
|
||||
bool Changed = false;
|
||||
|
@ -117,7 +117,7 @@ namespace {
|
||||
};
|
||||
}
|
||||
|
||||
Pass *createX86FloatingPointStackifierPass() { return new FPS(); }
|
||||
FunctionPass *createX86FloatingPointStackifierPass() { return new FPS(); }
|
||||
|
||||
/// runOnMachineFunction - Loop over all of the basic blocks, transforming FP
|
||||
/// register references into FP stack references.
|
||||
|
@ -112,6 +112,6 @@ void ISel::expandArguments(SelectionDAG &SD, MachineFunction &F) {
|
||||
/// into a machine code representation using pattern matching and a machine
|
||||
/// description file.
|
||||
///
|
||||
Pass *createX86PatternInstructionSelector(TargetMachine &TM) {
|
||||
FunctionPass *createX86PatternInstructionSelector(TargetMachine &TM) {
|
||||
return new ISel(TM);
|
||||
}
|
||||
|
@ -2105,6 +2105,6 @@ void ISel::visitFreeInst(FreeInst &I) {
|
||||
/// into a machine code representation is a very simple peep-hole fashion. The
|
||||
/// generated code sucks but the implementation is nice and simple.
|
||||
///
|
||||
Pass *createX86SimpleInstructionSelector(TargetMachine &TM) {
|
||||
FunctionPass *createX86SimpleInstructionSelector(TargetMachine &TM) {
|
||||
return new ISel(TM);
|
||||
}
|
||||
|
@ -19,7 +19,7 @@ namespace {
|
||||
};
|
||||
}
|
||||
|
||||
Pass *createX86PeepholeOptimizerPass() { return new PH(); }
|
||||
FunctionPass *createX86PeepholeOptimizerPass() { return new PH(); }
|
||||
|
||||
bool PH::runOnMachineFunction(MachineFunction &MF) {
|
||||
bool Changed = false;
|
||||
|
@ -30,7 +30,7 @@ namespace {
|
||||
}
|
||||
|
||||
// createLowerSwitchPass - Interface to this file...
|
||||
Pass *createLowerSwitchPass() {
|
||||
FunctionPass *createLowerSwitchPass() {
|
||||
return new LowerSwitch();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user