summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>2004-04-20 03:57:59 +0000
committerwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>2004-04-20 03:57:59 +0000
commit26a6b397ab75e32831c70bcd2980214c117fea89 (patch)
tree9f167c3380e53fb9a4d41188b8831a8b9f90116f
parentd7aeca92471096e338371f3faf973e5afa5acbeb (diff)
downloadgcc-26a6b397ab75e32831c70bcd2980214c117fea89.tar.gz
Eliminate broken unused function.
* rtl.h (reg_set_last): Delete declaration. * rtlanal.c (reg_set_last): Delete. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@80879 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/rtl.h1
-rw-r--r--gcc/rtlanal.c48
3 files changed, 5 insertions, 49 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 695043ef4af..2d7b398fad5 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2004-04-19 James E Wilson <wilson@specifixinc.com>
+
+ * rtl.h (reg_set_last): Delete declaration.
+ * rtlanal.c (reg_set_last): Delete.
+
2004-04-19 Roger Sayle <roger@eyesopen.com>
* fold-const.c (fold_convert): Make function extern/public.
diff --git a/gcc/rtl.h b/gcc/rtl.h
index f6ebe34caa4..4c443324fd4 100644
--- a/gcc/rtl.h
+++ b/gcc/rtl.h
@@ -1844,7 +1844,6 @@ extern int reg_overlap_mentioned_p (rtx, rtx);
extern rtx set_of (rtx, rtx);
extern void note_stores (rtx, void (*) (rtx, rtx, void *), void *);
extern void note_uses (rtx *, void (*) (rtx *, void *), void *);
-extern rtx reg_set_last (rtx, rtx);
extern int dead_or_set_p (rtx, rtx);
extern int dead_or_set_regno_p (rtx, unsigned int);
extern rtx find_reg_note (rtx, enum reg_note, rtx);
diff --git a/gcc/rtlanal.c b/gcc/rtlanal.c
index c66cc9adc8c..aade423eefe 100644
--- a/gcc/rtlanal.c
+++ b/gcc/rtlanal.c
@@ -1598,54 +1598,6 @@ reg_overlap_mentioned_p (rtx x, rtx in)
}
}
-/* Return the last value to which REG was set prior to INSN. If we can't
- find it easily, return 0.
-
- We only return a REG, SUBREG, or constant because it is too hard to
- check if a MEM remains unchanged. */
-
-rtx
-reg_set_last (rtx x, rtx insn)
-{
- rtx orig_insn = insn;
-
- /* Scan backwards until reg_set_last_1 changed one of the above flags.
- Stop when we reach a label or X is a hard reg and we reach a
- CALL_INSN (if reg_set_last_last_regno is a hard reg).
-
- If we find a set of X, ensure that its SET_SRC remains unchanged. */
-
- /* We compare with <= here, because reg_set_last_last_regno
- is actually the number of the first reg *not* in X. */
- for (;
- insn && GET_CODE (insn) != CODE_LABEL
- && ! (GET_CODE (insn) == CALL_INSN
- && REGNO (x) <= FIRST_PSEUDO_REGISTER);
- insn = PREV_INSN (insn))
- if (INSN_P (insn))
- {
- rtx set = set_of (x, insn);
- /* OK, this function modify our register. See if we understand it. */
- if (set)
- {
- rtx last_value;
- if (GET_CODE (set) != SET || SET_DEST (set) != x)
- return 0;
- last_value = SET_SRC (x);
- if (CONSTANT_P (last_value)
- || ((GET_CODE (last_value) == REG
- || GET_CODE (last_value) == SUBREG)
- && ! reg_set_between_p (last_value,
- insn, orig_insn)))
- return last_value;
- else
- return 0;
- }
- }
-
- return 0;
-}
-
/* Call FUN on each register or MEM that is stored into or clobbered by X.
(X would be the pattern of an insn).
FUN receives two arguments: