(untyped_call, blockage): New patterns.
From-SVN: r4169
This commit is contained in:
parent
bc3654906f
commit
e6f948e3de
@ -2341,6 +2341,43 @@
|
|||||||
"bsr $26,%1..ng"
|
"bsr $26,%1..ng"
|
||||||
[(set_attr "type" "ibr")])
|
[(set_attr "type" "ibr")])
|
||||||
|
|
||||||
|
;; Call subroutine returning any type.
|
||||||
|
|
||||||
|
(define_expand "untyped_call"
|
||||||
|
[(parallel [(call (match_operand 0 "" "")
|
||||||
|
(const_int 0))
|
||||||
|
(match_operand 1 "" "")
|
||||||
|
(match_operand 2 "" "")])]
|
||||||
|
""
|
||||||
|
"
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
emit_call_insn (gen_call (operands[0], const0_rtx, NULL, const0_rtx));
|
||||||
|
|
||||||
|
for (i = 0; i < XVECLEN (operands[2], 0); i++)
|
||||||
|
{
|
||||||
|
rtx set = XVECEXP (operands[2], 0, i);
|
||||||
|
emit_move_insn (SET_DEST (set), SET_SRC (set));
|
||||||
|
}
|
||||||
|
|
||||||
|
/* The optimizer does not know that the call sets the function value
|
||||||
|
registers we stored in the result block. We avoid problems by
|
||||||
|
claiming that all hard registers are used and clobbered at this
|
||||||
|
point. */
|
||||||
|
emit_insn (gen_blockage ());
|
||||||
|
|
||||||
|
DONE;
|
||||||
|
}")
|
||||||
|
|
||||||
|
;; UNSPEC_VOLATILE is considered to use and clobber all hard registers and
|
||||||
|
;; all of memory. This blocks insns from being moved across this point.
|
||||||
|
|
||||||
|
(define_insn "blockage"
|
||||||
|
[(unspec_volatile [(const_int 0)] 0)]
|
||||||
|
""
|
||||||
|
"")
|
||||||
|
|
||||||
(define_insn "jump"
|
(define_insn "jump"
|
||||||
[(set (pc)
|
[(set (pc)
|
||||||
(label_ref (match_operand 0 "" "")))]
|
(label_ref (match_operand 0 "" "")))]
|
||||||
|
@ -1767,6 +1767,43 @@
|
|||||||
"bali%# r15,%1"
|
"bali%# r15,%1"
|
||||||
[(set_attr "type" "call")])
|
[(set_attr "type" "call")])
|
||||||
|
|
||||||
|
;; Call subroutine returning any type.
|
||||||
|
|
||||||
|
(define_expand "untyped_call"
|
||||||
|
[(parallel [(call (match_operand 0 "" "")
|
||||||
|
(const_int 0))
|
||||||
|
(match_operand 1 "" "")
|
||||||
|
(match_operand 2 "" "")])]
|
||||||
|
""
|
||||||
|
"
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
emit_call_insn (gen_call (operands[0], const0_rtx, NULL, const0_rtx));
|
||||||
|
|
||||||
|
for (i = 0; i < XVECLEN (operands[2], 0); i++)
|
||||||
|
{
|
||||||
|
rtx set = XVECEXP (operands[2], 0, i);
|
||||||
|
emit_move_insn (SET_DEST (set), SET_SRC (set));
|
||||||
|
}
|
||||||
|
|
||||||
|
/* The optimizer does not know that the call sets the function value
|
||||||
|
registers we stored in the result block. We avoid problems by
|
||||||
|
claiming that all hard registers are used and clobbered at this
|
||||||
|
point. */
|
||||||
|
emit_insn (gen_blockage ());
|
||||||
|
|
||||||
|
DONE;
|
||||||
|
}")
|
||||||
|
|
||||||
|
;; UNSPEC_VOLATILE is considered to use and clobber all hard registers and
|
||||||
|
;; all of memory. This blocks insns from being moved across this point.
|
||||||
|
|
||||||
|
(define_insn "blockage"
|
||||||
|
[(unspec_volatile [(const_int 0)] 0)]
|
||||||
|
""
|
||||||
|
"")
|
||||||
|
|
||||||
;; No operation insn.
|
;; No operation insn.
|
||||||
(define_insn "nop"
|
(define_insn "nop"
|
||||||
[(const_int 0)]
|
[(const_int 0)]
|
||||||
|
@ -3055,6 +3055,43 @@
|
|||||||
"@
|
"@
|
||||||
brl\;l 2,20(1)
|
brl\;l 2,20(1)
|
||||||
bl %z1\;cror 15,15,15")
|
bl %z1\;cror 15,15,15")
|
||||||
|
|
||||||
|
;; Call subroutine returning any type.
|
||||||
|
|
||||||
|
(define_expand "untyped_call"
|
||||||
|
[(parallel [(call (match_operand 0 "" "")
|
||||||
|
(const_int 0))
|
||||||
|
(match_operand 1 "" "")
|
||||||
|
(match_operand 2 "" "")])]
|
||||||
|
""
|
||||||
|
"
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
emit_call_insn (gen_call (operands[0], const0_rtx, NULL, const0_rtx));
|
||||||
|
|
||||||
|
for (i = 0; i < XVECLEN (operands[2], 0); i++)
|
||||||
|
{
|
||||||
|
rtx set = XVECEXP (operands[2], 0, i);
|
||||||
|
emit_move_insn (SET_DEST (set), SET_SRC (set));
|
||||||
|
}
|
||||||
|
|
||||||
|
/* The optimizer does not know that the call sets the function value
|
||||||
|
registers we stored in the result block. We avoid problems by
|
||||||
|
claiming that all hard registers are used and clobbered at this
|
||||||
|
point. */
|
||||||
|
emit_insn (gen_blockage ());
|
||||||
|
|
||||||
|
DONE;
|
||||||
|
}")
|
||||||
|
|
||||||
|
;; UNSPEC_VOLATILE is considered to use and clobber all hard registers and
|
||||||
|
;; all of memory. This blocks insns from being moved across this point.
|
||||||
|
|
||||||
|
(define_insn "blockage"
|
||||||
|
[(unspec_volatile [(const_int 0)] 0)]
|
||||||
|
""
|
||||||
|
"")
|
||||||
|
|
||||||
;; Compare insns are next. Note that the RS/6000 has two types of compares,
|
;; Compare insns are next. Note that the RS/6000 has two types of compares,
|
||||||
;; signed & unsigned, and one type of branch.
|
;; signed & unsigned, and one type of branch.
|
||||||
|
Loading…
Reference in New Issue
Block a user