Skip to content

Commit d362996

Browse files
committed
JDK-8261397: bsd_aarch64 part
1 parent b1c516d commit d362996

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

src/hotspot/cpu/aarch64/vm_version_aarch64.hpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,11 @@ class VM_Version : public Abstract_VM_Version {
136136
constexpr static bool supports_stack_watermark_barrier() { return true; }
137137

138138
static void get_compatible_board(char *buf, int buflen);
139+
140+
#ifdef __APPLE__
141+
// Is the CPU running emulated (for example macOS Rosetta running x86_64 code on M1 ARM (aarch64)
142+
static bool is_cpu_emulated();
143+
#endif
139144
};
140145

141146
#endif // CPU_AARCH64_VM_VERSION_AARCH64_HPP

src/hotspot/os_cpu/bsd_aarch64/vm_version_bsd_aarch64.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,3 +97,11 @@ void VM_Version::get_compatible_board(char *buf, int buflen) {
9797
assert(buflen >= 1, "invalid argument");
9898
*buf = '\0';
9999
}
100+
101+
#ifdef __APPLE__
102+
103+
bool VM_Version::is_cpu_emulated() {
104+
return false;
105+
}
106+
107+
#endif

0 commit comments

Comments
 (0)