src/cpu/x86/vm/x86_64.ad
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File 6814842 Sdiff src/cpu/x86/vm

src/cpu/x86/vm/x86_64.ad

Print this page
rev 767 : [mq]: 6814842


6442   %}
6443 
6444   ins_pipe(ialu_reg_mem);
6445 %}
6446 
6447 // Load Short (16 bit signed)
6448 instruct loadS(rRegI dst, memory mem)
6449 %{
6450   match(Set dst (LoadS mem));
6451 
6452   ins_cost(125);
6453   format %{ "movswl $dst, $mem\t# short" %}
6454 
6455   ins_encode %{
6456     __ movswl($dst$$Register, $mem$$Address);
6457   %}
6458 
6459   ins_pipe(ialu_reg_mem);
6460 %}
6461 












6462 // Load Short (16 bit signed) into Long Register
6463 instruct loadS2L(rRegL dst, memory mem)
6464 %{
6465   match(Set dst (ConvI2L (LoadS mem)));
6466 
6467   ins_cost(125);
6468   format %{ "movswq $dst, $mem\t# short -> long" %}
6469 
6470   ins_encode %{
6471     __ movswq($dst$$Register, $mem$$Address);
6472   %}
6473 
6474   ins_pipe(ialu_reg_mem);
6475 %}
6476 
6477 // Load Unsigned Short/Char (16 bit UNsigned)
6478 instruct loadUS(rRegI dst, memory mem)
6479 %{
6480   match(Set dst (LoadUS mem));
6481 
6482   ins_cost(125);
6483   format %{ "movzwl  $dst, $mem\t# ushort/char" %}
6484 
6485   ins_encode %{
6486     __ movzwl($dst$$Register, $mem$$Address);
6487   %}
6488 
6489   ins_pipe(ialu_reg_mem);
6490 %}
6491 












6492 // Load Unsigned Short/Char (16 bit UNsigned) into Long Register
6493 instruct loadUS2L(rRegL dst, memory mem)
6494 %{
6495   match(Set dst (ConvI2L (LoadUS mem)));
6496 
6497   ins_cost(125);
6498   format %{ "movzwq  $dst, $mem\t# ushort/char -> long" %}
6499 
6500   ins_encode %{
6501     __ movzwq($dst$$Register, $mem$$Address);
6502   %}
6503 
6504   ins_pipe(ialu_reg_mem);
6505 %}
6506 
6507 // Load Integer
6508 instruct loadI(rRegI dst, memory mem)
6509 %{
6510   match(Set dst (LoadI mem));
6511 
6512   ins_cost(125);
6513   format %{ "movl    $dst, $mem\t# int" %}
6514 
6515   ins_encode %{
6516     __ movl($dst$$Register, $mem$$Address);
6517   %}
6518 
6519   ins_pipe(ialu_reg_mem);
6520 %}
6521 
















































6522 // Load Integer into Long Register
6523 instruct loadI2L(rRegL dst, memory mem)
6524 %{
6525   match(Set dst (ConvI2L (LoadI mem)));
6526 
6527   ins_cost(125);
6528   format %{ "movslq  $dst, $mem\t# int -> long" %}
6529 
6530   ins_encode %{
6531     __ movslq($dst$$Register, $mem$$Address);
6532   %}
6533 
6534   ins_pipe(ialu_reg_mem);
6535 %}
6536 
6537 // Load Unsigned Integer into Long Register
6538 instruct loadUI2L(rRegL dst, memory mem)
6539 %{
6540   match(Set dst (LoadUI2L mem));
6541 




6442   %}
6443 
6444   ins_pipe(ialu_reg_mem);
6445 %}
6446 
6447 // Load Short (16 bit signed)
6448 instruct loadS(rRegI dst, memory mem)
6449 %{
6450   match(Set dst (LoadS mem));
6451 
6452   ins_cost(125);
6453   format %{ "movswl $dst, $mem\t# short" %}
6454 
6455   ins_encode %{
6456     __ movswl($dst$$Register, $mem$$Address);
6457   %}
6458 
6459   ins_pipe(ialu_reg_mem);
6460 %}
6461 
6462 // Load Short (16 bit signed) to Byte (8 bit signed)
6463 instruct loadS2B(rRegI dst, memory mem, immI_24 twentyfour) %{
6464   match(Set dst (RShiftI (LShiftI (LoadS mem) twentyfour) twentyfour));
6465 
6466   ins_cost(125);
6467   format %{ "movsbl $dst, $mem\t# short -> byte" %}
6468   ins_encode %{
6469     __ movsbl($dst$$Register, $mem$$Address);
6470   %}
6471   ins_pipe(ialu_reg_mem);
6472 %}
6473 
6474 // Load Short (16 bit signed) into Long Register
6475 instruct loadS2L(rRegL dst, memory mem)
6476 %{
6477   match(Set dst (ConvI2L (LoadS mem)));
6478 
6479   ins_cost(125);
6480   format %{ "movswq $dst, $mem\t# short -> long" %}
6481 
6482   ins_encode %{
6483     __ movswq($dst$$Register, $mem$$Address);
6484   %}
6485 
6486   ins_pipe(ialu_reg_mem);
6487 %}
6488 
6489 // Load Unsigned Short/Char (16 bit UNsigned)
6490 instruct loadUS(rRegI dst, memory mem)
6491 %{
6492   match(Set dst (LoadUS mem));
6493 
6494   ins_cost(125);
6495   format %{ "movzwl  $dst, $mem\t# ushort/char" %}
6496 
6497   ins_encode %{
6498     __ movzwl($dst$$Register, $mem$$Address);
6499   %}
6500 
6501   ins_pipe(ialu_reg_mem);
6502 %}
6503 
6504 // Load Unsigned Short/Char (16 bit UNsigned) to Byte (8 bit signed)
6505 instruct loadUS2B(rRegI dst, memory mem, immI_24 twentyfour) %{
6506   match(Set dst (RShiftI (LShiftI (LoadUS mem) twentyfour) twentyfour));
6507 
6508   ins_cost(125);
6509   format %{ "movsbl $dst, $mem\t# ushort -> byte" %}
6510   ins_encode %{
6511     __ movsbl($dst$$Register, $mem$$Address);
6512   %}
6513   ins_pipe(ialu_reg_mem);
6514 %}
6515 
6516 // Load Unsigned Short/Char (16 bit UNsigned) into Long Register
6517 instruct loadUS2L(rRegL dst, memory mem)
6518 %{
6519   match(Set dst (ConvI2L (LoadUS mem)));
6520 
6521   ins_cost(125);
6522   format %{ "movzwq  $dst, $mem\t# ushort/char -> long" %}
6523 
6524   ins_encode %{
6525     __ movzwq($dst$$Register, $mem$$Address);
6526   %}
6527 
6528   ins_pipe(ialu_reg_mem);
6529 %}
6530 
6531 // Load Integer
6532 instruct loadI(rRegI dst, memory mem)
6533 %{
6534   match(Set dst (LoadI mem));
6535 
6536   ins_cost(125);
6537   format %{ "movl    $dst, $mem\t# int" %}
6538 
6539   ins_encode %{
6540     __ movl($dst$$Register, $mem$$Address);
6541   %}
6542 
6543   ins_pipe(ialu_reg_mem);
6544 %}
6545 
6546 // Load Integer (32 bit signed) to Byte (8 bit signed)
6547 instruct loadI2B(rRegI dst, memory mem, immI_24 twentyfour) %{
6548   match(Set dst (RShiftI (LShiftI (LoadI mem) twentyfour) twentyfour));
6549 
6550   ins_cost(125);
6551   format %{ "movsbl  $dst, $mem\t# int -> byte" %}
6552   ins_encode %{
6553     __ movsbl($dst$$Register, $mem$$Address);
6554   %}
6555   ins_pipe(ialu_reg_mem);
6556 %}
6557 
6558 // Load Integer (32 bit signed) to Unsigned Byte (8 bit UNsigned)
6559 instruct loadI2UB(rRegI dst, memory mem, immI_255 mask) %{
6560   match(Set dst (AndI (LoadI mem) mask));
6561 
6562   ins_cost(125);
6563   format %{ "movzbl  $dst, $mem\t# int -> ubyte" %}
6564   ins_encode %{
6565     __ movzbl($dst$$Register, $mem$$Address);
6566   %}
6567   ins_pipe(ialu_reg_mem);
6568 %}
6569 
6570 // Load Integer (32 bit signed) to Short (16 bit signed)
6571 instruct loadI2S(rRegI dst, memory mem, immI_16 sixteen) %{
6572   match(Set dst (RShiftI (LShiftI (LoadI mem) sixteen) sixteen));
6573 
6574   ins_cost(125);
6575   format %{ "movswl  $dst, $mem\t# int -> short" %}
6576   ins_encode %{
6577     __ movswl($dst$$Register, $mem$$Address);
6578   %}
6579   ins_pipe(ialu_reg_mem);
6580 %}
6581 
6582 // Load Integer (32 bit signed) to Unsigned Short/Char (16 bit UNsigned)
6583 instruct loadI2US(rRegI dst, memory mem, immI_65535 mask) %{
6584   match(Set dst (AndI (LoadI mem) mask));
6585 
6586   ins_cost(125);
6587   format %{ "movzwl  $dst, $mem\t# int -> ushort/char" %}
6588   ins_encode %{
6589     __ movzwl($dst$$Register, $mem$$Address);
6590   %}
6591   ins_pipe(ialu_reg_mem);
6592 %}
6593 
6594 // Load Integer into Long Register
6595 instruct loadI2L(rRegL dst, memory mem)
6596 %{
6597   match(Set dst (ConvI2L (LoadI mem)));
6598 
6599   ins_cost(125);
6600   format %{ "movslq  $dst, $mem\t# int -> long" %}
6601 
6602   ins_encode %{
6603     __ movslq($dst$$Register, $mem$$Address);
6604   %}
6605 
6606   ins_pipe(ialu_reg_mem);
6607 %}
6608 
6609 // Load Unsigned Integer into Long Register
6610 instruct loadUI2L(rRegL dst, memory mem)
6611 %{
6612   match(Set dst (LoadUI2L mem));
6613 


src/cpu/x86/vm/x86_64.ad
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File