mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-20 19:42:54 +02:00
R600/SI: Remove MachineFunction dump from AsmPrinter
The dump was dependent on a feature string, which meant that it couldn't be disabled or enable on a per compile basis. llvm-svn: 225275
This commit is contained in:
parent
83f99b8d3f
commit
ddd3dfdd38
@ -161,23 +161,18 @@ bool AMDGPUAsmPrinter::runOnMachineFunction(MachineFunction &MF) {
|
||||
}
|
||||
}
|
||||
|
||||
if (STM.dumpCode()) {
|
||||
#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
|
||||
MF.dump();
|
||||
#endif
|
||||
if (STM.dumpCode() && DisasmEnabled) {
|
||||
|
||||
if (DisasmEnabled) {
|
||||
OutStreamer.SwitchSection(Context.getELFSection(".AMDGPU.disasm",
|
||||
ELF::SHT_NOTE, 0,
|
||||
SectionKind::getReadOnly()));
|
||||
OutStreamer.SwitchSection(Context.getELFSection(".AMDGPU.disasm",
|
||||
ELF::SHT_NOTE, 0,
|
||||
SectionKind::getReadOnly()));
|
||||
|
||||
for (size_t i = 0; i < DisasmLines.size(); ++i) {
|
||||
std::string Comment(DisasmLineMaxLen - DisasmLines[i].size(), ' ');
|
||||
Comment += " ; " + HexLines[i] + "\n";
|
||||
for (size_t i = 0; i < DisasmLines.size(); ++i) {
|
||||
std::string Comment(DisasmLineMaxLen - DisasmLines[i].size(), ' ');
|
||||
Comment += " ; " + HexLines[i] + "\n";
|
||||
|
||||
OutStreamer.EmitBytes(StringRef(DisasmLines[i]));
|
||||
OutStreamer.EmitBytes(StringRef(Comment));
|
||||
}
|
||||
OutStreamer.EmitBytes(StringRef(DisasmLines[i]));
|
||||
OutStreamer.EmitBytes(StringRef(Comment));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user