LCOV - code coverage report
Current view: top level - src/kokkos/bcs - KokkosADIntegratedBC.K (source / functions) Hit Total Coverage
Test: idaholab/moose framework: #32971 (54bef8) with base c6cf66 Lines: 25 30 83.3 %
Date: 2026-05-29 20:35:17 Functions: 5 6 83.3 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : //* This file is part of the MOOSE framework
       2             : //* https://www.mooseframework.org
       3             : //*
       4             : //* All rights reserved, see COPYRIGHT for full restrictions
       5             : //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
       6             : //*
       7             : //* Licensed under LGPL 2.1, please see LICENSE for details
       8             : //* https://www.gnu.org/licenses/lgpl-2.1.html
       9             : 
      10             : #include "KokkosADIntegratedBC.h"
      11             : 
      12             : namespace Moose::Kokkos
      13             : {
      14             : 
      15             : InputParameters
      16        4322 : ADIntegratedBC::validParams()
      17             : {
      18        4322 :   InputParameters params = IntegratedBCBase::validParams();
      19        4322 :   return params;
      20             : }
      21             : 
      22          63 : ADIntegratedBC::ADIntegratedBC(const InputParameters & parameters)
      23             :   : IntegratedBCBase(parameters, Moose::VarFieldType::VAR_FIELD_STANDARD),
      24             :     _test(),
      25             :     _grad_test(),
      26             :     _phi(),
      27             :     _grad_phi(),
      28          33 :     _u(_var),
      29          33 :     _grad_u(_var)
      30             : {
      31          63 :   addMooseVariableDependency(&_var);
      32          63 : }
      33             : 
      34             : void
      35         668 : ADIntegratedBC::computeResidual()
      36             : {
      37         668 :   _computing_residual = true;
      38         668 :   _computing_jacobian = false;
      39             : 
      40         668 :   dispatch();
      41         668 : }
      42             : 
      43             : void
      44           0 : ADIntegratedBC::computeJacobian()
      45             : {
      46           0 :   _computing_residual = false;
      47           0 :   _computing_jacobian = true;
      48             : 
      49           0 :   dispatch();
      50           0 : }
      51             : 
      52             : void
      53        1212 : ADIntegratedBC::computeResidualAndJacobian()
      54             : {
      55        1212 :   _computing_residual = true;
      56        1212 :   _computing_jacobian = true;
      57             : 
      58        1212 :   dispatch();
      59        1212 : }
      60             : 
      61             : void
      62        1880 : ADIntegratedBC::dispatch()
      63             : {
      64        1880 :   _thread.resize(_num_local_threads, numKokkosBoundarySides());
      65             : 
      66        1880 :   Policy policy(0, _thread.size());
      67             : 
      68        1880 :   if (!_residual_dispatcher)
      69          57 :     _residual_dispatcher = DispatcherRegistry::build<ResidualLoop>(this, type());
      70             : 
      71        1880 :   _residual_dispatcher->parallelFor(policy);
      72        1880 : }
      73             : 
      74             : } // namespace Moose::Kokkos

Generated by: LCOV version 1.14