Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
ab306b43
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看板
提交
ab306b43
编写于
2月 05, 2014
作者:
E
ehelin
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8028254: gc/arguments/TestMinInitialErgonomics.java failed with unexpected initial heap size
Reviewed-by: brutisso, tschatzl, sjohanss
上级
836aa407
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
9 addition
and
9 deletion
+9
-9
src/share/vm/prims/whitebox.cpp
src/share/vm/prims/whitebox.cpp
+1
-1
test/gc/arguments/TestMaxHeapSizeTools.java
test/gc/arguments/TestMaxHeapSizeTools.java
+8
-8
未找到文件。
src/share/vm/prims/whitebox.cpp
浏览文件 @
ab306b43
...
...
@@ -171,7 +171,7 @@ WB_END
WB_ENTRY
(
void
,
WB_PrintHeapSizes
(
JNIEnv
*
env
,
jobject
o
))
{
CollectorPolicy
*
p
=
Universe
::
heap
()
->
collector_policy
();
gclog_or_tty
->
print_cr
(
"Minimum heap "
SIZE_FORMAT
" Initial heap "
SIZE_FORMAT
" Maximum heap "
SIZE_FORMAT
" Min alignment "
SIZE_FORMAT
" Max
alignment "
SIZE_FORMAT
,
SIZE_FORMAT
" Maximum heap "
SIZE_FORMAT
" Space alignment "
SIZE_FORMAT
" Heap
alignment "
SIZE_FORMAT
,
p
->
min_heap_byte_size
(),
p
->
initial_heap_byte_size
(),
p
->
max_heap_byte_size
(),
p
->
space_alignment
(),
p
->
heap_alignment
());
}
...
...
test/gc/arguments/TestMaxHeapSizeTools.java
浏览文件 @
ab306b43
...
...
@@ -41,8 +41,8 @@ final class MinInitialMaxValues {
public
long
initialHeapSize
;
public
long
maxHeapSize
;
public
long
min
Alignment
;
public
long
max
Alignment
;
public
long
space
Alignment
;
public
long
heap
Alignment
;
}
class
TestMaxHeapSizeTools
{
...
...
@@ -192,7 +192,7 @@ class TestMaxHeapSizeTools {
// Unfortunately there is no other way to retrieve the minimum heap size and
// the alignments.
Matcher
m
=
Pattern
.
compile
(
"Minimum heap \\d+ Initial heap \\d+ Maximum heap \\d+
Min alignment \\d+ Max
alignment \\d+"
).
Matcher
m
=
Pattern
.
compile
(
"Minimum heap \\d+ Initial heap \\d+ Maximum heap \\d+
Space alignment \\d+ Heap
alignment \\d+"
).
matcher
(
output
.
getStdout
());
if
(!
m
.
find
())
{
throw
new
RuntimeException
(
"Could not find heap size string."
);
...
...
@@ -204,8 +204,8 @@ class TestMaxHeapSizeTools {
val
.
minHeapSize
=
valueAfter
(
match
,
"Minimum heap "
);
val
.
initialHeapSize
=
valueAfter
(
match
,
"Initial heap "
);
val
.
maxHeapSize
=
valueAfter
(
match
,
"Maximum heap "
);
val
.
minAlignment
=
valueAfter
(
match
,
"Min
alignment "
);
val
.
maxAlignment
=
valueAfter
(
match
,
"Max
alignment "
);
val
.
spaceAlignment
=
valueAfter
(
match
,
"Space
alignment "
);
val
.
heapAlignment
=
valueAfter
(
match
,
"Heap
alignment "
);
}
/**
...
...
@@ -218,12 +218,12 @@ class TestMaxHeapSizeTools {
MinInitialMaxValues
v
=
new
MinInitialMaxValues
();
getMinInitialMaxHeap
(
args
,
v
);
if
((
expectedMin
!=
-
1
)
&&
(
align_up
(
expectedMin
,
v
.
min
Alignment
)
!=
v
.
minHeapSize
))
{
if
((
expectedMin
!=
-
1
)
&&
(
align_up
(
expectedMin
,
v
.
heap
Alignment
)
!=
v
.
minHeapSize
))
{
throw
new
RuntimeException
(
"Actual minimum heap size of "
+
v
.
minHeapSize
+
" differs from expected minimum heap size of "
+
expectedMin
);
}
if
((
expectedInitial
!=
-
1
)
&&
(
align_up
(
expectedInitial
,
v
.
min
Alignment
)
!=
v
.
initialHeapSize
))
{
if
((
expectedInitial
!=
-
1
)
&&
(
align_up
(
expectedInitial
,
v
.
heap
Alignment
)
!=
v
.
initialHeapSize
))
{
throw
new
RuntimeException
(
"Actual initial heap size of "
+
v
.
initialHeapSize
+
" differs from expected initial heap size of "
+
expectedInitial
);
}
...
...
@@ -247,7 +247,7 @@ class TestMaxHeapSizeTools {
MinInitialMaxValues
v
=
new
MinInitialMaxValues
();
getMinInitialMaxHeap
(
new
String
[]
{
gcflag
,
"-XX:MaxHeapSize="
+
maxHeapsize
+
"M"
},
v
);
long
expectedHeapSize
=
align_up
(
maxHeapsize
*
K
*
K
,
v
.
max
Alignment
);
long
expectedHeapSize
=
align_up
(
maxHeapsize
*
K
*
K
,
v
.
heap
Alignment
);
long
actualHeapSize
=
v
.
maxHeapSize
;
if
(
actualHeapSize
>
expectedHeapSize
)
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录