Commit 25f94bb5 by Jan Hubicka Committed by Jan Hubicka

i386.h (MASK_64BIT): New constant.

	* i386.h (MASK_64BIT): New constant.
	(TARGET_64BIT): New macro.
	(TARGET_OPTIONS): Add '64'/'32'
	(TARGET_DEFAULT): Define.
	* cygwin.h freebsd-aout.h i386-interix.h i386.h i386elf.h isc.h isccoff.h
	netbsd.h next.h openbsd.h p sco.h sco5.h scodbx.h sequent.h unix.h win32.h
	(TARGET_DEFAULT): Rename to TARGET_SUBTARGET_DEFAULT.

From-SVN: r40345
parent b891e06c
Fri Mar 9 17:38:08 CET 2001 Jan Hubicka <jh@suse.cz>
* i386.h (mask_64bit): New constant.
(target_64bit): New macro.
(target_options): Add '64'/'32'
(target_default): Define.
* cygwin.h freebsd-aout.h i386-interix.h i386.h i386elf.h isc.h
isccoff.h netbsd.h next.h openbsd.h p sco.h sco5.h scodbx.h sequent.h
unix.h win32.h (TARGET_DEFAULT): Rename to TARGET_SUBTARGET_DEFAULT.
Thu Mar 8 23:36:56 2001 Jeffrey A Law (law@cygnus.com) Thu Mar 8 23:36:56 2001 Jeffrey A Law (law@cygnus.com)
* config/pa/som.h (MAKE_DECL_ONE_ONLY, ASM_WEAKEN_LABEL): Disable. * config/pa/som.h (MAKE_DECL_ONE_ONLY, ASM_WEAKEN_LABEL): Disable.
......
...@@ -391,9 +391,9 @@ do { \ ...@@ -391,9 +391,9 @@ do { \
/* By default, target has a 80387, uses IEEE compatible arithmetic, /* By default, target has a 80387, uses IEEE compatible arithmetic,
and returns float values in the 387 and needs stack probes */ and returns float values in the 387 and needs stack probes */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT \ #define TARGET_SUBTARGET_DEFAULT \
(MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE) (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE)
/* This is how to output an assembler line /* This is how to output an assembler line
......
...@@ -30,8 +30,8 @@ Boston, MA 02111-1307, USA. */ ...@@ -30,8 +30,8 @@ Boston, MA 02111-1307, USA. */
#include "i386/gstabs.h" #include "i386/gstabs.h"
/* This goes away when the math-emulator is fixed */ /* This goes away when the math-emulator is fixed */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT \ #define TARGET_SUBTARGET_DEFAULT \
(MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_NO_FANCY_MATH_387) (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_NO_FANCY_MATH_387)
#undef CPP_PREDEFINES #undef CPP_PREDEFINES
......
...@@ -40,8 +40,8 @@ Boston, MA 02111-1307, USA. */ ...@@ -40,8 +40,8 @@ Boston, MA 02111-1307, USA. */
/* By default, target has a 80387, uses IEEE compatible arithmetic, /* By default, target has a 80387, uses IEEE compatible arithmetic,
and returns float values in the 387 and needs stack probes and returns float values in the 387 and needs stack probes
We also align doubles to 64-bits for MSVC default compatability */ We also align doubles to 64-bits for MSVC default compatability */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT \ #define TARGET_SUBTARGET_DEFAULT \
(MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE | \ (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE | \
MASK_ALIGN_DOUBLE) MASK_ALIGN_DOUBLE)
......
...@@ -119,6 +119,7 @@ extern int target_flags; ...@@ -119,6 +119,7 @@ extern int target_flags;
#define MASK_SSE2 0x00040000 /* Support SSE2 regs/builtins */ #define MASK_SSE2 0x00040000 /* Support SSE2 regs/builtins */
#define MASK_128BIT_LONG_DOUBLE 0x00080000 /* long double size is 128bit */ #define MASK_128BIT_LONG_DOUBLE 0x00080000 /* long double size is 128bit */
#define MASK_MIX_SSE_I387 0x00100000 /* Mix SSE and i387 instructions */ #define MASK_MIX_SSE_I387 0x00100000 /* Mix SSE and i387 instructions */
#define MASK_64BIT 0x00200000 /* Produce 64bit code */
/* Temporary codegen switches */ /* Temporary codegen switches */
#define MASK_INTEL_SYNTAX 0x00000200 #define MASK_INTEL_SYNTAX 0x00000200
...@@ -178,6 +179,9 @@ extern int target_flags; ...@@ -178,6 +179,9 @@ extern int target_flags;
/* Debug FUNCTION_ARG macros */ /* Debug FUNCTION_ARG macros */
#define TARGET_DEBUG_ARG (target_flags & MASK_DEBUG_ARG) #define TARGET_DEBUG_ARG (target_flags & MASK_DEBUG_ARG)
/* 64bit Sledgehammer mode */
#define TARGET_64BIT (target_flags & MASK_64BIT)
#define TARGET_386 (ix86_cpu == PROCESSOR_I386) #define TARGET_386 (ix86_cpu == PROCESSOR_I386)
#define TARGET_486 (ix86_cpu == PROCESSOR_I486) #define TARGET_486 (ix86_cpu == PROCESSOR_I486)
#define TARGET_PENTIUM (ix86_cpu == PROCESSOR_PENTIUM) #define TARGET_PENTIUM (ix86_cpu == PROCESSOR_PENTIUM)
...@@ -330,9 +334,19 @@ extern const int x86_partial_reg_dependency, x86_memory_mismatch_stall; ...@@ -330,9 +334,19 @@ extern const int x86_partial_reg_dependency, x86_memory_mismatch_stall;
N_("sizeof(long double) is 16.") }, \ N_("sizeof(long double) is 16.") }, \
{ "96bit-long-double", -MASK_128BIT_LONG_DOUBLE, \ { "96bit-long-double", -MASK_128BIT_LONG_DOUBLE, \
N_("sizeof(long double) is 12.") }, \ N_("sizeof(long double) is 12.") }, \
{ "64", MASK_64BIT, \
N_("Generate 64bit x86-64 code") }, \
{ "32", -MASK_64BIT, \
N_("Generate 32bit i386 code") }, \
SUBTARGET_SWITCHES \ SUBTARGET_SWITCHES \
{ "", TARGET_DEFAULT, 0 }} { "", TARGET_DEFAULT, 0 }}
#ifdef TARGET_64BIT_DEFAULT
#define TARGET_DEFAULT (MASK_64BIT | TARGET_SUBTARGET_DEFAULT)
#else
#define TARGET_DEFAULT TARGET_SUBTARGET_DEFAULT
#endif
/* Which processor to schedule for. The cpu attribute defines a list that /* Which processor to schedule for. The cpu attribute defines a list that
mirrors this list, so changes to i386.md must be made at the same time. */ mirrors this list, so changes to i386.md must be made at the same time. */
......
...@@ -29,7 +29,7 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */ ...@@ -29,7 +29,7 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
/* By default, target has a 80387, uses IEEE compatible arithmetic, /* By default, target has a 80387, uses IEEE compatible arithmetic,
and returns float values in the 387. */ and returns float values in the 387. */
#define TARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS)
/* The ELF ABI for the i386 says that records and unions are returned /* The ELF ABI for the i386 says that records and unions are returned
in memory. */ in memory. */
......
...@@ -58,8 +58,8 @@ ...@@ -58,8 +58,8 @@
opcode. fucomp is only used when generating IEEE compliant code. opcode. fucomp is only used when generating IEEE compliant code.
So don't make TARGET_IEEE_FP default for ISC. */ So don't make TARGET_IEEE_FP default for ISC. */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS)
/* The ISC 2.0.2 software FPU emulator apparently can't handle /* The ISC 2.0.2 software FPU emulator apparently can't handle
80-bit XFmode insns, so don't generate them. */ 80-bit XFmode insns, so don't generate them. */
......
...@@ -10,8 +10,8 @@ ...@@ -10,8 +10,8 @@
#include <netbsd.h> #include <netbsd.h>
/* This goes away when the math-emulator is fixed */ /* This goes away when the math-emulator is fixed */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT \ #define TARGET_SUBTARGET_DEFAULT \
(MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_NO_FANCY_MATH_387) (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_NO_FANCY_MATH_387)
#undef CPP_PREDEFINES #undef CPP_PREDEFINES
......
...@@ -23,8 +23,8 @@ Boston, MA 02111-1307, USA. */ ...@@ -23,8 +23,8 @@ Boston, MA 02111-1307, USA. */
/* By default, target has a 80387, with IEEE FP. */ /* By default, target has a 80387, with IEEE FP. */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP)
/* Implicit library calls should use memcpy, not bcopy, etc. */ /* Implicit library calls should use memcpy, not bcopy, etc. */
......
...@@ -31,8 +31,8 @@ Boston, MA 02111-1307, USA. */ ...@@ -31,8 +31,8 @@ Boston, MA 02111-1307, USA. */
#include <openbsd.h> #include <openbsd.h>
/* This goes away when the math-emulator is fixed */ /* This goes away when the math-emulator is fixed */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT \ #define TARGET_SUBTARGET_DEFAULT \
(MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_NO_FANCY_MATH_387) (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_NO_FANCY_MATH_387)
/* Run-time target specifications */ /* Run-time target specifications */
......
...@@ -31,8 +31,8 @@ Boston, MA 02111-1307, USA. */ ...@@ -31,8 +31,8 @@ Boston, MA 02111-1307, USA. */
opcode. fucomp is only used when generating IEEE compliant code. opcode. fucomp is only used when generating IEEE compliant code.
So don't make TARGET_IEEE_FP default for SCO. */ So don't make TARGET_IEEE_FP default for SCO. */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS)
/* Let's guess that the SCO software FPU emulator can't handle /* Let's guess that the SCO software FPU emulator can't handle
80-bit XFmode insns, so don't generate them. */ 80-bit XFmode insns, so don't generate them. */
......
...@@ -708,8 +708,8 @@ dtors_section () \ ...@@ -708,8 +708,8 @@ dtors_section () \
&& strcmp (STR, "Tdata") && strcmp (STR, "Ttext") \ && strcmp (STR, "Tdata") && strcmp (STR, "Ttext") \
&& strcmp (STR, "Tbss")) && strcmp (STR, "Tbss"))
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS)
#undef HANDLE_SYSV_PRAGMA #undef HANDLE_SYSV_PRAGMA
#define HANDLE_SYSV_PRAGMA 1 #define HANDLE_SYSV_PRAGMA 1
......
...@@ -31,8 +31,8 @@ Boston, MA 02111-1307, USA. */ ...@@ -31,8 +31,8 @@ Boston, MA 02111-1307, USA. */
opcode. fucomp is only used when generating IEEE compliant code. opcode. fucomp is only used when generating IEEE compliant code.
So don't make TARGET_IEEE_FP default for SCO. */ So don't make TARGET_IEEE_FP default for SCO. */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS)
/* Use crt1.o as a startup file and crtn.o as a closing file. */ /* Use crt1.o as a startup file and crtn.o as a closing file. */
......
...@@ -28,8 +28,8 @@ Boston, MA 02111-1307, USA. */ ...@@ -28,8 +28,8 @@ Boston, MA 02111-1307, USA. */
because the assembler can't handle the fucom insn. because the assembler can't handle the fucom insn.
Return float values in the 387. */ Return float values in the 387. */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_FLOAT_RETURNS)
/* Specify predefined symbols in preprocessor. */ /* Specify predefined symbols in preprocessor. */
......
...@@ -67,7 +67,7 @@ Boston, MA 02111-1307, USA. */ ...@@ -67,7 +67,7 @@ Boston, MA 02111-1307, USA. */
/* By default, target has a 80387, uses IEEE compatible arithmetic, /* By default, target has a 80387, uses IEEE compatible arithmetic,
and returns float values in the 387. */ and returns float values in the 387. */
#define TARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS) #define TARGET_SUBTARGET_DEFAULT (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS)
/* Floating-point return values come in the FP register. */ /* Floating-point return values come in the FP register. */
......
...@@ -214,9 +214,9 @@ do { \ ...@@ -214,9 +214,9 @@ do { \
/* By default, target has a 80387, uses IEEE compatible arithmetic, /* By default, target has a 80387, uses IEEE compatible arithmetic,
and returns float values in the 387 and needs stack probes */ and returns float values in the 387 and needs stack probes */
#undef TARGET_DEFAULT #undef TARGET_SUBTARGET_DEFAULT
#define TARGET_DEFAULT \ #define TARGET_SUBTARGET_DEFAULT \
(MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE) (MASK_80387 | MASK_IEEE_FP | MASK_FLOAT_RETURNS | MASK_STACK_PROBE)
/* This is how to output an assembler line /* This is how to output an assembler line
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment