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

            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: unassignedb...@nondot.org
          Reporter: dblai...@gmail.com
                CC: apra...@apple.com, llvm-bugs@lists.llvm.org,
                    paul.robin...@am.sony.com, ztur...@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
  r
  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.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to