diff --git a/thread/test/perf_workpool.cpp b/thread/test/perf_workpool.cpp index ae7ba9a6..20e15fe1 100644 --- a/thread/test/perf_workpool.cpp +++ b/thread/test/perf_workpool.cpp @@ -37,7 +37,7 @@ static void workload(uint64_t time_us) { do { auto diff = std::chrono::steady_clock::now() - start; diff_ns = std::chrono::duration_cast(diff).count(); - } while (diff_ns < (long) time_us); + } while (diff_ns < (long) time_us * 1000); } static void task_async() { @@ -143,4 +143,4 @@ int main(int argc, char** arg) { FLAGS_fires, FLAGS_vcpu_num, get_qps(start, end), sum_time.load() / FLAGS_fires); -} \ No newline at end of file +}