[PATCH] D36812: Add support for writing 64-bit symbol tables for archives when offsets become too large for 32-bit

Rafael Avila de Espindola via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 23 14:40:04 PDT 2017


Jake Ehrlich via Phabricator <reviews at reviews.llvm.org> writes:

> Index: test/Object/archive-SYM64-write.test
> ===================================================================
> --- /dev/null
> +++ test/Object/archive-SYM64-write.test
> @@ -0,0 +1,27 @@
> +# RUN: yaml2obj %s > %t
> +# RUN: rm -f %t.lib
> +# RUN: llvm-ar cr %t.lib %t
> +# RUN: mv %t %t2
> +# RUN: llvm-ar cr %t.lib %t2 %p/Inputs/trivial-object-test.elf-x86-64
> +# RUN: llvm-nm %t.lib | FileCheck %s

Why do you need to create the new library in two steps?

As written the test would pass without the patch, no? The produced
symbol table would be broken, but we don't test that it is not.

Not sure what is the best way to test that in llvm itself. All I can
think of is checking for /SYM64 or writing a unit test.

Cheers,
Rafael


More information about the llvm-commits mailing list