获取当前硬件平台Vector的核数。
uint32_t GetCoreNumAiv(void) const;
参数 |
输入/输出 |
说明 |
---|---|---|
- |
- |
- |
返回Vector Core的核数。
无
ge::graphStatus TilingXXX(gert::TilingContext* context) { auto ascendcPlatform = platform_ascendc::PlatformAscendC(context->GetPlatformInfo()); auto aicNum = ascendcPlatform.GetCoreNumAic(); auto aivNum = ascendcPlatform.GetCoreNumAiv(); // ...按照aivNum切分 context->SetBlockDim(ascendcPlatform.CalcTschBlockDim(aivNum, aicNum, aivNum)); return ret; }