45 #ifndef TEUCHOS_COMPOBJECT_HPP 46 #define TEUCHOS_COMPOBJECT_HPP 85 void setFlopCounter(
const Flops &FlopCounter) {flopCounter_= (
Flops *) &FlopCounter;
return;}
100 void resetFlops()
const {
if (flopCounter_!=0) flopCounter_->
resetFlops();
return;}
104 double getFlops()
const {
if (flopCounter_!=0)
return(flopCounter_->flops());
else return(0.0);}
109 void updateFlops(
int addflops)
const {
if (flopCounter_!=0) flopCounter_->updateFlops(addflops);
return;}
113 void updateFlops(
long int addflops)
const {
if (flopCounter_!=0) flopCounter_->updateFlops(addflops);
return;}
116 void updateFlops(
double addflops)
const {
if (flopCounter_!=0) flopCounter_->updateFlops(addflops);
return;}
119 void updateFlops(
float addflops)
const {
if (flopCounter_!=0) flopCounter_->updateFlops(addflops);
return;}
132 #endif // end of TEUCHOS_COMPOBJECT_HPP Flops * getFlopCounter() const
Get the pointer to the Teuchos::Flops() object associated with this object, returns 0 if none.
double getFlops() const
Returns the number of floating point operations with this multi-std::vector.
void setFlopCounter(const CompObject &compObject)
Set the internal Teuchos::Flops() pointer to the flop counter of another Teuchos::CompObject.
void unsetFlopCounter()
Set the internal Teuchos::Flops() pointer to 0 (no flops counted).
Functionality and data that is common to all computational classes.
void resetFlops()
Resets the number of floating point operations to zero for this multi-std::vector.
void updateFlops(double addflops) const
Increment Flop count for this object.
Object for providing basic support and consistent interfaces for counting/reporting floating-point op...
void updateFlops(float addflops) const
Increment Flop count for this object.
The Teuchos namespace contains all of the classes, structs and enums used by Teuchos,...
void updateFlops(long int addflops) const
Increment Flop count for this object.
The Teuchos Floating Point Operations Class.