1 /* Core target definitions for GNU compiler
2 for IBM RS/6000 PowerPC targeted to embedded ELF systems.
3 Copyright (C) 1995, 1996 Free Software Foundation, Inc.
4 Contributed by Cygnus Support.
6 This file is part of GNU CC.
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)
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.
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. */
23 #include "rs6000/sysv4.h"
25 /* For now, make stabs the default debugging type, not dwarf. */
26 #undef PREFERRED_DEBUGGING_TYPE
27 #define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
29 /* Make int foo : 8 not cause structures to be aligned to an int boundary */
31 #undef PCC_BITFIELD_TYPE_MATTERS
32 #define PCC_BITFIELD_TYPE_MATTERS (TARGET_BITFIELD_TYPE)
34 /* Define this macro to be the value 1 if instructions will fail to
35 work if given data not on the nominal alignment. If instructions
36 will merely go slower in that case, define this macro as 0.
38 Note, little endian systems trap on unaligned addresses, so never
39 turn off strict alignment in that case. */
40 #undef STRICT_ALIGNMENT
41 #define STRICT_ALIGNMENT (TARGET_STRICT_ALIGN || TARGET_LITTLE_ENDIAN)
43 /* Align stack to 8 byte boundaries, rather than 16 bytes Sys V.4 uses */
45 #define STACK_BOUNDARY 64
47 /* No data type wants to be aligned rounder than this. */
48 #undef BIGGEST_ALIGNMENT
49 #define BIGGEST_ALIGNMENT 64
51 /* Put PC relative got entries in .got2 */
52 #undef MINIMAL_TOC_SECTION_ASM_OP
53 #define MINIMAL_TOC_SECTION_ASM_OP \
54 ((TARGET_RELOCATABLE) ? "\t.section\t\".got2\",\"aw\"" : "\t.section\t\".got1\",\"aw\"")
56 /* Put relocatable data in .data, not .rodata so initialized pointers can be updated */
57 #undef CONST_SECTION_ASM_OP
58 #define CONST_SECTION_ASM_OP \
59 ((TARGET_RELOCATABLE) ? "\t.section\t\".data\"\t# .rodata" : "\t.section\t\".rodata\"")
61 /* Invoke an initializer function to set up the GOT */
62 #define NAME__MAIN "__eabi"
65 #define TARGET_VERSION fprintf (stderr, " (PowerPC Embedded)");
68 #define CPP_PREDEFINES \
69 "-DPPC -D__embedded__ -Asystem(embedded) -Acpu(powerpc) -Amachine(powerpc)"
71 /* Clue the simulator in to use netbsd */
72 #undef LINK_START_SPEC
73 #define LINK_START_SPEC "%{msim: %{!Ttext*: -Ttext 0x10000074}}"
75 /* Use the simulator crt0 or mvme and libgloss/newlib libraries if desired */
77 #define STARTFILE_SPEC "crti.o%s \
78 %{mmvme: mvme-crt0.o%s} \
79 %{msim: sim-crt0.o%s}"
83 %{mmvme: -lmvme -lc -lmvme} \
84 %{msim: -lsim -lc -lsim}"
87 #define LIBGCC_SPEC "libgcc.a%s"
90 #define ENDFILE_SPEC "crtn.o%s"