OSDN Git Service

c9df25bc818a9525a5d8d1c8f970a7f4aa4e5988
[pf3gnuchains/gcc-fork.git] / gcc / config / ia64 / hpux.h
1 /* Definitions of target machine GNU compiler.  IA-64 version.
2    Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
3    Contributed by Steve Ellcey <sje@cup.hp.com> and
4                   Reva Cuthbertson <reva@cup.hp.com>
5
6 This file is part of GNU CC.
7
8 GNU CC is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2, or (at your option)
11 any later version.
12
13 GNU CC is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with GNU CC; see the file COPYING.  If not, write to
20 the Free Software Foundation, 59 Temple Place - Suite 330,
21 Boston, MA 02111-1307, USA.  */
22
23 #undef CPP_PREDEFINES
24 #define CPP_PREDEFINES "\
25   -D__IA64__ -D__ia64 -D__ia64__ -D__hpux -D__hpux__ -Dhpux -Dunix \
26   -D__BIG_ENDIAN__ -D_LONGLONG -D__ELF__ \
27   -Asystem=hpux -Asystem=posix -Asystem=unix -Acpu=ia64 -Amachine=ia64 \
28   -D_UINT128_T"
29
30 /* -D__fpreg=long double is needed to compensate for the lack of __fpreg
31    which is a primitive type in HP C but does not exist in GNU C.  Same
32    for __float80 and __float128.  These types appear in HP-UX header
33    files and so must have some definition.  */
34
35 #undef CPP_SPEC
36 #define CPP_SPEC "\
37   %{mcpu=itanium:-D__itanium__} \
38   %{mlp64:-D__LP64__ -D__LONG_MAX__=9223372036854775807L} \
39   %{!ansi:%{!std=c*:%{!std=i*: -D_HPUX_SOURCE -D__STDC_EXT__}}} \
40   -D__fpreg=long\\ double \
41   -D__float80=long\\ double \
42   -D__float128=long\\ double"
43
44 #undef ASM_SPEC
45 #define ASM_SPEC "-x %{mconstant-gp} %{mauto-pic} \
46   %{milp32:-milp32} %{mlp64:-mlp64}"
47
48 #undef ENDFILE_SPEC
49
50 #undef STARTFILE_SPEC
51 #ifdef CROSS_COMPILE
52 #define STARTFILE_SPEC "%{!shared:crt0%O%s}"
53 #else
54 #define STARTFILE_SPEC "/usr/ccs/lib/hpux64/crt0%O"
55 #endif
56
57 #undef LINK_SPEC
58 #define LINK_SPEC "\
59   +Accept TypeMismatch \
60   %{shared:-b} \
61   %{!shared: \
62     -u main \
63     %{!static: \
64       %{rdynamic:-export-dynamic}} \
65       %{static:-static}}"
66
67 #undef  LIB_SPEC
68 #define LIB_SPEC "%{!shared:%{!symbolic:-lc}}"
69
70 #undef SUBTARGET_SWITCHES
71 #define SUBTARGET_SWITCHES \
72   { "ilp32",    MASK_ILP32,     "Generate ILP32 code" }, \
73   { "lp64",    -MASK_ILP32,     "Generate LP64 code" },
74
75 /* A C expression whose value is zero if pointers that need to be extended
76    from being `POINTER_SIZE' bits wide to `Pmode' are sign-extended and
77    greater then zero if they are zero-extended and less then zero if the
78    ptr_extend instruction should be used.  */
79
80 #define POINTERS_EXTEND_UNSIGNED -1
81
82 #define DONT_USE_BUILTIN_SETJMP
83 #define JMP_BUF_SIZE  (8 * 76)
84
85 #undef CONST_SECTION_ASM_OP
86 #define CONST_SECTION_ASM_OP    "\t.section\t.rodata,\t\"a\",\t\"progbits\""
87
88 #undef BITS_BIG_ENDIAN
89 #define BITS_BIG_ENDIAN 1
90
91 #undef TARGET_DEFAULT
92 #define TARGET_DEFAULT (MASK_DWARF2_ASM | MASK_BIG_ENDIAN)