Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
76e07c76
D
dragonwell8_hotspot
项目概览
openanolis
/
dragonwell8_hotspot
通知
2
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell8_hotspot
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
76e07c76
编写于
8月 01, 2008
作者:
X
xlu
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
6719981: Update Hotspot Windows os_win32 for windows XP 64 bit and windows 2008
Reviewed-by: dholmes, kamg
上级
02f9bb4c
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
68 addition
and
34 deletion
+68
-34
src/os/windows/vm/os_windows.cpp
src/os/windows/vm/os_windows.cpp
+68
-34
未找到文件。
src/os/windows/vm/os_windows.cpp
浏览文件 @
76e07c76
...
...
@@ -1447,44 +1447,78 @@ void os::print_dll_info(outputStream *st) {
enumerate_modules
(
pid
,
_print_module
,
(
void
*
)
st
);
}
// function pointer to Windows API "GetNativeSystemInfo".
typedef
void
(
WINAPI
*
GetNativeSystemInfo_func_type
)(
LPSYSTEM_INFO
);
static
GetNativeSystemInfo_func_type
_GetNativeSystemInfo
;
void
os
::
print_os_info
(
outputStream
*
st
)
{
st
->
print
(
"OS:"
);
st
->
print
(
"OS:"
);
OSVERSIONINFOEX
osvi
;
ZeroMemory
(
&
osvi
,
sizeof
(
OSVERSIONINFOEX
));
osvi
.
dwOSVersionInfoSize
=
sizeof
(
OSVERSIONINFOEX
);
OSVERSIONINFOEX
osvi
;
ZeroMemory
(
&
osvi
,
sizeof
(
OSVERSIONINFOEX
));
osvi
.
dwOSVersionInfoSize
=
sizeof
(
OSVERSIONINFOEX
);
if
(
!
GetVersionEx
((
OSVERSIONINFO
*
)
&
osvi
))
{
st
->
print_cr
(
"N/A"
);
return
;
}
int
os_vers
=
osvi
.
dwMajorVersion
*
1000
+
osvi
.
dwMinorVersion
;
if
(
osvi
.
dwPlatformId
==
VER_PLATFORM_WIN32_NT
)
{
switch
(
os_vers
)
{
case
3051
:
st
->
print
(
" Windows NT 3.51"
);
break
;
case
4000
:
st
->
print
(
" Windows NT 4.0"
);
break
;
case
5000
:
st
->
print
(
" Windows 2000"
);
break
;
case
5001
:
st
->
print
(
" Windows XP"
);
break
;
case
5002
:
st
->
print
(
" Windows Server 2003 family"
);
break
;
case
6000
:
st
->
print
(
" Windows Vista"
);
break
;
default:
// future windows, print out its major and minor versions
st
->
print
(
" Windows NT %d.%d"
,
osvi
.
dwMajorVersion
,
osvi
.
dwMinorVersion
);
}
}
else
{
switch
(
os_vers
)
{
case
4000
:
st
->
print
(
" Windows 95"
);
break
;
case
4010
:
st
->
print
(
" Windows 98"
);
break
;
case
4090
:
st
->
print
(
" Windows Me"
);
break
;
default:
// future windows, print out its major and minor versions
st
->
print
(
" Windows %d.%d"
,
osvi
.
dwMajorVersion
,
osvi
.
dwMinorVersion
);
}
}
if
(
!
GetVersionEx
((
OSVERSIONINFO
*
)
&
osvi
))
{
st
->
print_cr
(
"N/A"
);
return
;
}
st
->
print
(
" Build %d"
,
osvi
.
dwBuildNumber
);
st
->
print
(
" %s"
,
osvi
.
szCSDVersion
);
// service pack
st
->
cr
();
int
os_vers
=
osvi
.
dwMajorVersion
*
1000
+
osvi
.
dwMinorVersion
;
if
(
osvi
.
dwPlatformId
==
VER_PLATFORM_WIN32_NT
)
{
switch
(
os_vers
)
{
case
3051
:
st
->
print
(
" Windows NT 3.51"
);
break
;
case
4000
:
st
->
print
(
" Windows NT 4.0"
);
break
;
case
5000
:
st
->
print
(
" Windows 2000"
);
break
;
case
5001
:
st
->
print
(
" Windows XP"
);
break
;
case
5002
:
case
6000
:
{
// Retrieve SYSTEM_INFO from GetNativeSystemInfo call so that we could
// find out whether we are running on 64 bit processor or not.
SYSTEM_INFO
si
;
ZeroMemory
(
&
si
,
sizeof
(
SYSTEM_INFO
));
// Check to see if _GetNativeSystemInfo has been initialized.
if
(
_GetNativeSystemInfo
==
NULL
)
{
HMODULE
hKernel32
=
GetModuleHandle
(
TEXT
(
"kernel32.dll"
));
_GetNativeSystemInfo
=
CAST_TO_FN_PTR
(
GetNativeSystemInfo_func_type
,
GetProcAddress
(
hKernel32
,
"GetNativeSystemInfo"
));
if
(
_GetNativeSystemInfo
==
NULL
)
GetSystemInfo
(
&
si
);
}
else
{
_GetNativeSystemInfo
(
&
si
);
}
if
(
os_vers
==
5002
)
{
if
(
osvi
.
wProductType
==
VER_NT_WORKSTATION
&&
si
.
wProcessorArchitecture
==
PROCESSOR_ARCHITECTURE_AMD64
)
st
->
print
(
" Windows XP x64 Edition"
);
else
st
->
print
(
" Windows Server 2003 family"
);
}
else
{
// os_vers == 6000
if
(
osvi
.
wProductType
==
VER_NT_WORKSTATION
)
st
->
print
(
" Windows Vista"
);
else
st
->
print
(
" Windows Server 2008"
);
if
(
si
.
wProcessorArchitecture
==
PROCESSOR_ARCHITECTURE_AMD64
)
st
->
print
(
" , 64 bit"
);
}
break
;
}
default:
// future windows, print out its major and minor versions
st
->
print
(
" Windows NT %d.%d"
,
osvi
.
dwMajorVersion
,
osvi
.
dwMinorVersion
);
}
}
else
{
switch
(
os_vers
)
{
case
4000
:
st
->
print
(
" Windows 95"
);
break
;
case
4010
:
st
->
print
(
" Windows 98"
);
break
;
case
4090
:
st
->
print
(
" Windows Me"
);
break
;
default:
// future windows, print out its major and minor versions
st
->
print
(
" Windows %d.%d"
,
osvi
.
dwMajorVersion
,
osvi
.
dwMinorVersion
);
}
}
st
->
print
(
" Build %d"
,
osvi
.
dwBuildNumber
);
st
->
print
(
" %s"
,
osvi
.
szCSDVersion
);
// service pack
st
->
cr
();
}
void
os
::
print_memory_info
(
outputStream
*
st
)
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录