4 ms·
I'm not sure what's supposed to be confusing here but one thing I don't know is why it was called the heap. Did they use heap data structures or something?
by guerrilla 5y ago
I'm not sure what's supposed to be confusing here but one thing I don't know is why it was called the heap. Did they use heap data structures or something?
- bodhiandphysics 5y agoAs far as I can tell, the term heap comes from Algol 68. Algol 68 had garbage collection, and used mark and sweep. Mark and sweep works by searching memory like a tree, starting at the stack, so Algol 68 called this memory heap memory (at this point, heap was often used to just mean any tree). Languages like pascal and c also began calling their dynamic memory region the heap.
- afr0ck 5y agoI am a not a native speaker but Google Dictionary says this: Heap: "an untidy collection of objects placed haphazardly on top of each other". Example: "a heap of cardboard boxes" This makes sense as the Unix Heap is just a space containing a random collection of objects with random sizes.