< prev index next >

src/os/linux/vm/os_linux.hpp

Print this page


   1 /*
   2  * Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  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  *


 120   static void print_libversion_info(outputStream* st);
 121 
 122  public:
 123   static bool _stack_is_executable;
 124   static void *dlopen_helper(const char *name, char *ebuf, int ebuflen);
 125   static void *dll_load_in_vmthread(const char *name, char *ebuf, int ebuflen);
 126 
 127   static void init_thread_fpu_state();
 128   static int  get_fpu_control_word();
 129   static void set_fpu_control_word(int fpu_control);
 130   static pthread_t main_thread(void)                                { return _main_thread; }
 131   // returns kernel thread id (similar to LWP id on Solaris), which can be
 132   // used to access /proc
 133   static pid_t gettid();
 134   static void set_createThread_lock(Mutex* lk)                      { _createThread_lock = lk; }
 135   static Mutex* createThread_lock(void)                             { return _createThread_lock; }
 136   static void hotspot_sigmask(Thread* thread);
 137 
 138   static address   initial_thread_stack_bottom(void)                { return _initial_thread_stack_bottom; }
 139   static uintptr_t initial_thread_stack_size(void)                  { return _initial_thread_stack_size; }
 140   static bool is_initial_thread(void);
 141 
 142   static int page_size(void)                                        { return _page_size; }
 143   static void set_page_size(int val)                                { _page_size = val; }
 144 
 145   static int vm_default_page_size(void)                             { return _vm_default_page_size; }
 146 
 147   static address   ucontext_get_pc(ucontext_t* uc);
 148   static intptr_t* ucontext_get_sp(ucontext_t* uc);
 149   static intptr_t* ucontext_get_fp(ucontext_t* uc);
 150 
 151   // For Analyzer Forte AsyncGetCallTrace profiling support:
 152   //
 153   // This interface should be declared in os_linux_i486.hpp, but
 154   // that file provides extensions to the os class and not the
 155   // Linux class.
 156   static ExtendedPC fetch_frame_from_ucontext(Thread* thread, ucontext_t* uc,
 157     intptr_t** ret_sp, intptr_t** ret_fp);
 158 
 159   // This boolean allows users to forward their own non-matching signals
 160   // to JVM_handle_linux_signal, harmlessly.


   1 /*
   2  * Copyright (c) 1999, 2018, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.
   8  *
   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  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  *


 120   static void print_libversion_info(outputStream* st);
 121 
 122  public:
 123   static bool _stack_is_executable;
 124   static void *dlopen_helper(const char *name, char *ebuf, int ebuflen);
 125   static void *dll_load_in_vmthread(const char *name, char *ebuf, int ebuflen);
 126 
 127   static void init_thread_fpu_state();
 128   static int  get_fpu_control_word();
 129   static void set_fpu_control_word(int fpu_control);
 130   static pthread_t main_thread(void)                                { return _main_thread; }
 131   // returns kernel thread id (similar to LWP id on Solaris), which can be
 132   // used to access /proc
 133   static pid_t gettid();
 134   static void set_createThread_lock(Mutex* lk)                      { _createThread_lock = lk; }
 135   static Mutex* createThread_lock(void)                             { return _createThread_lock; }
 136   static void hotspot_sigmask(Thread* thread);
 137 
 138   static address   initial_thread_stack_bottom(void)                { return _initial_thread_stack_bottom; }
 139   static uintptr_t initial_thread_stack_size(void)                  { return _initial_thread_stack_size; }

 140 
 141   static int page_size(void)                                        { return _page_size; }
 142   static void set_page_size(int val)                                { _page_size = val; }
 143 
 144   static int vm_default_page_size(void)                             { return _vm_default_page_size; }
 145 
 146   static address   ucontext_get_pc(ucontext_t* uc);
 147   static intptr_t* ucontext_get_sp(ucontext_t* uc);
 148   static intptr_t* ucontext_get_fp(ucontext_t* uc);
 149 
 150   // For Analyzer Forte AsyncGetCallTrace profiling support:
 151   //
 152   // This interface should be declared in os_linux_i486.hpp, but
 153   // that file provides extensions to the os class and not the
 154   // Linux class.
 155   static ExtendedPC fetch_frame_from_ucontext(Thread* thread, ucontext_t* uc,
 156     intptr_t** ret_sp, intptr_t** ret_fp);
 157 
 158   // This boolean allows users to forward their own non-matching signals
 159   // to JVM_handle_linux_signal, harmlessly.


< prev index next >