merge selected patches from milepost-integration:
[official-gcc.git] / gcc / config / m68k / m68kemb.h
blob5d917f91c4ce0355ac5aca8ab348c4c1d2f0987f
1 /* Definitions of target machine for GNU compiler. "embedded" 68XXX.
2 This is meant to be included after m68k.h.
3 Copyright (C) 1994, 1995, 1998, 1999, 2004, 2006
4 Free Software Foundation, Inc. */
6 /* Override the SVR4 ABI for this target. */
8 #define PTRDIFF_TYPE "long int"
9 #define SIZE_TYPE "long unsigned int"
11 /* In order for bitfields to work on a 68000, or with -mnobitfield, we must
12 define either PCC_BITFIELD_TYPE_MATTERS or STRUCTURE_SIZE_BOUNDARY.
13 Defining STRUCTURE_SIZE_BOUNDARY results in structure packing problems,
14 so we define PCC_BITFIELD_TYPE_MATTERS. */
15 #define PCC_BITFIELD_TYPE_MATTERS 1
17 /* Don't default to pcc-struct-return, so that we can return small structures
18 and unions in registers, which is slightly more efficient. */
19 #define DEFAULT_PCC_STRUCT_RETURN 0
21 #undef FUNCTION_VALUE
22 #define FUNCTION_VALUE(VALTYPE,FUNC) LIBCALL_VALUE (TYPE_MODE (VALTYPE))
24 #undef LIBCALL_VALUE
25 #define LIBCALL_VALUE(MODE) \
26 m68k_libcall_value (MODE)
28 #undef FUNCTION_VALUE_REGNO_P
29 #define FUNCTION_VALUE_REGNO_P(N) \
30 ((N) == D0_REG || (TARGET_68881 && (N) == FP0_REG))
32 #undef NEEDS_UNTYPED_CALL
33 #define NEEDS_UNTYPED_CALL 1
35 /* Target OS builtins. */
36 #define TARGET_OS_CPP_BUILTINS() \
37 do \
38 { \
39 builtin_define ("__embedded__"); \
40 } \
41 while (0)
43 /* Override the default LIB_SPEC from gcc.c. We don't currently support
44 profiling, or libg.a. */
46 #undef LIB_SPEC
47 #define LIB_SPEC "-lc"
49 /* Make this be null, since we want the crt0.o to come from the linker
50 script */
52 #undef STARTFILE_SPEC
53 #define STARTFILE_SPEC ""