< prev index next >

src/hotspot/cpu/riscv/macroAssembler_riscv.hpp

Print this page

1366   }
1367 
1368   void ld_constant(Register dest, const Address &const_addr) {
1369     if (NearCpool) {
1370       ld(dest, const_addr);
1371     } else {
1372       InternalAddress target(const_addr.target());
1373       relocate(target.rspec(), [&] {
1374         int32_t offset;
1375         la_patchable(dest, target, offset);
1376         ld(dest, Address(dest, offset));
1377       });
1378     }
1379   }
1380 
1381   int bitset_to_regs(unsigned int bitset, unsigned char* regs);
1382   Address add_memory_helper(const Address dst, Register tmp);
1383 
1384   void load_reserved(Register addr, enum operand_size size, Assembler::Aqrl acquire);
1385   void store_conditional(Register addr, Register new_val, enum operand_size size, Assembler::Aqrl release);




1386 };
1387 
1388 #ifdef ASSERT
1389 inline bool AbstractAssembler::pd_check_instruction_mark() { return false; }
1390 #endif
1391 
1392 /**
1393  * class SkipIfEqual:
1394  *
1395  * Instantiating this class will result in assembly code being output that will
1396  * jump around any code emitted between the creation of the instance and it's
1397  * automatic destruction at the end of a scope block, depending on the value of
1398  * the flag passed to the constructor, which will be checked at run-time.
1399  */
1400 class SkipIfEqual {
1401  private:
1402   MacroAssembler* _masm;
1403   Label _label;
1404 
1405  public:

1366   }
1367 
1368   void ld_constant(Register dest, const Address &const_addr) {
1369     if (NearCpool) {
1370       ld(dest, const_addr);
1371     } else {
1372       InternalAddress target(const_addr.target());
1373       relocate(target.rspec(), [&] {
1374         int32_t offset;
1375         la_patchable(dest, target, offset);
1376         ld(dest, Address(dest, offset));
1377       });
1378     }
1379   }
1380 
1381   int bitset_to_regs(unsigned int bitset, unsigned char* regs);
1382   Address add_memory_helper(const Address dst, Register tmp);
1383 
1384   void load_reserved(Register addr, enum operand_size size, Assembler::Aqrl acquire);
1385   void store_conditional(Register addr, Register new_val, enum operand_size size, Assembler::Aqrl release);
1386 
1387 public:
1388   void fast_lock(Register obj, Register hdr, Register tmp1, Register tmp2, Label& slow);
1389   void fast_unlock(Register obj, Register hdr, Register tmp1, Register tmp2, Label& slow);
1390 };
1391 
1392 #ifdef ASSERT
1393 inline bool AbstractAssembler::pd_check_instruction_mark() { return false; }
1394 #endif
1395 
1396 /**
1397  * class SkipIfEqual:
1398  *
1399  * Instantiating this class will result in assembly code being output that will
1400  * jump around any code emitted between the creation of the instance and it's
1401  * automatic destruction at the end of a scope block, depending on the value of
1402  * the flag passed to the constructor, which will be checked at run-time.
1403  */
1404 class SkipIfEqual {
1405  private:
1406   MacroAssembler* _masm;
1407   Label _label;
1408 
1409  public:
< prev index next >