public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Segher Boessenkool <segher@kernel.crashing.org>
To: Rich Felker <dalias@libc.org>
Cc: Joseph Myers <joseph@codesourcery.com>, gcc-patches@gcc.gnu.org
Subject: Re: Reviving SH FDPIC target
Date: Fri, 04 Sep 2015 23:08:00 -0000	[thread overview]
Message-ID: <20150904230415.GA23901@gate.crashing.org> (raw)
In-Reply-To: <20150904201640.GU17773@brightrain.aerifal.cx>

On Fri, Sep 04, 2015 at 04:16:40PM -0400, Rich Felker wrote:
> One thing I've noticed that's odd is that gcc -mfdpic -fPIC produces
> different (less efficient) code from just gcc -mfdpic, which seems
> wrong, but agrees with sh.c which has a number of checks for flag_pic
> not matched with a TARGET_FDPIC check.

Generic code tests flag_pic in important places as well.

> I'm thinking all of these
> should either be flag_pic||TARGET_PIC or flag_pic&&!TARGET_FDPIC,
> depending on whether the code applies to all PIC or is specific to the
> non-FDPIC PIC model where r12 is call-saved. Does this sound correct?
> I think we need spurious -fPIC to work (although it could be handled
> with spec magic) and not pessimize code, since most library builds
> will use -fPIC.

If you never want -fPIC (or -fpic) if fdpic is enabled, you can disable
it (in sh_option_override)?


Segher

  reply	other threads:[~2015-09-04 23:04 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-02 18:36 Rich Felker
2015-09-02 20:00 ` Joseph Myers
2015-09-02 21:14   ` Rich Felker
2015-09-03  4:33     ` Rich Felker
2015-09-03 14:59       ` Joseph Myers
2015-09-03 15:59         ` Rich Felker
2015-09-04 20:22           ` Rich Felker
2015-09-04 23:08             ` Segher Boessenkool [this message]
2015-09-05 12:37               ` Rich Felker
2015-09-13 17:11               ` Rich Felker
2015-09-11  4:05             ` Rich Felker
2015-09-11  8:02               ` Rich Felker

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=20150904230415.GA23901@gate.crashing.org \
    --to=segher@kernel.crashing.org \
    --cc=dalias@libc.org \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=joseph@codesourcery.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).