Extract
Applicability
Product |
Supported |
|---|---|
√ |
|
√ |
|
x |
|
√ |
|
x |
|
x |
Function
Processes the sorting result data and outputs the sorted values and indexes.
Prototype
1 2 | template <typename T> __aicore__ inline void Extract(const LocalTensor<T> &dstValue, const LocalTensor<uint32_t> &dstIndex, const LocalTensor<T> &sorted, const int32_t repeatTime) |
Parameters
Parameter |
Description |
|---|---|
T |
Data type of the operand. For the For the For the |
Parameter |
Input/Output |
Description |
|---|---|---|
dstValue |
Output |
Destination operand. The type is LocalTensor, and the supported TPosition is VECIN, VECCALC, or VECOUT. The start address of the LocalTensor must be 32-byte aligned. |
dstIndex |
Output |
Destination operand. The type is LocalTensor, and the supported TPosition is VECIN, VECCALC, or VECOUT. The start address of the LocalTensor must be 32-byte aligned. This source operand is fixed at the uint32_t data type. |
sorted |
Input |
Source operand. The type is LocalTensor, and the supported TPosition is VECIN, VECCALC, or VECOUT. The start address of the LocalTensor must be 32-byte aligned. The source operand must have the same data type as the destination operand. |
repeatTime |
Input |
Number of iteration repeats. The value is of the int32_t type. For the Value range: repeatTime ∈ [0, 255] |
Returns
None
Constraints
- For details about the operand address alignment requirements, see General Address Alignment Restrictions.
Example
For details, see the examples in MrgSort.