Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell11
提交
5c895b44
D
dragonwell11
项目概览
openanolis
/
dragonwell11
通知
7
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell11
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
5c895b44
编写于
2月 18, 2014
作者:
S
sla
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8034080: Remove the USDT1 dtrace code from Hotspot
Reviewed-by: dholmes, coleenp
上级
5fb0537b
变更
19
展开全部
隐藏空白更改
内联
并排
Showing
19 changed file
with
86 addition
and
1801 deletion
+86
-1801
hotspot/src/share/vm/code/nmethod.cpp
hotspot/src/share/vm/code/nmethod.cpp
+0
-33
hotspot/src/share/vm/compiler/compileBroker.cpp
hotspot/src/share/vm/compiler/compileBroker.cpp
+0
-33
hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/vmCMSOperations.cpp
...gc_implementation/concurrentMarkSweep/vmCMSOperations.cpp
+0
-24
hotspot/src/share/vm/gc_implementation/shared/vmGCOperations.cpp
.../src/share/vm/gc_implementation/shared/vmGCOperations.cpp
+0
-15
hotspot/src/share/vm/oops/instanceKlass.cpp
hotspot/src/share/vm/oops/instanceKlass.cpp
+0
-46
hotspot/src/share/vm/prims/jni.cpp
hotspot/src/share/vm/prims/jni.cpp
+73
-1242
hotspot/src/share/vm/prims/jvm.cpp
hotspot/src/share/vm/prims/jvm.cpp
+5
-28
hotspot/src/share/vm/prims/unsafe.cpp
hotspot/src/share/vm/prims/unsafe.cpp
+5
-23
hotspot/src/share/vm/runtime/java.cpp
hotspot/src/share/vm/runtime/java.cpp
+0
-8
hotspot/src/share/vm/runtime/objectMonitor.cpp
hotspot/src/share/vm/runtime/objectMonitor.cpp
+0
-34
hotspot/src/share/vm/runtime/sharedRuntime.cpp
hotspot/src/share/vm/runtime/sharedRuntime.cpp
+0
-27
hotspot/src/share/vm/runtime/synchronizer.cpp
hotspot/src/share/vm/runtime/synchronizer.cpp
+0
-27
hotspot/src/share/vm/runtime/thread.cpp
hotspot/src/share/vm/runtime/thread.cpp
+0
-33
hotspot/src/share/vm/runtime/vmThread.cpp
hotspot/src/share/vm/runtime/vmThread.cpp
+0
-21
hotspot/src/share/vm/services/classLoadingService.cpp
hotspot/src/share/vm/services/classLoadingService.cpp
+0
-21
hotspot/src/share/vm/services/memoryManager.cpp
hotspot/src/share/vm/services/memoryManager.cpp
+0
-23
hotspot/src/share/vm/services/runtimeService.cpp
hotspot/src/share/vm/services/runtimeService.cpp
+0
-13
hotspot/src/share/vm/utilities/dtrace.hpp
hotspot/src/share/vm/utilities/dtrace.hpp
+1
-142
hotspot/src/share/vm/utilities/dtrace_disabled.hpp
hotspot/src/share/vm/utilities/dtrace_disabled.hpp
+2
-8
未找到文件。
hotspot/src/share/vm/code/nmethod.cpp
浏览文件 @
5c895b44
...
...
@@ -50,27 +50,6 @@
// Only bother with this argument setup if dtrace is available
#ifndef USDT2
HS_DTRACE_PROBE_DECL8
(
hotspot
,
compiled__method__load
,
const
char
*
,
int
,
const
char
*
,
int
,
const
char
*
,
int
,
void
*
,
size_t
);
HS_DTRACE_PROBE_DECL6
(
hotspot
,
compiled__method__unload
,
char
*
,
int
,
char
*
,
int
,
char
*
,
int
);
#define DTRACE_METHOD_UNLOAD_PROBE(method) \
{ \
Method* m = (method); \
if (m != NULL) { \
Symbol* klass_name = m->klass_name(); \
Symbol* name = m->name(); \
Symbol* signature = m->signature(); \
HS_DTRACE_PROBE6(hotspot, compiled__method__unload, \
klass_name->bytes(), klass_name->utf8_length(), \
name->bytes(), name->utf8_length(), \
signature->bytes(), signature->utf8_length()); \
} \
}
#else
/* USDT2 */
#define DTRACE_METHOD_UNLOAD_PROBE(method) \
{ \
Method* m = (method); \
...
...
@@ -84,7 +63,6 @@ HS_DTRACE_PROBE_DECL6(hotspot, compiled__method__unload,
(char *) signature->bytes(), signature->utf8_length()); \
} \
}
#endif
/* USDT2 */
#else // ndef DTRACE_ENABLED
...
...
@@ -1520,16 +1498,6 @@ bool nmethod::can_unload(BoolObjectClosure* is_alive, oop* root, bool unloading_
void
nmethod
::
post_compiled_method_load_event
()
{
Method
*
moop
=
method
();
#ifndef USDT2
HS_DTRACE_PROBE8
(
hotspot
,
compiled__method__load
,
moop
->
klass_name
()
->
bytes
(),
moop
->
klass_name
()
->
utf8_length
(),
moop
->
name
()
->
bytes
(),
moop
->
name
()
->
utf8_length
(),
moop
->
signature
()
->
bytes
(),
moop
->
signature
()
->
utf8_length
(),
insts_begin
(),
insts_size
());
#else
/* USDT2 */
HOTSPOT_COMPILED_METHOD_LOAD
(
(
char
*
)
moop
->
klass_name
()
->
bytes
(),
moop
->
klass_name
()
->
utf8_length
(),
...
...
@@ -1538,7 +1506,6 @@ void nmethod::post_compiled_method_load_event() {
(
char
*
)
moop
->
signature
()
->
bytes
(),
moop
->
signature
()
->
utf8_length
(),
insts_begin
(),
insts_size
());
#endif
/* USDT2 */
if
(
JvmtiExport
::
should_post_compiled_method_load
()
||
JvmtiExport
::
should_post_compiled_method_unload
())
{
...
...
hotspot/src/share/vm/compiler/compileBroker.cpp
浏览文件 @
5c895b44
...
...
@@ -60,38 +60,6 @@
// Only bother with this argument setup if dtrace is available
#ifndef USDT2
HS_DTRACE_PROBE_DECL8
(
hotspot
,
method__compile__begin
,
char
*
,
intptr_t
,
char
*
,
intptr_t
,
char
*
,
intptr_t
,
char
*
,
intptr_t
);
HS_DTRACE_PROBE_DECL9
(
hotspot
,
method__compile__end
,
char
*
,
intptr_t
,
char
*
,
intptr_t
,
char
*
,
intptr_t
,
char
*
,
intptr_t
,
bool
);
#define DTRACE_METHOD_COMPILE_BEGIN_PROBE(method, comp_name) \
{ \
Symbol* klass_name = (method)->klass_name(); \
Symbol* name = (method)->name(); \
Symbol* signature = (method)->signature(); \
HS_DTRACE_PROBE8(hotspot, method__compile__begin, \
comp_name, strlen(comp_name), \
klass_name->bytes(), klass_name->utf8_length(), \
name->bytes(), name->utf8_length(), \
signature->bytes(), signature->utf8_length()); \
}
#define DTRACE_METHOD_COMPILE_END_PROBE(method, comp_name, success) \
{ \
Symbol* klass_name = (method)->klass_name(); \
Symbol* name = (method)->name(); \
Symbol* signature = (method)->signature(); \
HS_DTRACE_PROBE9(hotspot, method__compile__end, \
comp_name, strlen(comp_name), \
klass_name->bytes(), klass_name->utf8_length(), \
name->bytes(), name->utf8_length(), \
signature->bytes(), signature->utf8_length(), (success)); \
}
#else
/* USDT2 */
#define DTRACE_METHOD_COMPILE_BEGIN_PROBE(method, comp_name) \
{ \
Symbol* klass_name = (method)->klass_name(); \
...
...
@@ -115,7 +83,6 @@ HS_DTRACE_PROBE_DECL9(hotspot, method__compile__end,
(char *) name->bytes(), name->utf8_length(), \
(char *) signature->bytes(), signature->utf8_length(), (success)); \
}
#endif
/* USDT2 */
#else // ndef DTRACE_ENABLED
...
...
hotspot/src/share/vm/gc_implementation/concurrentMarkSweep/vmCMSOperations.cpp
浏览文件 @
5c895b44
...
...
@@ -35,14 +35,6 @@
#include "utilities/dtrace.hpp"
#ifndef USDT2
HS_DTRACE_PROBE_DECL
(
hs_private
,
cms__initmark__begin
);
HS_DTRACE_PROBE_DECL
(
hs_private
,
cms__initmark__end
);
HS_DTRACE_PROBE_DECL
(
hs_private
,
cms__remark__begin
);
HS_DTRACE_PROBE_DECL
(
hs_private
,
cms__remark__end
);
#endif
/* !USDT2 */
//////////////////////////////////////////////////////////
// Methods in abstract class VM_CMS_Operation
//////////////////////////////////////////////////////////
...
...
@@ -138,11 +130,7 @@ void VM_CMS_Initial_Mark::doit() {
// Nothing to do.
return
;
}
#ifndef USDT2
HS_DTRACE_PROBE
(
hs_private
,
cms__initmark__begin
);
#else
/* USDT2 */
HS_PRIVATE_CMS_INITMARK_BEGIN
();
#endif
/* USDT2 */
_collector
->
_gc_timer_cm
->
register_gc_pause_start
(
"Initial Mark"
);
...
...
@@ -158,11 +146,7 @@ void VM_CMS_Initial_Mark::doit() {
_collector
->
_gc_timer_cm
->
register_gc_pause_end
();
#ifndef USDT2
HS_DTRACE_PROBE
(
hs_private
,
cms__initmark__end
);
#else
/* USDT2 */
HS_PRIVATE_CMS_INITMARK_END
();
#endif
/* USDT2 */
}
//////////////////////////////////////////////////////////
...
...
@@ -173,11 +157,7 @@ void VM_CMS_Final_Remark::doit() {
// Nothing to do.
return
;
}
#ifndef USDT2
HS_DTRACE_PROBE
(
hs_private
,
cms__remark__begin
);
#else
/* USDT2 */
HS_PRIVATE_CMS_REMARK_BEGIN
();
#endif
/* USDT2 */
_collector
->
_gc_timer_cm
->
register_gc_pause_start
(
"Final Mark"
);
...
...
@@ -194,11 +174,7 @@ void VM_CMS_Final_Remark::doit() {
_collector
->
save_heap_summary
();
_collector
->
_gc_timer_cm
->
register_gc_pause_end
();
#ifndef USDT2
HS_DTRACE_PROBE
(
hs_private
,
cms__remark__end
);
#else
/* USDT2 */
HS_PRIVATE_CMS_REMARK_END
();
#endif
/* USDT2 */
}
// VM operation to invoke a concurrent collection of a
...
...
hotspot/src/share/vm/gc_implementation/shared/vmGCOperations.cpp
浏览文件 @
5c895b44
...
...
@@ -41,33 +41,18 @@
#include "gc_implementation/g1/g1CollectedHeap.inline.hpp"
#endif // INCLUDE_ALL_GCS
#ifndef USDT2
HS_DTRACE_PROBE_DECL1
(
hotspot
,
gc__begin
,
bool
);
HS_DTRACE_PROBE_DECL
(
hotspot
,
gc__end
);
#endif
/* !USDT2 */
// The same dtrace probe can't be inserted in two different files, so we
// have to call it here, so it's only in one file. Can't create new probes
// for the other file anymore. The dtrace probes have to remain stable.
void
VM_GC_Operation
::
notify_gc_begin
(
bool
full
)
{
#ifndef USDT2
HS_DTRACE_PROBE1
(
hotspot
,
gc__begin
,
full
);
HS_DTRACE_WORKAROUND_TAIL_CALL_BUG
();
#else
/* USDT2 */
HOTSPOT_GC_BEGIN
(
full
);
HS_DTRACE_WORKAROUND_TAIL_CALL_BUG
();
#endif
/* USDT2 */
}
void
VM_GC_Operation
::
notify_gc_end
()
{
#ifndef USDT2
HS_DTRACE_PROBE
(
hotspot
,
gc__end
);
HS_DTRACE_WORKAROUND_TAIL_CALL_BUG
();
#else
/* USDT2 */
HOTSPOT_GC_END
();
HS_DTRACE_WORKAROUND_TAIL_CALL_BUG
();
#endif
/* USDT2 */
}
void
VM_GC_Operation
::
acquire_pending_list_lock
()
{
...
...
hotspot/src/share/vm/oops/instanceKlass.cpp
浏览文件 @
5c895b44
...
...
@@ -77,51 +77,6 @@
#ifdef DTRACE_ENABLED
#ifndef USDT2
HS_DTRACE_PROBE_DECL4
(
hotspot
,
class__initialization__required
,
char
*
,
intptr_t
,
oop
,
intptr_t
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
class__initialization__recursive
,
char
*
,
intptr_t
,
oop
,
intptr_t
,
int
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
class__initialization__concurrent
,
char
*
,
intptr_t
,
oop
,
intptr_t
,
int
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
class__initialization__erroneous
,
char
*
,
intptr_t
,
oop
,
intptr_t
,
int
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
class__initialization__super__failed
,
char
*
,
intptr_t
,
oop
,
intptr_t
,
int
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
class__initialization__clinit
,
char
*
,
intptr_t
,
oop
,
intptr_t
,
int
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
class__initialization__error
,
char
*
,
intptr_t
,
oop
,
intptr_t
,
int
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
class__initialization__end
,
char
*
,
intptr_t
,
oop
,
intptr_t
,
int
);
#define DTRACE_CLASSINIT_PROBE(type, clss, thread_type) \
{ \
char* data = NULL; \
int len = 0; \
Symbol* name = (clss)->name(); \
if (name != NULL) { \
data = (char*)name->bytes(); \
len = name->utf8_length(); \
} \
HS_DTRACE_PROBE4(hotspot, class__initialization__##type, \
data, len, SOLARIS_ONLY((void *))(clss)->class_loader(), thread_type); \
}
#define DTRACE_CLASSINIT_PROBE_WAIT(type, clss, thread_type, wait) \
{ \
char* data = NULL; \
int len = 0; \
Symbol* name = (clss)->name(); \
if (name != NULL) { \
data = (char*)name->bytes(); \
len = name->utf8_length(); \
} \
HS_DTRACE_PROBE5(hotspot, class__initialization__##type, \
data, len, SOLARIS_ONLY((void *))(clss)->class_loader(), thread_type, wait); \
}
#else
/* USDT2 */
#define HOTSPOT_CLASS_INITIALIZATION_required HOTSPOT_CLASS_INITIALIZATION_REQUIRED
#define HOTSPOT_CLASS_INITIALIZATION_recursive HOTSPOT_CLASS_INITIALIZATION_RECURSIVE
...
...
@@ -156,7 +111,6 @@ HS_DTRACE_PROBE_DECL5(hotspot, class__initialization__end,
HOTSPOT_CLASS_INITIALIZATION_##type( \
data, len, (clss)->class_loader(), thread_type, wait); \
}
#endif
/* USDT2 */
#else // ndef DTRACE_ENABLED
...
...
hotspot/src/share/vm/prims/jni.cpp
浏览文件 @
5c895b44
此差异已折叠。
点击以展开。
hotspot/src/share/vm/prims/jvm.cpp
浏览文件 @
5c895b44
...
...
@@ -82,12 +82,6 @@
#include <errno.h>
#ifndef USDT2
HS_DTRACE_PROBE_DECL1
(
hotspot
,
thread__sleep__begin
,
long
long
);
HS_DTRACE_PROBE_DECL1
(
hotspot
,
thread__sleep__end
,
int
);
HS_DTRACE_PROBE_DECL0
(
hotspot
,
thread__yield
);
#endif
/* !USDT2 */
/*
NOTE about use of any ctor or function call that can trigger a safepoint/GC:
such ctors and calls MUST NOT come between an oop declaration/init and its
...
...
@@ -3008,11 +3002,8 @@ JVM_END
JVM_ENTRY
(
void
,
JVM_Yield
(
JNIEnv
*
env
,
jclass
threadClass
))
JVMWrapper
(
"JVM_Yield"
);
if
(
os
::
dont_yield
())
return
;
#ifndef USDT2
HS_DTRACE_PROBE0
(
hotspot
,
thread__yield
);
#else
/* USDT2 */
HOTSPOT_THREAD_YIELD
();
#endif
/* USDT2 */
// When ConvertYieldToSleep is off (default), this matches the classic VM use of yield.
// Critical for similar threading behaviour
if
(
ConvertYieldToSleep
)
{
...
...
@@ -3038,12 +3029,7 @@ JVM_ENTRY(void, JVM_Sleep(JNIEnv* env, jclass threadClass, jlong millis))
// And set new thread state to SLEEPING.
JavaThreadSleepState
jtss
(
thread
);
#ifndef USDT2
HS_DTRACE_PROBE1
(
hotspot
,
thread__sleep__begin
,
millis
);
#else
/* USDT2 */
HOTSPOT_THREAD_SLEEP_BEGIN
(
millis
);
#endif
/* USDT2 */
HOTSPOT_THREAD_SLEEP_BEGIN
(
millis
);
EventThreadSleep
event
;
...
...
@@ -3071,12 +3057,8 @@ JVM_ENTRY(void, JVM_Sleep(JNIEnv* env, jclass threadClass, jlong millis))
event
.
set_time
(
millis
);
event
.
commit
();
}
#ifndef USDT2
HS_DTRACE_PROBE1
(
hotspot
,
thread__sleep__end
,
1
);
#else
/* USDT2 */
HOTSPOT_THREAD_SLEEP_END
(
1
);
#endif
/* USDT2 */
HOTSPOT_THREAD_SLEEP_END
(
1
);
// TODO-FIXME: THROW_MSG returns which means we will not call set_state()
// to properly restore the thread state. That's likely wrong.
THROW_MSG
(
vmSymbols
::
java_lang_InterruptedException
(),
"sleep interrupted"
);
...
...
@@ -3088,12 +3070,7 @@ JVM_ENTRY(void, JVM_Sleep(JNIEnv* env, jclass threadClass, jlong millis))
event
.
set_time
(
millis
);
event
.
commit
();
}
#ifndef USDT2
HS_DTRACE_PROBE1
(
hotspot
,
thread__sleep__end
,
0
);
#else
/* USDT2 */
HOTSPOT_THREAD_SLEEP_END
(
0
);
#endif
/* USDT2 */
HOTSPOT_THREAD_SLEEP_END
(
0
);
JVM_END
JVM_ENTRY
(
jobject
,
JVM_CurrentThread
(
JNIEnv
*
env
,
jclass
threadClass
))
...
...
hotspot/src/share/vm/prims/unsafe.cpp
浏览文件 @
5c895b44
...
...
@@ -44,11 +44,6 @@
* Implementation of class sun.misc.Unsafe
*/
#ifndef USDT2
HS_DTRACE_PROBE_DECL3
(
hotspot
,
thread__park__begin
,
uintptr_t
,
int
,
long
long
);
HS_DTRACE_PROBE_DECL1
(
hotspot
,
thread__park__end
,
uintptr_t
);
HS_DTRACE_PROBE_DECL1
(
hotspot
,
thread__unpark
,
uintptr_t
);
#endif
/* !USDT2 */
#define MAX_OBJECT_SIZE \
( arrayOopDesc::header_size(T_DOUBLE) * HeapWordSize \
...
...
@@ -1211,20 +1206,12 @@ UNSAFE_END
UNSAFE_ENTRY
(
void
,
Unsafe_Park
(
JNIEnv
*
env
,
jobject
unsafe
,
jboolean
isAbsolute
,
jlong
time
))
UnsafeWrapper
(
"Unsafe_Park"
);
EventThreadPark
event
;
#ifndef USDT2
HS_DTRACE_PROBE3
(
hotspot
,
thread__park__begin
,
thread
->
parker
(),
(
int
)
isAbsolute
,
time
);
#else
/* USDT2 */
HOTSPOT_THREAD_PARK_BEGIN
(
(
uintptr_t
)
thread
->
parker
(),
(
int
)
isAbsolute
,
time
);
#endif
/* USDT2 */
HOTSPOT_THREAD_PARK_BEGIN
((
uintptr_t
)
thread
->
parker
(),
(
int
)
isAbsolute
,
time
);
JavaThreadParkedState
jtps
(
thread
,
time
!=
0
);
thread
->
parker
()
->
park
(
isAbsolute
!=
0
,
time
);
#ifndef USDT2
HS_DTRACE_PROBE1
(
hotspot
,
thread__park__end
,
thread
->
parker
());
#else
/* USDT2 */
HOTSPOT_THREAD_PARK_END
(
(
uintptr_t
)
thread
->
parker
());
#endif
/* USDT2 */
HOTSPOT_THREAD_PARK_END
((
uintptr_t
)
thread
->
parker
());
if
(
event
.
should_commit
())
{
oop
obj
=
thread
->
current_park_blocker
();
event
.
set_klass
((
obj
!=
NULL
)
?
obj
->
klass
()
:
NULL
);
...
...
@@ -1263,12 +1250,7 @@ UNSAFE_ENTRY(void, Unsafe_Unpark(JNIEnv *env, jobject unsafe, jobject jthread))
}
}
if
(
p
!=
NULL
)
{
#ifndef USDT2
HS_DTRACE_PROBE1
(
hotspot
,
thread__unpark
,
p
);
#else
/* USDT2 */
HOTSPOT_THREAD_UNPARK
(
(
uintptr_t
)
p
);
#endif
/* USDT2 */
HOTSPOT_THREAD_UNPARK
((
uintptr_t
)
p
);
p
->
unpark
();
}
UNSAFE_END
...
...
hotspot/src/share/vm/runtime/java.cpp
浏览文件 @
5c895b44
...
...
@@ -97,9 +97,6 @@
#include "opto/runtime.hpp"
#endif
#ifndef USDT2
HS_DTRACE_PROBE_DECL
(
hotspot
,
vm__shutdown
);
#endif
/* !USDT2 */
#ifndef PRODUCT
...
...
@@ -603,13 +600,8 @@ void vm_exit(int code) {
void
notify_vm_shutdown
()
{
// For now, just a dtrace probe.
#ifndef USDT2
HS_DTRACE_PROBE
(
hotspot
,
vm__shutdown
);
HS_DTRACE_WORKAROUND_TAIL_CALL_BUG
();
#else
/* USDT2 */
HOTSPOT_VM_SHUTDOWN
();
HS_DTRACE_WORKAROUND_TAIL_CALL_BUG
();
#endif
/* USDT2 */
}
void
vm_direct_exit
(
int
code
)
{
...
...
hotspot/src/share/vm/runtime/objectMonitor.cpp
浏览文件 @
5c895b44
...
...
@@ -78,39 +78,6 @@
len = klassname->utf8_length(); \
}
#ifndef USDT2
HS_DTRACE_PROBE_DECL4
(
hotspot
,
monitor__notify
,
jlong
,
uintptr_t
,
char
*
,
int
);
HS_DTRACE_PROBE_DECL4
(
hotspot
,
monitor__notifyAll
,
jlong
,
uintptr_t
,
char
*
,
int
);
HS_DTRACE_PROBE_DECL4
(
hotspot
,
monitor__contended__enter
,
jlong
,
uintptr_t
,
char
*
,
int
);
HS_DTRACE_PROBE_DECL4
(
hotspot
,
monitor__contended__entered
,
jlong
,
uintptr_t
,
char
*
,
int
);
HS_DTRACE_PROBE_DECL4
(
hotspot
,
monitor__contended__exit
,
jlong
,
uintptr_t
,
char
*
,
int
);
#define DTRACE_MONITOR_WAIT_PROBE(monitor, obj, thread, millis) \
{ \
if (DTraceMonitorProbes) { \
DTRACE_MONITOR_PROBE_COMMON(obj, thread); \
HS_DTRACE_PROBE5(hotspot, monitor__wait, jtid, \
(monitor), bytes, len, (millis)); \
} \
}
#define DTRACE_MONITOR_PROBE(probe, monitor, obj, thread) \
{ \
if (DTraceMonitorProbes) { \
DTRACE_MONITOR_PROBE_COMMON(obj, thread); \
HS_DTRACE_PROBE4(hotspot, monitor__##probe, jtid, \
(uintptr_t)(monitor), bytes, len); \
} \
}
#else
/* USDT2 */
#define DTRACE_MONITOR_WAIT_PROBE(monitor, obj, thread, millis) \
{ \
if (DTraceMonitorProbes) { \
...
...
@@ -135,7 +102,6 @@ HS_DTRACE_PROBE_DECL4(hotspot, monitor__contended__exit,
} \
}
#endif
/* USDT2 */
#else // ndef DTRACE_ENABLED
#define DTRACE_MONITOR_WAIT_PROBE(obj, thread, millis, mon) {;}
...
...
hotspot/src/share/vm/runtime/sharedRuntime.cpp
浏览文件 @
5c895b44
...
...
@@ -127,14 +127,6 @@ void SharedRuntime::generate_stubs() {
#include <math.h>
#ifndef USDT2
HS_DTRACE_PROBE_DECL4
(
hotspot
,
object__alloc
,
Thread
*
,
char
*
,
int
,
size_t
);
HS_DTRACE_PROBE_DECL7
(
hotspot
,
method__entry
,
int
,
char
*
,
int
,
char
*
,
int
,
char
*
,
int
);
HS_DTRACE_PROBE_DECL7
(
hotspot
,
method__return
,
int
,
char
*
,
int
,
char
*
,
int
,
char
*
,
int
);
#endif
/* !USDT2 */
// Implementation of SharedRuntime
#ifndef PRODUCT
...
...
@@ -969,14 +961,9 @@ int SharedRuntime::dtrace_object_alloc_base(Thread* thread, oopDesc* o) {
Klass
*
klass
=
o
->
klass
();
int
size
=
o
->
size
();
Symbol
*
name
=
klass
->
name
();
#ifndef USDT2
HS_DTRACE_PROBE4
(
hotspot
,
object__alloc
,
get_java_tid
(
thread
),
name
->
bytes
(),
name
->
utf8_length
(),
size
*
HeapWordSize
);
#else
/* USDT2 */
HOTSPOT_OBJECT_ALLOC
(
get_java_tid
(
thread
),
(
char
*
)
name
->
bytes
(),
name
->
utf8_length
(),
size
*
HeapWordSize
);
#endif
/* USDT2 */
return
0
;
}
...
...
@@ -986,18 +973,11 @@ JRT_LEAF(int, SharedRuntime::dtrace_method_entry(
Symbol
*
kname
=
method
->
klass_name
();
Symbol
*
name
=
method
->
name
();
Symbol
*
sig
=
method
->
signature
();
#ifndef USDT2
HS_DTRACE_PROBE7
(
hotspot
,
method__entry
,
get_java_tid
(
thread
),
kname
->
bytes
(),
kname
->
utf8_length
(),
name
->
bytes
(),
name
->
utf8_length
(),
sig
->
bytes
(),
sig
->
utf8_length
());
#else
/* USDT2 */
HOTSPOT_METHOD_ENTRY
(
get_java_tid
(
thread
),
(
char
*
)
kname
->
bytes
(),
kname
->
utf8_length
(),
(
char
*
)
name
->
bytes
(),
name
->
utf8_length
(),
(
char
*
)
sig
->
bytes
(),
sig
->
utf8_length
());
#endif
/* USDT2 */
return
0
;
JRT_END
...
...
@@ -1007,18 +987,11 @@ JRT_LEAF(int, SharedRuntime::dtrace_method_exit(
Symbol
*
kname
=
method
->
klass_name
();
Symbol
*
name
=
method
->
name
();
Symbol
*
sig
=
method
->
signature
();
#ifndef USDT2
HS_DTRACE_PROBE7
(
hotspot
,
method__return
,
get_java_tid
(
thread
),
kname
->
bytes
(),
kname
->
utf8_length
(),
name
->
bytes
(),
name
->
utf8_length
(),
sig
->
bytes
(),
sig
->
utf8_length
());
#else
/* USDT2 */
HOTSPOT_METHOD_RETURN
(
get_java_tid
(
thread
),
(
char
*
)
kname
->
bytes
(),
kname
->
utf8_length
(),
(
char
*
)
name
->
bytes
(),
name
->
utf8_length
(),
(
char
*
)
sig
->
bytes
(),
sig
->
utf8_length
());
#endif
/* USDT2 */
return
0
;
JRT_END
...
...
hotspot/src/share/vm/runtime/synchronizer.cpp
浏览文件 @
5c895b44
...
...
@@ -84,32 +84,6 @@
len = klassname->utf8_length(); \
}
#ifndef USDT2
HS_DTRACE_PROBE_DECL5
(
hotspot
,
monitor__wait
,
jlong
,
uintptr_t
,
char
*
,
int
,
long
);
HS_DTRACE_PROBE_DECL4
(
hotspot
,
monitor__waited
,
jlong
,
uintptr_t
,
char
*
,
int
);
#define DTRACE_MONITOR_WAIT_PROBE(monitor, obj, thread, millis) \
{ \
if (DTraceMonitorProbes) { \
DTRACE_MONITOR_PROBE_COMMON(obj, thread); \
HS_DTRACE_PROBE5(hotspot, monitor__wait, jtid, \
(monitor), bytes, len, (millis)); \
} \
}
#define DTRACE_MONITOR_PROBE(probe, monitor, obj, thread) \
{ \
if (DTraceMonitorProbes) { \
DTRACE_MONITOR_PROBE_COMMON(obj, thread); \
HS_DTRACE_PROBE4(hotspot, monitor__##probe, jtid, \
(uintptr_t)(monitor), bytes, len); \
} \
}
#else
/* USDT2 */
#define DTRACE_MONITOR_WAIT_PROBE(monitor, obj, thread, millis) \
{ \
if (DTraceMonitorProbes) { \
...
...
@@ -130,7 +104,6 @@ HS_DTRACE_PROBE_DECL4(hotspot, monitor__waited,
} \
}
#endif
/* USDT2 */
#else // ndef DTRACE_ENABLED
#define DTRACE_MONITOR_WAIT_PROBE(obj, thread, millis, mon) {;}
...
...
hotspot/src/share/vm/runtime/thread.cpp
浏览文件 @
5c895b44
...
...
@@ -112,29 +112,6 @@
// Only bother with this argument setup if dtrace is available
#ifndef USDT2
HS_DTRACE_PROBE_DECL
(
hotspot
,
vm__init__begin
);
HS_DTRACE_PROBE_DECL
(
hotspot
,
vm__init__end
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
thread__start
,
char
*
,
intptr_t
,
intptr_t
,
intptr_t
,
bool
);
HS_DTRACE_PROBE_DECL5
(
hotspot
,
thread__stop
,
char
*
,
intptr_t
,
intptr_t
,
intptr_t
,
bool
);
#define DTRACE_THREAD_PROBE(probe, javathread) \
{ \
ResourceMark rm(this); \
int len = 0; \
const char* name = (javathread)->get_thread_name(); \
len = strlen(name); \
HS_DTRACE_PROBE5(hotspot, thread__##probe, \
name, len, \
java_lang_Thread::thread_id((javathread)->threadObj()), \
(javathread)->osthread()->thread_id(), \
java_lang_Thread::is_daemon((javathread)->threadObj())); \
}
#else
/* USDT2 */
#define HOTSPOT_THREAD_PROBE_start HOTSPOT_THREAD_START
#define HOTSPOT_THREAD_PROBE_stop HOTSPOT_THREAD_STOP
...
...
@@ -151,8 +128,6 @@ HS_DTRACE_PROBE_DECL5(hotspot, thread__stop, char*, intptr_t,
java_lang_Thread::is_daemon((javathread)->threadObj())); \
}
#endif
/* USDT2 */
#else // ndef DTRACE_ENABLED
#define DTRACE_THREAD_PROBE(probe, javathread)
...
...
@@ -3391,11 +3366,7 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
os
::
pause
();
}
#ifndef USDT2
HS_DTRACE_PROBE
(
hotspot
,
vm__init__begin
);
#else
/* USDT2 */
HOTSPOT_VM_INIT_BEGIN
();
#endif
/* USDT2 */
// Record VM creation timing statistics
TraceVmCreationTime
create_vm_timer
;
...
...
@@ -3557,11 +3528,7 @@ jint Threads::create_vm(JavaVMInitArgs* args, bool* canTryAgain) {
// debug stuff, that does not work until all basic classes have been initialized.
set_init_completed
();
#ifndef USDT2
HS_DTRACE_PROBE
(
hotspot
,
vm__init__end
);
#else
/* USDT2 */
HOTSPOT_VM_INIT_END
();
#endif
/* USDT2 */
// record VM initialization completion time
#if INCLUDE_MANAGEMENT
...
...
hotspot/src/share/vm/runtime/vmThread.cpp
浏览文件 @
5c895b44
...
...
@@ -40,12 +40,6 @@
#include "utilities/events.hpp"
#include "utilities/xmlstream.hpp"
#ifndef USDT2
HS_DTRACE_PROBE_DECL3
(
hotspot
,
vmops__request
,
char
*
,
uintptr_t
,
int
);
HS_DTRACE_PROBE_DECL3
(
hotspot
,
vmops__begin
,
char
*
,
uintptr_t
,
int
);
HS_DTRACE_PROBE_DECL3
(
hotspot
,
vmops__end
,
char
*
,
uintptr_t
,
int
);
#endif
/* !USDT2 */
// Dummy VM operation to act as first element in our circular double-linked list
class
VM_Dummy
:
public
VM_Operation
{
VMOp_Type
type
()
const
{
return
VMOp_Dummy
;
}
...
...
@@ -154,14 +148,9 @@ void VMOperationQueue::drain_list_oops_do(OopClosure* f) {
// High-level interface
bool
VMOperationQueue
::
add
(
VM_Operation
*
op
)
{
#ifndef USDT2
HS_DTRACE_PROBE3
(
hotspot
,
vmops__request
,
op
->
name
(),
strlen
(
op
->
name
()),
op
->
evaluation_mode
());
#else
/* USDT2 */
HOTSPOT_VMOPS_REQUEST
(
(
char
*
)
op
->
name
(),
strlen
(
op
->
name
()),
op
->
evaluation_mode
());
#endif
/* USDT2 */
// Encapsulates VM queue policy. Currently, that
// only involves putting them on the right list
...
...
@@ -358,14 +347,9 @@ void VMThread::evaluate_operation(VM_Operation* op) {
{
PerfTraceTime
vm_op_timer
(
perf_accumulated_vm_operation_time
());
#ifndef USDT2
HS_DTRACE_PROBE3
(
hotspot
,
vmops__begin
,
op
->
name
(),
strlen
(
op
->
name
()),
op
->
evaluation_mode
());
#else
/* USDT2 */
HOTSPOT_VMOPS_BEGIN
(
(
char
*
)
op
->
name
(),
strlen
(
op
->
name
()),
op
->
evaluation_mode
());
#endif
/* USDT2 */
EventExecuteVMOperation
event
;
...
...
@@ -383,14 +367,9 @@ void VMThread::evaluate_operation(VM_Operation* op) {
event
.
commit
();
}
#ifndef USDT2
HS_DTRACE_PROBE3
(
hotspot
,
vmops__end
,
op
->
name
(),
strlen
(
op
->
name
()),
op
->
evaluation_mode
());
#else
/* USDT2 */
HOTSPOT_VMOPS_END
(
(
char
*
)
op
->
name
(),
strlen
(
op
->
name
()),
op
->
evaluation_mode
());
#endif
/* USDT2 */
}
// Last access of info in _cur_vm_operation!
...
...
hotspot/src/share/vm/services/classLoadingService.cpp
浏览文件 @
5c895b44
...
...
@@ -37,26 +37,6 @@
// Only bother with this argument setup if dtrace is available
#ifndef USDT2
HS_DTRACE_PROBE_DECL4
(
hotspot
,
class__loaded
,
char
*
,
int
,
oop
,
bool
);
HS_DTRACE_PROBE_DECL4
(
hotspot
,
class__unloaded
,
char
*
,
int
,
oop
,
bool
);
#define DTRACE_CLASSLOAD_PROBE(type, clss, shared) \
{ \
char* data = NULL; \
int len = 0; \
Symbol* name = (clss)->name(); \
if (name != NULL) { \
data = (char*)name->bytes(); \
len = name->utf8_length(); \
} \
HS_DTRACE_PROBE4(hotspot, class__##type, \
data, len, SOLARIS_ONLY((void *))(clss)->class_loader(), (shared)); \
}
#else
/* USDT2 */
#define HOTSPOT_CLASS_unloaded HOTSPOT_CLASS_UNLOADED
#define HOTSPOT_CLASS_loaded HOTSPOT_CLASS_LOADED
#define DTRACE_CLASSLOAD_PROBE(type, clss, shared) \
...
...
@@ -72,7 +52,6 @@ HS_DTRACE_PROBE_DECL4(hotspot, class__unloaded, char*, int, oop, bool);
data, len, (clss)->class_loader(), (shared)); \
}
#endif
/* USDT2 */
#else // ndef DTRACE_ENABLED
#define DTRACE_CLASSLOAD_PROBE(type, clss, shared)
...
...
hotspot/src/share/vm/services/memoryManager.cpp
浏览文件 @
5c895b44
...
...
@@ -36,13 +36,6 @@
#include "services/gcNotifier.hpp"
#include "utilities/dtrace.hpp"
#ifndef USDT2
HS_DTRACE_PROBE_DECL8
(
hotspot
,
mem__pool__gc__begin
,
char
*
,
int
,
char
*
,
int
,
size_t
,
size_t
,
size_t
,
size_t
);
HS_DTRACE_PROBE_DECL8
(
hotspot
,
mem__pool__gc__end
,
char
*
,
int
,
char
*
,
int
,
size_t
,
size_t
,
size_t
,
size_t
);
#endif
/* !USDT2 */
MemoryManager
::
MemoryManager
()
{
_num_pools
=
0
;
(
void
)
const_cast
<
instanceOop
&>
(
_memory_mgr_obj
=
NULL
);
...
...
@@ -242,19 +235,11 @@ void GCMemoryManager::gc_begin(bool recordGCBeginTime, bool recordPreGCUsage,
MemoryPool
*
pool
=
MemoryService
::
get_memory_pool
(
i
);
MemoryUsage
usage
=
pool
->
get_memory_usage
();
_current_gc_stat
->
set_before_gc_usage
(
i
,
usage
);
#ifndef USDT2
HS_DTRACE_PROBE8
(
hotspot
,
mem__pool__gc__begin
,
name
(),
strlen
(
name
()),
pool
->
name
(),
strlen
(
pool
->
name
()),
usage
.
init_size
(),
usage
.
used
(),
usage
.
committed
(),
usage
.
max_size
());
#else
/* USDT2 */
HOTSPOT_MEM_POOL_GC_BEGIN
(
(
char
*
)
name
(),
strlen
(
name
()),
(
char
*
)
pool
->
name
(),
strlen
(
pool
->
name
()),
usage
.
init_size
(),
usage
.
used
(),
usage
.
committed
(),
usage
.
max_size
());
#endif
/* USDT2 */
}
}
}
...
...
@@ -280,19 +265,11 @@ void GCMemoryManager::gc_end(bool recordPostGCUsage,
MemoryPool
*
pool
=
MemoryService
::
get_memory_pool
(
i
);
MemoryUsage
usage
=
pool
->
get_memory_usage
();
#ifndef USDT2
HS_DTRACE_PROBE8
(
hotspot
,
mem__pool__gc__end
,
name
(),
strlen
(
name
()),
pool
->
name
(),
strlen
(
pool
->
name
()),
usage
.
init_size
(),
usage
.
used
(),
usage
.
committed
(),
usage
.
max_size
());
#else
/* USDT2 */
HOTSPOT_MEM_POOL_GC_END
(
(
char
*
)
name
(),
strlen
(
name
()),
(
char
*
)
pool
->
name
(),
strlen
(
pool
->
name
()),
usage
.
init_size
(),
usage
.
used
(),
usage
.
committed
(),
usage
.
max_size
());
#endif
/* USDT2 */
_current_gc_stat
->
set_after_gc_usage
(
i
,
usage
);
}
...
...
hotspot/src/share/vm/services/runtimeService.cpp
浏览文件 @
5c895b44
...
...
@@ -31,11 +31,6 @@
#include "utilities/exceptions.hpp"
#include "utilities/macros.hpp"
#ifndef USDT2
HS_DTRACE_PROBE_DECL
(
hs_private
,
safepoint__begin
);
HS_DTRACE_PROBE_DECL
(
hs_private
,
safepoint__end
);
#endif
/* !USDT2 */
#if INCLUDE_MANAGEMENT
TimeStamp
RuntimeService
::
_app_timer
;
TimeStamp
RuntimeService
::
_safepoint_timer
;
...
...
@@ -112,11 +107,7 @@ void RuntimeService::init() {
}
void
RuntimeService
::
record_safepoint_begin
()
{
#ifndef USDT2
HS_DTRACE_PROBE
(
hs_private
,
safepoint__begin
);
#else
/* USDT2 */
HS_PRIVATE_SAFEPOINT_BEGIN
();
#endif
/* USDT2 */
// Print the time interval in which the app was executing
if
(
PrintGCApplicationConcurrentTime
&&
_app_timer
.
is_updated
())
{
...
...
@@ -143,11 +134,7 @@ void RuntimeService::record_safepoint_synchronized() {
}
void
RuntimeService
::
record_safepoint_end
()
{
#ifndef USDT2
HS_DTRACE_PROBE
(
hs_private
,
safepoint__end
);
#else
/* USDT2 */
HS_PRIVATE_SAFEPOINT_END
();
#endif
/* USDT2 */
// Print the time interval for which the app was stopped
// during the current safepoint operation.
...
...
hotspot/src/share/vm/utilities/dtrace.hpp
浏览文件 @
5c895b44
...
...
@@ -37,7 +37,6 @@
// Work around dtrace tail call bug 6672627 until it is fixed in solaris 10.
#define HS_DTRACE_WORKAROUND_TAIL_CALL_BUG() \
do { volatile size_t dtrace_workaround_tail_call_bug = 1; } while (0)
#elif defined(LINUX)
#define HS_DTRACE_WORKAROUND_TAIL_CALL_BUG()
#elif defined(__APPLE__)
...
...
@@ -47,7 +46,6 @@
#error "dtrace enabled for unknown os"
#endif
/* defined(SOLARIS) */
#define USDT2 1
#include "dtracefiles/hotspot.h"
#include "dtracefiles/hotspot_jni.h"
#include "dtracefiles/hs_private.h"
...
...
@@ -59,147 +57,8 @@
#define HS_DTRACE_WORKAROUND_TAIL_CALL_BUG()
#ifndef USDT2
#define DTRACE_PROBE(a,b) {;}
#define DTRACE_PROBE1(a,b,c) {;}
#define DTRACE_PROBE2(a,b,c,d) {;}
#define DTRACE_PROBE3(a,b,c,d,e) {;}
#define DTRACE_PROBE4(a,b,c,d,e,f) {;}
#define DTRACE_PROBE5(a,b,c,d,e,f,g) {;}
#define DTRACE_PROBE6(a,b,c,d,e,f,g,h) {;}
#define DTRACE_PROBE7(a,b,c,d,e,f,g,h,i) {;}
#define DTRACE_PROBE8(a,b,c,d,e,f,g,h,i,j) {;}
#define DTRACE_PROBE9(a,b,c,d,e,f,g,h,i,j,k) {;}
#define DTRACE_PROBE10(a,b,c,d,e,f,g,h,i,j,k,l) {;}
#else
/* USDT2 */
#include "dtrace_usdt2_disabled.hpp"
#endif
/* USDT2 */
#include "dtrace_disabled.hpp"
#endif
/* defined(DTRACE_ENABLED) */
#ifndef USDT2
#define HS_DTRACE_PROBE_FN(provider,name)\
__dtrace_##provider##___##name
#ifdef SOLARIS
// Solaris dtrace needs actual extern function decls.
#define HS_DTRACE_PROBE_DECL_N(provider,name,args) \
DTRACE_ONLY(extern "C" void HS_DTRACE_PROBE_FN(provider,name) args)
#define HS_DTRACE_PROBE_CDECL_N(provider,name,args) \
DTRACE_ONLY(extern void HS_DTRACE_PROBE_FN(provider,name) args)
#else
// Systemtap dtrace compatible probes on GNU/Linux don't.
// If dtrace is disabled this macro becomes NULL
#define HS_DTRACE_PROBE_DECL_N(provider,name,args)
#define HS_DTRACE_PROBE_CDECL_N(provider,name,args)
#endif
/* Dtrace probe declarations */
#define HS_DTRACE_PROBE_DECL(provider,name) \
HS_DTRACE_PROBE_DECL0(provider,name)
#define HS_DTRACE_PROBE_DECL0(provider,name)\
HS_DTRACE_PROBE_DECL_N(provider,name,(void))
#define HS_DTRACE_PROBE_DECL1(provider,name,t0)\
HS_DTRACE_PROBE_DECL_N(provider,name,(uintptr_t))
#define HS_DTRACE_PROBE_DECL2(provider,name,t0,t1)\
HS_DTRACE_PROBE_DECL_N(provider,name,(uintptr_t,uintptr_t))
#define HS_DTRACE_PROBE_DECL3(provider,name,t0,t1,t2)\
HS_DTRACE_PROBE_DECL_N(provider,name,(uintptr_t,uintptr_t,uintptr_t))
#define HS_DTRACE_PROBE_DECL4(provider,name,t0,t1,t2,t3)\
HS_DTRACE_PROBE_DECL_N(provider,name,(uintptr_t,uintptr_t,uintptr_t,\
uintptr_t))
#define HS_DTRACE_PROBE_DECL5(provider,name,t0,t1,t2,t3,t4)\
HS_DTRACE_PROBE_DECL_N(provider,name,(\
uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t))
#define HS_DTRACE_PROBE_DECL6(provider,name,t0,t1,t2,t3,t4,t5)\
HS_DTRACE_PROBE_DECL_N(provider,name,(\
uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t))
#define HS_DTRACE_PROBE_DECL7(provider,name,t0,t1,t2,t3,t4,t5,t6)\
HS_DTRACE_PROBE_DECL_N(provider,name,(\
uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t))
#define HS_DTRACE_PROBE_DECL8(provider,name,t0,t1,t2,t3,t4,t5,t6,t7)\
HS_DTRACE_PROBE_DECL_N(provider,name,(\
uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,\
uintptr_t))
#define HS_DTRACE_PROBE_DECL9(provider,name,t0,t1,t2,t3,t4,t5,t6,t7,t8)\
HS_DTRACE_PROBE_DECL_N(provider,name,(\
uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,\
uintptr_t,uintptr_t))
#define HS_DTRACE_PROBE_DECL10(provider,name,t0,t1,t2,t3,t4,t5,t6,t7,t8,t9)\
HS_DTRACE_PROBE_DECL_N(provider,name,(\
uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,uintptr_t,\
uintptr_t,uintptr_t,uintptr_t))
/* Dtrace probe definitions */
#if defined(SOLARIS)
// Solaris dtrace uses actual function calls.
#define HS_DTRACE_PROBE_N(provider,name, args) \
DTRACE_ONLY(HS_DTRACE_PROBE_FN(provider,name) args)
#define HS_DTRACE_PROBE(provider,name) HS_DTRACE_PROBE0(provider,name)
#define HS_DTRACE_PROBE0(provider,name)\
HS_DTRACE_PROBE_N(provider,name,())
#define HS_DTRACE_PROBE1(provider,name,a0)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0))
#define HS_DTRACE_PROBE2(provider,name,a0,a1)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1))
#define HS_DTRACE_PROBE3(provider,name,a0,a1,a2)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2))
#define HS_DTRACE_PROBE4(provider,name,a0,a1,a2,a3)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2,\
(uintptr_t)a3))
#define HS_DTRACE_PROBE5(provider,name,a0,a1,a2,a3,a4)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2,\
(uintptr_t)a3,(uintptr_t)a4))
#define HS_DTRACE_PROBE6(provider,name,a0,a1,a2,a3,a4,a5)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2,\
(uintptr_t)a3,(uintptr_t)a4,(uintptr_t)a5))
#define HS_DTRACE_PROBE7(provider,name,a0,a1,a2,a3,a4,a5,a6)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2,\
(uintptr_t)a3,(uintptr_t)a4,(uintptr_t)a5,(uintptr_t)a6))
#define HS_DTRACE_PROBE8(provider,name,a0,a1,a2,a3,a4,a5,a6,a7)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2,\
(uintptr_t)a3,(uintptr_t)a4,(uintptr_t)a5,(uintptr_t)a6,(uintptr_t)a7))
#define HS_DTRACE_PROBE9(provider,name,a0,a1,a2,a3,a4,a5,a6,a7,a8)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2,\
(uintptr_t)a3,(uintptr_t)a4,(uintptr_t)a5,(uintptr_t)a6,(uintptr_t)a7,\
(uintptr_t)a8))
#define HS_DTRACE_PROBE10(provider,name,a0,a1,a2,a3,a4,a5,a6,a7,a8,a9)\
HS_DTRACE_PROBE_N(provider,name,((uintptr_t)a0,(uintptr_t)a1,(uintptr_t)a2,\
(uintptr_t)a3,(uintptr_t)a4,(uintptr_t)a5,(uintptr_t)a6,(uintptr_t)a7,\
(uintptr_t)a8,(uintptr_t)a9))
#else
// Systemtap dtrace compatible probes on GNU/Linux use direct macros.
// If dtrace is disabled this macro becomes NULL
#define HS_DTRACE_PROBE(provider,name) HS_DTRACE_PROBE0(provider,name)
#define HS_DTRACE_PROBE0(provider,name)\
DTRACE_PROBE(provider,name)
#define HS_DTRACE_PROBE1(provider,name,a0)\
DTRACE_PROBE1(provider,name,a0)
#define HS_DTRACE_PROBE2(provider,name,a0,a1)\
DTRACE_PROBE2(provider,name,a0,a1)
#define HS_DTRACE_PROBE3(provider,name,a0,a1,a2)\
DTRACE_PROBE3(provider,name,a0,a1,a2)
#define HS_DTRACE_PROBE4(provider,name,a0,a1,a2,a3)\
DTRACE_PROBE4(provider,name,a0,a1,a2,a3)
#define HS_DTRACE_PROBE5(provider,name,a0,a1,a2,a3,a4)\
DTRACE_PROBE5(provider,name,a0,a1,a2,a3,a4)
#define HS_DTRACE_PROBE6(provider,name,a0,a1,a2,a3,a4,a5)\
DTRACE_PROBE6(provider,name,a0,a1,a2,a3,a4,a5)
#define HS_DTRACE_PROBE7(provider,name,a0,a1,a2,a3,a4,a5,a6)\
DTRACE_PROBE7(provider,name,a0,a1,a2,a3,a4,a5,a6)
#define HS_DTRACE_PROBE8(provider,name,a0,a1,a2,a3,a4,a5,a6,a7)\
DTRACE_PROBE8(provider,name,a0,a1,a2,a3,a4,a5,a6,a7)
#define HS_DTRACE_PROBE9(provider,name,a0,a1,a2,a3,a4,a5,a6,a7,a8)\
DTRACE_PROBE9(provider,name,a0,a1,a2,a3,a4,a5,a6,a7,a8)
#define HS_DTRACE_PROBE10(provider,name,a0,a1,a2,a3,a4,a5,a6,a7,a8,a9)\
DTRACE_PROBE10(provider,name,a0,a1,a2,a3,a4,a5,a6,a7,a8,a9)
#endif
#endif
/* !USDT2 */
#endif // SHARE_VM_UTILITIES_DTRACE_HPP
hotspot/src/share/vm/utilities/dtrace_
usdt2_
disabled.hpp
→
hotspot/src/share/vm/utilities/dtrace_disabled.hpp
浏览文件 @
5c895b44
...
...
@@ -32,8 +32,6 @@
*/
#if !defined(DTRACE_ENABLED)
#ifdef USDT2
/* hotspot provider probes */
#define HOTSPOT_CLASS_LOADED(arg0, arg1, arg2, arg3)
#define HOTSPOT_CLASS_LOADED_ENABLED() 0
...
...
@@ -107,7 +105,7 @@
#define HOTSPOT_THREAD_PARK_BEGIN_ENABLED() 0
#define HOTSPOT_THREAD_PARK_END(arg0)
#define HOTSPOT_THREAD_PARK_END_ENABLED() 0
#define HOTSPOT_THREAD_UNPARK()
#define HOTSPOT_THREAD_UNPARK(
arg0
)
#define HOTSPOT_THREAD_UNPARK_ENABLED() 0
#define HOTSPOT_VM_INIT_BEGIN()
#define HOTSPOT_VM_INIT_BEGIN_ENABLED() 0
...
...
@@ -1086,12 +1084,8 @@
#define HOTSPOT_JNI_UNREGISTERNATIVES_RETURN(arg0)
#define HOTSPOT_JNI_UNREGISTERNATIVES_RETURN_ENABLED() 0
#else
/* USDT2 */
#error This file should only be included for USDT2
#endif
/* USDT2 */
#else
/* !defined(DTRACE_ENABLED) */
#error This file should only be included when dtrace is not enabled
#end
/* !defined(DTRACE_ENABLED) */
#end
if
/* !defined(DTRACE_ENABLED) */
#endif // SHARE_VM_UTILITIES_DTRACE_USDT2_DISABLED_HPP
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录