Computer Science › Section I · Data abstractions › Topic I.6
Pointers in machine language
Stacks, linked lists and trees all depend on following pointers, but a machine can only do that if its instructions allow it. Extending the Sparrow teaching machine with one new kind of load and store shows exactly what hardware support for pointers looks like.
In this topic
- A load Sparrow cannot do
- Three ways to name data
- An extension: op-code F
- Worked example: three loads compared
- Inside the machine cycle
- Push and pop in Sparrow
- Worked example: two pushes and a pop
- Worked example: summing a linked list
- Pointers in real processors
- Common mistakes to avoid
- Key takeaways
This topic is part of Wuanberri Pro. Checking your access…
