[llvm] [AMDGPU][MC] Add GFX12 VIMAGE and VSAMPLE encodings (PR #74062)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 1 03:23:01 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 cd31cf5989aaf6a187aaf3af4f94207c55a70d0f 23e427edcc52508b4962553a90cdf59261394bbe -- llvm/lib/Target/AMDGPU/AMDGPUSubtarget.cpp llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp llvm/lib/Target/AMDGPU/Disassembler/AMDGPUDisassembler.cpp llvm/lib/Target/AMDGPU/Disassembler/AMDGPUDisassembler.h llvm/lib/Target/AMDGPU/GCNSubtarget.h llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.cpp llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUInstPrinter.h llvm/lib/Target/AMDGPU/SIDefines.h llvm/lib/Target/AMDGPU/SIInstrInfo.h llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp b/llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
index a4e582e1ff..649ca9d3e7 100644
--- a/llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
+++ b/llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp
@@ -1460,13 +1460,9 @@ public:
return AMDGPU::isGFX11Plus(getSTI());
}
- bool isGFX12() const {
- return AMDGPU::isGFX12(getSTI());
- }
+ bool isGFX12() const { return AMDGPU::isGFX12(getSTI()); }
- bool isGFX12Plus() const {
- return AMDGPU::isGFX12Plus(getSTI());
- }
+ bool isGFX12Plus() const { return AMDGPU::isGFX12Plus(getSTI()); }
bool isGFX10_AEncoding() const { return AMDGPU::isGFX10_AEncoding(getSTI()); }
@@ -3612,8 +3608,8 @@ bool AMDGPUAsmParser::validateIntClampSupported(const MCInst &Inst) {
return true;
}
-constexpr uint64_t MIMGFlags = SIInstrFlags::MIMG | SIInstrFlags::VIMAGE |
- SIInstrFlags::VSAMPLE;
+constexpr uint64_t MIMGFlags =
+ SIInstrFlags::MIMG | SIInstrFlags::VIMAGE | SIInstrFlags::VSAMPLE;
bool AMDGPUAsmParser::validateMIMGDataSize(const MCInst &Inst,
const SMLoc &IDLoc) {
@@ -4667,8 +4663,7 @@ bool AMDGPUAsmParser::validateTHAndScopeBits(const MCInst &Inst,
return true;
if ((TID.TSFlags & SIInstrFlags::SMRD) &&
- ((TH == AMDGPU::CPol::TH_NT_RT) ||
- (TH == AMDGPU::CPol::TH_RT_NT) ||
+ ((TH == AMDGPU::CPol::TH_NT_RT) || (TH == AMDGPU::CPol::TH_RT_NT) ||
(TH == AMDGPU::CPol::TH_NT_HT)))
return PrintError("invalid th value for SMEM instruction");
``````````
</details>
https://github.com/llvm/llvm-project/pull/74062
More information about the llvm-commits
mailing list