This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fwd: [patch] avoid the crash of gdb+pretty printer on initialized local variables


>>>>> "Martin" == Martin Runge <martin.runge@web.de> writes:

Martin> I have seen gdb running into very long loops on Linux, too (Ubuntu
Martin> 11.04, gdb 7.2 and 7.3). It looks like gdb is frozen, but it uses 100%
Martin> CPU. When attaching to that gdb process, I observed gdb fetching a lot
Martin> of values (address increasing, but the range was by far too large). I
Martin> guess this comes from a pretty printer, asking gdb to fetch too many
Martin> values.Âlibstdc++ and Qt4 pretty printers were in use in my case.

Martin> Although the error is probably somewhere in the pretty_printers, the
Martin> user experience is very confusing. E.g. with Eclipse CDT on top, gdb
Martin> does not respond to mi commands any more. As gdb does not give any
Martin> "progress" of "still alive" messages via mi to Eclipse, it runs into a
Martin> timeout and assumes gdb dead, debug session is broken and needs to be
Martin> restarted.

Is Eclipse using the range limitation feature of dynamic varobjs?
That is intended to help prevent this sort of thing.

Martin> I think, only few people write their pretty printers themselves. Most
Martin> get them "somewhere from the Internet", so its hard to guarantee
Martin> quality or rely on it.

Yeah.

Martin> Would it be a good idea in your eyes, if
[...]

I am not sure what would be the best solution, but could you file a bug
report for the problem?

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]