diff mbox

Build breakage on darwin and pa64-hpux [was Re: Use -fbuilding-libgcc for more target macros used in libgcc]

Message ID B51EBCE2-8617-45CC-879D-490B87CA3263@comcast.net
State New
Headers show

Commit Message

Mike Stump Sept. 6, 2014, 5:17 a.m. UTC
On Sep 5, 2014, at 3:59 PM, Dominique Dhumieres <dominiq@lps.ens.fr> wrote:
> See pr63188 for darwin. The same patch should probably
> fix the problem for hppa64-hpux* too.

Thanks.

Committed revision 214983.

Comments

Andreas Schwab Sept. 6, 2014, 7:20 a.m. UTC | #1
Mike Stump <mikestump@comcast.net> writes:

> Index: config/pa/pa64-hpux.h
> ===================================================================
> --- config/pa/pa64-hpux.h	(revision 214981)
> +++ config/pa/pa64-hpux.h	(working copy)
> @@ -336,7 +336,7 @@ do {								\
>     the sections are not actually used.  However, we still must provide
>     defines to select the proper code path.  */
>  #undef INIT_SECTION_ASM_OP
> -#define INIT_SECTION_ASM_OP
> +#define INIT_SECTION_ASM_OP ""
>  #undef FINI_SECTION_ASM_OP
>  #define FINI_SECTION_ASM_OP

What about FINI_SECTION_ASM_OP?

Andreas.
Mike Stump Sept. 7, 2014, 6:41 p.m. UTC | #2
On Sep 6, 2014, at 12:20 AM, Andreas Schwab <schwab@linux-m68k.org> wrote:
> Mike Stump <mikestump@comcast.net> writes:
> 
>> Index: config/pa/pa64-hpux.h
>> ===================================================================
>> --- config/pa/pa64-hpux.h	(revision 214981)
>> +++ config/pa/pa64-hpux.h	(working copy)
>> @@ -336,7 +336,7 @@ do {								\
>>    the sections are not actually used.  However, we still must provide
>>    defines to select the proper code path.  */
>> #undef INIT_SECTION_ASM_OP
>> -#define INIT_SECTION_ASM_OP
>> +#define INIT_SECTION_ASM_OP ""
>> #undef FINI_SECTION_ASM_OP
>> #define FINI_SECTION_ASM_OP
> 
> What about FINI_SECTION_ASM_OP?

That wasn’t part of the tested patch in the PR.  :-(  If someone can confirm it breaks the hp build, I’ll just fix it…  I’ll note that people are free to use “” FINI_SECTION_ASM_OP as well, which I suspect won’t break with the above definition.
Joseph Myers Sept. 8, 2014, 11:54 p.m. UTC | #3
On Sat, 6 Sep 2014, Andreas Schwab wrote:

> Mike Stump <mikestump@comcast.net> writes:
> 
> > Index: config/pa/pa64-hpux.h
> > ===================================================================
> > --- config/pa/pa64-hpux.h	(revision 214981)
> > +++ config/pa/pa64-hpux.h	(working copy)
> > @@ -336,7 +336,7 @@ do {								\
> >     the sections are not actually used.  However, we still must provide
> >     defines to select the proper code path.  */
> >  #undef INIT_SECTION_ASM_OP
> > -#define INIT_SECTION_ASM_OP
> > +#define INIT_SECTION_ASM_OP ""
> >  #undef FINI_SECTION_ASM_OP
> >  #define FINI_SECTION_ASM_OP
> 
> What about FINI_SECTION_ASM_OP?

My patch didn't do anything with FINI_SECTION_ASM_OP.

As it's not actually used on the host at all (unlike INIT_SECTION_ASM_OP), 
it could be moved to libgcc_tm.h.  However, my inclination is that it 
would be confusing to have such closely related target macros in different 
places, and so it would make sense to add FINI_SECTION_ASM_OP and 
FINI_ARRAY_SECTION_ASM_OP to the target macros that are communicated to 
libgcc via macros predefined with -fbuilding-libgcc.  (This is without 
prejudice to any possible future cleanup or refactoring of the macros in 
this area.)
diff mbox

Patch

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 214981)
+++ ChangeLog	(working copy)
@@ -1,3 +1,9 @@ 
+2014-09-05  Dominique Dhumieres  <dominiq@lps.ens.fr>
+
+	PR target/63188
+	* config/darwin.h (INIT_SECTION_ASM_OP): Define to "".
+	* config/pa/pa64-hpux.h (INIT_SECTION_ASM_OP): Likewise.
+
 2014-09-05  Easwaran Raman  <eraman@google.com>
 
 	PR rtl-optimization/62146
Index: config/darwin.h
===================================================================
--- config/darwin.h	(revision 214981)
+++ config/darwin.h	(working copy)
@@ -499,7 +499,7 @@  extern GTY(()) int darwin_ms_struct;
 #define NO_PROFILE_COUNTERS	1
 
 #undef	INIT_SECTION_ASM_OP
-#define INIT_SECTION_ASM_OP
+#define INIT_SECTION_ASM_OP ""
 
 #undef	INVOKE__main
 
Index: config/pa/pa64-hpux.h
===================================================================
--- config/pa/pa64-hpux.h	(revision 214981)
+++ config/pa/pa64-hpux.h	(working copy)
@@ -336,7 +336,7 @@  do {								\
    the sections are not actually used.  However, we still must provide
    defines to select the proper code path.  */
 #undef INIT_SECTION_ASM_OP
-#define INIT_SECTION_ASM_OP
+#define INIT_SECTION_ASM_OP ""
 #undef FINI_SECTION_ASM_OP
 #define FINI_SECTION_ASM_OP