public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/96493] powerpc local call linkage failure
Date: Wed, 12 Aug 2020 22:47:37 +0000	[thread overview]
Message-ID: <bug-96493-4-XbkOQf8F4g@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-96493-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-10 branch has been updated by Alan Modra <amodra@gcc.gnu.org>:

https://gcc.gnu.org/g:61e46440e8124ba605f7ff81aaf1a19176d0c14b

commit r10-8615-g61e46440e8124ba605f7ff81aaf1a19176d0c14b
Author: Alan Modra <amodra@gmail.com>
Date:   Thu Aug 6 14:12:21 2020 +0930

    PR96493, powerpc local call linkage failure

    This corrects current_file_function_operand, an operand predicate used
    to determine whether a symbol_ref is safe to use with the local_call
    patterns.  Calls between pcrel and non-pcrel code need to go via
    linker stubs.  In the case of non-pcrel code to pcrel the stub saves
    r2 but there needs to be a nop after the branch for the r2 restore.
    So the local_call patterns can't be used there.  For pcrel code to
    non-pcrel the local_call patterns could still be used, but I thought
    it better to not use them since the call isn't direct.  Code generated
    by the corresponding call_nonlocal_aix for pcrel is identical anyway.

    Incidentally, without the TREE_CODE () == FUNCTION_DECL test,
    gcc.c-torture/compile/pr37433.c and pr37433-1.c ICE.  Also, if you
    make the test more strict by disallowing an op without a
    SYMBOL_REF_DECL then a bunch of go and split-stack tests fail.  That's
    because a prologue call to __morestack can't have a following nop.
    (__morestack calls its caller at a fixed offset from the __morestack
    call!)

    gcc/
            PR target/96493
            * config/rs6000/predicates.md (current_file_function_operand):
Don't
            accept functions that differ in r2 usage.

    gcc/testsuite/
            * gcc.target/powerpc/pr96493.c: New file.

    (cherry picked from commit f8ac30f1653ff69706c35af6d725f1d330600f11)

  parent reply	other threads:[~2020-08-12 22:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-06  3:37 [Bug target/96493] New: " amodra at gmail dot com
2020-08-06  7:55 ` [Bug target/96493] " amodra at gmail dot com
2020-08-06 15:46 ` bergner at gcc dot gnu.org
2020-08-07  0:35 ` amodra at gmail dot com
2020-08-07  3:03 ` cvs-commit at gcc dot gnu.org
2020-08-07 13:39 ` bergner at gcc dot gnu.org
2020-08-12 16:26 ` bergner at gcc dot gnu.org
2020-08-12 22:47 ` cvs-commit at gcc dot gnu.org [this message]
2020-08-12 22:56 ` amodra at gmail dot com

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-96493-4-XbkOQf8F4g@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).