< prev index next >

src/hotspot/cpu/x86/macroAssembler_x86.hpp

Print this page
*** 28,13 ***
--- 28,16 ---
  #include "asm/assembler.hpp"
  #include "asm/register.hpp"
  #include "code/vmreg.inline.hpp"
  #include "compiler/oopMap.hpp"
  #include "utilities/macros.hpp"
+ #include "runtime/signature.hpp"
  #include "runtime/vm_version.hpp"
  #include "utilities/checkedCast.hpp"
  
+ class ciInlineKlass;
+ 
  // MacroAssembler extends Assembler by frequently used macros.
  //
  // Instructions for which a 'better' code sequence exists depending
  // on arguments should also go in here.
  

*** 92,10 ***
--- 95,32 ---
  
    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);
  
+   // markWord tests, kills markWord reg
+   void test_markword_is_inline_type(Register markword, Label& is_inline_type);
+ 
+   // inlineKlass queries, kills temp_reg
+   void test_oop_is_not_inline_type(Register object, Register tmp, Label& not_inline_type, bool can_be_null = true);
+ 
+   void test_field_is_null_free_inline_type(Register flags, Register temp_reg, Label& is_null_free);
+   void test_field_is_not_null_free_inline_type(Register flags, Register temp_reg, Label& not_null_free);
+   void test_field_is_flat(Register flags, Register temp_reg, Label& is_flat);
+   void test_field_has_null_marker(Register flags, Register temp_reg, Label& has_null_marker);
+ 
+   // Check oops for special arrays, i.e. flat arrays and/or null-free arrays
+   void test_oop_prototype_bit(Register oop, Register temp_reg, int32_t test_bit, bool jmp_set, Label& jmp_label);
+   void test_flat_array_oop(Register oop, Register temp_reg, Label& is_flat_array);
+   void test_non_flat_array_oop(Register oop, Register temp_reg, Label& is_non_flat_array);
+   void test_null_free_array_oop(Register oop, Register temp_reg, Label& is_null_free_array);
+   void test_non_null_free_array_oop(Register oop, Register temp_reg, Label& is_non_null_free_array);
+ 
+   // Check array klass layout helper for flat or null-free arrays...
+   void test_flat_array_layout(Register lh, Label& is_flat_array);
+   void test_non_flat_array_layout(Register lh, Label& is_non_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 */ ||

*** 347,10 ***
--- 372,13 ---
    void load_method_holder_cld(Register rresult, Register rmethod);
  
    void load_method_holder(Register holder, Register method);
  
    // oop manipulations
+ 
+   // Load oopDesc._metadata without decode (useful for direct Klass* compare from oops)
+   void load_metadata(Register dst, Register src);
    void load_narrow_klass_compact(Register dst, Register src);
    void load_klass(Register dst, Register src, Register tmp);
    void store_klass(Register dst, Register src, Register tmp);
  
    // Compares the narrow Klass pointer of an object to a given narrow Klass.

*** 363,19 ***
--- 391,30 ---
    void access_load_at(BasicType type, DecoratorSet decorators, Register dst, Address src,
                        Register tmp1);
    void access_store_at(BasicType type, DecoratorSet decorators, Address dst, Register val,
                         Register tmp1, Register tmp2, Register tmp3);
  
+   void flat_field_copy(DecoratorSet decorators, Register src, Register dst, Register inline_layout_info);
+ 
+   // inline type data payload offsets...
+   void payload_offset(Register inline_klass, Register offset);
+   void payload_addr(Register oop, Register data, Register inline_klass);
+   // get data payload ptr a flat value array at index, kills rcx and index
+   void data_for_value_array_index(Register array, Register array_klass,
+                                   Register index, Register data);
+ 
    void load_heap_oop(Register dst, Address src, Register tmp1 = noreg, DecoratorSet decorators = 0);
    void load_heap_oop_not_null(Register dst, Address src, Register tmp1 = noreg, DecoratorSet decorators = 0);
    void store_heap_oop(Address dst, Register val, Register tmp1 = noreg,
                        Register tmp2 = noreg, Register tmp3 = noreg, DecoratorSet decorators = 0);
  
    // Used for storing null. All other oop constants should be
    // stored using routines that take a jobject.
    void store_heap_oop_null(Address dst);
  
+   void load_prototype_header(Register dst, Register src, Register tmp);
+ 
    void store_klass_gap(Register dst, Register src);
  
    // This dummy is to prevent a call to store_heap_oop from
    // converting a zero (like null) into a Register by giving
    // the compiler two choices it can't resolve

*** 519,10 ***
--- 558,12 ---
      Register t2,                       // temp register
      Label&   slow_case                 // continuation point if fast allocation fails
    );
    void zero_memory(Register address, Register length_in_bytes, int offset_in_bytes, Register temp);
  
+   void inline_layout_info(Register klass, Register index, Register layout_info);
+ 
    void population_count(Register dst, Register src, Register scratch1, Register scratch2);
  
    // interface method calling
    void lookup_interface_method(Register recv_klass,
                                 Register intf_klass,

*** 767,10 ***
--- 808,11 ---
      else                   addptr(dst, src.as_register());
    }
  
    void andptr(Register dst, int32_t src);
    void andptr(Register src1, Register src2) { andq(src1, src2); }
+   void andptr(Register dst, Address src) { andq(dst, src); }
  
    using Assembler::andq;
    void andq(Register dst, AddressLiteral src, Register rscratch = noreg);
  
    void cmp8(AddressLiteral src1, int imm, Register rscratch = noreg);

*** 1925,13 ***
    void movl2ptr(Register dst, Address src) { movslq(dst, src); }
    void movl2ptr(Register dst, Register src) { movslq(dst, src); }
  
  
   public:
    // 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, KRegister mask=knoreg);
  
    // clear memory initialization sequence for constant size;
    void clear_mem(Register base, int cnt, Register rtmp, XMMRegister xtmp, KRegister mask=knoreg);
  
    // clear memory of size 'cnt' qwords, starting at 'base' using XMM/YMM registers
--- 1967,16 ---
    void movl2ptr(Register dst, Address src) { movslq(dst, src); }
    void movl2ptr(Register dst, Register src) { movslq(dst, src); }
  
  
   public:
+   // Inline type specific methods
+   #include "asm/macroAssembler_common.hpp"
+ 
    // 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 val, XMMRegister xtmp, bool is_large, bool word_copy_only, KRegister mask=knoreg);
  
    // clear memory initialization sequence for constant size;
    void clear_mem(Register base, int cnt, Register rtmp, XMMRegister xtmp, KRegister mask=knoreg);
  
    // clear memory of size 'cnt' qwords, starting at 'base' using XMM/YMM registers
< prev index next >