]> gcc.gnu.org Git - gcc.git/blob - gcc/config/i386/sco.h
Added arg to RETURN_POPS_ARGS.
[gcc.git] / gcc / config / i386 / sco.h
1 /* Definitions for Intel 386 running SCO Unix System V.
2 Copyright (C) 1988, 1992, 1994, 1995 Free Software Foundation, Inc.
3
4 This file is part of GNU CC.
5
6 GNU CC is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2, or (at your option)
9 any later version.
10
11 GNU CC is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with GNU CC; see the file COPYING. If not, write to
18 the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
19
20 /* Mostly it's like AT&T Unix System V. */
21
22 #include "i386/sysv3.h"
23
24 /* By default, target has a 80387, uses IEEE compatible arithmetic,
25 and returns float values in the 387, ie,
26 (TARGET_80387 | TARGET_FLOAT_RETURNS_IN_80387)
27
28 SCO's software emulation of a 387 fails to handle the `fucomp'
29 opcode. fucomp is only used when generating IEEE compliant code.
30 So don't make TARGET_IEEE_FP default for SCO. */
31
32 #undef TARGET_DEFAULT
33 #define TARGET_DEFAULT 0201
34
35 /* Let's guess that the SCO software FPU emulator can't handle
36 80-bit XFmode insns, so don't generate them. */
37 #undef LONG_DOUBLE_TYPE_SIZE
38 #define LONG_DOUBLE_TYPE_SIZE 64
39
40 /* Use crt1.o as a startup file and crtn.o as a closing file. */
41
42 #undef STARTFILE_SPEC
43 #define STARTFILE_SPEC \
44 "%{pg:gcrt1.o%s}%{!pg:%{p:mcrt1.o%s}%{!p:crt1.o%s}} crtbegin.o%s"
45
46 #define ENDFILE_SPEC "crtend.o%s crtn.o%s"
47
48 /* Library spec, including SCO international language support. */
49
50 #undef LIB_SPEC
51 #define LIB_SPEC \
52 "%{p:-L/usr/lib/libp}%{pg:-L/usr/lib/libp} %{scointl:libintl.a%s} -lc"
53
54 /* Specify predefined symbols in preprocessor. */
55
56 #undef CPP_PREDEFINES
57 #define CPP_PREDEFINES "-Dunix -Di386 -DM_UNIX -DM_I386 -DM_COFF -DM_WORDSWAP -Asystem(unix) -Asystem(svr3) -Acpu(i386) -Amachine(i386)"
58
59 #undef CPP_SPEC
60 #define CPP_SPEC "%{scointl:-DM_INTERNAT}"
61
62 /* This spec is used for telling cpp whether char is signed or not. */
63
64 #undef SIGNED_CHAR_SPEC
65 #if DEFAULT_SIGNED_CHAR
66 #define SIGNED_CHAR_SPEC \
67 "%{funsigned-char:-D__CHAR_UNSIGNED__ -D_CHAR_UNSIGNED}"
68 #else
69 #define SIGNED_CHAR_SPEC \
70 "%{!fsigned-char:-D__CHAR_UNSIGNED__ -D_CHAR_UNSIGNED}"
71 #endif
72
73 /* Use atexit for static destructors, instead of defining
74 our own exit function. */
75 #define HAVE_ATEXIT
76
77 /* Specify the size_t type. */
78 #define SIZE_TYPE "unsigned int"
79
80 #if 0 /* Not yet certain whether this is needed. */
81 /* If no 387, use the general regs to return floating values,
82 since this system does not emulate the 80387. */
83
84 #undef VALUE_REGNO
85 #define VALUE_REGNO(MODE) \
86 ((TARGET_80387
87 && ((MODE) == SFmode || (MODE) == DFmode || (MODE) == XFmode)
88 ? FIRST_FLOAT_REG : 0)
89
90 #undef HARD_REGNO_MODE_OK
91 #define HARD_REGNO_MODE_OK(REGNO, MODE) \
92 ((REGNO) < 2 ? 1 \
93 : (REGNO) < 4 ? 1 \
94 : FP_REGNO_P (REGNO) ? ((GET_MODE_CLASS (MODE) == MODE_FLOAT \
95 || GET_MODE_CLASS (MODE) == MODE_COMPLEX_FLOAT) \
96 && TARGET_80387 \
97 && GET_MODE_UNIT_SIZE (MODE) <= 8) \
98 : (MODE) != QImode)
99 #endif
100
101 /* caller has to pop the extra argument passed to functions that return
102 structures. */
103
104 #undef RETURN_POPS_ARGS
105 #define RETURN_POPS_ARGS(FUNDECL,FUNTYPE,SIZE) \
106 (TREE_CODE (FUNTYPE) == IDENTIFIER_NODE ? 0 \
107 : (TARGET_RTD \
108 && (TYPE_ARG_TYPES (FUNTYPE) == 0 \
109 || (TREE_VALUE (tree_last (TYPE_ARG_TYPES (FUNTYPE))) \
110 == void_type_node))) ? (SIZE) \
111 : 0)
112 /* On other 386 systems, the last line looks like this:
113 : (aggregate_value_p (TREE_TYPE (FUNTYPE))) ? GET_MODE_SIZE (Pmode) : 0) */
114
115 /* Handle #pragma pack. */
116 #define HANDLE_SYSV_PRAGMA
This page took 0.040919 seconds and 5 git commands to generate.