asc_transpose
产 品 支 持 情 况
| 产 品 | 是 否 支 持 |
|---|---|
| √ | |
| √ | |
| √ |
功 能 说 明
用 于 实 现16*16的 二 维 矩 阵 数 据 块 转 置。
函 数 原 型
C++
__aicore__ inline void asc_transpose(__ubuf__ int16_t* dst, __ubuf__ int16_t* src)
__aicore__ inline void asc_transpose(__ubuf__ uint16_t* dst, __ubuf__ uint16_t* src)
- 同 步 计 算 C++
__aicore__ inline void asc_transpose_sync(__ubuf__ int16_t* dst, __ubuf__ int16_t* src) __aicore__ inline void asc_transpose_sync(__ubuf__ uint16_t* dst, __ubuf__ uint16_t* src)
参 数 说 明
| 参 数 名 | 输 入/输 出 | 描 述 |
|---|---|---|
| dst | 输 出 | 目 的 操 作 数(矢 量)的 起 始 地 址。 |
| src | 输 入 | 源 操 作 数(矢 量)的 起 始 地 址。 |
返 回 值 说 明
无
流 水 类 型
PIPE_V
约 束 说 明
- 操 作 数 地 址 重 叠 约 束 请 参 考通 用 地 址 重 叠 约 束。
- dst、src的 起 始 地 址 需 要32字 节 对 齐。
调 用 示 例
C++
// total_length指 参 与 计 算 的 数 据 总 长 度
constexpr int total_length = 256;
__ubuf__ int16_t dst[total_length];
__ubuf__ int16_t src[total_length];
// dst指 目 的 操 作 数 的 地 址
asc_transpose(dst, src);