/*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*
*/
#include "assembler_x86.inline.hpp"
#include "interpreter/invocationCounter.hpp"
// This file specializes the assember with interpreter-specific macros
#ifndef CC_INTERP
protected:
// Interpreter specific version of call_VM_base
int number_of_arguments);
int number_of_arguments,
bool check_exceptions);
// base routine for all dispatches
#endif // CC_INTERP
public:
#ifdef CC_INTERP
#else
// Interpreter-specific registers
void save_bcp() {
}
void restore_bcp() {
}
void restore_locals() {
}
}
}
}
}
}
void get_cache_and_index_at_bcp(Register cache, Register index, int bcp_offset, size_t index_size = sizeof(u2));
void get_cache_and_index_and_bytecode_at_bcp(Register cache, Register index, Register bytecode, int byte_no, int bcp_offset, size_t index_size = sizeof(u2));
void get_cache_entry_pointer_at_bcp(Register cache, Register tmp, int bcp_offset, size_t index_size = sizeof(u2));
void empty_expression_stack() {
// NULL last_sp until next java call
}
// Helpers for swap and dup
// Generate a subtype check: branch to ok_is_subtype if sub_klass is
// a subtype of super_klass.
// Dispatching
// dispatch via ebx (assume ebx is loaded already)
// dispatch normal table via ebx (assume ebx is loaded already)
// load ebx from [esi + step] and dispatch via ebx
// load ebx from [esi] and dispatch via ebx and table
// jump to an invoked target
void prepare_to_jump_from_interpreted();
// Returning from interpreted functions
//
// Removes the current activation (incl. unlocking of monitors)
// and sets up the return address. This code is also used for
// exception unwindwing. In that case, we do not want to throw
// IllegalMonitorStateExceptions, since that might get us into an
// infinite rethrow exception loop.
// Additionally this code is used for popFrame and earlyReturn.
// In popFrame case we want to skip throwing an exception,
// installing an exception, and notifying jvmdi.
// In earlyReturn case we only want to skip throwing an exception
// and installing an exception.
bool throw_monitor_exception = true,
bool install_monitor_exception = true,
bool notify_jvmdi = true);
#endif // CC_INTERP
// Object locking
#ifndef CC_INTERP
// Interpreter profiling operations
void set_method_data_pointer_for_bcp();
void verify_method_data_pointer();
bool decrement = false);
bool decrement = false);
bool receiver_can_be_null = false);
// Debugging
// only if +VerifyOops && state == atos
// only if +VerifyFPU && (state == ftos || state == dtos)
#endif // !CC_INTERP
void notify_method_entry();
};
#endif // CPU_X86_VM_INTERP_MASM_X86_64_HPP