| 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 457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 468 __ cmovq(greater, rax, Operand(rdx, 3)); | 468 __ cmovq(greater, rax, Operand(rdx, 3)); |
| 469 } | 469 } |
| 470 | 470 |
| 471 { | 471 { |
| 472 if (CpuFeatures::IsSupported(SSE4_1)) { | 472 if (CpuFeatures::IsSupported(SSE4_1)) { |
| 473 CpuFeatureScope scope(&assm, SSE4_1); | 473 CpuFeatureScope scope(&assm, SSE4_1); |
| 474 __ extractps(rax, xmm1, 0); | 474 __ extractps(rax, xmm1, 0); |
| 475 } | 475 } |
| 476 } | 476 } |
| 477 | 477 |
| 478 // AVX instruction |
| 479 { |
| 480 if (CpuFeatures::IsSupported(AVX)) { |
| 481 CpuFeatureScope scope(&assm, AVX); |
| 482 __ vaddsd(xmm0, xmm1, xmm2); |
| 483 __ vaddsd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
| 484 __ vmulsd(xmm0, xmm1, xmm2); |
| 485 __ vmulsd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
| 486 __ vsubsd(xmm0, xmm1, xmm2); |
| 487 __ vsubsd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
| 488 __ vdivsd(xmm0, xmm1, xmm2); |
| 489 __ vdivsd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
| 490 } |
| 491 } |
| 492 |
| 478 // FMA3 instruction | 493 // FMA3 instruction |
| 479 { | 494 { |
| 480 if (CpuFeatures::IsSupported(FMA3)) { | 495 if (CpuFeatures::IsSupported(FMA3)) { |
| 481 CpuFeatureScope scope(&assm, FMA3); | 496 CpuFeatureScope scope(&assm, FMA3); |
| 482 __ vfmadd132sd(xmm0, xmm1, xmm2); | 497 __ vfmadd132sd(xmm0, xmm1, xmm2); |
| 483 __ vfmadd132sd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); | 498 __ vfmadd132sd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
| 484 __ vfmadd213sd(xmm0, xmm1, xmm2); | 499 __ vfmadd213sd(xmm0, xmm1, xmm2); |
| 485 __ vfmadd213sd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); | 500 __ vfmadd213sd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
| 486 __ vfmadd231sd(xmm0, xmm1, xmm2); | 501 __ vfmadd231sd(xmm0, xmm1, xmm2); |
| 487 __ vfmadd231sd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); | 502 __ vfmadd231sd(xmm0, xmm1, Operand(rbx, rcx, times_4, 10000)); |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 566 #ifdef OBJECT_PRINT | 581 #ifdef OBJECT_PRINT |
| 567 OFStream os(stdout); | 582 OFStream os(stdout); |
| 568 code->Print(os); | 583 code->Print(os); |
| 569 byte* begin = code->instruction_start(); | 584 byte* begin = code->instruction_start(); |
| 570 byte* end = begin + code->instruction_size(); | 585 byte* end = begin + code->instruction_size(); |
| 571 disasm::Disassembler::Disassemble(stdout, begin, end); | 586 disasm::Disassembler::Disassemble(stdout, begin, end); |
| 572 #endif | 587 #endif |
| 573 } | 588 } |
| 574 | 589 |
| 575 #undef __ | 590 #undef __ |
| OLD | NEW |