[llvm] [AMDGPU] GCNRegPressure printing pass for testing. (PR #70031)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 25 14:28:52 PDT 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 24f068b0f77e5de1980b71f036f6b83c4d506904 814ccb9546ef681b8f231bb0569eb050b5b72995 -- llvm/lib/Target/AMDGPU/AMDGPU.h llvm/lib/Target/AMDGPU/AMDGPUTargetMachine.cpp llvm/lib/Target/AMDGPU/GCNRegPressure.cpp llvm/lib/Target/AMDGPU/GCNRegPressure.h
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/AMDGPU/GCNRegPressure.cpp b/llvm/lib/Target/AMDGPU/GCNRegPressure.cpp
index d2f8f4cf5dcc..4d5677d9463d 100644
--- a/llvm/lib/Target/AMDGPU/GCNRegPressure.cpp
+++ b/llvm/lib/Target/AMDGPU/GCNRegPressure.cpp
@@ -505,7 +505,7 @@ bool GCNRegPressurePrinter::runOnMachineFunction(MachineFunction &MF) {
const MachineRegisterInfo &MRI = MF.getRegInfo();
const LiveIntervals &LIS = getAnalysis<LiveIntervals>();
-
+
auto &OS = dbgs();
// Leading spaces are important for YAML syntax.
@@ -542,7 +542,7 @@ bool GCNRegPressurePrinter::runOnMachineFunction(MachineFunction &MF) {
GCNRPTracker::LiveRegSet LRAtMBBBegin, LRAtMBBEnd;
GCNRegPressure RPAtMBBEnd;
-
+
if (UseDownwardTracker) {
GCNDownwardRPTracker RPT(LIS);
RPT.reset(MBB.instr_front());
@@ -565,7 +565,7 @@ bool GCNRegPressurePrinter::runOnMachineFunction(MachineFunction &MF) {
LRAtMBBEnd = RPT.getLiveRegs();
RPAtMBBEnd = RPT.getPressure();
-
+
for (auto &MI : reverse(MBB)) {
RPT.recede(MI);
if (!MI.isDebugInstr())
``````````
</details>
https://github.com/llvm/llvm-project/pull/70031
More information about the llvm-commits
mailing list