src/share/vm/code/nmethod.cpp

changeset 7535
7ae4e26cb1e0
parent 7333
b12a2a9b05ca
parent 6876
710a3c8b516e
child 8604
04d83ba48607
     1.1 --- a/src/share/vm/code/nmethod.cpp	Mon Mar 16 11:49:32 2015 -0700
     1.2 +++ b/src/share/vm/code/nmethod.cpp	Thu Oct 12 21:27:07 2017 +0800
     1.3 @@ -22,6 +22,12 @@
     1.4   *
     1.5   */
     1.6  
     1.7 +/*
     1.8 + * This file has been modified by Loongson Technology in 2015. These
     1.9 + * modifications are Copyright (c) 2015 Loongson Technology, and are made
    1.10 + * available on the same license terms set forth above.
    1.11 + */
    1.12 +
    1.13  #include "precompiled.hpp"
    1.14  #include "code/codeCache.hpp"
    1.15  #include "code/compiledIC.hpp"
    1.16 @@ -1159,7 +1165,7 @@
    1.17    // not-entrant methods.
    1.18    address low_boundary = verified_entry_point();
    1.19    if (!is_in_use()) {
    1.20 -    low_boundary += NativeJump::instruction_size;
    1.21 +    low_boundary +=  NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::instruction_size;
    1.22      // %%% Note:  On SPARC we patch only a 4-byte trap, not a full NativeJump.
    1.23      // This means that the low_boundary is going to be a little too high.
    1.24      // This shouldn't matter, since oops of non-entrant methods are never used.
    1.25 @@ -1206,7 +1212,7 @@
    1.26    // not-entrant methods.
    1.27    address low_boundary = verified_entry_point();
    1.28    if (!is_in_use()) {
    1.29 -    low_boundary += NativeJump::instruction_size;
    1.30 +    low_boundary += NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::instruction_size;
    1.31      // %%% Note:  On SPARC we patch only a 4-byte trap, not a full NativeJump.
    1.32      // This means that the low_boundary is going to be a little too high.
    1.33      // This shouldn't matter, since oops of non-entrant methods are never used.
    1.34 @@ -1451,7 +1457,7 @@
    1.35      // The caller can be calling the method statically or through an inline
    1.36      // cache call.
    1.37      if (!is_osr_method() && !is_not_entrant()) {
    1.38 -      NativeJump::patch_verified_entry(entry_point(), verified_entry_point(),
    1.39 +       NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::patch_verified_entry(entry_point(), verified_entry_point(),
    1.40                    SharedRuntime::get_handle_wrong_method_stub());
    1.41      }
    1.42  
    1.43 @@ -1774,7 +1780,7 @@
    1.44    // not-entrant methods.
    1.45    address low_boundary = verified_entry_point();
    1.46    if (is_not_entrant()) {
    1.47 -    low_boundary += NativeJump::instruction_size;
    1.48 +    low_boundary +=  NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::instruction_size;
    1.49      // %%% Note:  On SPARC we patch only a 4-byte trap, not a full NativeJump.
    1.50      // (See comment above.)
    1.51    }
    1.52 @@ -1930,7 +1936,7 @@
    1.53    // not-entrant methods.
    1.54    address low_boundary = verified_entry_point();
    1.55    if (is_not_entrant()) {
    1.56 -    low_boundary += NativeJump::instruction_size;
    1.57 +    low_boundary += NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::instruction_size;
    1.58      // %%% Note:  On SPARC we patch only a 4-byte trap, not a full NativeJump.
    1.59      // (See comment above.)
    1.60    }
    1.61 @@ -2033,7 +2039,7 @@
    1.62    // not-entrant methods.
    1.63    address low_boundary = verified_entry_point();
    1.64    if (is_not_entrant()) {
    1.65 -    low_boundary += NativeJump::instruction_size;
    1.66 +    low_boundary += NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::instruction_size;
    1.67      // %%% Note:  On SPARC we patch only a 4-byte trap, not a full NativeJump.
    1.68      // (See comment above.)
    1.69    }
    1.70 @@ -2134,7 +2140,7 @@
    1.71  void nmethod::metadata_do(void f(Metadata*)) {
    1.72    address low_boundary = verified_entry_point();
    1.73    if (is_not_entrant()) {
    1.74 -    low_boundary += NativeJump::instruction_size;
    1.75 +    low_boundary +=  NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::instruction_size;
    1.76      // %%% Note:  On SPARC we patch only a 4-byte trap, not a full NativeJump.
    1.77      // (See comment above.)
    1.78    }
    1.79 @@ -2193,7 +2199,7 @@
    1.80    // not-entrant methods.
    1.81    address low_boundary = verified_entry_point();
    1.82    if (is_not_entrant()) {
    1.83 -    low_boundary += NativeJump::instruction_size;
    1.84 +    low_boundary +=  NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::instruction_size;
    1.85      // %%% Note:  On SPARC we patch only a 4-byte trap, not a full NativeJump.
    1.86      // (See comment above.)
    1.87    }
    1.88 @@ -2699,7 +2705,7 @@
    1.89      return;
    1.90  
    1.91    // Make sure all the entry points are correctly aligned for patching.
    1.92 -  NativeJump::check_verified_entry_alignment(entry_point(), verified_entry_point());
    1.93 +  NOT_MIPS64(NativeJump)MIPS64_ONLY(NativeGeneralJump)::check_verified_entry_alignment(entry_point(), verified_entry_point());
    1.94  
    1.95    // assert(method()->is_oop(), "must be valid");
    1.96  

mercurial