For function multi-versioning using the target or target_clones function attributes, currently we incorrectly set comdat for internal linkage resolvers. This is problematic for ELF linkers as GRP_COMDAT deduplication will kick in even with STB_LOCAL signature (https://groups.google.com/g/generic-abi/c/2X6mR-s2zoc "GRP_COMDAT group with STB_LOCAL signature"). In short, two `__attribute((target_clones(...))) static void foo()` in two translation units will be deduplicated. Fix this. Fix #65114 Reviewed By: erichkeane Differential Revision: https://reviews.llvm.org/D158963
284 KiB
284 KiB