::scalehrtime could be more precise
Work by Bryan Cantrill.
Original comment by Bryan says:
For quite some time, we've had the ::scalehrtime dcmd (see OS-770). However, this is imprecise with respect to large values (e.g., TSC reads) because it doesn't follow the same algorithm as the kernel (which only converts values less than the tsc_tick interval). ::scalehrtime should mimic this, using a delta against tsc_last if the value to convert is closer to tsc_last than it is to 0.
Updated by Electric Monk 9 months ago
- Status changed from New to Closed
- % Done changed from 0 to 100
commit adabf61274801f4e57bf88d159c75b1993eeaf3c Author: Bryan Cantrill <email@example.com> Date: 2019-08-30T10:01:09.000Z 11585 ::scalehrtime could be more precise Reviewed by: Jerry Jelinek <firstname.lastname@example.org> Reviewed by: Toomas Soome <email@example.com> Approved by: Dan McDonald <firstname.lastname@example.org>