< prev index next >

src/share/vm/runtime/stubRoutines.hpp

Print this page
rev 11647 : 8161258: Simplify including platform files.
Summary: Include patform files with macros cpu_header() etc. Do various cleanups of macro usages. Remove _64/_32 from adlc generated files and platform .hpp files. Merge stubRoutines_x86*.hpp. Remove empty mutex_<os>* files.
Reviewed-by: dholmes, coleenp, kbarrett


  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  *
  23  */
  24 
  25 #ifndef SHARE_VM_RUNTIME_STUBROUTINES_HPP
  26 #define SHARE_VM_RUNTIME_STUBROUTINES_HPP
  27 
  28 #include "code/codeBlob.hpp"
  29 #include "memory/allocation.hpp"
  30 #include "runtime/frame.hpp"
  31 #include "runtime/mutexLocker.hpp"
  32 #include "runtime/stubCodeGenerator.hpp"

  33 
  34 // StubRoutines provides entry points to assembly routines used by
  35 // compiled code and the run-time system. Platform-specific entry
  36 // points are defined in the platform-specific inner class.
  37 //
  38 // Class scheme:
  39 //
  40 //    platform-independent               platform-dependent
  41 //
  42 //    stubRoutines.hpp  <-- included --  stubRoutines_<arch>.hpp
  43 //           ^                                  ^
  44 //           |                                  |
  45 //       implements                         implements
  46 //           |                                  |
  47 //           |                                  |
  48 //    stubRoutines.cpp                   stubRoutines_<arch>.cpp
  49 //    stubRoutines_<os_family>.cpp       stubGenerator_<arch>.cpp
  50 //    stubRoutines_<os_arch>.cpp
  51 //
  52 // Note 1: The important thing is a clean decoupling between stub


  66 // Scheme for adding a new entry point:
  67 //
  68 // 1. determine if it's a platform-dependent or independent entry point
  69 //    a) if platform independent: make subsequent changes in the independent files
  70 //    b) if platform   dependent: make subsequent changes in the   dependent files
  71 // 2. add a private instance variable holding the entry point address
  72 // 3. add a public accessor function to the instance variable
  73 // 4. implement the corresponding generator function in the platform-dependent
  74 //    stubGenerator_<arch>.cpp file and call the function in generate_all() of that file
  75 
  76 
  77 class StubRoutines: AllStatic {
  78 
  79  public:
  80   enum platform_independent_constants {
  81     max_size_of_parameters = 256                           // max. parameter size supported by megamorphic lookups
  82   };
  83 
  84   // Dependencies
  85   friend class StubGenerator;
  86 #if defined STUBROUTINES_MD_HPP
  87 # include STUBROUTINES_MD_HPP
  88 #elif defined TARGET_ARCH_MODEL_x86_32
  89 # include "stubRoutines_x86_32.hpp"
  90 #elif defined TARGET_ARCH_MODEL_x86_64
  91 # include "stubRoutines_x86_64.hpp"
  92 #elif defined TARGET_ARCH_MODEL_sparc
  93 # include "stubRoutines_sparc.hpp"
  94 #elif defined TARGET_ARCH_MODEL_zero
  95 # include "stubRoutines_zero.hpp"
  96 #elif defined TARGET_ARCH_MODEL_ppc_64
  97 # include "stubRoutines_ppc_64.hpp"
  98 #elif defined TARGET_ARCH_MODEL_aarch64
  99 # include "stubRoutines_aarch64.hpp"
 100 #endif
 101 
 102   static jint    _verify_oop_count;
 103   static address _verify_oop_subroutine_entry;
 104 
 105   static address _call_stub_return_address;                // the return PC, when returning to a call stub
 106   static address _call_stub_entry;
 107   static address _forward_exception_entry;
 108   static address _catch_exception_entry;
 109   static address _throw_AbstractMethodError_entry;
 110   static address _throw_IncompatibleClassChangeError_entry;
 111   static address _throw_NullPointerException_at_call_entry;
 112   static address _throw_StackOverflowError_entry;
 113   static address _throw_delayed_StackOverflowError_entry;
 114 
 115   static address _atomic_xchg_entry;
 116   static address _atomic_xchg_ptr_entry;
 117   static address _atomic_store_entry;
 118   static address _atomic_store_ptr_entry;
 119   static address _atomic_cmpxchg_entry;
 120   static address _atomic_cmpxchg_ptr_entry;




  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  *
  23  */
  24 
  25 #ifndef SHARE_VM_RUNTIME_STUBROUTINES_HPP
  26 #define SHARE_VM_RUNTIME_STUBROUTINES_HPP
  27 
  28 #include "code/codeBlob.hpp"
  29 #include "memory/allocation.hpp"
  30 #include "runtime/frame.hpp"
  31 #include "runtime/mutexLocker.hpp"
  32 #include "runtime/stubCodeGenerator.hpp"
  33 #include "utilities/macros.hpp"
  34 
  35 // StubRoutines provides entry points to assembly routines used by
  36 // compiled code and the run-time system. Platform-specific entry
  37 // points are defined in the platform-specific inner class.
  38 //
  39 // Class scheme:
  40 //
  41 //    platform-independent               platform-dependent
  42 //
  43 //    stubRoutines.hpp  <-- included --  stubRoutines_<arch>.hpp
  44 //           ^                                  ^
  45 //           |                                  |
  46 //       implements                         implements
  47 //           |                                  |
  48 //           |                                  |
  49 //    stubRoutines.cpp                   stubRoutines_<arch>.cpp
  50 //    stubRoutines_<os_family>.cpp       stubGenerator_<arch>.cpp
  51 //    stubRoutines_<os_arch>.cpp
  52 //
  53 // Note 1: The important thing is a clean decoupling between stub


  67 // Scheme for adding a new entry point:
  68 //
  69 // 1. determine if it's a platform-dependent or independent entry point
  70 //    a) if platform independent: make subsequent changes in the independent files
  71 //    b) if platform   dependent: make subsequent changes in the   dependent files
  72 // 2. add a private instance variable holding the entry point address
  73 // 3. add a public accessor function to the instance variable
  74 // 4. implement the corresponding generator function in the platform-dependent
  75 //    stubGenerator_<arch>.cpp file and call the function in generate_all() of that file
  76 
  77 
  78 class StubRoutines: AllStatic {
  79 
  80  public:
  81   enum platform_independent_constants {
  82     max_size_of_parameters = 256                           // max. parameter size supported by megamorphic lookups
  83   };
  84 
  85   // Dependencies
  86   friend class StubGenerator;
  87 
  88 #include CPU_HEADER(stubRoutines)













  89 
  90   static jint    _verify_oop_count;
  91   static address _verify_oop_subroutine_entry;
  92 
  93   static address _call_stub_return_address;                // the return PC, when returning to a call stub
  94   static address _call_stub_entry;
  95   static address _forward_exception_entry;
  96   static address _catch_exception_entry;
  97   static address _throw_AbstractMethodError_entry;
  98   static address _throw_IncompatibleClassChangeError_entry;
  99   static address _throw_NullPointerException_at_call_entry;
 100   static address _throw_StackOverflowError_entry;
 101   static address _throw_delayed_StackOverflowError_entry;
 102 
 103   static address _atomic_xchg_entry;
 104   static address _atomic_xchg_ptr_entry;
 105   static address _atomic_store_entry;
 106   static address _atomic_store_ptr_entry;
 107   static address _atomic_cmpxchg_entry;
 108   static address _atomic_cmpxchg_ptr_entry;


< prev index next >