On 09/30/2016 02:31 PM, Rainer Orth wrote:
> this would be i386-pc-solaris2.12.  I'm not sure if the constructor
> priority detection works in a cross scenario.
> 
> I'm attaching the resulting assembly (although for Solaris as, the gas
> build is still running).

Hi. Sorry, I have a stupid mistake in dtor priority
(I used 65534 instead of desired 99). Please try to test it on Solaris 12
with the attached patch. I'll send the patch to ML soon.

Can you please test whether it makes any change on a solaris target w/o
prioritized ctors/dtors?

Thanks,
Martin
diff --git a/gcc/coverage.c b/gcc/coverage.c
index 0b8c0b3..a759831 100644
--- a/gcc/coverage.c
+++ b/gcc/coverage.c
@@ -1078,7 +1078,7 @@ build_gcov_exit_decl (void)
   append_to_statement_list (stmt, &dtor);
 
   /* Generate a destructor to run it (with priority 99).  */
-  cgraph_build_static_cdtor ('D', dtor, DEFAULT_INIT_PRIORITY - 1);
+  cgraph_build_static_cdtor ('D', dtor, MAX_RESERVED_INIT_PRIORITY - 1);
 }
 
 /* Create the gcov_info types and object.  Generate the constructor

Reply via email to