summaryrefslogtreecommitdiff
path: root/gcc/config/pa/som.h
diff options
context:
space:
mode:
authordanglin <danglin@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-05 20:57:06 +0000
committerdanglin <danglin@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-05 20:57:06 +0000
commitff59d3760f55dad707382dca4ba375e42dfb9ea1 (patch)
tree465ec10094020f2ced7d87cf202dca82d9966e60 /gcc/config/pa/som.h
parent3e0067928dd0e5967801bc9d18e039e31948566b (diff)
downloadgcc-ff59d3760f55dad707382dca4ba375e42dfb9ea1.tar.gz
* pa.c (pa_asm_output_aligned_bss, pa_asm_output_aligned_common,
pa_asm_output_aligned_local): New functions. * pa-protos.h: Add prototypes for pa_asm_output_aligned_bss, pa_asm_output_aligned_common and pa_asm_output_aligned_local. * pa-pro-end.h (ASM_OUTPUT_ALIGNED_COMMON): Use pa_asm_output_aligned_common. (ASM_OUTPUT_ALIGNED_LOCAL): Use pa_asm_output_aligned_local. * pa.h (ASM_OUTPUT_ALIGNED_BSS): New macro. (ASM_OUTPUT_ALIGNED_COMMON): Use pa_asm_output_aligned_common. (ASM_OUTPUT_ALIGNED_LOCAL): Use pa_asm_output_aligned_local. * pa64-hpux.h (MAX_OFILE_ALIGNMENT): New macro. (ASM_OUTPUT_ALIGNED_COMMON): Use pa_asm_output_aligned_common. (ASM_OUTPUT_ALIGNED_LOCAL): Use pa_asm_output_aligned_local. * som.h (MAX_OFILE_ALIGNMENT): Provide maximum alignment of global common data. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@85611 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/pa/som.h')
-rw-r--r--gcc/config/pa/som.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/gcc/config/pa/som.h b/gcc/config/pa/som.h
index d8082d82b9e..a87b2fda174 100644
--- a/gcc/config/pa/som.h
+++ b/gcc/config/pa/som.h
@@ -371,8 +371,17 @@ do { \
(*p++) (); \
} while (0)
-/* The .align directive in the HP assembler allows up to a 32 alignment. */
-#define MAX_OFILE_ALIGNMENT 32768
+/* This macro specifies the biggest alignment supported by the object
+ file format of this machine.
+
+ The .align directive in the HP assembler allows alignments up to 4096
+ bytes. However, the maximum alignment of a global common symbol is 8
+ bytes for objects smaller than the page size (4096 bytes). For larger
+ objects, the linker provides an alignment of 32 bytes. */
+#define MAX_OFILE_ALIGNMENT \
+ (TREE_PUBLIC (decl) && DECL_COMMON (decl) \
+ ? (host_integerp (DECL_SIZE_UNIT (decl), 1) >= 4096 ? 256 : 64) \
+ : 32768)
/* The SOM linker hardcodes paths into binaries. As a result, dotdots
must be removed from library prefixes to prevent binaries from depending