From: "H.J. Lu" <hjl.tools@gmail.com>
To: Jan Hubicka <hubicka@ucw.cz>
Cc: GCC Patches <gcc-patches@gcc.gnu.org>
Subject: Re: Transparent alias suport part 7 (lto-symtab support)
Date: Sat, 12 Dec 2015 19:00:00 -0000 [thread overview]
Message-ID: <CAMe9rOq22ye9a6JhcF1h8mxzMuF0ttY=iaYEgZNqgON_Ki2GEg@mail.gmail.com> (raw)
In-Reply-To: <20151208223003.GE58058@kam.mff.cuni.cz>
On Tue, Dec 8, 2015 at 2:30 PM, Jan Hubicka <hubicka@ucw.cz> wrote:
> Hi,
> this patch adds support to lto-symtab.c to prevent merging of certain
> declarations. The new predicate lto_symtab_merge_p can be used to decide
> about this. The change is pretty straigforward. lto_symtab_merge_decls_2
> makes the decisions about what decls to merge and lto_symtab_merge_symbols_1
> does the corresponding symbol merging/creation of transparent aliases.
>
> I re-implemented lto_symtab_prevailing_decl and moved it to inline so the
> merging pass is also considerably faster (it used to do quite expensive
> assembler name hash lookup on every occurenceof the decl). Merging decisions
> are represented by setting DECL_ABSTRACT_ORIGIN to error_mark_node and
> DECL_CHAIN to the replacement decl. This is quite arbitrary decision - I needed
> a pointer and flag that is not going to mess with the warnings we output
> during the lto-symtab's operation.
>
> The patch does not disable any of the wrong merging we are hitting. I will
> dot hat separately and with a testcases. I only revisited a bit the way
> builtins are handled.
>
> Bootstrapped/regtested x86_64-linux. I am re-running the lto-bootstrap after
> some last minute changes and plan commit once it converges.
>
> Honza
>
> PR ipa/61886
> * lto-streamer.h (lto_symtab_merge_decls, lto_symtab_merge_symbols,
> lto_symtab_prevailing_decl): MOve to lto-symtab.h.
>
> * lto-symtab.c: Include lto-symtab.h.
> (lto_cgraph_replace_node): Do not merge profiles here.
> (lto_symtab_merge_p): New function.
> (lto_symtab_merge_decls_2): Honor lto_symtab_merge_p.
> (lto_symtab_merge_symbols_1): Turn unmerged decls into transparent
> aliases.
> (lto_symtab_merge_symbols): Do not clear node->aux; we no longer use it.
> (lto_symtab_prevailing_decl): Move to lto-symtab.h; rewrite.
> * lto.c: Include lto-symtab.h
> * lto-symtab.h: New.
>
This caused:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68878
--
H.J.
prev parent reply other threads:[~2015-12-12 19:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-08 22:30 Jan Hubicka
2015-12-12 19:00 ` H.J. Lu [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='CAMe9rOq22ye9a6JhcF1h8mxzMuF0ttY=iaYEgZNqgON_Ki2GEg@mail.gmail.com' \
--to=hjl.tools@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=hubicka@ucw.cz \
/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).