Skip to content

Commit

Permalink
Update drmemtrace scheduler switch thresholds (#6840)
Browse files Browse the repository at this point in the history
Changes the drmemtrace scheduler's default context switch threshold
parameters, which trigger on system call latencies, to more closely
match observed patterns in large applications.

+ Raises the non-blocking threshold to a very high level as we do not
expect many such switchs, if any, in most applications.

+ Raises the blocking threshold from 100us to 500us to match switch
rates seen in real applications.

Tested on large internal traces where the switch rate was compared to
untraced values.
  • Loading branch information
derekbruening authored Jun 6, 2024
1 parent d7955d5 commit 2842570
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions clients/drcachesim/common/options.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -855,13 +855,14 @@ droption_t<bool> op_sched_order_time(DROPTION_SCOPE_ALL, "sched_order_time", tru
"Whether to honor recorded timestamps for ordering");

droption_t<uint64_t> op_sched_syscall_switch_us(
DROPTION_SCOPE_ALL, "sched_syscall_switch_us", 500,
"Minimum latency to consider any syscall as incurring a context switch.",
"Minimum latency in timestamp units (us) to consider any syscall as incurring "
"a context switch. Applies to -core_sharded and -core_serial. ");
DROPTION_SCOPE_ALL, "sched_syscall_switch_us", 30000000,
"Minimum latency to consider a non-blocking syscall as incurring a context switch.",
"Minimum latency in timestamp units (us) to consider a non-blocking syscall as "
"incurring a context switch (see -sched_blocking_switch_us for maybe-blocking "
"syscalls). Applies to -core_sharded and -core_serial. ");

droption_t<uint64_t> op_sched_blocking_switch_us(
DROPTION_SCOPE_ALL, "sched_blocking_switch_us", 100,
DROPTION_SCOPE_ALL, "sched_blocking_switch_us", 500,
"Minimum latency to consider a maybe-blocking syscall as incurring a context switch.",
"Minimum latency in timestamp units (us) to consider any syscall that is marked as "
"maybe-blocking to incur a context switch. Applies to -core_sharded and "
Expand Down

0 comments on commit 2842570

Please sign in to comment.