How to solve gdb <value optimized out> problem?

cazy ad319min@gmail.com
Thu May 27 16:20:00 GMT 2010


I am trying debug gcc 4.5.0 use gdb on ubuntu
 
and encounter the problem by seeing "value optimized out".  as fellow:
 
(gdb) run -I /usr/include /cazy/add.c 
Starting program: /home/cazy/gcc-object/gcc/cc1 -I /usr/include /cazy/add.c
Breakpoint 4, c_parser_declaration_or_fndef (parser=0xb7f32bb4, 
    fndef_ok=1 '\001', empty_ok=1 '\001', nested=0 '\000', 
    start_attr_ok=1 '\001') at ../../project/gcc-4.5.0/gcc/c-parser.c:1170
1170 {
(gdb) next
1175   location_t here = c_parser_peek_token (parser)->location;
(gdb) next
1170 {
(gdb) p here
$5 = <value optimized out>

 
This creates a lot of problem for me to debuging 
So, I am wondering if there is anyway to solve the problem?
 
thanks
cazy
-- 
View this message in context: http://old.nabble.com/How-to-solve-gdb-%3Cvalue-optimized-out%3E-problem--tp28693805p28693805.html
Sent from the gcc - Help mailing list archive at Nabble.com.



More information about the Gcc-help mailing list