[llvm] [CodeGen] Move rollback capabilities outside of the rematerializer (PR #184341)

via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 2 07:13:20 PDT 2026


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 origin/main HEAD --extensions h,cpp -- llvm/include/llvm/CodeGen/Rematerializer.h llvm/lib/CodeGen/Rematerializer.cpp llvm/unittests/CodeGen/RematerializerTest.cpp --diff_from_common_commit
``````````

:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:

</details>

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

``````````diff
diff --git a/llvm/unittests/CodeGen/RematerializerTest.cpp b/llvm/unittests/CodeGen/RematerializerTest.cpp
index 40e53febb..6b1373377 100644
--- a/llvm/unittests/CodeGen/RematerializerTest.cpp
+++ b/llvm/unittests/CodeGen/RematerializerTest.cpp
@@ -678,8 +678,9 @@ body:             |
   EXPECT_TRUE(getMF().verify());
 }
 
-/// Checks that rollback re-creates MIs at correct positions when the order of register deletions
-/// forces the re-creation logic to iterate through multiple deleted registers' respective insert position to find a valid one.
+/// Checks that rollback re-creates MIs at correct positions when the order of
+/// register deletions forces the re-creation logic to iterate through multiple
+/// deleted registers' respective insert position to find a valid one.
 TEST_F(RematerializerTest, RollbackInvalidInsertPos) {
   StringRef MIR = R"(
 name:            RollbackInvalidInsertPos

``````````

</details>


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


More information about the llvm-commits mailing list