Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
99b55ad9
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看板
提交
99b55ad9
编写于
1月 21, 2013
作者:
A
acorn
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
469df69d
c2cd04c5
变更
47
展开全部
隐藏空白更改
内联
并排
Showing
47 changed file
with
386 addition
and
451 deletion
+386
-451
make/bsd/makefiles/mapfile-vers-debug
make/bsd/makefiles/mapfile-vers-debug
+1
-2
make/bsd/makefiles/mapfile-vers-product
make/bsd/makefiles/mapfile-vers-product
+1
-2
make/linux/makefiles/mapfile-vers-debug
make/linux/makefiles/mapfile-vers-debug
+1
-2
make/linux/makefiles/mapfile-vers-product
make/linux/makefiles/mapfile-vers-product
+1
-2
make/solaris/makefiles/mapfile-vers
make/solaris/makefiles/mapfile-vers
+1
-2
src/cpu/x86/vm/jni_x86.h
src/cpu/x86/vm/jni_x86.h
+2
-7
src/os/bsd/vm/os_bsd.cpp
src/os/bsd/vm/os_bsd.cpp
+9
-6
src/os/bsd/vm/os_bsd.inline.hpp
src/os/bsd/vm/os_bsd.inline.hpp
+1
-9
src/os/linux/vm/os_linux.inline.hpp
src/os/linux/vm/os_linux.inline.hpp
+1
-9
src/os/posix/launcher/java_md.c
src/os/posix/launcher/java_md.c
+1
-6
src/os/posix/launcher/java_md.h
src/os/posix/launcher/java_md.h
+7
-1
src/os/solaris/vm/os_solaris.inline.hpp
src/os/solaris/vm/os_solaris.inline.hpp
+1
-4
src/os/windows/launcher/java_md.c
src/os/windows/launcher/java_md.c
+1
-6
src/os/windows/launcher/java_md.h
src/os/windows/launcher/java_md.h
+3
-1
src/os/windows/vm/os_windows.cpp
src/os/windows/vm/os_windows.cpp
+4
-4
src/os/windows/vm/os_windows.inline.hpp
src/os/windows/vm/os_windows.inline.hpp
+1
-4
src/share/tools/launcher/java.c
src/share/tools/launcher/java.c
+2
-2
src/share/tools/launcher/java.h
src/share/tools/launcher/java.h
+1
-2
src/share/vm/c1/c1_InstructionPrinter.cpp
src/share/vm/c1/c1_InstructionPrinter.cpp
+2
-2
src/share/vm/c1/c1_LIR.cpp
src/share/vm/c1/c1_LIR.cpp
+2
-2
src/share/vm/ci/ciReplay.cpp
src/share/vm/ci/ciReplay.cpp
+2
-2
src/share/vm/classfile/javaClasses.cpp
src/share/vm/classfile/javaClasses.cpp
+250
-266
src/share/vm/classfile/javaClasses.hpp
src/share/vm/classfile/javaClasses.hpp
+7
-10
src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp
...entation/concurrentMarkSweep/compactibleFreeListSpace.cpp
+2
-2
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
...ion/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
+3
-3
src/share/vm/gc_implementation/parallelScavenge/psScavenge.cpp
...hare/vm/gc_implementation/parallelScavenge/psScavenge.cpp
+2
-2
src/share/vm/gc_implementation/shared/ageTable.cpp
src/share/vm/gc_implementation/shared/ageTable.cpp
+2
-2
src/share/vm/memory/universe.cpp
src/share/vm/memory/universe.cpp
+2
-2
src/share/vm/oops/constantPool.cpp
src/share/vm/oops/constantPool.cpp
+2
-2
src/share/vm/oops/constantPool.hpp
src/share/vm/oops/constantPool.hpp
+8
-5
src/share/vm/opto/idealGraphPrinter.cpp
src/share/vm/opto/idealGraphPrinter.cpp
+2
-2
src/share/vm/opto/type.cpp
src/share/vm/opto/type.cpp
+6
-6
src/share/vm/prims/jvm.cpp
src/share/vm/prims/jvm.cpp
+1
-10
src/share/vm/prims/jvm.h
src/share/vm/prims/jvm.h
+1
-4
src/share/vm/prims/jvmtiRedefineClasses.cpp
src/share/vm/prims/jvmtiRedefineClasses.cpp
+16
-27
src/share/vm/runtime/aprofiler.cpp
src/share/vm/runtime/aprofiler.cpp
+2
-2
src/share/vm/runtime/arguments.cpp
src/share/vm/runtime/arguments.cpp
+2
-2
src/share/vm/runtime/os.hpp
src/share/vm/runtime/os.hpp
+1
-5
src/share/vm/runtime/perfData.cpp
src/share/vm/runtime/perfData.cpp
+2
-2
src/share/vm/runtime/virtualspace.cpp
src/share/vm/runtime/virtualspace.cpp
+3
-3
src/share/vm/services/diagnosticArgument.cpp
src/share/vm/services/diagnosticArgument.cpp
+3
-3
src/share/vm/services/heapDumper.cpp
src/share/vm/services/heapDumper.cpp
+2
-2
src/share/vm/services/lowMemoryDetector.cpp
src/share/vm/services/lowMemoryDetector.cpp
+2
-2
src/share/vm/utilities/globalDefinitions.hpp
src/share/vm/utilities/globalDefinitions.hpp
+9
-1
src/share/vm/utilities/globalDefinitions_gcc.hpp
src/share/vm/utilities/globalDefinitions_gcc.hpp
+5
-1
src/share/vm/utilities/ostream.cpp
src/share/vm/utilities/ostream.cpp
+3
-5
src/share/vm/utilities/taskqueue.cpp
src/share/vm/utilities/taskqueue.cpp
+3
-3
未找到文件。
make/bsd/makefiles/mapfile-vers-debug
浏览文件 @
99b55ad9
...
...
@@ -3,7 +3,7 @@
#
#
# Copyright (c) 2002, 201
1
, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2002, 201
3
, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
...
...
@@ -205,7 +205,6 @@ SUNWprivate_1.1 {
JVM_NewMultiArray;
JVM_OnExit;
JVM_Open;
JVM_PrintStackTrace;
JVM_RaiseSignal;
JVM_RawMonitorCreate;
JVM_RawMonitorDestroy;
...
...
make/bsd/makefiles/mapfile-vers-product
浏览文件 @
99b55ad9
...
...
@@ -3,7 +3,7 @@
#
#
# Copyright (c) 2002, 201
1
, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2002, 201
3
, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
...
...
@@ -205,7 +205,6 @@ SUNWprivate_1.1 {
JVM_NewMultiArray;
JVM_OnExit;
JVM_Open;
JVM_PrintStackTrace;
JVM_RaiseSignal;
JVM_RawMonitorCreate;
JVM_RawMonitorDestroy;
...
...
make/linux/makefiles/mapfile-vers-debug
浏览文件 @
99b55ad9
#
# Copyright (c) 2002, 201
1
, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2002, 201
3
, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
...
...
@@ -201,7 +201,6 @@ SUNWprivate_1.1 {
JVM_NewMultiArray;
JVM_OnExit;
JVM_Open;
JVM_PrintStackTrace;
JVM_RaiseSignal;
JVM_RawMonitorCreate;
JVM_RawMonitorDestroy;
...
...
make/linux/makefiles/mapfile-vers-product
浏览文件 @
99b55ad9
#
# Copyright (c) 2002, 201
1
, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2002, 201
3
, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
...
...
@@ -201,7 +201,6 @@ SUNWprivate_1.1 {
JVM_NewMultiArray;
JVM_OnExit;
JVM_Open;
JVM_PrintStackTrace;
JVM_RaiseSignal;
JVM_RawMonitorCreate;
JVM_RawMonitorDestroy;
...
...
make/solaris/makefiles/mapfile-vers
浏览文件 @
99b55ad9
#
# Copyright (c) 2000, 201
1
, Oracle and/or its affiliates. All rights reserved.
# Copyright (c) 2000, 201
3
, Oracle and/or its affiliates. All rights reserved.
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
#
# This code is free software; you can redistribute it and/or modify it
...
...
@@ -201,7 +201,6 @@ SUNWprivate_1.1 {
JVM_NewMultiArray;
JVM_OnExit;
JVM_Open;
JVM_PrintStackTrace;
JVM_RaiseSignal;
JVM_RawMonitorCreate;
JVM_RawMonitorDestroy;
...
...
src/cpu/x86/vm/jni_x86.h
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
1
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -38,14 +38,9 @@
#define JNICALL
typedef
int
jint
;
#if defined(_LP64)
&& !defined(__APPLE__)
#if defined(_LP64)
typedef
long
jlong
;
#else
/*
* On _LP64 __APPLE__ "long" and "long long" are both 64 bits,
* but we use the "long long" typedef to avoid complaints from
* the __APPLE__ compiler about fprintf formats.
*/
typedef
long
long
jlong
;
#endif
...
...
src/os/bsd/vm/os_bsd.cpp
浏览文件 @
99b55ad9
...
...
@@ -243,29 +243,32 @@ void os::Bsd::initialize_system_info() {
int
mib
[
2
];
size_t
len
;
int
cpu_val
;
u_
long
mem_val
;
ju
long
mem_val
;
/* get processors count via hw.ncpus sysctl */
mib
[
0
]
=
CTL_HW
;
mib
[
1
]
=
HW_NCPU
;
len
=
sizeof
(
cpu_val
);
if
(
sysctl
(
mib
,
2
,
&
cpu_val
,
&
len
,
NULL
,
0
)
!=
-
1
&&
cpu_val
>=
1
)
{
assert
(
len
==
sizeof
(
cpu_val
),
"unexpected data size"
);
set_processor_count
(
cpu_val
);
}
else
{
set_processor_count
(
1
);
// fallback
}
/* get physical memory via hw.
usermem sysctl (hw.usermem
is used
*
instead of hw.physmem because we need size of allocatable memory
/* get physical memory via hw.
memsize sysctl (hw.memsize
is used
*
since it returns a 64 bit value)
*/
mib
[
0
]
=
CTL_HW
;
mib
[
1
]
=
HW_
USERMEM
;
mib
[
1
]
=
HW_
MEMSIZE
;
len
=
sizeof
(
mem_val
);
if
(
sysctl
(
mib
,
2
,
&
mem_val
,
&
len
,
NULL
,
0
)
!=
-
1
)
if
(
sysctl
(
mib
,
2
,
&
mem_val
,
&
len
,
NULL
,
0
)
!=
-
1
)
{
assert
(
len
==
sizeof
(
mem_val
),
"unexpected data size"
);
_physical_memory
=
mem_val
;
else
}
else
{
_physical_memory
=
256
*
1024
*
1024
;
// fallback (XXXBSD?)
}
#ifdef __OpenBSD__
{
...
...
src/os/bsd/vm/os_bsd.inline.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -59,14 +59,6 @@ inline const char* os::path_separator() {
return
":"
;
}
inline
const
char
*
os
::
jlong_format_specifier
()
{
return
"%lld"
;
}
inline
const
char
*
os
::
julong_format_specifier
()
{
return
"%llu"
;
}
// File names are case-sensitive on windows only
inline
int
os
::
file_name_strcmp
(
const
char
*
s1
,
const
char
*
s2
)
{
return
strcmp
(
s1
,
s2
);
...
...
src/os/linux/vm/os_linux.inline.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -68,14 +68,6 @@ inline const char* os::path_separator() {
return
":"
;
}
inline
const
char
*
os
::
jlong_format_specifier
()
{
return
"%lld"
;
}
inline
const
char
*
os
::
julong_format_specifier
()
{
return
"%llu"
;
}
// File names are case-sensitive on windows only
inline
int
os
::
file_name_strcmp
(
const
char
*
s1
,
const
char
*
s2
)
{
return
strcmp
(
s1
,
s2
);
...
...
src/os/posix/launcher/java_md.c
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -1876,11 +1876,6 @@ void SplashFreeLibrary() {
}
}
const
char
*
jlong_format_specifier
()
{
return
"%lld"
;
}
/*
* Block current thread and continue execution in a new thread
*/
...
...
src/os/posix/launcher/java_md.h
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -64,6 +64,12 @@
#define Counter2Micros(counts) (1)
#endif
/* HAVE_GETHRTIME */
#ifdef _LP64
#define JLONG_FORMAT "%ld"
#else
#define JLONG_FORMAT "%lld"
#endif
/*
* Function prototypes.
*/
...
...
src/os/solaris/vm/os_solaris.inline.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -50,9 +50,6 @@ inline const char* os::file_separator() { return "/"; }
inline
const
char
*
os
::
line_separator
()
{
return
"
\n
"
;
}
inline
const
char
*
os
::
path_separator
()
{
return
":"
;
}
inline
const
char
*
os
::
jlong_format_specifier
()
{
return
"%lld"
;
}
inline
const
char
*
os
::
julong_format_specifier
()
{
return
"%llu"
;
}
// File names are case-sensitive on windows only
inline
int
os
::
file_name_strcmp
(
const
char
*
s1
,
const
char
*
s2
)
{
return
strcmp
(
s1
,
s2
);
...
...
src/os/windows/launcher/java_md.c
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -1323,11 +1323,6 @@ void SplashFreeLibrary() {
}
}
const
char
*
jlong_format_specifier
()
{
return
"%I64d"
;
}
/*
* Block current thread and continue execution in a new thread
*/
...
...
src/os/windows/launcher/java_md.h
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -69,6 +69,8 @@ extern jlong Counter2Micros(jlong counts);
extern
int
_main
(
int
argc
,
char
**
argv
);
#endif
#define JLONG_FORMAT "%I64d"
/*
* Function prototypes.
*/
...
...
src/os/windows/vm/os_windows.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -2946,7 +2946,7 @@ char* os::pd_reserve_memory(size_t bytes, char* addr, size_t alignment_hint) {
}
if
(
Verbose
&&
PrintMiscellaneous
)
{
reserveTimer
.
stop
();
tty
->
print_cr
(
"reserve_memory of %Ix bytes took
%ld ms (%ld
ticks)"
,
bytes
,
tty
->
print_cr
(
"reserve_memory of %Ix bytes took
"
JLONG_FORMAT
" ms ("
JLONG_FORMAT
"
ticks)"
,
bytes
,
reserveTimer
.
milliseconds
(),
reserveTimer
.
ticks
());
}
}
...
...
@@ -4305,7 +4305,7 @@ char* os::pd_map_memory(int fd, const char* file_name, size_t file_offset,
if
(
hFile
==
NULL
)
{
if
(
PrintMiscellaneous
&&
Verbose
)
{
DWORD
err
=
GetLastError
();
tty
->
print_cr
(
"CreateFile() failed: GetLastError->%ld."
);
tty
->
print_cr
(
"CreateFile() failed: GetLastError->%ld."
,
err
);
}
return
NULL
;
}
...
...
@@ -4355,7 +4355,7 @@ char* os::pd_map_memory(int fd, const char* file_name, size_t file_offset,
if
(
hMap
==
NULL
)
{
if
(
PrintMiscellaneous
&&
Verbose
)
{
DWORD
err
=
GetLastError
();
tty
->
print_cr
(
"CreateFileMapping() failed: GetLastError->%ld."
);
tty
->
print_cr
(
"CreateFileMapping() failed: GetLastError->%ld."
,
err
);
}
CloseHandle
(
hFile
);
return
NULL
;
...
...
src/os/windows/vm/os_windows.inline.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -38,9 +38,6 @@ inline const char* os::line_separator() { return "\r\n"; }
inline
const
char
*
os
::
path_separator
()
{
return
";"
;
}
inline
const
char
*
os
::
dll_file_extension
()
{
return
".dll"
;
}
inline
const
char
*
os
::
jlong_format_specifier
()
{
return
"%I64d"
;
}
inline
const
char
*
os
::
julong_format_specifier
()
{
return
"%I64u"
;
}
inline
const
int
os
::
default_file_open_flags
()
{
return
O_BINARY
|
O_NOINHERIT
;}
// File names are case-insensitive on windows only
...
...
src/share/tools/launcher/java.c
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -808,7 +808,7 @@ CheckJvmType(int *pargc, char ***argv, jboolean speculative) {
static
int
parse_stack_size
(
const
char
*
s
,
jlong
*
result
)
{
jlong
n
=
0
;
int
args_read
=
sscanf
(
s
,
jlong_format_specifier
()
,
&
n
);
int
args_read
=
sscanf
(
s
,
JLONG_FORMAT
,
&
n
);
if
(
args_read
!=
1
)
{
return
0
;
}
...
...
src/share/tools/launcher/java.h
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -86,7 +86,6 @@ void ReportExceptionDescription(JNIEnv * env);
jboolean
RemovableMachineDependentOption
(
char
*
option
);
void
PrintMachineDependentOptions
();
const
char
*
jlong_format_specifier
();
/*
* Block current thread and continue execution in new thread
*/
...
...
src/share/vm/c1/c1_InstructionPrinter.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1999, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -360,7 +360,7 @@ void InstructionPrinter::do_Constant(Constant* x) {
ValueType
*
t
=
x
->
type
();
switch
(
t
->
tag
())
{
case
intTag
:
output
()
->
print
(
"%d"
,
t
->
as_IntConstant
()
->
value
());
break
;
case
longTag
:
output
()
->
print
(
os
::
jlong_format_specifier
()
,
t
->
as_LongConstant
()
->
value
());
output
()
->
print
(
"L"
);
break
;
case
longTag
:
output
()
->
print
(
JLONG_FORMAT
,
t
->
as_LongConstant
()
->
value
());
output
()
->
print
(
"L"
);
break
;
case
floatTag
:
output
()
->
print
(
"%g"
,
t
->
as_FloatConstant
()
->
value
());
break
;
case
doubleTag
:
output
()
->
print
(
"%gD"
,
t
->
as_DoubleConstant
()
->
value
());
break
;
case
objectTag
:
print_object
(
x
);
break
;
...
...
src/share/vm/c1/c1_LIR.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2000, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2000, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -1563,7 +1563,7 @@ void LIR_Const::print_value_on(outputStream* out) const {
switch
(
type
())
{
case
T_ADDRESS
:
out
->
print
(
"address:%d"
,
as_jint
());
break
;
case
T_INT
:
out
->
print
(
"int:%d"
,
as_jint
());
break
;
case
T_LONG
:
out
->
print
(
"lng:
%lld"
,
as_jlong
());
break
;
case
T_LONG
:
out
->
print
(
"lng:
"
JLONG_FORMAT
,
as_jlong
());
break
;
case
T_FLOAT
:
out
->
print
(
"flt:%f"
,
as_jfloat
());
break
;
case
T_DOUBLE
:
out
->
print
(
"dbl:%f"
,
as_jdouble
());
break
;
case
T_OBJECT
:
out
->
print
(
"obj:0x%x"
,
as_jobject
());
break
;
...
...
src/share/vm/ci/ciReplay.cpp
浏览文件 @
99b55ad9
/* Copyright (c) 201
2
, Oracle and/or its affiliates. All rights reserved.
/* Copyright (c) 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -645,7 +645,7 @@ class CompileReplay : public StackObj {
java_mirror
->
bool_field_put
(
fd
.
offset
(),
value
);
}
else
if
(
strcmp
(
field_signature
,
"J"
)
==
0
)
{
jlong
value
;
if
(
sscanf
(
string_value
,
INT64
_FORMAT
,
&
value
)
!=
1
)
{
if
(
sscanf
(
string_value
,
JLONG
_FORMAT
,
&
value
)
!=
1
)
{
fprintf
(
stderr
,
"Error parsing long: %s
\n
"
,
string_value
);
return
;
}
...
...
src/share/vm/classfile/javaClasses.cpp
浏览文件 @
99b55ad9
此差异已折叠。
点击以展开。
src/share/vm/classfile/javaClasses.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -463,8 +463,7 @@ class java_lang_Throwable: AllStatic {
static
int
static_unassigned_stacktrace_offset
;
// Printing
static
char
*
print_stack_element_to_buffer
(
Method
*
method
,
int
bci
);
static
void
print_to_stream
(
Handle
stream
,
const
char
*
str
);
static
char
*
print_stack_element_to_buffer
(
Handle
mirror
,
int
method
,
int
version
,
int
bci
);
// StackTrace (programmatic access, new since 1.4)
static
void
clear_stacktrace
(
oop
throwable
);
// No stack trace available
...
...
@@ -484,12 +483,9 @@ class java_lang_Throwable: AllStatic {
static
oop
message
(
oop
throwable
);
static
oop
message
(
Handle
throwable
);
static
void
set_message
(
oop
throwable
,
oop
value
);
// Print stack trace stored in exception by call-back to Java
// Note: this is no longer used in Merlin, but we still suppport
// it for compatibility.
static
void
print_stack_trace
(
oop
throwable
,
oop
print_stream
);
static
void
print_stack_element
(
Handle
stream
,
Method
*
method
,
int
bci
);
static
void
print_stack_element
(
outputStream
*
st
,
Method
*
method
,
int
bci
);
static
void
print_stack_element
(
outputStream
*
st
,
Handle
mirror
,
int
method
,
int
version
,
int
bci
);
static
void
print_stack_element
(
outputStream
*
st
,
methodHandle
method
,
int
bci
);
static
void
print_stack_usage
(
Handle
stream
);
// Allocate space for backtrace (created but stack trace not filled in)
...
...
@@ -1257,7 +1253,8 @@ class java_lang_StackTraceElement: AllStatic {
static
void
set_lineNumber
(
oop
element
,
int
value
);
// Create an instance of StackTraceElement
static
oop
create
(
methodHandle
m
,
int
bci
,
TRAPS
);
static
oop
create
(
Handle
mirror
,
int
method
,
int
version
,
int
bci
,
TRAPS
);
static
oop
create
(
methodHandle
method
,
int
bci
,
TRAPS
);
// Debugging
friend
class
JavaClasses
;
...
...
src/share/vm/gc_implementation/concurrentMarkSweep/compactibleFreeListSpace.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2001, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2001, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -554,7 +554,7 @@ void CompactibleFreeListSpace::reportFreeListStatistics() const {
reportIndexedFreeListStatistics
();
size_t
total_size
=
totalSizeInIndexedFreeLists
()
+
_dictionary
->
total_chunk_size
(
DEBUG_ONLY
(
freelistLock
()));
gclog_or_tty
->
print
(
" free=
%ld
frag=%1.4f
\n
"
,
total_size
,
flsFrag
());
gclog_or_tty
->
print
(
" free=
"
SIZE_FORMAT
"
frag=%1.4f
\n
"
,
total_size
,
flsFrag
());
}
}
...
...
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2001, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2001, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -3338,7 +3338,7 @@ bool ConcurrentMarkSweepGeneration::grow_by(size_t bytes) {
if
(
Verbose
&&
PrintGC
)
{
size_t
new_mem_size
=
_virtual_space
.
committed_size
();
size_t
old_mem_size
=
new_mem_size
-
bytes
;
gclog_or_tty
->
print_cr
(
"Expanding %s from
%ldK by %ldK to %ld
K"
,
gclog_or_tty
->
print_cr
(
"Expanding %s from
"
SIZE_FORMAT
"K by "
SIZE_FORMAT
"K to "
SIZE_FORMAT
"
K"
,
name
(),
old_mem_size
/
K
,
bytes
/
K
,
new_mem_size
/
K
);
}
}
...
...
@@ -9203,7 +9203,7 @@ void ASConcurrentMarkSweepGeneration::shrink_by(size_t desired_bytes) {
if
(
Verbose
&&
PrintGCDetails
)
{
size_t
new_mem_size
=
_virtual_space
.
committed_size
();
size_t
old_mem_size
=
new_mem_size
+
bytes
;
gclog_or_tty
->
print_cr
(
"Shrinking %s from
%ldK by %ldK to %ld
K"
,
gclog_or_tty
->
print_cr
(
"Shrinking %s from
"
SIZE_FORMAT
"K by "
SIZE_FORMAT
"K to "
SIZE_FORMAT
"
K"
,
name
(),
old_mem_size
/
K
,
bytes
/
K
,
new_mem_size
/
K
);
}
}
...
...
src/share/vm/gc_implementation/parallelScavenge/psScavenge.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2002, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2002, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -529,7 +529,7 @@ bool PSScavenge::invoke_no_policy() {
if
(
PrintTenuringDistribution
)
{
gclog_or_tty
->
cr
();
gclog_or_tty
->
print_cr
(
"Desired survivor size
%ld
bytes, new threshold %u (max %u)"
,
gclog_or_tty
->
print_cr
(
"Desired survivor size
"
SIZE_FORMAT
"
bytes, new threshold %u (max %u)"
,
size_policy
->
calculated_survivor_size_in_bytes
(),
_tenuring_threshold
,
MaxTenuringThreshold
);
}
...
...
src/share/vm/gc_implementation/shared/ageTable.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -96,7 +96,7 @@ uint ageTable::compute_tenuring_threshold(size_t survivor_capacity) {
if
(
PrintTenuringDistribution
)
{
gclog_or_tty
->
cr
();
gclog_or_tty
->
print_cr
(
"Desired survivor size
%ld
bytes, new threshold %u (max %u)"
,
gclog_or_tty
->
print_cr
(
"Desired survivor size
"
SIZE_FORMAT
"
bytes, new threshold %u (max %u)"
,
desired_survivor_size
*
oopSize
,
result
,
MaxTenuringThreshold
);
}
...
...
src/share/vm/memory/universe.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -228,7 +228,7 @@ void Universe::check_alignment(uintx size, uintx alignment, const char* name) {
if
(
size
<
alignment
||
size
%
alignment
!=
0
)
{
ResourceMark
rm
;
stringStream
st
;
st
.
print
(
"Size of %s (
%ld bytes) must be aligned to %ld
bytes"
,
name
,
size
,
alignment
);
st
.
print
(
"Size of %s (
"
UINTX_FORMAT
" bytes) must be aligned to "
UINTX_FORMAT
"
bytes"
,
name
,
size
,
alignment
);
char
*
error
=
st
.
as_string
();
vm_exit_during_initialization
(
error
);
}
...
...
src/share/vm/oops/constantPool.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -66,7 +66,7 @@ ConstantPool::ConstantPool(Array<u1>* tags) {
set_pool_holder
(
NULL
);
set_flags
(
0
);
// only set to non-zero if constant pool is merged by RedefineClasses
set_
orig_length
(
0
);
set_
version
(
0
);
set_lock
(
new
Monitor
(
Monitor
::
nonleaf
+
2
,
"A constant pool lock"
));
// all fields are initialized; needed for GC
set_on_stack
(
false
);
...
...
src/share/vm/oops/constantPool.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -103,8 +103,8 @@ class ConstantPool : public Metadata {
union
{
// set for CDS to restore resolved references
int
_resolved_reference_length
;
// only set to non-zero if constant pool is merged by RedefineClasses
int
_orig_length
;
// keeps version number for redefined classes (used in backtrace)
int
_version
;
}
_saved
;
Monitor
*
_lock
;
...
...
@@ -784,8 +784,11 @@ class ConstantPool : public Metadata {
static
void
copy_cp_to_impl
(
constantPoolHandle
from_cp
,
int
start_i
,
int
end_i
,
constantPoolHandle
to_cp
,
int
to_i
,
TRAPS
);
static
void
copy_entry_to
(
constantPoolHandle
from_cp
,
int
from_i
,
constantPoolHandle
to_cp
,
int
to_i
,
TRAPS
);
int
find_matching_entry
(
int
pattern_i
,
constantPoolHandle
search_cp
,
TRAPS
);
int
orig_length
()
const
{
return
_saved
.
_orig_length
;
}
void
set_orig_length
(
int
orig_length
)
{
_saved
.
_orig_length
=
orig_length
;
}
int
version
()
const
{
return
_saved
.
_version
;
}
void
set_version
(
int
version
)
{
_saved
.
_version
=
version
;
}
void
increment_and_save_version
(
int
version
)
{
_saved
.
_version
=
version
>=
0
?
(
version
+
1
)
:
version
;
// keep overflow
}
void
set_resolved_reference_length
(
int
length
)
{
_saved
.
_resolved_reference_length
=
length
;
}
int
resolved_reference_length
()
const
{
return
_saved
.
_resolved_reference_length
;
}
...
...
src/share/vm/opto/idealGraphPrinter.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2007, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -547,7 +547,7 @@ void IdealGraphPrinter::visit_node(Node *n, bool edges, VectorSet* temp_set) {
// max. 2 chars allowed
if
(
value
>=
-
9
&&
value
<=
99
)
{
sprintf
(
buffer
,
INT64
_FORMAT
,
value
);
sprintf
(
buffer
,
JLONG
_FORMAT
,
value
);
print_prop
(
short_name
,
buffer
);
}
else
{
print_prop
(
short_name
,
"L"
);
...
...
src/share/vm/opto/type.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -1542,10 +1542,10 @@ bool TypeLong::is_finite() const {
static
const
char
*
longnamenear
(
jlong
x
,
const
char
*
xname
,
char
*
buf
,
jlong
n
)
{
if
(
n
>
x
)
{
if
(
n
>=
x
+
10000
)
return
NULL
;
sprintf
(
buf
,
"%s+"
INT64
_FORMAT
,
xname
,
n
-
x
);
sprintf
(
buf
,
"%s+"
JLONG
_FORMAT
,
xname
,
n
-
x
);
}
else
if
(
n
<
x
)
{
if
(
n
<=
x
-
10000
)
return
NULL
;
sprintf
(
buf
,
"%s-"
INT64
_FORMAT
,
xname
,
x
-
n
);
sprintf
(
buf
,
"%s-"
JLONG
_FORMAT
,
xname
,
x
-
n
);
}
else
{
return
xname
;
}
...
...
@@ -1557,11 +1557,11 @@ static const char* longname(char* buf, jlong n) {
if
(
n
==
min_jlong
)
return
"min"
;
else
if
(
n
<
min_jlong
+
10000
)
sprintf
(
buf
,
"min+"
INT64
_FORMAT
,
n
-
min_jlong
);
sprintf
(
buf
,
"min+"
JLONG
_FORMAT
,
n
-
min_jlong
);
else
if
(
n
==
max_jlong
)
return
"max"
;
else
if
(
n
>
max_jlong
-
10000
)
sprintf
(
buf
,
"max-"
INT64
_FORMAT
,
max_jlong
-
n
);
sprintf
(
buf
,
"max-"
JLONG
_FORMAT
,
max_jlong
-
n
);
else
if
((
str
=
longnamenear
(
max_juint
,
"maxuint"
,
buf
,
n
))
!=
NULL
)
return
str
;
else
if
((
str
=
longnamenear
(
max_jint
,
"maxint"
,
buf
,
n
))
!=
NULL
)
...
...
@@ -1569,7 +1569,7 @@ static const char* longname(char* buf, jlong n) {
else
if
((
str
=
longnamenear
(
min_jint
,
"minint"
,
buf
,
n
))
!=
NULL
)
return
str
;
else
sprintf
(
buf
,
INT64
_FORMAT
,
n
);
sprintf
(
buf
,
JLONG
_FORMAT
,
n
);
return
buf
;
}
...
...
src/share/vm/prims/jvm.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -484,15 +484,6 @@ JVM_ENTRY(void, JVM_FillInStackTrace(JNIEnv *env, jobject receiver))
JVM_END
JVM_ENTRY
(
void
,
JVM_PrintStackTrace
(
JNIEnv
*
env
,
jobject
receiver
,
jobject
printable
))
JVMWrapper
(
"JVM_PrintStackTrace"
);
// Note: This is no longer used in Merlin, but we still support it for compatibility.
oop
exception
=
JNIHandles
::
resolve_non_null
(
receiver
);
oop
stream
=
JNIHandles
::
resolve_non_null
(
printable
);
java_lang_Throwable
::
print_stack_trace
(
exception
,
stream
);
JVM_END
JVM_ENTRY
(
jint
,
JVM_GetStackTraceDepth
(
JNIEnv
*
env
,
jobject
throwable
))
JVMWrapper
(
"JVM_GetStackTraceDepth"
);
oop
exception
=
JNIHandles
::
resolve
(
throwable
);
...
...
src/share/vm/prims/jvm.h
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -212,9 +212,6 @@ JVM_IsNaN(jdouble d);
JNIEXPORT
void
JNICALL
JVM_FillInStackTrace
(
JNIEnv
*
env
,
jobject
throwable
);
JNIEXPORT
void
JNICALL
JVM_PrintStackTrace
(
JNIEnv
*
env
,
jobject
throwable
,
jobject
printable
);
JNIEXPORT
jint
JNICALL
JVM_GetStackTraceDepth
(
JNIEnv
*
env
,
jobject
throwable
);
...
...
src/share/vm/prims/jvmtiRedefineClasses.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2003, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2003, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -1334,20 +1334,8 @@ jvmtiError VM_RedefineClasses::merge_cp_and_rewrite(
return
JVMTI_ERROR_INTERNAL
;
}
int
orig_length
=
old_cp
->
orig_length
();
if
(
orig_length
==
0
)
{
// This old_cp is an actual original constant pool. We save
// the original length in the merged constant pool so that
// merge_constant_pools() can be more efficient. If a constant
// pool has a non-zero orig_length() value, then that constant
// pool was created by a merge operation in RedefineClasses.
merge_cp
->
set_orig_length
(
old_cp
->
length
());
}
else
{
// This old_cp is a merged constant pool from a previous
// RedefineClasses() calls so just copy the orig_length()
// value.
merge_cp
->
set_orig_length
(
old_cp
->
orig_length
());
}
// Update the version number of the constant pool
merge_cp
->
increment_and_save_version
(
old_cp
->
version
());
ResourceMark
rm
(
THREAD
);
_index_map_count
=
0
;
...
...
@@ -2417,18 +2405,19 @@ void VM_RedefineClasses::set_new_constant_pool(
int
scratch_cp_length
,
TRAPS
)
{
assert
(
scratch_cp
->
length
()
>=
scratch_cp_length
,
"sanity check"
);
// scratch_cp is a merged constant pool and has enough space for a
// worst case merge situation. We want to associate the minimum
// sized constant pool with the klass to save space.
constantPoolHandle
smaller_cp
(
THREAD
,
ConstantPool
::
allocate
(
loader_data
,
scratch_cp_length
,
THREAD
));
// preserve orig_length() value in the smaller copy
int
orig_length
=
scratch_cp
->
orig_length
();
assert
(
orig_length
!=
0
,
"sanity check"
);
smaller_cp
->
set_orig_length
(
orig_length
);
scratch_cp
->
copy_cp_to
(
1
,
scratch_cp_length
-
1
,
smaller_cp
,
1
,
THREAD
);
scratch_cp
=
smaller_cp
;
// scratch_cp is a merged constant pool and has enough space for a
// worst case merge situation. We want to associate the minimum
// sized constant pool with the klass to save space.
constantPoolHandle
smaller_cp
(
THREAD
,
ConstantPool
::
allocate
(
loader_data
,
scratch_cp_length
,
THREAD
));
// preserve version() value in the smaller copy
int
version
=
scratch_cp
->
version
();
assert
(
version
!=
0
,
"sanity check"
);
smaller_cp
->
set_version
(
version
);
scratch_cp
->
copy_cp_to
(
1
,
scratch_cp_length
-
1
,
smaller_cp
,
1
,
THREAD
);
scratch_cp
=
smaller_cp
;
// attach new constant pool to klass
scratch_cp
->
set_pool_holder
(
scratch_class
());
...
...
src/share/vm/runtime/aprofiler.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -129,7 +129,7 @@ void AllocationProfiler::print(size_t cutoff) {
assert
(
!
is_active
(),
"AllocationProfiler cannot be active while printing profile"
);
tty
->
cr
();
tty
->
print_cr
(
"Allocation profile (sizes in bytes, cutoff =
%ld
bytes):"
,
cutoff
*
BytesPerWord
);
tty
->
print_cr
(
"Allocation profile (sizes in bytes, cutoff =
"
SIZE_FORMAT
"
bytes):"
,
cutoff
*
BytesPerWord
);
tty
->
cr
();
// Print regular instance klasses and basic type array klasses
...
...
src/share/vm/runtime/arguments.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -532,7 +532,7 @@ char* SysClassPath::add_jars_to_path(char* path, const char* directory) {
// Parses a memory size specification string.
static
bool
atomull
(
const
char
*
s
,
julong
*
result
)
{
julong
n
=
0
;
int
args_read
=
sscanf
(
s
,
os
::
julong_format_specifier
()
,
&
n
);
int
args_read
=
sscanf
(
s
,
JULONG_FORMAT
,
&
n
);
if
(
args_read
!=
1
)
{
return
false
;
}
...
...
src/share/vm/runtime/os.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -641,10 +641,6 @@ class os: AllStatic {
static
struct
hostent
*
get_host_by_name
(
char
*
name
);
// Printing 64 bit integers
static
const
char
*
jlong_format_specifier
();
static
const
char
*
julong_format_specifier
();
// Support for signals (see JVM_RaiseSignal, JVM_RegisterSignal)
static
void
signal_init
();
static
void
signal_init_pd
();
...
...
src/share/vm/runtime/perfData.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2001, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2001, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -192,7 +192,7 @@ PerfLong::PerfLong(CounterNS ns, const char* namep, Units u, Variability v)
}
int
PerfLong
::
format
(
char
*
buffer
,
int
length
)
{
return
jio_snprintf
(
buffer
,
length
,
"%lld"
,
*
(
jlong
*
)
_valuep
);
return
jio_snprintf
(
buffer
,
length
,
JLONG_FORMAT
,
*
(
jlong
*
)
_valuep
);
}
PerfLongVariant
::
PerfLongVariant
(
CounterNS
ns
,
const
char
*
namep
,
Units
u
,
...
...
src/share/vm/runtime/virtualspace.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -868,8 +868,8 @@ void VirtualSpace::print() {
tty
->
print
(
"Virtual space:"
);
if
(
special
())
tty
->
print
(
" (pinned in memory)"
);
tty
->
cr
();
tty
->
print_cr
(
" - committed:
%ld"
,
committed_size
());
tty
->
print_cr
(
" - reserved:
%ld"
,
reserved_size
());
tty
->
print_cr
(
" - committed:
"
SIZE_FORMAT
,
committed_size
());
tty
->
print_cr
(
" - reserved:
"
SIZE_FORMAT
,
reserved_size
());
tty
->
print_cr
(
" - [low, high]: ["
INTPTR_FORMAT
", "
INTPTR_FORMAT
"]"
,
low
(),
high
());
tty
->
print_cr
(
" - [low_b, high_b]: ["
INTPTR_FORMAT
", "
INTPTR_FORMAT
"]"
,
low_boundary
(),
high_boundary
());
}
...
...
src/share/vm/services/diagnosticArgument.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2011, 201
2,
Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 201
3
Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -86,7 +86,7 @@ void GenDCmdArgument::to_string(StringArrayArgument* f, char* buf, size_t len) {
template
<
>
void
DCmdArgument
<
jlong
>::
parse_value
(
const
char
*
str
,
size_t
len
,
TRAPS
)
{
if
(
str
==
NULL
||
sscanf
(
str
,
INT64
_FORMAT
,
&
_value
)
!=
1
)
{
if
(
str
==
NULL
||
sscanf
(
str
,
JLONG
_FORMAT
,
&
_value
)
!=
1
)
{
THROW_MSG
(
vmSymbols
::
java_lang_IllegalArgumentException
(),
"Integer parsing error in diagnostic command arguments
\n
"
);
}
...
...
@@ -171,7 +171,7 @@ template <> void DCmdArgument<NanoTimeArgument>::parse_value(const char* str,
"Integer parsing error nanotime value: syntax error"
);
}
int
argc
=
sscanf
(
str
,
INT64_FORMAT
,
&
_value
.
_time
);
int
argc
=
sscanf
(
str
,
JLONG_FORMAT
,
&
_value
.
_time
);
if
(
argc
!=
1
)
{
THROW_MSG
(
vmSymbols
::
java_lang_IllegalArgumentException
(),
"Integer parsing error nanotime value: syntax error"
);
...
...
src/share/vm/services/heapDumper.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2005, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -1866,7 +1866,7 @@ int HeapDumper::dump(const char* path) {
if
(
error
()
==
NULL
)
{
char
msg
[
256
];
sprintf
(
msg
,
"Heap dump file created [%s bytes in %3.3f secs]"
,
os
::
jlong_format_specifier
()
,
timer
()
->
seconds
());
JLONG_FORMAT
,
timer
()
->
seconds
());
tty
->
print_cr
(
msg
,
writer
.
bytes_written
());
}
else
{
tty
->
print_cr
(
"Dump file is incomplete: %s"
,
writer
.
error
());
...
...
src/share/vm/services/lowMemoryDetector.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2003, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2003, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -353,7 +353,7 @@ void SensorInfo::clear(int count, TRAPS) {
#ifndef PRODUCT
void
SensorInfo
::
print
()
{
tty
->
print_cr
(
"%s count =
%ld
pending_triggers = %ld pending_clears = %ld"
,
tty
->
print_cr
(
"%s count =
"
SIZE_FORMAT
"
pending_triggers = %ld pending_clears = %ld"
,
(
_sensor_on
?
"on"
:
"off"
),
_sensor_count
,
_pending_trigger_count
,
_pending_clear_count
);
}
...
...
src/share/vm/utilities/globalDefinitions.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -1250,6 +1250,14 @@ inline int build_int_from_shorts( jushort low, jushort high ) {
#define PTR64_FORMAT "0x%016" PRIx64
// Format jlong, if necessary
#ifndef JLONG_FORMAT
#define JLONG_FORMAT INT64_FORMAT
#endif
#ifndef JULONG_FORMAT
#define JULONG_FORMAT UINT64_FORMAT
#endif
// Format pointers which change size between 32- and 64-bit.
#ifdef _LP64
#define INTPTR_FORMAT "0x%016" PRIxPTR
...
...
src/share/vm/utilities/globalDefinitions_gcc.hpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1998, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1998, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -306,4 +306,8 @@ inline int wcslen(const jchar* x) { return wcslen((const wchar_t*)x); }
#endif
#define offsetof(klass,field) offset_of(klass,field)
#if defined(_LP64) && defined(__APPLE__)
#define JLONG_FORMAT "%ld"
#endif // _LP64 && __APPLE__
#endif // SHARE_VM_UTILITIES_GLOBALDEFINITIONS_GCC_HPP
src/share/vm/utilities/ostream.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 1997, 201
2
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -243,13 +243,11 @@ outputStream& outputStream::indent() {
}
void
outputStream
::
print_jlong
(
jlong
value
)
{
// N.B. Same as INT64_FORMAT
print
(
os
::
jlong_format_specifier
(),
value
);
print
(
JLONG_FORMAT
,
value
);
}
void
outputStream
::
print_julong
(
julong
value
)
{
// N.B. Same as UINT64_FORMAT
print
(
os
::
julong_format_specifier
(),
value
);
print
(
JULONG_FORMAT
,
value
);
}
/**
...
...
src/share/vm/utilities/taskqueue.cpp
浏览文件 @
99b55ad9
/*
* Copyright (c) 2001, 201
0
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2001, 201
3
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -239,8 +239,8 @@ ParallelTaskTerminator::offer_termination(TerminatorTerminator* terminator) {
#ifdef TRACESPINNING
void
ParallelTaskTerminator
::
print_termination_counts
()
{
gclog_or_tty
->
print_cr
(
"ParallelTaskTerminator Total yields:
%lld "
"
Total spins: %lld Total peeks: %lld"
,
gclog_or_tty
->
print_cr
(
"ParallelTaskTerminator Total yields:
"
UINT32_FORMAT
"
Total spins: "
UINT32_FORMAT
" Total peeks: "
UINT32_FORMAT
,
total_yields
(),
total_spins
(),
total_peeks
());
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录