Logger Class Reference

Logger Class Reference#

Reference API: gko::log::Logger Class Reference
Reference API
Inheritance diagram for gko::log::Logger:
[legend]

Public Types

using mask_type = gko::uint64
 

Public Member Functions

template<size_type Event, typename... Params>
std::enable_if_t< Event==0 &&(0< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==1 &&(1< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==2 &&(2< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==3 &&(3< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==4 &&(4< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==5 &&(5< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==6 &&(6< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==7 &&(7< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==8 &&(8< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==9 &&(9< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==10 &&(10< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==11 &&(11< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==12 &&(12< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==13 &&(13< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==14 &&(14< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==15 &&(15< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==16 &&(16< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==17 &&(17< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==18 &&(18< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==19 &&(19< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==20 &&(20< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==21 &&(21< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==22 &&(22< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==23 &&(23< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==24 &&(24< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==25 &&(25< event_count_max)> on (Params &&... params) const
 
template<size_type Event, typename... Params>
std::enable_if_t< Event==26 &&(26< event_count_max)> on (Params &&... params) const
 
virtual bool needs_propagation () const
 

Static Public Attributes

static constexpr size_type event_count_max = sizeof(mask_type) * byte_size
 
static constexpr mask_type all_events_mask = ~mask_type{0}
 
static constexpr size_type allocation_started { 0 }
 
static constexpr mask_type allocation_started_mask {mask_type{1} << 0 }
 
static constexpr size_type allocation_completed { 1 }
 
static constexpr mask_type allocation_completed_mask {mask_type{1} << 1 }
 
static constexpr size_type free_started { 2 }
 
static constexpr mask_type free_started_mask {mask_type{1} << 2 }
 
static constexpr size_type free_completed { 3 }
 
static constexpr mask_type free_completed_mask {mask_type{1} << 3 }
 
static constexpr size_type copy_started { 4 }
 
static constexpr mask_type copy_started_mask {mask_type{1} << 4 }
 
static constexpr size_type copy_completed { 5 }
 
static constexpr mask_type copy_completed_mask {mask_type{1} << 5 }
 
static constexpr size_type operation_launched { 6 }
 
static constexpr mask_type operation_launched_mask {mask_type{1} << 6 }
 
static constexpr size_type operation_completed { 7 }
 
static constexpr mask_type operation_completed_mask {mask_type{1} << 7 }
 
static constexpr size_type polymorphic_object_create_started { 8 }
 
static constexpr mask_type polymorphic_object_create_started_mask {mask_type{1} << 8 }
 
static constexpr size_type polymorphic_object_create_completed { 9 }
 
static constexpr mask_type polymorphic_object_create_completed_mask {mask_type{1} << 9 }
 
static constexpr size_type polymorphic_object_copy_started { 10 }
 
static constexpr mask_type polymorphic_object_copy_started_mask {mask_type{1} << 10 }
 
static constexpr size_type polymorphic_object_copy_completed { 11 }
 
static constexpr mask_type polymorphic_object_copy_completed_mask {mask_type{1} << 11 }
 
static constexpr size_type polymorphic_object_deleted { 12 }
 
static constexpr mask_type polymorphic_object_deleted_mask {mask_type{1} << 12 }
 
static constexpr size_type linop_apply_started { 13 }
 
static constexpr mask_type linop_apply_started_mask {mask_type{1} << 13 }
 
static constexpr size_type linop_apply_completed { 14 }
 
static constexpr mask_type linop_apply_completed_mask {mask_type{1} << 14 }
 
static constexpr size_type linop_advanced_apply_started { 15 }
 
static constexpr mask_type linop_advanced_apply_started_mask {mask_type{1} << 15 }
 
static constexpr size_type linop_advanced_apply_completed { 16 }
 
static constexpr mask_type linop_advanced_apply_completed_mask {mask_type{1} << 16 }
 
static constexpr size_type linop_factory_generate_started { 17 }
 
static constexpr mask_type linop_factory_generate_started_mask {mask_type{1} << 17 }
 
static constexpr size_type linop_factory_generate_completed { 18 }
 
static constexpr mask_type linop_factory_generate_completed_mask {mask_type{1} << 18 }
 
static constexpr size_type criterion_check_started { 19 }
 
static constexpr mask_type criterion_check_started_mask {mask_type{1} << 19 }
 
static constexpr size_type criterion_check_completed { 20 }
 
static constexpr mask_type criterion_check_completed_mask {mask_type{1} << 20 }
 
static constexpr size_type iteration_complete {21}
 
static constexpr mask_type iteration_complete_mask {mask_type{1} << 21}
 
static constexpr size_type polymorphic_object_move_started { 22 }
 
static constexpr mask_type polymorphic_object_move_started_mask {mask_type{1} << 22 }
 
static constexpr size_type polymorphic_object_move_completed { 23 }
 
static constexpr mask_type polymorphic_object_move_completed_mask {mask_type{1} << 23 }
 
static constexpr size_type batch_linop_factory_generate_started { 24 }
 
static constexpr mask_type batch_linop_factory_generate_started_mask {mask_type{1} << 24 }
 
static constexpr size_type batch_linop_factory_generate_completed { 25 }
 
static constexpr mask_type batch_linop_factory_generate_completed_mask {mask_type{1} << 25 }
 
static constexpr size_type batch_solver_completed {26}
 
static constexpr mask_type batch_solver_completed_mask {mask_type{1} << 26}
 
static constexpr mask_type executor_events_mask
 
static constexpr mask_type operation_events_mask
 
static constexpr mask_type polymorphic_object_events_mask
 
static constexpr mask_type linop_events_mask
 
static constexpr mask_type linop_factory_events_mask
 
static constexpr mask_type batch_linop_factory_events_mask
 
static constexpr mask_type criterion_events_mask
 

Protected Member Functions

virtual void on_allocation_started (const Executor *exec, const size_type &num_bytes) const
 
virtual void on_allocation_completed (const Executor *exec, const size_type &num_bytes, const uintptr &location) const
 
virtual void on_free_started (const Executor *exec, const uintptr &location) const
 
virtual void on_free_completed (const Executor *exec, const uintptr &location) const
 
virtual void on_copy_started (const Executor *exec_from, const Executor *exec_to, const uintptr &loc_from, const uintptr &loc_to, const size_type &num_bytes) const
 
virtual void on_copy_completed (const Executor *exec_from, const Executor *exec_to, const uintptr &loc_from, const uintptr &loc_to, const size_type &num_bytes) const
 
virtual void on_operation_launched (const Executor *exec, const Operation *op) const
 
virtual void on_operation_completed (const Executor *exec, const Operation *op) const
 
virtual void on_polymorphic_object_create_started (const Executor *exec, const PolymorphicObject *po) const
 
virtual void on_polymorphic_object_create_completed (const Executor *exec, const PolymorphicObject *input, const PolymorphicObject *output) const
 
virtual void on_polymorphic_object_copy_started (const Executor *exec, const PolymorphicObject *input, const PolymorphicObject *output) const
 
virtual void on_polymorphic_object_copy_completed (const Executor *exec, const PolymorphicObject *input, const PolymorphicObject *output) const
 
virtual void on_polymorphic_object_deleted (const Executor *exec, const PolymorphicObject *po) const
 
virtual void on_linop_apply_started (const LinOp *A, const LinOp *b, const LinOp *x) const
 
virtual void on_linop_apply_completed (const LinOp *A, const LinOp *b, const LinOp *x) const
 
virtual void on_linop_advanced_apply_started (const LinOp *A, const LinOp *alpha, const LinOp *b, const LinOp *beta, const LinOp *x) const
 
virtual void on_linop_advanced_apply_completed (const LinOp *A, const LinOp *alpha, const LinOp *b, const LinOp *beta, const LinOp *x) const
 
virtual void on_linop_factory_generate_started (const LinOpFactory *factory, const LinOp *input) const
 
virtual void on_linop_factory_generate_completed (const LinOpFactory *factory, const LinOp *input, const LinOp *output) const
 
virtual void on_criterion_check_started (const stop::Criterion *criterion, const size_type &it, const LinOp *r, const LinOp *tau, const LinOp *x, const uint8 &stopping_id, const bool &set_finalized) const
 
virtual void on_criterion_check_completed (const stop::Criterion *criterion, const size_type &it, const LinOp *r, const LinOp *tau, const LinOp *x, const uint8 &stopping_id, const bool &set_finalized, const array< stopping_status > *status, const bool &one_changed, const bool &all_converged) const
 
virtual void on_criterion_check_completed (const stop::Criterion *criterion, const size_type &it, const LinOp *r, const LinOp *tau, const LinOp *implicit_tau_sq, const LinOp *x, const uint8 &stopping_id, const bool &set_finalized, const array< stopping_status > *status, const bool &one_changed, const bool &all_converged) const
 
virtual void on_iteration_complete (const LinOp *solver, const size_type &it, const LinOp *r, const LinOp *x=nullptr, const LinOp *tau=nullptr) const
 
virtual void on_iteration_complete (const LinOp *solver, const size_type &it, const LinOp *r, const LinOp *x, const LinOp *tau, const LinOp *implicit_tau_sq) const
 
virtual void on_iteration_complete (const LinOp *solver, const LinOp *b, const LinOp *x, const size_type &it, const LinOp *r, const LinOp *tau, const LinOp *implicit_tau_sq, const array< stopping_status > *status, bool stopped) const
 
virtual void on_polymorphic_object_move_started (const Executor *exec, const PolymorphicObject *input, const PolymorphicObject *output) const
 
virtual void on_polymorphic_object_move_completed (const Executor *exec, const PolymorphicObject *input, const PolymorphicObject *output) const
 
virtual void on_batch_linop_factory_generate_started (const batch::BatchLinOpFactory *factory, const batch::BatchLinOp *input) const
 
virtual void on_batch_linop_factory_generate_completed (const batch::BatchLinOpFactory *factory, const batch::BatchLinOp *input, const batch::BatchLinOp *output) const
 
virtual void on_batch_solver_completed (const array< int > &iters, const array< double > &residual_norms) const
 
virtual void on_batch_solver_completed (const array< int > &iters, const array< float > &residual_norms) const
 
virtual void on_batch_solver_completed (const array< int > &iters, const array< gko::half > &residual_norms) const
 
 Logger (std::shared_ptr< const gko::Executor > exec, const mask_type &enabled_events=all_events_mask)
 
 Logger (const mask_type &enabled_events=all_events_mask)
 

Constructor & Destructor Documentation

◆ Logger() [1/2]

gko::log::Logger::Logger ( std::shared_ptr< const gko::Executor exec,
const mask_type &  enabled_events = all_events_mask 
)
inlineexplicitprotected

Constructor for a Logger object.

Parameters
enabled_eventsthe events enabled for this Logger. These can be of the following form:
  1. all_event_mask which logs every event;
  2. an OR combination of masks, e.g. iteration_complete_mask|linop_apply_started_mask which activates both of these events;
  3. all events with exclusion through XOR, e.g. all_event_mask^linop_apply_started_mask which logs every event except linop's apply started event.

◆ Logger() [2/2]

gko::log::Logger::Logger ( const mask_type &  enabled_events = all_events_mask)
inlineexplicitprotected

Constructor for a Logger object.

Parameters
enabled_eventsthe events enabled for this Logger. These can be of the following form:
  1. all_event_mask which logs every event;
  2. an OR combination of masks, e.g. iteration_complete_mask|linop_apply_started_mask which activates both of these events;
  3. all events with exclusion through XOR, e.g. all_event_mask^linop_apply_started_mask which logs every event except linop's apply started event.

Member Function Documentation

◆ needs_propagation()

virtual bool gko::log::Logger::needs_propagation ( ) const
inlinevirtual

Returns true if this logger, when attached to an Executor, needs to be forwarded all events from objects on this executor.

Reimplemented in gko::log::ProfilerHook.

Referenced by gko::Executor::remove_logger().

◆ on_allocation_completed()

virtual void gko::log::Logger::on_allocation_completed ( const Executor exec,
const size_type num_bytes,
const uintptr location 
) const
inlineprotectedvirtual

Executor's allocation completed event.

Parameters
execthe executor used
num_bytesthe number of bytes allocated
locationthe address at which the data was allocated

Reimplemented in gko::log::Papi< ValueType >, gko::log::PerformanceHint, gko::log::Record, gko::log::Stream< ValueType >, loggers::StorageLogger, loggers::OperationLogger, and gko::log::ProfilerHook.

◆ on_allocation_started()

virtual void gko::log::Logger::on_allocation_started ( const Executor exec,
const size_type num_bytes 
) const
inlineprotectedvirtual

Executor's allocation started event.

Parameters
execthe executor used
num_bytesthe number of bytes to allocate

Reimplemented in gko::log::Papi< ValueType >, gko::log::Record, gko::log::Stream< ValueType >, loggers::OperationLogger, and gko::log::ProfilerHook.

◆ on_batch_linop_factory_generate_completed()

virtual void gko::log::Logger::on_batch_linop_factory_generate_completed ( const batch::BatchLinOpFactory factory,
const batch::BatchLinOp input,
const batch::BatchLinOp output 
) const
inlineprotectedvirtual

BatchLinOp Factory's generate completed event.

Parameters
factorythe factory used
inputthe BatchLinOp object used as input for the generation (usually a system matrix)
outputthe generated BatchLinOp object

◆ on_batch_linop_factory_generate_started()

virtual void gko::log::Logger::on_batch_linop_factory_generate_started ( const batch::BatchLinOpFactory factory,
const batch::BatchLinOp input 
) const
inlineprotectedvirtual

BatchLinOp Factory's generate started event.

Parameters
factorythe factory used
inputthe BatchLinOp object used as input for the generation (usually a system matrix)

◆ on_batch_solver_completed() [1/3]

virtual void gko::log::Logger::on_batch_solver_completed ( const array< int > &  iters,
const array< double > &  residual_norms 
) const
inlineprotectedvirtual

Batch solver's event that records the iteration count and the residual norm.

Parameters
itersthe array of iteration counts.
residual_normsthe array storing the residual norms.

◆ on_batch_solver_completed() [2/3]

virtual void gko::log::Logger::on_batch_solver_completed ( const array< int > &  iters,
const array< float > &  residual_norms 
) const
inlineprotectedvirtual

Batch solver's event that records the iteration count and the residual norm.

Parameters
itersthe array of iteration counts.
residual_normsthe array storing the residual norms.

◆ on_batch_solver_completed() [3/3]

virtual void gko::log::Logger::on_batch_solver_completed ( const array< int > &  iters,
const array< gko::half > &  residual_norms 
) const
inlineprotectedvirtual

Batch solver's event that records the iteration count and the residual norm.

Parameters
itersthe array of iteration counts.
residual_normsthe array storing the residual norms.

◆ on_copy_completed()

virtual void gko::log::Logger::on_copy_completed ( const Executor exec_from,
const Executor exec_to,
const uintptr loc_from,
const uintptr loc_to,
const size_type num_bytes 
) const
inlineprotectedvirtual

Executor's copy completed event.

Parameters
exec_fromthe executor copied from
exec_tothe executor copied to
loc_fromthe address at which the data was copied from
loc_tothe address at which the data was copied to
num_bytesthe number of bytes copied

Reimplemented in gko::log::Papi< ValueType >, gko::log::PerformanceHint, gko::log::Record, gko::log::Stream< ValueType >, loggers::OperationLogger, and gko::log::ProfilerHook.

◆ on_copy_started()

virtual void gko::log::Logger::on_copy_started ( const Executor exec_from,
const Executor exec_to,
const uintptr loc_from,
const uintptr loc_to,
const size_type num_bytes 
) const
inlineprotectedvirtual

Executor's copy started event.

Parameters
exec_fromthe executor to be copied from
exec_tothe executor to be copied to
loc_fromthe address at which the data will be copied from
loc_tothe address at which the data will be copied to
num_bytesthe number of bytes to be copied

Reimplemented in gko::log::Papi< ValueType >, gko::log::Record, gko::log::Stream< ValueType >, loggers::OperationLogger, and gko::log::ProfilerHook.

◆ on_criterion_check_completed() [1/2]

virtual void gko::log::Logger::on_criterion_check_completed ( const stop::Criterion criterion,
const size_type it,
const LinOp r,
const LinOp tau,
const LinOp implicit_tau_sq,
const LinOp x,
const uint8 stopping_id,
const bool &  set_finalized,
const array< stopping_status > *  status,
const bool &  one_changed,
const bool &  all_converged 
) const
inlineprotectedvirtual

stop::Criterion's check completed event. Parameters are the Criterion, the stoppingId, the finalized boolean, the stopping status, plus the output one_changed boolean and output all_converged boolean.

Parameters
criterionthe criterion used
itthe current iteration count
rthe residual
tauthe residual norm
implicit_tau_sqthe implicit residual norm squared
xthe solution
stopping_idthe id of the stopping criterion
set_finalizedwhether this finalizes the iteration
statusthe stopping status of the right hand sides
one_changedwhether at least one right hand side converged or not
all_convergedwhether all right hand sides are converged

Reimplemented in gko::log::Record, gko::log::Convergence< ValueType >, and gko::log::ProfilerHook.

References on_criterion_check_completed().

◆ on_criterion_check_completed() [2/2]

virtual void gko::log::Logger::on_criterion_check_completed ( const stop::Criterion criterion,
const size_type it,
const LinOp r,
const LinOp tau,
const LinOp x,
const uint8 stopping_id,
const bool &  set_finalized,
const array< stopping_status > *  status,
const bool &  one_changed,
const bool &  all_converged 
) const
inlineprotectedvirtual

stop::Criterion's check completed event. Parameters are the Criterion, the stoppingId, the finalized boolean, the stopping status, plus the output one_changed boolean and output all_converged boolean.

Parameters
criterionthe criterion used
itthe current iteration count
rthe residual
tauthe residual norm
xthe solution
stopping_idthe id of the stopping criterion
set_finalizedwhether this finalizes the iteration
statusthe stopping status of the right hand sides
one_changedwhether at least one right hand side converged or not
all_convergedwhether all right hand sides
Note
The on_criterion_check_completed function that this macro declares is deprecated. Please use the one with the additional implicit_tau_sq parameter as below.

Reimplemented in gko::log::Papi< ValueType >, gko::log::Record, gko::log::Stream< ValueType >, gko::log::Convergence< ValueType >, and gko::log::ProfilerHook.

Referenced by on_criterion_check_completed().

◆ on_criterion_check_started()

virtual void gko::log::Logger::on_criterion_check_started ( const stop::Criterion criterion,
const size_type it,
const LinOp r,
const LinOp tau,
const LinOp x,
const uint8 stopping_id,
const bool &  set_finalized 
) const
inlineprotectedvirtual

stop::Criterion's check started event.

Parameters
criterionthe criterion used
itthe current iteration count
rthe residual
tauthe residual norm
xthe solution
stopping_idthe id of the stopping criterion
set_finalizedwhether this finalizes the iteration

Reimplemented in gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_free_completed()

virtual void gko::log::Logger::on_free_completed ( const Executor exec,
const uintptr location 
) const
inlineprotectedvirtual

Executor's free completed event.

Parameters
execthe executor used
locationthe address at which the data was freed

Reimplemented in gko::log::Papi< ValueType >, gko::log::PerformanceHint, gko::log::Record, gko::log::Stream< ValueType >, loggers::StorageLogger, loggers::OperationLogger, and gko::log::ProfilerHook.

◆ on_free_started()

virtual void gko::log::Logger::on_free_started ( const Executor exec,
const uintptr location 
) const
inlineprotectedvirtual

Executor's free started event.

Parameters
execthe executor used
locationthe address at which the data will be freed

Reimplemented in gko::log::Papi< ValueType >, gko::log::Record, gko::log::Stream< ValueType >, loggers::OperationLogger, and gko::log::ProfilerHook.

◆ on_iteration_complete() [1/3]

virtual void gko::log::Logger::on_iteration_complete ( const LinOp solver,
const LinOp b,
const LinOp x,
const size_type it,
const LinOp r,
const LinOp tau,
const LinOp implicit_tau_sq,
const array< stopping_status > *  status,
bool  stopped 
) const
inlineprotectedvirtual

Register the iteration_complete event which logs every completed iterations.

Parameters
solverthe solver executing the iteration
bthe right-hand-side vector
xthe solution vector
itthe current iteration count
rthe residual (optional)
tauthe implicit residual norm squared (optional)
implicit_tau_sqthe residual norm (optional)
statusthe stopping status of the right hand sides (optional)
stoppedwhether all right hand sides have stopped (invalid if status is not provided)

Reimplemented in ResidualLogger< ValueType >, gko::log::Convergence< ValueType >, gko::log::Papi< ValueType >, gko::log::Stream< ValueType >, gko::log::ProfilerHook, and gko::log::Record.

References on_iteration_complete().

◆ on_iteration_complete() [2/3]

virtual void gko::log::Logger::on_iteration_complete ( const LinOp solver,
const size_type it,
const LinOp r,
const LinOp x,
const LinOp tau,
const LinOp implicit_tau_sq 
) const
inlineprotectedvirtual

Register the iteration_complete event which logs every completed iterations.

Parameters
itthe current iteration count
rthe residual
xthe solution vector (optional)
tauthe residual norm (optional)
implicit_tau_sqthe implicit residual norm squared (optional)
Warning
This on_iteration_complete function that this macro declares is deprecated. Please use the version with the stopping information.

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

References on_iteration_complete().

◆ on_iteration_complete() [3/3]

virtual void gko::log::Logger::on_iteration_complete ( const LinOp solver,
const size_type it,
const LinOp r,
const LinOp x = nullptr,
const LinOp tau = nullptr 
) const
inlineprotectedvirtual

Register the iteration_complete event which logs every completed iterations.

Parameters
itthe current iteration count
rthe residual
xthe solution vector (optional)
tauthe residual norm (optional)
Warning
This on_iteration_complete function that this macro declares is deprecated. Please use the version with the stopping information.

Reimplemented in loggers::ResidualLogger< ValueType >, gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

Referenced by on_iteration_complete(), and on_iteration_complete().

◆ on_linop_advanced_apply_completed()

virtual void gko::log::Logger::on_linop_advanced_apply_completed ( const LinOp A,
const LinOp alpha,
const LinOp b,
const LinOp beta,
const LinOp x 
) const
inlineprotectedvirtual

LinOp's advanced apply completed event.

Parameters
Athe system matrix
alphascaling of the result of op(b)
bthe input vector(s)
betascaling of the input x
xthe output vector(s)

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_linop_advanced_apply_started()

virtual void gko::log::Logger::on_linop_advanced_apply_started ( const LinOp A,
const LinOp alpha,
const LinOp b,
const LinOp beta,
const LinOp x 
) const
inlineprotectedvirtual

LinOp's advanced apply started event.

Parameters
Athe system matrix
alphascaling of the result of op(b)
bthe input vector(s)
betascaling of the input x
xthe output vector(s)

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_linop_apply_completed()

virtual void gko::log::Logger::on_linop_apply_completed ( const LinOp A,
const LinOp b,
const LinOp x 
) const
inlineprotectedvirtual

LinOp's apply completed event.

Parameters
Athe system matrix
bthe input vector(s)
xthe output vector(s)

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_linop_apply_started()

virtual void gko::log::Logger::on_linop_apply_started ( const LinOp A,
const LinOp b,
const LinOp x 
) const
inlineprotectedvirtual

LinOp's apply started event.

Parameters
Athe system matrix
bthe input vector(s)
xthe output vector(s)

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_linop_factory_generate_completed()

virtual void gko::log::Logger::on_linop_factory_generate_completed ( const LinOpFactory factory,
const LinOp input,
const LinOp output 
) const
inlineprotectedvirtual

LinOp Factory's generate completed event.

Parameters
factorythe factory used
inputthe LinOp object used as input for the generation (usually a system matrix)
outputthe generated LinOp object

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_linop_factory_generate_started()

virtual void gko::log::Logger::on_linop_factory_generate_started ( const LinOpFactory factory,
const LinOp input 
) const
inlineprotectedvirtual

LinOp Factory's generate started event.

Parameters
factorythe factory used
inputthe LinOp object used as input for the generation (usually a system matrix)

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_operation_completed()

virtual void gko::log::Logger::on_operation_completed ( const Executor exec,
const Operation op 
) const
inlineprotectedvirtual

Executor's operation completed event (method run).

Parameters
execthe executor used
opthe completed operation
Note
For the GPU, to be certain that the operation completed it is required to call synchronize. This burden falls on the logger. Most of the loggers will do lightweight logging, and therefore this operation for the GPU just notes that the Operation has been sent to the GPU.

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, gko::log::Stream< ValueType >, and loggers::OperationLogger.

◆ on_operation_launched()

virtual void gko::log::Logger::on_operation_launched ( const Executor exec,
const Operation op 
) const
inlineprotectedvirtual

Executor's operation launched event (method run).

Parameters
execthe executor used
opthe operation launched

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, gko::log::Stream< ValueType >, and loggers::OperationLogger.

◆ on_polymorphic_object_copy_completed()

virtual void gko::log::Logger::on_polymorphic_object_copy_completed ( const Executor exec,
const PolymorphicObject input,
const PolymorphicObject output 
) const
inlineprotectedvirtual

PolymorphicObject's copy completed event.

Parameters
execthe executor used
inputthe PolymorphicObject to be copied from
outputthe PolymorphicObject to be copied to

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_polymorphic_object_copy_started()

virtual void gko::log::Logger::on_polymorphic_object_copy_started ( const Executor exec,
const PolymorphicObject input,
const PolymorphicObject output 
) const
inlineprotectedvirtual

PolymorphicObject's copy started event.

Parameters
execthe executor used
inputthe PolymorphicObject to be copied from
outputthe PolymorphicObject to be copied to

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_polymorphic_object_create_completed()

virtual void gko::log::Logger::on_polymorphic_object_create_completed ( const Executor exec,
const PolymorphicObject input,
const PolymorphicObject output 
) const
inlineprotectedvirtual

PolymorphicObject's create completed event.

Parameters
execthe executor used
inputthe PolymorphicObject used as model for the creation
outputthe PolymorphicObject which was created

Reimplemented in gko::log::Papi< ValueType >, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_polymorphic_object_create_started()

virtual void gko::log::Logger::on_polymorphic_object_create_started ( const Executor exec,
const PolymorphicObject po 
) const
inlineprotectedvirtual

PolymorphicObject's create started event.

Parameters
execthe executor used
pothe PolymorphicObject to be created

Reimplemented in gko::log::Papi< ValueType >, gko::log::Stream< ValueType >, and gko::log::Record.

◆ on_polymorphic_object_deleted()

virtual void gko::log::Logger::on_polymorphic_object_deleted ( const Executor exec,
const PolymorphicObject po 
) const
inlineprotectedvirtual

PolymorphicObject's deleted event.

Parameters
execthe executor used
pothe PolymorphicObject to be deleted

Reimplemented in gko::log::Papi< ValueType >, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_polymorphic_object_move_completed()

virtual void gko::log::Logger::on_polymorphic_object_move_completed ( const Executor exec,
const PolymorphicObject input,
const PolymorphicObject output 
) const
inlineprotectedvirtual

PolymorphicObject's move completed event.

Parameters
execthe executor used
inputthe PolymorphicObject to be move from
outputthe PolymorphicObject to be move into

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

◆ on_polymorphic_object_move_started()

virtual void gko::log::Logger::on_polymorphic_object_move_started ( const Executor exec,
const PolymorphicObject input,
const PolymorphicObject output 
) const
inlineprotectedvirtual

PolymorphicObject's move started event.

Parameters
execthe executor used
inputthe PolymorphicObject to be move from
outputthe PolymorphicObject to be move into

Reimplemented in gko::log::Papi< ValueType >, gko::log::ProfilerHook, gko::log::Record, and gko::log::Stream< ValueType >.

Member Data Documentation

◆ all_events_mask

constexpr mask_type gko::log::Logger::all_events_mask = ~mask_type{0}
staticconstexpr

Bitset Mask which activates all events

◆ batch_linop_factory_events_mask

constexpr mask_type gko::log::Logger::batch_linop_factory_events_mask
staticconstexpr
Initial value:
=
batch_linop_factory_generate_started_mask |
batch_linop_factory_generate_completed_mask

Bitset Mask which activates all batch linop factory events

◆ criterion_events_mask

constexpr mask_type gko::log::Logger::criterion_events_mask
staticconstexpr
Initial value:
=
criterion_check_started_mask | criterion_check_completed_mask

Bitset Mask which activates all criterion events

◆ event_count_max

constexpr size_type gko::log::Logger::event_count_max = sizeof(mask_type) * byte_size
staticconstexpr

Maximum amount of events (bits) with the current implementation

◆ executor_events_mask

constexpr mask_type gko::log::Logger::executor_events_mask
staticconstexpr
Initial value:
=
allocation_started_mask | allocation_completed_mask |
free_started_mask | free_completed_mask | copy_started_mask |
copy_completed_mask

Bitset Mask which activates all executor events

◆ linop_events_mask

constexpr mask_type gko::log::Logger::linop_events_mask
staticconstexpr
Initial value:
=
linop_apply_started_mask | linop_apply_completed_mask |
linop_advanced_apply_started_mask | linop_advanced_apply_completed_mask

Bitset Mask which activates all linop events

◆ linop_factory_events_mask

constexpr mask_type gko::log::Logger::linop_factory_events_mask
staticconstexpr
Initial value:
=
linop_factory_generate_started_mask |
linop_factory_generate_completed_mask

Bitset Mask which activates all linop factory events

◆ operation_events_mask

constexpr mask_type gko::log::Logger::operation_events_mask
staticconstexpr
Initial value:
=
operation_launched_mask | operation_completed_mask

Bitset Mask which activates all operation events

◆ polymorphic_object_events_mask

constexpr mask_type gko::log::Logger::polymorphic_object_events_mask
staticconstexpr
Initial value:
=
polymorphic_object_create_started_mask |
polymorphic_object_create_completed_mask |
polymorphic_object_copy_started_mask |
polymorphic_object_copy_completed_mask |
polymorphic_object_move_started_mask |
polymorphic_object_move_completed_mask |
polymorphic_object_deleted_mask

Bitset Mask which activates all polymorphic object events


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