diff options
author | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-10-10 20:33:07 +0000 |
---|---|---|
committer | zack <zack@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-10-10 20:33:07 +0000 |
commit | 47a2c1d448f2578c0d9d1bd6be4a17e95d279870 (patch) | |
tree | f9be992652ecd68b01a301007bfe03ceccd94dc6 /gcc/rtl.c | |
parent | 18ee3f27ba9cc3c48b390db1d052618c0f393513 (diff) | |
download | gcc-47a2c1d448f2578c0d9d1bd6be4a17e95d279870.tar.gz |
* genmodes.c, mode-classes.def: New files.
* machmode.def: Rewritten to genmodes.c interface.
* Makefile.in (extra_modes_file): New substitution variable.
(MACHMODE_H): No longer includes machmode.def or
@extra_modes_file@; instead, mode-classes.def and insn-modes.h.
(BUILD_RTL): Add $(BUILD_PREFIX)insn-modes.o.
(OBJS-common): Add insn-modes.o.
(STAGESTUFF): Add insn-modes.c, insn-modes.h, s-modes, and
genmodes$(build_exeext).
(insn-modes.o, insn-modes.c, insn-modes.h, s-modes, genmodes.o,
genmodes$(build_exeext), $(BUILD_PREFIX_1)insn-modes.o): New targets.
(s-genrtl): Don't depend on $(RTL_BASE_H).
(gengenrtl.o): Don't depend on coretypes.h, $(GTM_H), real.h,
or $(RTL_BASE_H); just rtl.def.
* gengenrtl.c: Don't include coretypes.h, tm.h, rtl.h, or
real.h. Give fake definition of CONST_DOUBLE_FORMAT and
substitute definition of NUM_RTX_CODE. Add casts to avoid
warnings.
* machmode.h: Include insn-modes.h, not machmode.def. Include
mode-classes.def to define enum mode_class. Tweak definitions
of GET_MODE_CLASS, GET_MODE_SIZE, GET_MODE_BITSIZE, GET_MODE_MASK,
GET_MODE_INNER, GET_MODE_WIDER_MODE, GET_CLASS_NARROWEST_MODE.
(inner_mode_array): Renamed mode_inner.
(mode_base_align): New.
* rtl.c (mode_name, mode_class, mode_bitsize, mode_size,
mode_unit_size, mode_wider_mode, mode_mask_array,
inner_mode_array, class_narrowest_mode): Delete definitions.
* stor-layout.c (get_mode_alignment): Use mode_base_align.
* real.h: Use MIN_MODE_FLOAT and MAX_MODE_FLOAT, not QFmode
and TFmode, in real_format_for_mode and REAL_MODE_FORMAT.
* config/ip2k/ip2k.h, config/iq2000/iq2000.h:
No need to define BITS_PER_UNIT.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@72313 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/rtl.c')
-rw-r--r-- | gcc/rtl.c | 109 |
1 files changed, 0 insertions, 109 deletions
diff --git a/gcc/rtl.c b/gcc/rtl.c index 54b7476c738..f339ff69270 100644 --- a/gcc/rtl.c +++ b/gcc/rtl.c @@ -50,115 +50,6 @@ const char * const rtx_name[NUM_RTX_CODE] = { #undef DEF_RTL_EXPR -/* Indexed by machine mode, gives the name of that machine mode. - This name does not include the letters "mode". */ - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) NAME, - -const char * const mode_name[NUM_MACHINE_MODES] = { -#include "machmode.def" -}; - -#undef DEF_MACHMODE - -/* Indexed by machine mode, gives the class mode for GET_MODE_CLASS. */ - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) CLASS, - -const enum mode_class mode_class[NUM_MACHINE_MODES] = { -#include "machmode.def" -}; - -#undef DEF_MACHMODE - -/* Indexed by machine mode, gives the length of the mode, in bits. - GET_MODE_BITSIZE uses this. */ - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) BITSIZE, - -const unsigned short mode_bitsize[NUM_MACHINE_MODES] = { -#include "machmode.def" -}; - -#undef DEF_MACHMODE - -/* Indexed by machine mode, gives the length of the mode, in bytes. - GET_MODE_SIZE uses this. */ - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) SIZE, - -const unsigned char mode_size[NUM_MACHINE_MODES] = { -#include "machmode.def" -}; - -#undef DEF_MACHMODE - -/* Indexed by machine mode, gives the length of the mode's subunit. - GET_MODE_UNIT_SIZE uses this. */ - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) UNIT, - -const unsigned char mode_unit_size[NUM_MACHINE_MODES] = { -#include "machmode.def" /* machine modes are documented here */ -}; - -#undef DEF_MACHMODE - -/* Indexed by machine mode, gives next wider natural mode - (QI -> HI -> SI -> DI, etc.) Widening multiply instructions - use this. */ - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) \ - (unsigned char) WIDER, - -const unsigned char mode_wider_mode[NUM_MACHINE_MODES] = { -#include "machmode.def" /* machine modes are documented here */ -}; - -#undef DEF_MACHMODE - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) \ - ((BITSIZE) >= HOST_BITS_PER_WIDE_INT) ? ~(unsigned HOST_WIDE_INT) 0 : ((unsigned HOST_WIDE_INT) 1 << (BITSIZE)) - 1, - -/* Indexed by machine mode, gives mask of significant bits in mode. */ - -const unsigned HOST_WIDE_INT mode_mask_array[NUM_MACHINE_MODES] = { -#include "machmode.def" -}; - -#undef DEF_MACHMODE - -#define DEF_MACHMODE(SYM, NAME, CLASS, BITSIZE, SIZE, UNIT, WIDER, INNER) INNER, - -/* Indexed by machine mode, gives the mode of the inner elements in a - vector type. */ - -const enum machine_mode inner_mode_array[NUM_MACHINE_MODES] = { -#include "machmode.def" -}; - -/* Indexed by mode class, gives the narrowest mode for each class. - The Q modes are always of width 1 (2 for complex) - it is impossible - for any mode to be narrower. - - Note that we use QImode instead of BImode for MODE_INT, since - otherwise the middle end will try to use it for bitfields in - structures and the like, which we do not want. Only the target - md file should generate BImode widgets. */ - -const enum machine_mode class_narrowest_mode[(int) MAX_MODE_CLASS] = { - /* MODE_RANDOM */ VOIDmode, - /* MODE_INT */ QImode, - /* MODE_FLOAT */ QFmode, - /* MODE_PARTIAL_INT */ PQImode, - /* MODE_CC */ CCmode, - /* MODE_COMPLEX_INT */ CQImode, - /* MODE_COMPLEX_FLOAT */ QCmode, - /* MODE_VECTOR_INT */ V1DImode, - /* MODE_VECTOR_FLOAT */ V2SFmode -}; - - /* Indexed by rtx code, gives a sequence of operand-types for rtx's of that code. The sequence is a C string in which each character describes one operand. */ |