From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 0EB143858C62; Wed, 12 Jul 2023 17:16:53 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 0EB143858C62 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1689182213; bh=mGivjE+uc4I0FGAXzSjWzTDngtmVLgEEAUAf5M/IxZc=; h=From:To:Subject:Date:In-Reply-To:References:From; b=O475VXwWDRjGnixt6b9gJ0MYF2M3kcyNMqWw0VYwfNWUQ/MDN+rMSq3NiKNyu/l8Q 15EoEAYFUGCoGGhJ3BijwbgXeiXnHkmDx1/6dIUSsaflxjwutRUx0rv+9IQ08AyTJh o+Hu3YxR5ppmcrIyT0DpRjbUMa6risj8kT94vAx0= From: "ebotcazou at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/110592] [SPARC] GCC should default to TSO memory model when compiling for sparc32 Date: Wed, 12 Jul 2023 17:16:52 +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: 12.2.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: ebotcazou at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: INVALID 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=3D110592 --- Comment #9 from Eric Botcazou --- > I don't understand, how would that help? As I understand it, whenever > `-mcpu=3Dv7', the memory model is just ignored -- even if we set it to TS= O -- > because all rules that depend on it are gated on TARGET_V8 || TARGET_V9 or > simila Well, the subject of the PR is "GCC should default to TSO memory model when compiling for sparc32" so you'll get exactly that. > I'm not asking for you to change defaults in Linux or Solaris -- I'm just > asking to be _able_ to say `-mcpu=3Dv7 -mmemory-model=3Dtso' and get v7-o= nly > instruction streams with the LDSTUBs needed for TSO. Right now, with > `-mcpu=3Dv7', passing `-mmemory-model=3Dtso' has no effect. I'm suggesting changing the default *like* on Linux or Solaris, not to chan= ge anything on Linux or Solaris. So you want to mix memory models and synchronization instructions with -mcpu=3Dv7, although they were introduced in the V8 architecture?=