diff options
Diffstat (limited to 'rts/Disassembler.c')
-rw-r--r-- | rts/Disassembler.c | 53 |
1 files changed, 50 insertions, 3 deletions
diff --git a/rts/Disassembler.c b/rts/Disassembler.c index e133e3a6ff..01d6c3b1d9 100644 --- a/rts/Disassembler.c +++ b/rts/Disassembler.c @@ -68,7 +68,11 @@ disInstr ( StgBCO *bco, int pc ) case bci_BRK_FUN: debugBelch ("BRK_FUN " ); printPtr( ptrs[instrs[pc]] ); debugBelch (" %d ", instrs[pc+1]); printPtr( ptrs[instrs[pc+2]] ); - debugBelch(" %s\n", ((CostCentre*)(literals[instrs[pc+3]]))->label); + CostCentre* cc = (CostCentre*)literals[instrs[pc+3]]; + if (cc) { + debugBelch(" %s", cc->label); + } + debugBelch("\n"); pc += 4; break; case bci_SWIZZLE: @@ -94,11 +98,28 @@ disInstr ( StgBCO *bco, int pc ) debugBelch("PUSH_LLL %d %d %d\n", instrs[pc], instrs[pc+1], instrs[pc+2] ); pc += 3; break; + case bci_PUSH8: + debugBelch("PUSH8 %d\n", instrs[pc] ); + pc += 1; break; + case bci_PUSH16: + debugBelch("PUSH16 %d\n", instrs[pc] ); + pc += 1; break; + case bci_PUSH32: + debugBelch("PUSH32 %d\n", instrs[pc] ); + pc += 1; break; + case bci_PUSH8_W: + debugBelch("PUSH8_W %d\n", instrs[pc] ); + pc += 1; break; + case bci_PUSH16_W: + debugBelch("PUSH16_W %d\n", instrs[pc] ); + pc += 1; break; + case bci_PUSH32_W: + debugBelch("PUSH32_W %d\n", instrs[pc] ); + pc += 1; break; case bci_PUSH_G: debugBelch("PUSH_G " ); printPtr( ptrs[instrs[pc]] ); debugBelch("\n" ); pc += 1; break; - case bci_PUSH_ALTS: debugBelch("PUSH_ALTS " ); printPtr( ptrs[instrs[pc]] ); debugBelch("\n"); @@ -127,7 +148,33 @@ disInstr ( StgBCO *bco, int pc ) debugBelch("PUSH_ALTS_V " ); printPtr( ptrs[instrs[pc]] ); debugBelch("\n"); pc += 1; break; - + case bci_PUSH_PAD8: + debugBelch("PUSH_PAD8\n"); + pc += 1; break; + case bci_PUSH_PAD16: + debugBelch("PUSH_PAD16\n"); + pc += 1; break; + case bci_PUSH_PAD32: + debugBelch("PUSH_PAD32\n"); + pc += 1; break; + case bci_PUSH_UBX8: + debugBelch( + "PUSH_UBX8 0x%" FMT_Word8 " ", + (StgWord8) literals[instrs[pc]] ); + debugBelch("\n"); + pc += 1; break; + case bci_PUSH_UBX16: + debugBelch( + "PUSH_UBX16 0x%" FMT_Word16 " ", + (StgWord16) literals[instrs[pc]] ); + debugBelch("\n"); + pc += 1; break; + case bci_PUSH_UBX32: + debugBelch( + "PUSH_UBX32 0x%" FMT_Word32 " ", + (StgWord32) literals[instrs[pc]] ); + debugBelch("\n"); + pc += 1; break; case bci_PUSH_UBX: debugBelch("PUSH_UBX "); for (i = 0; i < instrs[pc+1]; i++) |