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]

[PATCH 0/3 v2] Limit tab-completion result when list is large


Hi all,

When debugging large programs, pressing the Tab key at the wrong
time causes GDB to lock up while it builds a completion list.  As
an example, with LibreOffice:

 $ gdb /usr/lib64/libreoffice/program/soffice.bin
 (gdb) start
 (gdb) b <Tab>

On my (pretty fast!) machine the user is left hanging for nearly a
minute while GDB builds a list of the 212405 places the user could
break on.  This is PR cli/11920.

PR cli/15548 proposes to abort building the completion list if it
grows too large, the theory being that nobody is going to scroll
through thousands of screens of completions to find the one they
want.  These three patches implement this.  The default limit is 200
completions, which the user can override with a new set/show option.

Tested on RHEL6.5 x86_64, no regressions.

Is this ok to commit?

Thanks,
Gary

--
http://gbenson.net/


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