Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> C is a masterpiece of elegance and simplicity and gives you a mental model of how a real computer works

It used to. Now, with multicore systems and out-of-order execution and cache and nearly everything else that makes modern hardware fast enough to use, it is an over-simplified view of the abstraction the hardware wants you to see, but is not detailed enough to guide you when you need extra performance.

As an example, C says nothing about cache lines; its memory model is completely flat. Cache is ideally 'transparent', but we all know that cache hits are a lot faster than misses. C gives you no guidance on how to arrange your data structures to ensure as many hits as possible.



A beginner won't have to worry about that stuff.


So why draw the line there? Why is it ok to abstract away modern hardware, but not ok to abstract away memory management or pointers?


You can write a useful program that only uses one core. You can't write a useful program that doesn't use memory.


But you can write a great deal of useful code that never does any manual memory management.


You asked where you draw the line. My point is that there's a real difference between not using a resource (more than one core) or using it without understanding how it works, because it's hidden behind a paper curtain.


Because understanding pointers makes understanding references a lot easier.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: