diff options
author | Jan Hubicka <jh@suse.cz> | 2002-07-23 14:08:10 +0200 |
---|---|---|
committer | Gerald Pfeifer <gerald@gcc.gnu.org> | 2002-07-23 12:08:10 +0000 |
commit | 2b773ee2c1954b982aac0ee71fd6e5ae148e4691 (patch) | |
tree | 6ad4354996bd2595d502fa3e71a030e6cfb95ec4 /gcc/gcse.c | |
parent | a0dc500c860478e0917fd98ad618ec65482fe395 (diff) | |
download | gcc-2b773ee2c1954b982aac0ee71fd6e5ae148e4691.tar.gz |
gcse.c (try_replace_reg): Use num_changes_pending.
2002-07-23 Jan Hubicka <jh@suse.cz>
* gcse.c (try_replace_reg): Use num_changes_pending.
* recog.c (num_changes_pending): New function.
(validate_replace_src): Use validate_repalce_src_group.
(validate_replace_src_group): New.
* recog.h (validate_repalce_src_group): New.
(num_changes_pending): Likewise.
From-SVN: r55677
Diffstat (limited to 'gcc/gcse.c')
-rw-r--r-- | gcc/gcse.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/gcc/gcse.c b/gcc/gcse.c index 37fa2d610a1..620b98636be 100644 --- a/gcc/gcse.c +++ b/gcc/gcse.c @@ -3977,10 +3977,9 @@ try_replace_reg (from, to, insn) int success = 0; rtx set = single_set (insn); - if (reg_mentioned_p (from, PATTERN (insn))) - { - success = validate_replace_src (from, to, insn); - } + validate_replace_src_group (from, to, insn); + if (num_changes_pending () && apply_change_group ()) + success = 1; if (!success && set && reg_mentioned_p (from, SET_SRC (set))) { |