Guest User

Untitled

a guest
May 27th, 2018
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. else if (t.matches("test expr EQ expr")) //a10p1
  2. {
  3. return genCode(t.children.get(0))+
  4. "sw $3, -4($30)\n" +
  5. "lis $3\n" + ".word -4\n" + "add $30, $3, $30\n" +
  6. genCode(t.children.get(2)) +
  7. "lis $6\n" + ".word 4\n" + "add $30, $6, $30\n" +
  8. "lw $6, -4($30)\n" +
  9. "lis $7\n" +
  10. ".word 0\n" +
  11. "bne $6, $3, 2\n" +
  12. "lis $7\n" +
  13. ".word 1\n";
  14. }
Add Comment
Please, Sign In to add comment