https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71779
Bernd Edlinger <bernd.edlinger at hotmail dot de> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |bernd.edlinger at hotmail dot
de
--- Comment #9 from Bernd Edlinger <bernd.edlinger at hotmail dot de> ---
(In reply to James Greenhalgh from comment #2)
> ---
>
> So I have two questions.
>
> First, where did the DImode paradoxical subreg come from in the first place,
> and why wasn't it a zero-extend?
>
I think that comes from store_bit_field_using_insv.
This can be changed to a zero_extract, but I am not
sure if that is the reason for the wrong code.
Index: expmed.c
===================================================================
--- expmed.c (revision 238694)
+++ expmed.c (working copy)
@@ -664,14 +664,7 @@ store_bit_field_using_insv (const extraction_insn
if we must narrow it, be sure we do it correctly. */
if (GET_MODE_SIZE (GET_MODE (value)) < GET_MODE_SIZE (op_mode))
- {
- tmp = simplify_subreg (op_mode, value1, GET_MODE (value), 0);
- if (! tmp)
- tmp = simplify_gen_subreg (op_mode,
- force_reg (GET_MODE (value),
- value1),
- GET_MODE (value), 0);
- }
+ tmp = convert_to_mode (op_mode, value1, 1);
else
{
tmp = gen_lowpart_if_possible (op_mode, value1);
at least it changes insn 1047 to zero_extend:
(insn 1047 1046 1048 (set (reg:DI 479)
(zero_extend:DI (reg:SI 480))) isl_input.c:2496 -1
(nil))
not sure if this changes anything...