[lldb-dev] [Bug 40943] New: lldb crashes (on linux) when debugging optimized code (-O2)

via lldb-dev lldb-dev at lists.llvm.org
Sun Mar 3 20:25:34 PST 2019


https://bugs.llvm.org/show_bug.cgi?id=40943

            Bug ID: 40943
           Summary: lldb crashes (on linux) when debugging optimized code
                    (-O2)
           Product: lldb
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: All Bugs
          Assignee: lldb-dev at lists.llvm.org
          Reporter: davide at freebsd.org
                CC: aprantl at apple.com, labath at google.com,
                    llvm-bugs at lists.llvm.org, zturner at google.com

$ cat  outer.c
void optimize_me_not() {}

$ cat abc.c
a;
main() {
  optimize_me_not();
  {
    int b[1];
    b[0] = 1;
    a = 0;
  }
}

$ clang-trunk abc.c /home/davide/reduce-crash/outer.c -g -O2 -o a.out
$

$ cat cmds
b 3
r
kill
quit

$ lldb-trunk a.out -s cmds -b
(lldb) target create "a.out"
Current executable set to 'a.out' (x86_64).
(lldb) command source -s 0 'cmds'
Executing commands in '/home/davide/reduce-crash/cmds'.
Segmentation fault (core dumped)

$ clang-trunk --version
clang version 9.0.0 (trunk 355281)
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /usr/local/bin

$ lldb-trunk --version
lldb version 9.0.0 (https://llvm.org/svn/llvm-project/lldb/trunk revision
355281)
  clang revision 355281
  llvm revision 355281

$ uname -a
Linux 4.15.0-45-generic #48-Ubuntu SMP Tue Jan 29 16:28:13 UTC 2019 x86_64
x86_64 x86_64 GNU/Linux

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20190304/eecbaae9/attachment.html>


More information about the lldb-dev mailing list