In DWARF2 debugging format, stack unwinding is supported with the help of CFI(Call Frame Information) present in .debug_frame section. This is precisely a table that keeps a rule for every register to get its value in previous frame. However, all of these rules relies on the fact that the registers are saved on stack at some location. This is not true for getting value of stack pointer in previous frame register when there is no frame-pointer. In such cases, stack pointer may not be saved on stack but just managed by incrementing and decrementing its value. However, there is no way in dwarf2 (or dwarf format in general) to indicate that the register value is an expression over its current value. So, my question is, how can one get the value of stack pointer during stack unwinding with dwarf2 debugging format (when no frame-pointer is there).
-BV