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 cpp -- 
clang/test/CodeGenHIP/amdgcnspirv-uses-amdgpu-abi.cpp 
clang/lib/CodeGen/Targets/SPIR.cpp llvm/lib/Target/SPIRV/SPIRVCallLowering.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/clang/lib/CodeGen/Targets/SPIR.cpp 
b/clang/lib/CodeGen/Targets/SPIR.cpp
index 354009307..2134e158a 100644
--- a/clang/lib/CodeGen/Targets/SPIR.cpp
+++ b/clang/lib/CodeGen/Targets/SPIR.cpp
@@ -67,12 +67,14 @@ class AMDGCNSPIRVABIInfo : public SPIRVABIInfo {
   ABIArgInfo classifyReturnType(QualType RetTy) const;
   ABIArgInfo classifyKernelArgumentType(QualType Ty) const;
   ABIArgInfo classifyArgumentType(QualType Ty) const;
+
 public:
   AMDGCNSPIRVABIInfo(CodeGenTypes &CGT) : SPIRVABIInfo(CGT) {}
   void computeInfo(CGFunctionInfo &FI) const override;
 
-  llvm::FixedVectorType *getOptimalVectorMemoryType(
-      llvm::FixedVectorType *Ty, const LangOptions &LangOpt) const override;
+  llvm::FixedVectorType *
+  getOptimalVectorMemoryType(llvm::FixedVectorType *Ty,
+                             const LangOptions &LangOpt) const override;
 };
 } // end anonymous namespace
 namespace {
@@ -251,9 +253,9 @@ unsigned AMDGCNSPIRVABIInfo::numRegsForType(QualType Ty) 
const {
   return (getContext().getTypeSize(Ty) + 31) / 32;
 }
 
-llvm::Type *
-AMDGCNSPIRVABIInfo::coerceKernelArgumentType(llvm::Type *Ty, unsigned FromAS,
-                                             unsigned ToAS) const {
+llvm::Type *AMDGCNSPIRVABIInfo::coerceKernelArgumentType(llvm::Type *Ty,
+                                                         unsigned FromAS,
+                                                         unsigned ToAS) const {
   // Single value types.
   auto *PtrTy = llvm::dyn_cast<llvm::PointerType>(Ty);
   if (PtrTy && PtrTy->getAddressSpace() == FromAS)
diff --git a/llvm/lib/Target/SPIRV/SPIRVCallLowering.cpp 
b/llvm/lib/Target/SPIRV/SPIRVCallLowering.cpp
index c4adba3a1..bcaa3c4c6 100644
--- a/llvm/lib/Target/SPIRV/SPIRVCallLowering.cpp
+++ b/llvm/lib/Target/SPIRV/SPIRVCallLowering.cpp
@@ -377,7 +377,7 @@ bool 
SPIRVCallLowering::lowerFormalArguments(MachineIRBuilder &MIRBuilder,
       if (Arg.hasAttribute(Attribute::ByVal) ||
           (Arg.hasAttribute(Attribute::ByRef) &&
            F.getParent()->getTargetTriple().getVendor() ==
-              Triple::VendorType::AMD)) {
+               Triple::VendorType::AMD)) {
         auto Attr =
             static_cast<unsigned>(SPIRV::FunctionParameterAttribute::ByVal);
         buildOpDecorate(VRegs[i][0], MIRBuilder,

``````````

</details>


https://github.com/llvm/llvm-project/pull/169865
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to