public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "kretz at kde dot org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/49133] [4.6/4.7 Regression] modification of aliased __m128d miscompiles
Date: Tue, 24 May 2011 10:36:00 -0000	[thread overview]
Message-ID: <bug-49133-4-GGv4OEhCgt@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-49133-4@http.gcc.gnu.org/bugzilla/>

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49133

--- Comment #2 from Matthias Kretz <kretz at kde dot org> 2011-05-24 10:16:41 UTC ---
I applied the patch to the latest 4.6 snapshot. I confirm that it fixes the
bug. Also, there are no regressions in my testsuite.

Just for confirmation, the patched sse.md looks like this for me now (starting
from line 4952):
(define_insn "sse2_loadhpd"
  [(set (match_operand:V2DF 0 "nonimmediate_operand"     "=x,x,x,o,o,o")
    (vec_concat:V2DF
      (vec_select:DF
        (match_operand:V2DF 1 "nonimmediate_operand" " 0,0,x,0,0,0")
        (parallel [(const_int 0)]))
      (match_operand:DF 2 "nonimmediate_operand"     " m,x,0,x,*f,r")))]
  "TARGET_SSE2 && !(MEM_P (operands[1]) && MEM_P (operands[2]))"
  "@
   movhpd\t{%2, %0|%0, %2}
   unpcklpd\t{%2, %0|%0, %2}
   shufpd\t{$0, %1, %0|%0, %1, 0}
   #

Question, why not use unpcklpd instead of shufpd $0? On older CPUs unpcklpd
should be slightly faster than shufpd.


  parent reply	other threads:[~2011-05-24 10:33 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-23 22:20 [Bug target/49133] New: [4.6 " kretz at kde dot org
2011-05-24  8:54 ` [Bug target/49133] [4.6/4.7 " ubizjak at gmail dot com
2011-05-24 10:36 ` kretz at kde dot org [this message]
2011-05-24 11:48 ` ubizjak at gmail dot com
2011-05-24 11:54 ` ubizjak at gmail dot com
2011-05-24 15:58 ` uros at gcc dot gnu.org
2011-05-24 18:58 ` uros at gcc dot gnu.org
2011-05-25  8:15 ` jakub at gcc dot gnu.org
2011-05-25 13:47 ` uros at gcc dot gnu.org
2011-05-25 16:43 ` uros at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-49133-4-GGv4OEhCgt@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).