From: "H.J. Lu" <hjl.tools@gmail.com>
To: Uros Bizjak <ubizjak@gmail.com>
Cc: Richard Henderson <rth@redhat.com>,
"gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH] PR rtl-optimization/32219: optimizer causees wrong code in pic/hidden/weak symbol checking
Date: Thu, 19 Feb 2015 21:16:00 -0000 [thread overview]
Message-ID: <CAMe9rOqmEJO5P61ntCD8y10y_uRZMJh4H=yfxtDUr4m5xi9LUg@mail.gmail.com> (raw)
In-Reply-To: <CAMe9rOrxywA3kt+zzkhvETypTpZODszEKgVeHZPJpFA-vdHyGg@mail.gmail.com>
On Thu, Feb 19, 2015 at 1:07 PM, H.J. Lu <hjl.tools@gmail.com> wrote:
> On Thu, Feb 19, 2015 at 1:04 PM, Uros Bizjak <ubizjak@gmail.com> wrote:
>> On Mon, Feb 16, 2015 at 5:30 PM, Richard Henderson <rth@redhat.com> wrote:
>>
>>>>>> 2015-02-12 H.J. Lu <hongjiu.lu@intel.com>
>>>>>> Richard Henderson <rth@redhat.com>
>>>>>>
>>>>>> PR rtl/32219
>>>>>> * cgraphunit.c (cgraph_node::finalize_function): Set definition
>>>>>> before notice_global_symbol.
>>>>>> (varpool_node::finalize_decl): Likewise.
>>>>>> * varasm.c (default_binds_local_p_2): Rename from
>>>>>> default_binds_local_p_1, add weak_dominate argument. Use direct
>>>>>> returns instead of assigning to local variable. Unify varpool and
>>>>>> cgraph paths via symtab_node. Reject undef weak variables before
>>>>>> testing visibility. Reorder tests for simplicity.
>>>>>> (default_binds_local_p): Use default_binds_local_p_2.
>>>>>> (default_binds_local_p_1): Likewise.
>>>>>> (decl_binds_to_current_def_p): Unify varpool and cgraph paths
>>>>>> via symtab_node.
>>>>>> (default_elf_asm_output_external): Emit visibility when specified.
>>>>>
>>>>> It looks like this patch broke alphaev68-linux-gnu [1]. There are many
>>>>> failures of the type:
>>>>>
>>>>> /tmp/cck7V7MR.o: In function
>>>>> `__static_initialization_and_destruction_0(int, int)':^M
>>>>> (.text+0x3ac): relocation truncated to fit: GPRELHIGH against symbol
>>>>> `std::__cxx11::basic_string<char, std::char_traits<char>,
>>>>> std::allocator<char> >::~basic_string()@@GLIBCXX_3.4.21' defined in
>>>>> .text section in
>>>>> /space/uros/gcc-build/alphaev68-unknown-linux-gnu/./libstdc++-v3/src/.libs/libstdc++.so^M
>>>>> /space/homedirs/uros/local/bin/ld: /tmp/cck7V7MR.o: gp-relative
>>>>> relocation against dynamic symbol
>>>>
>>>> It could be related to:
>>>>
>>>> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65064
>>>>
>>>> Before this bug fix, all common symbols don't bind locally,
>>>> which is one of PR 32219 bugs. After this fix, common
>>>> symbols bind locally. It may cause problems on targets with
>>>> small data sections and common symbols aren't in small
>>>> data section:
>>>
>>> This is a destructor, and so obviously not a common symbol.
>>>
>>> I'll have a look.
>>
>> The attached patch fixes all alpha-linux-gnu failures.
>>
>> 2015-02-19 Uros Bizjak <ubizjak@gmail.com>
>>
>> * config/alpha/alpha.c (alpha_in_small_data_p): Reject common symbols.
>>
>> Patch was bootstrapped and regression tested on alphaev68-linux-gnu.
>>
>> OK for mainline?
>>
>
> You may want to use something like this:
>
> https://gcc.gnu.org/ml/gcc-patches/2015-02/msg01105.html
>
See:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65064
for why.
--
H.J.
next prev parent reply other threads:[~2015-02-19 21:08 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-16 13:25 Uros Bizjak
2015-02-16 14:01 ` H.J. Lu
2015-02-16 16:30 ` Richard Henderson
2015-02-16 16:38 ` H.J. Lu
2015-02-19 21:07 ` Uros Bizjak
2015-02-19 21:08 ` H.J. Lu
2015-02-19 21:16 ` Richard Henderson
2015-02-19 21:16 ` H.J. Lu [this message]
2015-02-19 21:35 ` Richard Henderson
2015-02-19 21:43 ` H.J. Lu
2015-02-19 23:39 ` Uros Bizjak
-- strict thread matches above, loose matches on Subject: below --
2015-02-06 16:23 [PATCH] PR rtl-optimization/32219: optimizer causes " H.J. Lu
2015-02-06 21:31 ` Jack Howarth
2015-02-06 21:41 ` H.J. Lu
2015-02-07 1:51 ` Jack Howarth
2015-02-07 1:55 ` H.J. Lu
2015-02-07 8:28 ` Jack Howarth
2015-02-07 12:27 ` H.J. Lu
2015-02-07 15:11 ` Jack Howarth
2015-02-07 15:56 ` H.J. Lu
2015-02-07 16:45 ` H.J. Lu
2015-02-10 21:19 ` Richard Henderson
2015-02-12 6:23 ` [PATCH] PR rtl-optimization/32219: optimizer causees " Richard Henderson
2015-02-12 18:16 ` H.J. Lu
2015-02-12 18:58 ` H.J. Lu
2015-02-12 19:25 ` Richard Henderson
2015-02-12 23:04 ` H.J. Lu
2015-02-12 23:05 ` H.J. Lu
2015-02-13 0:05 ` Richard Henderson
2015-02-13 4:14 ` H.J. Lu
2015-02-13 5:11 ` Richard Henderson
2015-02-18 14:17 ` Alex Velenko
2015-02-19 13:12 ` H.J. Lu
2015-02-19 15:02 ` Richard Henderson
2015-02-19 17:25 ` Alex Velenko
2015-02-19 17:27 ` Richard Henderson
2015-03-03 15:58 ` Alex Velenko
2015-03-05 14:55 ` Alex Velenko
2015-03-05 15:31 ` Ramana Radhakrishnan
2015-03-06 11:14 ` Alex Velenko
2015-02-12 19:16 ` Jack Howarth
2015-02-12 19:18 ` H.J. Lu
2015-02-12 19:39 ` Jack Howarth
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='CAMe9rOqmEJO5P61ntCD8y10y_uRZMJh4H=yfxtDUr4m5xi9LUg@mail.gmail.com' \
--to=hjl.tools@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=rth@redhat.com \
--cc=ubizjak@gmail.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).