Re: symbol files in python

Tom Tromey <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <[email protected]>
>>>>> "Dmitry" == Dmitry Neverov via Gdb <[email protected]> writes:

Dmitry> I'm trying to filter out uninitialized variables in a frame by checking
Dmitry> their lines in python, something like this:

I suspect this will not yield good results when optimization is present.

I normally see this kind of thing as GIGO -- gdb does what the compiler
tells it.  If the compiler thinks a variable is uninitialized at some
PC, it's free to omit that from the location list.

Dmitry> Is it correct to expect that symbols in blocks inside a function will
Dmitry> have the same file as the function's frame?

Not always, I think because of inlining.  However I'm not really sure.
Compilers can emit pretty much anything they like.

Tom
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.