summaryrefslogtreecommitdiff
path: root/scripts/stack_core.py
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2014-07-14 17:15:41 -0700
committerElliott Hughes <enh@google.com>2014-07-14 19:01:02 -0700
commita8e31235e92258f9434682922ddca2b135c93bc4 (patch)
treec0ad5f5c03eb48fab79635c2acd8d973d2ea5607 /scripts/stack_core.py
parentca1c55b353482602c56bfe74caa56cd126d709e1 (diff)
Add the arm64 pstate register to the stack tool.
Also take into account the fact that the arm pcsr register is the fifth entry on its line, so the stack tool previously stripped that off. (cherry picked from commit be4de46d09356be6f25bb2886b436eb6221358e1) Change-Id: I0a937ae1a36071c3aaa5d955f56ee034dfdfe7de
Diffstat (limited to 'scripts/stack_core.py')
-rwxr-xr-xscripts/stack_core.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/stack_core.py b/scripts/stack_core.py
index 62d2aa51c..6b1e11eea 100755
--- a/scripts/stack_core.py
+++ b/scripts/stack_core.py
@@ -49,7 +49,7 @@ class TraceConverter:
register_names = {
"arm": "r0|r1|r2|r3|r4|r5|r6|r7|r8|r9|sl|fp|ip|sp|lr|pc|cpsr",
- "arm64": "x0|x1|x2|x3|x4|x5|x6|x7|x8|x9|x10|x11|x12|x13|x14|x15|x16|x17|x18|x19|x20|x21|x22|x23|x24|x25|x26|x27|x28|x29|x30|sp|pc",
+ "arm64": "x0|x1|x2|x3|x4|x5|x6|x7|x8|x9|x10|x11|x12|x13|x14|x15|x16|x17|x18|x19|x20|x21|x22|x23|x24|x25|x26|x27|x28|x29|x30|sp|pc|pstate",
"mips": "zr|at|v0|v1|a0|a1|a2|a3|t0|t1|t2|t3|t4|t5|t6|t7|s0|s1|s2|s3|s4|s5|s6|s7|t8|t9|k0|k1|gp|sp|s8|ra|hi|lo|bva|epc",
"x86": "eax|ebx|ecx|edx|esi|edi|x?cs|x?ds|x?es|x?fs|x?ss|eip|ebp|esp|flags",
"x86_64": "rax|rbx|rcx|rdx|rsi|rdi|r8|r9|r10|r11|r12|r13|r14|r15|cs|ss|rip|rbp|rsp|eflags",
@@ -59,7 +59,7 @@ class TraceConverter:
if symbol.ARCH == "arm64" or symbol.ARCH == "mips64" or symbol.ARCH == "x86_64":
self.width = "{16}"
- self.register_line = re.compile("(([ ]*\\b(" + self.register_names[symbol.ARCH] + ")\\b +[0-9a-f]" + self.width + "){2,4})")
+ self.register_line = re.compile("(([ ]*\\b(" + self.register_names[symbol.ARCH] + ")\\b +[0-9a-f]" + self.width + "){2,5})")
# Note that both trace and value line matching allow for variable amounts of
# whitespace (e.g. \t). This is because the we want to allow for the stack