src/share/vm/runtime/frame.inline.hpp

Sun, 03 Feb 2013 22:43:57 +0100

author
ewendeli
date
Sun, 03 Feb 2013 22:43:57 +0100
changeset 4703
b5cb079ecaa4
parent 4037
da91efe96a93
child 5237
f2110083203d
permissions
-rw-r--r--

Merge

duke@435 1 /*
coleenp@4037 2 * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
duke@435 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
duke@435 4 *
duke@435 5 * This code is free software; you can redistribute it and/or modify it
duke@435 6 * under the terms of the GNU General Public License version 2 only, as
duke@435 7 * published by the Free Software Foundation.
duke@435 8 *
duke@435 9 * This code is distributed in the hope that it will be useful, but WITHOUT
duke@435 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
duke@435 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
duke@435 12 * version 2 for more details (a copy is included in the LICENSE file that
duke@435 13 * accompanied this code).
duke@435 14 *
duke@435 15 * You should have received a copy of the GNU General Public License version
duke@435 16 * 2 along with this work; if not, write to the Free Software Foundation,
duke@435 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
duke@435 18 *
trims@1907 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
trims@1907 20 * or visit www.oracle.com if you need additional information or have any
trims@1907 21 * questions.
duke@435 22 *
duke@435 23 */
duke@435 24
stefank@2314 25 #ifndef SHARE_VM_RUNTIME_FRAME_INLINE_HPP
stefank@2314 26 #define SHARE_VM_RUNTIME_FRAME_INLINE_HPP
stefank@2314 27
stefank@2314 28 #include "interpreter/bytecodeInterpreter.hpp"
stefank@2314 29 #include "interpreter/bytecodeInterpreter.inline.hpp"
stefank@2314 30 #include "interpreter/interpreter.hpp"
coleenp@4037 31 #include "oops/method.hpp"
stefank@2314 32 #include "runtime/frame.hpp"
stefank@2314 33 #include "runtime/signature.hpp"
stefank@2314 34 #ifdef TARGET_ARCH_x86
stefank@2314 35 # include "jniTypes_x86.hpp"
stefank@2314 36 #endif
stefank@2314 37 #ifdef TARGET_ARCH_sparc
stefank@2314 38 # include "jniTypes_sparc.hpp"
stefank@2314 39 #endif
stefank@2314 40 #ifdef TARGET_ARCH_zero
stefank@2314 41 # include "jniTypes_zero.hpp"
stefank@2314 42 #endif
bobv@2508 43 #ifdef TARGET_ARCH_arm
bobv@2508 44 # include "jniTypes_arm.hpp"
bobv@2508 45 #endif
bobv@2508 46 #ifdef TARGET_ARCH_ppc
bobv@2508 47 # include "jniTypes_ppc.hpp"
bobv@2508 48 #endif
stefank@2314 49 #ifdef ZERO
stefank@2314 50 #ifdef TARGET_ARCH_zero
stefank@2314 51 # include "entryFrame_zero.hpp"
stefank@2314 52 # include "fakeStubFrame_zero.hpp"
stefank@2314 53 # include "interpreterFrame_zero.hpp"
stefank@2314 54 # include "sharkFrame_zero.hpp"
stefank@2314 55 #endif
stefank@2314 56 #endif
stefank@2314 57
twisti@1040 58 // This file holds platform-independent bodies of inline functions for frames.
duke@435 59
duke@435 60 // Note: The bcx usually contains the bcp; however during GC it contains the bci
coleenp@4037 61 // (changed by gc_prologue() and gc_epilogue()) to be Method* position
duke@435 62 // independent. These accessors make sure the correct value is returned
duke@435 63 // by testing the range of the bcx value. bcp's are guaranteed to be above
duke@435 64 // max_method_code_size, since methods are always allocated in OldSpace and
duke@435 65 // Eden is allocated before OldSpace.
duke@435 66 //
duke@435 67 // The bcp is accessed sometimes during GC for ArgumentDescriptors; than
duke@435 68 // the correct translation has to be performed (was bug).
duke@435 69
duke@435 70 inline bool frame::is_bci(intptr_t bcx) {
duke@435 71 #ifdef _LP64
duke@435 72 return ((uintptr_t) bcx) <= ((uintptr_t) max_method_code_size) ;
duke@435 73 #else
duke@435 74 return 0 <= bcx && bcx <= max_method_code_size;
duke@435 75 #endif
duke@435 76 }
duke@435 77
duke@435 78 inline bool frame::is_entry_frame() const {
duke@435 79 return StubRoutines::returns_to_call_stub(pc());
duke@435 80 }
duke@435 81
duke@435 82 inline bool frame::is_first_frame() const {
duke@435 83 return is_entry_frame() && entry_frame_is_first();
duke@435 84 }
duke@435 85
duke@435 86 // here are the platform-dependent bodies:
duke@435 87
stefank@2314 88 #ifdef TARGET_ARCH_x86
stefank@2314 89 # include "frame_x86.inline.hpp"
stefank@2314 90 #endif
stefank@2314 91 #ifdef TARGET_ARCH_sparc
stefank@2314 92 # include "frame_sparc.inline.hpp"
stefank@2314 93 #endif
stefank@2314 94 #ifdef TARGET_ARCH_zero
stefank@2314 95 # include "frame_zero.inline.hpp"
stefank@2314 96 #endif
bobv@2508 97 #ifdef TARGET_ARCH_arm
bobv@2508 98 # include "frame_arm.inline.hpp"
bobv@2508 99 #endif
bobv@2508 100 #ifdef TARGET_ARCH_ppc
bobv@2508 101 # include "frame_ppc.inline.hpp"
bobv@2508 102 #endif
stefank@2314 103
stefank@2314 104
stefank@2314 105 #endif // SHARE_VM_RUNTIME_FRAME_INLINE_HPP

mercurial