src/share/vm/runtime/os.hpp

Print this page




 744   //
 745   // If user_sys_cpu_time is true, user+sys time is returned.
 746   // Otherwise, only user time is returned
 747   static jlong current_thread_cpu_time(bool user_sys_cpu_time);
 748   static jlong thread_cpu_time(Thread* t, bool user_sys_cpu_time);
 749 
 750   // Return a bunch of info about the timers.
 751   // Note that the returned info for these two functions may be different
 752   // on some platforms
 753   static void current_thread_cpu_time_info(jvmtiTimerInfo *info_ptr);
 754   static void thread_cpu_time_info(jvmtiTimerInfo *info_ptr);
 755 
 756   static bool is_thread_cpu_time_supported();
 757 
 758   // System loadavg support.  Returns -1 if load average cannot be obtained.
 759   static int loadavg(double loadavg[], int nelem);
 760 
 761   // Hook for os specific jvm options that we don't want to abort on seeing
 762   static bool obsolete_option(const JavaVMOption *option);
 763 



 764   // Extensions
 765 #include "runtime/os_ext.hpp"
 766 
 767  public:
 768   class CrashProtectionCallback : public StackObj {
 769   public:
 770     virtual void call() = 0;
 771   };
 772 
 773   // Platform dependent stuff
 774 #ifdef TARGET_OS_FAMILY_linux
 775 # include "os_linux.hpp"
 776 # include "os_posix.hpp"
 777 #endif
 778 #ifdef TARGET_OS_FAMILY_solaris
 779 # include "os_solaris.hpp"
 780 # include "os_posix.hpp"
 781 #endif
 782 #ifdef TARGET_OS_FAMILY_windows
 783 # include "os_windows.hpp"




 744   //
 745   // If user_sys_cpu_time is true, user+sys time is returned.
 746   // Otherwise, only user time is returned
 747   static jlong current_thread_cpu_time(bool user_sys_cpu_time);
 748   static jlong thread_cpu_time(Thread* t, bool user_sys_cpu_time);
 749 
 750   // Return a bunch of info about the timers.
 751   // Note that the returned info for these two functions may be different
 752   // on some platforms
 753   static void current_thread_cpu_time_info(jvmtiTimerInfo *info_ptr);
 754   static void thread_cpu_time_info(jvmtiTimerInfo *info_ptr);
 755 
 756   static bool is_thread_cpu_time_supported();
 757 
 758   // System loadavg support.  Returns -1 if load average cannot be obtained.
 759   static int loadavg(double loadavg[], int nelem);
 760 
 761   // Hook for os specific jvm options that we don't want to abort on seeing
 762   static bool obsolete_option(const JavaVMOption *option);
 763 
 764   // Amount beyond the callee frame size that we bang the stack.
 765   static int extra_bang_size_in_bytes();
 766 
 767   // Extensions
 768 #include "runtime/os_ext.hpp"
 769 
 770  public:
 771   class CrashProtectionCallback : public StackObj {
 772   public:
 773     virtual void call() = 0;
 774   };
 775 
 776   // Platform dependent stuff
 777 #ifdef TARGET_OS_FAMILY_linux
 778 # include "os_linux.hpp"
 779 # include "os_posix.hpp"
 780 #endif
 781 #ifdef TARGET_OS_FAMILY_solaris
 782 # include "os_solaris.hpp"
 783 # include "os_posix.hpp"
 784 #endif
 785 #ifdef TARGET_OS_FAMILY_windows
 786 # include "os_windows.hpp"