LCOV - code coverage report
Current view: top level - src/api_check/inc - kernel_vec_reduce_check.h (source / functions) Coverage Total Hit
Test: coverage.info_filtered Lines: 100.0 % 2 2
Test Date: 2026-07-27 14:41:20 Functions: 66.7 % 3 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              : /*!
      12              :  * \file kernel_vec_reduce_check.h
      13              :  * \brief
      14              :  */
      15              : 
      16              : #ifndef ASCENDC_VEC_REDUCE_CHECK_H
      17              : #define ASCENDC_VEC_REDUCE_CHECK_H
      18              : #include "kernel_base_check.h"
      19              : 
      20              : namespace AscendC {
      21              : namespace check {
      22              : 
      23              : class TikcppVecReduceCheck : public TikcppBaseCheck {
      24              : public:
      25           44 :     TikcppVecReduceCheck(const std::string& name, VecReduceApiParams& param) : TikcppBaseCheck(name), param_(param) {}
      26           44 :     ~TikcppVecReduceCheck() override = default;
      27              :     uint32_t AlignStartPos(const uint32_t startPos, const uint32_t byteLen) const;
      28              :     bool CheckAllDtypeBytes(const std::string& errMsg);
      29              :     void ReduceBodyCal(const std::vector<uint32_t>& paramsArray, uint32_t& outputCount, uint32_t& nextStartPos) const;
      30              :     bool CheckCheckWorkSize(const std::string& errMsg, const uint64_t needElements, const uint32_t byteLen);
      31              :     bool CheckWorkTensorOffset(const std::string& errMsg);
      32              :     bool CheckWorkTensorSizeEqual(const std::string& errMsg);
      33              :     bool CheckDstTensorSizeRange(const std::string& errMsg);
      34              :     bool CheckAllLowLevel(std::vector<uint64_t> maskArray);
      35              :     bool CheckAllHighLevel();
      36              :     bool CheckAllHighLevelMode2();
      37              :     bool CheckAddrAlign();
      38              :     bool CommonCheck();
      39              : 
      40              : public:
      41              :     VecReduceApiParams& param_;
      42              : };
      43              : } // namespace check
      44              : } // namespace AscendC
      45              : #endif
        

Generated by: LCOV version 2.0-1