mirror of
https://github.com/NVIDIA/nvbench.git
synced 2026-04-29 11:11:15 +00:00
Better throttle recovery delay
This commit is contained in:
@@ -140,13 +140,13 @@
|
|||||||
|
|
||||||
* `--throttle-threshold <value>`
|
* `--throttle-threshold <value>`
|
||||||
* Set the GPU throttle threshold as percentage of the peak clock rate.
|
* Set the GPU throttle threshold as percentage of the peak clock rate.
|
||||||
* Default is 0.75 (75%).
|
* Default is 75%.
|
||||||
* Applies to the most recent `--benchmark`, or all benchmarks if specified
|
* Applies to the most recent `--benchmark`, or all benchmarks if specified
|
||||||
before any `--benchmark` arguments.
|
before any `--benchmark` arguments.
|
||||||
|
|
||||||
* `--throttle-recovery-delay <value>`
|
* `--throttle-recovery-delay <value>`
|
||||||
* Set the GPU throttle recovery delay in seconds.
|
* Set the GPU throttle recovery delay in seconds.
|
||||||
* Default is 0.5 seconds.
|
* Default is 0.05 seconds.
|
||||||
* Applies to the most recent `--benchmark`, or all benchmarks if specified
|
* Applies to the most recent `--benchmark`, or all benchmarks if specified
|
||||||
before any `--benchmark` arguments.
|
before any `--benchmark` arguments.
|
||||||
|
|
||||||
|
|||||||
@@ -309,8 +309,8 @@ protected:
|
|||||||
nvbench::float64_t m_skip_time{-1.};
|
nvbench::float64_t m_skip_time{-1.};
|
||||||
nvbench::float64_t m_timeout{15.};
|
nvbench::float64_t m_timeout{15.};
|
||||||
|
|
||||||
nvbench::float32_t m_throttle_threshold{0.75f}; // [% of peak SM clock rate]
|
nvbench::float32_t m_throttle_threshold{0.75f}; // [% of peak SM clock rate]
|
||||||
nvbench::float32_t m_throttle_recovery_delay{0.0f}; // [seconds]
|
nvbench::float32_t m_throttle_recovery_delay{0.05f}; // [seconds]
|
||||||
bool m_discard_on_throttle{false};
|
bool m_discard_on_throttle{false};
|
||||||
|
|
||||||
nvbench::criterion_params m_criterion_params;
|
nvbench::criterion_params m_criterion_params;
|
||||||
|
|||||||
@@ -18,24 +18,24 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#include <cuda_runtime.h>
|
||||||
|
|
||||||
#include <nvbench/blocking_kernel.cuh>
|
#include <nvbench/blocking_kernel.cuh>
|
||||||
#include <nvbench/cpu_timer.cuh>
|
#include <nvbench/cpu_timer.cuh>
|
||||||
#include <nvbench/cuda_call.cuh>
|
#include <nvbench/cuda_call.cuh>
|
||||||
#include <nvbench/cuda_timer.cuh>
|
#include <nvbench/cuda_timer.cuh>
|
||||||
|
#include <nvbench/detail/gpu_frequency.cuh>
|
||||||
|
#include <nvbench/detail/kernel_launcher_timer_wrapper.cuh>
|
||||||
|
#include <nvbench/detail/l2flush.cuh>
|
||||||
|
#include <nvbench/detail/statistics.cuh>
|
||||||
#include <nvbench/device_info.cuh>
|
#include <nvbench/device_info.cuh>
|
||||||
#include <nvbench/exec_tag.cuh>
|
#include <nvbench/exec_tag.cuh>
|
||||||
#include <nvbench/launch.cuh>
|
#include <nvbench/launch.cuh>
|
||||||
#include <nvbench/stopping_criterion.cuh>
|
#include <nvbench/stopping_criterion.cuh>
|
||||||
|
|
||||||
#include <nvbench/detail/kernel_launcher_timer_wrapper.cuh>
|
|
||||||
#include <nvbench/detail/l2flush.cuh>
|
|
||||||
#include <nvbench/detail/statistics.cuh>
|
|
||||||
#include <nvbench/detail/gpu_frequency.cuh>
|
|
||||||
|
|
||||||
#include <cuda_runtime.h>
|
|
||||||
|
|
||||||
#include <utility>
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "nvbench/types.cuh"
|
#include "nvbench/types.cuh"
|
||||||
|
|
||||||
namespace nvbench
|
namespace nvbench
|
||||||
@@ -91,7 +91,7 @@ protected:
|
|||||||
nvbench::blocking_kernel m_blocker;
|
nvbench::blocking_kernel m_blocker;
|
||||||
|
|
||||||
nvbench::criterion_params m_criterion_params;
|
nvbench::criterion_params m_criterion_params;
|
||||||
nvbench::stopping_criterion_base& m_stopping_criterion;
|
nvbench::stopping_criterion_base &m_stopping_criterion;
|
||||||
nvbench::detail::gpu_frequency m_gpu_frequency;
|
nvbench::detail::gpu_frequency m_gpu_frequency;
|
||||||
|
|
||||||
bool m_disable_blocking_kernel{false};
|
bool m_disable_blocking_kernel{false};
|
||||||
@@ -102,8 +102,8 @@ protected:
|
|||||||
nvbench::float64_t m_skip_time{};
|
nvbench::float64_t m_skip_time{};
|
||||||
nvbench::float64_t m_timeout{};
|
nvbench::float64_t m_timeout{};
|
||||||
|
|
||||||
nvbench::float32_t m_throttle_threshold{0.75f}; // [% of peak SM clock rate]
|
nvbench::float32_t m_throttle_threshold; // [% of peak SM clock rate]
|
||||||
nvbench::float32_t m_throttle_recovery_delay{0.0f}; // [seconds]
|
nvbench::float32_t m_throttle_recovery_delay; // [seconds]
|
||||||
bool m_discard_on_throttle{false};
|
bool m_discard_on_throttle{false};
|
||||||
|
|
||||||
nvbench::int64_t m_total_samples{};
|
nvbench::int64_t m_total_samples{};
|
||||||
|
|||||||
@@ -1071,7 +1071,7 @@ try
|
|||||||
}
|
}
|
||||||
else if (prop_arg == "--throttle-threshold")
|
else if (prop_arg == "--throttle-threshold")
|
||||||
{
|
{
|
||||||
bench.set_throttle_threshold(static_cast<nvbench::float32_t>(value));
|
bench.set_throttle_threshold(static_cast<nvbench::float32_t>(value) / 100.0f);
|
||||||
}
|
}
|
||||||
else if (prop_arg == "--throttle-recovery-delay")
|
else if (prop_arg == "--throttle-recovery-delay")
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -338,8 +338,8 @@ private:
|
|||||||
nvbench::float64_t m_skip_time;
|
nvbench::float64_t m_skip_time;
|
||||||
nvbench::float64_t m_timeout;
|
nvbench::float64_t m_timeout;
|
||||||
|
|
||||||
nvbench::float32_t m_throttle_threshold{0.75f}; // [% of peak SM clock rate]
|
nvbench::float32_t m_throttle_threshold; // [% of peak SM clock rate]
|
||||||
nvbench::float32_t m_throttle_recovery_delay{0.0f}; // [seconds]
|
nvbench::float32_t m_throttle_recovery_delay; // [seconds]
|
||||||
bool m_discard_on_throttle{false};
|
bool m_discard_on_throttle{false};
|
||||||
|
|
||||||
// Deadlock protection. See blocking_kernel's class doc for details.
|
// Deadlock protection. See blocking_kernel's class doc for details.
|
||||||
|
|||||||
Reference in New Issue
Block a user