< prev index next >
src/hotspot/cpu/x86/macroAssembler_x86.hpp
Print this page
@@ -26,10 +26,11 @@
#define CPU_X86_MACROASSEMBLER_X86_HPP
#include "asm/assembler.hpp"
#include "utilities/macros.hpp"
#include "runtime/rtmLocking.hpp"
+#include "runtime/signature.hpp"
// MacroAssembler extends Assembler by frequently used macros.
//
// Instructions for which a 'better' code sequence exists depending
// on arguments should also go in here.
@@ -96,10 +97,20 @@
void null_check(Register reg, int offset = -1);
static bool needs_explicit_null_check(intptr_t offset);
static bool uses_implicit_null_check(void* address);
+ void test_klass_is_value(Register klass, Register temp_reg, Label& is_value);
+
+ void test_field_is_flattenable(Register flags, Register temp_reg, Label& is_flattenable);
+ void test_field_is_not_flattenable(Register flags, Register temp_reg, Label& notFlattenable);
+ void test_field_is_flattened(Register flags, Register temp_reg, Label& is_flattened);
+
+ // Check klass/oops is flat value type array (oop->_klass->_layout_helper & vt_bit)
+ void test_flat_array_klass(Register klass, Register temp_reg, Label& is_flat_array);
+ void test_flat_array_oop(Register oop, Register temp_reg, Label& is_flat_array);
+
// Required platform-specific helpers for Label::patch_instructions.
// They _shadow_ the declarations in AbstractAssembler, which are undefined.
void pd_patch_instruction(address branch, address target, const char* file, int line) {
unsigned char op = branch[0];
assert(op == 0xE8 /* call */ ||
@@ -1598,18 +1609,30 @@
// sign extend as need a l to ptr sized element
void movl2ptr(Register dst, Address src) { LP64_ONLY(movslq(dst, src)) NOT_LP64(movl(dst, src)); }
void movl2ptr(Register dst, Register src) { LP64_ONLY(movslq(dst, src)) NOT_LP64(if (dst != src) movl(dst, src)); }
// C2 compiled method's prolog code.
- void verified_entry(int framesize, int stack_bang_size, bool fp_mode_24b, bool is_stub);
+ void verified_entry(Compile* C, int sp_inc = 0);
+
+ enum RegState {
+ reg_readonly,
+ reg_writable,
+ reg_written
+ };
+
+ // Unpack all value type arguments passed as oops
+ void unpack_value_args(Compile* C, bool receiver_only);
+ bool move_helper(VMReg from, VMReg to, BasicType bt, RegState reg_state[], int ret_off);
+ bool unpack_value_helper(const GrowableArray<SigEntry>* sig, int& sig_index, VMReg from, VMRegPair* regs_to, int& to_index, RegState reg_state[], int ret_off);
+ void restore_stack(Compile* C);
// clear memory of size 'cnt' qwords, starting at 'base';
// if 'is_large' is set, do not try to produce short loop
- void clear_mem(Register base, Register cnt, Register rtmp, XMMRegister xtmp, bool is_large);
+ void clear_mem(Register base, Register cnt, Register val, XMMRegister xtmp, bool is_large, bool word_copy_only);
// clear memory of size 'cnt' qwords, starting at 'base' using XMM/YMM registers
- void xmm_clear_mem(Register base, Register cnt, XMMRegister xtmp);
+ void xmm_clear_mem(Register base, Register cnt, Register val, XMMRegister xtmp);
#ifdef COMPILER2
void string_indexof_char(Register str1, Register cnt1, Register ch, Register result,
XMMRegister vec1, XMMRegister vec2, XMMRegister vec3, Register tmp);
< prev index next >