Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_hotspot
提交
23a259aa
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看板
提交
23a259aa
编写于
7月 12, 2011
作者:
J
jcoomes
浏览文件
操作
浏览文件
下载
差异文件
Merge
上级
153b0b58
7a6df037
变更
18
隐藏空白更改
内联
并排
Showing
18 changed file
with
243 addition
and
42 deletion
+243
-42
src/os/linux/vm/os_linux.cpp
src/os/linux/vm/os_linux.cpp
+122
-2
src/os/solaris/vm/os_solaris.cpp
src/os/solaris/vm/os_solaris.cpp
+4
-0
src/os/windows/vm/os_windows.cpp
src/os/windows/vm/os_windows.cpp
+4
-0
src/os_cpu/linux_x86/vm/assembler_linux_x86.cpp
src/os_cpu/linux_x86/vm/assembler_linux_x86.cpp
+23
-0
src/os_cpu/linux_x86/vm/threadLS_linux_x86.cpp
src/os_cpu/linux_x86/vm/threadLS_linux_x86.cpp
+14
-7
src/os_cpu/linux_x86/vm/threadLS_linux_x86.hpp
src/os_cpu/linux_x86/vm/threadLS_linux_x86.hpp
+12
-8
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
...ion/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
+4
-0
src/share/vm/memory/defNewGeneration.cpp
src/share/vm/memory/defNewGeneration.cpp
+4
-0
src/share/vm/memory/genCollectedHeap.cpp
src/share/vm/memory/genCollectedHeap.cpp
+4
-0
src/share/vm/opto/lcm.cpp
src/share/vm/opto/lcm.cpp
+3
-0
src/share/vm/opto/matcher.cpp
src/share/vm/opto/matcher.cpp
+3
-0
src/share/vm/prims/jni.cpp
src/share/vm/prims/jni.cpp
+0
-9
src/share/vm/runtime/arguments.cpp
src/share/vm/runtime/arguments.cpp
+24
-9
src/share/vm/runtime/atomic.cpp
src/share/vm/runtime/atomic.cpp
+6
-0
src/share/vm/runtime/globals.hpp
src/share/vm/runtime/globals.hpp
+11
-6
src/share/vm/runtime/os.cpp
src/share/vm/runtime/os.cpp
+1
-0
src/share/vm/runtime/os.hpp
src/share/vm/runtime/os.hpp
+1
-0
src/share/vm/runtime/thread.cpp
src/share/vm/runtime/thread.cpp
+3
-1
未找到文件。
src/os/linux/vm/os_linux.cpp
浏览文件 @
23a259aa
...
@@ -169,7 +169,35 @@ sigset_t SR_sigset;
...
@@ -169,7 +169,35 @@ sigset_t SR_sigset;
/* Used to protect dlsym() calls */
/* Used to protect dlsym() calls */
static
pthread_mutex_t
dl_mutex
;
static
pthread_mutex_t
dl_mutex
;
////////////////////////////////////////////////////////////////////////////////
#ifdef JAVASE_EMBEDDED
class
MemNotifyThread
:
public
Thread
{
friend
class
VMStructs
;
public:
virtual
void
run
();
private:
static
MemNotifyThread
*
_memnotify_thread
;
int
_fd
;
public:
// Constructor
MemNotifyThread
(
int
fd
);
// Tester
bool
is_memnotify_thread
()
const
{
return
true
;
}
// Printing
char
*
name
()
const
{
return
(
char
*
)
"Linux MemNotify Thread"
;
}
// Returns the single instance of the MemNotifyThread
static
MemNotifyThread
*
memnotify_thread
()
{
return
_memnotify_thread
;
}
// Create and start the single instance of MemNotifyThread
static
void
start
();
};
#endif // JAVASE_EMBEDDED
// utility functions
// utility functions
static
int
SR_initialize
();
static
int
SR_initialize
();
...
@@ -2085,6 +2113,14 @@ void os::print_os_info(outputStream* st) {
...
@@ -2085,6 +2113,14 @@ void os::print_os_info(outputStream* st) {
st
->
cr
();
st
->
cr
();
}
}
void
os
::
pd_print_cpu_info
(
outputStream
*
st
)
{
st
->
print
(
"
\n
/proc/cpuinfo:
\n
"
);
if
(
!
_print_ascii_file
(
"/proc/cpuinfo"
,
st
))
{
st
->
print
(
" <Not Available>"
);
}
st
->
cr
();
}
void
os
::
print_memory_info
(
outputStream
*
st
)
{
void
os
::
print_memory_info
(
outputStream
*
st
)
{
st
->
print
(
"Memory:"
);
st
->
print
(
"Memory:"
);
...
@@ -4237,7 +4273,16 @@ jint os::init_2(void)
...
@@ -4237,7 +4273,16 @@ jint os::init_2(void)
}
}
// this is called at the end of vm_initialization
// this is called at the end of vm_initialization
void
os
::
init_3
(
void
)
{
}
void
os
::
init_3
(
void
)
{
#ifdef JAVASE_EMBEDDED
// Start the MemNotifyThread
if
(
LowMemoryProtection
)
{
MemNotifyThread
::
start
();
}
return
;
#endif
}
// Mark the polling page as unreadable
// Mark the polling page as unreadable
void
os
::
make_polling_page_unreadable
(
void
)
{
void
os
::
make_polling_page_unreadable
(
void
)
{
...
@@ -5360,3 +5405,78 @@ bool os::is_headless_jre() {
...
@@ -5360,3 +5405,78 @@ bool os::is_headless_jre() {
return
true
;
return
true
;
}
}
#ifdef JAVASE_EMBEDDED
//
// A thread to watch the '/dev/mem_notify' device, which will tell us when the OS is running low on memory.
//
MemNotifyThread
*
MemNotifyThread
::
_memnotify_thread
=
NULL
;
// ctor
//
MemNotifyThread
::
MemNotifyThread
(
int
fd
)
:
Thread
()
{
assert
(
memnotify_thread
()
==
NULL
,
"we can only allocate one MemNotifyThread"
);
_fd
=
fd
;
if
(
os
::
create_thread
(
this
,
os
::
os_thread
))
{
_memnotify_thread
=
this
;
os
::
set_priority
(
this
,
NearMaxPriority
);
os
::
start_thread
(
this
);
}
}
// Where all the work gets done
//
void
MemNotifyThread
::
run
()
{
assert
(
this
==
memnotify_thread
(),
"expected the singleton MemNotifyThread"
);
// Set up the select arguments
fd_set
rfds
;
if
(
_fd
!=
-
1
)
{
FD_ZERO
(
&
rfds
);
FD_SET
(
_fd
,
&
rfds
);
}
// Now wait for the mem_notify device to wake up
while
(
1
)
{
// Wait for the mem_notify device to signal us..
int
rc
=
select
(
_fd
+
1
,
_fd
!=
-
1
?
&
rfds
:
NULL
,
NULL
,
NULL
,
NULL
);
if
(
rc
==
-
1
)
{
perror
(
"select!
\n
"
);
break
;
}
else
if
(
rc
)
{
//ssize_t free_before = os::available_memory();
//tty->print ("Notified: Free: %dK \n",os::available_memory()/1024);
// The kernel is telling us there is not much memory left...
// try to do something about that
// If we are not already in a GC, try one.
if
(
!
Universe
::
heap
()
->
is_gc_active
())
{
Universe
::
heap
()
->
collect
(
GCCause
::
_allocation_failure
);
//ssize_t free_after = os::available_memory();
//tty->print ("Post-Notify: Free: %dK\n",free_after/1024);
//tty->print ("GC freed: %dK\n", (free_after - free_before)/1024);
}
// We might want to do something like the following if we find the GC's are not helping...
// Universe::heap()->size_policy()->set_gc_time_limit_exceeded(true);
}
}
}
//
// See if the /dev/mem_notify device exists, and if so, start a thread to monitor it.
//
void
MemNotifyThread
::
start
()
{
int
fd
;
fd
=
open
(
"/dev/mem_notify"
,
O_RDONLY
,
0
);
if
(
fd
<
0
)
{
return
;
}
if
(
memnotify_thread
()
==
NULL
)
{
new
MemNotifyThread
(
fd
);
}
}
#endif // JAVASE_EMBEDDED
src/os/solaris/vm/os_solaris.cpp
浏览文件 @
23a259aa
...
@@ -2317,6 +2317,10 @@ static bool check_addr0(outputStream* st) {
...
@@ -2317,6 +2317,10 @@ static bool check_addr0(outputStream* st) {
return
status
;
return
status
;
}
}
void
os
::
pd_print_cpu_info
(
outputStream
*
st
)
{
// Nothing to do for now.
}
void
os
::
print_memory_info
(
outputStream
*
st
)
{
void
os
::
print_memory_info
(
outputStream
*
st
)
{
st
->
print
(
"Memory:"
);
st
->
print
(
"Memory:"
);
st
->
print
(
" %dk page"
,
os
::
vm_page_size
()
>>
10
);
st
->
print
(
" %dk page"
,
os
::
vm_page_size
()
>>
10
);
...
...
src/os/windows/vm/os_windows.cpp
浏览文件 @
23a259aa
...
@@ -1720,6 +1720,10 @@ void os::print_os_info(outputStream* st) {
...
@@ -1720,6 +1720,10 @@ void os::print_os_info(outputStream* st) {
st
->
cr
();
st
->
cr
();
}
}
void
os
::
pd_print_cpu_info
(
outputStream
*
st
)
{
// Nothing to do for now.
}
void
os
::
print_memory_info
(
outputStream
*
st
)
{
void
os
::
print_memory_info
(
outputStream
*
st
)
{
st
->
print
(
"Memory:"
);
st
->
print
(
"Memory:"
);
st
->
print
(
" %dk page"
,
os
::
vm_page_size
()
>>
10
);
st
->
print
(
" %dk page"
,
os
::
vm_page_size
()
>>
10
);
...
...
src/os_cpu/linux_x86/vm/assembler_linux_x86.cpp
浏览文件 @
23a259aa
...
@@ -33,6 +33,28 @@ void MacroAssembler::int3() {
...
@@ -33,6 +33,28 @@ void MacroAssembler::int3() {
call
(
RuntimeAddress
(
CAST_FROM_FN_PTR
(
address
,
os
::
breakpoint
)));
call
(
RuntimeAddress
(
CAST_FROM_FN_PTR
(
address
,
os
::
breakpoint
)));
}
}
#ifdef MINIMIZE_RAM_USAGE
void
MacroAssembler
::
get_thread
(
Register
thread
)
{
// call pthread_getspecific
// void * pthread_getspecific(pthread_key_t key);
if
(
thread
!=
rax
)
push
(
rax
);
push
(
rcx
);
push
(
rdx
);
push
(
ThreadLocalStorage
::
thread_index
());
call
(
RuntimeAddress
(
CAST_FROM_FN_PTR
(
address
,
pthread_getspecific
)));
increment
(
rsp
,
wordSize
);
pop
(
rdx
);
pop
(
rcx
);
if
(
thread
!=
rax
)
{
mov
(
thread
,
rax
);
pop
(
rax
);
}
}
#else
void
MacroAssembler
::
get_thread
(
Register
thread
)
{
void
MacroAssembler
::
get_thread
(
Register
thread
)
{
movl
(
thread
,
rsp
);
movl
(
thread
,
rsp
);
shrl
(
thread
,
PAGE_SHIFT
);
shrl
(
thread
,
PAGE_SHIFT
);
...
@@ -43,6 +65,7 @@ void MacroAssembler::get_thread(Register thread) {
...
@@ -43,6 +65,7 @@ void MacroAssembler::get_thread(Register thread) {
movptr
(
thread
,
tls
);
movptr
(
thread
,
tls
);
}
}
#endif // MINIMIZE_RAM_USAGE
#else
#else
void
MacroAssembler
::
int3
()
{
void
MacroAssembler
::
int3
()
{
call
(
RuntimeAddress
(
CAST_FROM_FN_PTR
(
address
,
os
::
breakpoint
)));
call
(
RuntimeAddress
(
CAST_FROM_FN_PTR
(
address
,
os
::
breakpoint
)));
...
...
src/os_cpu/linux_x86/vm/threadLS_linux_x86.cpp
浏览文件 @
23a259aa
...
@@ -52,25 +52,20 @@
...
@@ -52,25 +52,20 @@
// MADV_DONTNEED on Linux keeps the virtual memory mapping, but zaps the
// MADV_DONTNEED on Linux keeps the virtual memory mapping, but zaps the
// physical memory page (i.e. similar to MADV_FREE on Solaris).
// physical memory page (i.e. similar to MADV_FREE on Solaris).
#if
ndef AMD64
#if
!defined(AMD64) && !defined(MINIMIZE_RAM_USAGE)
Thread
*
ThreadLocalStorage
::
_sp_map
[
1UL
<<
(
SP_BITLENGTH
-
PAGE_SHIFT
)];
Thread
*
ThreadLocalStorage
::
_sp_map
[
1UL
<<
(
SP_BITLENGTH
-
PAGE_SHIFT
)];
#endif // !AMD64
void
ThreadLocalStorage
::
generate_code_for_get_thread
()
{
void
ThreadLocalStorage
::
generate_code_for_get_thread
()
{
// nothing we can do here for user-level thread
// nothing we can do here for user-level thread
}
}
void
ThreadLocalStorage
::
pd_init
()
{
void
ThreadLocalStorage
::
pd_init
()
{
#ifndef AMD64
assert
(
align_size_down
(
os
::
vm_page_size
(),
PAGE_SIZE
)
==
os
::
vm_page_size
(),
assert
(
align_size_down
(
os
::
vm_page_size
(),
PAGE_SIZE
)
==
os
::
vm_page_size
(),
"page size must be multiple of PAGE_SIZE"
);
"page size must be multiple of PAGE_SIZE"
);
#endif // !AMD64
}
}
void
ThreadLocalStorage
::
pd_set_thread
(
Thread
*
thread
)
{
void
ThreadLocalStorage
::
pd_set_thread
(
Thread
*
thread
)
{
os
::
thread_local_storage_at_put
(
ThreadLocalStorage
::
thread_index
(),
thread
);
os
::
thread_local_storage_at_put
(
ThreadLocalStorage
::
thread_index
(),
thread
);
#ifndef AMD64
address
stack_top
=
os
::
current_stack_base
();
address
stack_top
=
os
::
current_stack_base
();
size_t
stack_size
=
os
::
current_stack_size
();
size_t
stack_size
=
os
::
current_stack_size
();
...
@@ -88,5 +83,17 @@ void ThreadLocalStorage::pd_set_thread(Thread* thread) {
...
@@ -88,5 +83,17 @@ void ThreadLocalStorage::pd_set_thread(Thread* thread) {
"thread exited without detaching from VM??"
);
"thread exited without detaching from VM??"
);
_sp_map
[(
uintptr_t
)
p
>>
PAGE_SHIFT
]
=
thread
;
_sp_map
[(
uintptr_t
)
p
>>
PAGE_SHIFT
]
=
thread
;
}
}
#endif // !AMD64
}
}
#else
void
ThreadLocalStorage
::
generate_code_for_get_thread
()
{
// nothing we can do here for user-level thread
}
void
ThreadLocalStorage
::
pd_init
()
{
}
void
ThreadLocalStorage
::
pd_set_thread
(
Thread
*
thread
)
{
os
::
thread_local_storage_at_put
(
ThreadLocalStorage
::
thread_index
(),
thread
);
}
#endif // !AMD64 && !MINIMIZE_RAM_USAGE
src/os_cpu/linux_x86/vm/threadLS_linux_x86.hpp
浏览文件 @
23a259aa
...
@@ -27,28 +27,32 @@
...
@@ -27,28 +27,32 @@
// Processor dependent parts of ThreadLocalStorage
// Processor dependent parts of ThreadLocalStorage
#ifndef AMD64
#if !defined(AMD64) && !defined(MINIMIZE_RAM_USAGE)
// map stack pointer to thread pointer - see notes in threadLS_linux_x86.cpp
// map stack pointer to thread pointer - see notes in threadLS_linux_x86.cpp
#define SP_BITLENGTH 32
#define SP_BITLENGTH 32
#define PAGE_SHIFT 12
#define PAGE_SHIFT 12
#define PAGE_SIZE (1UL << PAGE_SHIFT)
#define PAGE_SIZE (1UL << PAGE_SHIFT)
static
Thread
*
_sp_map
[
1UL
<<
(
SP_BITLENGTH
-
PAGE_SHIFT
)];
static
Thread
*
_sp_map
[
1UL
<<
(
SP_BITLENGTH
-
PAGE_SHIFT
)];
#endif // !AMD64
public
:
public
:
#ifndef AMD64
static
Thread
**
sp_map_addr
()
{
return
_sp_map
;
}
static
Thread
**
sp_map_addr
()
{
return
_sp_map
;
}
#endif // !AMD64
static
Thread
*
thread
()
{
static
Thread
*
thread
()
{
#ifdef AMD64
return
(
Thread
*
)
os
::
thread_local_storage_at
(
thread_index
());
#else
uintptr_t
sp
;
uintptr_t
sp
;
__asm__
volatile
(
"movl %%esp, %0"
:
"=r"
(
sp
));
__asm__
volatile
(
"movl %%esp, %0"
:
"=r"
(
sp
));
return
_sp_map
[
sp
>>
PAGE_SHIFT
];
return
_sp_map
[
sp
>>
PAGE_SHIFT
];
#endif // AMD64
}
}
#else
public
:
static
Thread
*
thread
()
{
return
(
Thread
*
)
os
::
thread_local_storage_at
(
thread_index
());
}
#endif // AMD64 || MINIMIZE_RAM_USAGE
#endif // OS_CPU_LINUX_X86_VM_THREADLS_LINUX_X86_HPP
#endif // OS_CPU_LINUX_X86_VM_THREADLS_LINUX_X86_HPP
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
浏览文件 @
23a259aa
...
@@ -2716,6 +2716,10 @@ void CMSCollector::gc_epilogue(bool full) {
...
@@ -2716,6 +2716,10 @@ void CMSCollector::gc_epilogue(bool full) {
bitMapLock
()
->
unlock
();
bitMapLock
()
->
unlock
();
releaseFreelistLocks
();
releaseFreelistLocks
();
if
(
!
CleanChunkPoolAsync
)
{
Chunk
::
clean_chunk_pool
();
}
_between_prologue_and_epilogue
=
false
;
// ready for next cycle
_between_prologue_and_epilogue
=
false
;
// ready for next cycle
}
}
...
...
src/share/vm/memory/defNewGeneration.cpp
浏览文件 @
23a259aa
...
@@ -905,6 +905,10 @@ void DefNewGeneration::gc_epilogue(bool full) {
...
@@ -905,6 +905,10 @@ void DefNewGeneration::gc_epilogue(bool full) {
to
()
->
check_mangled_unused_area_complete
();
to
()
->
check_mangled_unused_area_complete
();
}
}
if
(
!
CleanChunkPoolAsync
)
{
Chunk
::
clean_chunk_pool
();
}
// update the generation and space performance counters
// update the generation and space performance counters
update_counters
();
update_counters
();
gch
->
collector_policy
()
->
counters
()
->
update_counters
();
gch
->
collector_policy
()
->
counters
()
->
update_counters
();
...
...
src/share/vm/memory/genCollectedHeap.cpp
浏览文件 @
23a259aa
...
@@ -1384,6 +1384,10 @@ void GenCollectedHeap::gc_epilogue(bool full) {
...
@@ -1384,6 +1384,10 @@ void GenCollectedHeap::gc_epilogue(bool full) {
generation_iterate
(
&
blk
,
false
);
// not old-to-young.
generation_iterate
(
&
blk
,
false
);
// not old-to-young.
perm_gen
()
->
gc_epilogue
(
full
);
perm_gen
()
->
gc_epilogue
(
full
);
if
(
!
CleanChunkPoolAsync
)
{
Chunk
::
clean_chunk_pool
();
}
always_do_update_barrier
=
UseConcMarkSweepGC
;
always_do_update_barrier
=
UseConcMarkSweepGC
;
};
};
...
...
src/share/vm/opto/lcm.cpp
浏览文件 @
23a259aa
...
@@ -45,6 +45,9 @@
...
@@ -45,6 +45,9 @@
#ifdef TARGET_ARCH_MODEL_arm
#ifdef TARGET_ARCH_MODEL_arm
# include "adfiles/ad_arm.hpp"
# include "adfiles/ad_arm.hpp"
#endif
#endif
#ifdef TARGET_ARCH_MODEL_ppc
# include "adfiles/ad_ppc.hpp"
#endif
// Optimization - Graph Style
// Optimization - Graph Style
...
...
src/share/vm/opto/matcher.cpp
浏览文件 @
23a259aa
...
@@ -52,6 +52,9 @@
...
@@ -52,6 +52,9 @@
#ifdef TARGET_ARCH_MODEL_arm
#ifdef TARGET_ARCH_MODEL_arm
# include "adfiles/ad_arm.hpp"
# include "adfiles/ad_arm.hpp"
#endif
#endif
#ifdef TARGET_ARCH_MODEL_ppc
# include "adfiles/ad_ppc.hpp"
#endif
OptoReg
::
Name
OptoReg
::
c_frame_pointer
;
OptoReg
::
Name
OptoReg
::
c_frame_pointer
;
...
...
src/share/vm/prims/jni.cpp
浏览文件 @
23a259aa
...
@@ -70,15 +70,6 @@
...
@@ -70,15 +70,6 @@
#include "utilities/dtrace.hpp"
#include "utilities/dtrace.hpp"
#include "utilities/events.hpp"
#include "utilities/events.hpp"
#include "utilities/histogram.hpp"
#include "utilities/histogram.hpp"
#ifdef TARGET_ARCH_x86
# include "jniTypes_x86.hpp"
#endif
#ifdef TARGET_ARCH_sparc
# include "jniTypes_sparc.hpp"
#endif
#ifdef TARGET_ARCH_zero
# include "jniTypes_zero.hpp"
#endif
#ifdef TARGET_OS_FAMILY_linux
#ifdef TARGET_OS_FAMILY_linux
# include "os_linux.inline.hpp"
# include "os_linux.inline.hpp"
# include "thread_linux.inline.hpp"
# include "thread_linux.inline.hpp"
...
...
src/share/vm/runtime/arguments.cpp
浏览文件 @
23a259aa
...
@@ -37,15 +37,6 @@
...
@@ -37,15 +37,6 @@
#include "services/management.hpp"
#include "services/management.hpp"
#include "utilities/defaultStream.hpp"
#include "utilities/defaultStream.hpp"
#include "utilities/taskqueue.hpp"
#include "utilities/taskqueue.hpp"
#ifdef TARGET_ARCH_x86
# include "vm_version_x86.hpp"
#endif
#ifdef TARGET_ARCH_sparc
# include "vm_version_sparc.hpp"
#endif
#ifdef TARGET_ARCH_zero
# include "vm_version_zero.hpp"
#endif
#ifdef TARGET_OS_FAMILY_linux
#ifdef TARGET_OS_FAMILY_linux
# include "os_linux.inline.hpp"
# include "os_linux.inline.hpp"
#endif
#endif
...
@@ -251,6 +242,11 @@ static ObsoleteFlag obsolete_jvm_flags[] = {
...
@@ -251,6 +242,11 @@ static ObsoleteFlag obsolete_jvm_flags[] = {
{
"UseParallelOldGCDensePrefix"
,
{
"UseParallelOldGCDensePrefix"
,
JDK_Version
::
jdk_update
(
6
,
27
),
JDK_Version
::
jdk
(
8
)
},
JDK_Version
::
jdk_update
(
6
,
27
),
JDK_Version
::
jdk
(
8
)
},
{
"AllowTransitionalJSR292"
,
JDK_Version
::
jdk
(
7
),
JDK_Version
::
jdk
(
8
)
},
{
"AllowTransitionalJSR292"
,
JDK_Version
::
jdk
(
7
),
JDK_Version
::
jdk
(
8
)
},
{
"UseCompressedStrings"
,
JDK_Version
::
jdk
(
7
),
JDK_Version
::
jdk
(
8
)
},
#ifdef PRODUCT
{
"DesiredMethodLimit"
,
JDK_Version
::
jdk_update
(
7
,
2
),
JDK_Version
::
jdk
(
8
)
},
#endif // PRODUCT
{
NULL
,
JDK_Version
(
0
),
JDK_Version
(
0
)
}
{
NULL
,
JDK_Version
(
0
),
JDK_Version
(
0
)
}
};
};
...
@@ -2912,6 +2908,18 @@ void Arguments::set_shared_spaces_flags() {
...
@@ -2912,6 +2908,18 @@ void Arguments::set_shared_spaces_flags() {
}
}
}
}
// Disable options not supported in this release, with a warning if they
// were explicitly requested on the command-line
#define UNSUPPORTED_OPTION(opt, description) \
do { \
if (opt) { \
if (FLAG_IS_CMDLINE(opt)) { \
warning(description " is disabled in this release."); \
} \
FLAG_SET_DEFAULT(opt, false); \
} \
} while(0)
// Parse entry point called from JNI_CreateJavaVM
// Parse entry point called from JNI_CreateJavaVM
jint
Arguments
::
parse
(
const
JavaVMInitArgs
*
args
)
{
jint
Arguments
::
parse
(
const
JavaVMInitArgs
*
args
)
{
...
@@ -3009,6 +3017,13 @@ jint Arguments::parse(const JavaVMInitArgs* args) {
...
@@ -3009,6 +3017,13 @@ jint Arguments::parse(const JavaVMInitArgs* args) {
return
result
;
return
result
;
}
}
#ifdef JAVASE_EMBEDDED
#ifdef PPC
UNSUPPORTED_OPTION
(
EnableInvokeDynamic
,
"Invoke dynamic"
);
#endif
UNSUPPORTED_OPTION
(
UseG1GC
,
"G1 GC"
);
#endif
#ifndef PRODUCT
#ifndef PRODUCT
if
(
TraceBytecodesAt
!=
0
)
{
if
(
TraceBytecodesAt
!=
0
)
{
TraceBytecodes
=
true
;
TraceBytecodes
=
true
;
...
...
src/share/vm/runtime/atomic.cpp
浏览文件 @
23a259aa
...
@@ -51,6 +51,12 @@
...
@@ -51,6 +51,12 @@
#ifdef TARGET_OS_ARCH_windows_x86
#ifdef TARGET_OS_ARCH_windows_x86
# include "atomic_windows_x86.inline.hpp"
# include "atomic_windows_x86.inline.hpp"
#endif
#endif
#ifdef TARGET_OS_ARCH_linux_arm
# include "atomic_linux_arm.inline.hpp"
#endif
#ifdef TARGET_OS_ARCH_linux_ppc
# include "atomic_linux_ppc.inline.hpp"
#endif
jbyte
Atomic
::
cmpxchg
(
jbyte
exchange_value
,
volatile
jbyte
*
dest
,
jbyte
compare_value
)
{
jbyte
Atomic
::
cmpxchg
(
jbyte
exchange_value
,
volatile
jbyte
*
dest
,
jbyte
compare_value
)
{
assert
(
sizeof
(
jbyte
)
==
1
,
"assumption."
);
assert
(
sizeof
(
jbyte
)
==
1
,
"assumption."
);
...
...
src/share/vm/runtime/globals.hpp
浏览文件 @
23a259aa
...
@@ -343,6 +343,12 @@ class CommandLineFlags {
...
@@ -343,6 +343,12 @@ class CommandLineFlags {
#define falseInTiered true
#define falseInTiered true
#endif
#endif
#ifdef JAVASE_EMBEDDED
#define falseInEmbedded false
#else
#define falseInEmbedded true
#endif
// develop flags are settable / visible only during development and are constant in the PRODUCT version
// develop flags are settable / visible only during development and are constant in the PRODUCT version
// product flags are always settable / visible
// product flags are always settable / visible
// notproduct flags are settable / visible only during development and are not declared in the PRODUCT version
// notproduct flags are settable / visible only during development and are not declared in the PRODUCT version
...
@@ -438,6 +444,9 @@ class CommandLineFlags {
...
@@ -438,6 +444,9 @@ class CommandLineFlags {
product(bool, UsePPCLWSYNC, true, \
product(bool, UsePPCLWSYNC, true, \
"Use lwsync instruction if true, else use slower sync") \
"Use lwsync instruction if true, else use slower sync") \
\
\
develop(bool, CleanChunkPoolAsync, falseInEmbedded, \
"Whether to clean the chunk pool asynchronously") \
\
/* Temporary: See 6948537 */
\
/* Temporary: See 6948537 */
\
experimental(bool, UseMemSetInBOT, true, \
experimental(bool, UseMemSetInBOT, true, \
"(Unstable) uses memset in BOT updates in GC code") \
"(Unstable) uses memset in BOT updates in GC code") \
...
@@ -3611,13 +3620,9 @@ class CommandLineFlags {
...
@@ -3611,13 +3620,9 @@ class CommandLineFlags {
\
\
/* flags for performance data collection */
\
/* flags for performance data collection */
\
\
\
NOT_EMBEDDED(product(bool, UsePerfData, true, \
product(bool, UsePerfData, falseInEmbedded, \
"Flag to disable jvmstat instrumentation for performance testing" \
"and problem isolation purposes.")) \
\
EMBEDDED_ONLY(product(bool, UsePerfData, false, \
"Flag to disable jvmstat instrumentation for performance testing" \
"Flag to disable jvmstat instrumentation for performance testing" \
"and problem isolation purposes.")
)
\
"and problem isolation purposes.")
\
\
\
product(bool, PerfDataSaveToFile, false, \
product(bool, PerfDataSaveToFile, false, \
"Save PerfData memory to hsperfdata_<pid> file on exit") \
"Save PerfData memory to hsperfdata_<pid> file on exit") \
...
...
src/share/vm/runtime/os.cpp
浏览文件 @
23a259aa
...
@@ -761,6 +761,7 @@ void os::print_cpu_info(outputStream* st) {
...
@@ -761,6 +761,7 @@ void os::print_cpu_info(outputStream* st) {
// st->print("(active %d)", os::active_processor_count());
// st->print("(active %d)", os::active_processor_count());
st
->
print
(
" %s"
,
VM_Version
::
cpu_features
());
st
->
print
(
" %s"
,
VM_Version
::
cpu_features
());
st
->
cr
();
st
->
cr
();
pd_print_cpu_info
(
st
);
}
}
void
os
::
print_date_and_time
(
outputStream
*
st
)
{
void
os
::
print_date_and_time
(
outputStream
*
st
)
{
...
...
src/share/vm/runtime/os.hpp
浏览文件 @
23a259aa
...
@@ -480,6 +480,7 @@ class os: AllStatic {
...
@@ -480,6 +480,7 @@ class os: AllStatic {
// Output format may be different on different platforms.
// Output format may be different on different platforms.
static
void
print_os_info
(
outputStream
*
st
);
static
void
print_os_info
(
outputStream
*
st
);
static
void
print_cpu_info
(
outputStream
*
st
);
static
void
print_cpu_info
(
outputStream
*
st
);
static
void
pd_print_cpu_info
(
outputStream
*
st
);
static
void
print_memory_info
(
outputStream
*
st
);
static
void
print_memory_info
(
outputStream
*
st
);
static
void
print_dll_info
(
outputStream
*
st
);
static
void
print_dll_info
(
outputStream
*
st
);
static
void
print_environment_variables
(
outputStream
*
st
,
const
char
**
env_list
,
char
*
buffer
,
int
len
);
static
void
print_environment_variables
(
outputStream
*
st
,
const
char
**
env_list
,
char
*
buffer
,
int
len
);
...
...
src/share/vm/runtime/thread.cpp
浏览文件 @
23a259aa
...
@@ -3347,7 +3347,9 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
...
@@ -3347,7 +3347,9 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
// Notify JVMTI agents that VM initialization is complete - nop if no agents.
// Notify JVMTI agents that VM initialization is complete - nop if no agents.
JvmtiExport
::
post_vm_initialized
();
JvmtiExport
::
post_vm_initialized
();
Chunk
::
start_chunk_pool_cleaner_task
();
if
(
CleanChunkPoolAsync
)
{
Chunk
::
start_chunk_pool_cleaner_task
();
}
// initialize compiler(s)
// initialize compiler(s)
CompileBroker
::
compilation_init
();
CompileBroker
::
compilation_init
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录