#include <OPC_IceHook.h>
Public Member Functions | |
inline_ udword | GetNbHits () const |
Returns the number of eraly exits due to temporal coherence. | |
inline_ udword | GetNbTotalCalls () const |
Returns the total number of calls to the radix sorter. | |
inline_ const udword * | GetRanks () const |
Access to results. mRanks is a list of indices in sorted order, i.e. in the order you may further process your data. | |
inline_ udword * | GetRecyclable () const |
mIndices2 gets trashed on calling the sort routine, but otherwise you can recycle it the way you want. | |
udword | GetUsedRam () const |
RadixSort () | |
RadixSort & | Sort (const udword *input, udword nb, RadixHint hint=RADIX_SIGNED) |
RadixSort & | Sort (const float *input, udword nb) |
~RadixSort () | |
Private Member Functions | |
void | CheckResize (udword nb) |
bool | Resize (udword nb) |
Private Attributes | |
udword | mCurrentSize |
Current size of the indices list. | |
udword | mNbHits |
Number of early exits due to coherence. | |
udword * | mRanks |
Two lists, swapped each pass. | |
udword * | mRanks2 |
udword | mTotalCalls |
Total number of calls to the sort routine. |
Definition at line 27 of file OPC_IceHook.h.
Constructor.
Definition at line 170 of file IceRevisitedRadix.cpp.
Destructor.
Definition at line 186 of file IceRevisitedRadix.cpp.
inline_ void RadixSort::CheckResize | ( | udword | nb | ) | [private] |
Definition at line 217 of file IceRevisitedRadix.cpp.
inline_ udword IceCore::RadixSort::GetNbHits | ( | ) | const [inline] |
Returns the number of eraly exits due to temporal coherence.
Definition at line 48 of file OPC_IceHook.h.
inline_ udword IceCore::RadixSort::GetNbTotalCalls | ( | ) | const [inline] |
Returns the total number of calls to the radix sorter.
Definition at line 46 of file OPC_IceHook.h.
inline_ const udword* IceCore::RadixSort::GetRanks | ( | ) | const [inline] |
Access to results. mRanks is a list of indices in sorted order, i.e. in the order you may further process your data.
Definition at line 38 of file OPC_IceHook.h.
inline_ udword* IceCore::RadixSort::GetRecyclable | ( | ) | const [inline] |
mIndices2 gets trashed on calling the sort routine, but otherwise you can recycle it the way you want.
Definition at line 41 of file OPC_IceHook.h.
udword RadixSort::GetUsedRam | ( | ) | const |
Gets the ram used.
Definition at line 511 of file IceRevisitedRadix.cpp.
bool RadixSort::Resize | ( | udword | nb | ) | [private] |
Resizes the inner lists.
nb | [in] new size (number of dwords) |
Definition at line 204 of file IceRevisitedRadix.cpp.
RadixSort & RadixSort::Sort | ( | const udword * | input, |
udword | nb, | ||
RadixHint | hint = RADIX_SIGNED |
||
) |
Main sort routine. This one is for integer values. After the call, mRanks contains a list of indices in sorted order, i.e. in the order you may process your data.
input | [in] a list of integer values to sort |
nb | [in] number of values to sort, must be < 2^31 |
hint | [in] RADIX_SIGNED to handle negative values, RADIX_UNSIGNED if you know your input buffer only contains positive values |
Definition at line 238 of file IceRevisitedRadix.cpp.
RadixSort & RadixSort::Sort | ( | const float * | input2, |
udword | nb | ||
) |
Main sort routine. This one is for floating-point values. After the call, mRanks contains a list of indices in sorted order, i.e. in the order you may process your data.
input | [in] a list of floating-point values to sort |
nb | [in] number of values to sort, must be < 2^31 |
Definition at line 350 of file IceRevisitedRadix.cpp.
udword IceCore::RadixSort::mCurrentSize [private] |
Current size of the indices list.
Definition at line 55 of file OPC_IceHook.h.
udword IceCore::RadixSort::mNbHits [private] |
Number of early exits due to coherence.
Definition at line 60 of file OPC_IceHook.h.
udword* IceCore::RadixSort::mRanks [private] |
Two lists, swapped each pass.
Definition at line 56 of file OPC_IceHook.h.
udword* IceCore::RadixSort::mRanks2 [private] |
Definition at line 57 of file OPC_IceHook.h.
udword IceCore::RadixSort::mTotalCalls [private] |
Total number of calls to the sort routine.
Definition at line 59 of file OPC_IceHook.h.