LCOV - code coverage report
Current view: top level - src/postprocessors - ComputeGroupExecutionCount.C (source / functions) Hit Total Coverage
Test: idaholab/swift: #92 (25e020) with base b3cd84 Lines: 12 13 92.3 %
Date: 2025-09-10 17:10:32 Functions: 3 3 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : 
       2             : /**********************************************************************/
       3             : /*                    DO NOT MODIFY THIS HEADER                       */
       4             : /*             Swift, a Fourier spectral solver for MOOSE             */
       5             : /*                                                                    */
       6             : /*            Copyright 2024 Battelle Energy Alliance, LLC            */
       7             : /*                        ALL RIGHTS RESERVED                         */
       8             : /**********************************************************************/
       9             : 
      10             : #include "ComputeGroupExecutionCount.h"
      11             : #include "ComputeGroup.h"
      12             : #include "TensorProblem.h"
      13             : 
      14             : registerMooseObject("SwiftApp", ComputeGroupExecutionCount);
      15             : 
      16             : InputParameters
      17           8 : ComputeGroupExecutionCount::validParams()
      18             : {
      19           8 :   InputParameters params = GeneralPostprocessor::validParams();
      20           8 :   params.addClassDescription(
      21             :       "Return the number of computeBuffer() calls issued to the given compute group object.");
      22          16 :   params.addParam<TensorComputeName>(
      23             :       "compute_group", "root", "ComputeGroup TensorCompute object to get execution count from.");
      24           8 :   return params;
      25           0 : }
      26             : 
      27           4 : ComputeGroupExecutionCount::ComputeGroupExecutionCount(const InputParameters & parameters)
      28             :   : GeneralPostprocessor(parameters),
      29           8 :     _tensor_problem(TensorProblem::cast(this, this->_fe_problem)),
      30           4 :     _compute_group(
      31           8 :         _tensor_problem.getCompute<ComputeGroup>(getParam<TensorComputeName>("compute_group")))
      32             : {
      33           4 : }
      34             : 
      35             : PostprocessorValue
      36           8 : ComputeGroupExecutionCount::getValue() const
      37             : {
      38           8 :   return _compute_group.getComputeCount();
      39             : }

Generated by: LCOV version 1.14