mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
Add new helpers for registering targets.
- Less boilerplate == good. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77052 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -63,17 +63,6 @@ namespace {
|
||||
};
|
||||
} // end of anonymous namespace
|
||||
|
||||
/// createAlphaCodePrinterPass - Returns a pass that prints the Alpha
|
||||
/// assembly code for a MachineFunction to the given output stream,
|
||||
/// using the given target machine description. This should work
|
||||
/// regardless of whether the function is in SSA form.
|
||||
///
|
||||
FunctionPass *llvm::createAlphaCodePrinterPass(formatted_raw_ostream &o,
|
||||
TargetMachine &tm,
|
||||
bool verbose) {
|
||||
return new AlphaAsmPrinter(o, tm, tm.getTargetAsmInfo(), verbose);
|
||||
}
|
||||
|
||||
#include "AlphaGenAsmWriter.inc"
|
||||
|
||||
void AlphaAsmPrinter::printOperand(const MachineInstr *MI, int opNum)
|
||||
@@ -288,6 +277,5 @@ bool AlphaAsmPrinter::PrintAsmMemoryOperand(const MachineInstr *MI,
|
||||
|
||||
// Force static initialization.
|
||||
extern "C" void LLVMInitializeAlphaAsmPrinter() {
|
||||
TargetRegistry::RegisterAsmPrinter(TheAlphaTarget,
|
||||
createAlphaCodePrinterPass);
|
||||
RegisterAsmPrinter<AlphaAsmPrinter> X(TheAlphaTarget);
|
||||
}
|
||||
|
Reference in New Issue
Block a user