[PATCH] D35944: [ELF] Disable relocation validation when targeting weak undefined symbols

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 31 17:11:04 PDT 2017


ruiu added a comment.

Hi Ben,

Is that a real scenario? I mean, if function `foo` is defined in the same compilation unit as `main`, it is resolved locally, and if function `foo` is not defined in the same compilation unit as `main`, then the compiler emits a call instruction that can jump to any address (because the compiler doesn't know where `foo` will be after linking), no?


https://reviews.llvm.org/D35944





More information about the llvm-commits mailing list