Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

uni normalize removes NOP delay slots generated from .asm.mir file #49

Open
romits800 opened this issue Mar 5, 2020 · 1 comment
Open

Comments

@romits800
Copy link
Contributor

When running uni normalize for Mips the delay slots two of the delay slots (NOPs) in .asm.mir file do not appear in the .llvm.mir file:

uni normalize --target=Mips sphinx3.glist.glist_tail.asm.mir -o sphinx3.glist.glist_tail.llvm.mir
cat sphinx3.glist.glist_tail.asm.mir
body:             |
  bb.0 (%ir-block.0, freq 8):
    successors: %bb.2..loopexit(37), %bb.1..preheader(62)
    liveins: %a0
  
    BEQ %a0, %zero, %bb.2..loopexit, implicit-def dead %at {
      %v0 = ADDiu %zero, 0
    }
  
  bb.1..preheader (freq 159):
    successors: %bb.2..loopexit(3), %bb.1..preheader(96)
    liveins: %a0
  
    %v0 = OR killed %a0, %zero
    %a0 = LW %v0, 8 :: (load 4 from %ir.2, align 8)
    BNE %a0, %zero, %bb.1..preheader, implicit-def %at {
      NOP
    }
  
  bb.2..loopexit (freq 8):
    liveins: %v0
    liveouts:
  
    PseudoReturn %ra {
      NOP
    }

...

and

cat sphinx3.glist.glist_tail.llvm.mir
name:            glist_tail
body:             |
  bb.0 (freq 8):
    successors: %bb.2(1), %bb.1(2)
  
    BEQ %a0, %zero, %bb.2, implicit %at, implicit-def %at {
      %v0 = ADDiu %zero, 0
    }
  
  bb.1 (freq 159):
    successors: %bb.1(1), %bb.2(2)
  
    %v0 = OR %a0, %zero
    %a0 = LW %v0, 8
    BNE %a0, %zero, %bb.1, implicit %at, implicit-def %at
  
  bb.2 (freq 8):
  
    PseudoReturn %ra

...
@romits800
Copy link
Contributor Author

@romits800 romits800 changed the title Removed NOP delay slots generated from .asm.mir file uni normalize removes NOP delay slots generated from .asm.mir file Mar 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant