On 06/27/2018 06:25 PM, Nick Clifton wrote:
OK - so if I change annobin so that it creates its own function start symbol,
eg libxsmm_crc32_u64_start and then it references this symbol in the .weak
directive, (instead of libxsmm_crc32_u64), then everything should be OK right ?
Since the new symbol will be exclusive to annobin, it will not be used in any
function calls, and so no R_X86_64_PC32 relocs should be generated against it.

Superficially, this will work.

But I'm a bit worried that the .weak still makes the symbol global, so that it ends up in the dynamic symbol table.

Consider this:

        .text
foo:
        .long 0

bar:
        .long 0

        .globl baz
baz:
        .long 0

        .section .other
        .weak bar
        .quad bar

I see bar and baz in .dynsym as a result, and we definitely only want baz there because foo and bar should remain local.

Thanks,
Florian
_______________________________________________
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/NBEA6X7LIQE2DFEDWVI2O5IVUP23YXEE/

Reply via email to