comparison src/share/vm/services/classLoadingService.cpp @ 14518:d8041d695d19

Merged with jdk9/dev/hotspot changeset 3812c088b945
author twisti
date Tue, 11 Mar 2014 18:45:59 -0700
parents e6195383bcaf
children 4ca6dc0799b6
comparison
equal deleted inserted replaced
14141:f97c5ec83832 14518:d8041d695d19
34 #include "utilities/macros.hpp" 34 #include "utilities/macros.hpp"
35 35
36 #ifdef DTRACE_ENABLED 36 #ifdef DTRACE_ENABLED
37 37
38 // Only bother with this argument setup if dtrace is available 38 // Only bother with this argument setup if dtrace is available
39
40 #ifndef USDT2
41
42 HS_DTRACE_PROBE_DECL4(hotspot, class__loaded, char*, int, oop, bool);
43 HS_DTRACE_PROBE_DECL4(hotspot, class__unloaded, char*, int, oop, bool);
44
45 #define DTRACE_CLASSLOAD_PROBE(type, clss, shared) \
46 { \
47 char* data = NULL; \
48 int len = 0; \
49 Symbol* name = (clss)->name(); \
50 if (name != NULL) { \
51 data = (char*)name->bytes(); \
52 len = name->utf8_length(); \
53 } \
54 HS_DTRACE_PROBE4(hotspot, class__##type, \
55 data, len, SOLARIS_ONLY((void *))(clss)->class_loader(), (shared)); \
56 }
57
58 #else /* USDT2 */
59 39
60 #define HOTSPOT_CLASS_unloaded HOTSPOT_CLASS_UNLOADED 40 #define HOTSPOT_CLASS_unloaded HOTSPOT_CLASS_UNLOADED
61 #define HOTSPOT_CLASS_loaded HOTSPOT_CLASS_LOADED 41 #define HOTSPOT_CLASS_loaded HOTSPOT_CLASS_LOADED
62 #define DTRACE_CLASSLOAD_PROBE(type, clss, shared) \ 42 #define DTRACE_CLASSLOAD_PROBE(type, clss, shared) \
63 { \ 43 { \
70 } \ 50 } \
71 HOTSPOT_CLASS_##type( /* type = unloaded, loaded */ \ 51 HOTSPOT_CLASS_##type( /* type = unloaded, loaded */ \
72 data, len, (clss)->class_loader(), (shared)); \ 52 data, len, (clss)->class_loader(), (shared)); \
73 } 53 }
74 54
75 #endif /* USDT2 */
76 #else // ndef DTRACE_ENABLED 55 #else // ndef DTRACE_ENABLED
77 56
78 #define DTRACE_CLASSLOAD_PROBE(type, clss, shared) 57 #define DTRACE_CLASSLOAD_PROBE(type, clss, shared)
79 58
80 #endif 59 #endif