alpaka
Abstraction Library for Parallel Kernel Acceleration
alpaka::cpu::detail Namespace Reference

The CPU device. More...

Classes

struct  QueueCpuOmp2CollectiveImpl
 The CPU collective device queue implementation. More...
 

Typedefs

using DevCpuImpl = alpaka::detail::QueueRegistry< cpu::ICpuQueue >
 The CPU device implementation. More...
 

Functions

auto cpuid (std::uint32_t, std::uint32_t, std::uint32_t ex[4]) -> void
 
auto getCpuName () -> std::string
 
auto getFreeGlobalMemSizeBytes () -> std::size_t
 
size_t getPageSize ()
 
auto getTotalGlobalMemSizeBytes () -> std::size_t
 

Variables

constexpr int NO_CPUID = 0
 
constexpr int UNKNOWN_COMPILER = 1
 
constexpr int UNKNOWN_CPU = 0
 

Detailed Description

The CPU device.

Typedef Documentation

◆ DevCpuImpl

The CPU device implementation.

Definition at line 49 of file DevCpu.hpp.

Function Documentation

◆ cpuid()

auto alpaka::cpu::detail::cpuid ( std::uint32_t  ,
std::uint32_t  ,
std::uint32_t  ex[4] 
) -> void
inline

Definition at line 70 of file SysInfo.hpp.

◆ getCpuName()

auto alpaka::cpu::detail::getCpuName ( ) -> std::string
inline
Returns
The name of the CPU the code is running on.

Definition at line 77 of file SysInfo.hpp.

◆ getFreeGlobalMemSizeBytes()

auto alpaka::cpu::detail::getFreeGlobalMemSizeBytes ( ) -> std::size_t
inline
Returns
The free number of bytes of global memory.
Exceptions
std::logic_errorif not implemented on the system and std::runtime_error on other errors.

Definition at line 209 of file SysInfo.hpp.

◆ getPageSize()

size_t alpaka::cpu::detail::getPageSize ( )
inline
Returns
Pagesize in bytes used by the system.

Definition at line 124 of file SysInfo.hpp.

◆ getTotalGlobalMemSizeBytes()

auto alpaka::cpu::detail::getTotalGlobalMemSizeBytes ( ) -> std::size_t
inline
Returns
The total number of bytes of global memory. Adapted from David Robert Nadeau: http://nadeausoftware.com/articles/2012/09/c_c_tip_how_get_physical_memory_size_system

Definition at line 146 of file SysInfo.hpp.

Variable Documentation

◆ NO_CPUID

constexpr int alpaka::cpu::detail::NO_CPUID = 0
constexpr

Definition at line 47 of file SysInfo.hpp.

◆ UNKNOWN_COMPILER

constexpr int alpaka::cpu::detail::UNKNOWN_COMPILER = 1
constexpr

Definition at line 49 of file SysInfo.hpp.

◆ UNKNOWN_CPU

constexpr int alpaka::cpu::detail::UNKNOWN_CPU = 0
constexpr

Definition at line 48 of file SysInfo.hpp.