diff options
author | Joachim Protze <protze@itc.rwth-aachen.de> | 2019-01-16 11:35:11 +0000 |
---|---|---|
committer | Joachim Protze <protze@itc.rwth-aachen.de> | 2019-01-16 11:35:11 +0000 |
commit | edf145dbbed1d7adbf5b5f08dfe1bb347af22a7d (patch) | |
tree | e8ea2a1493582b6a125b9c49d37c4c9884961167 | |
parent | a756722a7c8510468b4533f3db67464aa04393cb (diff) |
[OpenMP] Remove compiler warning about unused value
The compiler warns about an unused variable/statement:
runtime/src/kmp_affinity.cpp:4958:18: warning: statement has no effect [-Wunused-value]
KA_TRACE(1000, ; {
^
runtime/src/kmp_debug.h:84:24: note: in definition of macro 'KA_TRACE'
__kmp_debug_printf x; \
^
Instead of the unused reference to this function, this patch now calls the function
with an empty string. The call to this function should have no effect.
Patch provided by joachim.protze
Reviewers: jlpeyton, hbae, AndreyChurbanov
Reviewed By: AndreyChurbanov
Tags: #openmp, #ompt
Differential Revision: https://reviews.llvm.org/D56775
-rw-r--r-- | openmp/runtime/src/kmp_affinity.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/openmp/runtime/src/kmp_affinity.cpp b/openmp/runtime/src/kmp_affinity.cpp index f14cdf68c08..aebd6ccd66d 100644 --- a/openmp/runtime/src/kmp_affinity.cpp +++ b/openmp/runtime/src/kmp_affinity.cpp @@ -4885,7 +4885,7 @@ int __kmp_aux_set_affinity(void **mask) { } gtid = __kmp_entry_gtid(); - KA_TRACE(1000, ; { + KA_TRACE(1000, (""); { char buf[KMP_AFFIN_MASK_PRINT_LEN]; __kmp_affinity_print_mask(buf, KMP_AFFIN_MASK_PRINT_LEN, (kmp_affin_mask_t *)(*mask)); @@ -4955,7 +4955,7 @@ int __kmp_aux_get_affinity(void **mask) { th = __kmp_threads[gtid]; KMP_DEBUG_ASSERT(th->th.th_affin_mask != NULL); - KA_TRACE(1000, ; { + KA_TRACE(1000, (""); { char buf[KMP_AFFIN_MASK_PRINT_LEN]; __kmp_affinity_print_mask(buf, KMP_AFFIN_MASK_PRINT_LEN, th->th.th_affin_mask); @@ -4972,7 +4972,7 @@ int __kmp_aux_get_affinity(void **mask) { #if !KMP_OS_WINDOWS retval = __kmp_get_system_affinity((kmp_affin_mask_t *)(*mask), FALSE); - KA_TRACE(1000, ; { + KA_TRACE(1000, (""); { char buf[KMP_AFFIN_MASK_PRINT_LEN]; __kmp_affinity_print_mask(buf, KMP_AFFIN_MASK_PRINT_LEN, (kmp_affin_mask_t *)(*mask)); @@ -5006,7 +5006,7 @@ int __kmp_aux_set_affinity_mask_proc(int proc, void **mask) { return -1; } - KA_TRACE(1000, ; { + KA_TRACE(1000, (""); { int gtid = __kmp_entry_gtid(); char buf[KMP_AFFIN_MASK_PRINT_LEN]; __kmp_affinity_print_mask(buf, KMP_AFFIN_MASK_PRINT_LEN, @@ -5038,7 +5038,7 @@ int __kmp_aux_unset_affinity_mask_proc(int proc, void **mask) { return -1; } - KA_TRACE(1000, ; { + KA_TRACE(1000, (""); { int gtid = __kmp_entry_gtid(); char buf[KMP_AFFIN_MASK_PRINT_LEN]; __kmp_affinity_print_mask(buf, KMP_AFFIN_MASK_PRINT_LEN, @@ -5070,7 +5070,7 @@ int __kmp_aux_get_affinity_mask_proc(int proc, void **mask) { return -1; } - KA_TRACE(1000, ; { + KA_TRACE(1000, (""); { int gtid = __kmp_entry_gtid(); char buf[KMP_AFFIN_MASK_PRINT_LEN]; __kmp_affinity_print_mask(buf, KMP_AFFIN_MASK_PRINT_LEN, |