Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
0342985d
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看板
提交
0342985d
编写于
8月 01, 2012
作者:
Z
zgu
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
47ba72e7
37292a59
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
11 addition
and
11 deletion
+11
-11
src/share/vm/services/memSnapshot.cpp
src/share/vm/services/memSnapshot.cpp
+1
-1
src/share/vm/services/memSnapshot.hpp
src/share/vm/services/memSnapshot.hpp
+4
-4
src/share/vm/services/memTrackWorker.cpp
src/share/vm/services/memTrackWorker.cpp
+6
-4
src/share/vm/services/memTracker.hpp
src/share/vm/services/memTracker.hpp
+0
-2
未找到文件。
src/share/vm/services/memSnapshot.cpp
浏览文件 @
0342985d
...
...
@@ -344,7 +344,7 @@ void MemSnapshot::promote() {
// due to platform dependent behaviors. On some platforms, we see uncommit/release
// native thread stack, but some, we don't.
if
(
!
cur_vm
->
is_uncommit_record
()
&&
!
cur_vm
->
is_deallocation_record
())
{
ShouldNotReachHere
(
);
fatal
(
err_msg
(
"Should not reach here, pointer flags = [%x]"
,
cur_vm
->
flags
())
);
}
#endif
}
...
...
src/share/vm/services/memSnapshot.hpp
浏览文件 @
0342985d
...
...
@@ -63,13 +63,13 @@ class MemPointerIterator : public MemPointerArrayIteratorImpl {
MemPointer
*
p1
=
(
MemPointer
*
)
ptr
;
MemPointer
*
p2
=
(
MemPointer
*
)
_array
->
at
(
_pos
-
1
);
assert
(
!
is_dup_pointer
(
p1
,
p2
),
"dup pointer"
);
err_msg
(
"duplicated pointer, flag = [%x]"
,
(
unsigned
int
)((
MemPointerRecord
*
)
p1
)
->
flags
())
);
}
if
(
_pos
<
_array
->
length
()
-
1
)
{
MemPointer
*
p1
=
(
MemPointer
*
)
ptr
;
MemPointer
*
p2
=
(
MemPointer
*
)
_array
->
at
(
_pos
+
1
);
assert
(
!
is_dup_pointer
(
p1
,
p2
),
"dup pointer"
);
err_msg
(
"duplicated pointer, flag = [%x]"
,
(
unsigned
int
)((
MemPointerRecord
*
)
p1
)
->
flags
())
);
}
return
_array
->
insert_at
(
ptr
,
_pos
);
}
...
...
@@ -79,14 +79,14 @@ class MemPointerIterator : public MemPointerArrayIteratorImpl {
MemPointer
*
p1
=
(
MemPointer
*
)
ptr
;
MemPointer
*
p2
=
(
MemPointer
*
)
_array
->
at
(
_pos
-
1
);
assert
(
!
is_dup_pointer
(
p1
,
p2
),
"dup pointer"
);
err_msg
(
"duplicated pointer, flag = [%x]"
,
(
unsigned
int
)((
MemPointerRecord
*
)
p1
)
->
flags
())
);
}
if
(
_pos
<
_array
->
length
()
-
1
)
{
MemPointer
*
p1
=
(
MemPointer
*
)
ptr
;
MemPointer
*
p2
=
(
MemPointer
*
)
_array
->
at
(
_pos
+
1
);
assert
(
!
is_dup_pointer
(
p1
,
p2
),
"dup pointer"
);
err_msg
(
"duplicated pointer, flag = [%x]"
,
(
unsigned
int
)((
MemPointerRecord
*
)
p1
)
->
flags
())
);
}
if
(
_array
->
insert_at
(
ptr
,
_pos
+
1
))
{
_pos
++
;
...
...
src/share/vm/services/memTrackWorker.cpp
浏览文件 @
0342985d
...
...
@@ -99,9 +99,11 @@ void MemTrackWorker::run() {
}
if
(
rec
!=
NULL
)
{
// merge the recorder into staging area
bool
result
=
snapshot
->
merge
(
rec
);
assert
(
result
,
"merge failed"
);
debug_only
(
_merge_count
++
;)
if
(
!
snapshot
->
merge
(
rec
))
{
MemTracker
::
shutdown
(
MemTracker
::
NMT_out_of_memory
);
}
else
{
NOT_PRODUCT
(
_merge_count
++
;)
}
MemTracker
::
release_thread_recorder
(
rec
);
}
else
{
// no more recorder to merge, promote staging area
...
...
@@ -129,7 +131,7 @@ void MemTrackWorker::run() {
}
assert
(
MemTracker
::
shutdown_in_progress
(),
"just check"
);
// transit
e
s to final shutdown
// transits to final shutdown
MemTracker
::
final_shutdown
();
}
...
...
src/share/vm/services/memTracker.hpp
浏览文件 @
0342985d
...
...
@@ -184,7 +184,6 @@ class MemTracker : AllStatic {
// record a 'malloc' call
static
inline
void
record_malloc
(
address
addr
,
size_t
size
,
MEMFLAGS
flags
,
address
pc
=
0
,
Thread
*
thread
=
NULL
)
{
assert
(
is_on
(),
"check by caller"
);
if
(
NMT_CAN_TRACK
(
flags
))
{
create_memory_record
(
addr
,
(
flags
|
MemPointerRecord
::
malloc_tag
()),
size
,
pc
,
thread
);
}
...
...
@@ -285,7 +284,6 @@ class MemTracker : AllStatic {
// retrieve global snapshot
static
MemSnapshot
*
get_snapshot
()
{
assert
(
is_on
(),
"native memory tracking is off"
);
if
(
shutdown_in_progress
())
{
return
NULL
;
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录