From fe12d76c19ad3eef5a4ac555a519bc14f09d7326 Mon Sep 17 00:00:00 2001 From: Jeff Law Date: Sun, 20 Nov 2016 22:29:36 -0700 Subject: re PR target/48551 (Following source code crashes the c++ compiler on coldfire platform.) 2016-11-20 Jeff Law PR target/48551 * reload.h (struct target_reload): Make x_double_reg_address_ok be per-mode rather. * reload.c (find_reloads_address): Check if double_reg_address_ok is true for the mode of the memory reference. * reload1.c (init_reload): Initialize double_reg_address_ok for each mode. PR target/48551 * gcc.target/m68k/pr48551.c: New test. From-SVN: r242648 --- gcc/reload.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'gcc/reload.h') diff --git a/gcc/reload.h b/gcc/reload.h index 98b75e3..1fc8ecb 100644 --- a/gcc/reload.h +++ b/gcc/reload.h @@ -159,9 +159,6 @@ struct target_reload { which these are valid is the same as spill_indirect_levels, above. */ bool x_indirect_symref_ok; - /* Nonzero if an address (plus (reg frame_pointer) (reg ...)) is valid. */ - bool x_double_reg_address_ok; - /* Nonzero if indirect addressing is supported on the machine; this means that spilling (REG n) does not require reloading it into a register in order to do (MEM (REG n)) or (MEM (PLUS (REG n) (CONST_INT c))). The @@ -181,6 +178,10 @@ struct target_reload { [FIRST_PSEUDO_REGISTER] [MAX_MOVE_MAX / MIN_UNITS_PER_WORD + 1]); + /* Nonzero if an address (plus (reg frame_pointer) (reg ...)) is valid + in the given mode. */ + bool x_double_reg_address_ok[MAX_MACHINE_MODE]; + /* We will only make a register eligible for caller-save if it can be saved in its widest mode with a simple SET insn as long as the memory address is valid. We record the INSN_CODE is those insns here since -- cgit v1.1