Loading...
Searching...
No Matches
gpr::linalg::KernelWall Class Reference

#include <gpr/linalg/TeamFactor.h>

Public Types

enum class  Kind { Factor , Solve }

Public Member Functions

 KernelWall (Kind kind) noexcept
 ~KernelWall ()
 KernelWall (const KernelWall &)=delete
KernelWall & operator= (const KernelWall &)=delete

Detailed Description

Adds the wall of its scope to the factor or the solve total. A scope opened inside another one on the same thread adds nothing, so a distributed factor whose tiles call another timed kernel counts once.

Definition at line 30 of file TeamFactor.h.

Member Enumeration Documentation

◆ Kind

enum class gpr::linalg::KernelWall::Kind
strong
Enumerator
Factor 
Solve 

Definition at line 32 of file TeamFactor.h.

32{ Factor, Solve };

Constructor & Destructor Documentation

◆ KernelWall() [1/2]

gpr::linalg::KernelWall::KernelWall ( Kind kind)
explicitnoexcept

Definition at line 122 of file TeamFactor.cpp.

123 : kind_(kind), outermost_(wallDepth()++ == 0), start_ns_(nowNanoseconds())
124{
125}

◆ ~KernelWall()

gpr::linalg::KernelWall::~KernelWall ( )

Definition at line 127 of file TeamFactor.cpp.

128{
129 --wallDepth();
130 if (!outermost_) return;
131 const double seconds =
132 1e-9 * static_cast<double>(nowNanoseconds() - start_ns_);
133 addWall(kind_ == Kind::Factor ? factorWallSeconds() : solveWallSeconds(),
134 seconds);
135}

◆ KernelWall() [2/2]

gpr::linalg::KernelWall::KernelWall ( const KernelWall & )
delete

Member Function Documentation

◆ operator=()

KernelWall & gpr::linalg::KernelWall::operator= ( const KernelWall & )
delete

The documentation for this class was generated from the following files: