Runtime 部分 ERROR 日志仅输出枚举的原始数值。定位问题时需要额外查询枚举定义,无法直接从日志识别对应的枚举语义,影响故障分析效率。
涉及 AICPU Schedule、AICPU Sharder、Queue Schedule 和 TSD 等模块中的枚举日志。
cann/runtime
对于能够获得有效名称的枚举,ERROR 日志输出 枚举名称(原始值);对于明确非法且无法获得有效名称的输入,仅保留原始数值。枚举名称转换接口使用 std::string,且不改变业务流程、返回值和错误处理逻辑。
枚举名称(原始值)
std::string
整改前日志形式示例:
query mode[3] is invalid
期望日志形式示例:
query mode[DGW_QUERY_MODE_GROUP(3)] is invalid
对应修复 PR:https://gitcode.com/cann/runtime/merge_requests/4680
/assign
Describe the current behavior / 问题描述
Runtime 部分 ERROR 日志仅输出枚举的原始数值。定位问题时需要额外查询枚举定义,无法直接从日志识别对应的枚举语义,影响故障分析效率。
涉及 AICPU Schedule、AICPU Sharder、Queue Schedule 和 TSD 等模块中的枚举日志。
Environment / 环境信息
cann/runtimeSteps to reproduce the issue / 重现步骤
Describe the expected behavior / 预期结果
对于能够获得有效名称的枚举,ERROR 日志输出
枚举名称(原始值);对于明确非法且无法获得有效名称的输入,仅保留原始数值。枚举名称转换接口使用std::string,且不改变业务流程、返回值和错误处理逻辑。Related log / screenshot / 日志 / 截图
整改前日志形式示例:
期望日志形式示例:
Special notes for this issue/备注
对应修复 PR:https://gitcode.com/cann/runtime/merge_requests/4680