Commit 37bd08f8 by Hartmut Penner Committed by Hartmut Penner

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
parent b0649028
2003-03-11 Hartmut Penner <hpenner@de.ibm.com>
* 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.
2003-03-11 Neil Booth <neil@daikokuya.co.uk>
* Makefile.in: Update.
......
......@@ -307,7 +307,6 @@ static void hybrid_search_sbitmap PARAMS ((basic_block, sbitmap *, sbitmap *,
enum df_confluence_op,
transfer_function_sbitmap,
sbitmap, sbitmap, void *));
static inline bool read_modify_subreg_p PARAMS ((rtx));
/* Local memory allocation/deallocation routines. */
......@@ -885,7 +884,7 @@ df_ref_record (df, reg, loc, insn, ref_type, ref_flags)
/* Return non-zero if writes to paradoxical SUBREGs, or SUBREGs which
are too narrow, are read-modify-write. */
static inline bool
bool
read_modify_subreg_p (x)
rtx x;
{
......
......@@ -353,3 +353,4 @@ extern void iterative_dataflow_bitmap PARAMS ((bitmap *, bitmap *, bitmap *,
enum df_confluence_op,
transfer_function_bitmap,
int *, void *));
extern bool read_modify_subreg_p PARAMS ((rtx));
......@@ -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. */
......
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