LCOV - code coverage report
Current view: top level - legacy/ascend950/unified_platform/resource/notify/aicpu - notify_lite.cc (source / functions) Coverage Total Hit
Test: coverage.info Lines: 100.0 % 12 12
Test Date: 2026-08-04 10:52:23 Functions: 100.0 % 4 4

            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              : #include "notify_lite.h"
      11              : #include "binary_stream.h"
      12              : #include "string_util.h"
      13              : #include "log.h"
      14              : namespace Hccl {
      15              : 
      16           93 : NotifyLite::NotifyLite(std::vector<char> &uniqueId)
      17              : {
      18           93 :     BinaryStream binaryStream(uniqueId);
      19           93 :     binaryStream >> notifyId;
      20           93 :     binaryStream >> devPhyId;
      21          267 :     HCCL_INFO("NotifyLite::NotifyLite:%s", Describe().c_str());
      22           93 : }
      23              : 
      24           30 : u32 NotifyLite::GetId() const
      25              : {
      26           30 :     return notifyId;
      27              : }
      28              : 
      29            8 : u32 NotifyLite::GetDevPhyId() const
      30              : {
      31            8 :     return devPhyId;
      32              : }
      33              : 
      34          177 : std::string NotifyLite::Describe() const
      35              : {
      36          177 :     return StringFormat("NotifyLite[notifyId=%u, devPhyId=%u]", notifyId, devPhyId);
      37              : }
      38              : 
      39              : } // namespace Hccl
        

Generated by: LCOV version 2.0-1