[PATCH] D14153: [ELF2] R_X86_64_64 plt relocation implemented.

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 28 10:49:02 PDT 2015


ruiu accepted this revision.
ruiu added a comment.
This revision is now accepted and ready to land.

LGTM with a nit.


================
Comment at: ELF/Target.cpp:265-274
@@ -264,10 +264,12 @@
 unsigned X86_64TargetInfo::getPLTRefReloc(unsigned Type) const {
   switch (Type) {
   case R_X86_64_32:
     return R_X86_64_32;
+  case R_X86_64_64:
+    return R_X86_64_64;
   case R_X86_64_PC32:
   case R_X86_64_PLT32:
     return R_X86_64_PC32;
   }
   llvm_unreachable("Unexpected relocation");
 }
----------------
This function is called only when relocNeedsPlt returns true, so

  if (Type == R_X86_64_PLT32)
    return R_X86_64_PC32;
  return Type;



http://reviews.llvm.org/D14153





More information about the llvm-commits mailing list