[PATCH] D38239: [ELF] - Define linkerscript symbols early.
George Rimar via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 25 01:35:04 PST 2017
>> + // We want to declare linker script's symbols early, so that can version them.
>> + Script->declareSymbols();
>> +
>
>The defsyms can use symbol added by addReservedSymbols(), no? If so this
>is still too early. It should be just before scanVersionScript.
>
>Cheers,
>Rafael
There is no problems for defsyms to use reserved symbols.
My patch just declares them early, so we can version them, but final
values are anyways assigned much later (from assignAddresses()->assignSymbol()).
I checked that can do --defsym=foo2=etext, for example (both with and without this patch).
So no need to move this line I believe.
Though even now does not seem we handle this case correctly, I opened bug:
https://bugs.llvm.org//show_bug.cgi?id=35744
George.
More information about the llvm-commits
mailing list