* [PATCH, i386]: Fix mode of forced register in vec_dupv4sf
@ 2011-06-11 12:41 Uros Bizjak
2011-06-11 17:45 ` H.J. Lu
0 siblings, 1 reply; 2+ messages in thread
From: Uros Bizjak @ 2011-06-11 12:41 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: text/plain, Size: 316 bytes --]
Hello!
2011-06-11 Uros Bizjak <ubizjak@gmail.com>
* config/i386/sse.md (vec_dupv4sf): Correct mode of forced register.
(*vec_dupv2df): Rename from vec_dupv2df.
(vec_dupv2df): New expander.
Tested on x86_64-pc-linux-gnu {,-m32}. Committed to mainline SVN, will
also be committed to 4.5 and 4.6 branch.
Uros.
[-- Attachment #2: d.diff.txt --]
[-- Type: text/plain, Size: 1116 bytes --]
Index: sse.md
===================================================================
--- sse.md (revision 174946)
+++ sse.md (working copy)
@@ -3816,7 +3816,7 @@
"TARGET_SSE"
{
if (!TARGET_AVX)
- operands[1] = force_reg (V4SFmode, operands[1]);
+ operands[1] = force_reg (SFmode, operands[1]);
})
(define_insn "*vec_dupv4sf_avx"
@@ -5117,6 +5117,16 @@
(set_attr "length_immediate" "*,*,*,1,*,*")
(set_attr "mode" "DF,V1DF,V1DF,V2DF,V1DF,V1DF")])
+(define_expand "vec_dupv4sf"
+ [(set (match_operand:V2DF 0 "register_operand" "")
+ (vec_duplicate:V2DF
+ (match_operand:DF 1 "nonimmediate_operand" "")))]
+ "TARGET_SSE2"
+{
+ if (!TARGET_SSE3)
+ operands[1] = force_reg (DFmode, operands[1]);
+})
+
(define_insn "*vec_dupv2df_sse3"
[(set (match_operand:V2DF 0 "register_operand" "=x")
(vec_duplicate:V2DF
@@ -5127,7 +5137,7 @@
(set_attr "prefix" "maybe_vex")
(set_attr "mode" "DF")])
-(define_insn "vec_dupv2df"
+(define_insn "*vec_dupv2df"
[(set (match_operand:V2DF 0 "register_operand" "=x")
(vec_duplicate:V2DF
(match_operand:DF 1 "register_operand" "0")))]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH, i386]: Fix mode of forced register in vec_dupv4sf
2011-06-11 12:41 [PATCH, i386]: Fix mode of forced register in vec_dupv4sf Uros Bizjak
@ 2011-06-11 17:45 ` H.J. Lu
0 siblings, 0 replies; 2+ messages in thread
From: H.J. Lu @ 2011-06-11 17:45 UTC (permalink / raw)
To: Uros Bizjak; +Cc: gcc-patches
On Sat, Jun 11, 2011 at 4:16 AM, Uros Bizjak <ubizjak@gmail.com> wrote:
> Hello!
>
> 2011-06-11 Uros Bizjak <ubizjak@gmail.com>
>
> * config/i386/sse.md (vec_dupv4sf): Correct mode of forced register.
> (*vec_dupv2df): Rename from vec_dupv2df.
> (vec_dupv2df): New expander.
>
> Tested on x86_64-pc-linux-gnu {,-m32}. Committed to mainline SVN, will
> also be committed to 4.5 and 4.6 branch.
>
This may have caused:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49374
--
H.J.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-06-11 16:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-06-11 12:41 [PATCH, i386]: Fix mode of forced register in vec_dupv4sf Uros Bizjak
2011-06-11 17:45 ` H.J. Lu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).