LCOV - code coverage report
Current view: top level - legacy/ascend950/framework/resource_manager/notify/aicpu - host_device_sync_notify_lite_mgr.cc (source / functions) Coverage Total Hit
Test: coverage.info Lines: 100.0 % 13 13
Test Date: 2026-08-18 17:47:01 Functions: 100.0 % 3 3

            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 "host_device_sync_notify_lite_mgr.h"
      12              : #include "binary_stream.h"
      13              : 
      14              : namespace Hccl {
      15              : 
      16            5 : NotifyLite* HostDeviceSyncNotifyLiteMgr::GetDeviceWaitNotify() { return notifys[0].get(); }
      17              : 
      18            5 : NotifyLite* HostDeviceSyncNotifyLiteMgr::GetHostWaitNotify() { return notifys[1].get(); }
      19              : 
      20            1 : void HostDeviceSyncNotifyLiteMgr::ParsePackedData(std::vector<char>& data)
      21              : {
      22            1 :     BinaryStream binaryStream(data);
      23              : 
      24            1 :     std::vector<char> uniqueId0;
      25            1 :     std::vector<char> uniqueId1;
      26            1 :     binaryStream >> uniqueId0;
      27            1 :     binaryStream >> uniqueId1;
      28              : 
      29            1 :     if (!isReady) {
      30            1 :         notifys[0] = std::make_unique<NotifyLite>(uniqueId0);
      31            1 :         notifys[1] = std::make_unique<NotifyLite>(uniqueId1);
      32            1 :         isReady = true;
      33              :     }
      34            1 : }
      35              : 
      36              : } // namespace Hccl
        

Generated by: LCOV version 2.0-1