Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
21b0475a
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看板
体验新版 GitCode,发现更多精彩内容 >>
提交
21b0475a
编写于
6月 03, 2010
作者:
K
kvn
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
6958254: -XX:+VerifyOops is broken on x86
Summary: save and restore r10 in verify_oop(). Reviewed-by: never
上级
11a59890
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
15 addition
and
3 deletion
+15
-3
src/cpu/x86/vm/assembler_x86.cpp
src/cpu/x86/vm/assembler_x86.cpp
+8
-1
src/cpu/x86/vm/stubGenerator_x86_64.cpp
src/cpu/x86/vm/stubGenerator_x86_64.cpp
+7
-2
未找到文件。
src/cpu/x86/vm/assembler_x86.cpp
浏览文件 @
21b0475a
...
...
@@ -7643,6 +7643,9 @@ void MacroAssembler::verify_oop(Register reg, const char* s) {
// Pass register number to verify_oop_subroutine
char
*
b
=
new
char
[
strlen
(
s
)
+
50
];
sprintf
(
b
,
"verify_oop: %s: %s"
,
reg
->
name
(),
s
);
#ifdef _LP64
push
(
rscratch1
);
// save r10, trashed by movptr()
#endif
push
(
rax
);
// save rax,
push
(
reg
);
// pass register argument
ExternalAddress
buffer
((
address
)
b
);
...
...
@@ -7653,6 +7656,7 @@ void MacroAssembler::verify_oop(Register reg, const char* s) {
// call indirectly to solve generation ordering problem
movptr
(
rax
,
ExternalAddress
(
StubRoutines
::
verify_oop_subroutine_entry_address
()));
call
(
rax
);
// Caller pops the arguments (oop, message) and restores rax, r10
}
...
...
@@ -7767,6 +7771,9 @@ void MacroAssembler::verify_oop_addr(Address addr, const char* s) {
char
*
b
=
new
char
[
strlen
(
s
)
+
50
];
sprintf
(
b
,
"verify_oop_addr: %s"
,
s
);
#ifdef _LP64
push
(
rscratch1
);
// save r10, trashed by movptr()
#endif
push
(
rax
);
// save rax,
// addr may contain rsp so we will have to adjust it based on the push
// we just did
...
...
@@ -7789,7 +7796,7 @@ void MacroAssembler::verify_oop_addr(Address addr, const char* s) {
// call indirectly to solve generation ordering problem
movptr
(
rax
,
ExternalAddress
(
StubRoutines
::
verify_oop_subroutine_entry_address
()));
call
(
rax
);
// Caller pops the arguments
and restores rax, from the stack
// Caller pops the arguments
(addr, message) and restores rax, r10.
}
void
MacroAssembler
::
verify_tlab
()
{
...
...
src/cpu/x86/vm/stubGenerator_x86_64.cpp
浏览文件 @
21b0475a
...
...
@@ -914,6 +914,7 @@ class StubGenerator: public StubCodeGenerator {
// * [tos + 5]: error message (char*)
// * [tos + 6]: object to verify (oop)
// * [tos + 7]: saved rax - saved by caller and bashed
// * [tos + 8]: saved r10 (rscratch1) - saved by caller
// * = popped on exit
address
generate_verify_oop
()
{
StubCodeMark
mark
(
this
,
"StubRoutines"
,
"verify_oop"
);
...
...
@@ -934,6 +935,7 @@ class StubGenerator: public StubCodeGenerator {
// After previous pushes.
oop_to_verify
=
6
*
wordSize
,
saved_rax
=
7
*
wordSize
,
saved_r10
=
8
*
wordSize
,
// Before the call to MacroAssembler::debug(), see below.
return_addr
=
16
*
wordSize
,
...
...
@@ -983,15 +985,17 @@ class StubGenerator: public StubCodeGenerator {
// return if everything seems ok
__
bind
(
exit
);
__
movptr
(
rax
,
Address
(
rsp
,
saved_rax
));
// get saved rax back
__
movptr
(
rscratch1
,
Address
(
rsp
,
saved_r10
));
// get saved r10 back
__
pop
(
c_rarg3
);
// restore c_rarg3
__
pop
(
c_rarg2
);
// restore c_rarg2
__
pop
(
r12
);
// restore r12
__
popf
();
// restore flags
__
ret
(
3
*
wordSize
);
// pop caller saved stuff
__
ret
(
4
*
wordSize
);
// pop caller saved stuff
// handle errors
__
bind
(
error
);
__
movptr
(
rax
,
Address
(
rsp
,
saved_rax
));
// get saved rax back
__
movptr
(
rscratch1
,
Address
(
rsp
,
saved_r10
));
// get saved r10 back
__
pop
(
c_rarg3
);
// get saved c_rarg3 back
__
pop
(
c_rarg2
);
// get saved c_rarg2 back
__
pop
(
r12
);
// get saved r12 back
...
...
@@ -1009,6 +1013,7 @@ class StubGenerator: public StubCodeGenerator {
// * [tos + 17] error message (char*)
// * [tos + 18] object to verify (oop)
// * [tos + 19] saved rax - saved by caller and bashed
// * [tos + 20] saved r10 (rscratch1) - saved by caller
// * = popped on exit
__
movptr
(
c_rarg0
,
Address
(
rsp
,
error_msg
));
// pass address of error message
...
...
@@ -1021,7 +1026,7 @@ class StubGenerator: public StubCodeGenerator {
__
call
(
RuntimeAddress
(
CAST_FROM_FN_PTR
(
address
,
MacroAssembler
::
debug64
)));
__
mov
(
rsp
,
r12
);
// restore rsp
__
popa
();
// pop registers (includes r12)
__
ret
(
3
*
wordSize
);
// pop caller saved stuff
__
ret
(
4
*
wordSize
);
// pop caller saved stuff
return
start
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录