MCPcopy Create free account
hub / github.com/clMathLibraries/clSPARSE / Reset

Method Reset

src/clsparseTimer/clsparseTimer-host.cpp:139–157  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

137}
138
139void
140clsparseHostTimer::Reset( )
141{
142 if( nEvents == 0 || nSamples == 0 )
143 throw std::runtime_error( "StatisticalTimer::Reserve( ) was not called before Reset( )" );
144
145 clkStart.clear( );
146 clkTicks.clear( );
147
148 clkStart.resize( nEvents );
149 clkTicks.resize( nEvents );
150
151 for( cl_uint i = 0; i < nEvents; ++i )
152 {
153 clkTicks.at( i ).reserve( nSamples );
154 }
155
156 return;
157}
158
159// The caller can pre-allocate memory, to improve performance.
160// nEvents is an approximate value for how many seperate events the caller will think

Callers

nothing calls this directly

Calls 3

resizeMethod · 0.80
atMethod · 0.80
clearMethod · 0.45

Tested by

no test coverage detected