[PATCH] Don't use priority {cd}tors if not supported by a target (PR, gcov-profile/78086)

Martin Liška mliska@suse.cz
Mon Oct 31 12:13:00 GMT 2016


On 10/31/2016 11:07 AM, Rainer Orth wrote:
> Hi Martin,
> 
>> Using priority {cd}tors on a target that does not support that can cause
>> failures (see the PR).
>> Apart from that, I decided to use priority 100 for both gcov_init and
>> gcov_exit functions as
>> the reserved range includes priority 100. Moreover, I enhanced test-cases
>> we have.
> 
> just two nits:
> 
> diff --git a/gcc/testsuite/g++.dg/gcov/pr16855-priority.C b/gcc/testsuite/g++.dg/gcov/pr16855-priority.C
> new file mode 100644
> index 0000000..7e39565
> --- /dev/null
> +++ b/gcc/testsuite/g++.dg/gcov/pr16855-priority.C
> [...]
> +static void __attribute__ ((constructor ((101)))) ctor_100 ()
> 
> Should be called ctor_101 now.  Same for dtor_100 below.
> 
> 	Rainer
> 

Thanks for the note. Fixed in attached patch.

Martin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Don-t-use-priority-cd-tors-if-not-supported-by-a-tar-v2.patch
Type: text/x-patch
Size: 6050 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20161031/1cc14b58/attachment.bin>


More information about the Gcc-patches mailing list