]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
elfcopy: Use libelftc's string table routines to build .shstrtab.
authormarkj <markj@FreeBSD.org>
Tue, 4 Jun 2019 18:34:05 +0000 (18:34 +0000)
committermarkj <markj@FreeBSD.org>
Tue, 4 Jun 2019 18:34:05 +0000 (18:34 +0000)
commitbec7330290f181712b2840f220eee1b5533ea3b6
treedd76c37a48ec1285a87b08b765380037402fcf7c
parent57cb8d51d00f548c0f1aa5242047ae8bb3d4c13b
elfcopy: Use libelftc's string table routines to build .shstrtab.

This replaces some hand-rolled routines and is substantially faster
since libelftc uses a hash table for lookups and insertions, whereas
elfcopy would perform a linear scan of the table.

PR: 234949
Reviewed by: emaste
MFC after: 2 weeks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D20473
contrib/elftoolchain/elfcopy/ascii.c
contrib/elftoolchain/elfcopy/binary.c
contrib/elftoolchain/elfcopy/elfcopy.h
contrib/elftoolchain/elfcopy/main.c
contrib/elftoolchain/elfcopy/sections.c