OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 578 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
589 __ vfnmadd231ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); | 589 __ vfnmadd231ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
590 | 590 |
591 __ vfnmsub132ss(xmm0, xmm1, xmm2); | 591 __ vfnmsub132ss(xmm0, xmm1, xmm2); |
592 __ vfnmsub132ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); | 592 __ vfnmsub132ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
593 __ vfnmsub213ss(xmm0, xmm1, xmm2); | 593 __ vfnmsub213ss(xmm0, xmm1, xmm2); |
594 __ vfnmsub213ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); | 594 __ vfnmsub213ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
595 __ vfnmsub231ss(xmm0, xmm1, xmm2); | 595 __ vfnmsub231ss(xmm0, xmm1, xmm2); |
596 __ vfnmsub231ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); | 596 __ vfnmsub231ss(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
597 } | 597 } |
598 } | 598 } |
| 599 |
| 600 // BMI1 instructions |
| 601 { |
| 602 if (CpuFeatures::IsSupported(BMI1)) { |
| 603 CpuFeatureScope scope(&assm, BMI1); |
| 604 __ andnq(rax, rbx, rcx); |
| 605 __ andnq(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 606 __ andnl(rax, rbx, rcx); |
| 607 __ andnl(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 608 __ bextrq(rax, rbx, rcx); |
| 609 __ bextrq(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 610 __ bextrl(rax, rbx, rcx); |
| 611 __ bextrl(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 612 __ blsiq(rax, rbx); |
| 613 __ blsiq(rax, Operand(rbx, rcx, times_4, 10000)); |
| 614 __ blsil(rax, rbx); |
| 615 __ blsil(rax, Operand(rbx, rcx, times_4, 10000)); |
| 616 __ blsmskq(rax, rbx); |
| 617 __ blsmskq(rax, Operand(rbx, rcx, times_4, 10000)); |
| 618 __ blsmskl(rax, rbx); |
| 619 __ blsmskl(rax, Operand(rbx, rcx, times_4, 10000)); |
| 620 __ blsrq(rax, rbx); |
| 621 __ blsrq(rax, Operand(rbx, rcx, times_4, 10000)); |
| 622 __ blsrl(rax, rbx); |
| 623 __ blsrl(rax, Operand(rbx, rcx, times_4, 10000)); |
| 624 __ tzcntq(rax, rbx); |
| 625 __ tzcntq(rax, Operand(rbx, rcx, times_4, 10000)); |
| 626 __ tzcntl(rax, rbx); |
| 627 __ tzcntl(rax, Operand(rbx, rcx, times_4, 10000)); |
| 628 } |
| 629 } |
| 630 |
| 631 // LZCNT instructions |
| 632 { |
| 633 if (CpuFeatures::IsSupported(LZCNT)) { |
| 634 CpuFeatureScope scope(&assm, LZCNT); |
| 635 __ lzcntq(rax, rbx); |
| 636 __ lzcntq(rax, Operand(rbx, rcx, times_4, 10000)); |
| 637 __ lzcntl(rax, rbx); |
| 638 __ lzcntl(rax, Operand(rbx, rcx, times_4, 10000)); |
| 639 } |
| 640 } |
| 641 |
| 642 // POPCNT instructions |
| 643 { |
| 644 if (CpuFeatures::IsSupported(POPCNT)) { |
| 645 CpuFeatureScope scope(&assm, POPCNT); |
| 646 __ popcntq(rax, rbx); |
| 647 __ popcntq(rax, Operand(rbx, rcx, times_4, 10000)); |
| 648 __ popcntl(rax, rbx); |
| 649 __ popcntl(rax, Operand(rbx, rcx, times_4, 10000)); |
| 650 } |
| 651 } |
| 652 |
| 653 // BMI2 instructions |
| 654 { |
| 655 if (CpuFeatures::IsSupported(BMI2)) { |
| 656 CpuFeatureScope scope(&assm, BMI2); |
| 657 __ bzhiq(rax, rbx, rcx); |
| 658 __ bzhiq(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 659 __ bzhil(rax, rbx, rcx); |
| 660 __ bzhil(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 661 __ mulxq(rax, rbx, rcx); |
| 662 __ mulxq(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 663 __ mulxl(rax, rbx, rcx); |
| 664 __ mulxl(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 665 __ pdepq(rax, rbx, rcx); |
| 666 __ pdepq(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 667 __ pdepl(rax, rbx, rcx); |
| 668 __ pdepl(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 669 __ pextq(rax, rbx, rcx); |
| 670 __ pextq(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 671 __ pextl(rax, rbx, rcx); |
| 672 __ pextl(rax, rbx, Operand(rbx, rcx, times_4, 10000)); |
| 673 __ sarxq(rax, rbx, rcx); |
| 674 __ sarxq(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 675 __ sarxl(rax, rbx, rcx); |
| 676 __ sarxl(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 677 __ shlxq(rax, rbx, rcx); |
| 678 __ shlxq(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 679 __ shlxl(rax, rbx, rcx); |
| 680 __ shlxl(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 681 __ shrxq(rax, rbx, rcx); |
| 682 __ shrxq(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 683 __ shrxl(rax, rbx, rcx); |
| 684 __ shrxl(rax, Operand(rbx, rcx, times_4, 10000), rbx); |
| 685 __ rorxq(rax, rbx, 63); |
| 686 __ rorxq(rax, Operand(rbx, rcx, times_4, 10000), 63); |
| 687 __ rorxl(rax, rbx, 31); |
| 688 __ rorxl(rax, Operand(rbx, rcx, times_4, 10000), 31); |
| 689 } |
| 690 } |
| 691 |
599 // xchg. | 692 // xchg. |
600 { | 693 { |
601 __ xchgq(rax, rax); | 694 __ xchgq(rax, rax); |
602 __ xchgq(rax, rbx); | 695 __ xchgq(rax, rbx); |
603 __ xchgq(rbx, rbx); | 696 __ xchgq(rbx, rbx); |
604 __ xchgq(rbx, Operand(rsp, 12)); | 697 __ xchgq(rbx, Operand(rsp, 12)); |
605 } | 698 } |
606 | 699 |
607 // Nop instructions | 700 // Nop instructions |
608 for (int i = 0; i < 16; i++) { | 701 for (int i = 0; i < 16; i++) { |
(...skipping 10 matching lines...) Expand all Loading... |
619 #ifdef OBJECT_PRINT | 712 #ifdef OBJECT_PRINT |
620 OFStream os(stdout); | 713 OFStream os(stdout); |
621 code->Print(os); | 714 code->Print(os); |
622 byte* begin = code->instruction_start(); | 715 byte* begin = code->instruction_start(); |
623 byte* end = begin + code->instruction_size(); | 716 byte* end = begin + code->instruction_size(); |
624 disasm::Disassembler::Disassemble(stdout, begin, end); | 717 disasm::Disassembler::Disassemble(stdout, begin, end); |
625 #endif | 718 #endif |
626 } | 719 } |
627 | 720 |
628 #undef __ | 721 #undef __ |
OLD | NEW |