diff options
author | Greg McGary <greg@mcgary.org> | 2000-08-24 20:31:35 +0000 |
---|---|---|
committer | Greg McGary <gkm@gcc.gnu.org> | 2000-08-24 20:31:35 +0000 |
commit | b6a1cbaeb19076fca9b0deb00138fedf0c8c36ff (patch) | |
tree | 598c21af74eb9deec6a463196f439a03d7a53b91 /gcc/optabs.c | |
parent | 2f26c11dbb2d0f1e37f16120c455147a00dff716 (diff) | |
download | gcc-b6a1cbaeb19076fca9b0deb00138fedf0c8c36ff.zip gcc-b6a1cbaeb19076fca9b0deb00138fedf0c8c36ff.tar.gz gcc-b6a1cbaeb19076fca9b0deb00138fedf0c8c36ff.tar.bz2 |
optabs.c (init_optabs): Initialize fixtab...
* optabs.c (init_optabs): Initialize fixtab, fixtrunctab, floattab,
and extendtab within their proper array boundaries.
* emit-rtl.c (init_emit_once): Pass `const_tiny_rtx' with bounds
for the entire array.
* config/arm/arm.c (arm_override_options): Use ARRAY_SIZE.
* config/alpha/alpha.c (alpha_lookup_xfloating_lib_func): Likewise.
* config/avr/avr.c (order_regs_for_local_alloc): Likewise.
* config/fr30/fr30.c (fr30_print_operand): Likewise.
* config/i386/dgux.c (output_options): Likewise.
* config/i386/dgux.h (ASM_FILE_START): Likewise.
* config/m88k/m88k.c (output_options): Likewise.
* config/m88k/m88k.h (ASM_FILE_START): Likewise.
* config/mcore/mcore.c (mcore_output_inline_const_forced,
layout_mcore_frame, handle_structs_in_regs): Likewise.
* config/mips/mips.c (output_block_move): Likewise.
* config/rs6000/rs6000.c (rs6000_override_options,
rs6000_file_start): Likewise.
* config/sparc/sparc.c (sparc_add_gc_roots): Likewise.
* fixinc/fixfixes.c (FIX_TABLE_CT): Likewise.
* fixinc/fixtests.c (TEST_TABLE_CT): Likewise.
* builtins.c (expand_builtin_setjmp): Likewise.
* expr.c (safe_from_p): Likewise.
* flow.c (life_analysis): Likewise.
* fold-const.c (size_int_type_wide): Likewise.
* gcc.c (translate_options, init_spec, set_spec, main): Likewise.
* genattrtab.c (make_length_attrs): Likewise.
* genopinit.c (gen_insn): Likewise.
* genrecog.c (NUM_KNOWN_PREDS, NUM_SPECIAL_MODE_PREDS): Likewise.
* global.c (global_alloc): Likewise.
* local-alloc.c (find_free_reg): Likewise.
* mips-tdump.c (print_symbol): Likewise.
* mips-tfile.c (parse_def, parse_input): Likewise.
* reload1.c (NUM_ELIMINABLE_REGS): Likewise.
* stmt.c (expand_nl_goto_receiver): Likewise.
* stor-layout.c (set_sizetype): Likewise.
* varasm.c (decode_reg_name): Likewise.
* toplev.c (decode_f_option, decode_W_option,
set_target_switch, print_switch_values): Likewise.
(NUM_ELEM): Remove macro.
(display_help, main): s/NUM_ELEM/ARRAY_SIZE/
From-SVN: r35949
Diffstat (limited to 'gcc/optabs.c')
-rw-r--r-- | gcc/optabs.c | 45 |
1 files changed, 20 insertions, 25 deletions
diff --git a/gcc/optabs.c b/gcc/optabs.c index 6530d83..0a64fad 100644 --- a/gcc/optabs.c +++ b/gcc/optabs.c @@ -4484,34 +4484,29 @@ mark_optab (arg) void init_optabs () { - int i; -#ifdef FIXUNS_TRUNC_LIKE_FIX_TRUNC - int j; -#endif - - enum insn_code *p; + unsigned int i, j, k; /* Start by initializing all tables to contain CODE_FOR_nothing. */ - for (p = fixtab[0][0]; - p < fixtab[0][0] + sizeof fixtab / sizeof (fixtab[0][0][0]); - p++) - *p = CODE_FOR_nothing; - - for (p = fixtrunctab[0][0]; - p < fixtrunctab[0][0] + sizeof fixtrunctab / sizeof (fixtrunctab[0][0][0]); - p++) - *p = CODE_FOR_nothing; - - for (p = floattab[0][0]; - p < floattab[0][0] + sizeof floattab / sizeof (floattab[0][0][0]); - p++) - *p = CODE_FOR_nothing; - - for (p = extendtab[0][0]; - p < extendtab[0][0] + sizeof extendtab / sizeof extendtab[0][0][0]; - p++) - *p = CODE_FOR_nothing; + for (i = 0; i < ARRAY_SIZE (fixtab); i++) + for (j = 0; j < ARRAY_SIZE (fixtab[0]); j++) + for (k = 0; k < ARRAY_SIZE (fixtab[0][0]); k++) + fixtab[i][j][k] = CODE_FOR_nothing; + + for (i = 0; i < ARRAY_SIZE (fixtrunctab); i++) + for (j = 0; j < ARRAY_SIZE (fixtrunctab[0]); j++) + for (k = 0; k < ARRAY_SIZE (fixtrunctab[0][0]); k++) + fixtrunctab[i][j][k] = CODE_FOR_nothing; + + for (i = 0; i < ARRAY_SIZE (floattab); i++) + for (j = 0; j < ARRAY_SIZE (floattab[0]); j++) + for (k = 0; k < ARRAY_SIZE (floattab[0][0]); k++) + floattab[i][j][k] = CODE_FOR_nothing; + + for (i = 0; i < ARRAY_SIZE (extendtab); i++) + for (j = 0; j < ARRAY_SIZE (extendtab[0]); j++) + for (k = 0; k < ARRAY_SIZE (extendtab[0][0]); k++) + extendtab[i][j][k] = CODE_FOR_nothing; for (i = 0; i < NUM_RTX_CODE; i++) setcc_gen_code[i] = CODE_FOR_nothing; |