uint64_t nsec2tsc(uint64_t nsec) { if (mult_will_overflow_u64(nsec, system_timing.tsc_freq)) return usec2tsc(nsec / 1000); else return (nsec * system_timing.tsc_freq) / 1000000000; }
uint64_t nsec2tsc(uint64_t nsec) { if (mult_will_overflow_u64(nsec, get_tsc_freq())) return usec2tsc(nsec / 1000); else return (nsec * get_tsc_freq()) / 1000000000; }