https://llvm.org/bugs/show_bug.cgi?id=31261
Bug ID: 31261 Summary: LLD fails to link an obj using versioned symbols Product: lld Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: ELF Assignee: unassignedb...@nondot.org Reporter: mail+l...@tzik.jp CC: llvm-bugs@lists.llvm.org Classification: Unclassified LLD fails to handle a .symver hack done in gRPC. https://chromium.googlesource.com/external/github.com/grpc/grpc/+/master/src/core/lib/support/wrap_memcpy.c Here is a repro case: ---- $ cat > failcase.s <<EOF .text memcpy@GLIBC_2.2.5 = memcpy .globl main .p2align 4, 0x90 .type main,@function main: callq» memcpy retq EOF $ clang -fuse-ld=lld failcase.s symbol memcpy@GLIBC_2.2.5 has undefined version GLIBC_2.2.5 ---- Or, in C. ---- $ cat > failcase.c <<EOF __asm__(".symver memcpy,memcpy@GLIBC_2.2.5"); void* memcpy(void* dest, const void* src, unsigned long size); void* foo(void* dest, const void* src, unsigned long size) { return memcpy(dest, src, size); } int main(int argc, const char** argv) { return 0; } EOF $ clang -fuse-ld=lld failcase.c symbol memcpy@GLIBC_2.2.5 has undefined version GLIBC_2.2.5 ---- -- You are receiving this mail because: You are on the CC list for the bug.
_______________________________________________ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs