[PATCH] D15767: [lld/ELF] Don't reclaim .ctors/.dtors

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 24 01:16:13 PST 2015

ruiu added a comment.

The code looks OK, but I'm not sure if this is the right thing to do. `.ctors` and `.dtors` are used to construct and destruct statically-allocated objects. This patch is to keep them regardless of their usage, which in turn the data referenced by `.ctors` or `.dtors` always live even if they are not used.

I'm wondering why we need this for FreeBSD. What's the difference from Linux?


More information about the llvm-commits mailing list