From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id B71503858C54; Wed, 26 Apr 2023 06:41:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B71503858C54 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1682491285; bh=KGnIVXz5U9cq6Nuq6M1ghQSwcORP3jzFXNWEIsc36Lg=; h=From:To:Subject:Date:In-Reply-To:References:From; b=Q7vm0TUrScan+KRM/OQ8YzwaDGYIHxFwrNk7AZlLL+xd1FxDb3AZV6M1U+F+rG2gz UBrwiftgRqrrNgb2g7ZUZwYKGVL+npLVw1t7npop8trvgiaxgusfzRdnpidgcGg5yw m9rUc6LKbYUmKGbpB5VZyC3zPYkUHRI1zq9LPI/0= From: "crazylht at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/109610] [14 regression] gcc.target/powerpc/dform-3.c fails after r14-172-g0368d169492017 Date: Wed, 26 Apr 2023 06:41:25 +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: 14.0 X-Bugzilla-Keywords: testsuite-fail X-Bugzilla-Severity: normal X-Bugzilla-Who: crazylht at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 14.0 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D109610 --- Comment #5 from Hongtao.liu --- One solution is add an peephole for handle such redudancy. +;; Peephole to catch memory loads to VSX_REG and then moves to GENERAL_REG= S. +(define_peephole2 + [(set (match_operand:VSX_M 0 "vsx_register_operand") + (match_operand:VSX_M 1 "memory_operand")) + (set (match_operand:VSX_M 2 "int_reg_operand") + (match_dup 0))] + "TARGET_POWERPC64 && VECTOR_MEM_VSX_P (mode) + && peep2_reg_dead_p (2, operands[0])" + [(set (match_dup 2) (match_dup 1))]) If powerpc maintainer doesn't like this way, another alternative is add a target hook in RA to still use GENEREAL_REGS for other targets, but use NO_= REGS only for x86.=