public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug rtl-optimization/67609] [5/6 Regression] Generates wrong code for SSE2 _mm_load_pd
Date: Fri, 23 Oct 2015 08:30:00 -0000	[thread overview]
Message-ID: <bug-67609-4-mSyjx7LHps@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-67609-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67609

--- Comment #26 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Richard Henderson from comment #22)
> (In reply to Jeffrey A. Law from comment #21)
> > So going back to the original problem, for a subreg of a multi-word reg, 
> > why can't we simplify that down to a suitably sized reg?
> 
> Because we're dealing with registers of different sizes.
> 
> Assigning to a subreg as the low-part of a multi-word pseudo only
> makes sense when talking about general registers, which is the only
> place that "word_mode" applies.

Hmm, I don't see this documented anywhere.  In fact there is no such
thing as a "vector register", there are only vector modes.  And we
are using %xmm for plain SF/DFmode all over the place.

Note that in the particular case the mode we subreg is TImode,
not a vector mode.

> When talking about vector registers, which are universally larger
> than word-mode, we cannot simply assign to a subreg.
> 
> There is a vec_set named pattern that can perform an insertion into
> a vector element, like what's being demonstrated in the test source
> here.  Ideally that's how we'd have expanded this originally.

Indeed, if expand can see we are setting the low part of a vector
then it should try using vec_set.  Auditing of other targets might
be necessary here though.  And of course the i386 backend might
end up choosing movdf for this operation anyway...

> We already have ix86_cannot_change_mode_class to avoid the cases
> that we knew we couldn't support, e.g. QI and HImode loads/stores.
> But perhaps we should prevent all size-changing mode changes for
> the vector registers.

That may be a workaround for x86 but I don't see how this fixes the
issue in general given that targets may have general registers larger
than word_mode (is x32 TARGET_64BIT?).


  parent reply	other threads:[~2015-10-23  8:30 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-17 11:37 [Bug regression/67609] New: [Regression] " bisqwit at iki dot fi
2015-09-17 12:51 ` [Bug target/67609] [5/6 Regression] " rguenth at gcc dot gnu.org
2015-09-17 13:13 ` ubizjak at gmail dot com
2015-09-17 13:48 ` rguenth at gcc dot gnu.org
2015-09-17 18:09 ` [Bug regression/67609] " bisqwit at iki dot fi
2015-09-17 19:03 ` [Bug rtl-optimization/67609] " ubizjak at gmail dot com
2015-10-16 12:44 ` vmakarov at gcc dot gnu.org
2015-10-16 12:50 ` vmakarov at gcc dot gnu.org
2015-10-20 16:26 ` vmakarov at gcc dot gnu.org
2015-10-20 16:32 ` vmakarov at gcc dot gnu.org
2015-10-20 19:12 ` ubizjak at gmail dot com
2015-10-21  7:52 ` ubizjak at gmail dot com
2015-10-21 16:30 ` vmakarov at gcc dot gnu.org
2015-10-21 17:34 ` ubizjak at gmail dot com
2015-10-21 18:16 ` law at redhat dot com
2015-10-21 18:42 ` vmakarov at gcc dot gnu.org
2015-10-22  8:23 ` rguenth at gcc dot gnu.org
2015-10-22 12:49 ` law at redhat dot com
2015-10-22 13:40 ` rguenth at gcc dot gnu.org
2015-10-22 19:34 ` law at redhat dot com
2015-10-22 21:55 ` rth at gcc dot gnu.org
2015-10-22 22:54 ` rth at gcc dot gnu.org
2015-10-23  1:58 ` vmakarov at gcc dot gnu.org
2015-10-23  5:02 ` vmakarov at gcc dot gnu.org
2015-10-23  8:30 ` rguenth at gcc dot gnu.org [this message]
2015-10-23 13:14 ` vmakarov at gcc dot gnu.org
2015-10-23 19:06 ` rth at gcc dot gnu.org
2015-10-26 19:18 ` rth at gcc dot gnu.org
2015-10-26 21:48 ` vmakarov at gcc dot gnu.org
2015-10-27 10:18 ` rguenth at gcc dot gnu.org
2015-10-27 20:00 ` rth at gcc dot gnu.org
2015-10-29 18:37 ` rth at gcc dot gnu.org
2015-10-29 18:45 ` [Bug rtl-optimization/67609] [5 " rth 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-67609-4-mSyjx7LHps@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).