Borrow Checking, RC, GC, and the Eleven () Other Memory Safety Approaches

#102 · 🔥 188 · 💬 68 · 11 days ago · verdagon.dev · todsacerdoti · 📷
With this wisdom, one can see the vast hidden landscape of memory safety, get a hint about where the programming world might head in the next decades, and even design new memory safety approaches. Our leader Ivan was hoping that this ancient city might contain a fifth memory safety tome, similar to the ancient borrow checking codex that Graydon Hoare found in the Kukulkan pyramid in 2016.We made it to the central pyramid, and discovered a pedestal with a tattered tome, surprisingly intact after all this time. Cornucopia adds temporal memory safety to that with special allocators that don't reuse memory in a page until it's empty and all of the existing capabilities have been revoked via an application-wide memory sweep done concurrently in the background. The only programs I know of with deliberate memory leaks are those whose executions are short enough, and whose target machines have enough virtual memory space, that running out of memory is not a concern. 42 It could be said that regions on its own isn't really a memory safety approach, and it could be said that arena-only programming is just a memory management technique. What do we do with this avalanche of knowledge? Perhaps someone, after reading this article, will go forth and design a new memory safety blend! It's not impossible, I even used this grimoire to make a theoretical blend for C++.The world needs more memory safety blends and techniques! Especially ones that let us have better architectures, more simplicity, and less constraints. When one thinks not just about memory safety but about safety in general, a null-safe functional GC'd language has an edge over other approaches, even over borrow checking which forces long-term-referrable objects into central collections which have their own potential edge cases.
Borrow Checking, RC, GC, and the Eleven () Other Memory Safety Approaches



Send Feedback | WebAssembly Version (beta)