[llvm-bugs] [Bug 46114] New: wrong debug info at -O3
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed May 27 23:20:10 PDT 2020
https://bugs.llvm.org/show_bug.cgi?id=46114
Bug ID: 46114
Summary: wrong debug info at -O3
Product: clang
Version: unspecified
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: LLVM Codegen
Assignee: unassignedclangbugs at nondot.org
Reporter: qrzhang at gatech.edu
CC: llvm-bugs at lists.llvm.org, neeilans at live.com,
richard-llvm at metafoo.co.uk
Bisection points to e5f07080b8ac73dd573e81a186925a122ab8a39d.
l_52 = 1 is a wrong value.
$ clang-trunk -g -O3 abc.c
$ lldb-trunk -s cmds -b a.out
(lldb) b 6
Breakpoint 1: where = a.out`main + 6 at abc.c:6:20, address =
0x0000000000400486
(lldb) r
Process 2616 stopped
* thread #1, name = 'a.out', stop reason = breakpoint 1.1
frame #0: 0x0000000000400486 a.out`main at abc.c:6:20
3 char c;
4 int main() {
5 int d = a, l_52 = 0;
-> 6 b = (l_52 = a) - c; // stop here
7 if (d) {
8 int e=1;
9 }
(lldb) p l_52
(int) $0 = 1
$ cat abc.c
int a = 1;
short b;
char c;
int main() {
int d = a, l_52 = 0;
b = (l_52 = a) - c; // qirun0
if (d) {
int e=1;
}
}
$ cat cmds
b 6
r
p l_52
kill
q
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20200528/60172834/attachment.html>
More information about the llvm-bugs
mailing list