[llvm] InstructionSelect: Use GISelChangeObserver instead of MachineFunction::Delegate (PR #105725)

via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 22 13:21:09 PDT 2024


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 2b66417d08d8e87f42cd154370ad1722ae7842c8 13cdc0c49797d3140e0aff6a4e8c1e4eff0d1059 --extensions h,cpp -- llvm/include/llvm/CodeGen/GlobalISel/GISelChangeObserver.h llvm/include/llvm/CodeGen/GlobalISel/InstructionSelector.h llvm/lib/CodeGen/GlobalISel/GISelChangeObserver.cpp llvm/lib/CodeGen/GlobalISel/InstructionSelect.cpp
``````````

</details>

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

``````````diff
diff --git a/llvm/include/llvm/CodeGen/GlobalISel/GISelChangeObserver.h b/llvm/include/llvm/CodeGen/GlobalISel/GISelChangeObserver.h
index 214777ca90..1167d51e88 100644
--- a/llvm/include/llvm/CodeGen/GlobalISel/GISelChangeObserver.h
+++ b/llvm/include/llvm/CodeGen/GlobalISel/GISelChangeObserver.h
@@ -152,6 +152,5 @@ private:
   GISelChangeObserver &TemporaryObserver;
 };
 
-
 } // namespace llvm
 #endif
diff --git a/llvm/lib/CodeGen/GlobalISel/InstructionSelect.cpp b/llvm/lib/CodeGen/GlobalISel/InstructionSelect.cpp
index f89a0e84bc..8639c39e15 100644
--- a/llvm/lib/CodeGen/GlobalISel/InstructionSelect.cpp
+++ b/llvm/lib/CodeGen/GlobalISel/InstructionSelect.cpp
@@ -75,8 +75,7 @@ InstructionSelect::InstructionSelect(CodeGenOptLevel OL, char &PassID)
 /// a non-obvious limitation for selector implementers. Therefore, to allow
 /// deletion of arbitrary instructions, we detect this case and continue
 /// selection with the predecessor of the deleted instruction.
-class InstructionSelect::MIIteratorMaintainer
-    : public GISelChangeObserver {
+class InstructionSelect::MIIteratorMaintainer : public GISelChangeObserver {
 #ifndef NDEBUG
   SmallSetVector<const MachineInstr *, 32> CreatedInstrs;
 #endif

``````````

</details>


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


More information about the llvm-commits mailing list