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: RFC: remove gnu_debuglink_crc32


On 01/21/2013 06:57 PM, Tom Tromey wrote:
> I noticed that BFD has a function equivalent to gnu_debuglink_crc32.
> There doesn't seem to be any reason to keep our own function, so this
> patch removes it.

Right.  GDB gained the function first, and the bfd one was
added afterwards:

http://sourceware.org/ml/binutils/2003-01/msg00511.html

"It has become clear recently that GDB is not the only program which
would benefit from these separate packages; notably objdump and the
oprofile post-processing tools require access to them. Rather than
duplicate the same section-extracting, path-searching and
checksum-matching code in these tools, it was suggested that we
centralize the feature in binutils itself. "

So your patch has been the intention all along.

> 
> Built and regtested on x86-64 Fedora 16.
> 
> There's some other overlap in this area, but I think we can't readily
> share it due to gdb's support of remote files.
> 
> Tom
> 
>     	* symfile.c (get_file_crc): Use bfd_calc_gnu_debuglink_crc32.
>     	* utils.c (gnu_debuglink_crc32): Remove.
>     	* utils.h (gnu_debuglink_crc32): Don't declare.

Looks good to me...

-- 
Pedro Alves


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