< prev index next >

src/hotspot/share/oops/method.inline.hpp

Print this page

 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_OOPS_METHOD_INLINE_HPP
 26 #define SHARE_OOPS_METHOD_INLINE_HPP
 27 
 28 #include "oops/method.hpp"
 29 
 30 #include "runtime/atomic.hpp"
 31 
 32 inline address Method::from_compiled_entry() const {
 33   return Atomic::load_acquire(&_from_compiled_entry);
 34 }
 35 








 36 inline address Method::from_interpreted_entry() const {
 37   return Atomic::load_acquire(&_from_interpreted_entry);
 38 }
 39 
 40 inline void Method::set_method_data(MethodData* data) {
 41   // The store into method must be released. On platforms without
 42   // total store order (TSO) the reference may become visible before
 43   // the initialization of data otherwise.
 44   Atomic::release_store(&_method_data, data);
 45 }
 46 
 47 inline CompiledMethod* volatile Method::code() const {
 48   assert( check_code(), "" );
 49   return Atomic::load_acquire(&_code);
 50 }
 51 
 52 // Write (bci, line number) pair to stream
 53 inline void CompressedLineNumberWriteStream::write_pair_regular(int bci_delta, int line_delta) {
 54   // bci and line number does not compress into single byte.
 55   // Write out escape character and use regular compression for bci and line number.

 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_OOPS_METHOD_INLINE_HPP
 26 #define SHARE_OOPS_METHOD_INLINE_HPP
 27 
 28 #include "oops/method.hpp"
 29 
 30 #include "runtime/atomic.hpp"
 31 
 32 inline address Method::from_compiled_entry() const {
 33   return Atomic::load_acquire(&_from_compiled_entry);
 34 }
 35 
 36 inline address Method::from_compiled_inline_ro_entry() const {
 37   return Atomic::load_acquire(&_from_compiled_inline_ro_entry);
 38 }
 39 
 40 inline address Method::from_compiled_inline_entry() const {
 41   return Atomic::load_acquire(&_from_compiled_inline_entry);
 42 }
 43 
 44 inline address Method::from_interpreted_entry() const {
 45   return Atomic::load_acquire(&_from_interpreted_entry);
 46 }
 47 
 48 inline void Method::set_method_data(MethodData* data) {
 49   // The store into method must be released. On platforms without
 50   // total store order (TSO) the reference may become visible before
 51   // the initialization of data otherwise.
 52   Atomic::release_store(&_method_data, data);
 53 }
 54 
 55 inline CompiledMethod* volatile Method::code() const {
 56   assert( check_code(), "" );
 57   return Atomic::load_acquire(&_code);
 58 }
 59 
 60 // Write (bci, line number) pair to stream
 61 inline void CompressedLineNumberWriteStream::write_pair_regular(int bci_delta, int line_delta) {
 62   // bci and line number does not compress into single byte.
 63   // Write out escape character and use regular compression for bci and line number.
< prev index next >