Path: blob/master/src/hotspot/share/interpreter/zero/zeroInterpreterGenerator.hpp
40957 views
/*1* Copyright (c) 1997, 2020, 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_INTERPRETER_CPPINTERPRETERGENERATOR_HPP25#define SHARE_INTERPRETER_CPPINTERPRETERGENERATOR_HPP2627// This file contains the platform-independent parts28// of the Zero interpreter generator.2930# include "entry_zero.hpp"31// # include "interpreter/interp_masm.hpp"3233class ZeroInterpreterGenerator: public AbstractInterpreterGenerator {3435private:36void generate_all();3738address generate_slow_signature_handler();3940address generate_method_entry(AbstractInterpreter::MethodKind kind);41address generate_normal_entry(bool synchronized);42address generate_native_entry(bool synchronized);43address generate_abstract_entry();44address generate_math_entry(AbstractInterpreter::MethodKind kind);45address generate_empty_entry();46address generate_getter_entry();47address generate_setter_entry();48address generate_Reference_get_entry();4950public:51ZeroInterpreterGenerator(StubQueue* _code);5253protected:54MacroAssembler* assembler() const {55return _masm;56}5758public:59static address generate_entry_impl(MacroAssembler* masm, address entry_point) {60ZeroEntry *entry = (ZeroEntry *) masm->pc();61masm->advance(sizeof(ZeroEntry));62entry->set_entry_point(entry_point);63return (address) entry;64}6566protected:67address generate_entry(address entry_point) {68return generate_entry_impl(assembler(), entry_point);69}70};7172#endif // SHARE_INTERPRETER_CPPINTERPRETERGENERATOR_HPP737475