mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-23 00:51:00 +08:00
re PR target/23268 (ICE using math functions log & rint, -ffast-math, -O1 (,2,3,s))
PR target/23268 * config/i386/i386.md ("*fist<mode>2_1"): New pattern. ("lrint<mode>2"): Change expander to use "*fist<mode>2_1" pattern. From-SVN: r103224
This commit is contained in:
parent
c26104e494
commit
87bb8864f6
@ -1,3 +1,9 @@
|
||||
2005-08-17 Uros Bizjak <uros@kss-loka.si>
|
||||
|
||||
PR target/23268
|
||||
* config/i386/i386.md ("*fist<mode>2_1"): New pattern.
|
||||
("lrint<mode>2"): Change expander to use "*fist<mode>2_1" pattern.
|
||||
|
||||
2005-08-17 J"orn Rennecke <joern.rennecke@st.com>
|
||||
|
||||
* varasm.c (decode_reg_name): Skip empty aqdditional register names.
|
||||
|
@ -16477,6 +16477,30 @@
|
||||
DONE;
|
||||
})
|
||||
|
||||
(define_insn_and_split "*fist<mode>2_1"
|
||||
[(set (match_operand:X87MODEI 0 "nonimmediate_operand" "=m,?r")
|
||||
(unspec:X87MODEI [(match_operand:XF 1 "register_operand" "f,f")]
|
||||
UNSPEC_FIST))]
|
||||
"TARGET_USE_FANCY_MATH_387
|
||||
&& flag_unsafe_math_optimizations
|
||||
&& !(reload_completed || reload_in_progress)"
|
||||
"#"
|
||||
"&& 1"
|
||||
[(const_int 0)]
|
||||
{
|
||||
if (memory_operand (operands[0], VOIDmode))
|
||||
emit_insn (gen_fist<mode>2 (operands[0], operands[1]));
|
||||
else
|
||||
{
|
||||
operands[2] = assign_386_stack_local (<MODE>mode, SLOT_TEMP);
|
||||
emit_insn (gen_fist<mode>2_with_temp (operands[0], operands[1],
|
||||
operands[2]));
|
||||
}
|
||||
DONE;
|
||||
}
|
||||
[(set_attr "type" "fpspc")
|
||||
(set_attr "mode" "<MODE>")])
|
||||
|
||||
(define_insn "fistdi2"
|
||||
[(set (match_operand:DI 0 "memory_operand" "=m")
|
||||
(unspec:DI [(match_operand:XF 1 "register_operand" "f")]
|
||||
@ -16566,22 +16590,13 @@
|
||||
"")
|
||||
|
||||
(define_expand "lrint<mode>2"
|
||||
[(use (match_operand:X87MODEI 0 "nonimmediate_operand" ""))
|
||||
(use (match_operand:XF 1 "register_operand" ""))]
|
||||
[(set (match_operand:X87MODEI 0 "nonimmediate_operand" "")
|
||||
(unspec:X87MODEI [(match_operand:XF 1 "register_operand" "")]
|
||||
UNSPEC_FIST))]
|
||||
"TARGET_USE_FANCY_MATH_387
|
||||
&& (!TARGET_SSE_MATH || TARGET_MIX_SSE_I387)
|
||||
&& flag_unsafe_math_optimizations"
|
||||
{
|
||||
if (memory_operand (operands[0], VOIDmode))
|
||||
emit_insn (gen_fist<mode>2 (operands[0], operands[1]));
|
||||
else
|
||||
{
|
||||
rtx op = assign_386_stack_local (<MODE>mode, SLOT_TEMP);
|
||||
emit_insn (gen_fist<mode>2_with_temp (operands[0], operands[1],
|
||||
op));
|
||||
}
|
||||
DONE;
|
||||
})
|
||||
"")
|
||||
|
||||
;; Rounding mode control word calculation could clobber FLAGS_REG.
|
||||
(define_insn_and_split "frndintxf2_floor"
|
||||
|
Loading…
x
Reference in New Issue
Block a user