Some cleaning up, triggered by alpha.

- TARGET_CPU_DEFAULT belongs in configure.in, not in various .h files.
If it goes out wrong, it's the output of uname that needs to be fixed
(or config.guess, e.g., even pentium gives out i386, as intended). Makes
it possible to configure a i586-unknown-openbsd system if one really WANTS
to output only pentium specific code.

- ASM_FILE_START put into alpha/openbsd.h. Used to be in alpha.h, but
elf & osf diverged...

- set xfrag=none for alpha, as the default config is bogus and supplies
a dec-osf specific xalpha.
This commit is contained in:
espie 1999-01-11 21:23:25 +00:00
parent aadacc7c85
commit 1237398b0a
8 changed files with 92 additions and 46 deletions

View File

@ -1,12 +1,10 @@
/* $OpenBSD: openbsd.h,v 1.1 1999/01/10 02:50:05 espie Exp $ */
/* $OpenBSD: openbsd.h,v 1.2 1999/01/11 21:23:25 espie Exp $ */
/* vi:ts=8:
*/
/* We settle for little endian for now */
#define TARGET_ENDIAN_DEFAULT 0
#define TARGET_DEFAULT (MASK_GAS | MASK_FP | MASK_FPREGS)
#include <alpha/alpha.h>
#define OBSD_NO_DYNAMIC_LIBRARIES
@ -40,3 +38,27 @@
/* We don't have an init section yet */
#undef HAS_INIT_SECTION
/* taken from alpha/osf.h. This used to be common to all alpha
* configurations, but elf has departed from it.
* Check alpha/alpha.h, alpha/osf.h for it when egcs is upgraded.
*/
#ifndef ASM_FILE_START
#define ASM_FILE_START(FILE) \
{ \
alpha_write_verstamp (FILE); \
fprintf (FILE, "\t.set noreorder\n"); \
fprintf (FILE, "\t.set volatile\n"); \
fprintf (FILE, "\t.set noat\n"); \
if (TARGET_SUPPORT_ARCH) \
fprintf (FILE, "\t.arch %s\n", \
alpha_cpu == PROCESSOR_EV6 ? "ev6" \
: (alpha_cpu == PROCESSOR_EV5 \
? (TARGET_MAX ? "pca56" : TARGET_BWX ? "ev56" : "ev5") \
: "ev4")); \
\
ASM_OUTPUT_SOURCE_FILENAME (FILE, main_input_filename); \
}
#endif

View File

@ -1,10 +1,7 @@
/* $OpenBSD: openbsd.h,v 1.3 1999/01/10 02:50:05 espie Exp $ */
/* $OpenBSD: openbsd.h,v 1.4 1999/01/11 21:23:26 espie Exp $ */
/* vi:ts=8:
*/
/* This should go away when the math-emulator is fixed */
#define TARGET_CPU_DEFAULT TARGET_NO_FANCY_MATH_387
/* This is tested by i386gas.h. */
#define YES_UNDERSCORES

View File

@ -1,7 +1,9 @@
/* $OpenBSD: openbsd.h,v 1.2 1999/01/10 02:50:06 espie Exp $ */
/* $OpenBSD: openbsd.h,v 1.3 1999/01/11 21:23:27 espie Exp $ */
/* vi:ts=8:
*/
/* m68k is an old configuration that does not use the TARGET_CPU_DEFAULT
* framework. */
#define TARGET_DEFAULT (MASK_BITFIELD | MASK_68881 | MASK_68020)
#include <m68k/m68k.h>

View File

@ -1,5 +1,5 @@
--- gcc/configure.in.orig Thu Dec 17 22:09:07 1998
+++ gcc/configure.in Mon Dec 28 23:03:47 1998
--- gcc/configure.in.orig Wed Dec 30 23:05:07 1998
+++ gcc/configure.in Mon Jan 11 22:08:12 1999
@@ -497,11 +497,19 @@
tm_file=${cpu_type}/${cpu_type}.h
xm_file=${cpu_type}/xm-${cpu_type}.h
@ -21,19 +21,20 @@
esac
case $machine in
@@ -581,6 +589,11 @@
@@ -581,6 +589,12 @@
fixincludes=fixinc.wrap
gas=yes gnu_ld=yes
;;
+
+ alpha*-*-openbsd*)
+ # nothing special
+ # default x-alpha is only appropriate for dec-osf.
+ target_cpu_default="MASK_GAS"
+ xmake_file=none
+ ;;
+
alpha*-dec-osf*)
if test x$stabs = xyes
@@ -771,6 +784,9 @@
@@ -771,6 +785,9 @@
h8300-*-*)
float_format=i32
;;
@ -43,7 +44,7 @@
hppa1.1-*-pro*)
tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h"
xm_file=pa/xm-papro.h
@@ -1096,10 +1112,8 @@
@@ -1097,10 +1114,8 @@
fixincludes=fixinc.wrap
tmake_file=i386/t-freebsd
;;
@ -55,19 +56,20 @@
changequote([,])dnl
tm_file=i386/netbsd.h
# On NetBSD, the headers are already okay, except for math.h.
@@ -1107,6 +1121,11 @@
@@ -1108,6 +1123,12 @@
tmake_file=t-netbsd
;;
changequote(,)dnl
+ i[34567]86-*-openbsd*)
+changequote([,])dnl
+ # nothing special
+ # Remove when the math emulator is fixed
+ target_cpu_default="TARGET_NO_FANCY_MATCH_387"
+ ;;
+changequote(,)dnl
i[34567]86-*-coff*)
changequote([,])dnl
tm_file=i386/i386-coff.h
@@ -1967,6 +1986,9 @@
@@ -1968,6 +1989,9 @@
tmake_file=t-netbsd
float_format=m68k
;;
@ -77,7 +79,7 @@
m68k-*-sysv3*) # Motorola m68k's running system V.3
xm_file="xm-alloca.h ${xm_file}"
xm_defines=USG
@@ -2298,6 +2320,12 @@
@@ -2299,6 +2323,12 @@
gas=yes
fixincludes=Makefile.in
;;
@ -90,7 +92,7 @@
mips-sony-bsd* | mips-sony-newsos*) # Sony NEWS 3600 or risc/news.
tm_file="mips/news4.h ${tm_file}"
if test x$stabs = xyes; then
@@ -2648,6 +2676,9 @@
@@ -2649,6 +2679,9 @@
;;
pdp11-*-*)
;;
@ -100,7 +102,7 @@
pyramid-*-*)
cpu_type=pyr
xmake_file=pyr/x-pyr
@@ -2660,6 +2691,12 @@
@@ -2661,6 +2694,12 @@
xmake_file=romp/x-mach
use_collect2=yes
;;
@ -113,7 +115,7 @@
powerpc-*-beos*)
cpu_type=rs6000
tm_file=rs6000/beos.h
@@ -2949,6 +2986,9 @@
@@ -2950,6 +2989,9 @@
fixincludes=fixinc.wrap
tmake_file=t-netbsd
;;
@ -123,7 +125,7 @@
sparc-*-bsd*)
tm_file=sparc/bsd.h
;;
@@ -3167,6 +3207,9 @@
@@ -3168,6 +3210,9 @@
fixincludes=fixinc.wrap
tmake_file=t-netbsd
float_format=vax

View File

@ -1,12 +1,10 @@
/* $OpenBSD: openbsd.h,v 1.1 1999/01/10 02:50:05 espie Exp $ */
/* $OpenBSD: openbsd.h,v 1.2 1999/01/11 21:23:25 espie Exp $ */
/* vi:ts=8:
*/
/* We settle for little endian for now */
#define TARGET_ENDIAN_DEFAULT 0
#define TARGET_DEFAULT (MASK_GAS | MASK_FP | MASK_FPREGS)
#include <alpha/alpha.h>
#define OBSD_NO_DYNAMIC_LIBRARIES
@ -40,3 +38,27 @@
/* We don't have an init section yet */
#undef HAS_INIT_SECTION
/* taken from alpha/osf.h. This used to be common to all alpha
* configurations, but elf has departed from it.
* Check alpha/alpha.h, alpha/osf.h for it when egcs is upgraded.
*/
#ifndef ASM_FILE_START
#define ASM_FILE_START(FILE) \
{ \
alpha_write_verstamp (FILE); \
fprintf (FILE, "\t.set noreorder\n"); \
fprintf (FILE, "\t.set volatile\n"); \
fprintf (FILE, "\t.set noat\n"); \
if (TARGET_SUPPORT_ARCH) \
fprintf (FILE, "\t.arch %s\n", \
alpha_cpu == PROCESSOR_EV6 ? "ev6" \
: (alpha_cpu == PROCESSOR_EV5 \
? (TARGET_MAX ? "pca56" : TARGET_BWX ? "ev56" : "ev5") \
: "ev4")); \
\
ASM_OUTPUT_SOURCE_FILENAME (FILE, main_input_filename); \
}
#endif

View File

@ -1,10 +1,7 @@
/* $OpenBSD: openbsd.h,v 1.3 1999/01/10 02:50:05 espie Exp $ */
/* $OpenBSD: openbsd.h,v 1.4 1999/01/11 21:23:26 espie Exp $ */
/* vi:ts=8:
*/
/* This should go away when the math-emulator is fixed */
#define TARGET_CPU_DEFAULT TARGET_NO_FANCY_MATH_387
/* This is tested by i386gas.h. */
#define YES_UNDERSCORES

View File

@ -1,7 +1,9 @@
/* $OpenBSD: openbsd.h,v 1.2 1999/01/10 02:50:06 espie Exp $ */
/* $OpenBSD: openbsd.h,v 1.3 1999/01/11 21:23:27 espie Exp $ */
/* vi:ts=8:
*/
/* m68k is an old configuration that does not use the TARGET_CPU_DEFAULT
* framework. */
#define TARGET_DEFAULT (MASK_BITFIELD | MASK_68881 | MASK_68020)
#include <m68k/m68k.h>

View File

@ -1,5 +1,5 @@
--- gcc/configure.in.orig Thu Dec 17 22:09:07 1998
+++ gcc/configure.in Mon Dec 28 23:03:47 1998
--- gcc/configure.in.orig Wed Dec 30 23:05:07 1998
+++ gcc/configure.in Mon Jan 11 22:08:12 1999
@@ -497,11 +497,19 @@
tm_file=${cpu_type}/${cpu_type}.h
xm_file=${cpu_type}/xm-${cpu_type}.h
@ -21,19 +21,20 @@
esac
case $machine in
@@ -581,6 +589,11 @@
@@ -581,6 +589,12 @@
fixincludes=fixinc.wrap
gas=yes gnu_ld=yes
;;
+
+ alpha*-*-openbsd*)
+ # nothing special
+ # default x-alpha is only appropriate for dec-osf.
+ target_cpu_default="MASK_GAS"
+ xmake_file=none
+ ;;
+
alpha*-dec-osf*)
if test x$stabs = xyes
@@ -771,6 +784,9 @@
@@ -771,6 +785,9 @@
h8300-*-*)
float_format=i32
;;
@ -43,7 +44,7 @@
hppa1.1-*-pro*)
tm_file="pa/pa-pro.h ${tm_file} pa/pa-pro-end.h libgloss.h"
xm_file=pa/xm-papro.h
@@ -1096,10 +1112,8 @@
@@ -1097,10 +1114,8 @@
fixincludes=fixinc.wrap
tmake_file=i386/t-freebsd
;;
@ -55,19 +56,20 @@
changequote([,])dnl
tm_file=i386/netbsd.h
# On NetBSD, the headers are already okay, except for math.h.
@@ -1107,6 +1121,11 @@
@@ -1108,6 +1123,12 @@
tmake_file=t-netbsd
;;
changequote(,)dnl
+ i[34567]86-*-openbsd*)
+changequote([,])dnl
+ # nothing special
+ # Remove when the math emulator is fixed
+ target_cpu_default="TARGET_NO_FANCY_MATCH_387"
+ ;;
+changequote(,)dnl
i[34567]86-*-coff*)
changequote([,])dnl
tm_file=i386/i386-coff.h
@@ -1967,6 +1986,9 @@
@@ -1968,6 +1989,9 @@
tmake_file=t-netbsd
float_format=m68k
;;
@ -77,7 +79,7 @@
m68k-*-sysv3*) # Motorola m68k's running system V.3
xm_file="xm-alloca.h ${xm_file}"
xm_defines=USG
@@ -2298,6 +2320,12 @@
@@ -2299,6 +2323,12 @@
gas=yes
fixincludes=Makefile.in
;;
@ -90,7 +92,7 @@
mips-sony-bsd* | mips-sony-newsos*) # Sony NEWS 3600 or risc/news.
tm_file="mips/news4.h ${tm_file}"
if test x$stabs = xyes; then
@@ -2648,6 +2676,9 @@
@@ -2649,6 +2679,9 @@
;;
pdp11-*-*)
;;
@ -100,7 +102,7 @@
pyramid-*-*)
cpu_type=pyr
xmake_file=pyr/x-pyr
@@ -2660,6 +2691,12 @@
@@ -2661,6 +2694,12 @@
xmake_file=romp/x-mach
use_collect2=yes
;;
@ -113,7 +115,7 @@
powerpc-*-beos*)
cpu_type=rs6000
tm_file=rs6000/beos.h
@@ -2949,6 +2986,9 @@
@@ -2950,6 +2989,9 @@
fixincludes=fixinc.wrap
tmake_file=t-netbsd
;;
@ -123,7 +125,7 @@
sparc-*-bsd*)
tm_file=sparc/bsd.h
;;
@@ -3167,6 +3207,9 @@
@@ -3168,6 +3210,9 @@
fixincludes=fixinc.wrap
tmake_file=t-netbsd
float_format=vax