summaryrefslogtreecommitdiff
path: root/gcc/sched-deps.c
diff options
context:
space:
mode:
authorhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2015-08-07 16:18:09 +0000
committerhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2015-08-07 16:18:09 +0000
commitca3be54b1dc1b91cd7396d23c7c01722834a4108 (patch)
treee6b6eb42328572e63f292ea0725c48ed8916349c /gcc/sched-deps.c
parent9f1638d516f0cad0efeab98ee8e5a460245a737b (diff)
downloadgcc-ca3be54b1dc1b91cd7396d23c7c01722834a4108.tar.gz
Add alternative_mask to ira_implicitly_set_insn_hard_regs
Since ira_implicitly_set_insn_hard_regs may be called outside of ira-lives.c, it can't use the local variable, preferred_alternatives. This patch adds an alternative_mask argument to ira_implicitly_set_insn_hard_regs. gcc/ PR rtl-optimization/67029 * ira-color.c: Include "recog.h" before including "ira-int.h". * target-globals.c: Likewise. * ira-lives.c (ira_implicitly_set_insn_hard_regs): Add an adds an alternative_mask argument and use it instead of preferred_alternatives. * ira.h (ira_implicitly_set_insn_hard_regs): Moved to ... * ira-int.h (ira_implicitly_set_insn_hard_regs): Here. * sched-deps.c: Include "ira-int.h" after including "ira.h". (sched_analyze_insn): Update call to ira_implicitly_set_insn_hard_regs. * sel-sched.c: Include "ira-int.h" after including "ira.h". (implicit_clobber_conflict_p): Update call to ira_implicitly_set_insn_hard_regs. gcc/testsuite/ PR rtl-optimization/67029 * gcc.dg/pr67029.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@226724 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/sched-deps.c')
-rw-r--r--gcc/sched-deps.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/sched-deps.c b/gcc/sched-deps.c
index 3ac66e8eeba..0a8dcb00af9 100644
--- a/gcc/sched-deps.c
+++ b/gcc/sched-deps.c
@@ -43,6 +43,7 @@ along with GCC; see the file COPYING3. If not see
#include "alloc-pool.h"
#include "cselib.h"
#include "ira.h"
+#include "ira-int.h"
#include "target.h"
#ifdef INSN_SCHEDULING
@@ -2891,7 +2892,8 @@ sched_analyze_insn (struct deps_desc *deps, rtx x, rtx_insn *insn)
extract_insn (insn);
preprocess_constraints (insn);
- ira_implicitly_set_insn_hard_regs (&temp);
+ alternative_mask prefrred = get_preferred_alternatives (insn);
+ ira_implicitly_set_insn_hard_regs (&temp, prefrred);
AND_COMPL_HARD_REG_SET (temp, ira_no_alloc_regs);
IOR_HARD_REG_SET (implicit_reg_pending_clobbers, temp);
}