[LLVMbugs] [Bug 11818] New: Debug info broken, gdb can't find value of variables (value optimized out)

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Fri Jan 20 16:25:53 PST 2012


http://llvm.org/bugs/show_bug.cgi?id=11818

             Bug #: 11818
           Summary: Debug info broken, gdb can't find value of variables
                    (value optimized out)
           Product: libraries
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Common Code Generator Code
        AssignedTo: unassignedbugs at nondot.org
        ReportedBy: jonathan+llvm at pinacea.com
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


Created attachment 7918
  --> http://llvm.org/bugs/attachment.cgi?id=7918
Source test program without right debug info

I've found a bug when compiling C code (without optimization), I can set
breakpoint but I can't get a correct or any value sometimes from the local
variables of the function or from the arguments.

Quick example : 

I break into a function declared like this :
   static bool function1(int count, char *text)

gdb$ info locals
status = 128
gdb$ info args
count = <optimized out>
text = <optimized out> 


I found this when using -faddress-sanitizer on another program (see the
discussion from the address-sanitizer mailing-list
http://groups.google.com/group/address-sanitizer/t/cea13a8b4a2fc0ab)


Attached is the source of a test program that doesn't show values when breaking
in debugger. For me it's mostly triggered when using -faddress-sanitizer when
compiling.

I was using latest r148535 on a Linux system.

(I didn't know exactly where to file this bug, Product/Component)

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list