This is the mail archive of the gdb-prs@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]

[Bug breakpoints/14340] New: rbreak inefficiency


http://sourceware.org/bugzilla/show_bug.cgi?id=14340

             Bug #: 14340
           Summary: rbreak inefficiency
           Product: gdb
           Version: HEAD
            Status: NEW
          Severity: normal
          Priority: P2
         Component: breakpoints
        AssignedTo: unassigned@sourceware.org
        ReportedBy: dje@google.com
    Classification: Unclassified


rbreak_command first calls search_symbols to collect the list of symbols that
match the regexp (or file:regexp).  It then loops over each found symbol
calling, essentially, "break file:function" which in turn causes gdb to loop
over all symtabs again, but this time for each symtab:symbol from the result of
search_symbols.

Perhaps there's a reason why the code is the way it is, but it's odd that the
result of search_symbols isn't sufficient.
There's a massive speedup to be had by having a breakpoint API routine that
takes a struct symbol as an argument.

Presumably I'm missing something, but I'm not sure what it is.

[sidebar: it's odd that struct symbol_search records symtab even though one can
get the symbol's symtab from struct symbol]

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


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