src/share/vm/prims/forte.cpp

Print this page
rev 4899 : 8019973: PPC64 (part 11): Fix IA64 preprocessor conditionals on AIX.
Summary: On AIX 7.1 systemcfg.h defines IA64 unconditionally, so test for !AIX where IA64 is used. Clean up old gcc bug workaround (ATTR) and includes in forte.cpp.

*** 20,29 **** --- 20,33 ---- * or visit www.oracle.com if you need additional information or have any * questions. * */ + #include "utilities/macros.hpp" + + #if defined(SOLARIS) || (defined(LINUX) && defined(X86)) + #include "precompiled.hpp" #include "code/debugInfoRec.hpp" #include "code/pcDesc.hpp" #include "gc_interface/collectedHeap.inline.hpp" #include "memory/space.hpp"
*** 67,79 **** //------------------------------------------------------- // Native interfaces for use by Forte tools. - - #ifndef IA64 - class vframeStreamForte : public vframeStreamCommon { public: // constructor that starts with sender of frame fr (top_frame) vframeStreamForte(JavaThread *jt, frame fr, bool stop_at_java_call_stub); void forte_next(); --- 71,80 ----
*** 593,646 **** trace->num_frames = ticks_unknown_state; // -7 break; } } - - #ifndef _WINDOWS // Support for the Forte(TM) Peformance Tools collector. // // The method prototype is derived from libcollector.h. For more // information, please see the libcollect man page. // Method to let libcollector know about a dynamically loaded function. // Because it is weakly bound, the calls become NOP's when the library // isn't present. - #ifdef __APPLE__ - // XXXDARWIN: Link errors occur even when __attribute__((weak_import)) - // is added - #define collector_func_load(x0,x1,x2,x3,x4,x5,x6) (0) - #else void collector_func_load(char* name, void* null_argument_1, void* null_argument_2, void *vaddr, int size, int zero_argument, void* null_argument_3); #pragma weak collector_func_load #define collector_func_load(x0,x1,x2,x3,x4,x5,x6) \ ( collector_func_load ? collector_func_load(x0,x1,x2,x3,x4,x5,x6),(void)0 : (void)0 ) - #endif // __APPLE__ - #endif // !_WINDOWS } // end extern "C" - #endif // !IA64 void Forte::register_stub(const char* name, address start, address end) { - #if !defined(_WINDOWS) && !defined(IA64) assert(pointer_delta(end, start, sizeof(jbyte)) < INT_MAX, "Code size exceeds maximum range"); collector_func_load((char*)name, NULL, NULL, start, pointer_delta(end, start, sizeof(jbyte)), 0, NULL); - #endif // !_WINDOWS && !IA64 } #else // INCLUDE_JVMTI extern "C" { JNIEXPORT void AsyncGetCallTrace(ASGCT_CallTrace *trace, jint depth, void* ucontext) { trace->num_frames = ticks_no_class_load; // -1 } } #endif // INCLUDE_JVMTI --- 594,637 ---- trace->num_frames = ticks_unknown_state; // -7 break; } } // Support for the Forte(TM) Peformance Tools collector. // // The method prototype is derived from libcollector.h. For more // information, please see the libcollect man page. // Method to let libcollector know about a dynamically loaded function. // Because it is weakly bound, the calls become NOP's when the library // isn't present. void collector_func_load(char* name, void* null_argument_1, void* null_argument_2, void *vaddr, int size, int zero_argument, void* null_argument_3); #pragma weak collector_func_load #define collector_func_load(x0,x1,x2,x3,x4,x5,x6) \ ( collector_func_load ? collector_func_load(x0,x1,x2,x3,x4,x5,x6),(void)0 : (void)0 ) } // end extern "C" void Forte::register_stub(const char* name, address start, address end) { assert(pointer_delta(end, start, sizeof(jbyte)) < INT_MAX, "Code size exceeds maximum range"); collector_func_load((char*)name, NULL, NULL, start, pointer_delta(end, start, sizeof(jbyte)), 0, NULL); } #else // INCLUDE_JVMTI extern "C" { JNIEXPORT void AsyncGetCallTrace(ASGCT_CallTrace *trace, jint depth, void* ucontext) { trace->num_frames = ticks_no_class_load; // -1 } } #endif // INCLUDE_JVMTI + + #endif // SOLARIS || (LINUX && X86)