From: "H.J. Lu" <hjl.tools@gmail.com>
To: GCC Patches <gcc-patches@gcc.gnu.org>
Cc: Richard Henderson <rth@redhat.com>
Subject: Re: PING: PATCH: PR target/46770: Use .init_array/.fini_array sections
Date: Thu, 14 Apr 2011 19:11:00 -0000 [thread overview]
Message-ID: <BANLkTimM9oXfNk7NKYg1TSfoN2C-_vB9ow@mail.gmail.com> (raw)
In-Reply-To: <AANLkTimtcwsV8Af7a60Jz57g-J38oR==+Ew7BqQvMbJm@mail.gmail.com>
On Thu, Mar 31, 2011 at 7:57 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
> On Mon, Mar 21, 2011 at 11:40 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
>> On Mon, Mar 14, 2011 at 12:28 PM, H.J. Lu <hjl.tools@gmail.com> wrote:
>>> On Thu, Jan 27, 2011 at 2:40 AM, Richard Guenther
>>> <richard.guenther@gmail.com> wrote:
>>>> On Thu, Jan 27, 2011 at 12:12 AM, H.J. Lu <hongjiu.lu@intel.com> wrote:
>>>>> On Tue, Dec 14, 2010 at 05:20:48PM -0800, H.J. Lu wrote:
>>>>>> This patch uses .init_array/.fini_array sections instead of
>>>>>> .ctors/.dtors sections if mixing .init_array/.fini_array and
>>>>>> .ctors/.dtors sections with init_priority works.
>>>>>>
>>>>>> It removes .ctors/.ctors sections from executables and DSOes, which will
>>>>>> remove one function call at startup time from each executable and DSO.
>>>>>> It should reduce image size and improve system startup time.
>>>>>>
>>>>>> If a platform with a working .init_array/.fini_array support needs a
>>>>>> different .init_array/.fini_array implementation, it can set
>>>>>> use_initfini_array to no.
>>>>>>
>>>>>> Since .init_array/.fini_array is a target feature. --enable-initfini-array
>>>>>> is default to no unless the native run-time test is passed.
>>>>>>
>>>>>> To pass the native run-time test, a linker with SORT_BY_INIT_PRIORITY
>>>>>> support is required. The binutils patch is available at
>>>>>>
>>>>>> http://sourceware.org/ml/binutils/2010-12/msg00466.html
>>>>>
>>>>> Linker patch has been checked in.
>>>>>
>>>>>>
>>>>>> This patch passed 32bit/64bit regression test on Linux/x86-64. Any
>>>>>> comments?
>>>>>>
>>>>>
>>>>> This updated patch fixes build on Linux/ia64 and should work on others.
>>>>> Any comments?
>>>>
>>>> Yes. This is stage1 material.
>>>>
>>>
>>> Here is the updated patch. OK for trunk?
>>>
>>> Thanks.
>>>
>>>
>>> --
>>> H.J.
>>> ----
>>> 2011-03-14 H.J. Lu <hongjiu.lu@intel.com>
>>>
>>> PR target/46770
>>> * acinclude.m4 (gcc_AC_INITFINI_ARRAY): Removed.
>>>
>>> * config.gcc (use_initfini_array): New variable.
>>> Use initfini-array.o if supported.
>>>
>>> * crtstuff.c: Don't generate .ctors nor .dtors sections if
>>> NO_CTORS_DTORS_SECTIONS is defined.
>>>
>>> * configure.ac: Remove gcc_AC_INITFINI_ARRAY. Add
>>> --enable-initfini-array and check if .init_array can be used with
>>> .ctors.
>>>
>>> * configure: Regenerated.
>>>
>>> * config/initfini-array.c: New.
>>> * config/initfini-array.h: Likewise.
>>> * config/t-initfini-array: Likewise.
>>>
>>> * config/arm/arm.c (arm_asm_init_sections): Call
>>> elf_initfini_array_init_sections if NO_CTORS_DTORS_SECTIONS
>>> is defined.
>>> * config/avr/avr.c (avr_asm_init_sections): Likewise.
>>> * config/ia64/ia64.c (ia64_asm_init_sections): Likewise.
>>> * config/mep/mep.c (mep_asm_init_sections): Likewise.
>>> * config/microblaze/microblaze.c (microblaze_elf_asm_init_sections):
>>> Likewise.
>>> * config/rs6000/rs6000.c (rs6000_elf_asm_init_sections): Likewise.
>>> * config/stormy16/stormy16.c (xstormy16_asm_init_sections):
>>> Likewise.
>>> * config/v850/v850.c (v850_asm_init_sections): Likewise.
>>>
>>
>> PING:
>>
>> http://gcc.gnu.org/ml/gcc-patches/2011-03/msg00760.html
>>
>
> Any comments? Any objections?
>
Hi Richard,
Can you take a look at this patch?
Thanks.
--
H.J.
next prev parent reply other threads:[~2011-04-14 19:05 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-21 18:40 H.J. Lu
2011-03-31 15:15 ` H.J. Lu
2011-04-14 19:11 ` H.J. Lu [this message]
2011-04-26 13:08 ` H.J. Lu
2011-05-18 17:30 ` H.J. Lu
2011-06-01 23:30 ` Carrot Wei
2011-06-03 4:31 ` H.J. Lu
2011-06-03 12:31 ` Richard Guenther
2011-06-03 12:52 ` H.J. Lu
2011-06-19 20:02 ` H.J. Lu
2011-06-19 21:31 ` Uros Bizjak
2011-07-22 12:31 ` H.J. Lu
2011-07-22 12:36 ` Rainer Orth
2011-07-22 12:36 ` H.J. Lu
2011-07-22 13:20 ` Rainer Orth
2011-07-22 12:37 ` Jakub Jelinek
2011-07-22 13:21 ` Joseph S. Myers
2011-07-22 13:29 ` H.J. Lu
2011-07-22 14:17 ` H.J. Lu
2011-07-22 14:55 ` H.J. Lu
2011-08-06 14:51 ` H.J. Lu
2011-08-09 14:32 ` H.J. Lu
2011-08-14 19:20 ` H.J. Lu
2011-08-19 10:05 ` Jakub Jelinek
2011-08-19 14:58 ` H.J. Lu
2011-08-19 15:54 ` Jakub Jelinek
2011-08-20 21:16 ` H.J. Lu
2012-03-19 20:35 ` DJ Delorie
2012-03-19 20:40 ` Andrew Pinski
2012-03-19 20:42 ` DJ Delorie
2011-07-01 14:12 ` H.J. Lu
2011-06-03 17:13 ` Michael Eager
2011-08-22 7:39 David Edelsohn
2011-08-22 7:44 ` H.J. Lu
2011-08-22 7:46 ` Jakub Jelinek
2011-08-22 14:23 ` H.J. Lu
2011-08-22 15:27 ` H.J. Lu
2011-08-22 15:46 ` Paolo Bonzini
2011-08-22 17:37 ` H.J. Lu
2011-08-22 18:33 ` H.J. Lu
2011-08-22 19:12 ` Joseph S. Myers
2011-08-22 19:19 ` H.J. Lu
2011-08-22 19:38 ` Joseph S. Myers
2011-08-22 20:50 ` H.J. Lu
2011-08-22 7:46 ` David Edelsohn
2011-08-22 16:26 ` H.J. Lu
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=BANLkTimM9oXfNk7NKYg1TSfoN2C-_vB9ow@mail.gmail.com \
--to=hjl.tools@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=rth@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).