This is an automated email from Gerrit.

"Dietmar May <dietmar....@outlook.com>" just uploaded a new patch set to 
Gerrit, which you can find at https://review.openocd.org/c/openocd/+/6473

-- gerrit

commit 3adfa89d97fb70a1b53f4240f012a52ce65e5a0f
Author: Dietmar May <dietmar....@outlook.com>
Date:   Thu Aug 19 11:00:18 2021 -0400

    aarch64: read registers starting with SP, not PC
    
    It's important when debugging assembly code to see updates to the stack
    pointer; so add SP to the core register range.
    
    Signed-off-by: Dietmar May <dietmar....@outlook.com>
    Change-Id: I57170647462fd6ac770913da0997552bc09ac9fb

diff --git a/src/target/armv8_dpm.c b/src/target/armv8_dpm.c
index 715079e97..44efb7e8b 100644
--- a/src/target/armv8_dpm.c
+++ b/src/target/armv8_dpm.c
@@ -778,7 +778,7 @@ int armv8_dpm_read_current_registers(struct arm_dpm *dpm)
        /* update core mode and state */
        armv8_set_cpsr(arm, cpsr);
 
-       for (unsigned int i = ARMV8_PC; i < cache->num_regs ; i++) {
+       for (unsigned int i = ARMV8_SP; i < cache->num_regs ; i++) {
                struct arm_reg *arm_reg;
 
                r = armv8_reg_current(arm, i);

-- 

Reply via email to