Blaze 3.9
Functions
Setall.h File Reference

Header file for the SIMD setall functionality. More...

#include <blaze/math/simd/BasicTypes.h>
#include <blaze/system/Inline.h>
#include <blaze/system/Vectorization.h>
#include <blaze/util/constraints/Integral.h>
#include <blaze/util/EnableIf.h>
#include <blaze/util/mpl/If.h>
#include <blaze/util/StaticAssert.h>
#include <blaze/util/Types.h>
#include <blaze/util/typetraits/HasSize.h>
#include <blaze/util/typetraits/IsIntegral.h>
#include <blaze/util/typetraits/IsSigned.h>

Go to the source code of this file.

Functions

template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 1UL >, If_t< IsSigned_v< T >, SIMDint8, SIMDuint8 > > blaze::setall (T v0, Ts... vs) noexcept
 Sets all values in a SIMD vector to the given 1-byte integral values. More...
 
template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 1UL >, If_t< IsSigned_v< T >, SIMDcint8, SIMDcuint8 > > blaze::setall (const complex< T > &v0, const complex< Ts > &... vs) noexcept
 Sets all values in the vector to the given 1-byte integral complex values. More...
 
template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 2UL >, If_t< IsSigned_v< T >, SIMDint16, SIMDuint16 > > blaze::setall (T v0, Ts... vs) noexcept
 Sets all values in a SIMD vector to the given 2-byte integral values. More...
 
template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 2UL >, If_t< IsSigned_v< T >, SIMDcint16, SIMDcuint16 > > blaze::setall (const complex< T > &v0, const complex< Ts > &... vs) noexcept
 Sets all values in the vector to the given 2-byte integral complex values. More...
 
template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 4UL >, If_t< IsSigned_v< T >, SIMDint32, SIMDuint32 > > blaze::setall (T v0, Ts... vs) noexcept
 Sets all values in a SIMD vector to the given 4-byte integral values. More...
 
template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 4UL >, If_t< IsSigned_v< T >, SIMDcint32, SIMDcuint32 > > blaze::setall (const complex< T > &v0, const complex< Ts > &... vs) noexcept
 Sets all values in the vector to the given 4-byte integral complex values. More...
 
template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 8UL >, If_t< IsSigned_v< T >, SIMDint64, SIMDuint64 > > blaze::setall (T v0, Ts... vs) noexcept
 Sets all values in a SIMD vector to the given 8-byte integral values. More...
 
template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 8UL >, If_t< IsSigned_v< T >, SIMDcint64, SIMDcuint64 > > blaze::setall (const complex< T > &v0, const complex< Ts > &... vs) noexcept
 Sets all values in the vector to the given 8-byte integral complex values. More...
 
template<typename... Ts>
SIMDfloat blaze::setall (float v0, Ts... vs) noexcept
 Sets all values in a SIMD vector to the given float values. More...
 
template<typename... Ts>
SIMDcfloat blaze::setall (const complex< float > &v0, Ts... vs) noexcept
 Sets all values in the vector to the given complex<float> values. More...
 
template<typename... Ts>
SIMDdouble blaze::setall (double v0, Ts... vs) noexcept
 Sets all values in a SIMD vector to the given double values. More...
 
template<typename... Ts>
SIMDcdouble blaze::setall (const complex< double > &v0, Ts... vs) noexcept
 Sets all values in the vector to the given complex<double> values. More...
 

Detailed Description

Header file for the SIMD setall functionality.

Copyright (C) 2012-2020 Klaus Iglberger - All Rights Reserved

This file is part of the Blaze library. You can redistribute it and/or modify it under the terms of the New (Revised) BSD License. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  3. Neither the names of the Blaze development group nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Function Documentation

◆ setall() [1/6]

template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 2UL >, If_t< IsSigned_v< T >, SIMDcint16, SIMDcuint16 > > blaze::setall ( const complex< T > &  v0,
const complex< Ts > &...  vs 
)
noexcept

Sets all values in the vector to the given 2-byte integral complex values.

Parameters
v0The first given 2-byte integral complex value.
vsThe remaining 2-byte integral complex values.
Returns
The SIMD vector of 2-byte integral complex values.

This function sets the values of a SIMD vector to the given values. Depending on the available SIMD instruction set, the function accepts another maximum number of values:

SIMD instruction setMaximum number of values
SSE 4
AVX 8
AVX-51216

In case less arguments are given than the SIMD vector contains values, the missing values are set to 0.

◆ setall() [2/6]

template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 4UL >, If_t< IsSigned_v< T >, SIMDcint32, SIMDcuint32 > > blaze::setall ( const complex< T > &  v0,
const complex< Ts > &...  vs 
)
noexcept

Sets all values in the vector to the given 4-byte integral complex values.

Parameters
v0The first given 4-byte integral complex value.
vsThe remaining 4-byte integral complex values.
Returns
The SIMD vector of 4-byte integral complex values.

This function sets the values of a SIMD vector to the given values. Depending on the available SIMD instruction set, the function accepts another maximum number of values:

SIMD instruction setMaximum number of values
SSE 2
AVX 4
AVX-5128

In case less arguments are given than the SIMD vector contains values, the missing values are set to 0.

◆ setall() [3/6]

template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 8UL >, If_t< IsSigned_v< T >, SIMDcint64, SIMDcuint64 > > blaze::setall ( const complex< T > &  v0,
const complex< Ts > &...  vs 
)
noexcept

Sets all values in the vector to the given 8-byte integral complex values.

Parameters
v0The first given 8-byte integral complex value.
vsThe remaining 8-byte integral complex values.
Returns
The SIMD vector of 8-byte integral complex values.

This function sets the values of a SIMD vector to the given values. Depending on the available SIMD instruction set, the function accepts another maximum number of values:

SIMD instruction setMaximum number of values
SSE 1
AVX 2
AVX-5124

In case less arguments are given than the SIMD vector contains values, the missing values are set to 0.

◆ setall() [4/6]

template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 2UL >, If_t< IsSigned_v< T >, SIMDint16, SIMDuint16 > > blaze::setall ( v0,
Ts...  vs 
)
noexcept

Sets all values in a SIMD vector to the given 2-byte integral values.

Parameters
v0The first given 2-byte integral value.
vsThe remaining 2-byte integral values.
Returns
The SIMD vector of 2-byte integral values.

This function sets the values of a SIMD vector to the given values. Depending on the available SIMD instruction set, the function accepts another maximum number of values:

SIMD instruction setMaximum number of values
SSE 8
AVX 16
AVX-51232

In case less arguments are given than the SIMD vector contains values, the missing values are set to 0.

◆ setall() [5/6]

template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 4UL >, If_t< IsSigned_v< T >, SIMDint32, SIMDuint32 > > blaze::setall ( v0,
Ts...  vs 
)
noexcept

Sets all values in a SIMD vector to the given 4-byte integral values.

Parameters
v0The first given 4-byte integral value.
vsThe remaining 4-byte integral values.
Returns
The SIMD vector of 4-byte integral values.

This function sets the values of a SIMD vector to the given values. Depending on the available SIMD instruction set, the function accepts another maximum number of values:

SIMD instruction setMaximum number of values
SSE 4
AVX 8
AVX-51216

In case less arguments are given than the SIMD vector contains values, the missing values are set to 0.

◆ setall() [6/6]

template<typename T , typename... Ts>
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 8UL >, If_t< IsSigned_v< T >, SIMDint64, SIMDuint64 > > blaze::setall ( v0,
Ts...  vs 
)
noexcept

Sets all values in a SIMD vector to the given 8-byte integral values.

Parameters
v0The first given 8-byte integral value.
vsThe remaining 8-byte integral values.
Returns
The SIMD vector of 8-byte integral values.

This function sets the values of a SIMD vector to the given values. Depending on the available SIMD instruction set, the function accepts another maximum number of values:

SIMD instruction setMaximum number of values
SSE 2
AVX 4
AVX-5128

In case less arguments are given than the SIMD vector contains values, the missing values are set to 0.