Path: blob/aarch64-shenandoah-jdk8u272-b10/hotspot/src/share/vm/runtime/frame.inline.hpp
32285 views
/*1* Copyright (c) 1997, 2018, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation.7*8* This code is distributed in the hope that it will be useful, but WITHOUT9* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or10* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License11* version 2 for more details (a copy is included in the LICENSE file that12* accompanied this code).13*14* You should have received a copy of the GNU General Public License version15* 2 along with this work; if not, write to the Free Software Foundation,16* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.17*18* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA19* or visit www.oracle.com if you need additional information or have any20* questions.21*22*/2324#ifndef SHARE_VM_RUNTIME_FRAME_INLINE_HPP25#define SHARE_VM_RUNTIME_FRAME_INLINE_HPP2627#include "interpreter/bytecodeInterpreter.hpp"28#include "interpreter/bytecodeInterpreter.inline.hpp"29#include "interpreter/interpreter.hpp"30#include "oops/method.hpp"31#include "runtime/frame.hpp"32#include "runtime/signature.hpp"33#ifdef TARGET_ARCH_x8634# include "jniTypes_x86.hpp"35#endif36#ifdef TARGET_ARCH_aarch3237# include "jniTypes_aarch32.hpp"38#endif39#ifdef TARGET_ARCH_aarch6440# include "jniTypes_aarch64.hpp"41#endif42#ifdef TARGET_ARCH_sparc43# include "jniTypes_sparc.hpp"44#endif45#ifdef TARGET_ARCH_zero46# include "jniTypes_zero.hpp"47#endif48#ifdef TARGET_ARCH_arm49# include "jniTypes_arm.hpp"50#endif51#ifdef TARGET_ARCH_ppc52# include "jniTypes_ppc.hpp"53#endif54#ifdef TARGET_ARCH_zero55# include "entryFrame_zero.hpp"56# include "fakeStubFrame_zero.hpp"57# include "interpreterFrame_zero.hpp"58# include "sharkFrame_zero.hpp"59#endif6061// This file holds platform-independent bodies of inline functions for frames.6263// Note: The bcx usually contains the bcp; however during GC it contains the bci64// (changed by gc_prologue() and gc_epilogue()) to be Method* position65// independent. These accessors make sure the correct value is returned66// by testing the range of the bcx value. bcp's are guaranteed to be above67// max_method_code_size, since methods are always allocated in OldSpace and68// Eden is allocated before OldSpace.69//70// The bcp is accessed sometimes during GC for ArgumentDescriptors; than71// the correct translation has to be performed (was bug).7273inline bool frame::is_bci(intptr_t bcx) {74#ifdef _LP6475return ((uintptr_t) bcx) <= ((uintptr_t) max_method_code_size) ;76#else77return 0 <= bcx && bcx <= max_method_code_size;78#endif79}8081inline bool frame::is_entry_frame() const {82return StubRoutines::returns_to_call_stub(pc());83}8485inline bool frame::is_stub_frame() const {86return StubRoutines::is_stub_code(pc()) || (_cb != NULL && _cb->is_adapter_blob());87}8889inline bool frame::is_first_frame() const {90return is_entry_frame() && entry_frame_is_first();91}9293#ifdef CC_INTERP94inline oop* frame::interpreter_frame_temp_oop_addr() const {95interpreterState istate = get_interpreterState();96return (oop *)&istate->_oop_temp;97}98#endif // CC_INTERP99100// here are the platform-dependent bodies:101102#ifdef TARGET_ARCH_x86103# include "frame_x86.inline.hpp"104#endif105#ifdef TARGET_ARCH_aarch32106# include "frame_aarch32.inline.hpp"107#endif108#ifdef TARGET_ARCH_aarch64109# include "frame_aarch64.inline.hpp"110#endif111#ifdef TARGET_ARCH_sparc112# include "frame_sparc.inline.hpp"113#endif114#ifdef TARGET_ARCH_zero115# include "frame_zero.inline.hpp"116#endif117#ifdef TARGET_ARCH_arm118# include "frame_arm.inline.hpp"119#endif120#ifdef TARGET_ARCH_ppc121# include "frame_ppc.inline.hpp"122#endif123124125#endif // SHARE_VM_RUNTIME_FRAME_INLINE_HPP126127128