summaryrefslogtreecommitdiff
path: root/gcc/cse.c
diff options
context:
space:
mode:
authorkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>2003-05-03 14:25:22 +0000
committerkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>2003-05-03 14:25:22 +0000
commitd5f9786fae594d6d9f449e98620f3009d9a6710d (patch)
tree7ad4bd29e44c9c37b87311753f154d5fa72e515b /gcc/cse.c
parentfcf31ac6ce1b003bd96382d41e617bf1a803aff2 (diff)
downloadgcc-d5f9786fae594d6d9f449e98620f3009d9a6710d.tar.gz
* emit-rtl.c (last_call_insn, add_function_usage_to): New functions.
* rtl.h (last_call_insn, add_function_usage_to): New prototypes. * builtins.c (expand_builtin_apply): Use the new emit-rtl functions. * calls.c (emit_call_1): Likewise. (expand_call): For calls initializing constant memory, replace emission of standalone mem /u clobber with function usage entry. * expr.c (emit_block_move_via_libcall): Likewise. * cse.c (count_reg_usage, case EXPR_LIST): New case. * flow.c (propagate_one_insn): Pass entire operand of CALL_INSN_FUNCTION_USAGE to mark_used_regs. * integrate.c (try_constants): For CALL_INSNs, substitute constants within the FUNCTION_USAGE also. * loop.c (prescan_loop): Note clobbers of const mem mentioned in FUNCTION_USAGE lists. * reload1.c (replace_pseudos_in): Renamed. (reload): Use it for clobbers surviving until the end of the reload. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@66429 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cse.c')
-rw-r--r--gcc/cse.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/gcc/cse.c b/gcc/cse.c
index a90f0d8979e..01c583cae07 100644
--- a/gcc/cse.c
+++ b/gcc/cse.c
@@ -7515,6 +7515,17 @@ count_reg_usage (x, counts, dest, incr)
count_reg_usage (XEXP (note, 0), counts, NULL_RTX, incr);
return;
+ case EXPR_LIST:
+ if (REG_NOTE_KIND (x) == REG_EQUAL
+ || (REG_NOTE_KIND (x) != REG_NONNEG && GET_CODE (XEXP (x,0)) == USE)
+ /* FUNCTION_USAGE expression lists may include (CLOBBER (mem /u)),
+ involving registers in the address. */
+ || GET_CODE (XEXP (x, 0)) == CLOBBER)
+ count_reg_usage (XEXP (x, 0), counts, NULL_RTX, incr);
+
+ count_reg_usage (XEXP (x, 1), counts, NULL_RTX, incr);
+ return;
+
case INSN_LIST:
abort ();