https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68404
--- Comment #30 from Bernd Schmidt <bernds at gcc dot gnu.org> ---
Something like this maybe? I don't know much about the machine and can't say
whether the earlyclobber is justified, but looking at my dumps this appears to
prevent the problematic peephole from triggering. No testing beyond that.
Index: rs6000.c
===================================================================
--- rs6000.c (revision 233217)
+++ rs6000.c (working copy)
@@ -35801,6 +35801,9 @@ fusion_gpr_load_p (rtx addis_reg, /* reg
if (!fusion_gpr_addis (addis_value, GET_MODE (addis_value)))
return false;
+ if (reg_overlap_mentioned_p (target, addis_value))
+ return false;
+
/* Allow sign/zero extension. */
if (GET_CODE (mem) == ZERO_EXTEND
|| (GET_CODE (mem) == SIGN_EXTEND && TARGET_P8_FUSION_SIGN))