https://bugs.kde.org/show_bug.cgi?id=417187

--- Comment #6 from Julian Seward <jsew...@acm.org> ---
(In reply to Stefan Maksimovic from comment #4)
> Created attachment 125693 [details]
> test program log with grail changes

Thank you for the attachments.  Let me see if I understand what you are
saying. In this log file, for SB #4, the front end logic analysed three
sequences:

  0x4013BC: 0x8C43FFFC  lw r3, 65532(r2)
  0x4013C0: 0x1460FFFE  bne r3, r0, 65534
  0x4013C4: 0x24420004  addiu r2, r2, 4

This is OK.  This is what you could call the "initial" sequence for the SB.
As I see it, it correctly contains the terminating branch (the bne) and the
delay slot (addiu).  Yes?

Next we have

  0x4013BC: 0x8C43FFFC  lw r3, 65532(r2)
  0x4013C0: 0x1460FFFE  bne r3, r0, 65534
  0x4013C4: 0x24420004  addiu r2, r2, 4

That's pretty strange, because it's a repeat of the entry block, but maybe
it's because the insn at 0x4013C0 branches back to the start of the block
(0x4013BC) (so this is a word-search loop?)

In this case, this is a speculative ("SPEC") disassembly.  Both the branch
and delay slot are analysed, but that is just luck -- in that the delay slot
just happens to fall within the 3-instruction limit.

So anyway, ignoring that, we have, finally, a second speculative disassembly:

  0x4013C8: 0x2442FFFC  addiu r2, r2, 65532
  0x4013CC: 0x8F9981B0  lw r25, 33200(r28)
  0x4013D0: 0x0320F809  jalr r31 r25

This is obviously wrong, because the delay slot (which would be at 0x4013D4)
is missing.

Do I understand all that correctly?

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to