Skip to content

Commit 8ba94b8

Browse files
author
Requiem
committed
chore: adjusted thresholds
1 parent d08750b commit 8ba94b8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/vmaware.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5307,13 +5307,13 @@ struct VM {
53075307
#if (x86 && WINDOWS)
53085308
// Detect a hypervisor without giving it time to react (when the hypervisor sees the vmexit, it's already too late for it, as the counter already exceeded the threshold)
53095309
// Uses our own software-based clock, meaning a hypervisor can't hide time by offsetting TSC or controlling any hardware timer
5310-
double threshold = 4.0;
5310+
double threshold = 3;
53115311
if (util::is_running_under_translator()) {
53125312
debug("TIMER: Running inside a binary translation layer");
53135313
return false;
53145314
}
53155315
if (util::hyper_x() != HYPERV_UNKNOWN) {
5316-
threshold = 15.0;
5316+
threshold = 20.0;
53175317
}
53185318

53195319
// prevent false sharing when triggering hypervisor exits with the intentional data race condition

0 commit comments

Comments
 (0)