This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[3.4] Fix Ada bootstrap on darwin
- From: Andrew Pinski <pinskia at physics dot uc dot edu>
- To: "gcc-patches at gcc dot gnu dot org Patches" <gcc-patches at gcc dot gnu dot org>
- Cc: Andrew Pinski <pinskia at physics dot uc dot edu>, geoffrey Keating <geoffk at apple dot com>, Stan Shebs <shebs at apple dot com>
- Date: Mon, 31 May 2004 19:29:50 -0400
- Subject: [3.4] Fix Ada bootstrap on darwin
I would like to apply the following patch to the 3.4 branch so that it
will
fix Ada bootstrap on Darwin. This is the only 3.4.1 bug assigned to me.
OK? Tested on 3.4 branch on powerpc-apple-darwin with new regressions.
Thanks,
Andrew Pinski
ChangeLog:
2003-07-02 Andrew Pinski <pinskia@physics.uc.edu>
PR target/10129
* config/darwin.c (darwin_encode_section_info): When the decl has
a DECL_INITIAL, it is only defined also when it is not a common.
Patch:
Index: darwin.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/darwin.c,v
retrieving revision 1.38
diff -u -p -r1.38 darwin.c
--- darwin.c 7 Jun 2003 17:11:38 -0000 1.38
+++ darwin.c 2 Jul 2003 06:17:51 -0000
@@ -997,7 +997,7 @@ darwin_encode_section_info (decl, rtl, f
&& !DECL_EXTERNAL (decl)
&& ((TREE_STATIC (decl)
&& (!DECL_COMMON (decl) || !TREE_PUBLIC (decl)))
- || (DECL_INITIAL (decl)
+ || (!DECL_COMMON (decl) && DECL_INITIAL (decl)
&& DECL_INITIAL (decl) != error_mark_node)))
defined = 1;