[Openmp-commits] [openmp] 20baa9a - [openmp][runtime] Silence warnings
Alexandre Ganea via Openmp-commits
openmp-commits at lists.llvm.org
Sun Aug 11 16:01:32 PDT 2024
Author: Alexandre Ganea
Date: 2024-08-11T19:01:12-04:00
New Revision: 20baa9a9eccda9bd61951f3f97b1d197f8b66dfc
URL: https://github.com/llvm/llvm-project/commit/20baa9a9eccda9bd61951f3f97b1d197f8b66dfc
DIFF: https://github.com/llvm/llvm-project/commit/20baa9a9eccda9bd61951f3f97b1d197f8b66dfc.diff
LOG: [openmp][runtime] Silence warnings
This fixes several of those when building with MSVC on Windows:
```
[3625/7617] Building CXX object
projects\openmp\runtime\src\CMakeFiles\omp.dir\kmp_affinity.cpp.obj
C:\src\git\llvm-project\openmp\runtime\src\kmp_affinity.cpp(2637):
warning C4062: enumerator 'KMP_HW_UNKNOWN' in switch of enum 'kmp_hw_t'
is not handled
C:\src\git\llvm-project\openmp\runtime\src\kmp.h(628): note: see
declaration of 'kmp_hw_t'
```
Added:
Modified:
openmp/runtime/src/kmp_affinity.cpp
Removed:
################################################################################
diff --git a/openmp/runtime/src/kmp_affinity.cpp b/openmp/runtime/src/kmp_affinity.cpp
index ab13ac4f43596d..dd48b1ea5c13f9 100644
--- a/openmp/runtime/src/kmp_affinity.cpp
+++ b/openmp/runtime/src/kmp_affinity.cpp
@@ -2634,8 +2634,9 @@ static int __kmp_topology_type_2_intel_type(kmp_hw_t type) {
return INTEL_LEVEL_TYPE_MODULE;
case KMP_HW_DIE:
return INTEL_LEVEL_TYPE_DIE;
+ default:
+ return INTEL_LEVEL_TYPE_INVALID;
}
- return INTEL_LEVEL_TYPE_INVALID;
}
struct cpuid_level_info_t {
More information about the Openmp-commits
mailing list