Blaze 3.9
Public Member Functions | Static Public Member Functions | Private Attributes | List of all members
blaze::ShiftLI Struct Reference

Generic wrapper for the uniform left-shift operation. More...

#include <ShiftLI.h>

Public Member Functions

 ShiftLI (int count)
 Constructor of the ShiftLI functor. More...
 
template<typename T >
BLAZE_ALWAYS_INLINE BLAZE_DEVICE_CALLABLE decltype(auto) operator() (T &&a) const
 Returns the result of the uniform left-shift operation for the given objects/values. More...
 
template<typename T >
BLAZE_ALWAYS_INLINE decltype(auto) load (const T &a) const
 Returns the result of the uniform left-shift operation for the given SIMD vector. More...
 

Static Public Member Functions

template<typename T >
static constexpr bool simdEnabled ()
 Returns whether SIMD is enabled for the specified data type T. More...
 
static constexpr bool paddingEnabled ()
 Returns whether the operation supports padding, i.e. whether it can deal with zeros. More...
 

Private Attributes

int count_
 The number of bits to shift.
 

Detailed Description

Generic wrapper for the uniform left-shift operation.

Constructor & Destructor Documentation

◆ ShiftLI()

blaze::ShiftLI::ShiftLI ( int  count)
inlineexplicit

Constructor of the ShiftLI functor.

Parameters
countThe number of bits to shift.

Member Function Documentation

◆ load()

template<typename T >
BLAZE_ALWAYS_INLINE decltype(auto) blaze::ShiftLI::load ( const T &  a) const
inline

Returns the result of the uniform left-shift operation for the given SIMD vector.

Parameters
aThe SIMD vector to be shifted.
Returns
The result of the uniform left-shift operation for the given SIMD vector.

◆ operator()()

template<typename T >
BLAZE_ALWAYS_INLINE BLAZE_DEVICE_CALLABLE decltype(auto) blaze::ShiftLI::operator() ( T &&  a) const
inline

Returns the result of the uniform left-shift operation for the given objects/values.

Parameters
aThe given object/value to be shifted.
Returns
The result of the uniform left-shift operation for the given objects/values.

◆ paddingEnabled()

static constexpr bool blaze::ShiftLI::paddingEnabled ( )
inlinestaticconstexpr

Returns whether the operation supports padding, i.e. whether it can deal with zeros.

Returns
true in case padding is supported, false if not.

◆ simdEnabled()

template<typename T >
static constexpr bool blaze::ShiftLI::simdEnabled ( )
inlinestaticconstexpr

Returns whether SIMD is enabled for the specified data type T.

Returns
true in case SIMD is enabled for the data type T, false if not.

The documentation for this struct was generated from the following file: