[llvm-bugs] [Bug 34513] New: Missing DW_OP_deref for non-trivial return by value

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Sep 6 16:28:57 PDT 2017


            Bug ID: 34513
           Summary: Missing DW_OP_deref for non-trivial return by value
           Product: libraries
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: DebugInfo
          Assignee: unassignedbugs at nondot.org
          Reporter: dblaikie at gmail.com
                CC: aprantl at apple.com, llvm-bugs at lists.llvm.org,
                    paul.robinson at am.sony.com, zturner at google.com

Try this in a debugger:

struct string {
  string() {}
  string(int i) : i(i) {}
  ~string() {}
  int i = 0;
string get_string() {
  string unused;
  string result = 3;
  return result;
int main() { get_string(); }

$ clang++ -g -fno-exceptions str.cpp

$ gdb ./a.out
  b 10
  p result
  p *(string*)result

Looks like there's a missing DW_OP_deref in here somehow.

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/20170906/dcb555a0/attachment.html>

More information about the llvm-bugs mailing list