Instruction Pointer

Learn about instruction pointers in the pc register and how to program data work.

Working of pc registers

Consider these two execution steps. The pc is pointed at 0x00000000004000dc and see how it works below:

Press + to interact
0x00000000004000dc in _start ()
1: x/i $pc
=> 0x4000dc <_start+44>: ldr w3, [x1]
2: /x $x0 = 0x4100f0
3: /x $x1 = 0x4100f4
4: /x $x2 = 0x1
5: /x $x3 = 0x0
6: /x (int)a = 0x1
7: /x (int)b = 0x1
8: /x (long)pa = 0x4100f0
9: /x (long)pb = 0x4100f4

The kernel is running on ldr w3, [x1] ...

Access this course and 1400+ top-rated courses and projects.