From: Jeff Law <jeffreyalaw@gmail.com>
To: Richard Biener <richard.guenther@gmail.com>
Cc: Roger Sayle <roger@nextmovesoftware.com>,
GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] Don't call emit_clobber in lower-subreg.cc's resolve_simple_move.
Date: Mon, 8 May 2023 16:02:57 -0600 [thread overview]
Message-ID: <21650fa7-e181-f87d-1f6e-0127b2291556@gmail.com> (raw)
In-Reply-To: <CAFiYyc212qQJDBd9T-2nihX1HP6RZkVj0K6tMns0k0s7WWaM1Q@mail.gmail.com>
On 5/8/23 00:43, Richard Biener wrote:
> On Sat, May 6, 2023 at 8:46 PM Jeff Law via Gcc-patches
> <gcc-patches@gcc.gnu.org> wrote:
>>
>>
>>
>> On 5/6/23 06:57, Roger Sayle wrote:
>>>
>>> Following up on posts/reviews by Segher and Uros, there's some question
>>> over why the middle-end's lower subreg pass emits a clobber (of a
>>> multi-word register) into the instruction stream before emitting the
>>> sequence of moves of the word-sized parts. This clobber interferes
>>> with (LRA) register allocation, preventing the multi-word pseudo to
>>> remain in the same hard registers. This patch eliminates this
>>> (presumably superfluous) clobber and thereby improves register allocation.
>> Those clobbered used to help dataflow analysis know that a multi word
>> register was fully assigned by a subsequent sequence. I suspect they
>> haven't been terribly useful in quite a while.
>
> Likely - maybe they still make a difference for some targets though.
> It might be interesting to see whether combining the clobber with the
> first set or making the set a multi-set with a parallel would be any
> better?
Wrapping them inside a PARALLEL might be better, but probably isn't
worth the effort. I think all this stuff dates back to the era where we
had flow.c to provide the register lifetimes used by local-alloc. We
also had things like REG_NO_CONFLICT to indicate that the sub-object
assignments didn't conflict. In all it was rather hackish.
Jeff
prev parent reply other threads:[~2023-05-08 22:03 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-06 12:57 Roger Sayle
2023-05-06 18:46 ` Jeff Law
2023-05-08 6:43 ` Richard Biener
2023-05-08 22:02 ` Jeff Law [this message]
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=21650fa7-e181-f87d-1f6e-0127b2291556@gmail.com \
--to=jeffreyalaw@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=richard.guenther@gmail.com \
--cc=roger@nextmovesoftware.com \
/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).