diff options
author | 2022-05-19 18:21:45 -0700 | |
---|---|---|
committer | 2022-05-19 18:22:58 -0700 | |
commit | b39a7000a007e66f63c65b2490628ea34026e5e6 (patch) | |
tree | 1f1133e4835146135f721f3b62c35dc9ba21309f /absl | |
parent | a168dd01438976657ddcfe09660c738dd73f8726 (diff) |
Don't default to the unscaled cycle clock on any Apple targets.
Previously was disabled on iPhone, but still enabled for macOS.
The unscaled cycle clock does not work correctly when run on a VM.
PiperOrigin-RevId: 449876559
Change-Id: I679ade90b43462e8d2794b1a2b32569d59029ed9
Diffstat (limited to 'absl')
-rw-r--r-- | absl/base/internal/unscaledcycleclock.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/absl/base/internal/unscaledcycleclock.h b/absl/base/internal/unscaledcycleclock.h index a4351406..2cbeae31 100644 --- a/absl/base/internal/unscaledcycleclock.h +++ b/absl/base/internal/unscaledcycleclock.h @@ -59,8 +59,7 @@ // CycleClock that runs at atleast 1 MHz. We've found some Android // ARM64 devices where this is not the case, so we disable it by // default on Android ARM64. -#if defined(__native_client__) || \ - (defined(TARGET_OS_IPHONE) && TARGET_OS_IPHONE) || \ +#if defined(__native_client__) || (defined(__APPLE__)) || \ (defined(__ANDROID__) && defined(__aarch64__)) #define ABSL_USE_UNSCALED_CYCLECLOCK_DEFAULT 0 #else |