Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
36c8c5fd
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看板
提交
36c8c5fd
编写于
10月 04, 2017
作者:
A
asaha
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
d9823536
1659b51e
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
74 addition
and
61 deletion
+74
-61
.hgtags
.hgtags
+24
-0
THIRD_PARTY_README
THIRD_PARTY_README
+2
-2
src/share/vm/interpreter/linkResolver.cpp
src/share/vm/interpreter/linkResolver.cpp
+44
-58
src/share/vm/interpreter/linkResolver.hpp
src/share/vm/interpreter/linkResolver.hpp
+4
-1
未找到文件。
.hgtags
浏览文件 @
36c8c5fd
...
...
@@ -975,6 +975,19 @@ df6af363337eff5b22ae7940b0981231fdf5dfb4 jdk8u141-b13
23f1790147d838ddb1133cc79dc08e7c9ba5ab44 jdk8u141-b15
eea89df81a8e414813d921eeeeef9b6795f56698 jdk8u144-b00
db36f4d498b1bde975700a800b5ce732941c04b7 jdk8u144-b01
2d5100bddeb80cf767485b787fc3051311e3d7b9 jdk8u151-b00
596b584c68b73ec635347807571463580deb955f jdk8u151-b01
1f6f436360d5cd375b806aec1c78abb8fcb4e5f6 jdk8u151-b02
0aaeb48ae39e4fc558caf1b0c7ee504a49fec441 jdk8u151-b03
e48302d521d59c2fe62f874f1f5d34bc46517da7 jdk8u151-b04
507af6ef977a5d0306a8723dec66e34befc1ae81 jdk8u151-b05
e1dc36cddcbc36b78e3d0558f87bbf459191e479 jdk8u151-b06
e2a930243efa63b0a789e85a523e69574d53ac92 jdk8u151-b07
158904fa31b28f1e027dc5b5a833ee673e89a84b jdk8u151-b08
8b0169692abbf8fb7972920cd79cee7dcab959c3 jdk8u151-b09
e352e54382928eb8d5ec70455ef251973c332ccb jdk8u151-b10
0f06584f52ffc8627b78f4d461a3eba2b703a8f7 jdk8u151-b11
856e341587d52114a753e48674517e7e307fceff jdk8u151-b12
5aa8c4ca51f0e666d368a4f119ed734d3ac59d7c jdk8u122-b00
2198ef7e1c1702b3506b95b5d8c886ad5a12bbe5 jdk8u122-b01
58d961f47dd4ee1d516512b7744e0f1fc83d8f52 jdk8u122-b02
...
...
@@ -991,5 +1004,16 @@ fb8ea28efb05cd89e5416665232165ef0d2eef29 jdk8u122-b04
d63e731a896c711b8e0c30ac9ae2d900d4e024f6 jdk8u152-b03
0bd600d6d77b5b41780074bcbfa133032dadf657 jdk8u152-b04
68758c5ab0c1ef01e89bea8a9b799714831a177f jdk8u152-b05
98fb3d75fe567bda30a3667c58a9f83ad2acbdf3 jdk8u152-b06
4af38194b12580bdc885ab3873d7efefa990f543 jdk8u152-b07
285fcd09ae9994ac836a2759f6615520b2568432 jdk8u152-b08
70f18ab733f55856cbd880fe8ba3034ff4d7265d jdk8u152-b09
39967c81d3f3b8d20584d1400e6f4b2490f0c822 jdk8u152-b10
cbb6bc4b8c867ea69962fd5b6c79ffe3aa9fd77d jdk8u152-b11
cdfe7ec6f29293d7c2f64239518e8947733ad85c jdk8u152-b12
3dd92151df1b3b7c21756f241b49607024b6fe5a jdk8u152-b13
0a9d8db98fc5f0302da6520ba329f41baa092ae0 jdk8u152-b14
c1bf165d3b27e864a9f8eec5bb0c1e746a972ad5 jdk8u152-b15
98b4b0661837817cc39047000e1a7efa6015af7c jdk8u152-b16
7b96cfeed22242bb68a387d1680e602e37e48050 jdk8u162-b00
92693f9dd704467ddd5fbae5a5908c1713a08ee0 jdk8u162-b01
THIRD_PARTY_README
浏览文件 @
36c8c5fd
...
...
@@ -2808,12 +2808,12 @@ SOFTWARE.
-------------------------------------------------------------------------------
%% This notice is provided with respect to zlib v1.2.
8
, which may be included
%% This notice is provided with respect to zlib v1.2.
11
, which may be included
with JRE 8, JDK 8, and OpenJDK 8.
--- begin of LICENSE ---
version 1.2.
8, April 28th, 2013
version 1.2.
11, January 15th, 2017
Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler
...
...
src/share/vm/interpreter/linkResolver.cpp
浏览文件 @
36c8c5fd
...
...
@@ -540,6 +540,42 @@ void LinkResolver::resolve_method_statically(methodHandle& resolved_method, Klas
}
}
void
LinkResolver
::
check_method_loader_constraints
(
methodHandle
&
resolved_method
,
KlassHandle
resolved_klass
,
Symbol
*
method_name
,
Symbol
*
method_signature
,
KlassHandle
current_klass
,
const
char
*
method_type
,
TRAPS
)
{
Handle
loader
(
THREAD
,
InstanceKlass
::
cast
(
current_klass
())
->
class_loader
());
Handle
class_loader
(
THREAD
,
resolved_method
->
method_holder
()
->
class_loader
());
{
ResourceMark
rm
(
THREAD
);
Symbol
*
failed_type_symbol
=
SystemDictionary
::
check_signature_loaders
(
method_signature
,
loader
,
class_loader
,
true
,
CHECK
);
if
(
failed_type_symbol
!=
NULL
)
{
const
char
*
msg
=
"loader constraint violation: when resolving %s"
"
\"
%s
\"
the class loader (instance of %s) of the current class, %s,"
" and the class loader (instance of %s) for the method's defining class, %s, have"
" different Class objects for the type %s used in the signature"
;
char
*
sig
=
Method
::
name_and_sig_as_C_string
(
resolved_klass
(),
method_name
,
method_signature
);
const
char
*
loader1
=
SystemDictionary
::
loader_name
(
loader
());
char
*
current
=
InstanceKlass
::
cast
(
current_klass
())
->
name
()
->
as_C_string
();
const
char
*
loader2
=
SystemDictionary
::
loader_name
(
class_loader
());
char
*
target
=
InstanceKlass
::
cast
(
resolved_method
->
method_holder
())
->
name
()
->
as_C_string
();
char
*
failed_type_name
=
failed_type_symbol
->
as_C_string
();
size_t
buflen
=
strlen
(
msg
)
+
strlen
(
sig
)
+
strlen
(
loader1
)
+
strlen
(
current
)
+
strlen
(
loader2
)
+
strlen
(
target
)
+
strlen
(
failed_type_name
)
+
strlen
(
method_type
)
+
1
;
char
*
buf
=
NEW_RESOURCE_ARRAY_IN_THREAD
(
THREAD
,
char
,
buflen
);
jio_snprintf
(
buf
,
buflen
,
msg
,
method_type
,
sig
,
loader1
,
current
,
loader2
,
target
,
failed_type_name
);
THROW_MSG
(
vmSymbols
::
java_lang_LinkageError
(),
buf
);
}
}
}
void
LinkResolver
::
resolve_method
(
methodHandle
&
resolved_method
,
KlassHandle
resolved_klass
,
Symbol
*
method_name
,
Symbol
*
method_signature
,
KlassHandle
current_klass
,
bool
check_access
,
...
...
@@ -596,34 +632,8 @@ void LinkResolver::resolve_method(methodHandle& resolved_method, KlassHandle res
CHECK
);
// check loader constraints
Handle
loader
(
THREAD
,
InstanceKlass
::
cast
(
current_klass
())
->
class_loader
());
Handle
class_loader
(
THREAD
,
resolved_method
->
method_holder
()
->
class_loader
());
{
ResourceMark
rm
(
THREAD
);
Symbol
*
failed_type_symbol
=
SystemDictionary
::
check_signature_loaders
(
method_signature
,
loader
,
class_loader
,
true
,
CHECK
);
if
(
failed_type_symbol
!=
NULL
)
{
const
char
*
msg
=
"loader constraint violation: when resolving method"
"
\"
%s
\"
the class loader (instance of %s) of the current class, %s,"
" and the class loader (instance of %s) for the method's defining class, %s, have"
" different Class objects for the type %s used in the signature"
;
char
*
sig
=
Method
::
name_and_sig_as_C_string
(
resolved_klass
(),
method_name
,
method_signature
);
const
char
*
loader1
=
SystemDictionary
::
loader_name
(
loader
());
char
*
current
=
InstanceKlass
::
cast
(
current_klass
())
->
name
()
->
as_C_string
();
const
char
*
loader2
=
SystemDictionary
::
loader_name
(
class_loader
());
char
*
target
=
InstanceKlass
::
cast
(
resolved_method
->
method_holder
())
->
name
()
->
as_C_string
();
char
*
failed_type_name
=
failed_type_symbol
->
as_C_string
();
size_t
buflen
=
strlen
(
msg
)
+
strlen
(
sig
)
+
strlen
(
loader1
)
+
strlen
(
current
)
+
strlen
(
loader2
)
+
strlen
(
target
)
+
strlen
(
failed_type_name
)
+
1
;
char
*
buf
=
NEW_RESOURCE_ARRAY_IN_THREAD
(
THREAD
,
char
,
buflen
);
jio_snprintf
(
buf
,
buflen
,
msg
,
sig
,
loader1
,
current
,
loader2
,
target
,
failed_type_name
);
THROW_MSG
(
vmSymbols
::
java_lang_LinkageError
(),
buf
);
}
}
check_method_loader_constraints
(
resolved_method
,
resolved_klass
,
method_name
,
method_signature
,
current_klass
,
"method"
,
CHECK
);
}
}
...
...
@@ -672,36 +682,8 @@ void LinkResolver::resolve_interface_method(methodHandle& resolved_method,
resolved_method
,
CHECK
);
HandleMark
hm
(
THREAD
);
Handle
loader
(
THREAD
,
InstanceKlass
::
cast
(
current_klass
())
->
class_loader
());
Handle
class_loader
(
THREAD
,
resolved_method
->
method_holder
()
->
class_loader
());
{
ResourceMark
rm
(
THREAD
);
Symbol
*
failed_type_symbol
=
SystemDictionary
::
check_signature_loaders
(
method_signature
,
loader
,
class_loader
,
true
,
CHECK
);
if
(
failed_type_symbol
!=
NULL
)
{
const
char
*
msg
=
"loader constraint violation: when resolving "
"interface method
\"
%s
\"
the class loader (instance of %s) of the "
"current class, %s, and the class loader (instance of %s) for "
"the method's defining class, %s, have different Class objects for the type %s "
"used in the signature"
;
char
*
sig
=
Method
::
name_and_sig_as_C_string
(
resolved_klass
(),
method_name
,
method_signature
);
const
char
*
loader1
=
SystemDictionary
::
loader_name
(
loader
());
char
*
current
=
InstanceKlass
::
cast
(
current_klass
())
->
name
()
->
as_C_string
();
const
char
*
loader2
=
SystemDictionary
::
loader_name
(
class_loader
());
char
*
target
=
InstanceKlass
::
cast
(
resolved_method
->
method_holder
())
->
name
()
->
as_C_string
();
char
*
failed_type_name
=
failed_type_symbol
->
as_C_string
();
size_t
buflen
=
strlen
(
msg
)
+
strlen
(
sig
)
+
strlen
(
loader1
)
+
strlen
(
current
)
+
strlen
(
loader2
)
+
strlen
(
target
)
+
strlen
(
failed_type_name
)
+
1
;
char
*
buf
=
NEW_RESOURCE_ARRAY_IN_THREAD
(
THREAD
,
char
,
buflen
);
jio_snprintf
(
buf
,
buflen
,
msg
,
sig
,
loader1
,
current
,
loader2
,
target
,
failed_type_name
);
THROW_MSG
(
vmSymbols
::
java_lang_LinkageError
(),
buf
);
}
}
check_method_loader_constraints
(
resolved_method
,
resolved_klass
,
method_name
,
method_signature
,
current_klass
,
"interface method"
,
CHECK
);
}
if
(
nostatics
&&
resolved_method
->
is_static
())
{
...
...
@@ -1051,6 +1033,10 @@ void LinkResolver::runtime_resolve_special_method(CallInfo& result, methodHandle
Method
::
name_and_sig_as_C_string
(
resolved_klass
(),
resolved_method
->
name
(),
resolved_method
->
signature
()));
}
else
if
(
sel_method
()
!=
resolved_method
())
{
check_method_loader_constraints
(
sel_method
,
resolved_klass
,
sel_method
->
name
(),
sel_method
->
signature
(),
current_klass
,
"method"
,
CHECK
);
}
}
...
...
src/share/vm/interpreter/linkResolver.hpp
浏览文件 @
36c8c5fd
/*
* Copyright (c) 1997, 201
6
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
7
, 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
...
...
@@ -135,6 +135,9 @@ class LinkResolver: AllStatic {
static
void
resolve_pool
(
KlassHandle
&
resolved_klass
,
Symbol
*&
method_name
,
Symbol
*&
method_signature
,
KlassHandle
&
current_klass
,
constantPoolHandle
pool
,
int
index
,
TRAPS
);
static
void
resolve_interface_method
(
methodHandle
&
resolved_method
,
KlassHandle
resolved_klass
,
Symbol
*
method_name
,
Symbol
*
method_signature
,
KlassHandle
current_klass
,
bool
check_access
,
bool
nostatics
,
TRAPS
);
static
void
check_method_loader_constraints
(
methodHandle
&
resolved_method
,
KlassHandle
resolved_klass
,
Symbol
*
method_name
,
Symbol
*
method_signature
,
KlassHandle
current_klass
,
const
char
*
method_type
,
TRAPS
);
static
void
resolve_method
(
methodHandle
&
resolved_method
,
KlassHandle
resolved_klass
,
Symbol
*
method_name
,
Symbol
*
method_signature
,
KlassHandle
current_klass
,
bool
check_access
,
bool
require_methodref
,
TRAPS
);
static
void
linktime_resolve_static_method
(
methodHandle
&
resolved_method
,
KlassHandle
resolved_klass
,
Symbol
*
method_name
,
Symbol
*
method_signature
,
KlassHandle
current_klass
,
bool
check_access
,
TRAPS
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录