[Openmp-commits] [openmp] [OpenMP][test]Flip bit-fields in 'struct flags' for big-endian in test cases (PR #79895)
via Openmp-commits
openmp-commits at lists.llvm.org
Mon Jan 29 12:47:41 PST 2024
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 0065d06760c0fba786b7b5ff061b3b3efa08bfbc 60e8aa588fb1c335b18300e9eaaae282a4e38dfd -- openmp/runtime/test/tasking/bug_nested_proxy_task.c openmp/runtime/test/tasking/bug_proxy_task_dep_waiting.c
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/openmp/runtime/test/tasking/bug_nested_proxy_task.c b/openmp/runtime/test/tasking/bug_nested_proxy_task.c
index 05259b217c..24fe1f3fe7 100644
--- a/openmp/runtime/test/tasking/bug_nested_proxy_task.c
+++ b/openmp/runtime/test/tasking/bug_nested_proxy_task.c
@@ -51,19 +51,19 @@ typedef struct kmp_depend_info {
kmp_uint8 flag; // flag as an unsigned char
struct { // flag as a set of 8 bits
#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
- unsigned all : 1;
- unsigned unused : 3;
- unsigned set : 1;
- unsigned mtx : 1;
- unsigned out : 1;
- unsigned in : 1;
+ unsigned all : 1;
+ unsigned unused : 3;
+ unsigned set : 1;
+ unsigned mtx : 1;
+ unsigned out : 1;
+ unsigned in : 1;
#else
- unsigned in : 1;
- unsigned out : 1;
- unsigned mtx : 1;
- unsigned set : 1;
- unsigned unused : 3;
- unsigned all : 1;
+ unsigned in : 1;
+ unsigned out : 1;
+ unsigned mtx : 1;
+ unsigned set : 1;
+ unsigned unused : 3;
+ unsigned all : 1;
#endif
} flags;
};
diff --git a/openmp/runtime/test/tasking/bug_proxy_task_dep_waiting.c b/openmp/runtime/test/tasking/bug_proxy_task_dep_waiting.c
index 8a98df32ce..688860c035 100644
--- a/openmp/runtime/test/tasking/bug_proxy_task_dep_waiting.c
+++ b/openmp/runtime/test/tasking/bug_proxy_task_dep_waiting.c
@@ -48,19 +48,19 @@ typedef struct kmp_depend_info {
kmp_uint8 flag; // flag as an unsigned char
struct { // flag as a set of 8 bits
#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
- unsigned all : 1;
- unsigned unused : 3;
- unsigned set : 1;
- unsigned mtx : 1;
- unsigned out : 1;
- unsigned in : 1;
+ unsigned all : 1;
+ unsigned unused : 3;
+ unsigned set : 1;
+ unsigned mtx : 1;
+ unsigned out : 1;
+ unsigned in : 1;
#else
- unsigned in : 1;
- unsigned out : 1;
- unsigned mtx : 1;
- unsigned set : 1;
- unsigned unused : 3;
- unsigned all : 1;
+ unsigned in : 1;
+ unsigned out : 1;
+ unsigned mtx : 1;
+ unsigned set : 1;
+ unsigned unused : 3;
+ unsigned all : 1;
#endif
} flags;
};
``````````
</details>
https://github.com/llvm/llvm-project/pull/79895
More information about the Openmp-commits
mailing list