public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: "Marcin Kościelnicki" <koriakin@0x04.net>
To: Andreas Krebbel <krebbel@linux.vnet.ibm.com>,
	Jeff Law <law@redhat.com>,
	gcc-patches@gcc.gnu.org
Subject: Re: [PATCH 4/5] Don't mark targets of unconditional jumps with side effects as FALLTHRU.
Date: Fri, 22 Jan 2016 16:39:00 -0000	[thread overview]
Message-ID: <56A25B31.9090403@0x04.net> (raw)
In-Reply-To: <56A1DDCB.5020200@linux.vnet.ibm.com>

On 22/01/16 08:44, Andreas Krebbel wrote:
> On 01/22/2016 12:10 AM, Jeff Law wrote:
>> On 01/21/2016 03:05 AM, Andreas Krebbel wrote:
>>> On 01/02/2016 08:16 PM, Marcin Kościelnicki wrote:
>>>> When an unconditional jump with side effects targets an immediately
>>>> following label, rtl_tidy_fallthru_edge is called.  Since it has side
>>>> effects, it doesn't remove the jump, but the label is still marked
>>>> as fallthru.  This later causes a verification error.  Do nothing in this
>>>> case instead.
>>>>
>>>> gcc/ChangeLog:
>>>>
>>>> 	* cfgrtl.c (rtl_tidy_fallthru_edge): Bail for unconditional jumps
>>>> 	with side effects.
>>>
>>> The change looks ok to me (although I'm not able to approve it). Could you please run regressions
>>> tests on x86_64 with that change?
>>>
>>> Perhaps a short comment in the code would be good.
>> I think the patch is technically fine, the question is does it fix a
>> visible bug?  I read the series as new feature enablement so I put this
>> patch into my gcc7 queue.
>
> We need the patch for the S/390 split-stack implementation which we would like to see in GCC 6.  I'm
> aware that this isn't stage 3 material but people seem to have reasons to really want split stack on
> S/390 asap and we would have to backport this feature anyway. Therefore I would prefer to have it in
> the official release already. That's the only common code change we would need for that.
>
> I've started a bootstrap and regression test for the patch also on Power.
>
> Do you see a chance we can get this into GCC 6?
>
> Bye,
>
> -Andreas-
>

I've tested the patch on x86_64, no regressions.

I'm not entirely sure if the patch needs to go in for the current 
version of split-stack support.

This patch fixed a showstopper bug on g5 CPUs when the patch still 
supported them.  I haven't seen this bug with the z900 sequences (which 
are now the only ones left), but since we're still using unconditional 
jumps with side effects, I left it in just to be safe.  The testsuite 
passes on s390x -fsplit-stack both with the patch and without it.

So, I don't know.  It seems to work now, probably because no 
optimization pass has a reason to touch that jump, but it may start to 
fail if someone adds a new optimization that tries to be smart with our 
prologue.

  reply	other threads:[~2016-01-22 16:39 UTC|newest]

Thread overview: 55+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-02 19:16 [RFC] [PR 68191] s390: Add -fsplit-stack support Marcin Kościelnicki
2016-01-02 19:16 ` [PATCH 2/5] s390: Fix missing .size directives Marcin Kościelnicki
2016-01-20 13:16   ` Andreas Krebbel
2016-01-20 14:01     ` Dominik Vogt
2016-01-21  9:59     ` Andreas Krebbel
2016-01-21 10:10       ` Marcin Kościelnicki
2016-01-02 19:16 ` [PATCH 4/5] Don't mark targets of unconditional jumps with side effects as FALLTHRU Marcin Kościelnicki
2016-01-21 10:05   ` Andreas Krebbel
2016-01-21 10:10     ` Marcin Kościelnicki
2016-01-21 23:10     ` Jeff Law
2016-01-22  7:44       ` Andreas Krebbel
2016-01-22 16:39         ` Marcin Kościelnicki [this message]
2016-01-27  7:11         ` Jeff Law
2016-04-17 21:24   ` Jeff Law
2016-01-02 19:16 ` [PATCH 3/5] Fix NOTE_INSN_PROLOGUE_END after unconditional jump Marcin Kościelnicki
2016-04-17 21:25   ` Jeff Law
2016-01-02 19:17 ` [PATCH 5/5] s390: Add -fsplit-stack support Marcin Kościelnicki
2016-01-15 18:39   ` Andreas Krebbel
2016-01-15 21:08     ` Marcin Kościelnicki
2016-01-21 10:12       ` Andreas Krebbel
2016-01-21 13:04         ` Marcin Kościelnicki
2016-01-16 13:46     ` [PATCH] " Marcin Kościelnicki
2016-01-29 13:33       ` Andreas Krebbel
2016-01-29 15:43         ` Marcin Kościelnicki
2016-01-29 16:17           ` Andreas Krebbel
2016-02-02 14:52             ` Marcin Kościelnicki
2016-02-02 15:19               ` Andreas Krebbel
2016-02-02 15:31                 ` Marcin Kościelnicki
2016-02-02 18:34                   ` Ulrich Weigand
2016-02-02 20:11                     ` Marcin Kościelnicki
2016-02-03 18:40                       ` Marcin Kościelnicki
2016-02-04 15:06                         ` Ulrich Weigand
2016-02-04 15:20                           ` Marcin Kościelnicki
2016-02-04 16:27                             ` Ulrich Weigand
2016-02-05 21:13                               ` Marcin Kościelnicki
2016-02-05 22:02                                 ` Ulrich Weigand
2016-02-03  0:20                     ` Marcin Kościelnicki
2016-02-03 17:03                       ` Ulrich Weigand
2016-02-03 17:18                         ` Marcin Kościelnicki
2016-02-03 17:27                           ` Ulrich Weigand
2016-02-04 12:44                             ` Marcin Kościelnicki
2016-02-10 13:14                               ` Marcin Kościelnicki
2016-02-14 16:01                                 ` Marcin Kościelnicki
2016-02-15 10:21                                   ` Andreas Krebbel
2016-02-15 10:44                                     ` Marcin Kościelnicki
2016-02-07 12:22             ` [PATCH] testsuite/s390: Add __morestack test Marcin Kościelnicki
2016-02-19 10:21               ` Andreas Krebbel
2016-01-02 19:17 ` [PATCH 1/5] s390: Use proper read-only data section for literals Marcin Kościelnicki
2016-01-20 13:11   ` Andreas Krebbel
2016-01-21  6:56     ` Marcin Kościelnicki
2016-01-21  8:17       ` Mike Stump
2016-01-21  9:46       ` Andreas Krebbel
2016-01-03  3:21 ` [RFC] [PR 68191] s390: Add -fsplit-stack support Ian Lance Taylor
2016-01-03 10:32   ` Marcin Kościelnicki
2016-01-04  7:35   ` Marcin Kościelnicki

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=56A25B31.9090403@0x04.net \
    --to=koriakin@0x04.net \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=krebbel@linux.vnet.ibm.com \
    --cc=law@redhat.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).