From: Alan Modra Date: Wed, 27 Mar 2019 01:12:35 +0000 (+1030) Subject: [RS6000] Don't rely on rs6000_hard_regno_mode_ok being zero X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=914be15cf3f8bd387c93dfe7b927df18f4462640;p=gcc.git [RS6000] Don't rely on rs6000_hard_regno_mode_ok being zero * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Always assign rs6000_hard_regno_mode_ok_p[m][r]. Formatting. From-SVN: r269959 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index a298f878bbb..f86b2ec7556 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2019-03-27 Alan Modra + + * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Always + assign rs6000_hard_regno_mode_ok_p[m][r]. Formatting. + 2019-03-26 Andrew Waterman Jim Wilson diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index a7590db013e..03c91432bff 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -3463,13 +3463,13 @@ rs6000_init_hard_regno_mode_ok (bool global_init_p) for (r = 0; HARD_REGISTER_NUM_P (r); ++r) for (m = 0; m < NUM_MACHINE_MODES; ++m) rs6000_hard_regno_nregs[m][r] - = rs6000_hard_regno_nregs_internal (r, (machine_mode)m); + = rs6000_hard_regno_nregs_internal (r, (machine_mode) m); /* Precalculate TARGET_HARD_REGNO_MODE_OK. */ for (r = 0; HARD_REGISTER_NUM_P (r); ++r) for (m = 0; m < NUM_MACHINE_MODES; ++m) - if (rs6000_hard_regno_mode_ok_uncached (r, (machine_mode)m)) - rs6000_hard_regno_mode_ok_p[m][r] = true; + rs6000_hard_regno_mode_ok_p[m][r] + = rs6000_hard_regno_mode_ok_uncached (r, (machine_mode) m); /* Precalculate CLASS_MAX_NREGS sizes. */ for (c = 0; c < LIM_REG_CLASSES; ++c)