PetscLogGpuFlops#

Log how many flops are performed in a calculation on the device

Synopsis#

Input Parameter#

  • flops - the number of flops

Notes#

To limit the chance of integer overflow when multiplying by a constant, represent the constant as a double, not an integer. Use PetscLogFlops(4.0n) not PetscLogFlops(4n)

The values are also added to the total flop count for the MPI rank that is set with PetscLogFlops(); hence the number of flops just on the CPU would be the value from set from PetscLogFlops() minus the value set from PetscLogGpuFlops()

See Also#

Profiling, PetscLogView(), PetscLogFlops(), PetscLogGpuTimeBegin(), PetscLogGpuTimeEnd()

Level#

intermediate

Location#

include/petsclog.h


Index of all Profiling routines
Table of Contents for all manual pages
Index of all manual pages