re PR target/28806 (lround is not expanded inline to SSE conversion sequence)
authorRichard Guenther <rguenther@suse.de>
Sat, 28 Oct 2006 11:30:41 +0000 (11:30 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Sat, 28 Oct 2006 11:30:41 +0000 (11:30 +0000)
commit4d81bf84358f0f905b606a5cb27777e614d213e1
tree984f65a3da9766999d6ccf8748f98e89fbad2338
parent6f16dafb641b6c935c94f87c8ceaac9458dadc72
re PR target/28806 (lround is not expanded inline to SSE conversion sequence)

2006-10-28  Richard Guenther  <rguenther@suse.de>

PR target/28806
* builtins.c (expand_builtin_int_roundingfn_2): Expand
BUILT_IN_LROUND and BUILT_IN_LLROUND from here.
(expand_builtin): Adjust likewise.
* genopinit.c (optabs[]): Add lround optab.
* optabs.c (init_optabs): Initialize lround_optab.
* optabs.h (enum convert_optab_index): Add COI_lround.
(lround_optab): Define.
* config/i386/i386-protos.h (ix86_expand_lround): Declare.
* config/i386/i386.c (ix86_sse_copysign_to_positive): New
static function.
(ix86_expand_lround): New function.
* config/i386/i386.md (lround<mode>di2, lround<mode>si2):
New expanders.
* doc/md.texi (lroundMN2): Document.

* gcc.target/i386/math-torture/lround.c: New testcase.

From-SVN: r118105
gcc/ChangeLog
gcc/builtins.c
gcc/config/i386/i386-protos.h
gcc/config/i386/i386.c
gcc/config/i386/i386.md
gcc/doc/md.texi
gcc/genopinit.c
gcc/optabs.c
gcc/optabs.h
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/i386/math-torture/lround.c [new file with mode: 0644]