[llvm-dev] LTO, ifuncs, and lld

Shawn Webb via llvm-dev llvm-dev at lists.llvm.org
Wed Nov 28 17:14:59 PST 2018


Hey LLVM folks,

I've run into an interesting assertion. In one of HardenedBSD's
feature branches, we're working on integration llvm's Cross-DSO CFI
implementation. Using Cross-DSO CFI requires building libs with LTO,
which causes clang to emit LLVM IR intermediate object files rather
than ELF intermediate object files.

I've found that with lld, attempting to link LLVM IR intermediate
object files hits an assert in lld. I've created a reproduction test
case in this tiny little repo: https://github.com/lattera/ifunc_repro

The assertion I hit is detailed in the commit message of the initial
commit:
https://github.com/lattera/ifunc_repro/commit/0be98f9e81a1c91e80b135da6bb8d073d7a0c6f7

HardenedBSD's Cross-DSO CFI feature branch uses clang/llvm/lld 7.0.1.
I'm more than happy to test out patches to help address this issue.

Please let me know if you have any questions, comments, or concerns.

Thanks,

-- 
Shawn Webb
Cofounder and Security Engineer
HardenedBSD

Tor-ified Signal:    +1 443-546-8752
Tor+XMPP+OTR:        lattera at is.a.hacker.sx
GPG Key ID:          0x6A84658F52456EEE
GPG Key Fingerprint: 2ABA B6BD EF6A F486 BE89  3D9E 6A84 658F 5245 6EEE
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20181128/dcc1c721/attachment.sig>


More information about the llvm-dev mailing list