Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
f4f207c1
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看板
提交
f4f207c1
编写于
3月 28, 2014
作者:
V
vlivanov
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
fe0330ea
24f894db
变更
13
展开全部
隐藏空白更改
内联
并排
Showing
13 changed file
with
5723 addition
and
37 deletion
+5723
-37
src/share/vm/c1/c1_GraphBuilder.cpp
src/share/vm/c1/c1_GraphBuilder.cpp
+8
-5
src/share/vm/opto/c2_globals.hpp
src/share/vm/opto/c2_globals.hpp
+1
-1
src/share/vm/opto/memnode.cpp
src/share/vm/opto/memnode.cpp
+25
-28
src/share/vm/runtime/globals.hpp
src/share/vm/runtime/globals.hpp
+4
-3
test/compiler/stable/TestStableBoolean.java
test/compiler/stable/TestStableBoolean.java
+627
-0
test/compiler/stable/TestStableByte.java
test/compiler/stable/TestStableByte.java
+632
-0
test/compiler/stable/TestStableChar.java
test/compiler/stable/TestStableChar.java
+631
-0
test/compiler/stable/TestStableDouble.java
test/compiler/stable/TestStableDouble.java
+632
-0
test/compiler/stable/TestStableFloat.java
test/compiler/stable/TestStableFloat.java
+632
-0
test/compiler/stable/TestStableInt.java
test/compiler/stable/TestStableInt.java
+632
-0
test/compiler/stable/TestStableLong.java
test/compiler/stable/TestStableLong.java
+632
-0
test/compiler/stable/TestStableObject.java
test/compiler/stable/TestStableObject.java
+635
-0
test/compiler/stable/TestStableShort.java
test/compiler/stable/TestStableShort.java
+632
-0
未找到文件。
src/share/vm/c1/c1_GraphBuilder.cpp
浏览文件 @
f4f207c1
...
...
@@ -3767,11 +3767,14 @@ bool GraphBuilder::try_inline_full(ciMethod* callee, bool holder_known, Bytecode
}
// now perform tests that are based on flag settings
if
(
callee
->
force_inline
())
{
if
(
inline_level
()
>
MaxForceInlineLevel
)
INLINE_BAILOUT
(
"MaxForceInlineLevel"
);
print_inlining
(
callee
,
"force inline by annotation"
);
}
else
if
(
callee
->
should_inline
())
{
print_inlining
(
callee
,
"force inline by CompileOracle"
);
if
(
callee
->
force_inline
()
||
callee
->
should_inline
())
{
if
(
inline_level
()
>
MaxForceInlineLevel
)
INLINE_BAILOUT
(
"MaxForceInlineLevel"
);
if
(
recursive_inline_level
(
callee
)
>
MaxRecursiveInlineLevel
)
INLINE_BAILOUT
(
"recursive inlining too deep"
);
const
char
*
msg
=
""
;
if
(
callee
->
force_inline
())
msg
=
"force inline by annotation"
;
if
(
callee
->
should_inline
())
msg
=
"force inline by CompileOracle"
;
print_inlining
(
callee
,
msg
);
}
else
{
// use heuristic controls on inlining
if
(
inline_level
()
>
MaxInlineLevel
)
INLINE_BAILOUT
(
"inlining too deep"
);
...
...
src/share/vm/opto/c2_globals.hpp
浏览文件 @
f4f207c1
...
...
@@ -458,7 +458,7 @@
product(bool, EliminateAutoBox, false, \
"Control optimizations for autobox elimination") \
\
experimental(bool, UseImplicitStableValues, false,
\
diagnostic(bool, UseImplicitStableValues, true,
\
"Mark well-known stable fields as such (e.g. String.value)") \
\
product(intx, AutoBoxCacheMax, 128, \
...
...
src/share/vm/opto/memnode.cpp
浏览文件 @
f4f207c1
...
...
@@ -1593,35 +1593,33 @@ LoadNode::load_array_final_field(const TypeKlassPtr *tkls,
// Try to constant-fold a stable array element.
static
const
Type
*
fold_stable_ary_elem
(
const
TypeAryPtr
*
ary
,
int
off
,
BasicType
loadbt
)
{
assert
(
ary
->
const_oop
(),
"array should be constant"
);
assert
(
ary
->
is_stable
(),
"array should be stable"
);
if
(
ary
->
const_oop
()
!=
NULL
)
{
// Decode the results of GraphKit::array_element_address.
ciArray
*
aobj
=
ary
->
const_oop
()
->
as_array
();
ciConstant
con
=
aobj
->
element_value_by_offset
(
off
);
if
(
con
.
basic_type
()
!=
T_ILLEGAL
&&
!
con
.
is_null_or_zero
())
{
const
Type
*
con_type
=
Type
::
make_from_constant
(
con
);
if
(
con_type
!=
NULL
)
{
if
(
con_type
->
isa_aryptr
())
{
// Join with the array element type, in case it is also stable.
int
dim
=
ary
->
stable_dimension
();
con_type
=
con_type
->
is_aryptr
()
->
cast_to_stable
(
true
,
dim
-
1
);
}
if
(
loadbt
==
T_NARROWOOP
&&
con_type
->
isa_oopptr
())
{
con_type
=
con_type
->
make_narrowoop
();
}
// Decode the results of GraphKit::array_element_address.
ciArray
*
aobj
=
ary
->
const_oop
()
->
as_array
();
ciConstant
con
=
aobj
->
element_value_by_offset
(
off
);
if
(
con
.
basic_type
()
!=
T_ILLEGAL
&&
!
con
.
is_null_or_zero
())
{
const
Type
*
con_type
=
Type
::
make_from_constant
(
con
);
if
(
con_type
!=
NULL
)
{
if
(
con_type
->
isa_aryptr
())
{
// Join with the array element type, in case it is also stable.
int
dim
=
ary
->
stable_dimension
();
con_type
=
con_type
->
is_aryptr
()
->
cast_to_stable
(
true
,
dim
-
1
);
}
if
(
loadbt
==
T_NARROWOOP
&&
con_type
->
isa_oopptr
())
{
con_type
=
con_type
->
make_narrowoop
();
}
#ifndef PRODUCT
if
(
TraceIterativeGVN
)
{
tty
->
print
(
"FoldStableValues: array element [off=%d]: con_type="
,
off
);
con_type
->
dump
();
tty
->
cr
();
}
#endif //PRODUCT
return
con_type
;
if
(
TraceIterativeGVN
)
{
tty
->
print
(
"FoldStableValues: array element [off=%d]: con_type="
,
off
);
con_type
->
dump
();
tty
->
cr
();
}
#endif //PRODUCT
return
con_type
;
}
}
return
NULL
;
}
...
...
@@ -1641,7 +1639,7 @@ const Type *LoadNode::Value( PhaseTransform *phase ) const {
// Try to guess loaded type from pointer type
if
(
tp
->
isa_aryptr
())
{
const
TypeAryPtr
*
ary
=
tp
->
is_aryptr
();
const
Type
*
t
=
ary
->
elem
();
const
Type
*
t
=
ary
->
elem
();
// Determine whether the reference is beyond the header or not, by comparing
// the offset against the offset of the start of the array's data.
...
...
@@ -1653,10 +1651,9 @@ const Type *LoadNode::Value( PhaseTransform *phase ) const {
const
bool
off_beyond_header
=
((
uint
)
off
>=
(
uint
)
min_base_off
);
// Try to constant-fold a stable array element.
if
(
FoldStableValues
&&
ary
->
is_stable
())
{
// Make sure the reference is not into the header
if
(
off_beyond_header
&&
off
!=
Type
::
OffsetBot
)
{
assert
(
adr
->
is_AddP
()
&&
adr
->
in
(
AddPNode
::
Offset
)
->
is_Con
(),
"offset is a constant"
);
if
(
FoldStableValues
&&
ary
->
is_stable
()
&&
ary
->
const_oop
()
!=
NULL
)
{
// Make sure the reference is not into the header and the offset is constant
if
(
off_beyond_header
&&
adr
->
is_AddP
()
&&
off
!=
Type
::
OffsetBot
)
{
const
Type
*
con_type
=
fold_stable_ary_elem
(
ary
,
off
,
memory_type
());
if
(
con_type
!=
NULL
)
{
return
con_type
;
...
...
src/share/vm/runtime/globals.hpp
浏览文件 @
f4f207c1
...
...
@@ -2986,7 +2986,8 @@ class CommandLineFlags {
"maximum number of nested recursive calls that are inlined") \
\
develop(intx, MaxForceInlineLevel, 100, \
"maximum number of nested @ForceInline calls that are inlined") \
"maximum number of nested calls that are forced for inlining " \
"(using CompilerOracle or marked w/ @ForceInline)") \
\
product_pd(intx, InlineSmallCode, \
"Only inline already compiled methods if their code size is " \
...
...
@@ -3797,8 +3798,8 @@ class CommandLineFlags {
experimental(bool, TrustFinalNonStaticFields, false, \
"trust final non-static declarations for constant folding") \
\
experimental(bool, FoldStableValues, false,
\
"
Private flag to control optimizations for stable variables")
\
diagnostic(bool, FoldStableValues, true,
\
"
Optimize loads from stable fields (marked w/ @Stable)")
\
\
develop(bool, TraceInvokeDynamic, false, \
"trace internal invoke dynamic operations") \
...
...
test/compiler/stable/TestStableBoolean.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableByte.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableChar.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableDouble.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableFloat.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableInt.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableLong.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableObject.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
test/compiler/stable/TestStableShort.java
0 → 100644
浏览文件 @
f4f207c1
此差异已折叠。
点击以展开。
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录