[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
|
|
Subscribe / Log in / New account

C++ already gives us a tool for pointer zapping

C++ already gives us a tool for pointer zapping

Posted Oct 17, 2024 23:58 UTC (Thu) by PaulMcKenney (✭ supporter ✭, #9624)
In reply to: C++ already gives us a tool for pointer zapping by jrtc27
Parent article: Zapping pointers out of thin air

Good to hear, thank you!

If you can say, what is the performance of the CAS(A)(L) instructions that handle both the address and the capability compared to those that handle only the address?


to post comments

C++ already gives us a tool for pointer zapping

Posted Oct 18, 2024 0:41 UTC (Fri) by jrtc27 (subscriber, #107748) [Link] (1 responses)

Performance is always going to be dependent on the implementation, as a tradeoff with power and area, and there are some quirks on Morello due to being an experimental prototype implementation, but in general it would be reasonable to expect them to perform somewhere between plain CAS(A)(L) and CAS(A)(L)P. On a high-performance implementation there will likely be a 128-bit data path already there (true of Morello) so they probably all perform about the same, but a lower-performance implementation could choose to have a narrower data path to reduce core area and take an extra cycle. But in terms of cache coherency traffic it's the same, it still fits in a single cache line, you're just accessing more of that cache line.

C++ already gives us a tool for pointer zapping

Posted Oct 18, 2024 16:36 UTC (Fri) by PaulMcKenney (✭ supporter ✭, #9624) [Link]

Very good, thank you!

With that performance issue mostly out of the way, one big remaining issue is the memory occupancy. Interesting tradeoff, the overhead of double-size pointers vs. the overhead of killer static analysis. ;-)


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds