aboutsummaryrefslogtreecommitdiff
path: root/libgcc
diff options
context:
space:
mode:
authorAndrew Pinski <apinski@cavium.com>2011-12-06 21:35:41 +0000
committerAndrew Pinski <pinskia@gcc.gnu.org>2011-12-06 13:35:41 -0800
commit806fc6aa98cd8071c9b451347c9ce2cf071c0598 (patch)
tree414614ab6d32ccb8e11383f1012f9bfda19a2359 /libgcc
parent5fa3ea21352a956a05859c65a2107f019c16013c (diff)
downloadgcc-806fc6aa98cd8071c9b451347c9ce2cf071c0598.zip
gcc-806fc6aa98cd8071c9b451347c9ce2cf071c0598.tar.gz
gcc-806fc6aa98cd8071c9b451347c9ce2cf071c0598.tar.bz2
crtstuff.c (__do_global_dtors_aux_fini_array_entry): Align to the size of func_ptr.
2011-12-06 Andrew Pinski <apinski@cavium.com> * crtstuff.c (__do_global_dtors_aux_fini_array_entry): Align to the size of func_ptr. (__frame_dummy_init_array_entry): Likewise. From-SVN: r182066
Diffstat (limited to 'libgcc')
-rw-r--r--libgcc/ChangeLog6
-rw-r--r--libgcc/crtstuff.c4
2 files changed, 8 insertions, 2 deletions
diff --git a/libgcc/ChangeLog b/libgcc/ChangeLog
index cde3853..d74aeb9 100644
--- a/libgcc/ChangeLog
+++ b/libgcc/ChangeLog
@@ -1,3 +1,9 @@
+2011-12-06 Andrew Pinski <apinski@cavium.com>
+
+ * crtstuff.c (__do_global_dtors_aux_fini_array_entry): Align to the
+ size of func_ptr.
+ (__frame_dummy_init_array_entry): Likewise.
+
2011-12-06 Georg-Johann Lay <avr@gjlay.de>
Forward-port from gcc-4_6-branch r181936 2011-12-02.
diff --git a/libgcc/crtstuff.c b/libgcc/crtstuff.c
index 77b8d42..5d820fa 100644
--- a/libgcc/crtstuff.c
+++ b/libgcc/crtstuff.c
@@ -412,7 +412,7 @@ __do_global_dtors_aux (void)
CRT_CALL_STATIC_FUNCTION (FINI_SECTION_ASM_OP, __do_global_dtors_aux)
#elif defined (FINI_ARRAY_SECTION_ASM_OP)
static func_ptr __do_global_dtors_aux_fini_array_entry[]
- __attribute__ ((__used__, section(".fini_array")))
+ __attribute__ ((__used__, section(".fini_array"), aligned(sizeof(func_ptr))))
= { __do_global_dtors_aux };
#else /* !FINI_SECTION_ASM_OP && !FINI_ARRAY_SECTION_ASM_OP */
static void __attribute__((used))
@@ -466,7 +466,7 @@ frame_dummy (void)
CRT_CALL_STATIC_FUNCTION (INIT_SECTION_ASM_OP, frame_dummy)
#else /* defined(INIT_SECTION_ASM_OP) */
static func_ptr __frame_dummy_init_array_entry[]
- __attribute__ ((__used__, section(".init_array")))
+ __attribute__ ((__used__, section(".init_array"), aligned(sizeof(func_ptr))))
= { frame_dummy };
#endif /* !defined(INIT_SECTION_ASM_OP) */
#endif /* USE_EH_FRAME_REGISTRY || JCR_SECTION_NAME || USE_TM_CLONE_REGISTRY */