Factor out the mode handling in lower-subreg.c
authorRichard Sandiford <richard.sandiford@linaro.org>
Wed, 1 Nov 2017 13:51:28 +0000 (13:51 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Wed, 1 Nov 2017 13:51:28 +0000 (13:51 +0000)
commit8536340f4930c47a5b444da1a2d3ad21519b5676
tree58a84b77e189c3dc96c5081b85d2ba0efad24d45
parent8c4dcf35d54e111156d78801111633feb11de87a
Factor out the mode handling in lower-subreg.c

This patch adds a helper routine (interesting_mode_p) to lower-subreg.c,
to make the decision about whether a mode can be split and, if so,
calculate the number of bytes and words in the mode.  At present this
function always returns true; a later patch will add cases in which it
can return false.

2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
    Alan Hayward  <alan.hayward@arm.com>
    David Sherwood  <david.sherwood@arm.com>

gcc/
* lower-subreg.c (interesting_mode_p): New function.
(compute_costs, find_decomposable_subregs, decompose_register)
(simplify_subreg_concatn, can_decompose_p, resolve_simple_move)
(resolve_clobber, dump_choices): Use it.

Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r254308
gcc/ChangeLog
gcc/lower-subreg.c