public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Segher Boessenkool <segher@kernel.crashing.org>
To: Jiufu Guo <guojiufu@linux.ibm.com>
Cc: gcc-patches@gcc.gnu.org, wschmidt@linux.ibm.com
Subject: Re: [PATCH, rs6000]: mark clobber for registers changed by untpyed_call
Date: Fri, 14 Feb 2020 18:12:00 -0000	[thread overview]
Message-ID: <20200214181221.GL22482@gate.crashing.org> (raw)
In-Reply-To: <h48blq1ac46.fsf@genoa.aus.stglabs.ibm.com>

On Fri, Feb 14, 2020 at 02:58:49PM +0800, Jiufu Guo wrote:
> Segher Boessenkool <segher@kernel.crashing.org> writes:
> 
> > On Sat, Feb 08, 2020 at 10:17:42AM -0600, Segher Boessenkool wrote:
> >> And we do not know which of the register will be used for the return, in
> >> untyped_call (only untyped-return knows).  But we can add clobbers of all
> >> registers that *might* be used for the return, we do know that here, see
> >> operands[2] of untyped_call.
> >
> > Clobbers in parallel to the call, I mean, not as separate insns later.
> >
> Thanks Segher, as discussed, we may refine the patch by adding a
> 'barrier' to avoid instructions mis-scheduled.  This improvement patch
> maybe fine for practice.
> 
> Below is the updated patch: bootstrap and regtest pass on powerpc64le.
> Is this ok to submit to trunk?

This is okay for trunk, and for backports after a week or so.  Thanks!

(It doesn't fully solve the problem, as we discussed; because the return
registers are not seen (by df, etc.) as live immediately after the call,
new instructions using those registers can be created between the call
and the later clobber.  The barrier does nothing to prevent that.)

Don't forget to do a changelog entry, mentioning the PR as well :-)


Segher

      reply	other threads:[~2020-02-14 18:12 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-05 13:53 Jiufu Guo
2020-02-05 19:25 ` Segher Boessenkool
2020-02-06  2:49   ` Jiufu Guo
2020-02-06 15:35     ` Segher Boessenkool
2020-02-07  7:10       ` Jiufu Guo
2020-02-08 16:17         ` Segher Boessenkool
2020-02-08 21:45           ` Segher Boessenkool
2020-02-14  6:58             ` Jiufu Guo
2020-02-14 18:12               ` Segher Boessenkool [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=20200214181221.GL22482@gate.crashing.org \
    --to=segher@kernel.crashing.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=guojiufu@linux.ibm.com \
    --cc=wschmidt@linux.ibm.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).