diff options
author | Hartmut Penner <hpenner@de.ibm.com> | 2003-03-11 09:17:38 +0000 |
---|---|---|
committer | Hartmut Penner <hpenner@gcc.gnu.org> | 2003-03-11 09:17:38 +0000 |
commit | 37bd08f8df0003521d3da3b37a25235fd421bce6 (patch) | |
tree | 99c6c896b78762f0154b920cb1e21308b46f43d3 /gcc/sched-deps.c | |
parent | b0649028b4627e6e5e2eb9fd999be8a67da65566 (diff) | |
download | gcc-37bd08f8df0003521d3da3b37a25235fd421bce6.zip gcc-37bd08f8df0003521d3da3b37a25235fd421bce6.tar.gz gcc-37bd08f8df0003521d3da3b37a25235fd421bce6.tar.bz2 |
df.c (read_modify_subreg_p): Change from static to global.
* df.c (read_modify_subreg_p): Change from static to global.
* df.h (read_modify_subreg_p): Add prototype.
* sched-deps.c (sched_analyze_1): Generate true dependency for
strict_low_part, certain subregs and zero/sign_extract.
From-SVN: r64164
Diffstat (limited to 'gcc/sched-deps.c')
-rw-r--r-- | gcc/sched-deps.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c index b3c619d..874ebc2 100644 --- a/gcc/sched-deps.c +++ b/gcc/sched-deps.c @@ -42,6 +42,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA #include "sched-int.h" #include "params.h" #include "cselib.h" +#include "df.h" extern char *reg_known_equiv_p; extern rtx *reg_known_value; @@ -468,6 +469,19 @@ sched_analyze_1 (deps, x, insn) while (GET_CODE (dest) == STRICT_LOW_PART || GET_CODE (dest) == SUBREG || GET_CODE (dest) == ZERO_EXTRACT || GET_CODE (dest) == SIGN_EXTRACT) { + if (GET_CODE (dest) == STRICT_LOW_PART + || GET_CODE (dest) == ZERO_EXTRACT + || GET_CODE (dest) == SIGN_EXTRACT + || read_modify_subreg_p (dest)) + { + /* These both read and modify the result. We must handle + them as writes to get proper dependencies for following + instructions. We must handle them as reads to get proper + dependencies from this to previous instructions. + Thus we need to call sched_analyze_2. */ + + sched_analyze_2 (deps, XEXP (dest, 0), insn); + } if (GET_CODE (dest) == ZERO_EXTRACT || GET_CODE (dest) == SIGN_EXTRACT) { /* The second and third arguments are values read by this insn. */ |