pub fn duration_as_ns(d: &Duration) -> u64