From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E93923A4080C; Fri, 23 Apr 2021 00:32:56 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E93923A4080C From: "iains at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/100152] [10.3, 11, 12 Regression] used caller-saved register not preserved across a call. Date: Fri, 23 Apr 2021 00:32:56 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 10.3.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: iains at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 10.4 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Apr 2021 00:32:57 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D100152 --- Comment #28 from Iain Sandoe --- reduced test case: ___UTF_8_put(char *a, int b) { char *c =3D a; int bytes; if (b <=3D 15) bytes =3D 2; else if (b <=3D 255) bytes =3D 4; else if (b <=3D 4095) bytes =3D 5; else bytes =3D 6; c =3D *a =3D c; switch (bytes) { case 6: *--c =3D b >>=3D 6; case 5: *--c =3D b; b >>=3D 6; } *c =3D bytes + b; } ___SCMOBJ_to_NONNULLSTRING(d) { { unsigned long g, h; char c; h =3D ((long *)1)[1]; g =3D 0; for (; g < h; g++) i(); g =3D 0; for (; g < h; g++) ___UTF_8_put(c, (long)*((unsigned *)d + (g << 2 >> 2)) << 2 >> 2); } }=