Commit d68f4cc4 by Chris Demetriou Committed by Chris Demetriou

mips.md: Adjust SI-mode "trap_if" instruction to use better predicates and constraints.

2003-08-19  Chris Demetriou  <cgd@broadcom.com>

        * config/mips/mips.md: Adjust SI-mode "trap_if" instruction
        to use better predicates and constraints.  Define new
        instruction to handle "trap_if" with DI-mode arguments.
        (conditional_trap): FAIL if trap code is not 0.

From-SVN: r70570
parent 86ecdfb6
2003-08-19 Chris Demetriou <cgd@broadcom.com>
* config/mips/mips.md: Adjust SI-mode "trap_if" instruction
to use better predicates and constraints. Define new
instruction to handle "trap_if" with DI-mode arguments.
(conditional_trap): FAIL if trap code is not 0.
2003-08-19 Andrew Pinski <pinskia@physics.uc.edu> 2003-08-19 Andrew Pinski <pinskia@physics.uc.edu>
* config/i386/i386.c (legitimate_pic_address_disp_p): Change the * config/i386/i386.c (legitimate_pic_address_disp_p): Change the
......
...@@ -640,17 +640,30 @@ ...@@ -640,17 +640,30 @@
(match_operand 1 "const_int_operand" ""))] (match_operand 1 "const_int_operand" ""))]
"ISA_HAS_COND_TRAP" "ISA_HAS_COND_TRAP"
{ {
mips_gen_conditional_trap (operands); if (operands[1] == const0_rtx)
DONE; {
mips_gen_conditional_trap (operands);
DONE;
}
else
FAIL;
}) })
(define_insn "" (define_insn ""
[(trap_if (match_operator 0 "trap_cmp_op" [(trap_if (match_operator 0 "trap_cmp_op"
[(match_operand:SI 1 "reg_or_0_operand" "d") [(match_operand:SI 1 "reg_or_0_operand" "dJ")
(match_operand:SI 2 "nonmemory_operand" "dI")]) (match_operand:SI 2 "arith_operand" "dI")])
(const_int 0))] (const_int 0))]
"ISA_HAS_COND_TRAP" "ISA_HAS_COND_TRAP"
"t%C0\t%z1,%z2") "t%C0\t%z1,%z2")
(define_insn ""
[(trap_if (match_operator 0 "trap_cmp_op"
[(match_operand:DI 1 "reg_or_0_operand" "dJ")
(match_operand:DI 2 "arith_operand" "dI")])
(const_int 0))]
"TARGET_64BIT && ISA_HAS_COND_TRAP"
"t%C0\t%z1,%z2")
;; ;;
;; .................... ;; ....................
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment