mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 11:42:57 +01:00
use getSectionForFunction to decide which section to emit code into
llvm-svn: 30738
This commit is contained in:
parent
758352e9b1
commit
a293b73042
@ -58,7 +58,7 @@ namespace {
|
||||
bool runOnMachineFunction(MachineFunction &F);
|
||||
bool doInitialization(Module &M);
|
||||
bool doFinalization(Module &M);
|
||||
|
||||
|
||||
bool PrintAsmOperand(const MachineInstr *MI, unsigned OpNo,
|
||||
unsigned AsmVariant, const char *ExtraCode);
|
||||
bool PrintAsmMemoryOperand(const MachineInstr *MI,
|
||||
@ -73,8 +73,8 @@ namespace {
|
||||
/// using the given target machine description. This should work
|
||||
/// regardless of whether the function is in SSA form.
|
||||
///
|
||||
FunctionPass *llvm::createAlphaCodePrinterPass (std::ostream &o,
|
||||
TargetMachine &tm) {
|
||||
FunctionPass *llvm::createAlphaCodePrinterPass(std::ostream &o,
|
||||
TargetMachine &tm) {
|
||||
return new AlphaAsmPrinter(o, tm, tm.getTargetAsmInfo());
|
||||
}
|
||||
|
||||
@ -166,7 +166,8 @@ bool AlphaAsmPrinter::runOnMachineFunction(MachineFunction &MF) {
|
||||
|
||||
// Print out labels for the function.
|
||||
const Function *F = MF.getFunction();
|
||||
SwitchToTextSection(".text", F);
|
||||
SwitchToTextSection(getSectionForFunction(*F).c_str(), F);
|
||||
|
||||
EmitAlignment(4, F);
|
||||
switch (F->getLinkage()) {
|
||||
default: assert(0 && "Unknown linkage type!");
|
||||
|
Loading…
Reference in New Issue
Block a user