Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
85759245
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看板
提交
85759245
编写于
11月 11, 2013
作者:
J
jwilhelm
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
19cf3e11
1b7cbfc2
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
11 addition
and
10 deletion
+11
-10
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
...ion/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
+11
-10
未找到文件。
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
浏览文件 @
85759245
...
...
@@ -594,9 +594,9 @@ CMSCollector::CMSCollector(ConcurrentMarkSweepGeneration* cmsGen,
_verification_mark_bm
(
0
,
Mutex
::
leaf
+
1
,
"CMS_verification_mark_bm_lock"
),
_completed_initialization
(
false
),
_collector_policy
(
cp
),
_should_unload_classes
(
false
),
_should_unload_classes
(
CMSClassUnloadingEnabled
),
_concurrent_cycles_since_last_unload
(
0
),
_roots_scanning_options
(
0
),
_roots_scanning_options
(
SharedHeap
::
SO_None
),
_inter_sweep_estimate
(
CMS_SweepWeight
,
CMS_SweepPadding
),
_intra_sweep_estimate
(
CMS_SweepWeight
,
CMS_SweepPadding
),
_gc_tracer_cm
(
new
(
ResourceObj
::
C_HEAP
,
mtGC
)
CMSTracer
()),
...
...
@@ -788,14 +788,6 @@ CMSCollector::CMSCollector(ConcurrentMarkSweepGeneration* cmsGen,
&&
_survivor_chunk_index
==
0
),
"Error"
);
// Choose what strong roots should be scanned depending on verification options
if
(
!
CMSClassUnloadingEnabled
)
{
// If class unloading is disabled we want to include all classes into the root set.
add_root_scanning_option
(
SharedHeap
::
SO_AllClasses
);
}
else
{
add_root_scanning_option
(
SharedHeap
::
SO_SystemClasses
);
}
NOT_PRODUCT
(
_overflow_counter
=
CMSMarkStackOverflowInterval
;)
_gc_counters
=
new
CollectorCounters
(
"CMS"
,
1
);
_completed_initialization
=
true
;
...
...
@@ -2532,6 +2524,9 @@ void CMSCollector::collect_in_foreground(bool clear_all_soft_refs, GCCause::Caus
// Snapshot the soft reference policy to be used in this collection cycle.
ref_processor
()
->
setup_policy
(
clear_all_soft_refs
);
// Decide if class unloading should be done
update_should_unload_classes
();
bool
init_mark_was_synchronous
=
false
;
// until proven otherwise
while
(
_collectorState
!=
Idling
)
{
if
(
TraceCMSState
)
{
...
...
@@ -3310,7 +3305,10 @@ void CMSCollector::setup_cms_unloading_and_verification_state() {
||
VerifyBeforeExit
;
const
int
rso
=
SharedHeap
::
SO_Strings
|
SharedHeap
::
SO_CodeCache
;
// We set the proper root for this CMS cycle here.
if
(
should_unload_classes
())
{
// Should unload classes this cycle
remove_root_scanning_option
(
SharedHeap
::
SO_AllClasses
);
add_root_scanning_option
(
SharedHeap
::
SO_SystemClasses
);
remove_root_scanning_option
(
rso
);
// Shrink the root set appropriately
set_verifying
(
should_verify
);
// Set verification state for this cycle
return
;
// Nothing else needs to be done at this time
...
...
@@ -3318,6 +3316,9 @@ void CMSCollector::setup_cms_unloading_and_verification_state() {
// Not unloading classes this cycle
assert
(
!
should_unload_classes
(),
"Inconsitency!"
);
remove_root_scanning_option
(
SharedHeap
::
SO_SystemClasses
);
add_root_scanning_option
(
SharedHeap
::
SO_AllClasses
);
if
((
!
verifying
()
||
unloaded_classes_last_cycle
())
&&
should_verify
)
{
// Include symbols, strings and code cache elements to prevent their resurrection.
add_root_scanning_option
(
rso
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录