[llvm] [BOLT][AArch64] Implement PLTCall optimization (PR #93584)

Rafael Auler via llvm-commits llvm-commits at lists.llvm.org
Wed May 29 11:16:03 PDT 2024


================
@@ -1412,9 +1413,15 @@ class MCPlusBuilder {
     return false;
   }
 
-  /// Modify a direct call instruction \p Inst with an indirect call taking
-  /// a destination from a memory location pointed by \p TargetLocation symbol.
-  virtual bool convertCallToIndirectCall(MCInst &Inst,
+  /// Modify a direct call instruction pointed by the iterator \p It, with an
+  /// indirect call taking a destination from a memory location pointed by \p
+  /// TargetLocation symbol. If additional instructions need to be prepended
+  /// before \p It, then the iterator must be updated to point to the indirect
+  /// call instruction.
+  ///
+  /// \return true on success
+  virtual bool convertCallToIndirectCall(BinaryBasicBlock &BB,
----------------
rafaelauler wrote:

I checked and apparently my BUILD_SHARED_LIBS build succeeds, but I think we shouldn't rely on this. If you check the CMakeLists.txt file in the AArch64 folder, you will see it does not depend on BOLTCore lib, which defines BinaryBasicBlock.

https://github.com/llvm/llvm-project/pull/93584


More information about the llvm-commits mailing list