[PATCH] D24728: [ARM][LLD] Add support for .ARM.exidx sections

Peter Smith via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 22 07:18:09 PDT 2016


peter.smith added a comment.

Would it be simpler/helpful if I split out the support for .ARM.exidx sections in executables/shared-libraries and remove support for relocatable links?

Given that the primary use case for relocatable links is C only kernel modules, I think it would be ok for now to not support ordering of .ARM.exidx sections in relocatable links. My preference would be to discard the .ARM.exidx sections as clang will output a .ARM.exidx can't unwind section even for C code even if -fno-exceptions is used.

This should simplify the patch, and we would at least know what we'd need to do if it became necessary to support it later.


================
Comment at: ELF/Writer.cpp:1006
@@ -1003,1 +1005,3 @@
+    if (Config->EMachine == EM_ARM && Sec->getType() == SHT_ARM_EXIDX)
+      ARMExidx.add(Sec);
   }
----------------
grimar wrote:
> First check looks excessive for me, I guess only EM_ARM can have SHT_ARM_EXIDX anyways.
Unfortunately the section type for SHT_ARM_EXIDX 0x70000001 is in the processor specific extensions field of ELF so it isn't unique. The same value is used by SHT_X86_64_UNWIND.


https://reviews.llvm.org/D24728





More information about the llvm-commits mailing list