* i386.md (cvtts?2si peep2): New.
From-SVN: r64537
This commit is contained in:
parent
1e78888716
commit
8dfa3bb06e
@ -1,3 +1,7 @@
|
||||
Tue Mar 18 13:15:08 CET 2003 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
* i386.md (cvtts?2si peep2): New.
|
||||
|
||||
2003-03-18 Kazu Hirata <kazu@cs.umass.edu>
|
||||
|
||||
* config/h8300/h8300.md (*iorsi3_two_qi_zext): New.
|
||||
|
@ -4516,6 +4516,16 @@
|
||||
(set (match_dup 0) (fix:DI (match_dup 2)))]
|
||||
"")
|
||||
|
||||
;; Avoid vector decoded form of the instruction.
|
||||
(define_peephole2
|
||||
[(match_scratch:SF 2 "x")
|
||||
(set (match_operand:DI 0 "register_operand" "")
|
||||
(fix:DI (match_operand:SF 1 "memory_operand" "")))]
|
||||
"TARGET_K8 && !optimize_size"
|
||||
[(set (match_dup 2) (match_dup 1))
|
||||
(set (match_dup 0) (fix:DI (match_dup 2)))]
|
||||
"")
|
||||
|
||||
(define_insn "fix_truncdfdi_sse"
|
||||
[(set (match_operand:DI 0 "register_operand" "=r,r")
|
||||
(fix:DI (match_operand:DF 1 "nonimmediate_operand" "Y,Ym")))]
|
||||
@ -4534,6 +4544,16 @@
|
||||
(set (match_dup 0) (fix:DI (match_dup 2)))]
|
||||
"")
|
||||
|
||||
;; Avoid vector decoded form of the instruction.
|
||||
(define_peephole2
|
||||
[(match_scratch:DF 2 "Y")
|
||||
(set (match_operand:DI 0 "register_operand" "")
|
||||
(fix:DI (match_operand:DF 1 "memory_operand" "")))]
|
||||
"TARGET_K8 && !optimize_size"
|
||||
[(set (match_dup 2) (match_dup 1))
|
||||
(set (match_dup 0) (fix:DI (match_dup 2)))]
|
||||
"")
|
||||
|
||||
;; Signed conversion to SImode.
|
||||
|
||||
(define_expand "fix_truncxfsi2"
|
||||
@ -4647,6 +4667,16 @@
|
||||
(set (match_dup 0) (fix:SI (match_dup 2)))]
|
||||
"")
|
||||
|
||||
;; Avoid vector decoded form of the instruction.
|
||||
(define_peephole2
|
||||
[(match_scratch:SF 2 "x")
|
||||
(set (match_operand:SI 0 "register_operand" "")
|
||||
(fix:SI (match_operand:SF 1 "memory_operand" "")))]
|
||||
"TARGET_K8 && !optimize_size"
|
||||
[(set (match_dup 2) (match_dup 1))
|
||||
(set (match_dup 0) (fix:SI (match_dup 2)))]
|
||||
"")
|
||||
|
||||
(define_insn "fix_truncdfsi_sse"
|
||||
[(set (match_operand:SI 0 "register_operand" "=r,r")
|
||||
(fix:SI (match_operand:DF 1 "nonimmediate_operand" "Y,Ym")))]
|
||||
@ -4655,6 +4685,16 @@
|
||||
[(set_attr "type" "sseicvt")
|
||||
(set_attr "athlon_decode" "double,vector")])
|
||||
|
||||
;; Avoid vector decoded form of the instruction.
|
||||
(define_peephole2
|
||||
[(match_scratch:DF 2 "Y")
|
||||
(set (match_operand:SI 0 "register_operand" "")
|
||||
(fix:SI (match_operand:DF 1 "memory_operand" "")))]
|
||||
"TARGET_K8 && !optimize_size"
|
||||
[(set (match_dup 2) (match_dup 1))
|
||||
(set (match_dup 0) (fix:SI (match_dup 2)))]
|
||||
"")
|
||||
|
||||
;; Avoid vector decoded form of the instruction.
|
||||
(define_peephole2
|
||||
[(match_scratch:DF 2 "Y")
|
||||
|
@ -1,3 +1,7 @@
|
||||
Tue Mar 18 13:14:05 CET 2003 Jan Hubicka <jh@suse.cz>
|
||||
|
||||
* gcc.dg/i386-cvt-1.c: New test.
|
||||
|
||||
2003-03-17 Zack Weinberg <zack@codesourcery.com>
|
||||
|
||||
* objc.dg/naming-1.m: Use "(parse|syntax) error".
|
||||
|
12
gcc/testsuite/gcc.dg/i386-cvt-1.c
Normal file
12
gcc/testsuite/gcc.dg/i386-cvt-1.c
Normal file
@ -0,0 +1,12 @@
|
||||
/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
|
||||
/* { dg-options "-O2 -march=k8 -mfpmath=sse" } */
|
||||
/* { dg-final { scan-assembler "cvttsd2si.*xmm" } } */
|
||||
/* { dg-final { scan-assembler "cvttss2si.*xmm" } } */
|
||||
int a,a1;
|
||||
double b;
|
||||
float b1;
|
||||
t()
|
||||
{
|
||||
a=b;
|
||||
a1=b1;
|
||||
}
|
Loading…
Reference in New Issue
Block a user