API Change Description

To optimize API naming and make it clearer and easier to understand, some API names have been changed in the current version compared with CANN8.5.0 and earlier versions. For details, see the following table.

Original API NameNew API NameRemarks
ScalarGetCountOfValueGetBitCountNone
ScalarCountLeadingZeroCountLeadingZeroNone
ScalarGetSFFValueGetSFFValueNone
ScalarCastCast (float to half, int32_t)None
ToBfloat16Cast (float to bfloat16_t)None
ToFloatCast (multi-type to float)The return value type of one overloaded version is changed from float to template U, where U = float.
FusedMulAddReluMulAddReluNone
CastDeqCastDequantNone
CompareScalarComparesNone
GetAccValGetReduceRepeatSumSprNone
GetReduceMaxMinCountGetReduceRepeatMaxMinSprNone
SetAtomicNoneDisableDmaAtomicNone
InitConstValueFillNone
SetMMLayoutTransformSetMMRowMajor/SetMMColumnMajorSetMMLayoutTransform(true) corresponds to SetMMRowMajor().
SetMMLayoutTransform(false) corresponds to SetMMColumnMajor().
SetHF32ModeSetHF32ModeThe API name remains unchanged, and the parameter type is changed from bool to the HF32Mode enum.
SetHF32TransModeSetHF32TransModeThe API name remains unchanged, and the parameter type is changed from bool to the HF32TransMode enum.
CalcTschBlockDimCalcTschNumBlocksNone

The APIs in the following table were modified in 9.1.0. Compared with CANN9.0.0 and earlier versions, some API names have been changed. For details, see the following table.

Original API NameNew API NameRemarks
BlockReduceSum / BlockReduceMax / BlockReduceMinReduceDataBlock•Provides a unified DataBlock reduction operation API, distinguishing different reduction operations through template parameters.
•Adjusts the parameter order of mask and repeatTime.
WholeReduceSum / WholeReduceMax / WholeReduceMinReduceRepeatProvides a unified Repeat reduction operation API, distinguishing different reduction operations through template parameters.
RepeatReduceSumReduceRepeat•Provides a unified Repeat reduction operation API, distinguishing different reduction operations through template parameters.
•Adjusts the parameter order of mask and repeatTime.
•Removes the invalid parameter dstBlkStride.
PairReduceSumReducePairElem•Provides a unified Pair element reduction operation API, distinguishing different reduction operations through template parameters.
•Adjusts the parameter order of mask and repeatTime.