6#include "Algo/BinarySearch.h"
14template<
typename T,
class PREDICATE_CLASS>
27template<
typename T,
class PREDICATE_CLASS>
76template<
class T,
class PREDICATE_CLASS>
77UE_DEPRECATED(5.3,
"Sort is deprecated, please use Algo::Sort. Algo::Sort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
91template<
class T,
class PREDICATE_CLASS>
92UE_DEPRECATED(5.3,
"Sort is deprecated, please use Algo::Sort. Algo::Sort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
107UE_DEPRECATED(5.3,
"Sort is deprecated, please use Algo::Sort. Algo::Sort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
121UE_DEPRECATED(5.3,
"Sort is deprecated, please use Algo::Sort. Algo::Sort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
138template<
class T,
class PREDICATE_CLASS>
194template <
class TGCDPolicy>
214 auto Num = To - From;
215 auto GCD = TGCDPolicy::GCD(
Num, Amount);
225 IndexToFill = (IndexToFill + Amount) %
Num;
237template <
class TRotationPolicy>
249 template <
class T,
class PREDICATE_CLASS>
279template <
class TMergePolicy,
int32 MinMergeSubgroupSize = 2>
290 template<
class T,
class PREDICATE_CLASS>
295 if (MinMergeSubgroupSize > 1)
297 if (MinMergeSubgroupSize > 2)
360template<
class T,
class PREDICATE_CLASS>
375template<
class T,
class PREDICATE_CLASS>
376UE_DEPRECATED(5.3,
"StableSort is deprecated, please use Algo::StableSort. Algo::StableSort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
390template<
class T,
class PREDICATE_CLASS>
391UE_DEPRECATED(5.3,
"StableSort is deprecated, please use Algo::StableSort. Algo::StableSort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
407UE_DEPRECATED(5.3,
"StableSort is deprecated, please use Algo::StableSort. Algo::StableSort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
421UE_DEPRECATED(5.3,
"StableSort is deprecated, please use Algo::StableSort. Algo::StableSort supports ranges with index types other than int32, and doesn't automatically dereference pointers.")
434template<
typename ValueType,
typename CountType,
class SortKeyClass >
437 CountType Histograms[ 1024 + 2048 + 2048 ];
449 uint32 Key = SortKey( s[i] );
481 ValueType
Value = s[i];
492 ValueType
Value = s[i];
503 ValueType
Value = s[i];
511template<
typename T >
520template<
typename ValueType,
typename CountType >
532 union {
float f;
uint32 i; }
v;
540template<
typename CountType >
559template< ERadixSortBufferState BufferState,
typename ValueType,
typename CountType,
class SortKeyClass >
562 CountType Histograms[(1024 * 2) + (2048 * 4)];
576 uint64 Key = SortKey( *s++ );
595 for (; i < 1024; i++)
604 for (; i < 2048; i++)
682template<
typename T >
691template< ERadixSortBufferState BufferState,
typename ValueType,
typename CountType >
697template<
typename ValueType,
typename CountType,
class SortKeyClass >
705template<
typename ValueType,
typename CountType >
OODEFFUNC typedef void(OODLE_CALLBACK t_fp_OodleCore_Plugin_Free)(void *ptr)
#define UE_DEPRECATED(Version, Message)
Definition CoreMiscDefines.h:302
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
void StableSort(T *First, const int32 Num, const PREDICATE_CLASS &Predicate)
Definition Sorting.h:377
void StableSortInternal(T *First, const int32 Num, const PREDICATE_CLASS &Predicate)
Definition Sorting.h:361
void RadixSort64(ValueType *RESTRICT Array, ValueType *RESTRICT Buffer, CountType Num, const SortKeyClass &SortKey)
Definition Sorting.h:560
ERadixSortBufferState
Definition Sorting.h:547
void RadixSort32(ValueType *RESTRICT Dst, ValueType *RESTRICT Src, CountType Num, const SortKeyClass &SortKey)
Definition Sorting.h:435
void Sort(T *First, const int32 Num, const PREDICATE_CLASS &Predicate)
Definition Sorting.h:78
UE_REWRITE constexpr void Exchange(T &A, T &B)
Definition UnrealTemplate.h:627
UE_INTRINSIC_CAST UE_REWRITE constexpr std::remove_reference_t< T > && MoveTemp(T &&Obj) noexcept
Definition UnrealTemplate.h:520
static int32 GCD(int32 A, int32 B)
Definition Sorting.h:176
UE_FORCEINLINE_HINT SizeType AddUninitialized()
Definition Array.h:1664
static void Rotate(T *First, const int32 From, const int32 To, const int32 Amount)
Definition Sorting.h:207
static void Sort(T *First, const int32 Num, const PREDICATE_CLASS &Predicate)
Definition Sorting.h:291
static void Merge(T *First, const int32 Mid, const int32 Num, const PREDICATE_CLASS &Predicate)
Definition Sorting.h:250
SizeType UpperBoundInternal(RangeValueType *First, const SizeType Num, const PredicateValueType &Value, ProjectionType Projection, SortPredicateType SortPredicate)
Definition BinarySearch.h:56
SizeType LowerBoundInternal(RangeValueType *First, const SizeType Num, const PredicateValueType &Value, ProjectionType Projection, SortPredicateType SortPredicate)
Definition BinarySearch.h:23
UE_REWRITE void Sort(RangeType &&Range)
Definition Sort.h:16
float v
Definition radaudio_mdct.cpp:62
U16 Index
Definition radfft.cpp:71
Definition IdentityFunctor.h:11
static UE_FORCEINLINE_HINT void * Memzero(void *Dest, SIZE_T Count)
Definition UnrealMemory.h:131
uint32 operator()(float Value) const
Definition Sorting.h:530
int32 Num() const
Definition Sorting.h:56
T * GetData() const
Definition Sorting.h:55
TArrayRange(T *InPtr, int32 InSize)
Definition Sorting.h:49
TDereferenceWrapper(const PREDICATE_CLASS &InPredicate)
Definition Sorting.h:32
const PREDICATE_CLASS & Predicate
Definition Sorting.h:30
UE_FORCEINLINE_HINT bool operator()(T *A, T *B) const
Definition Sorting.h:36
TDereferenceWrapper(const PREDICATE_CLASS &InPredicate)
Definition Sorting.h:19
UE_FORCEINLINE_HINT bool operator()(const T &A, const T &B) const
Definition Sorting.h:24
UE_FORCEINLINE_HINT bool operator()(T &A, T &B)
Definition Sorting.h:23
const PREDICATE_CLASS & Predicate
Definition Sorting.h:17
Definition IsContiguousContainer.h:16
static constexpr bool Value
Definition IsContiguousContainer.h:20
UE_FORCEINLINE_HINT uint32 operator()(const T &Value) const
Definition Sorting.h:514
UE_FORCEINLINE_HINT uint64 operator()(const T &Value) const
Definition Sorting.h:685