[PATCH] D41049: Compact symbols from 96 to 88 bytes
Rafael Avila de Espindola via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 11 14:59:46 PST 2017
Rui Ueyama via Phabricator <reviews at reviews.llvm.org> writes:
> ruiu added inline comments.
>
>
> ================
> Comment at: ELF/InputFiles.h:310
> + const typename ELFT::Verdef *getVerdef(uint32_t Index) {
> + assert(Index <= Verdefs.size());
> + return Verdefs[Index];
> ----------------
> If you can trigger this by passing a malformed object file, this should be a fatal() instead of assert().
I don't think I can. The assert is really for testing internal
consistency. The code creating shared symbols has:
------------------------------
if (VersymIndex >= Verdefs.size()) {
error("corrupt input file: version definition index " +
Twine(VersymIndex) + " for symbol " + Name +
" is out of bounds\n>>> defined in " + toString(this));
------------------------------
I will upload a new version.
Cheers,
Rafael
More information about the llvm-commits
mailing list