diff options
author | liuzhensong <liuzhensong@loongson.cn> | 2022-02-21 14:34:07 +0800 |
---|---|---|
committer | liuzhensong <liuzhensong@loongson.cn> | 2022-03-20 09:37:12 +0800 |
commit | d218dba3f491191322e50df74376faa11c4a9f6b (patch) | |
tree | c90bc402432c83cdddce46fe214394f19852d8ad /bfd/elfxx-loongarch.h | |
parent | 3b14682a432e61c756ec9ad0b5bf5f8136e2cdce (diff) |
LoongArch: Fix LD check fails.
Some test cases about ifunc.
bfd/
* elfnn-loongarch.c
* elfxx-loongarch.h
=== ld Summary ===
of expected passes 1430
of expected failures 11
of untested testcases 1
of unsupported tests 154
Diffstat (limited to 'bfd/elfxx-loongarch.h')
-rw-r--r-- | bfd/elfxx-loongarch.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/bfd/elfxx-loongarch.h b/bfd/elfxx-loongarch.h index 3b5c6361e0..8ea63d03fa 100644 --- a/bfd/elfxx-loongarch.h +++ b/bfd/elfxx-loongarch.h @@ -31,3 +31,11 @@ extern reloc_howto_type * loongarch_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED, const char *r_name); bool loongarch_adjust_reloc_bitsfield (reloc_howto_type *howto, bfd_vma *fix_val); + +/* TRUE if this is a PLT reference to a local IFUNC. */ +#define PLT_LOCAL_IFUNC_P(INFO, H) \ + ((H)->dynindx == -1 \ + || ((bfd_link_executable (INFO) \ + || ELF_ST_VISIBILITY ((H)->other) != STV_DEFAULT) \ + && (H)->def_regular \ + && (H)->type == STT_GNU_IFUNC)) |