diff options
author | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-06-21 23:22:30 +0000 |
---|---|---|
committer | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-06-21 23:22:30 +0000 |
commit | 05b93640030b8202a5c8e6d19a048e501b4f5b60 (patch) | |
tree | a51893fa5517a7ec2b7577959cf98aa24df8727c /gcc/config/i370 | |
parent | 1e06725af950e15306cca1db67d1939ad9d99fa4 (diff) | |
download | gcc-05b93640030b8202a5c8e6d19a048e501b4f5b60.tar.gz |
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.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@68317 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/i370')
-rw-r--r-- | gcc/config/i370/i370.c | 17 | ||||
-rw-r--r-- | gcc/config/i370/i370.h | 2 |
2 files changed, 9 insertions, 10 deletions
diff --git a/gcc/config/i370/i370.c b/gcc/config/i370/i370.c index 501e353bf86..f7df14fb853 100644 --- a/gcc/config/i370/i370.c +++ b/gcc/config/i370/i370.c @@ -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 diff --git a/gcc/config/i370/i370.h b/gcc/config/i370/i370.h index 93e6ea63017..19806fe939c 100644 --- a/gcc/config/i370/i370.h +++ b/gcc/config/i370/i370.h @@ -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)) |