Print this page


Split Close
Expand all
Collapse all
          --- old/src/cpu/x86/vm/x86_32.ad
          +++ new/src/cpu/x86/vm/x86_32.ad
↓ open down ↓ 5547 lines elided ↑ open up ↑
5548 5548  
5549 5549    format %{ "BSWAP  $dst.lo\n\t"
5550 5550              "BSWAP  $dst.hi\n\t"
5551 5551              "XCHG   $dst.lo $dst.hi" %}
5552 5552  
5553 5553    ins_cost(125);
5554 5554    ins_encode( bswap_long_bytes(dst) );
5555 5555    ins_pipe( ialu_reg_reg);
5556 5556  %}
5557 5557  
5558      -instruct bytes_reverse_unsigned_short(eRegI dst) %{
     5558 +instruct bytes_reverse_unsigned_short(eRegI dst, eFlagsReg cr) %{
5559 5559    match(Set dst (ReverseBytesUS dst));
     5560 +  effect(KILL cr);
5560 5561  
5561 5562    format %{ "BSWAP  $dst\n\t" 
5562 5563              "SHR    $dst,16\n\t" %}
5563 5564    ins_encode %{
5564 5565      __ bswapl($dst$$Register);
5565 5566      __ shrl($dst$$Register, 16); 
5566 5567    %}
5567 5568    ins_pipe( ialu_reg );
5568 5569  %}
5569 5570  
5570      -instruct bytes_reverse_short(eRegI dst) %{
     5571 +instruct bytes_reverse_short(eRegI dst, eFlagsReg cr) %{
5571 5572    match(Set dst (ReverseBytesS dst));
     5573 +  effect(KILL cr);
5572 5574  
5573 5575    format %{ "BSWAP  $dst\n\t" 
5574 5576              "SAR    $dst,16\n\t" %}
5575 5577    ins_encode %{
5576 5578      __ bswapl($dst$$Register);
5577 5579      __ sarl($dst$$Register, 16); 
5578 5580    %}
5579 5581    ins_pipe( ialu_reg );
5580 5582  %}
5581 5583  
↓ open down ↓ 140 lines elided ↑ open up ↑
5722 5724      __ bind(msw_not_zero);
5723 5725      __ addl(Rdst, BitsPerInt);
5724 5726      __ bind(done);
5725 5727    %}
5726 5728    ins_pipe(ialu_reg);
5727 5729  %}
5728 5730  
5729 5731  
5730 5732  //---------- Population Count Instructions -------------------------------------
5731 5733  
5732      -instruct popCountI(eRegI dst, eRegI src) %{
     5734 +instruct popCountI(eRegI dst, eRegI src, eFlagsReg cr) %{
5733 5735    predicate(UsePopCountInstruction);
5734 5736    match(Set dst (PopCountI src));
     5737 +  effect(KILL cr);
5735 5738  
5736 5739    format %{ "POPCNT $dst, $src" %}
5737 5740    ins_encode %{
5738 5741      __ popcntl($dst$$Register, $src$$Register);
5739 5742    %}
5740 5743    ins_pipe(ialu_reg);
5741 5744  %}
5742 5745  
5743      -instruct popCountI_mem(eRegI dst, memory mem) %{
     5746 +instruct popCountI_mem(eRegI dst, memory mem, eFlagsReg cr) %{
5744 5747    predicate(UsePopCountInstruction);
5745 5748    match(Set dst (PopCountI (LoadI mem)));
     5749 +  effect(KILL cr);
5746 5750  
5747 5751    format %{ "POPCNT $dst, $mem" %}
5748 5752    ins_encode %{
5749 5753      __ popcntl($dst$$Register, $mem$$Address);
5750 5754    %}
5751 5755    ins_pipe(ialu_reg);
5752 5756  %}
5753 5757  
5754 5758  // Note: Long.bitCount(long) returns an int.
5755 5759  instruct popCountL(eRegI dst, eRegL src, eRegI tmp, eFlagsReg cr) %{
↓ open down ↓ 7628 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX