From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8E1593857C65; Thu, 7 Mar 2024 14:12:58 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8E1593857C65 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1709820778; bh=QlLR2Ysbunim+oa+aSnzhKjcCk1jJPPbyCt6Pg1jRPA=; h=From:To:Subject:Date:In-Reply-To:References:From; b=imNl7vr2mXtWtKe06iBDQu0m7DUuKXa4GtPxBsHYl2xXIQ1EFi2lUBlVMNRy1LWHM B4Jvi0aHVQZnaCwbHnU8FpuZ5Ndz9MMpOQlkN6d/tGQJvZy5AYPA7sC+74qLue2hT/ 5tGTqs25K9i06mIKbp7i4pfYS5EFrjBHskFRW7kM= From: "gjl at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/114252] Introducing bswapsi reduces code performance Date: Thu, 07 Mar 2024 14:12:57 +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: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: gjl 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: --- 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=3D114252 --- Comment #14 from Georg-Johann Lay --- The code in the example is not a perfect bswap, it needs additional shuffli= ng of bytes. The tree passes must know that bswap is not a perfect fit. There must be *some* criterion that depends on the permutation, and when a bswap = is closer to the bswapped-permutation that a non-bswapped permutation is to the original one.=