26 #define CPU_X86_C2_MACROASSEMBLER_X86_HPP
27
28 // C2_MacroAssembler contains high-level macros for C2
29
30 public:
31 // C2 compiled method's prolog code.
32 void verified_entry(int framesize, int stack_bang_size, bool fp_mode_24b, bool is_stub);
33
34 Assembler::AvxVectorLen vector_length_encoding(int vlen_in_bytes);
35
36 // Code used by cmpFastLock and cmpFastUnlock mach instructions in .ad file.
37 // See full description in macroAssembler_x86.cpp.
38 void fast_lock(Register obj, Register box, Register tmp,
39 Register scr, Register cx1, Register cx2, Register thread,
40 RTMLockingCounters* rtm_counters,
41 RTMLockingCounters* stack_rtm_counters,
42 Metadata* method_data,
43 bool use_rtm, bool profile_rtm);
44 void fast_unlock(Register obj, Register box, Register tmp, bool use_rtm);
45
46 #if INCLUDE_RTM_OPT
47 void rtm_counters_update(Register abort_status, Register rtm_counters);
48 void branch_on_random_using_rdtsc(Register tmp, Register scr, int count, Label& brLabel);
49 void rtm_abort_ratio_calculation(Register tmp, Register rtm_counters_reg,
50 RTMLockingCounters* rtm_counters,
51 Metadata* method_data);
52 void rtm_profiling(Register abort_status_Reg, Register rtm_counters_Reg,
53 RTMLockingCounters* rtm_counters, Metadata* method_data, bool profile_rtm);
54 void rtm_retry_lock_on_abort(Register retry_count, Register abort_status, Label& retryLabel);
55 void rtm_retry_lock_on_busy(Register retry_count, Register box, Register tmp, Register scr, Label& retryLabel);
56 void rtm_stack_locking(Register obj, Register tmp, Register scr,
57 Register retry_on_abort_count,
58 RTMLockingCounters* stack_rtm_counters,
59 Metadata* method_data, bool profile_rtm,
60 Label& DONE_LABEL, Label& IsInflated);
61 void rtm_inflated_locking(Register obj, Register box, Register tmp,
62 Register scr, Register retry_on_busy_count,
63 Register retry_on_abort_count,
64 RTMLockingCounters* rtm_counters,
65 Metadata* method_data, bool profile_rtm,
475
476 void vector_count_trailing_zeros_avx(BasicType bt, XMMRegister dst, XMMRegister src, XMMRegister xtmp1,
477 XMMRegister xtmp2, XMMRegister xtmp3, Register rtmp, int vec_enc);
478
479 void vector_signum_avx(int opcode, XMMRegister dst, XMMRegister src, XMMRegister zero, XMMRegister one,
480 XMMRegister xtmp1, int vec_enc);
481
482 void vector_signum_evex(int opcode, XMMRegister dst, XMMRegister src, XMMRegister zero, XMMRegister one,
483 KRegister ktmp1, int vec_enc);
484
485 void vmovmask(BasicType elem_bt, XMMRegister dst, Address src, XMMRegister mask, int vec_enc);
486
487 void vmovmask(BasicType elem_bt, Address dst, XMMRegister src, XMMRegister mask, int vec_enc);
488
489 void rearrange_bytes(XMMRegister dst, XMMRegister shuffle, XMMRegister src, XMMRegister xtmp1,
490 XMMRegister xtmp2, XMMRegister xtmp3, Register rtmp, KRegister ktmp, int vlen_enc);
491
492 void vector_rearrange_int_float(BasicType bt, XMMRegister dst, XMMRegister shuffle,
493 XMMRegister src, int vlen_enc);
494
495 #endif // CPU_X86_C2_MACROASSEMBLER_X86_HPP
|
26 #define CPU_X86_C2_MACROASSEMBLER_X86_HPP
27
28 // C2_MacroAssembler contains high-level macros for C2
29
30 public:
31 // C2 compiled method's prolog code.
32 void verified_entry(int framesize, int stack_bang_size, bool fp_mode_24b, bool is_stub);
33
34 Assembler::AvxVectorLen vector_length_encoding(int vlen_in_bytes);
35
36 // Code used by cmpFastLock and cmpFastUnlock mach instructions in .ad file.
37 // See full description in macroAssembler_x86.cpp.
38 void fast_lock(Register obj, Register box, Register tmp,
39 Register scr, Register cx1, Register cx2, Register thread,
40 RTMLockingCounters* rtm_counters,
41 RTMLockingCounters* stack_rtm_counters,
42 Metadata* method_data,
43 bool use_rtm, bool profile_rtm);
44 void fast_unlock(Register obj, Register box, Register tmp, bool use_rtm);
45
46 void fast_lock_lightweight(Register obj, Register box, Register rax_reg,
47 Register t, Register thread);
48 void fast_unlock_lightweight(Register obj, Register reg_rax, Register t, Register thread);
49
50 #if INCLUDE_RTM_OPT
51 void rtm_counters_update(Register abort_status, Register rtm_counters);
52 void branch_on_random_using_rdtsc(Register tmp, Register scr, int count, Label& brLabel);
53 void rtm_abort_ratio_calculation(Register tmp, Register rtm_counters_reg,
54 RTMLockingCounters* rtm_counters,
55 Metadata* method_data);
56 void rtm_profiling(Register abort_status_Reg, Register rtm_counters_Reg,
57 RTMLockingCounters* rtm_counters, Metadata* method_data, bool profile_rtm);
58 void rtm_retry_lock_on_abort(Register retry_count, Register abort_status, Label& retryLabel);
59 void rtm_retry_lock_on_busy(Register retry_count, Register box, Register tmp, Register scr, Label& retryLabel);
60 void rtm_stack_locking(Register obj, Register tmp, Register scr,
61 Register retry_on_abort_count,
62 RTMLockingCounters* stack_rtm_counters,
63 Metadata* method_data, bool profile_rtm,
64 Label& DONE_LABEL, Label& IsInflated);
65 void rtm_inflated_locking(Register obj, Register box, Register tmp,
66 Register scr, Register retry_on_busy_count,
67 Register retry_on_abort_count,
68 RTMLockingCounters* rtm_counters,
69 Metadata* method_data, bool profile_rtm,
479
480 void vector_count_trailing_zeros_avx(BasicType bt, XMMRegister dst, XMMRegister src, XMMRegister xtmp1,
481 XMMRegister xtmp2, XMMRegister xtmp3, Register rtmp, int vec_enc);
482
483 void vector_signum_avx(int opcode, XMMRegister dst, XMMRegister src, XMMRegister zero, XMMRegister one,
484 XMMRegister xtmp1, int vec_enc);
485
486 void vector_signum_evex(int opcode, XMMRegister dst, XMMRegister src, XMMRegister zero, XMMRegister one,
487 KRegister ktmp1, int vec_enc);
488
489 void vmovmask(BasicType elem_bt, XMMRegister dst, Address src, XMMRegister mask, int vec_enc);
490
491 void vmovmask(BasicType elem_bt, Address dst, XMMRegister src, XMMRegister mask, int vec_enc);
492
493 void rearrange_bytes(XMMRegister dst, XMMRegister shuffle, XMMRegister src, XMMRegister xtmp1,
494 XMMRegister xtmp2, XMMRegister xtmp3, Register rtmp, KRegister ktmp, int vlen_enc);
495
496 void vector_rearrange_int_float(BasicType bt, XMMRegister dst, XMMRegister shuffle,
497 XMMRegister src, int vlen_enc);
498
499 void load_nklass_compact_c2(Register dst, Register obj, Register index, Address::ScaleFactor scale, int disp);
500
501 #endif // CPU_X86_C2_MACROASSEMBLER_X86_HPP
|