[OpenMP] Fix incorrect use of align instead of round (#196191)
diff --git a/openmp/device/src/Mapping.cpp b/openmp/device/src/Mapping.cpp
index 5c51da6..1096e5f 100644
--- a/openmp/device/src/Mapping.cpp
+++ b/openmp/device/src/Mapping.cpp
@@ -131,7 +131,7 @@
}
uint32_t mapping::getNumberOfWarpsInBlock() {
- return utils::alignUp(mapping::getNumberOfThreadsInBlock(),
+ return utils::roundUp(mapping::getNumberOfThreadsInBlock(),
mapping::getWarpSize());
}
diff --git a/openmp/device/src/Reduction.cpp b/openmp/device/src/Reduction.cpp
index 271d316..b1b1e0d 100644
--- a/openmp/device/src/Reduction.cpp
+++ b/openmp/device/src/Reduction.cpp
@@ -135,7 +135,7 @@
//
// Only L1 parallel region can enter this if condition.
if (NumThreads > mapping::getWarpSize()) {
- uint32_t WarpsNeeded = utils::alignUp(NumThreads, mapping::getWarpSize());
+ uint32_t WarpsNeeded = utils::roundUp(NumThreads, mapping::getWarpSize());
// Gather all the reduced values from each warp
// to the first warp.
cpyFct(reduce_data, WarpsNeeded);
@@ -280,7 +280,7 @@
uint32_t ActiveThreads = kmpcMin(NumRecs, NumThreads);
if (ActiveThreads > mapping::getWarpSize()) {
uint32_t WarpsNeeded =
- utils::alignUp(ActiveThreads, mapping::getWarpSize());
+ utils::roundUp(ActiveThreads, mapping::getWarpSize());
// Gather all the reduced values from each warp
// to the first warp.
cpyFct(reduce_data, WarpsNeeded);