Skip to content

Commit

Permalink
Handle WORD_REGISTER_OPERATIONS when reloading (subreg (reg))
Browse files Browse the repository at this point in the history
gcc/
	PR target/78660
	* lra-constraints.c (curr_insn_transform): Handle
	WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245598 138bc75d-0d04-0410-961f-82ee72b054a4
  • Loading branch information
mpf committed Feb 20, 2017
1 parent 2f78ea2 commit a547b44
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
6 changes: 6 additions & 0 deletions gcc/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2017-02-20 Matthew Fortune <matthew.fortune@imgtec.com>

PR target/78660
* lra-constraints.c (curr_insn_transform): Handle
WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.

2017-02-19 Uros Bizjak <ubizjak@gmail.com>

Revert:
Expand Down
10 changes: 9 additions & 1 deletion gcc/lra-constraints.c
Original file line number Diff line number Diff line change
Expand Up @@ -4130,7 +4130,15 @@ curr_insn_transform (bool check_only_p)
&& (goal_alt[i] == NO_REGS
|| (simplify_subreg_regno
(ira_class_hard_regs[goal_alt[i]][0],
GET_MODE (reg), byte, mode) >= 0)))))
GET_MODE (reg), byte, mode) >= 0)))
/* WORD_REGISTER_OPERATIONS targets require the register
to be reloaded when the outer mode is strictly
narrower than the inner mode. Note: It may be
necessary to always reload the inner mode here but it
requires further investigation. */
|| (GET_MODE_PRECISION (mode)
< GET_MODE_PRECISION (GET_MODE (reg))
&& WORD_REGISTER_OPERATIONS)))
{
if (type == OP_OUT)
type = OP_INOUT;
Expand Down

0 comments on commit a547b44

Please sign in to comment.