3 ms·
I'm sure some programmers don't need to know this. For example an Erlang or Haskell programmer can't do anything about memory layout anyway, so this knowledge w
by amelius 8y ago
I'm sure some programmers don't need to know this. For example an Erlang or Haskell programmer can't do anything about memory layout anyway, so this knowledge would be of no immediate practical use.
- yetihehe 8y ago> For example an Erlang or Haskell programmer can't do anything about memory layout anyway No, but we can make algorithms that will do things in other ways than standard. Knowing memory layout and behaviour enables programmer to invent better ways to do things. Of course those algorithms are very application specific, but at least it increases solution space. Erlangers mantra here is "profile this" so that you know which one is actually better.
- agentultra 8y agoNot exactly. There's plenty of ways of looking at GC and controlling allocation and lifetimes in Haskell is definitely possible. And when necessary the C FFI is useful to have to write small bits of code to take advantage of particular layouts and drive them from code. See [0]. [0] https://www.youtube.com/watch?v=b4bb8EP_pIE https://www.youtube.com/watch?v=b4bb8EP_pIE