+Mon May 3 22:38:41 1999 David Edelsohn <edelsohn@gnu.org>
+
+ * rs6000/aix43.h (SUBTARGET_OVERRIDE_OPTIONS): Change non-PowerPC
+ and AIX64 combination to warning. Add warning for disabling
+ PowerPC64 support when using 64-bit mode.
+ (LIB_SPEC): Do not link with libg.a in 64-bit mode.
+ (LINK_SPEC): Do not export libg.exp symbols in 64-bit mode.
+ * rs6000/rs6000.h (MY_ISCOFF): Treat import/export files as valid
+ XCOFF files.
+ (read_only_data_section, private_data_section,
+ read_only_private_data_section): Always align CSECTs to doubleword
+ boundary regardless of mode.
+ (TEXT_SECTION_ASM_OP): Align text CSECT on doubleword boundary in
+ 64-bit mode.
+ (DATA_SECTION_ASM_OP): Always align CSECT to doubleword boundary.
+ (ASM_OUTPUT_LOCAL): Use rounded size in 64-bit mode to
+ maintain doublword alignment.
+
Mon May 3 14:45:23 1999 Jeffrey A Law (law@cygnus.com)
* mn10200.md (btst insns): btst does not leave cc0 in a useable
if (TARGET_64BIT && (target_flags & NON_POWERPC_MASKS)) \
{ \
target_flags &= ~NON_POWERPC_MASKS; \
- error ("-maix64 and POWER architecture are incompatible."); \
+ warning ("-maix64 and POWER architecture are incompatible."); \
+ } \
+ if (TARGET_64BIT && ! (target_flags & MASK_POWERPC64)) \
+ { \
+ target_flags |= MASK_POWERPC64; \
+ warning ("-maix64 requires PowerPC64 architecture remain enabled."); \
} \
} while (0);
#undef LIB_SPEC
#define LIB_SPEC "%{pg:-L/lib/profiled -L/usr/lib/profiled}\
- %{p:-L/lib/profiled -L/usr/lib/profiled} %{!shared:%{g*:-lg}}\
+ %{p:-L/lib/profiled -L/usr/lib/profiled}\
+ %{!maix64:%{!shared:%{g*:-lg}}}\
%{mpe:-L/usr/lpp/ppe.poe/lib -lmpi -lvtd}\
- %{mthreads: -L/usr/lib/threads -lpthreads -lc_r /usr/lib/libc.a}\
- %{!mthreads: -lc}"
+ %{mthreads:-L/usr/lib/threads -lpthreads -lc_r /usr/lib/libc.a}\
+ %{!mthreads:-lc}"
#undef LINK_SPEC
#define LINK_SPEC "-bpT:0x10000000 -bpD:0x20000000 %{!r:-btextro} -bnodelcsect\
- %{static:-bnso %(link_syscalls) } %{!shared: %{g*: %(link_libg) }}\
+ %{static:-bnso %(link_syscalls) } %{!maix64:%{!shared:%{g*: %(link_libg) }}}\
%{shared:-bM:SRE %{!e:-bnoentry}} %{maix64:-b64}"
#undef STARTFILE_SPEC
#define OBJECT_FORMAT_COFF
/* Define the magic numbers that we recognize as COFF.
+
AIX 4.3 adds U803XTOCMAGIC (0757) for 64-bit objects, but collect2.c
does not include files in the correct order to conditionally define
- the symbolic name in this macro. */
+ the symbolic name in this macro.
+
+ The AIX linker accepts import/export files as object files,
+ so accept "#!" (0x2321) magic number. */
#define MY_ISCOFF(magic) \
((magic) == U802WRMAGIC || (magic) == U802ROMAGIC \
- || (magic) == U802TOCMAGIC || (magic) == 0757)
+ || (magic) == U802TOCMAGIC || (magic) == 0757 || (magic) == 0x2321)
/* This is the only version of nm that collect2 can work with. */
#define REAL_NM_FILE_NAME "/usr/ucb/nm"
#define JUMP_TABLES_IN_TEXT_SECTION 1
-/* Define the routines to implement these extra sections. */
+/* Define the routines to implement these extra sections.
+ BIGGEST_ALIGNMENT is 64, so align the sections that much. */
#define EXTRA_SECTION_FUNCTIONS \
\
{ \
if (in_section != read_only_data) \
{ \
- fprintf (asm_out_file, ".csect %s[RO]%s\n", \
- xcoff_read_only_section_name, \
- (TARGET_32BIT ? "" : ",3")); \
+ fprintf (asm_out_file, ".csect %s[RO],3\n", \
+ xcoff_read_only_section_name); \
in_section = read_only_data; \
} \
} \
{ \
if (in_section != private_data) \
{ \
- fprintf (asm_out_file, ".csect %s[RW]%s\n", \
- xcoff_private_data_section_name, \
- (TARGET_32BIT ? "" : ",3")); \
+ fprintf (asm_out_file, ".csect %s[RW],3\n", \
+ xcoff_private_data_section_name); \
in_section = private_data; \
} \
} \
{ \
if (in_section != read_only_private_data) \
{ \
- fprintf (asm_out_file, ".csect %s[RO]%s\n", \
- xcoff_private_data_section_name, \
- (TARGET_32BIT ? "" : ",3")); \
+ fprintf (asm_out_file, ".csect %s[RO],3\n", \
+ xcoff_private_data_section_name); \
in_section = read_only_private_data; \
} \
} \
#define ASM_APP_OFF ""
-/* Output before instructions. */
+/* Output before instructions.
+ Text section for 64-bit target may contain 64-bit address jump table. */
-#define TEXT_SECTION_ASM_OP ".csect .text[PR]"
+#define TEXT_SECTION_ASM_OP (TARGET_32BIT \
+ ? ".csect .text[PR]" : ".csect .text[PR],3")
-/* Output before writable data. */
+/* Output before writable data.
+ Align entire section to BIGGEST_ALIGNMENT. */
-#define DATA_SECTION_ASM_OP (TARGET_32BIT \
- ? ".csect .data[RW]" : ".csect .data[RW],3")
+#define DATA_SECTION_ASM_OP ".csect .data[RW],3"
/* How to refer to registers in assembler output.
This sequence is indexed by compiler's hard-register-number (see above). */
} while (0)
/* This says how to output an assembler line
- to define a local common symbol. */
+ to define a local common symbol.
+ Alignment cannot be specified, but we can try to maintain
+ alignment after preceding TOC section if it was aligned
+ for 64-bit mode. */
-#define ASM_OUTPUT_LOCAL(FILE, NAME, SIZE,ROUNDED) \
+#define ASM_OUTPUT_LOCAL(FILE, NAME, SIZE, ROUNDED) \
do { fputs (".lcomm ", (FILE)); \
RS6000_OUTPUT_BASENAME ((FILE), (NAME)); \
- fprintf ((FILE), ",%d,%s\n", (SIZE), xcoff_bss_section_name); \
+ fprintf ((FILE), ",%d,%s\n", (TARGET_32BIT ? (SIZE) : (ROUNDED)), \
+ xcoff_bss_section_name); \
} while (0)
/* Store in OUTPUT a string (made with alloca) containing