r/ProgrammingLanguages • u/baehyunsol Sodigy • Jul 27 '26
Why is everyone creating systems programming languages?
I see a lot of new programming languages here. I love reading the documents of the languages and sometimes actually run their compilers. Many of the projects are AI-driven, but that's fine. It's still fun to see what problems they're trying to solve and how they actually solved the problems.
Reading the documents, I realized that most new languages, especially AI-written ones, are "systems programming languages". They're trying to solve the problems that C/C++/Zig/Rust have solved (or are trying to solve), and their syntax is mixture of C/Zig/Rust.
Why? Why is everyone trying to compete with C/C++?
There are so many kinds of languages. Haskell demonstrates how pure a language can be, Python is perfect when you only have 5 minutes to write code and don't care about the output, Java runs on 3 billion machines, ...
View all comments
Show parent comment
1
u/WittyStick Jul 28 '26 edited Jul 28 '26
Current CPUs are typically in the ~3-5 cycles range for L1 cache accesses, which is good, provided our code is cache-friendly. One issue is that we spend two decades, the '90s and '00s promoting "OOP," which happens to be ill-suited to modern hardware because it's not very cache-friendly. This is part of the answer to OP's question too: language designers are often looking at ways to make their code more cache-friendly without sacrificing programmer ergonomics, in contrast to the mainstream OOP languages which have the ergonomics, but lots of pointer chasing and not maximizing cache usage.
That's what we have now - the central system is called main memory, aka the von-Neumann bottleneck.
There's still a need for decent size memories (much larger than cache), which are fast to access, but don't necessarily need to be shared between all cores. I think we will see more on-chip memory (like Apple's M3) - but I would hope that hardware designers explore other options than a single main memory contested by all cores - and treat the problem of fetching data as a routing problem between cores. Particularly if we're going to continue adding cores - if we get 128/256 cores and there's still only one main memory, we're missing out on huge opportunities. I'm not suggesting we get rid of main memory altogether though - there are still uses for a memory shared between all cores - but we don't actually need it for a lot of things because the code isn't even thread-safe to begin with. Anything
thread_localfor example would not need to be in main memory - it could sit in a smaller memory associated with one or more cores which the thread runs on, but which other cores cannot access directly.Possibly, but not necessarily. We'd certainly need to change the way we use our existing languages (ie, C). We've had segmented memories before, but we don't necessarily need them in the programming model - we could have a facade of a single virtual address space like we have now, but where different parts of that memory are handled by different cores on the processor. A pointer dereference may not be a direct memory access, but it may need to request the memory at that address from another core.
This is why Fil-C is getting a lot of attention. It can add bounds checking to existing C codebases with only small cost.
I think there's much more to explore in static guarantees that can eliminate these overflow errors without any runtime cost. We can omit some runtime bounds checking if we've already proved at compile time that OOB accesses would not be possible.