<html>
<head>
<base href="http://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - registers unavailable in the TestFrames.py inferior stack frames above frame 0"
href="http://llvm.org/bugs/show_bug.cgi?id=17385">17385</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>registers unavailable in the TestFrames.py inferior stack frames above frame 0
</td>
</tr>
<tr>
<th>Product</th>
<td>lldb
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>All Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>lldb-dev@cs.uiuc.edu
</td>
</tr>
<tr>
<th>Reporter</th>
<td>matt.kopec@intel.com
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Compile options:
clang -g -O0 -m32 -c -o main.o main.c
clang main.o -g -O0 -m32 -o "a.out"
Output:
mkopec1@mkopec1-linux:~/dev/llvm/tools/lldb/test/python_api/frame$ lldb a.out
Current executable set to 'a.out' (i386).
(lldb) b c
Breakpoint 1: where = a.out`c + 25 at main.c:40, address = 0x08048569
(lldb) r
Process 25392 launched:
'/home/mkopec1/dev/llvm/tools/lldb/test/python_api/frame/a.out' (i386)
a(val=1, ch='A')
b(val=2, ch='B')
Process 25392 stopped
* thread #1: tid = 25392, 0x08048569 a.out`c(val=3, ch='C') + 25 at main.c:40,
name = 'a.out', stop reason = breakpoint 1.1
frame #0: 0x08048569 a.out`c(val=3, ch='C') + 25 at main.c:40
37
38 int c(int val, char ch)
39 {
-> 40 int my_val = val;
41 char my_ch = ch;
42 printf("c(val=%d, ch='%c')\n", val, ch);
43 return val + 3 + ch;
(lldb) register read
General Purpose Registers:
rax = 0x0000000000000043
rbx = 0x00000000f77ad043
rcx = 0x0000000000000003
rdx = 0x0000000008048760
rdi = 0x0000000000000000
rsi = 0x0000000000000042
rbp = 0x00000000ffdc0578
rsp = 0x00000000ffdc0550
r8 = 0x0000000000000000
r9 = 0x0000000000000000
r10 = 0x0000000000000000
r11 = 0x0000000000000000
r12 = 0x0000000000000000
r13 = 0x0000000000000000
r14 = 0x0000000000000000
r15 = 0x0000000000000000
rip = 0x0000000008048569
rflags = 0x0000000000000286
cs = 0x0000000000000023
fs = 0x0000000000000000
gs = 0x0000000000000063
ss = 0x000000000000002b
ds = 0x000000000000002b
es = 0x000000000000002b
(lldb) up
frame #1: 0x08048544 a.out`b(val=2, ch='B') + 100 at main.c:35
32 int my_val = val;
33 char my_ch = ch;
34 printf("b(val=%d, ch='%c')\n", val, ch);
-> 35 return c(val+1, ch+1);
36 }
37
38 int c(int val, char ch)
(lldb) register read
General Purpose Registers:
24 registers were unavailable.
(lldb) up
frame #2: 0x0804847f a.out`a(val=1, ch='A') + 111 at main.c:23
20 char my_ch = ch;
21 printf("a(val=%d, ch='%c')\n", val, ch);
22 if (val <= 1)
-> 23 return b(val+1, ch+1);
24 else if (val >= 3)
25 return c(val+1, ch+1);
26
(lldb) register read
General Purpose Registers:
24 registers were unavailable.
All the registers are available in the first frame where the breakpoint on
function 'c' gets hit, as expected. However, going up in the call stack, there
are no registers available for these previous frames. At least some registers
should be available in the upper frames, such as the pc, stack pointer, etc.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>