From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id DD27D3865479; Fri, 10 May 2024 03:35:02 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DD27D3865479 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1715312102; bh=fVn2BxuHgzUh4canJyyxVPllwDc4HIAb5XX72zD/ByU=; h=From:To:Subject:Date:In-Reply-To:References:From; b=AtVGPA18dzYbeamtQIp4+/MiQLAz36h7Lt9WJnweazmiMuzokM5DbAmGsHytZCOw+ m/YMQKwdvuxuY5rk6AJcdp+JiKxKk5sZEBifCIruhaoIvi3/kZQQ2AWhsOPxqzVjdW 0KSm7hxKjOrTlkC2ksxmOhhUS/0/bajyqVo4TXIQ= From: "xry111 at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/115014] GCC generates incorrect instructions for addressing the data segment through EBP register Date: Fri, 10 May 2024 03:35:01 +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: 13.2.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: enhancement X-Bugzilla-Who: xry111 at gcc dot gnu.org X-Bugzilla-Status: WAITING 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: cc 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=3D115014 Xi Ruoyao changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |xry111 at gcc dot gnu.org --- Comment #5 from Xi Ruoyao --- (In reply to Martin Doucha from comment #2) > (In reply to Andrew Pinski from comment #1) > > I am not so sure this is wanted. GCC assumes a flat memory system for s= tack > > and normal memory accesses . >=20 > This is certainly not wanted in the most common case where the flat memory > assumption is correct. But it should be used for compiling embedded binar= ies > with -ffreestanding argument. No, "Freestanding Environment" has a very specific meaning in the C standar= d.=20 If we must add this it'd be a separate -m{something} argument.=