From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.gentoo.org (smtp.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) by sourceware.org (Postfix) with ESMTP id ED88E3858D37 for ; Wed, 16 Feb 2022 07:15:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org ED88E3858D37 Received: by smtp.gentoo.org (Postfix, from userid 559) id B0D65342DA7; Wed, 16 Feb 2022 07:15:07 +0000 (UTC) Date: Wed, 16 Feb 2022 02:15:05 -0500 From: Mike Frysinger To: Hans-Peter Nilsson Cc: gdb-patches@sourceware.org Subject: Re: [PATCH 08/12] sim cris: Unbreak --disable-sim-hardware builds Message-ID: Mail-Followup-To: Hans-Peter Nilsson , gdb-patches@sourceware.org References: <20220214225824.AC90A20439@pchp3.se.axis.com> <20220214230512.7B80720439@pchp3.se.axis.com> <20220216055419.AC9A020411@pchp3.se.axis.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="Kva1UF6/Z47KCEiN" Content-Disposition: inline In-Reply-To: <20220216055419.AC9A020411@pchp3.se.axis.com> X-Spam-Status: No, score=-5.6 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Feb 2022 07:15:12 -0000 --Kva1UF6/Z47KCEiN Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 16 Feb 2022 06:54, Hans-Peter Nilsson wrote: > Date: Tue, 15 Feb 2022 23:51:16 -0500 Mike Frysinger > > On 15 Feb 2022 00:05, Hans-Peter Nilsson via Gdb-patches wrote: > > > +#if WITH_HW > > > if (cris_have_900000xxif) > > > sim_hw_parse (sd, "/core/%s/reg %#x %i", "cris_900000xx", 0x9000= 0000, 0x100); > > > +#else > > > + /* With the option disabled, nothing should be able to set this va= riable. > > > + We should "use" it, though, and why not assert that it isn't se= t. */ > > > + ASSERT (! cris_have_900000xxif); > > > +#endif > >=20 > > WITH_HW is always defined to either 1 or 0. could you write: > > if (WITH_HW) > > ... > > else > > ... > >=20 > > this avoids bit rot in the uncommon configure paths >=20 > I don't think that's a good idea, because then we'd rely on > the sim_hw_parse reference go away at *all* optimization > levels. we prob should rework the sim-hw module a bit to handle this scenario. oth= er modules (like sim-profile) handle this internally. basically we should have a stable API regardless of configure settings. then we wouldn't rely on DCE kicking in all the time. -mike --Kva1UF6/Z47KCEiN Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEuQK1JxMl+JKsJRrUQWM7n+g39YEFAmIMpHkACgkQQWM7n+g3 9YFFMRAAqAqX3Ge0xGpVtjJhANVSLR3JeivOfD8RSR6bvY7g9c1VZ96KA197DtDs p1BaJE41/Gw9hrVEyi6RP7BNL4byx5SVW8EwJZiUi5BmIE7Ji7B/QvIHegWd8dYz 3I8vmxMagaacR/GpxO8jN+r9OGKRR69W13TvhFQyt7CRjb8xGPmYWZW8hG8rkvBI 2RVEb+GjIeL3oSdOFNlLrYhk4u1z9VmC/C5LGhX0uRbMdKlHpjU4X187ZG11yAYQ CV+vOANOw8XVtIfPMtuEZ7nX/sIyqP5jwIEoHx//ME4rC9FluTmkb1MTJHRuFFNm wNeLKcWB8EOWxvOpWntlkpq+E3PLxyVmip/CPX45Z/pXdmuxwH74MSCmYGYBaogg BJzn5tRTQ+fb8dueGicEhFHxWDiEnlVCKAGJcC5Z6kRVfW6E2Yd8W4xWq0dJACZ9 NW4RTOYc/3Tm7FkIGUbgujwaCYX3yQ4EKCmBjWti47LbnznKaer9HlW5fhCAC2Jk AS8QUfh4DJESmlOdvbfWcphE6ZaYeFrrjCl7MuWYtXQJzzNBI/b+DqJNGZNyAKn8 Hkwnztws+aNLMYHjqi4S9QjrEf3SgjjOtGOTZVAyWVHIhOUB9klWlCisXUWivE1a u91h88QSnOGwJtj7uq/bxP6FfIwg3t/BTEcIpnDZscjd3JVVS0Q= =jK0j -----END PGP SIGNATURE----- --Kva1UF6/Z47KCEiN--