OpenShot Audio Library | OpenShotAudio: juce::dsp::SIMDRegister< Type > Struct Template Reference

OpenShot Audio Library | OpenShotAudio 0.3.0

Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
juce::dsp::SIMDRegister< Type > Struct Template Reference

`#include <juce_SIMDRegister.h>`

## Public Types
using | ElementType = Type
using | value_type = ElementType
using | MaskType = typename SIMDInternal::MaskTypeFor< ElementType >::type
using | PrimitiveType = typename SIMDInternal::PrimitiveType< ElementType >::type
using | NativeOps = SIMDNativeOps< PrimitiveType >
using | vSIMDType = typename NativeOps::vSIMDType
using | vMaskType = SIMDRegister< MaskType >
using | vMaskSIMDType = typename vMaskType::vSIMDType
using | CmplxOps = CmplxSIMDOps< ElementType >

## Public Member Functions
| SIMDRegister () noexcept=default
| SIMDRegister (vSIMDType a) noexcept
| SIMDRegister (Type s) noexcept
| ~SIMDRegister () noexcept=default
void JUCE_VECTOR_CALLTYPE | copyToRawArray (ElementType *a) const noexcept
ElementType JUCE_VECTOR_CALLTYPE | get (size_t idx) const noexcept
void JUCE_VECTOR_CALLTYPE | set (size_t idx, ElementType v) noexcept
ElementType JUCE_VECTOR_CALLTYPE | operator[] (size_t idx) const noexcept
ElementAccess JUCE_VECTOR_CALLTYPE | operator[] (size_t idx) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator+= (SIMDRegister v) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator-= (SIMDRegister v) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator*= (SIMDRegister v) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator= (ElementType s) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator+= (ElementType s) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator-= (ElementType s) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator*= (ElementType s) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator&= (vMaskType v) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator|= (vMaskType v) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator^= (vMaskType v) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator&= (MaskType s) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator|= (MaskType s) noexcept
SIMDRegister &JUCE_VECTOR_CALLTYPE | operator^= (MaskType s) noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator+ (SIMDRegister v) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator- (SIMDRegister v) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator* (SIMDRegister v) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator+ (ElementType s) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator- (ElementType s) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator* (ElementType s) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator& (vMaskType v) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator| (vMaskType v) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator^ (vMaskType v) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator~ () const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator& (MaskType s) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator| (MaskType s) const noexcept
SIMDRegister JUCE_VECTOR_CALLTYPE | operator^ (MaskType s) const noexcept
bool JUCE_VECTOR_CALLTYPE | operator== (SIMDRegister other) const noexcept
bool JUCE_VECTOR_CALLTYPE | operator!= (SIMDRegister other) const noexcept
bool JUCE_VECTOR_CALLTYPE | operator== (Type s) const noexcept
bool JUCE_VECTOR_CALLTYPE | operator!= (Type s) const noexcept
ElementType | sum () const noexcept

## Static Public Member Functions
static constexpr size_t | size () noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | expand (ElementType s) noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | fromNative (vSIMDType a) noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | fromRawArray (const ElementType *a) noexcept
static vMaskType JUCE_VECTOR_CALLTYPE | equal (SIMDRegister a, SIMDRegister b) noexcept
static vMaskType JUCE_VECTOR_CALLTYPE | notEqual (SIMDRegister a, SIMDRegister b) noexcept
static vMaskType JUCE_VECTOR_CALLTYPE | lessThan (SIMDRegister a, SIMDRegister b) noexcept
static vMaskType JUCE_VECTOR_CALLTYPE | lessThanOrEqual (SIMDRegister a, SIMDRegister b) noexcept
static vMaskType JUCE_VECTOR_CALLTYPE | greaterThan (SIMDRegister a, SIMDRegister b) noexcept
static vMaskType JUCE_VECTOR_CALLTYPE | greaterThanOrEqual (SIMDRegister a, SIMDRegister b) noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | min (SIMDRegister a, SIMDRegister b) noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | max (SIMDRegister a, SIMDRegister b) noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | multiplyAdd (SIMDRegister a, const SIMDRegister b, SIMDRegister c) noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | truncate (SIMDRegister a) noexcept
static SIMDRegister JUCE_VECTOR_CALLTYPE | abs (SIMDRegister a) noexcept
static bool | isSIMDAligned (const ElementType *ptr) noexcept
static ElementType * | getNextSIMDAlignedPtr (ElementType *ptr) noexcept

## Public Attributes
vSIMDType | value

## Static Public Attributes
static constexpr size_t | SIMDRegisterSize = sizeof (vSIMDType)
static constexpr size_t | SIMDNumElements = SIMDRegisterSize / sizeof (ElementType)

## Detailed Description

template<typename Type>
struct juce::dsp::SIMDRegister< Type >

A wrapper around the platform's native SIMD register type.

This class is only available on SIMD machines. Use JUCE_USE_SIMD to query if SIMD is available for your system.

SIMDRegister<Type> is a templated class representing the native vectorized version of FloatingType. SIMDRegister supports all numerical primitive types and std:complex<float> and std::complex<double> supports and most operations of the corresponding primitive type. Additionally, SIMDRegister can be accessed like an array to extract the individual elements.

If you are using SIMDRegister as a pointer, then you must ensure that the memory is sufficiently aligned for SIMD vector operations. Failing to do so will result in crashes or very slow code. Use SIMDRegister::isSIMDAligned to query if a pointer is sufficiently aligned for SIMD vector operations.

Note that using SIMDRegister without enabling optimizations will result in code with very poor performance.

Definition at line 63 of file juce_SIMDRegister.h.

## Member Typedef Documentation

## ◆ CmplxOps

template<typename Type >

using juce::dsp::SIMDRegister< Type >::CmplxOps = CmplxSIMDOps<ElementType>

Wrapper for operations which need to be handled differently for complex and scalar types (used internally).

Definition at line 96 of file juce_SIMDRegister.h.

## ◆ ElementType

template<typename Type >

using juce::dsp::SIMDRegister< Type >::ElementType = Type

The type that represents the individual constituents of the SIMD Register

Definition at line 67 of file juce_SIMDRegister.h.

## ◆ MaskType

template<typename Type >

using juce::dsp::SIMDRegister< Type >::MaskType = typename SIMDInternal::MaskTypeFor<ElementType>::type

The corresponding primitive integer type, for example, this will be int32_t if type is a float.

Definition at line 74 of file juce_SIMDRegister.h.

## ◆ NativeOps

template<typename Type >

using juce::dsp::SIMDRegister< Type >::NativeOps = SIMDNativeOps<PrimitiveType>

The native operations for this platform and type combination (used internally)

Definition at line 83 of file juce_SIMDRegister.h.

## ◆ PrimitiveType

template<typename Type >

using juce::dsp::SIMDRegister< Type >::PrimitiveType = typename SIMDInternal::PrimitiveType<ElementType>::type

The native primitive type (used internally).

Definition at line 80 of file juce_SIMDRegister.h.

## ◆ value_type

template<typename Type >

using juce::dsp::SIMDRegister< Type >::value_type = ElementType

STL compatible value_type definition (same as ElementType).

Definition at line 70 of file juce_SIMDRegister.h.

## ◆ vMaskSIMDType

template<typename Type >

using juce::dsp::SIMDRegister< Type >::vMaskSIMDType = typename vMaskType::vSIMDType

The internal native type for the corresponding mask type (used internally).

Definition at line 92 of file juce_SIMDRegister.h.

## ◆ vMaskType

template<typename Type >

using juce::dsp::SIMDRegister< Type >::vMaskType = SIMDRegister<MaskType>

The corresponding integer SIMDRegister type (used internally).

Definition at line 89 of file juce_SIMDRegister.h.

## ◆ vSIMDType

template<typename Type >

using juce::dsp::SIMDRegister< Type >::vSIMDType = typename NativeOps::vSIMDType

The native type (used internally).

Definition at line 86 of file juce_SIMDRegister.h.

## Constructor & Destructor Documentation

## ◆ SIMDRegister() [1/3]

template<typename Type >

juce::dsp::SIMDRegister< Type >::SIMDRegister | ( |  | ) |
| inlinedefaultnoexcept

Default constructor.

## ◆ SIMDRegister() [2/3]

template<typename Type >

juce::dsp::SIMDRegister< Type >::SIMDRegister | ( | vSIMDType | a | ) |
| inlinenoexcept

Constructs an object from the native SIMD type.

Definition at line 115 of file juce_SIMDRegister.h.

## ◆ SIMDRegister() [3/3]

template<typename Type >

juce::dsp::SIMDRegister< Type >::SIMDRegister | ( | Type | s | ) |
| inlinenoexcept

Constructs an object from a scalar type by broadcasting it to all elements.

Definition at line 118 of file juce_SIMDRegister.h.

## ◆ ~SIMDRegister()

template<typename Type >

juce::dsp::SIMDRegister< Type >::~SIMDRegister | ( |  | ) |
| inlinedefaultnoexcept

Destructor.

## Member Function Documentation

## ◆ abs()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::abs | ( | SIMDRegister< Type > | a | ) |
| inlinestaticnoexcept

Returns the absolute value of each element.

Definition at line 338 of file juce_SIMDRegister.h.

## ◆ copyToRawArray()

template<typename Type >

void JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::copyToRawArray | ( | ElementType * | a | ) | const
| inlinenoexcept

Copies the elements of the SIMDRegister to a scalar array in memory.

Definition at line 144 of file juce_SIMDRegister.h.

## ◆ equal()

template<typename Type >

static vMaskType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::equal | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a SIMDRegister of the corresponding integral type where each element has each bit set if the corresponding element of a is equal to the corresponding element of b, or zero otherwise. The result can then be used in bit operations defined above to avoid branches in vector SIMD code.

Definition at line 286 of file juce_SIMDRegister.h.

## ◆ expand()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::expand | ( | ElementType | s | ) |
| inlinestaticnoexcept

Creates a new SIMDRegister from the corresponding scalar primitive. The scalar is extended to all elements of the vector.

Definition at line 130 of file juce_SIMDRegister.h.

Referenced by juce::dsp::SIMDRegister< Type >::abs(), and juce::dsp::SIMDRegister< Type >::operator==().

## ◆ fromNative()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::fromNative | ( | vSIMDType | a | ) |
| inlinestaticnoexcept

Creates a new SIMDRegister from the internal SIMD type (for example __mm128 for single-precision floating point on SSE architectures).

Definition at line 134 of file juce_SIMDRegister.h.

## ◆ fromRawArray()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::fromRawArray | ( | const ElementType * | a | ) |
| inlinestaticnoexcept

Creates a new SIMDRegister from the first SIMDNumElements of a scalar array.

Definition at line 137 of file juce_SIMDRegister.h.

## ◆ get()

template<typename Type >

ElementType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::get | ( | size_t | idx | ) | const
| inlinenoexcept

Returns the idx-th element of the receiver. Note that this does not check if idx is larger than the native register size.

Definition at line 153 of file juce_SIMDRegister.h.

Referenced by juce::dsp::SIMDRegister< Type >::operator[]().

## ◆ getNextSIMDAlignedPtr()

template<typename Type >

static ElementType * juce::dsp::SIMDRegister< Type >::getNextSIMDAlignedPtr | ( | ElementType * | ptr | ) |
| inlinestaticnoexcept

Returns the next position in memory where isSIMDAligned returns true.

If the current position in memory is already aligned then this method will simply return the pointer.

Definition at line 356 of file juce_SIMDRegister.h.

## ◆ greaterThan()

template<typename Type >

static vMaskType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::greaterThan | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a SIMDRegister of the corresponding integral type where each element has each bit set if the corresponding element of a is greater than to the corresponding element of b, or zero otherwise. The result can then be used in bit operations defined above to avoid branches in vector SIMD code.

Definition at line 306 of file juce_SIMDRegister.h.

## ◆ greaterThanOrEqual()

template<typename Type >

static vMaskType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::greaterThanOrEqual | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a SIMDRegister of the corresponding integral type where each element has each bit set if the corresponding element of a is greater than or equal to the corresponding element of b, or zero otherwise. The result can then be used in bit operations defined above to avoid branches in vector SIMD code.

Definition at line 311 of file juce_SIMDRegister.h.

## ◆ isSIMDAligned()

template<typename Type >

static bool juce::dsp::SIMDRegister< Type >::isSIMDAligned | ( | const ElementType * | ptr | ) |
| inlinestaticnoexcept

Checks if the given pointer is sufficiently aligned for using SIMD operations.

Definition at line 345 of file juce_SIMDRegister.h.

Referenced by juce::dsp::SIMDRegister< Type >::copyToRawArray(), and juce::dsp::SIMDRegister< Type >::fromRawArray().

## ◆ lessThan()

template<typename Type >

static vMaskType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::lessThan | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a SIMDRegister of the corresponding integral type where each element has each bit set if the corresponding element of a is less than to the corresponding element of b, or zero otherwise. The result can then be used in bit operations defined above to avoid branches in vector SIMD code.

Definition at line 296 of file juce_SIMDRegister.h.

Referenced by juce::dsp::SIMDRegister< Type >::abs().

## ◆ lessThanOrEqual()

template<typename Type >

static vMaskType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::lessThanOrEqual | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a SIMDRegister of the corresponding integral type where each element has each bit set if the corresponding element of a is than or equal to the corresponding element of b, or zero otherwise. The result can then be used in bit operations defined above to avoid branches in vector SIMD code.

Definition at line 301 of file juce_SIMDRegister.h.

## ◆ max()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::max | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a new vector where each element is the maximum of the corresponding element of a and b.

Definition at line 318 of file juce_SIMDRegister.h.

## ◆ min()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::min | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a new vector where each element is the minimum of the corresponding element of a and b.

Definition at line 315 of file juce_SIMDRegister.h.

## ◆ multiplyAdd()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::multiplyAdd | ( | SIMDRegister< Type > | a,
|  | const SIMDRegister< Type > | b,
|  | SIMDRegister< Type > | c
| ) |  |
| inlinestaticnoexcept

Multiplies b and c and adds the result to a.

Definition at line 322 of file juce_SIMDRegister.h.

## ◆ notEqual()

template<typename Type >

static vMaskType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::notEqual | ( | SIMDRegister< Type > | a,
|  | SIMDRegister< Type > | b
| ) |  |
| inlinestaticnoexcept

Returns a SIMDRegister of the corresponding integral type where each element has each bit set if the corresponding element of a is not equal to the corresponding element of b, or zero otherwise. The result can then be used in bit operations defined above to avoid branches in vector SIMD code.

Definition at line 291 of file juce_SIMDRegister.h.

## ◆ operator!=() [1/2]

template<typename Type >

bool JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator!= | ( | SIMDRegister< Type > | other | ) | const
| inlinenoexcept

Returns true if any element-wise comparisons return false.

Definition at line 274 of file juce_SIMDRegister.h.

## ◆ operator!=() [2/2]

template<typename Type >

bool JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator!= | ( | Type | s | ) | const
| inlinenoexcept

Returns true if any elements are not equal to the scalar.

Definition at line 280 of file juce_SIMDRegister.h.

## ◆ operator&() [1/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator& | ( | MaskType | s | ) | const
| inlinenoexcept

Returns a vector where each element is the bit-and'd value of the corresponding element in the receiver and the scalar s.

Definition at line 261 of file juce_SIMDRegister.h.

## ◆ operator&() [2/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator& | ( | vMaskType | v | ) | const
| inlinenoexcept

Returns the bit-and of the receiver and v.

Definition at line 248 of file juce_SIMDRegister.h.

## ◆ operator&=() [1/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator&= | ( | MaskType | s | ) |
| inlinenoexcept

Bit-and each element of the receiver with the scalar s and store the result in the receiver.

Definition at line 218 of file juce_SIMDRegister.h.

## ◆ operator&=() [2/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator&= | ( | vMaskType | v | ) |
| inlinenoexcept

Bit-and the receiver with SIMDRegister v and store the result in the receiver.

Definition at line 208 of file juce_SIMDRegister.h.

## ◆ operator*() [1/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator* | ( | ElementType | s | ) | const
| inlinenoexcept

Returns a vector where each element is the product of the corresponding element in the receiver and the scalar s.

Definition at line 244 of file juce_SIMDRegister.h.

## ◆ operator*() [2/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator* | ( | SIMDRegister< Type > | v | ) | const
| inlinenoexcept

Returns the product of the receiver and v.

Definition at line 234 of file juce_SIMDRegister.h.

## ◆ operator*=() [1/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator*= | ( | ElementType | s | ) |
| inlinenoexcept

Multiplies a scalar to the receiver.

Definition at line 204 of file juce_SIMDRegister.h.

## ◆ operator*=() [2/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator*= | ( | SIMDRegister< Type > | v | ) |
| inlinenoexcept

Multiplies another SIMDRegister to the receiver.

Definition at line 191 of file juce_SIMDRegister.h.

## ◆ operator+() [1/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator+ | ( | ElementType | s | ) | const
| inlinenoexcept

Returns a vector where each element is the sum of the corresponding element in the receiver and the scalar s.

Definition at line 238 of file juce_SIMDRegister.h.

## ◆ operator+() [2/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator+ | ( | SIMDRegister< Type > | v | ) | const
| inlinenoexcept

Returns the sum of the receiver and v.

Definition at line 228 of file juce_SIMDRegister.h.

## ◆ operator+=() [1/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator+= | ( | ElementType | s | ) |
| inlinenoexcept

Adds a scalar to the receiver.

Definition at line 198 of file juce_SIMDRegister.h.

## ◆ operator+=() [2/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator+= | ( | SIMDRegister< Type > | v | ) |
| inlinenoexcept

Adds another SIMDRegister to the receiver.

Definition at line 185 of file juce_SIMDRegister.h.

## ◆ operator-() [1/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator- | ( | ElementType | s | ) | const
| inlinenoexcept

Returns a vector where each element is the difference of the corresponding element in the receiver and the scalar s.

Definition at line 241 of file juce_SIMDRegister.h.

## ◆ operator-() [2/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator- | ( | SIMDRegister< Type > | v | ) | const
| inlinenoexcept

Returns the difference of the receiver and v.

Definition at line 231 of file juce_SIMDRegister.h.

## ◆ operator-=() [1/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator-= | ( | ElementType | s | ) |
| inlinenoexcept

Subtracts a scalar to the receiver.

Definition at line 201 of file juce_SIMDRegister.h.

## ◆ operator-=() [2/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator-= | ( | SIMDRegister< Type > | v | ) |
| inlinenoexcept

Subtracts another SIMDRegister to the receiver.

Definition at line 188 of file juce_SIMDRegister.h.

## ◆ operator=()

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator= | ( | ElementType | s | ) |
| inlinenoexcept

Broadcasts the scalar to all elements of the receiver.

Definition at line 195 of file juce_SIMDRegister.h.

## ◆ operator==() [1/2]

template<typename Type >

bool JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator== | ( | SIMDRegister< Type > | other | ) | const
| inlinenoexcept

Returns true if all element-wise comparisons return true.

Definition at line 271 of file juce_SIMDRegister.h.

## ◆ operator==() [2/2]

template<typename Type >

bool JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator== | ( | Type | s | ) | const
| inlinenoexcept

Returns true if all elements are equal to the scalar.

Definition at line 277 of file juce_SIMDRegister.h.

## ◆ operator[]() [1/2]

template<typename Type >

ElementType JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator[] | ( | size_t | idx | ) | const
| inlinenoexcept

Returns the idx-th element of the receiver. Note that this does not check if idx is larger than the native register size.

Definition at line 170 of file juce_SIMDRegister.h.

## ◆ operator[]() [2/2]

template<typename Type >

ElementAccess JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator[] | ( | size_t | idx | ) |
| inlinenoexcept

Returns the idx-th element of the receiver. Note that this does not check if idx is larger than the native register size.

Definition at line 177 of file juce_SIMDRegister.h.

## ◆ operator^() [1/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator^ | ( | MaskType | s | ) | const
| inlinenoexcept

Returns a vector where each element is the bit-xor'd value of the corresponding element in the receiver and the scalar s.

Definition at line 267 of file juce_SIMDRegister.h.

## ◆ operator^() [2/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator^ | ( | vMaskType | v | ) | const
| inlinenoexcept

Returns the bit-xor of the receiver and v.

Definition at line 254 of file juce_SIMDRegister.h.

## ◆ operator^=() [1/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator^= | ( | MaskType | s | ) |
| inlinenoexcept

Bit-xor each element of the receiver with the scalar s and store the result in the receiver.

Definition at line 224 of file juce_SIMDRegister.h.

## ◆ operator^=() [2/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator^= | ( | vMaskType | v | ) |
| inlinenoexcept

Bit-xor the receiver with SIMDRegister v and store the result in the receiver.

Definition at line 214 of file juce_SIMDRegister.h.

## ◆ operator|() [1/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator| | ( | MaskType | s | ) | const
| inlinenoexcept

Returns a vector where each element is the bit-or'd value of the corresponding element in the receiver and the scalar s.

Definition at line 264 of file juce_SIMDRegister.h.

## ◆ operator|() [2/2]

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator| | ( | vMaskType | v | ) | const
| inlinenoexcept

Returns the bit-or of the receiver and v.

Definition at line 251 of file juce_SIMDRegister.h.

## ◆ operator|=() [1/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator|= | ( | MaskType | s | ) |
| inlinenoexcept

Bit-or each element of the receiver with the scalar s and store the result in the receiver.

Definition at line 221 of file juce_SIMDRegister.h.

## ◆ operator|=() [2/2]

template<typename Type >

SIMDRegister &JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator|= | ( | vMaskType | v | ) |
| inlinenoexcept

Bit-or the receiver with SIMDRegister v and store the result in the receiver.

Definition at line 211 of file juce_SIMDRegister.h.

## ◆ operator~()

template<typename Type >

SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::operator~ | ( |  | ) | const
| inlinenoexcept

Returns a vector where each element is the bit-inverted value of the corresponding element in the receiver.

Definition at line 257 of file juce_SIMDRegister.h.

## ◆ set()

template<typename Type >

void JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::set | ( | size_t | idx,
|  | ElementType | v
| ) |  |
| inlinenoexcept

Sets the idx-th element of the receiver. Note that this does not check if idx is larger than the native register size.

Definition at line 161 of file juce_SIMDRegister.h.

## ◆ size()

template<typename Type >

static constexpr size_t juce::dsp::SIMDRegister< Type >::size | ( |  | ) |
| inlinestaticconstexprnoexcept

Returns the number of elements in this vector.

Definition at line 125 of file juce_SIMDRegister.h.

## ◆ sum()

template<typename Type >

ElementType juce::dsp::SIMDRegister< Type >::sum | ( |  | ) | const
| inlinenoexcept

Returns a scalar which is the sum of all elements of the receiver.

Definition at line 329 of file juce_SIMDRegister.h.

## ◆ truncate()

template<typename Type >

static SIMDRegister JUCE_VECTOR_CALLTYPE juce::dsp::SIMDRegister< Type >::truncate | ( | SIMDRegister< Type > | a | ) |
| inlinestaticnoexcept

Truncates each element to its integer part. Effectively discards the fractional part of each element. A.k.a. round to zero.

Definition at line 334 of file juce_SIMDRegister.h.

## Member Data Documentation

## ◆ SIMDNumElements

template<typename Type >

constexpr size_t juce::dsp::SIMDRegister< Type >::SIMDNumElements = SIMDRegisterSize / sizeof (ElementType)
| staticconstexpr

The number of elements that this vector can hold.

Definition at line 107 of file juce_SIMDRegister.h.

Referenced by juce::dsp::SIMDRegister< Type >::get(), juce::dsp::SIMDRegister< Type >::operator[](), juce::dsp::SIMDRegister< Type >::set(), and juce::dsp::SIMDRegister< Type >::size().

## ◆ SIMDRegisterSize

template<typename Type >

constexpr size_t juce::dsp::SIMDRegister< Type >::SIMDRegisterSize = sizeof (vSIMDType)
| staticconstexpr

The size in bytes of this register.

Definition at line 104 of file juce_SIMDRegister.h.

Referenced by juce::dsp::SIMDRegister< Type >::getNextSIMDAlignedPtr(), and juce::dsp::SIMDRegister< Type >::isSIMDAligned().

## ◆ value

template<typename Type >

vSIMDType juce::dsp::SIMDRegister< Type >::value

Definition at line 109 of file juce_SIMDRegister.h.

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

- juce_SIMDRegister.h