17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #ifndef SHARE_VM_UTILITIES_MACROS_HPP
26 #define SHARE_VM_UTILITIES_MACROS_HPP
27
28 // Use this to mark code that needs to be cleaned up (for development only)
29 #define NEEDS_CLEANUP
30
31 // Makes a string of the argument (which is not macro-expanded)
32 #define STR(a) #a
33
34 // Makes a string of the macro expansion of a
35 #define XSTR(a) STR(a)
36
37 // -DINCLUDE_<something>=0 | 1 can be specified on the command line to include
38 // or exclude functionality.
39
40 #ifndef INCLUDE_JVMTI
41 #define INCLUDE_JVMTI 1
42 #endif // INCLUDE_JVMTI
43
44 #if INCLUDE_JVMTI
45 #define JVMTI_ONLY(x) x
46 #define NOT_JVMTI(x)
47 #define NOT_JVMTI_RETURN
48 #define NOT_JVMTI_RETURN_(code) /* next token must be ; */
49 #else
50 #define JVMTI_ONLY(x)
51 #define NOT_JVMTI(x) x
52 #define NOT_JVMTI_RETURN { return; }
53 #define NOT_JVMTI_RETURN_(code) { return code; }
54 #endif // INCLUDE_JVMTI
55
56 #ifndef INCLUDE_FPROF
|
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 *
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 * or visit www.oracle.com if you need additional information or have any
21 * questions.
22 *
23 */
24
25 #ifndef SHARE_VM_UTILITIES_MACROS_HPP
26 #define SHARE_VM_UTILITIES_MACROS_HPP
27
28 // Use this to mark code that needs to be cleaned up (for development only)
29 #define NEEDS_CLEANUP
30
31 // Makes a string of the argument (which is not macro-expanded)
32 #define STR(a) #a
33
34 // Makes a string of the macro expansion of a
35 #define XSTR(a) STR(a)
36
37 // Apply pre-processor token pasting to the expansions of x and y.
38 // The token pasting operator (##) prevents its arguments from being
39 // expanded. This macro allows expansion of its arguments before the
40 // concatenation is performed. Note: One auxilliary level ought to be
41 // sufficient, but two are used because of bugs in some preprocesors.
42 #define PASTE_TOKENS(x, y) PASTE_TOKENS_AUX(x, y)
43 #define PASTE_TOKENS_AUX(x, y) PASTE_TOKENS_AUX2(x, y)
44 #define PASTE_TOKENS_AUX2(x, y) x ## y
45
46 // -DINCLUDE_<something>=0 | 1 can be specified on the command line to include
47 // or exclude functionality.
48
49 #ifndef INCLUDE_JVMTI
50 #define INCLUDE_JVMTI 1
51 #endif // INCLUDE_JVMTI
52
53 #if INCLUDE_JVMTI
54 #define JVMTI_ONLY(x) x
55 #define NOT_JVMTI(x)
56 #define NOT_JVMTI_RETURN
57 #define NOT_JVMTI_RETURN_(code) /* next token must be ; */
58 #else
59 #define JVMTI_ONLY(x)
60 #define NOT_JVMTI(x) x
61 #define NOT_JVMTI_RETURN { return; }
62 #define NOT_JVMTI_RETURN_(code) { return code; }
63 #endif // INCLUDE_JVMTI
64
65 #ifndef INCLUDE_FPROF
|