Skip to content

Commit ff982b1

Browse files
committed
fix incorrect error message in shim 'QueryPerformanceCounter'
1 parent 957ec2b commit ff982b1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/shims/time.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
128128
// Miri will assume that the machine's hardware counter has a resolution of 1 nanosecond.
129129
let duration = Instant::now().duration_since(this.machine.time_anchor);
130130
let qpc = i64::try_from(duration.as_nanos())
131-
.map_err(|_| err_unsup_format!("programs running longer than 2^64 nanoseconds are not supported"))?;
131+
.map_err(|_| err_unsup_format!("programs running longer than 2^63 nanoseconds are not supported"))?;
132132
this.write_scalar(Scalar::from_i64(qpc), this.deref_operand(lpPerformanceCount_op)?.into())?;
133133
Ok(-1) // return non-zero on success
134134
}

0 commit comments

Comments
 (0)