#undef SUBTARGET_SWITCHES
#define SUBTARGET_SWITCHES \
{ "sio", MASK_SIO, \
N_("Generate cpp defines for server IO") }, \
{ "wsio", -MASK_SIO, \
N_("Generate cpp defines for workstation IO") }, \
{"gnu-ld", MASK_GNU_LD, \
N_("Assume code will be linked by GNU ld") }, \
{"hp-ld", -MASK_GNU_LD, \
N_("Assume code will be linked by HP ld") },
#undef LINK_SPEC
#if ((TARGET_DEFAULT | TARGET_CPU_DEFAULT) & MASK_GNU_LD)
#define LINK_SPEC \
"%{!shared:%{p:-L/lib/pa20_64/libp -L/usr/lib/pa20_64/libp %{!static:\
%nWarning: consider linking with `-static' as system libraries with\n\
%n profiling support are only provided in archive format}}}\
%{!shared:%{pg:-L/lib/pa20_64/libp -L/usr/lib/pa20_64/libp %{!static:\
%nWarning: consider linking with `-static' as system libraries with\n\
%n profiling support are only provided in archive format}}}\
%{mhp-ld:+Accept TypeMismatch -z} -E %{mlinker-opt:-O} %{!shared:-u main}\
%{static:-a archive} %{shared:%{mhp-ld:-b}%{!mhp-ld:-shared}}"
#else
#define LINK_SPEC \
"%{!shared:%{p:-L/lib/pa20_64/libp -L/usr/lib/pa20_64/libp %{!static:\
%nWarning: consider linking with `-static' as system libraries with\n\
%n profiling support are only provided in archive format}}}\
%{!shared:%{pg:-L/lib/pa20_64/libp -L/usr/lib/pa20_64/libp %{!static:\
%nWarning: consider linking with `-static' as system libraries with\n\
%n profiling support are only provided in archive format}}}\
%{!mgnu-ld:+Accept TypeMismatch -z} -E %{mlinker-opt:-O} %{!shared:-u main}\
%{static:-a archive} %{shared:%{mgnu-ld:-shared}%{!mgnu-ld:-b}}"
#endif
#undef LIB_SPEC
#if ((TARGET_DEFAULT | TARGET_CPU_DEFAULT) & MASK_GNU_LD)
#define LIB_SPEC \
"%{!shared:\
%{!p:%{!pg: -lc %{static:%{!nolibdld:-a shared -ldld -a archive -lc}}}}\
%{p:%{!pg:%{static:%{!mhp-ld:-a shared}%{mhp-ld:-a archive_shared}}\
-lprof %{static:-a archive} -lc\
%{static:%{!nolibdld:-a shared -ldld -a archive -lc}}}}\
%{pg:%{static:%{!mhp-ld:-a shared}%{mhp-ld:-a archive_shared}}\
-lgprof %{static:-a archive} -lc\
%{static:%{!nolibdld:-a shared -ldld -a archive -lc}}}}\
/usr/lib/pa20_64/milli.a"
#else
#define LIB_SPEC \
"%{!shared:\
%{!p:%{!pg: -lc %{static:%{!nolibdld:-a shared -ldld -a archive -lc}}}}\
%{p:%{!pg:%{static:%{mgnu-ld:-a shared}%{!mgnu-ld:-a archive_shared}}\
-lprof %{static:-a archive} -lc\
%{static:%{!nolibdld:-a shared -ldld -a archive -lc}}}}\
%{pg:%{static:%{mgnu-ld:-a shared}%{!mgnu-ld:-a archive_shared}}\
-lgprof %{static:-a archive} -lc\
%{static:%{!nolibdld:-a shared -ldld -a archive -lc}}}}\
/usr/lib/pa20_64/milli.a"
#endif
#ifndef CROSS_COMPILE
#undef MD_EXEC_PREFIX
#define MD_EXEC_PREFIX "/usr/ccs/bin"
#endif
#ifndef CROSS_COMPILE
#undef MD_STARTFILE_PREFIX
#define MD_STARTFILE_PREFIX "/usr/ccs/lib/pa20_64/"
#endif
#ifndef CROSS_COMPILE
#undef MD_STARTFILE_PREFIX_1
#define MD_STARTFILE_PREFIX_1 "/opt/langtools/lib/pa20_64/"
#endif
#undef TARGET_GAS
#ifdef USING_ELFOS_H
#define TARGET_GAS 1
#undef TARGET_ASM_FILE_START
#define TARGET_ASM_FILE_START pa_hpux64_gas_file_start
#undef STRING_ASM_OP
#define STRING_ASM_OP "\t.stringz\t"
#define TEXT_SECTION_ASM_OP "\t.text"
#define DATA_SECTION_ASM_OP "\t.data"
#define BSS_SECTION_ASM_OP "\t.section\t.bss"
#define JCR_SECTION_NAME ".jcr"
#define HP_INIT_ARRAY_SECTION_ASM_OP "\t.section\t.init"
#define GNU_INIT_ARRAY_SECTION_ASM_OP "\t.section\t.init_array"
#define HP_FINI_ARRAY_SECTION_ASM_OP "\t.section\t.fini"
#define GNU_FINI_ARRAY_SECTION_ASM_OP "\t.section\t.fini_array"
#undef ASM_OUTPUT_ALIGNED_COMMON
#define ASM_OUTPUT_ALIGNED_COMMON(FILE, NAME, SIZE, ALIGN) \
do { \
bss_section (); \
assemble_name ((FILE), (NAME)); \
fprintf ((FILE), "\t.comm "HOST_WIDE_INT_PRINT_UNSIGNED"\n", \
MAX ((unsigned HOST_WIDE_INT)(SIZE), \
((unsigned HOST_WIDE_INT)(ALIGN) / BITS_PER_UNIT))); \
} while (0)
#undef ASM_OUTPUT_ALIGNED_LOCAL
#define ASM_OUTPUT_ALIGNED_LOCAL(FILE, NAME, SIZE, ALIGN) \
do { \
bss_section (); \
fprintf ((FILE), "\t.align %d\n", ((ALIGN) / BITS_PER_UNIT)); \
assemble_name ((FILE), (NAME)); \
fprintf ((FILE), "\n\t.block "HOST_WIDE_INT_PRINT_UNSIGNED"\n", \
(unsigned HOST_WIDE_INT)(SIZE)); \
} while (0)
#undef TARGET_ASM_GLOBALIZE_LABEL
#define GLOBAL_ASM_OP "\t.globl\t"
#undef ASM_DECLARE_FUNCTION_NAME
#define ASM_DECLARE_FUNCTION_NAME(FILE, NAME, DECL) \
do { \
ASM_OUTPUT_TYPE_DIRECTIVE (FILE, NAME, "function"); \
ASM_DECLARE_RESULT (FILE, DECL_RESULT (DECL)); \
} while (0)
#define ASM_OUTPUT_EXTERNAL(FILE, DECL, NAME) \
do { \
int save_referenced; \
save_referenced = TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (DECL));\
if (FUNCTION_NAME_P (NAME)) \
ASM_OUTPUT_TYPE_DIRECTIVE (FILE, NAME, "function"); \
else \
ASM_OUTPUT_TYPE_DIRECTIVE (FILE, NAME, "object"); \
TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME (DECL)) = save_referenced;\
} while (0)
#undef ASM_OUTPUT_EXTERNAL_LIBCALL
#define ASM_OUTPUT_EXTERNAL_LIBCALL(FILE, FUN) \
do { \
if (!FUNCTION_NAME_P (XSTR (FUN, 0))) \
hppa_encode_label (FUN); \
ASM_OUTPUT_TYPE_DIRECTIVE (FILE, XSTR (FUN, 0), "function"); \
} while (0)
#undef ASM_GENERATE_INTERNAL_LABEL
#define ASM_GENERATE_INTERNAL_LABEL(LABEL, PREFIX, NUM) \
sprintf (LABEL, "*%c$%s%04ld", (PREFIX)[0], (PREFIX) + 1, (long)(NUM))
#else
#define TARGET_GAS 0
#undef NEW_HP_ASSEMBLER
#define NEW_HP_ASSEMBLER 1
#define DWARF2_DEBUGGING_INFO 1
#define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
#define OBJECT_FORMAT_ELF
#undef TARGET_ASM_FILE_START
#define TARGET_ASM_FILE_START pa_hpux64_hpas_file_start
#undef TEXT_SECTION_ASM_OP
#define TEXT_SECTION_ASM_OP "\t.SUBSPA $CODE$\n"
#undef READONLY_DATA_SECTION_ASM_OP
#define READONLY_DATA_SECTION_ASM_OP "\t.SUBSPA $LIT$\n"
#undef DATA_SECTION_ASM_OP
#define DATA_SECTION_ASM_OP "\t.SUBSPA $DATA$\n"
#undef BSS_SECTION_ASM_OP
#define BSS_SECTION_ASM_OP "\t.SUBSPA $BSS$\n"
#undef CTORS_SECTION_ASM_OP
#define CTORS_SECTION_ASM_OP "\t.SUBSPA \\.ctors,QUAD=1,ALIGN=8,ACCESS=31"
#undef DTORS_SECTION_ASM_OP
#define DTORS_SECTION_ASM_OP "\t.SUBSPA \\.dtors,QUAD=1,ALIGN=8,ACCESS=31"
#define HP_INIT_ARRAY_SECTION_ASM_OP \
"\t.SUBSPA \\.init,QUAD=1,ALIGN=8,ACCESS=31"
#define GNU_INIT_ARRAY_SECTION_ASM_OP \
"\t.SUBSPA \\.init_array,QUAD=1,ALIGN=8,ACCESS=31"
#define HP_FINI_ARRAY_SECTION_ASM_OP \
"\t.SUBSPA \\.fini,QUAD=1,ALIGN=8,ACCESS=31"
#define GNU_FINI_ARRAY_SECTION_ASM_OP \
"\t.SUBSPA \\.fini_array,QUAD=1,ALIGN=8,ACCESS=31"
#endif
#undef HAS_INIT_SECTION
#undef LD_INIT_SWITCH
#undef LD_FINI_SWITCH
#undef STARTFILE_SPEC
#define STARTFILE_SPEC \
"%{!shared: %{!symbolic: crt0.o%s}} %{static:crtbeginT.o%s} \
%{!static:%{!shared:crtbegin.o%s} %{shared:crtbeginS.o%s}}"
#undef ENDFILE_SPEC
#define ENDFILE_SPEC "%{!shared:crtend.o%s} %{shared:crtendS.o%s}"
#undef INIT_SECTION_ASM_OP
#define INIT_SECTION_ASM_OP
#undef FINI_SECTION_ASM_OP
#define FINI_SECTION_ASM_OP
#undef CRT_CALL_STATIC_FUNCTION
#define CRT_CALL_STATIC_FUNCTION(SECTION_OP, FUNC)
#undef SUPPORTS_INIT_PRIORITY
#define SUPPORTS_INIT_PRIORITY (TARGET_GNU_LD ? 1 : 0)
#ifdef CRTSTUFFS_O
#define PA_CXA_FINALIZE_STUB \
extern void __cxa_finalize (void *) TARGET_ATTRIBUTE_WEAK; \
void \
__cxa_finalize (void *p __attribute__((unused))) {}
#else
#define PA_CXA_FINALIZE_STUB
#endif
#ifdef JCR_SECTION_NAME
#define PA_JV_REGISTERCLASSES_STUB \
void \
_Jv_RegisterClasses (void *p __attribute__((unused))) {}
#else
#define PA_JV_REGISTERCLASSES_STUB
#endif
#if defined(EH_FRAME_SECTION_NAME) || defined(JCR_SECTION_NAME)
#define PA_INIT_FRAME_DUMMY_ASM_OP ".dword P%frame_dummy"
#else
#define PA_INIT_FRAME_DUMMY_ASM_OP ""
#endif
#define PA_INIT_FINI_HACK \
static void __attribute__((used)) \
__do_global_ctors_aux (void) \
{ \
func_ptr *p = __CTOR_LIST__; \
while (*(p + 1)) \
p++; \
for (; *p != (func_ptr) -1; p--) \
(*p) (); \
} \
\
PA_CXA_FINALIZE_STUB \
PA_JV_REGISTERCLASSES_STUB \
\
asm (HP_INIT_ARRAY_SECTION_ASM_OP); \
asm (".dword P%__do_global_ctors_aux"); \
asm (PA_INIT_FRAME_DUMMY_ASM_OP); \
asm (GNU_INIT_ARRAY_SECTION_ASM_OP); \
asm (".dword P%__do_global_ctors_aux"); \
asm (PA_INIT_FRAME_DUMMY_ASM_OP); \
asm (HP_FINI_ARRAY_SECTION_ASM_OP); \
asm (".dword P%__do_global_dtors_aux"); \
asm (GNU_FINI_ARRAY_SECTION_ASM_OP); \
asm (".dword P%__do_global_dtors_aux")
#ifdef DTORS_SECTION_ASM_OP
#define DTOR_LIST_BEGIN \
asm (DTORS_SECTION_ASM_OP); \
STATIC func_ptr __DTOR_LIST__[1] \
__attribute__ ((aligned(sizeof(func_ptr)))) \
= { (func_ptr) (-1) }; \
PA_INIT_FINI_HACK
#else
#define DTOR_LIST_BEGIN \
STATIC func_ptr __DTOR_LIST__[1] \
__attribute__ ((section(".dtors"), aligned(sizeof(func_ptr)))) \
= { (func_ptr) (-1) }; \
PA_INIT_FINI_HACK
#endif
#define INIT_ENVIRONMENT "LD_PXDB=/usr/ccs/bin/size"
#define GTHREAD_USE_WEAK 0