X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/593a1d5fd87cdf5b46dd5fcb84467b432cea0f91..c910b4d9d2451126ae3917b931cd4390c11e1d52:/osfmk/i386/rtclock.h diff --git a/osfmk/i386/rtclock.h b/osfmk/i386/rtclock.h index e3ea716d4..6f3406a8c 100644 --- a/osfmk/i386/rtclock.h +++ b/osfmk/i386/rtclock.h @@ -83,6 +83,7 @@ extern rtc_nanotime_t rtc_nanotime_info; 0: movl RNT_GENERATION(%edi),%esi /* being updated? */ ; \ testl %esi,%esi ; \ jz 0b /* wait until done */ ; \ + lfence ; \ rdtsc ; \ lfence ; \ subl RNT_TSC_BASE(%edi),%eax ; \ @@ -111,6 +112,7 @@ extern rtc_nanotime_t rtc_nanotime_info; 0: movl RNT_GENERATION(%rdi),%esi ; \ test %esi,%esi /* info updating? */ ; \ jz 0b /* - wait if so */ ; \ + lfence ; \ rdtsc ; \ lfence ; \ shlq $32,%rdx ; \