File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -151,10 +151,7 @@ struct state
151151 // / Control the stopping criterion for the measurement loop.
152152 // / @{
153153 [[nodiscard]] const std::string &get_stopping_criterion () const { return m_stopping_criterion; }
154- void set_stopping_criterion (std::string criterion)
155- {
156- m_stopping_criterion = std::move (criterion);
157- }
154+ void set_stopping_criterion (std::string criterion);
158155 // / @}
159156
160157 // / If true, the benchmark is only run once, skipping all warmup runs and only
Original file line number Diff line number Diff line change 1616 * limitations under the License.
1717 */
1818#include < nvbench/benchmark_base.cuh>
19+ #include < nvbench/criterion_manager.cuh>
1920#include < nvbench/detail/throw.cuh>
2021#include < nvbench/state.cuh>
2122#include < nvbench/types.cuh>
@@ -300,4 +301,10 @@ void state::add_buffer_size(std::size_t num_bytes,
300301 }
301302}
302303
304+ void state::set_stopping_criterion (std::string criterion)
305+ {
306+ m_stopping_criterion = std::move (criterion);
307+ m_criterion_params = criterion_manager::get ().get_criterion (m_stopping_criterion).get_params ();
308+ }
309+
303310} // namespace nvbench
You can’t perform that action at this time.
0 commit comments