Put instruction names into an indexed string table on the side, removing a pointer from MCInstrDesc.

Make them accessible through MCInstrInfo. They are only used for debugging purposes so this doesn't
have an impact on performance. X86MCTargetDesc.o goes from 630K to 461K on x86_64.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150245 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Benjamin Kramer
2012-02-10 13:18:44 +00:00
parent 06efdd238e
commit c667ba69ac
5 changed files with 39 additions and 14 deletions
+4 -1
View File
@@ -1484,7 +1484,10 @@ void MachineInstr::print(raw_ostream &OS, const TargetMachine *TM) const {
OS << " = ";
// Print the opcode name.
OS << getDesc().getName();
if (TM && TM->getInstrInfo())
OS << TM->getInstrInfo()->getName(getOpcode());
else
OS << "UNKNOWN";
// Print the rest of the operands.
bool OmittedAnyCallClobbers = false;