alpaka
Abstraction Library for Parallel Kernel Acceleration
Loading...
Searching...
No Matches
util.hpp File Reference
#include "alpaka/CVec.hpp"
#include "alpaka/api/trait.hpp"
#include "alpaka/core/common.hpp"
#include "alpaka/mem/DataPitches.hpp"
#include "alpaka/tag.hpp"
#include "alpaka/utility.hpp"
#include <cstdint>
#include <utility>

Go to the source code of this file.

Namespaces

namespace  alpaka
 main alpaka namespace.
namespace  alpaka::api
namespace  alpaka::api::util

Functions

template<std::integral auto T_limit, std::integral auto T_index, std::integral auto T_increment>
consteval auto alpaka::api::util::adjustToLimit (concepts::CVector auto const input)
 adjust the input vector to a given limit by halving all components until the product of these is is below or equal to the limit
auto alpaka::api::util::adjustToLimit (concepts::Vector auto input, std::integral auto const limit)
 adjust the input vector to a given limit by halving the largest dimension until the product of all components is below or equal to the limit
template<typename T_ValueType, alpaka::concepts::Vector T_Extents>
auto alpaka::api::util::emulatedAlignedMemDescription (uint32_t alignmentInByte, T_Extents extents)
 provides a memory description to create multidimensional linewise aligned memory within a one dimensional byte area
consteval uint32_t alpaka::api::util::highestPowerOfTwo (uint32_t value)
template<typename T_ValueType>
constexpr auto alpaka::api::util::simdOptimizedAlignment (auto api, alpaka::concepts::DeviceKind auto deviceKind)
 Calculate the best alignment for SIMD optimized memory allocation.