re PR middle-end/44569 (ICE in simplify_subreg for debug insn with CONCATN)

PR middle-end/44569
	* lower-suberg.c (simplify_subreg_concatn): For VOIDmode elements,
	determine the mode of a subreg by GET_MODE_INNER of CONCATN RTX.

From-SVN: r166092
This commit is contained in:
Uros Bizjak 2010-10-30 21:55:16 +02:00
parent 1607a827d1
commit 695ae29578
3 changed files with 27 additions and 19 deletions

View file

@ -1,3 +1,9 @@
2010-10-30 Uros Bizjak <ubizjak@gmail.com>
PR middle-end/44569
* lower-suberg.c (simplify_subreg_concatn): For VOIDmode elements,
determine the mode of a subreg by GET_MODE_INNER of CONCATN RTX.
2010-10-30 H.J. Lu <hongjiu.lu@intel.com>
PR target/46195
@ -92,8 +98,7 @@
pdp11_preferred_output_reload_class, pdp11_secondary_reload,
pdp11_secondary_memory_needed): New function.
(pdp11_return_in_memory): Add other float types.
* config/pdp11/pdp11.h (HARD_REGNO_MODE_OK): Add other float
types.
* config/pdp11/pdp11.h (HARD_REGNO_MODE_OK): Add other float types.
(SECONDARY_MEMORY_NEEDED, CANNOT_CHANGE_MODE_CLASS): Define.
(PREFERRED_RELOAD_CLASS, SECONDARY_RELOAD_CLASS,
REGISTER_MOVE_COST): Delete.
@ -105,8 +110,7 @@
* config/mn10300/mn10300.c (mn10300_tune_string): New variable.
(mn10300_tune_cpu): New variable.
(mn10300_handle_option): Handle -mam34 and -mtune options.
(mn10300_option_override): Convert tune string into tune cpu
variable.
(mn10300_option_override): Convert tune string into tune cpu variable.
(mn10300_legitimate_constant_p): Delete unused local variable.
(is_load_insn): New function.
(is_store_insn): New function.
@ -114,14 +118,13 @@
(TARGET_SCHED_ADJUST_COST): Define.
* config/mn10300/mn10300.opt (mam34): New option.
(mtune): New option.
* config/mn10300/mn10300.h (TARGET_CPU_CPP_BUILTINS): Add AM34
support.
* config/mn10300/mn10300.h (TARGET_CPU_CPP_BUILTINS): Add AM34 support.
(enum processor_type): Add AM34.
(TARGET_AM34): Define.
* config/mn10300/mn10300.md (attr cpu): Add am34.
Add pipeline description.
(movqi, movhi, movsi, movsf, movdf, movdi): Fix predicates. Remove unneeded
alternatives. Add timing attribute.
(movqi, movhi, movsi, movsf, movdf, movdi): Fix predicates.
Remove unneeded alternatives. Add timing attribute.
(pop_pic_reg, am33_addsi3, mn10300_addsi3, am33_subsi3,
mn10300_subsi3, mulsidi3, umulsidi3, am33_mulsi3,
mn10300_mulsi3, udivmodsi4_am33, divmodsi4, am33_andsi3,
@ -167,8 +170,7 @@
(FUNCTION_ARG_ADVANCE): Delete.
* config/cris/cris.c (cris_function_arg_1, cris_function_arg): New
functions.
(cris_function_incoming_arg, cris_function_arg_advance): New
functions.
(cris_function_incoming_arg, cris_function_arg_advance): New functions.
(TARGET_FUNCTION_ARG, TARGET_FUNCTION_INCOMING_ARG): Define.
(TARGET_FUNCTION_ARG_ADVANCE): Define.
@ -215,8 +217,7 @@
* config/crx/crx.h (FUNCTION_ARG, FUNCTION_ARG_ADVANCE): Delete.
* config/crx/crx.c (crx_function_arg): Make static. Take a
const_tree and a bool.
(crx_function_arg_advance): Make static. Take a const_tree and
a bool.
(crx_function_arg_advance): Make static. Take a const_tree and a bool.
(enough_regs_for_param): Take a const_tree.
(TARGET_FUNCTION_ARG, TARGET_FUNCTION_ARG_ADVANCE): Define.
@ -296,11 +297,9 @@
(frv_function_arg_advance): Delete.
* config/frv/frv.h (FUNCTION_ARG, FUNCTION_ARG_ADVANCE): Delete.
* config/frv/frv.c (frv_function_arg): Rename to...
(frv_function_arg_1): Make static. Take const_tree and bool
arguments.
(frv_function_arg_1): Make static. Take const_tree and bool arguments.
(frv_function_arg, frv_function_incoming_arg): New functions.
(frv_function_arg_advance): Make static. Take a const_tree and
a bool.
(frv_function_arg_advance): Make static. Take a const_tree and a bool.
(TARGET_FUNCTION_ARG, TARGET_FUNCTION_INCOMING_ARG): Define.
(TARGET_FUNCTION_ARG_ADVANCE): Define.

View file

@ -396,7 +396,7 @@ simplify_subreg_concatn (enum machine_mode outermode, rtx op,
unsigned int byte)
{
unsigned int inner_size;
enum machine_mode innermode;
enum machine_mode innermode, partmode;
rtx part;
unsigned int final_offset;
@ -409,11 +409,19 @@ simplify_subreg_concatn (enum machine_mode outermode, rtx op,
inner_size = GET_MODE_SIZE (innermode) / XVECLEN (op, 0);
part = XVECEXP (op, 0, byte / inner_size);
partmode = GET_MODE (part);
if (partmode == VOIDmode)
{
gcc_assert (VECTOR_MODE_P (innermode));
partmode = GET_MODE_INNER (innermode);
}
final_offset = byte % inner_size;
if (final_offset + GET_MODE_SIZE (outermode) > inner_size)
return NULL_RTX;
return simplify_gen_subreg (outermode, part, GET_MODE (part), final_offset);
return simplify_gen_subreg (outermode, part, partmode, final_offset);
}
/* Wrapper around simplify_gen_subreg which handles CONCATN. */

View file

@ -67,7 +67,7 @@
* obj-c++.dg/property/dynamic-2.mm: New.
2010-10-29 Artjoms Sinkarovs <artyom.shinakroff@gmail.com>
Andrew Pinski <pinskia@gmail.com>
Andrew Pinski <pinskia@gmail.com>
* gcc.c-torture/execute/vector-shift.c: New testcase.
* gcc.c-torture/execute/vector-shift1.c: Likewise.
@ -83,6 +83,7 @@
* gcc.c-torture/execute/20101011-1.c: Skip on SH.
2010-10-29 Pat Haugen <pthaugen@us.ibm.com>
* gcc.c-torture/execute/20101011-1.c: Fix #ifdef.
2010-10-28 Uros Bizjak <ubizjak@gmail.com>