IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
BitwiseSelectReg.h
Go to the documentation of this file.
1 // BitwiseSelectReg.h:
3 // -------------------
4 //
14 
15 #ifndef __IPSDKUTIL_INSTRUCTIONSET_LOGICAL_DETAIL_AVX2_BITWISESELECTREG_H__
16 #define __IPSDKUTIL_INSTRUCTIONSET_LOGICAL_DETAIL_AVX2_BITWISESELECTREG_H__
17 
24 
25 #include <boost/type_traits/is_integral.hpp>
26 
27 namespace ipsdk {
28 namespace simd {
29 namespace detail {
30 
33 
35 template <typename T>
37 {
38  static IPSDK_FORCEINLINE
39  typename AvxType<T>::Type
40  act(const typename AvxType<T>::Type& mask,
41  const typename AvxType<T>::Type& in1,
42  const typename AvxType<T>::Type& in2)
43  {
44  typename AvxType<T>::Type in2AndNotMask =
46 
47  typename AvxType<T>::Type out =
50  in2AndNotMask);
51 
52  return out;
53  }
54 
55  static IPSDK_FORCEINLINE
56  void
57  act(const typename AvxType<T>::Type& mask,
58  const typename AvxType<T>::Type& in1,
59  const typename AvxType<T>::Type& in2,
60  typename AvxType<T>::Type& out)
61  {
62  typename AvxType<T>::Type in2AndNotMask, in1AndMask;
65  BitwiseOrReg<eInstructionSet::eIS_Avx2, T>::act(in1AndMask, in2AndNotMask, out);
66  }
67 };
68 
71 
72 } // end of namespace detail
73 } // end of namespace simd
74 } // end of namespace ipsdk
75 
76 #endif // __IPSDKUTIL_INSTRUCTIONSET_LOGICAL_DETAIL_AVX2_BITWISESELECTREG_H__
Defines the IPSDK_FORCEINLINE.
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
Definition: BitwiseAndNotReg.h:30
Definition: BitwiseSelectReg.h:30
eInstructionSet
Enumerate for processor instruction set description.
Definition: InstructionSetTypes.h:31
Definition: BitwiseOrReg.h:30
Advanced Vector Extensions 2.
Definition: InstructionSetTypes.h:48
Definition of import/export macro for library.
structure used to retrieve AVX type associated to a base type
Definition: AvxTypes.h:33
Definition: BitwiseAndReg.h:30