I never understood why software has to pay for the lack of memory safety primitives in the hardware.
Memory Safety
111–120 of 157 posts
Re: Memory Safety
#112> Languages that are not memory safe include C, C++, and assembly. False. C and C++ are not memory safe if you use the most common and most performant implementations, sure. At some point these folks are going to have to accept that caveat
Re: Memory Safety
#113Earlier quoted context omitted.
They are, pity that Rust type system has nothing to prevent them outside a very specific use case of in-memory data structures and threads. Make those in-memory data structures writable via OS IPC and all bets are open, regarding what other processes, or kernel extensions, do to the memory segment. Fearless concurrency is welcomed, but lets not overlook the fine print in systems programming.
If you have both sides cooperating, then it's perfectly reasonable to write a safe interface on top of shared memory. If not…well, what do you suggest? Also, pointing at the overwhelming majority of code and going "this is a very specific use case" is also kind of wild, because even in IPC scenarios there will be in-memory data that needs protection.
Re: Memory Safety
#114Earlier quoted context omitted.
Bounds checking of pointers, C Machine kind of. Solaris and Linux SPARC since 2015, for example. https://docs.oracle.com/en/operating-systems/solaris/oracle-... https://docs.kernel.org/arch/sparc/adi.html ARM MTE, as another one, https://learn.arm.com/learning-paths/mobile-graphics-and-gam...
These approaches can only detect linear overflows deterministically. Use-after-frees (temporal safety violations) are only detected with some probability. It's mostly a debugging tool. And MTE requires special firmware, which is usually not available in the cloud because the tag memory reservation is a boot-time decision.
It is kind of interesting how all attempts to improve security are akin to arguing about usefulness of seatbelts when people still die wearing them.
Re: Memory Safety
#115I find it strange that this web site completely ignores the Java ecosystem, which offers memory-safe implementations for most of the protocols and services listed.
Re: Memory Safety
#116Earlier quoted context omitted.
Why do you think data races are not a practical source of bugs?
They are, pity that Rust type system has nothing to prevent them outside a very specific use case of in-memory data structures and threads. Make those in-memory data structures writable via OS IPC and all bets are open, regarding what other processes, or kernel extensions, do to the memory segment. Fearless concurrency is welcomed, but lets not overlook the fine print in systems programming.
Re: Memory Safety
#117Earlier quoted context omitted.
They are, pity that Rust type system has nothing to prevent them outside a very specific use case of in-memory data structures and threads. Make those in-memory data structures writable via OS IPC and all bets are open, regarding what other processes, or kernel extensions, do to the memory segment. Fearless concurrency is welcomed, but lets not overlook the fine print in systems programming.
Are you perhaps confusing data races with race conditions?
Re: Memory Safety
#118Earlier quoted context omitted.
is there actually a programming language that makes race conditions impossible (I am not being facetious, I actually do not know)? if the existence of races makes a language unsafe, then aren't all languages unsafe?
isn’t that the point of languages that have first class actor models something something?
Re: Memory Safety
#119This site is curious in that in incorrectly categorizes go as memory safe. Perhaps in part because the sponsors are invested in using go and benefit from its inclusion in a list of memory safe languages.
Politicians
Re: Memory Safety
#120Now do type safety.