OSDN Git Service

* config.gcc (s390-*-linux-*, s390x-*-linux*): Switch to
[pf3gnuchains/gcc-fork.git] / gcc / config / s390 / linux64.h
1 /* Definitions for Linux for s/390 zSeries
2    Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
3    Contributed by Hartmut Penner (hpenner@de.ibm.com) and
4                   Ulrich Weigand (uweigand@de.ibm.com).
5 This file is part of GNU CC.
6
7 GNU CC is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2, or (at your option)
10 any later version.
11
12 GNU CC is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with GNU CC; see the file COPYING.  If not, write to
19 the Free Software Foundation, 59 Temple Place - Suite 330,
20 Boston, MA 02111-1307, USA.  */
21
22 #ifndef _LINUX64_H
23 #define _LINUX64_H
24
25 #undef PTRDIFF_TYPE
26 #define PTRDIFF_TYPE "long int"
27
28 #undef TARGET_DEFAULT
29 #define TARGET_DEFAULT             0x13
30
31 #undef TARGET_VERSION
32 #define TARGET_VERSION fprintf (stderr, " (Linux for S/390 zSeries 64 bit)");
33
34 /* Names to predefine in the preprocessor for this target machine.  */
35
36 #undef CPP_PREDEFINES
37 #define CPP_PREDEFINES \
38   "-Dlinux -Asystem(linux) -Acpu(s390) -Amachine(s390) -D__s390__ -D__s390x__ \
39    -Asystem(unix) -Dunix -D__ELF__ \
40    -D__LONG_MAX__=9223372036854775807L"
41
42 #undef  LINK_SPEC
43 #ifdef CROSS_COMPILE
44 #define LINK_SPEC "-m elf64_s390 %{shared:-shared} \
45   %{!shared: \
46     %{!ibcs: \
47       %{!static: \
48         %{rdynamic:-export-dynamic} \
49         %{!dynamic-linker:-dynamic-linker /lib/ld64.so.1 \
50         -rpath-link=/usr/local/s390x-ibm-linux/lib}} \
51         %{static:-static}}}"
52 #else
53 #define LINK_SPEC "-m elf64_s390 %{shared:-shared} \
54   %{!shared: \
55     %{!ibcs: \
56       %{!static: \
57         %{rdynamic:-export-dynamic} \
58         %{!dynamic-linker:-dynamic-linker /lib/ld64.so.1}} \
59         %{static:-static}}}"
60 #endif
61
62 #undef INT_ASM_OP
63 #define INT_ASM_OP "\t.quad\t"
64
65 #undef PROMOTE_PROTOTYPES 
66 #undef MASK_RETURN_ADDR 
67 #undef SELECT_SECTION
68
69 /* With 64 bit new linkage for floating point registers.  */
70 #undef CALL_USED_REGISTERS                      
71 #define CALL_USED_REGISTERS                     \
72 { 1, 1, 1, 1,                                   \
73   1, 1, 0, 0,                                   \
74   0, 0, 0, 0,                                   \
75   0, 1, 1, 1,                                   \
76   1, 1, 1, 1,                                   \
77   1, 1, 1, 1,                                   \
78   0, 0, 0, 0,                                   \
79   0, 0, 0, 0,                                   \
80   1, 1 }
81
82 #endif