Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
6dd0f5e5
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看板
提交
6dd0f5e5
编写于
9月 30, 2018
作者:
A
aefimov
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
06c8954d
e0b043c9
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
22 addition
and
4 deletion
+22
-4
src/share/vm/oops/cpCache.cpp
src/share/vm/oops/cpCache.cpp
+14
-4
src/share/vm/runtime/sharedRuntime.cpp
src/share/vm/runtime/sharedRuntime.cpp
+8
-0
未找到文件。
src/share/vm/oops/cpCache.cpp
浏览文件 @
6dd0f5e5
/*
* Copyright (c) 1998, 201
7
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1998, 201
8
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -209,12 +209,22 @@ void ConstantPoolCacheEntry::set_direct_or_vtable_call(Bytecodes::Code invoke_co
if
(
byte_no
==
1
)
{
assert
(
invoke_code
!=
Bytecodes
::
_invokevirtual
&&
invoke_code
!=
Bytecodes
::
_invokeinterface
,
""
);
bool
do_resolve
=
true
;
// Don't mark invokespecial to method as resolved if sender is an interface. The receiver
// has to be checked that it is a subclass of the current class every time this bytecode
// is executed.
if
(
invoke_code
!=
Bytecodes
::
_invokespecial
||
!
sender_is_interface
||
method
->
name
()
==
vmSymbols
::
object_initializer_name
())
{
set_bytecode_1
(
invoke_code
);
if
(
invoke_code
==
Bytecodes
::
_invokespecial
&&
sender_is_interface
&&
method
->
name
()
!=
vmSymbols
::
object_initializer_name
())
{
do_resolve
=
false
;
}
// Don't mark invokestatic to method as resolved if the holder class has not yet completed
// initialization. An invokestatic must only proceed if the class is initialized, but if
// we resolve it before then that class initialization check is skipped.
if
(
invoke_code
==
Bytecodes
::
_invokestatic
&&
!
method
->
method_holder
()
->
is_initialized
())
{
do_resolve
=
false
;
}
if
(
do_resolve
)
{
set_bytecode_1
(
invoke_code
);
}
}
else
if
(
byte_no
==
2
)
{
if
(
change_to_virtual
)
{
...
...
src/share/vm/runtime/sharedRuntime.cpp
浏览文件 @
6dd0f5e5
...
...
@@ -1232,6 +1232,14 @@ methodHandle SharedRuntime::resolve_sub_helper(JavaThread *thread,
}
#endif
// Do not patch call site for static call when the class is not
// fully initialized.
if
(
invoke_code
==
Bytecodes
::
_invokestatic
&&
!
callee_method
->
method_holder
()
->
is_initialized
())
{
assert
(
callee_method
->
method_holder
()
->
is_linked
(),
"must be"
);
return
callee_method
;
}
// JSR 292 key invariant:
// If the resolved method is a MethodHandle invoke target, the call
// site must be a MethodHandle call site, because the lambda form might tail-call
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录