LCOV - code coverage report
Current view: top level - legacy/ascend950/unified_platform/ccu/dfx - ccu_dfx.cpp (source / functions) Coverage Total Hit
Test: coverage.info Lines: 33.3 % 6 2
Test Date: 2026-08-04 10:52:23 Functions: 50.0 % 4 2

            Line data    Source code
       1              : /**
       2              :  * Copyright (c) 2025 Huawei Technologies Co., Ltd.
       3              :  * This program is free software, you can redistribute it and/or modify it under the terms and conditions of
       4              :  * CANN Open Software License Agreement Version 2.0 (the "License").
       5              :  * Please refer to the License for details. You may not use this file except in compliance with the License.
       6              :  * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR IMPLIED,
       7              :  * INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE.
       8              :  * See LICENSE in the root of the software repository for the full text of the License.
       9              :  */
      10              : 
      11              : #include "ccu_dfx.h"
      12              : 
      13              : #include "hccl_common_v2.h"
      14              : #include "exception_util.h"
      15              : #include "ccu_error_handler.h"
      16              : 
      17              : namespace Hccl {
      18              : using namespace std;
      19              : 
      20            2 : HcclResult GetCcuErrorMsg(s32 deviceId, uint16_t status, const ParaCcu &ccuTaskParam, std::vector<CcuErrorInfo> &errorInfo)
      21              : {
      22           74 :     TRY_CATCH_RETURN(
      23              :         HCCL_RUN_INFO(
      24              :             "[CcuDfx]GetCcuErrorMsg: deviceId[%d], dieId[%u], missionId[%u], execMissionId[%u], executeId[%llu].",
      25              :             deviceId, static_cast<u32>(ccuTaskParam.dieId), static_cast<u32>(ccuTaskParam.missionId),
      26              :             static_cast<u32>(ccuTaskParam.execMissionId), ccuTaskParam.executeId);
      27              : 
      28              :         // 入参校验
      29              :         CHK_PRT_RET((deviceId < 0 || static_cast<u32>(deviceId) >= MAX_MODULE_DEVICE_NUM),
      30              :                     HCCL_ERROR("[CcuDfx][GetCcuErrorMsg]deviceId[%d] error, MAX_MODULE_DEVICE_NUM[%u].", 
      31              :                                 deviceId, MAX_MODULE_DEVICE_NUM), HcclResult::HCCL_E_PARA);
      32              : 
      33              :         CcuErrorHandler::GetCcuErrorMsg(deviceId, status, ccuTaskParam, errorInfo);
      34              :     );
      35            0 :     return HcclResult::HCCL_SUCCESS;
      36              : }
      37              : 
      38            0 : HcclResult GetCcuJettys(s32 deviceLogicId, const ParaCcu& ccuTaskParam, std::vector<CcuJetty *>& ccuJettys)
      39              : {
      40            0 :     TRY_CATCH_RETURN(
      41              :         CcuErrorHandler::GetCcuJettys(deviceLogicId, ccuTaskParam, ccuJettys);
      42              :     );
      43            0 :     return HcclResult::HCCL_SUCCESS;
      44              : }
      45              : 
      46              : } // namespace Hccl
        

Generated by: LCOV version 2.0-1