From 81217be921244ece2f9246bd4ed3991ba71ed68b Mon Sep 17 00:00:00 2001 From: Daniel Berlin Date: Tue, 11 Dec 2001 22:50:35 +0000 Subject: [PATCH] sched-rgn.c (CONST_BASED_ADDRESS_P): CONST_INT -> CONSTANT_P. 2001-12-11 Daniel Berlin * sched-rgn.c (CONST_BASED_ADDRESS_P): CONST_INT -> CONSTANT_P. (may_trap_exp): Stores only are risk if they trap, too, not just if code == MEM. From-SVN: r47900 --- gcc/ChangeLog | 6 ++++++ gcc/sched-rgn.c | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 22edc49e5ff..acd76f34710 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2001-12-11 Daniel Berlin + + * sched-rgn.c (CONST_BASED_ADDRESS_P): CONST_INT -> CONSTANT_P. + (may_trap_exp): Stores only are risk if they trap, too, not just + if code == MEM. + 2001-12-11 Aldy Hernandez * flow.c (find_regno_partial): Indent properly. Add a default to diff --git a/gcc/sched-rgn.c b/gcc/sched-rgn.c index cc3fc9ae05e..ab5adee8159 100644 --- a/gcc/sched-rgn.c +++ b/gcc/sched-rgn.c @@ -1566,8 +1566,8 @@ enum INSN_TRAP_CLASS (GET_CODE (x) == REG \ || ((GET_CODE (x) == PLUS || GET_CODE (x) == MINUS \ || (GET_CODE (x) == LO_SUM)) \ - && (GET_CODE (XEXP (x, 0)) == CONST_INT \ - || GET_CODE (XEXP (x, 1)) == CONST_INT))) + && (CONSTANT_P (XEXP (x, 0)) \ + || CONSTANT_P (XEXP (x, 1))))) /* Turns on the fed_by_spec_load flag for insns fed by load_insn. */ @@ -1738,7 +1738,7 @@ may_trap_exp (x, is_store) code = GET_CODE (x); if (is_store) { - if (code == MEM) + if (code == MEM && may_trap_p (x)) return TRAP_RISKY; else return TRAP_FREE;