| OLD | NEW |
| 1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/compiler/wasm-compiler.h" | 5 #include "src/compiler/wasm-compiler.h" |
| 6 | 6 |
| 7 #include "src/isolate-inl.h" | 7 #include "src/isolate-inl.h" |
| 8 | 8 |
| 9 #include "src/base/platform/elapsed-timer.h" | 9 #include "src/base/platform/elapsed-timer.h" |
| 10 #include "src/base/platform/platform.h" | 10 #include "src/base/platform/platform.h" |
| (...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 495 // easier when I do them one by one. | 495 // easier when I do them one by one. |
| 496 // kExprI64Add: | 496 // kExprI64Add: |
| 497 case wasm::kExprI64Add: | 497 case wasm::kExprI64Add: |
| 498 op = m->Int64Add(); | 498 op = m->Int64Add(); |
| 499 break; | 499 break; |
| 500 // kExprI64Sub: | 500 // kExprI64Sub: |
| 501 case wasm::kExprI64Sub: | 501 case wasm::kExprI64Sub: |
| 502 op = m->Int64Sub(); | 502 op = m->Int64Sub(); |
| 503 break; | 503 break; |
| 504 // kExprI64Mul: | 504 // kExprI64Mul: |
| 505 case wasm::kExprI64Mul: |
| 506 op = m->Int64Mul(); |
| 507 break; |
| 505 // kExprI64DivS: | 508 // kExprI64DivS: |
| 506 case wasm::kExprI64DivS: | 509 case wasm::kExprI64DivS: |
| 507 return BuildI64DivS(left, right); | 510 return BuildI64DivS(left, right); |
| 508 // kExprI64DivU: | 511 // kExprI64DivU: |
| 509 case wasm::kExprI64DivU: | 512 case wasm::kExprI64DivU: |
| 510 return BuildI64DivU(left, right); | 513 return BuildI64DivU(left, right); |
| 511 // kExprI64RemS: | 514 // kExprI64RemS: |
| 512 case wasm::kExprI64RemS: | 515 case wasm::kExprI64RemS: |
| 513 return BuildI64RemS(left, right); | 516 return BuildI64RemS(left, right); |
| 514 // kExprI64RemU: | 517 // kExprI64RemU: |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 566 std::swap(left, right); | 569 std::swap(left, right); |
| 567 break; | 570 break; |
| 568 case wasm::kExprI64GeU: | 571 case wasm::kExprI64GeU: |
| 569 op = m->Uint64LessThanOrEqual(); | 572 op = m->Uint64LessThanOrEqual(); |
| 570 std::swap(left, right); | 573 std::swap(left, right); |
| 571 break; | 574 break; |
| 572 | 575 |
| 573 #if WASM_64 | 576 #if WASM_64 |
| 574 // Opcodes only supported on 64-bit platforms. | 577 // Opcodes only supported on 64-bit platforms. |
| 575 // TODO(titzer): query the machine operator builder here instead of #ifdef. | 578 // TODO(titzer): query the machine operator builder here instead of #ifdef. |
| 576 case wasm::kExprI64Mul: | |
| 577 op = m->Int64Mul(); | |
| 578 break; | |
| 579 case wasm::kExprI64Ror: | 579 case wasm::kExprI64Ror: |
| 580 op = m->Word64Ror(); | 580 op = m->Word64Ror(); |
| 581 break; | 581 break; |
| 582 case wasm::kExprI64Rol: | 582 case wasm::kExprI64Rol: |
| 583 return BuildI64Rol(left, right); | 583 return BuildI64Rol(left, right); |
| 584 #endif | 584 #endif |
| 585 | 585 |
| 586 case wasm::kExprF32CopySign: | 586 case wasm::kExprF32CopySign: |
| 587 return BuildF32CopySign(left, right); | 587 return BuildF32CopySign(left, right); |
| 588 case wasm::kExprF64CopySign: | 588 case wasm::kExprF64CopySign: |
| (...skipping 2064 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2653 static_cast<int>(function.code_end_offset - function.code_start_offset), | 2653 static_cast<int>(function.code_end_offset - function.code_start_offset), |
| 2654 decode_ms, static_cast<int>(graph.NodeCount()), compile_ms); | 2654 decode_ms, static_cast<int>(graph.NodeCount()), compile_ms); |
| 2655 } | 2655 } |
| 2656 return code; | 2656 return code; |
| 2657 } | 2657 } |
| 2658 | 2658 |
| 2659 | 2659 |
| 2660 } // namespace compiler | 2660 } // namespace compiler |
| 2661 } // namespace internal | 2661 } // namespace internal |
| 2662 } // namespace v8 | 2662 } // namespace v8 |
| OLD | NEW |