15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #include "precompiled.hpp"
26 #include "jvm.h"
27 #include "asm/macroAssembler.hpp"
28 #include "asm/macroAssembler.inline.hpp"
29 #include "logging/log.hpp"
30 #include "logging/logStream.hpp"
31 #include "memory/resourceArea.hpp"
32 #include "runtime/java.hpp"
33 #include "runtime/os.hpp"
34 #include "runtime/stubCodeGenerator.hpp"
35 #include "utilities/virtualizationSupport.hpp"
36 #include "vm_version_x86.hpp"
37
38
39 int VM_Version::_cpu;
40 int VM_Version::_model;
41 int VM_Version::_stepping;
42 VM_Version::CpuidInfo VM_Version::_cpuid_info = { 0, };
43
44 // Address of instruction which causes SEGV
45 address VM_Version::_cpuinfo_segv_addr = 0;
46 // Address of instruction after the one which causes SEGV
47 address VM_Version::_cpuinfo_cont_addr = 0;
48
49 static BufferBlob* stub_blob;
50 static const int stub_size = 2000;
51
52 extern "C" {
53 typedef void (*get_cpu_info_stub_t)(void*);
54 typedef void (*detect_virt_stub_t)(uint32_t, uint32_t*);
55 }
56 static get_cpu_info_stub_t get_cpu_info_stub = NULL;
|
15 * You should have received a copy of the GNU General Public License version
16 * 2 along with this work; if not, write to the Free Software Foundation,
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #include "precompiled.hpp"
26 #include "jvm.h"
27 #include "asm/macroAssembler.hpp"
28 #include "asm/macroAssembler.inline.hpp"
29 #include "logging/log.hpp"
30 #include "logging/logStream.hpp"
31 #include "memory/resourceArea.hpp"
32 #include "runtime/java.hpp"
33 #include "runtime/os.hpp"
34 #include "runtime/stubCodeGenerator.hpp"
35 #include "runtime/vm_version.hpp"
36 #include "utilities/virtualizationSupport.hpp"
37
38
39 int VM_Version::_cpu;
40 int VM_Version::_model;
41 int VM_Version::_stepping;
42 VM_Version::CpuidInfo VM_Version::_cpuid_info = { 0, };
43
44 // Address of instruction which causes SEGV
45 address VM_Version::_cpuinfo_segv_addr = 0;
46 // Address of instruction after the one which causes SEGV
47 address VM_Version::_cpuinfo_cont_addr = 0;
48
49 static BufferBlob* stub_blob;
50 static const int stub_size = 2000;
51
52 extern "C" {
53 typedef void (*get_cpu_info_stub_t)(void*);
54 typedef void (*detect_virt_stub_t)(uint32_t, uint32_t*);
55 }
56 static get_cpu_info_stub_t get_cpu_info_stub = NULL;
|