IPSDK  4_1_0_2
IPSDK : Image Processing Software Development Kit
max.h
Go to the documentation of this file.
1 // max.h:
3 // -----------------
4 //
16 
17 #ifndef __IPSDKUTIL_INSTRUCTIONSET_ARITHMETIC_MAX_H__
18 #define __IPSDKUTIL_INSTRUCTIONSET_ARITHMETIC_MAX_H__
19 
21 
26 
27 namespace ipsdk {
28 namespace simd {
29 
32 
37 template <eInstructionSet::domain instructionSet, class PackT>
38 IPSDK_FORCEINLINE
39 PackT
40 max(const PackT& in1, const PackT& in2)
41 {
42  typedef typename PackT::DataType T;
43  return detail::BinaryPackOp<instructionSet, T,
44  detail::MaxReg<instructionSet, T> >::act(in1, in2);
45 }
46 
47 template <eInstructionSet::domain instructionSet, class PackT>
48 IPSDK_FORCEINLINE
49 void
50 max(const PackT& in1, const PackT& in2, PackT& out)
51 {
52  typedef typename PackT::DataType T;
53  detail::BinaryPackOp<instructionSet, T,
54  detail::MaxReg<instructionSet, T> >::act(in1, in2, out);
55 }
56 
59 
60 } // end of namespace simd
61 } // end of namespace ipsdk
62 
63 #endif // __IPSDKUTIL_INSTRUCTIONSET_ARITHMETIC_MAX_H__
Defines the IPSDK_FORCEINLINE.
Main namespace for IPSDK library.
Definition: AlgorithmFunctionEfficiency.h:22
template structure which is specialized to implement the maximum computation on 2 scalars or 2 regist...
IPSDK_FORCEINLINE PackT max(const PackT &in1, const PackT &in2)
returns the maximum of 2 packs
Definition: max.h:40
defines template structures PromotedType<T1, T2> and PromotedType3<T1, T2, T3>; their attribute Type ...
Vector DataType
data type used for estimation
Definition: EstimationTypes.h:58
Definition: MaxRegDecl.h:29
Definition of import/export macro for library.
Definition: BinaryPackOp.h:31