mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-02-21 13:39:39 +08:00
safe-ctype.h (HC_UNKNOWN, [...]): New #defines.
include: * safe-ctype.h (HC_UNKNOWN, HC_ASCII, HC_EBCDIC, HOST_CHARSET): New #defines. libiberty: * safe-ctype.c: Separate out EOF==-1 check. Use HOST_CHARSET for charset determination. gcc: * aclocal.m4 (gcc_AC_C_CHARSET): Delete. * configure.in: Don't use gcc_AC_C_CHARSET. * configure, config.in: Regenerate. * config/i370/i370.c, config/i370/i370.h: Use (HOST_CHARSET == HC_EBCDIC) or (HOST_CHARSET == HC_ASCII) instead of HOST_EBCDIC or !HOST_EBCDIC. Clarify comments a tad. From-SVN: r68317
This commit is contained in:
parent
de32c0cb3b
commit
7468e0b523
@ -1,3 +1,12 @@
|
||||
2003-06-21 Zack Weinberg <zack@codesourcery.com>
|
||||
|
||||
* aclocal.m4 (gcc_AC_C_CHARSET): Delete.
|
||||
* configure.in: Don't use gcc_AC_C_CHARSET.
|
||||
* configure, config.in: Regenerate.
|
||||
* config/i370/i370.c, config/i370/i370.h: Use
|
||||
(HOST_CHARSET == HC_EBCDIC) or (HOST_CHARSET == HC_ASCII)
|
||||
instead of HOST_EBCDIC or !HOST_EBCDIC. Clarify comments a tad.
|
||||
|
||||
2003-06-21 Neil Booth <neil@daikokuya.co.uk>
|
||||
|
||||
* Makefile.in: Update.
|
||||
@ -58,7 +67,7 @@ Sat Jun 21 13:41:00 CEST 2003 Jan Hubicka <jh@suse.cz>
|
||||
* toplev.h (decode_g_option): New.
|
||||
|
||||
2003-06-20 Aldy Hernandez <aldyh@redhat.com>
|
||||
|
||||
|
||||
PR/11092
|
||||
* config/rs6000/rs6000.h (LEGITIMATE_CONSTANT_P): Adjust for
|
||||
vectors.
|
||||
@ -120,7 +129,7 @@ Sat Jun 21 13:41:00 CEST 2003 Jan Hubicka <jh@suse.cz>
|
||||
to ASM_OUTPUT_SOURCE_LINE.
|
||||
|
||||
2003-06-20 Daniel Egger <degger@fhm.edu>
|
||||
Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
|
||||
Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
|
||||
|
||||
* doc/install.texi (Building): Correct and improve statement
|
||||
about parallel builds.
|
||||
|
28
gcc/aclocal.m4
vendored
28
gcc/aclocal.m4
vendored
@ -564,34 +564,6 @@ AC_CACHE_CHECK(for __int64, ac_cv_c___int64,
|
||||
fi
|
||||
])
|
||||
|
||||
dnl Host character set probe.
|
||||
dnl The EBCDIC values match the table in config/i370/i370.c;
|
||||
dnl there are other versions of EBCDIC but GCC won't work with them.
|
||||
dnl
|
||||
AC_DEFUN([gcc_AC_C_CHARSET],
|
||||
[AC_CACHE_CHECK(execution character set, ac_cv_c_charset,
|
||||
[AC_EGREP_CPP(ASCII,
|
||||
[#if '\n' == 0x0A && ' ' == 0x20 && '0' == 0x30 \
|
||||
&& 'A' == 0x41 && 'a' == 0x61 && '!' == 0x21
|
||||
ASCII
|
||||
#endif], ac_cv_c_charset=ASCII)
|
||||
if test x${ac_cv_c_charset+set} != xset; then
|
||||
AC_EGREP_CPP(EBCDIC,
|
||||
[#if '\n' == 0x15 && ' ' == 0x40 && '0' == 0xF0 \
|
||||
&& 'A' == 0xC1 && 'a' == 0x81 && '!' == 0x5A
|
||||
EBCDIC
|
||||
#endif], ac_cv_c_charset=EBCDIC)
|
||||
fi
|
||||
if test x${ac_cv_c_charset+set} != xset; then
|
||||
ac_cv_c_charset=unknown
|
||||
fi])
|
||||
if test $ac_cv_c_charset = unknown; then
|
||||
AC_MSG_ERROR([*** Cannot determine host character set.])
|
||||
elif test $ac_cv_c_charset = EBCDIC; then
|
||||
AC_DEFINE(HOST_EBCDIC, 1,
|
||||
[Define if the host execution character set is EBCDIC.])
|
||||
fi])
|
||||
|
||||
#serial AM2
|
||||
|
||||
dnl From Bruno Haible.
|
||||
|
@ -321,9 +321,6 @@
|
||||
/* The number of bytes in type __int64 */
|
||||
#undef SIZEOF___INT64
|
||||
|
||||
/* Define if the host execution character set is EBCDIC. */
|
||||
#undef HOST_EBCDIC
|
||||
|
||||
/* Define if you want more run-time sanity checks. This one gets a grab
|
||||
bag of miscellaneous but relatively cheap checks. */
|
||||
#undef ENABLE_CHECKING
|
||||
|
@ -121,7 +121,7 @@ static bool i370_rtx_costs PARAMS ((rtx, int, int, int *));
|
||||
#ifdef TARGET_HLASM
|
||||
|
||||
#define MVS_HASH_PRIME 999983
|
||||
#if defined(HOST_EBCDIC)
|
||||
#if HOST_CHARSET == HC_EBCDIC
|
||||
#define MVS_SET_SIZE 256
|
||||
#else
|
||||
#define MVS_SET_SIZE 128
|
||||
@ -156,7 +156,7 @@ static alias_node_t *alias_anchor = 0;
|
||||
and must handled in a special manner. */
|
||||
static const char *const mvs_function_table[MVS_FUNCTION_TABLE_LENGTH] =
|
||||
{
|
||||
#if defined(HOST_EBCDIC) /* Changed for EBCDIC collating sequence */
|
||||
#if HOST_CHARSET == HC_EBCDIC /* Changed for EBCDIC collating sequence */
|
||||
"ceil", "edc_acos", "edc_asin", "edc_atan", "edc_ata2", "edc_cos",
|
||||
"edc_cosh", "edc_erf", "edc_erfc", "edc_exp", "edc_gamm", "edc_lg10",
|
||||
"edc_log", "edc_sin", "edc_sinh", "edc_sqrt", "edc_tan", "edc_tanh",
|
||||
@ -176,7 +176,7 @@ static const char *const mvs_function_table[MVS_FUNCTION_TABLE_LENGTH] =
|
||||
#endif /* TARGET_HLASM */
|
||||
/* ===================================================== */
|
||||
|
||||
#if defined(TARGET_EBCDIC) && !defined(HOST_EBCDIC)
|
||||
#if defined(TARGET_EBCDIC) && HOST_CHARSET == HC_ASCII
|
||||
/* ASCII to EBCDIC conversion table. */
|
||||
static const unsigned char ascebc[256] =
|
||||
{
|
||||
@ -229,10 +229,9 @@ static const unsigned char ascebc[256] =
|
||||
0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F,
|
||||
0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0x3F, 0xFF
|
||||
};
|
||||
#endif /* TARGET_EBCDIC && ! HOST_EBCDIC */
|
||||
#endif /* target EBCDIC, host ASCII */
|
||||
|
||||
|
||||
#if defined(HOST_EBCDIC) && !defined(TARGET_EBCDIC)
|
||||
#if !defined(TARGET_EBCDIC) && HOST_CHARSET == HC_EBCDIC
|
||||
/* EBCDIC to ASCII conversion table. */
|
||||
static const unsigned char ebcasc[256] =
|
||||
{
|
||||
@ -301,7 +300,7 @@ static const unsigned char ebcasc[256] =
|
||||
/*F8 8 9 */
|
||||
0x38, 0x39, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF
|
||||
};
|
||||
#endif /* HOST_EBCDIC && ! TARGET_EBCDIC */
|
||||
#endif /* target ASCII, host EBCDIC */
|
||||
|
||||
/* Initialize the GCC target structure. */
|
||||
#ifdef TARGET_HLASM
|
||||
@ -351,11 +350,11 @@ char
|
||||
mvs_map_char (c)
|
||||
int c;
|
||||
{
|
||||
#if defined(TARGET_EBCDIC) && !defined(HOST_EBCDIC)
|
||||
#if defined(TARGET_EBCDIC) && HOST_CHARSET == HC_ASCII
|
||||
fprintf (stderr, "mvs_map_char: TE & !HE: c = %02x\n", c);
|
||||
return ascebc[c];
|
||||
#else
|
||||
#if defined(HOST_EBCDIC) && !defined(TARGET_EBCDIC)
|
||||
#if !defined(TARGET_EBCDIC) && HOST_CHARSET == HC_EBCDIC
|
||||
fprintf (stderr, "mvs_map_char: !TE & HE: c = %02x\n", c);
|
||||
return ebcasc[c];
|
||||
#else
|
||||
|
@ -141,7 +141,7 @@ extern size_t mvs_function_name_length;
|
||||
/* but only define it if really needed, since otherwise it will break builds */
|
||||
|
||||
#ifdef TARGET_EBCDIC
|
||||
#ifdef HOST_EBCDIC
|
||||
#if HOST_CHARSET == HC_EBCDIC
|
||||
#define MAP_CHARACTER(c) ((char)(c))
|
||||
#else
|
||||
#define MAP_CHARACTER(c) ((char)mvs_map_char (c))
|
||||
|
588
gcc/configure
vendored
588
gcc/configure
vendored
File diff suppressed because it is too large
Load Diff
@ -259,8 +259,6 @@ if test $ac_cv_c___int64 = yes; then
|
||||
AC_COMPILE_CHECK_SIZEOF(__int64)
|
||||
fi
|
||||
|
||||
gcc_AC_C_CHARSET
|
||||
|
||||
# -----------------
|
||||
# Find Ada compiler
|
||||
# -----------------
|
||||
|
@ -1,3 +1,8 @@
|
||||
2003-06-21 Zack Weinberg <zack@codesourcery.com>
|
||||
|
||||
* safe-ctype.h (HC_UNKNOWN, HC_ASCII, HC_EBCDIC, HOST_CHARSET):
|
||||
New #defines.
|
||||
|
||||
2003-06-17 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* ansidecl.h: Delete HAVE_LONG_DOUBLE GCC bootstrap support.
|
||||
@ -383,7 +388,7 @@
|
||||
|
||||
2000-09-04 Alex Samuel <samuel@codesourcery.com>
|
||||
|
||||
* dyn-string.h: Adjust formatting.
|
||||
* dyn-string.h: Adjust formatting.
|
||||
(dyn_string_insert_char): New macro. New declaration.
|
||||
|
||||
2000-08-28 Jason Merrill <jason@redhat.com>
|
||||
@ -408,7 +413,7 @@
|
||||
dyn_string_insert_cstr, dyn_string_append, dyn_string_append_cstr,
|
||||
dyn_string_append_char, dyn_string_substring): Change return type
|
||||
to int.
|
||||
|
||||
|
||||
2000-06-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* demangle.h (demangling_styles): Remove trailing comma in enum.
|
||||
@ -421,12 +426,12 @@
|
||||
* dyn-string.h: Move here from gcc/dyn-string.h. Add new functions.
|
||||
|
||||
* demangle.h (DMGL_GNU_NEW_ABI): New macro.
|
||||
(DMGL_STYLE_MASK): Or in DMGL_GNU_NEW_ABI.
|
||||
(DMGL_STYLE_MASK): Or in DMGL_GNU_NEW_ABI.
|
||||
(current_demangling_style): Add gnu_new_abi_demangling.
|
||||
(GNU_NEW_ABI_DEMANGLING_STYLE_STRING): New macro.
|
||||
(GNU_NEW_ABI_DEMANGLING): Likewise.
|
||||
(cplus_demangle_new_abi): New declaration.
|
||||
|
||||
|
||||
Tue May 30 16:53:34 2000 Andrew Cagney <cagney@b1.cygnus.com>
|
||||
|
||||
* floatformat.h (struct floatformat): Add field name.
|
||||
@ -458,9 +463,9 @@ Thu May 4 17:15:26 2000 Philippe De Muyter <phdm@macqel.be>
|
||||
2000-04-28 Kenneth Block <block@zk3.dec.com>
|
||||
Jason Merrill <jason@casey.cygnus.com>
|
||||
|
||||
* demangle.h (libiberty_demanglers): new table for different styles.
|
||||
(cplus_demangle_set_style): New function for setting style.
|
||||
(cplus_demangle_name_to_style): New function to translate name.
|
||||
* demangle.h (libiberty_demanglers): new table for different styles.
|
||||
(cplus_demangle_set_style): New function for setting style.
|
||||
(cplus_demangle_name_to_style): New function to translate name.
|
||||
|
||||
2000-04-24 Mark Mitchell <mark@codesourcery.com>
|
||||
|
||||
|
@ -37,7 +37,24 @@ Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifdef isalpha
|
||||
#error "safe-ctype.h and ctype.h may not be used simultaneously"
|
||||
#endif
|
||||
|
||||
/* Determine host character set. */
|
||||
#define HC_UNKNOWN 0
|
||||
#define HC_ASCII 1
|
||||
#define HC_EBCDIC 2
|
||||
|
||||
#if '\n' == 0x0A && ' ' == 0x20 && '0' == 0x30 \
|
||||
&& 'A' == 0x41 && 'a' == 0x61 && '!' == 0x21
|
||||
# define HOST_CHARSET HC_ASCII
|
||||
#else
|
||||
# if '\n' == 0x15 && ' ' == 0x40 && '0' == 0xF0 \
|
||||
&& 'A' == 0xC1 && 'a' == 0x81 && '!' == 0x5A
|
||||
# define HOST_CHARSET HC_EBCDIC
|
||||
# else
|
||||
# define HOST_CHARSET HC_UNKNOWN
|
||||
# endif
|
||||
#endif
|
||||
|
||||
/* Categories. */
|
||||
|
||||
@ -99,5 +116,4 @@ extern const unsigned char _sch_tolower[256];
|
||||
#define TOUPPER(c) _sch_toupper[(c) & 0xff]
|
||||
#define TOLOWER(c) _sch_tolower[(c) & 0xff]
|
||||
|
||||
#endif /* no ctype.h */
|
||||
#endif /* SAFE_CTYPE_H */
|
||||
|
@ -1,3 +1,8 @@
|
||||
2003-06-21 Zack Weinberg <zack@codesourcery.com>
|
||||
|
||||
* safe-ctype.c: Separate out EOF==-1 check. Use HOST_CHARSET
|
||||
for charset determination.
|
||||
|
||||
2003-06-19 Dara Hazeghi <dhazeghi@yahoo.com>
|
||||
|
||||
* configure.in: Add check for malloc.h needed by
|
||||
@ -8,14 +13,14 @@
|
||||
free().
|
||||
|
||||
2003-06-09 Albert Chin-A-Young <china@thewrittenword.com>
|
||||
|
||||
|
||||
PR bootstrap/10974
|
||||
* physmem.c: Update comment.
|
||||
* configure.in: Modify test for _system_configuration for older
|
||||
AIX systems.
|
||||
|
||||
* config.in, configure: Regenerated.
|
||||
|
||||
|
||||
2003-06-05 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
|
||||
|
||||
PR other/10810
|
||||
@ -109,7 +114,7 @@
|
||||
ANSI_PROTOTYPES.
|
||||
* vsprintf.c: Include "ansidecl.h" earlier, rely on
|
||||
ANSI_PROTOTYPES and possibly include <stdarg.h>.
|
||||
|
||||
|
||||
* Makefile.in: Regenerate dependencies.
|
||||
|
||||
2003-04-15 DJ Delorie <dj@redhat.com>
|
||||
@ -207,7 +212,7 @@
|
||||
2003-02-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
Richard Earnshaw <rearnsha@arm.com>
|
||||
Geoffrey Keating <geoffk@apple.com>
|
||||
|
||||
|
||||
* configure.in: Check for sys/sysctl.h and sysctl.
|
||||
* physmem.c: Add support for *bsd and darwin.
|
||||
* Makefile.in: Generate depedency for physmem.o.
|
||||
@ -236,7 +241,7 @@
|
||||
* physmem.c (physmem_total, physmem_available): De-ANSI-fy.
|
||||
* configure.in (AC_CHECK_FUNCS): Add pstat_getstatic and
|
||||
pstat_getdynamic.
|
||||
|
||||
|
||||
2003-02-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* Makefile.in (CFILES): Add physmem.c.
|
||||
|
@ -33,6 +33,10 @@ Boston, MA 02111-1307, USA. */
|
||||
#include <safe-ctype.h>
|
||||
#include <stdio.h> /* for EOF */
|
||||
|
||||
#if EOF != -1
|
||||
#error "<safe-ctype.h> requires EOF == -1"
|
||||
#endif
|
||||
|
||||
/* Shorthand */
|
||||
#define bl _sch_isblank
|
||||
#define cn _sch_iscntrl
|
||||
@ -64,9 +68,7 @@ Boston, MA 02111-1307, USA. */
|
||||
#define S (const unsigned short) (nv|sp|bl|pr) /* space */
|
||||
|
||||
/* Are we ASCII? */
|
||||
#if '\n' == 0x0A && ' ' == 0x20 && '0' == 0x30 \
|
||||
&& 'A' == 0x41 && 'a' == 0x61 && '!' == 0x21 \
|
||||
&& EOF == -1
|
||||
#if HOST_CHARSET == HC_ASCII
|
||||
|
||||
const unsigned short _sch_istable[256] =
|
||||
{
|
||||
@ -159,5 +161,9 @@ const unsigned char _sch_toupper[256] =
|
||||
};
|
||||
|
||||
#else
|
||||
#error "Unsupported host character set"
|
||||
#endif /* not ASCII */
|
||||
# if HOST_CHARSET == HC_EBCDIC
|
||||
#error "FIXME: write tables for EBCDIC"
|
||||
# else
|
||||
#error "Unrecognized host character set"
|
||||
# endif
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user