From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 35E6D3858430; Tue, 21 May 2024 13:04:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 35E6D3858430 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1716296657; bh=Sa1f97CQsp+FqcDYuvC2UMPqdQuyCk5vRrrrAUoiVFU=; h=From:To:Subject:Date:In-Reply-To:References:From; b=NcnlyKsqfg90cuQOqXBHIRpM66jutdmK9S5ZYDKTpdYeXC9fzyk5FiWJE2JZFruRI cDxaLROvZdW6t1c+dZ14tYU59HF/Aqrnn6+6wSrLasbMowswAqo5hm/LThjFyfgkjA uViPs/UekkoT3lRN8oFTObfkabrdqb67DxvztHhc= From: "chenglulu at loongson dot cn" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/114978] [14/15 regression] 548.exchange2_r 14%-28% regressions on Loongarch64 after gcc 14 snapshot 20240317 Date: Tue, 21 May 2024 13:04:17 +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: chenglulu at loongson dot cn 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.2 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=3D114978 --- Comment #22 from chenglulu --- (In reply to Xi Ruoyao from comment #21) > (In reply to chenglulu from comment #19) > > diff --git a/gcc/config/loongarch/loongarch.cc > > b/gcc/config/loongarch/loongarch.cc > > index e7835ae34ae..6a808cb0a5c 100644 > > --- a/gcc/config/loongarch/loongarch.cc > > +++ b/gcc/config/loongarch/loongarch.cc > > @@ -2383,7 +2383,7 @@ loongarch_address_insns (rtx x, machine_mode mode, > > bool might_split_p) > > return factor; > >=20=20 > > case ADDRESS_REG_REG: > > - return factor; > > + return factor * 3; > >=20=20 > > case ADDRESS_CONST_INT: > > return lsx_p ? 0 : factor; > >=20 > > With this patch, -march=3Dla464 has a score of 11.9. > > However, the specific revision plan has not yet been decided. >=20 > Hmm are ldx and stx really so slow? I think it's more like it's because LDX/STX uses an extra register.=