[llvm] [BOLT][AArch64] Fix strict usage during ADR Relax (PR #71377)

via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 6 03:12:23 PST 2023


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff 2cce0f6c57414fd881c61b7fe5f36e6e90266fc0 ebc7188877360245c1bd638d8074eefc3b06777e -- bolt/lib/Passes/ADRRelaxationPass.cpp
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/bolt/lib/Passes/ADRRelaxationPass.cpp b/bolt/lib/Passes/ADRRelaxationPass.cpp
index c5cfb4901a9b..4039fa2fbb51 100644
--- a/bolt/lib/Passes/ADRRelaxationPass.cpp
+++ b/bolt/lib/Passes/ADRRelaxationPass.cpp
@@ -73,7 +73,7 @@ void ADRRelaxationPass::runOnFunction(BinaryFunction &BF) {
       if (It != BB.begin() && BC.MIB->isNoop(*std::prev(It))) {
         It = BB.eraseInstruction(std::prev(It));
       } else if (std::next(It) != BB.end() && BC.MIB->isNoop(*std::next(It))) {
-          BB.eraseInstruction(std::next(It));
+        BB.eraseInstruction(std::next(It));
       } else if (!opts::StrictMode && !BF.isSimple()) {
         // If the function is not simple, it may contain a jump table undetected
         // by us. This jump table may use an offset from the branch instruction

``````````

</details>


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


More information about the llvm-commits mailing list