Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
78e710c7
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看板
提交
78e710c7
编写于
8月 02, 2009
作者:
J
jmasa
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
3072d4b7
982d38f1
变更
1
显示空白变更内容
内联
并排
Showing
1 changed file
with
40 addition
and
12 deletion
+40
-12
src/share/vm/runtime/arguments.cpp
src/share/vm/runtime/arguments.cpp
+40
-12
未找到文件。
src/share/vm/runtime/arguments.cpp
浏览文件 @
78e710c7
...
...
@@ -1054,7 +1054,15 @@ void Arguments::set_cms_and_parnew_gc_flags() {
// Unless explicitly requested otherwise, size young gen
// for "short" pauses ~ 4M*ParallelGCThreads
if
(
FLAG_IS_DEFAULT
(
MaxNewSize
))
{
// MaxNewSize not set at command-line
// If either MaxNewSize or NewRatio is set on the command line,
// assume the user is trying to set the size of the young gen.
if
(
FLAG_IS_DEFAULT
(
MaxNewSize
)
&&
FLAG_IS_DEFAULT
(
NewRatio
))
{
// Set MaxNewSize to our calculated preferred_max_new_size unless
// NewSize was set on the command line and it is larger than
// preferred_max_new_size.
if
(
!
FLAG_IS_DEFAULT
(
NewSize
))
{
// NewSize explicitly set at command-line
FLAG_SET_ERGO
(
uintx
,
MaxNewSize
,
MAX2
(
NewSize
,
preferred_max_new_size
));
}
else
{
...
...
@@ -1064,14 +1072,31 @@ void Arguments::set_cms_and_parnew_gc_flags() {
// Too early to use gclog_or_tty
tty
->
print_cr
(
"Ergo set MaxNewSize: "
SIZE_FORMAT
,
MaxNewSize
);
}
}
// Unless explicitly requested otherwise, prefer a large
// Old to Young gen size so as to shift the collection load
// to the old generation concurrent collector
if
(
FLAG_IS_DEFAULT
(
NewRatio
))
{
// If this is only guarded by FLAG_IS_DEFAULT(NewRatio)
// then NewSize and OldSize may be calculated. That would
// generally lead to some differences with ParNewGC for which
// there was no obvious reason. Also limit to the case where
// MaxNewSize has not been set.
FLAG_SET_ERGO
(
intx
,
NewRatio
,
MAX2
(
NewRatio
,
new_ratio
));
size_t
min_new
=
align_size_up
(
ScaleForWordSize
(
min_new_default
),
os
::
vm_page_size
());
// Code along this path potentially sets NewSize and OldSize
// Calculate the desired minimum size of the young gen but if
// NewSize has been set on the command line, use it here since
// it should be the final value.
size_t
min_new
;
if
(
FLAG_IS_DEFAULT
(
NewSize
))
{
min_new
=
align_size_up
(
ScaleForWordSize
(
min_new_default
),
os
::
vm_page_size
());
}
else
{
min_new
=
NewSize
;
}
size_t
prev_initial_size
=
initial_heap_size
();
if
(
prev_initial_size
!=
0
&&
prev_initial_size
<
min_new
+
OldSize
)
{
set_initial_heap_size
(
min_new
+
OldSize
);
...
...
@@ -1083,8 +1108,10 @@ void Arguments::set_cms_and_parnew_gc_flags() {
initial_heap_size
()
/
M
,
prev_initial_size
/
M
);
}
}
// MaxHeapSize is aligned down in collectorPolicy
size_t
max_heap
=
align_size_down
(
MaxHeapSize
,
size_t
max_heap
=
align_size_down
(
MaxHeapSize
,
CardTableRS
::
ct_max_alignment_constraint
());
if
(
PrintGCDetails
&&
Verbose
)
{
...
...
@@ -1150,8 +1177,9 @@ void Arguments::set_cms_and_parnew_gc_flags() {
// CMSParPromoteBlocksToClaim is a collector-specific flag, so
// we'll let it to take precedence.
jio_fprintf
(
defaultStream
::
error_stream
(),
"Both OldPLABSize and CMSParPromoteBlocksToClaim options are specified "
"for the CMS collector. CMSParPromoteBlocksToClaim will take precedence.
\n
"
);
"Both OldPLABSize and CMSParPromoteBlocksToClaim"
" options are specified for the CMS collector."
" CMSParPromoteBlocksToClaim will take precedence.
\n
"
);
}
}
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录