[llvm] [Offload] Allow setting null arguments in olLaunchKernel (PR #141958)
via llvm-commits
llvm-commits at lists.llvm.org
Thu May 29 08:02:02 PDT 2025
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 HEAD~1 HEAD --extensions c,inc,cpp,h -- offload/unittests/OffloadAPI/device_code/noargs.c offload/liboffload/include/generated/OffloadAPI.h offload/liboffload/include/generated/OffloadEntryPoints.inc offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/offload/unittests/OffloadAPI/device_code/noargs.c b/offload/unittests/OffloadAPI/device_code/noargs.c
index a46c9469b..36e609aa2 100644
--- a/offload/unittests/OffloadAPI/device_code/noargs.c
+++ b/offload/unittests/OffloadAPI/device_code/noargs.c
@@ -1,5 +1,3 @@
#include <gpuintrin.h>
-__gpu_kernel void noargs() {
- (void)0;
-}
+__gpu_kernel void noargs() { (void)0; }
diff --git a/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp b/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp
index 3b6a25139..fe511a9de 100644
--- a/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp
+++ b/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp
@@ -78,8 +78,8 @@ TEST_P(olLaunchKernelTest, Success) {
}
TEST_P(olLaunchKernelNoArgsTest, Success) {
- ASSERT_SUCCESS(olLaunchKernel(Queue, Device, Kernel, nullptr, 0,
- &LaunchArgs, nullptr));
+ ASSERT_SUCCESS(
+ olLaunchKernel(Queue, Device, Kernel, nullptr, 0, &LaunchArgs, nullptr));
ASSERT_SUCCESS(olWaitQueue(Queue));
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/141958
More information about the llvm-commits
mailing list