< prev index next >

src/hotspot/share/runtime/os.hpp

Print this page




 880 #ifndef PLATFORM_PRINT_NATIVE_STACK
 881   // No platform-specific code for printing the native stack.
 882   static bool platform_print_native_stack(outputStream* st, const void* context,
 883                                           char *buf, int buf_size) {
 884     return false;
 885   }
 886 #endif
 887 
 888   // debugging support (mostly used by debug.cpp but also fatal error handler)
 889   static bool find(address pc, outputStream* st = tty); // OS specific function to make sense out of an address
 890 
 891   static bool dont_yield();                     // when true, JVM_Yield() is nop
 892   static void print_statistics();
 893 
 894   // Thread priority helpers (implemented in OS-specific part)
 895   static OSReturn set_native_priority(Thread* thread, int native_prio);
 896   static OSReturn get_native_priority(const Thread* const thread, int* priority_ptr);
 897   static int java_to_os_priority[CriticalPriority + 1];
 898   // Hint to the underlying OS that a task switch would not be good.
 899   // Void return because it's a hint and can fail.
 900   static void hint_no_preempt();
 901   static const char* native_thread_creation_failed_msg() {
 902     return OS_NATIVE_THREAD_CREATION_FAILED_MSG;
 903   }
 904 
 905   // Used at creation if requested by the diagnostic flag PauseAtStartup.
 906   // Causes the VM to wait until an external stimulus has been applied
 907   // (for Unix, that stimulus is a signal, for Windows, an external
 908   // ResumeThread call)
 909   static void pause();
 910 
 911   // Builds a platform dependent Agent_OnLoad_<libname> function name
 912   // which is used to find statically linked in agents.
 913   static char*  build_agent_function_name(const char *sym, const char *cname,
 914                                           bool is_absolute_path);
 915 
 916   class SuspendedThreadTaskContext {
 917   public:
 918     SuspendedThreadTaskContext(Thread* thread, void *ucontext) : _thread(thread), _ucontext(ucontext) {}
 919     Thread* thread() const { return _thread; }
 920     void* ucontext() const { return _ucontext; }




 880 #ifndef PLATFORM_PRINT_NATIVE_STACK
 881   // No platform-specific code for printing the native stack.
 882   static bool platform_print_native_stack(outputStream* st, const void* context,
 883                                           char *buf, int buf_size) {
 884     return false;
 885   }
 886 #endif
 887 
 888   // debugging support (mostly used by debug.cpp but also fatal error handler)
 889   static bool find(address pc, outputStream* st = tty); // OS specific function to make sense out of an address
 890 
 891   static bool dont_yield();                     // when true, JVM_Yield() is nop
 892   static void print_statistics();
 893 
 894   // Thread priority helpers (implemented in OS-specific part)
 895   static OSReturn set_native_priority(Thread* thread, int native_prio);
 896   static OSReturn get_native_priority(const Thread* const thread, int* priority_ptr);
 897   static int java_to_os_priority[CriticalPriority + 1];
 898   // Hint to the underlying OS that a task switch would not be good.
 899   // Void return because it's a hint and can fail.

 900   static const char* native_thread_creation_failed_msg() {
 901     return OS_NATIVE_THREAD_CREATION_FAILED_MSG;
 902   }
 903 
 904   // Used at creation if requested by the diagnostic flag PauseAtStartup.
 905   // Causes the VM to wait until an external stimulus has been applied
 906   // (for Unix, that stimulus is a signal, for Windows, an external
 907   // ResumeThread call)
 908   static void pause();
 909 
 910   // Builds a platform dependent Agent_OnLoad_<libname> function name
 911   // which is used to find statically linked in agents.
 912   static char*  build_agent_function_name(const char *sym, const char *cname,
 913                                           bool is_absolute_path);
 914 
 915   class SuspendedThreadTaskContext {
 916   public:
 917     SuspendedThreadTaskContext(Thread* thread, void *ucontext) : _thread(thread), _ucontext(ucontext) {}
 918     Thread* thread() const { return _thread; }
 919     void* ucontext() const { return _ucontext; }


< prev index next >