diff options
author | Nate Begeman <natebegeman@mac.com> | 2006-04-22 18:53:45 +0000 |
---|---|---|
committer | Nate Begeman <natebegeman@mac.com> | 2006-04-22 18:53:45 +0000 |
commit | 4ca2ea5b43a69c3786f8636675b486455a2cbf3f (patch) | |
tree | c773e752243da2d8cdb31290fd9b3d8edeba04ec /llvm/lib/CodeGen/MachineInstr.cpp | |
parent | e728efdfce8bb978a576fa3ba9306d17d565b077 (diff) | |
download | bcm5719-llvm-4ca2ea5b43a69c3786f8636675b486455a2cbf3f.tar.gz bcm5719-llvm-4ca2ea5b43a69c3786f8636675b486455a2cbf3f.zip |
JumpTable support! What this represents is working asm and jit support for
x86 and ppc for 100% dense switch statements when relocations are non-PIC.
This support will be extended and enhanced in the coming days to support
PIC, and less dense forms of jump tables.
llvm-svn: 27947
Diffstat (limited to 'llvm/lib/CodeGen/MachineInstr.cpp')
-rw-r--r-- | llvm/lib/CodeGen/MachineInstr.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/MachineInstr.cpp b/llvm/lib/CodeGen/MachineInstr.cpp index 973e3ec1e6e..f92c0844d8a 100644 --- a/llvm/lib/CodeGen/MachineInstr.cpp +++ b/llvm/lib/CodeGen/MachineInstr.cpp @@ -238,6 +238,9 @@ static void print(const MachineOperand &MO, std::ostream &OS, case MachineOperand::MO_ConstantPoolIndex: OS << "<cp#" << MO.getConstantPoolIndex() << ">"; break; + case MachineOperand::MO_JumpTableIndex: + OS << "<jt#" << MO.getJumpTableIndex() << ">"; + break; case MachineOperand::MO_GlobalAddress: OS << "<ga:" << ((Value*)MO.getGlobal())->getName(); if (MO.getOffset()) OS << "+" << MO.getOffset(); @@ -377,6 +380,9 @@ std::ostream &operator<<(std::ostream &OS, const MachineOperand &MO) { case MachineOperand::MO_ConstantPoolIndex: OS << "<cp#" << MO.getConstantPoolIndex() << ">"; break; + case MachineOperand::MO_JumpTableIndex: + OS << "<jt#" << MO.getJumpTableIndex() << ">"; + break; case MachineOperand::MO_GlobalAddress: OS << "<ga:" << ((Value*)MO.getGlobal())->getName() << ">"; break; |