aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernd Schmidt <bernds@redhat.com>2001-01-11 17:02:44 +0000
committerBernd Schmidt <bernds@gcc.gnu.org>2001-01-11 17:02:44 +0000
commitfb6754f0963d3a6571d07d3189eedcf92985219c (patch)
treec1d6a756d2b66bffb76aa47d962ae7bcfcb64074
parentd2796d4ebc4a13a8cc0cbf3b106a680119f569dc (diff)
downloadgcc-fb6754f0963d3a6571d07d3189eedcf92985219c.zip
gcc-fb6754f0963d3a6571d07d3189eedcf92985219c.tar.gz
gcc-fb6754f0963d3a6571d07d3189eedcf92985219c.tar.bz2
Partially undo a previous patch
From-SVN: r38908
-rw-r--r--gcc/ChangeLog9
-rw-r--r--gcc/alias.c35
-rw-r--r--gcc/basic-block.h1
-rw-r--r--gcc/flow.c16
-rw-r--r--gcc/sched-deps.c6
5 files changed, 30 insertions, 37 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 35f1fe0..cb3295e 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,12 @@
+2001-01-11 Bernd Schmidt <bernds@redhat.com>
+
+ * alias.c (throughout): Use REGNO, rather than ORIGINAL_REGNO.
+ * sched-deps.c (deps_may_trap_p): Likewise.
+ * basic-block.h: Remove a comment.
+ * flow.c (PROP_POSTRELOAD): Remove.
+ (update_life_info): Don't add it to prop_flags.
+ (mark_set_1): Lose the code that was enabled by it.
+
2001-01-11 Michael Hayes <mhayes@redhat.com>
* flow.c (flow_call_edges_add): New.
diff --git a/gcc/alias.c b/gcc/alias.c
index 4f9eef3..235d299 100644
--- a/gcc/alias.c
+++ b/gcc/alias.c
@@ -148,8 +148,8 @@ static rtx *new_reg_base_value;
static unsigned int reg_base_value_size; /* size of reg_base_value array */
#define REG_BASE_VALUE(X) \
- (ORIGINAL_REGNO (X) < reg_base_value_size \
- ? reg_base_value[ORIGINAL_REGNO (X)] : 0)
+ (REGNO (X) < reg_base_value_size \
+ ? reg_base_value[REGNO (X)] : 0)
/* Vector of known invariant relationships between registers. Set in
loop unrolling. Indexed by register number, if nonzero the value
@@ -668,7 +668,7 @@ find_base_value (src)
return src;
case REG:
- regno = ORIGINAL_REGNO (src);
+ regno = REGNO (src);
/* At the start of a function, argument registers have known base
values which may be lost later. Returning an ADDRESS
expression here allows optimization based on argument values
@@ -792,7 +792,7 @@ record_set (dest, set, data)
if (GET_CODE (dest) != REG)
return;
- regno = ORIGINAL_REGNO (dest);
+ regno = REGNO (dest);
if (regno >= reg_base_value_size)
abort ();
@@ -873,8 +873,8 @@ record_base_value (regno, val, invariant)
if (GET_CODE (val) == REG)
{
- if (ORIGINAL_REGNO (val) < reg_base_value_size)
- reg_base_value[regno] = reg_base_value[ORIGINAL_REGNO (val)];
+ if (REGNO (val) < reg_base_value_size)
+ reg_base_value[regno] = reg_base_value[REGNO (val)];
return;
}
@@ -892,10 +892,10 @@ canon_rtx (x)
rtx x;
{
/* Recursively look for equivalences. */
- if (GET_CODE (x) == REG && ORIGINAL_REGNO (x) >= FIRST_PSEUDO_REGISTER
- && ORIGINAL_REGNO (x) < reg_known_value_size)
- return reg_known_value[ORIGINAL_REGNO (x)] == x
- ? x : canon_rtx (reg_known_value[ORIGINAL_REGNO (x)]);
+ if (GET_CODE (x) == REG && REGNO (x) >= FIRST_PSEUDO_REGISTER
+ && REGNO (x) < reg_known_value_size)
+ return reg_known_value[REGNO (x)] == x
+ ? x : canon_rtx (reg_known_value[REGNO (x)]);
else if (GET_CODE (x) == PLUS)
{
rtx x0 = canon_rtx (XEXP (x, 0));
@@ -2114,7 +2114,6 @@ init_alias_analysis ()
reg_base_value_size * sizeof (rtx));
memset ((char *)alias_invariant, 0, reg_base_value_size * sizeof (rtx));
}
-
/* The basic idea is that each pass through this loop will use the
"constant" information from the previous pass to propagate alias
@@ -2211,9 +2210,9 @@ init_alias_analysis ()
if (set != 0
&& GET_CODE (SET_DEST (set)) == REG
- && ORIGINAL_REGNO (SET_DEST (set)) >= FIRST_PSEUDO_REGISTER)
+ && REGNO (SET_DEST (set)) >= FIRST_PSEUDO_REGISTER)
{
- unsigned int regno = ORIGINAL_REGNO (SET_DEST (set));
+ unsigned int regno = REGNO (SET_DEST (set));
rtx src = SET_SRC (set);
if (REG_NOTES (insn) != 0
@@ -2229,13 +2228,13 @@ init_alias_analysis ()
else if (REG_N_SETS (regno) == 1
&& GET_CODE (src) == PLUS
&& GET_CODE (XEXP (src, 0)) == REG
- && ORIGINAL_REGNO (XEXP (src, 0)) >= FIRST_PSEUDO_REGISTER
- && (reg_known_value[ORIGINAL_REGNO (XEXP (src, 0))])
+ && REGNO (XEXP (src, 0)) >= FIRST_PSEUDO_REGISTER
+ && (reg_known_value[REGNO (XEXP (src, 0))])
&& GET_CODE (XEXP (src, 1)) == CONST_INT)
{
rtx op0 = XEXP (src, 0);
- if (reg_known_value[ORIGINAL_REGNO (op0)])
- op0 = reg_known_value[ORIGINAL_REGNO (op0)];
+ if (reg_known_value[REGNO (op0)])
+ op0 = reg_known_value[REGNO (op0)];
reg_known_value[regno]
= plus_constant_for_output (op0,
INTVAL (XEXP (src, 1)));
@@ -2293,7 +2292,7 @@ init_alias_analysis ()
rtx base = reg_base_value[ui];
if (base && GET_CODE (base) == REG)
{
- unsigned int base_regno = ORIGINAL_REGNO (base);
+ unsigned int base_regno = REGNO (base);
if (base_regno == ui) /* register set from itself */
reg_base_value[ui] = 0;
else
diff --git a/gcc/basic-block.h b/gcc/basic-block.h
index b017546..eae8e29 100644
--- a/gcc/basic-block.h
+++ b/gcc/basic-block.h
@@ -481,7 +481,6 @@ enum update_life_extent
#define PROP_SCAN_DEAD_CODE 16 /* Scan for dead code. */
#define PROP_AUTOINC 32 /* Create autoinc mem references. */
#define PROP_FINAL 63 /* All of the above. */
-/* Flag number 64 is used internally in flow.c. */
/* Flags for loop discovery. */
diff --git a/gcc/flow.c b/gcc/flow.c
index 862d40f..7340638 100644
--- a/gcc/flow.c
+++ b/gcc/flow.c
@@ -168,10 +168,6 @@ Boston, MA 02111-1307, USA. */
#define EPILOGUE_USES(REGNO) 0
#endif
-/* Not in basic-block.h, since it is private to this file. When set, it
- causes us to keep REG_N_SETS uptodate for original pseudo registers. */
-#define PROP_POSTRELOAD 64
-
/* The obstack on which the flow graph components are allocated. */
struct obstack flow_obstack;
@@ -3066,9 +3062,6 @@ update_life_info (blocks, extent, prop_flags)
tmp = INITIALIZE_REG_SET (tmp_head);
- if (reload_completed)
- prop_flags |= PROP_POSTRELOAD;
-
/* For a global update, we go through the relaxation process again. */
if (extent != UPDATE_LIFE_LOCAL)
{
@@ -4643,7 +4636,6 @@ mark_set_1 (pbi, code, reg, cond, insn, flags)
rtx reg, cond, insn;
int flags;
{
- int orig_regno = -1;
int regno_first = -1, regno_last = -1;
int not_dead = 0;
int i;
@@ -4681,7 +4673,6 @@ mark_set_1 (pbi, code, reg, cond, insn, flags)
/* Fall through. */
case REG:
- orig_regno = ORIGINAL_REGNO (reg);
regno_last = regno_first = REGNO (reg);
if (regno_first < FIRST_PSEUDO_REGISTER)
regno_last += HARD_REGNO_NREGS (regno_first, GET_MODE (reg)) - 1;
@@ -4826,7 +4817,7 @@ mark_set_1 (pbi, code, reg, cond, insn, flags)
/* Additional data to record if this is the final pass. */
if (flags & (PROP_LOG_LINKS | PROP_REG_INFO
- | PROP_DEATH_NOTES | PROP_AUTOINC | PROP_POSTRELOAD))
+ | PROP_DEATH_NOTES | PROP_AUTOINC))
{
register rtx y;
register int blocknum = pbi->bb->index;
@@ -4841,11 +4832,6 @@ mark_set_1 (pbi, code, reg, cond, insn, flags)
pbi->reg_next_use[i] = 0;
}
- /* After reload has completed, try to keep REG_N_SETS uptodate for
- the original pseudos. */
- if ((flags & PROP_POSTRELOAD) && orig_regno >= FIRST_PSEUDO_REGISTER)
- REG_N_SETS (orig_regno) += 1;
-
if (flags & PROP_REG_INFO)
{
for (i = regno_first; i <= regno_last; ++i)
diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c
index 4a7f72b..67ea68b 100644
--- a/gcc/sched-deps.c
+++ b/gcc/sched-deps.c
@@ -96,9 +96,9 @@ deps_may_trap_p (mem)
rtx addr = XEXP (mem, 0);
if (REG_P (addr)
- && ORIGINAL_REGNO (addr) >= FIRST_PSEUDO_REGISTER
- && reg_known_value[ORIGINAL_REGNO (addr)])
- addr = reg_known_value[ORIGINAL_REGNO (addr)];
+ && REGNO (addr) >= FIRST_PSEUDO_REGISTER
+ && reg_known_value[REGNO (addr)])
+ addr = reg_known_value[REGNO (addr)];
return rtx_addr_can_trap_p (addr);
}