asc_set_copy_pad_val
产 品 支 持 情 况
| 产 品 | 是 否 支 持 |
|---|---|
| √ | |
| √ | |
| √ |
功 能 说 明
和asc_copy_gm2ub_align或asc_copy_ub2gm_align接 口 配 合 使 用,设 置 连 续 搬 运 数 据 块 左 右 两 侧 需 要 填 补 的 数 据 值。
对 于Ascend 950PR/Ascend 950DT产 品:
- 该 接 口 仅 对asc_copy_gm2ub_align接 口 有 效。
- fp8_e8m0_t、fp8_e5m2_t、fp8_e4m3fn_t、fp4x2_e2m1_t、fp4x2_e1m2_t、hifloat8_t类 型 的 数 据 需 转 换 成int8_t类 型 后 再 调 用 本 接 口。
函 数 原 型
C++
__aicore__ inline void asc_set_copy_pad_val(int8_t pad_value)
__aicore__ inline void asc_set_copy_pad_val(uint8_t pad_value)
__aicore__ inline void asc_set_copy_pad_val(int16_t pad_value)
__aicore__ inline void asc_set_copy_pad_val(uint16_t pad_value)
__aicore__ inline void asc_set_copy_pad_val(half pad_value)
__aicore__ inline void asc_set_copy_pad_val(bfloat16_t pad_value)
__aicore__ inline void asc_set_copy_pad_val(int32_t pad_value)
__aicore__ inline void asc_set_copy_pad_val(uint32_t pad_value)
__aicore__ inline void asc_set_copy_pad_val(float pad_value)
参 数 说 明
| 参 数 名 | 输 入/输 出 | 描 述 |
|---|---|---|
| pad_value | 输 入 | 需 要 填 补 的 数 据 值。 |
返 回 值 说 明
无
流 水 类 型
PIPE_S
约 束 说 明
无
调 用 示 例
C++
// 源 操 作 数 非 对 齐,需 要 填 补 数 据
asc_set_copy_pad_val(0);
asc_copy_gm2ub_align(dst, src, 2, 48 * sizeof(int8_t), 0, 0, true, 0, 0, 0);