mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-26 12:20:42 +00:00
Codegen pass definition cleanup. No functionality.
Moving toward a uniform style of pass definition to allow easier target configuration. Globally declare Pass ID. Globally declare pass initializer. Use INITIALIZE_PASS consistently. Add a call to the initializer from CodeGen.cpp. Remove redundant "createPass" functions and "getPassName" methods. While cleaning up declarations, cleaned up comments (sorry for large diff). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150100 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -74,7 +74,6 @@ namespace {
|
||||
MachineFunctionPass(ID), PreRegAlloc(false) {}
|
||||
|
||||
virtual bool runOnMachineFunction(MachineFunction &MF);
|
||||
virtual const char *getPassName() const { return "Tail Duplication"; }
|
||||
|
||||
private:
|
||||
void AddSSAUpdateEntry(unsigned OrigReg, unsigned NewReg,
|
||||
@@ -118,9 +117,10 @@ namespace {
|
||||
char TailDuplicatePass::ID = 0;
|
||||
}
|
||||
|
||||
FunctionPass *llvm::createTailDuplicatePass() {
|
||||
return new TailDuplicatePass();
|
||||
}
|
||||
char &llvm::TailDuplicateID = TailDuplicatePass::ID;
|
||||
|
||||
INITIALIZE_PASS(TailDuplicatePass, "tailduplication", "Tail Duplication",
|
||||
false, false)
|
||||
|
||||
bool TailDuplicatePass::runOnMachineFunction(MachineFunction &MF) {
|
||||
TII = MF.getTarget().getInstrInfo();
|
||||
|
||||
Reference in New Issue
Block a user