Path: ...!news.mixmin.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: comp.arch Subject: Re: arm ldxr/stxr vs cas Date: Wed, 11 Sep 2024 10:33:16 -0400 Organization: A noiseless patient Spider Lines: 11 Message-ID: References: <07d60bd0a63b903820013ae60792fb7a@www.novabbs.org> <898cf44224e9790b74a0269eddff095a@www.novabbs.org> MIME-Version: 1.0 Content-Type: text/plain Injection-Date: Wed, 11 Sep 2024 16:33:20 +0200 (CEST) Injection-Info: dont-email.me; posting-host="04284103aa79240cdc3b8cfdc887951f"; logging-data="3843335"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1929i1cBR8k+/6BWrSmfqfssbK1rUX20R8=" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:tytAWDVF8KvgnLzuP0ltgrFQoZ0= sha1:qe2cjpPixiH8KAM5/aJXlBG6j/k= Bytes: 1624 > I suspect at least theoretically conditions could exist where > having more than one lock within a cache line would be beneficial. > If lock B is always acquired after lock A, then sharing a cache > line might (I think) improve performance. One would lose I suspect in practice this almost never happens because if it did, it would mean that the program would benefit from merging those two locks into a single one. Stefan