JDK-8250598 : Hyper-V is detected in spite of running on host OS
  • Type: Bug
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 11,13
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2020-07-27
  • Updated: 2024-11-20
  • Resolved: 2020-08-26
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11 JDK 16
11.0.10-oracleFixed 16 b13Fixed
Related Reports
Relates :  
Description
https://mail.openjdk.java.net/pipermail/hotspot-runtime-dev/2020-July/040833

When I got hs_err log on Windows, I saw "HyperV virtualization detected" in it in spite of running on host OS.

Hypervisor detector has been introduced in JDK-8219241, but it has some problems as below:

  - Hyper-V is detected on Windows in spite of running on host OS
  - Call CPUID with other than EAX = 40000000h (it is not described in the spec [1])
  - Does not check CPUID hypervisor present bit [1]
  - Does not support x86 (32bit) platform

[1] https://kb.vmware.com/s/article/1009458
Comments
Fix request for 11u: Review thread on jdk-updates-dev: https://mail.openjdk.java.net/pipermail/jdk-updates-dev/2020-August/003686.html This change appears on virtual machine only, so hard to test, but the code would be run on initialize phase in VM. Thus we can see error in any tests if the change is wrong.
28-08-2020

URL: https://hg.openjdk.java.net/jdk/jdk/rev/80c95309a924 User: ysuenaga Date: 2020-08-26 10:21:33 +0000
26-08-2020

ILW = MLM = P4
28-07-2020