Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
50215306
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看板
提交
50215306
编写于
8月 23, 2010
作者:
D
dcubed
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
364c91ae
bdc378de
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
28 addition
and
2 deletion
+28
-2
src/share/vm/memory/allocation.cpp
src/share/vm/memory/allocation.cpp
+2
-2
src/share/vm/runtime/arguments.cpp
src/share/vm/runtime/arguments.cpp
+23
-0
src/share/vm/runtime/arguments.hpp
src/share/vm/runtime/arguments.hpp
+3
-0
未找到文件。
src/share/vm/memory/allocation.cpp
浏览文件 @
50215306
...
...
@@ -58,7 +58,7 @@ void* ResourceObj::operator new(size_t size, allocation_type type) {
void
ResourceObj
::
operator
delete
(
void
*
p
)
{
assert
(((
ResourceObj
*
)
p
)
->
allocated_on_C_heap
(),
"delete only allowed for C_HEAP objects"
);
DEBUG_ONLY
(((
ResourceObj
*
)
p
)
->
_allocation
=
(
uintptr_t
)
badHeapOopVal
;)
DEBUG_ONLY
(((
ResourceObj
*
)
p
)
->
_allocation
=
(
uintptr_t
)
badHeapOopVal
;)
FreeHeap
(
p
);
}
...
...
@@ -104,7 +104,7 @@ ResourceObj& ResourceObj::operator=(const ResourceObj& r) { // default copy assi
ResourceObj
::~
ResourceObj
()
{
// allocated_on_C_heap() also checks that encoded (in _allocation) address == this.
if
(
!
allocated_on_C_heap
())
{
// ResourceObj::delete() zaps _allocation for C_heap.
_allocation
=
(
uintptr_t
)
badHeapOopVal
;
// zap type
_allocation
=
(
uintptr_t
)
badHeapOopVal
;
// zap type
}
}
#endif // ASSERT
...
...
src/share/vm/runtime/arguments.cpp
浏览文件 @
50215306
...
...
@@ -1561,6 +1561,18 @@ bool Arguments::verify_interval(uintx val, uintx min,
return
false
;
}
bool
Arguments
::
verify_min_value
(
intx
val
,
intx
min
,
const
char
*
name
)
{
// Returns true if given value is greater than specified min threshold
// false, otherwise.
if
(
val
>=
min
)
{
return
true
;
}
jio_fprintf
(
defaultStream
::
error_stream
(),
"%s of "
INTX_FORMAT
" is invalid; must be greater than "
INTX_FORMAT
"
\n
"
,
name
,
val
,
min
);
return
false
;
}
bool
Arguments
::
verify_percentage
(
uintx
value
,
const
char
*
name
)
{
if
(
value
<=
100
)
{
return
true
;
...
...
@@ -1613,6 +1625,16 @@ bool Arguments::check_gc_consistency() {
return
status
;
}
// Check stack pages settings
bool
Arguments
::
check_stack_pages
()
{
bool
status
=
true
;
status
=
status
&&
verify_min_value
(
StackYellowPages
,
1
,
"StackYellowPages"
);
status
=
status
&&
verify_min_value
(
StackRedPages
,
1
,
"StackRedPages"
);
status
=
status
&&
verify_min_value
(
StackShadowPages
,
1
,
"StackShadowPages"
);
return
status
;
}
// Check the consistency of vm_init_args
bool
Arguments
::
check_vm_args_consistency
()
{
// Method for adding checks for flag consistency.
...
...
@@ -1725,6 +1747,7 @@ bool Arguments::check_vm_args_consistency() {
}
status
=
status
&&
check_gc_consistency
();
status
=
status
&&
check_stack_pages
();
if
(
_has_alloc_profile
)
{
if
(
UseParallelGC
||
UseParallelOldGC
)
{
...
...
src/share/vm/runtime/arguments.hpp
浏览文件 @
50215306
...
...
@@ -338,6 +338,7 @@ class Arguments : AllStatic {
}
static
bool
verify_interval
(
uintx
val
,
uintx
min
,
uintx
max
,
const
char
*
name
);
static
bool
verify_min_value
(
intx
val
,
intx
min
,
const
char
*
name
);
static
bool
verify_percentage
(
uintx
value
,
const
char
*
name
);
static
void
describe_range_error
(
ArgsRange
errcode
);
static
ArgsRange
check_memory_size
(
julong
size
,
julong
min_size
);
...
...
@@ -400,6 +401,8 @@ class Arguments : AllStatic {
static
bool
check_gc_consistency
();
// Check consistecy or otherwise of VM argument settings
static
bool
check_vm_args_consistency
();
// Check stack pages settings
static
bool
check_stack_pages
();
// Used by os_solaris
static
bool
process_settings_file
(
const
char
*
file_name
,
bool
should_exist
,
jboolean
ignore_unrecognized
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录