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,h --
llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.h
llvm/lib/Target/SPIRV/SPIRVISelLowering.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/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
b/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
index 099cfc3cd..d9ed9c763 100644
--- a/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
+++ b/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.cpp
@@ -2101,8 +2101,8 @@ SPIRVTypeInst
SPIRVGlobalRegistry::getOrCreateSPIRVPointerType(
SPIRV::StorageClass::StorageClass SC, bool EmitIR) {
const Type *LLVMType = getTypeForSPIRVType(BaseType);
assert(!storageClassRequiresExplictLayout(SC));
- SPIRVTypeInst R = getOrCreateSPIRVPointerType(LLVMType, MIRBuilder, SC,
false,
- EmitIR);
+ SPIRVTypeInst R =
+ getOrCreateSPIRVPointerType(LLVMType, MIRBuilder, SC, false, EmitIR);
assert(
(R->getOpcode() == SPIRV::OpTypeUntypedPointerKHR ||
getPointeeType(R) == BaseType) &&
diff --git a/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.h
b/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.h
index 123e2b029..2926044f8 100644
--- a/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.h
+++ b/llvm/lib/Target/SPIRV/SPIRVGlobalRegistry.h
@@ -648,10 +648,11 @@ public:
// storage class. The base type will be translated to a SPIR-V type, and the
// appropriate layout decorations will be added to the base type.
// See getOrCreateSPIRVPointerTypeInternal for ForceTyped.
- SPIRVTypeInst getOrCreateSPIRVPointerType(
- const Type *BaseType, MachineIRBuilder &MIRBuilder,
- SPIRV::StorageClass::StorageClass SC, bool ForceTyped = false,
- bool EmitIR = true);
+ SPIRVTypeInst
+ getOrCreateSPIRVPointerType(const Type *BaseType,
+ MachineIRBuilder &MIRBuilder,
+ SPIRV::StorageClass::StorageClass SC,
+ bool ForceTyped = false, bool EmitIR = true);
SPIRVTypeInst
getOrCreateSPIRVPointerType(const Type *BaseType, MachineInstr &I,
SPIRV::StorageClass::StorageClass SC,
@@ -672,11 +673,9 @@ public:
// storage class. It is the responsibility of the caller to make sure the
// decorations on the base type are valid for the given storage class. For
// example, it has the correct offset and stride decorations.
- SPIRVTypeInst
- getOrCreateSPIRVPointerType(SPIRVTypeInst BaseType,
- MachineIRBuilder &MIRBuilder,
- SPIRV::StorageClass::StorageClass SC,
- bool EmitIR = true);
+ SPIRVTypeInst getOrCreateSPIRVPointerType(
+ SPIRVTypeInst BaseType, MachineIRBuilder &MIRBuilder,
+ SPIRV::StorageClass::StorageClass SC, bool EmitIR = true);
// Returns a pointer to a SPIR-V pointer type that is the same as `PtrType`
// except the stroage class has been changed to `SC`. It is the
responsibility
``````````
</details>
https://github.com/llvm/llvm-project/pull/245051
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits