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: FYI: minor simplification in add_psymbol_to_bcache


>>>>> "Daniel" == Daniel Jacobowitz <drow@false.org> writes:

Tom> First, it removes the gratuitous use of a 'static' local variable.

Daniel> It adds a memset... if you assume that this is a hot function, then it
Daniel> was probably avoided on purpose.  On the other hand, the way it's
Daniel> implemented is quite dodgy; there will be bogus padding if
Daniel> sizeof (long) != sizeof (CORE_ADDR) and you alternate adding symbols
Daniel> with VAL and COREADDR set.

TBH I was not thinking too soundly, I suppose, when I nuked this.  I
think your point is a good one.  If you'd prefer, I will leave this
static and just zero out that field.

Tom


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