Commit 9a63901f by Richard Kenner

Use WORD_REGISTER_OPERATION and LOAD_EXTEND_OP and delete

BYTE_LOADS_{SIGN,ZERO}_EXTEND.

From-SVN: r5477
parent e90d3cbb
...@@ -1204,9 +1204,15 @@ extern char *a29k_function_name; ...@@ -1204,9 +1204,15 @@ extern char *a29k_function_name;
manipulate fields. */ manipulate fields. */
#define SLOW_BYTE_ACCESS 0 #define SLOW_BYTE_ACCESS 0
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_ZERO_EXTEND #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* Define if the object format being used is COFF or a superset. */ /* Define if the object format being used is COFF or a superset. */
#define OBJECT_FORMAT_COFF #define OBJECT_FORMAT_COFF
......
...@@ -1221,13 +1221,15 @@ extern char *current_function_name; ...@@ -1221,13 +1221,15 @@ extern char *current_function_name;
#define SLOW_BYTE_ACCESS 1 #define SLOW_BYTE_ACCESS 1
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bits in the register. */ on the full register even if a narrower mode is specified. */
/* #define BYTE_LOADS_ZERO_EXTEND */ #define WORD_REGISTER_OPERATIONS
/* Define if normal loads of shorter-than-word items from memory sign-extends /* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
the rest of the bits in the register. */ will either zero-extend or sign-extend. The value of this macro should
#define BYTE_LOADS_SIGN_EXTEND be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) SIGN_EXTEND
/* Define if loading short immediate values into registers sign extends. */ /* Define if loading short immediate values into registers sign extends. */
#define SHORT_IMMEDIATES_SIGN_EXTEND #define SHORT_IMMEDIATES_SIGN_EXTEND
......
/* Definitions of target machine for GNU compiler, for Acorn RISC Machine. /* Definitions of target machine for GNU compiler, for Acorn RISC Machine.
Copyright (C) 1991 Free Software Foundation, Inc. Copyright (C) 1991, 1993 Free Software Foundation, Inc.
Contributed by Pieter `Tiggr' Schoenmakers (rcpieter@win.tue.nl) Contributed by Pieter `Tiggr' Schoenmakers (rcpieter@win.tue.nl)
and Martin Simmons (@harleqn.co.uk). and Martin Simmons (@harleqn.co.uk).
...@@ -848,11 +848,6 @@ do \ ...@@ -848,11 +848,6 @@ do \
in one reasonably fast instruction. */ in one reasonably fast instruction. */
#define MOVE_MAX 4 #define MOVE_MAX 4
/* Define if normal loads of shorter-than-word items from memory clears
the rest of the bigs in the register.
On the ARM, movhi does a garbage extend. */
/* #define BYTE_LOADS_ZERO_EXTEND */
/* Define this if zero-extension is slow (more than one real instruction). /* Define this if zero-extension is slow (more than one real instruction).
On the ARM, it is more than one instruction only if not fetching from On the ARM, it is more than one instruction only if not fetching from
memory. */ memory. */
......
...@@ -773,10 +773,15 @@ do \ ...@@ -773,10 +773,15 @@ do \
jumps to the default label instead. */ jumps to the default label instead. */
/* #define CASE_DROPS_THROUGH */ /* #define CASE_DROPS_THROUGH */
/* Define this macro if an instruction to load a value narrower than a /* Define if operations between registers always perform the operation
word from memory into a register also sign-extends the value to on the full register even if a narrower mode is specified. */
the whole register. */ #define WORD_REGISTER_OPERATIONS
#define BYTE_LOADS_SIGN_EXTEND
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) SIGN_EXTEND
/* Specify the tree operation to be used to convert reals to integers. */ /* Specify the tree operation to be used to convert reals to integers. */
#define IMPLICIT_FIX_EXPR FIX_ROUND_EXPR #define IMPLICIT_FIX_EXPR FIX_ROUND_EXPR
......
...@@ -1055,9 +1055,15 @@ extern struct rtx_def *legitimize_address (); ...@@ -1055,9 +1055,15 @@ extern struct rtx_def *legitimize_address ();
in one reasonably fast instruction. */ in one reasonably fast instruction. */
#define MOVE_MAX 16 #define MOVE_MAX 16
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_ZERO_EXTEND #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* Nonzero if access to memory by bytes is no faster than for words. /* Nonzero if access to memory by bytes is no faster than for words.
Defining this results in worse code on the i960. */ Defining this results in worse code on the i960. */
......
...@@ -1508,9 +1508,15 @@ enum reg_class { NO_REGS, AP_REG, XRF_REGS, GENERAL_REGS, AGRF_REGS, ...@@ -1508,9 +1508,15 @@ enum reg_class { NO_REGS, AP_REG, XRF_REGS, GENERAL_REGS, AGRF_REGS,
in one reasonably fast instruction. */ in one reasonably fast instruction. */
#define MOVE_MAX 8 #define MOVE_MAX 8
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_ZERO_EXTEND #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* Zero if access to memory by bytes is faster. */ /* Zero if access to memory by bytes is faster. */
#define SLOW_BYTE_ACCESS 1 #define SLOW_BYTE_ACCESS 1
......
...@@ -1049,12 +1049,15 @@ do { \ ...@@ -1049,12 +1049,15 @@ do { \
#define PROMOTE_PROTOTYPES #define PROMOTE_PROTOTYPES
/* Define this macro if an instruction to load a value narrower /* Define if operations between registers always perform the operation
than a word from memory into a register also zero-extends the on the full register even if a narrower mode is specified. */
value to the whole register. */ #define WORD_REGISTER_OPERATIONS
#define BYTE_LOADS_ZERO_EXTEND /* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* Standard register usage. */ /* Standard register usage. */
......
...@@ -1367,9 +1367,15 @@ while (0) ...@@ -1367,9 +1367,15 @@ while (0)
in one reasonably fast instruction. */ in one reasonably fast instruction. */
#define MOVE_MAX 8 #define MOVE_MAX 8
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_ZERO_EXTEND #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* Nonzero if access to memory by bytes is slow and undesirable. */ /* Nonzero if access to memory by bytes is slow and undesirable. */
#define SLOW_BYTE_ACCESS 1 #define SLOW_BYTE_ACCESS 1
......
...@@ -1186,9 +1186,15 @@ struct rt_cargs {int gregs, fregs; }; ...@@ -1186,9 +1186,15 @@ struct rt_cargs {int gregs, fregs; };
is undesirable. */ is undesirable. */
#define SLOW_BYTE_ACCESS 1 #define SLOW_BYTE_ACCESS 1
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_ZERO_EXTEND #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* This is BSD, so it wants DBX format. */ /* This is BSD, so it wants DBX format. */
#define DBX_DEBUGGING_INFO #define DBX_DEBUGGING_INFO
......
...@@ -1288,9 +1288,15 @@ struct rs6000_args {int words, fregno, nargs_prototype; }; ...@@ -1288,9 +1288,15 @@ struct rs6000_args {int words, fregno, nargs_prototype; };
is undesirable. */ is undesirable. */
#define SLOW_BYTE_ACCESS 1 #define SLOW_BYTE_ACCESS 1
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_ZERO_EXTEND #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* Define if loading short immediate values into registers sign extends. */ /* Define if loading short immediate values into registers sign extends. */
#define SHORT_IMMEDIATES_SIGN_EXTEND #define SHORT_IMMEDIATES_SIGN_EXTEND
......
...@@ -902,9 +902,15 @@ extern int current_function_anonymous_args; ...@@ -902,9 +902,15 @@ extern int current_function_anonymous_args;
in one reasonably fast instruction. */ in one reasonably fast instruction. */
#define MOVE_MAX 4 #define MOVE_MAX 4
/* Define if normal loads of shorter-than-word items from sign extends /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_SIGN_EXTEND 1 #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) SIGN_EXTEND
/* Define this if zero-extension is slow (more than one real instruction). /* Define this if zero-extension is slow (more than one real instruction).
On the SH, it's only one instruction */ On the SH, it's only one instruction */
......
...@@ -1348,9 +1348,15 @@ extern struct rtx_def *legitimize_pic_address (); ...@@ -1348,9 +1348,15 @@ extern struct rtx_def *legitimize_pic_address ();
gen_rtx (MEM, SImode, gen_rtx (SYMBOL_REF, Pmode, "errno")) gen_rtx (MEM, SImode, gen_rtx (SYMBOL_REF, Pmode, "errno"))
#endif /* 0 */ #endif /* 0 */
/* Define if normal loads of shorter-than-word items from memory clears /* Define if operations between registers always perform the operation
the rest of the bigs in the register. */ on the full register even if a narrower mode is specified. */
#define BYTE_LOADS_ZERO_EXTEND #define WORD_REGISTER_OPERATIONS
/* Define if loading in MODE, an integral mode narrower than BITS_PER_WORD
will either zero-extend or sign-extend. The value of this macro should
be the code that says which one of the two operations is implicitly
done, NIL if none. */
#define LOAD_EXTEND_OP(MODE) ZERO_EXTEND
/* Nonzero if access to memory by bytes is slow and undesirable. /* Nonzero if access to memory by bytes is slow and undesirable.
For RISC chips, it means that access to memory by bytes is no For RISC chips, it means that access to memory by bytes is no
......
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