Use a RelocationRef instead of a relocation_iterator.
No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@180723 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
index d843e9a..354795d 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyld.cpp
@@ -154,7 +154,7 @@
         isFirstRelocation = false;
       }
 
-      processRelocationRef(SectionID, i, *obj, LocalSections, LocalSymbols,
+      processRelocationRef(SectionID, *i, *obj, LocalSections, LocalSymbols,
 			   Stubs);
     }
   }
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
index d52bcad..ef4a405 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
@@ -600,17 +600,17 @@
 }
 
 void RuntimeDyldELF::processRelocationRef(unsigned SectionID,
-                                          relocation_iterator RelI,
+                                          RelocationRef RelI,
                                           ObjectImage &Obj,
                                           ObjSectionToIDMap &ObjSectionToID,
                                           const SymbolTableMap &Symbols,
                                           StubMap &Stubs) {
   uint64_t RelType;
-  Check(RelI->getType(RelType));
+  Check(RelI.getType(RelType));
   int64_t Addend;
-  Check(RelI->getAdditionalInfo(Addend));
+  Check(RelI.getAdditionalInfo(Addend));
   SymbolRef Symbol;
-  Check(RelI->getSymbol(Symbol));
+  Check(RelI.getSymbol(Symbol));
 
   // Obtain the symbol name which is referenced in the relocation
   StringRef TargetName;
@@ -667,7 +667,7 @@
     }
   }
   uint64_t Offset;
-  Check(RelI->getOffset(Offset));
+  Check(RelI.getOffset(Offset));
 
   DEBUG(dbgs() << "\t\tSectionID: " << SectionID
                << " Offset: " << Offset
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
index 835b66f..2c04198 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.h
@@ -71,7 +71,7 @@
   virtual void resolveRelocation(const RelocationEntry &RE, uint64_t Value);
 
   virtual void processRelocationRef(unsigned SectionID,
-                                    relocation_iterator RelI,
+                                    RelocationRef RelI,
                                     ObjectImage &Obj,
                                     ObjSectionToIDMap &ObjSectionToID,
                                     const SymbolTableMap &Symbols,
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
index d0022c1..a02b19c 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldImpl.h
@@ -282,7 +282,7 @@
   /// \brief Parses the object file relocation and stores it to Relocations
   ///        or SymbolRelocations (this depends on the object file type).
   virtual void processRelocationRef(unsigned SectionID,
-                                    relocation_iterator RelI,
+                                    RelocationRef RelI,
                                     ObjectImage &Obj,
                                     ObjSectionToIDMap &ObjSectionToID,
                                     const SymbolTableMap &Symbols,
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp
index 9a6048c..ddac59f 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp
@@ -214,14 +214,14 @@
 }
 
 void RuntimeDyldMachO::processRelocationRef(unsigned SectionID,
-                                            relocation_iterator RelI,
+                                            RelocationRef RelI,
                                             ObjectImage &Obj,
                                             ObjSectionToIDMap &ObjSectionToID,
                                             const SymbolTableMap &Symbols,
                                             StubMap &Stubs) {
   const ObjectFile *OF = Obj.getObjectFile();
   const MachOObjectFile *MachO = static_cast<const MachOObjectFile*>(OF);
-  macho::RelocationEntry RE = MachO->getRelocation(RelI->getRawDataRefImpl());
+  macho::RelocationEntry RE = MachO->getRelocation(RelI.getRawDataRefImpl());
 
   uint32_t RelType = MachO->getAnyRelocationType(RE);
   RelocationValueRef Value;
@@ -233,7 +233,7 @@
   if (isExtern) {
     // Obtain the symbol name which is referenced in the relocation
     SymbolRef Symbol;
-    RelI->getSymbol(Symbol);
+    RelI.getSymbol(Symbol);
     StringRef TargetName;
     Symbol.getName(TargetName);
     // First search for the symbol in the local symbol table
@@ -277,7 +277,7 @@
   }
 
   uint64_t Offset;
-  RelI->getOffset(Offset);
+  RelI.getOffset(Offset);
   if (Arch == Triple::arm && (RelType & 0xf) == macho::RIT_ARM_Branch24Bit) {
     // This is an ARM branch relocation, need to use a stub function.
 
diff --git a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h
index c82b2f9..0fbfe03 100644
--- a/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h
+++ b/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.h
@@ -49,7 +49,7 @@
                             int64_t Addend);
 
   virtual void processRelocationRef(unsigned SectionID,
-                                    relocation_iterator RelI,
+                                    RelocationRef RelI,
                                     ObjectImage &Obj,
                                     ObjSectionToIDMap &ObjSectionToID,
                                     const SymbolTableMap &Symbols,