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 <memory> | 7 #include <memory> |
8 | 8 |
9 #include "src/assembler-inl.h" | 9 #include "src/assembler-inl.h" |
10 #include "src/base/platform/elapsed-timer.h" | 10 #include "src/base/platform/elapsed-timer.h" |
(...skipping 3390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3401 inputs[1]); | 3401 inputs[1]); |
3402 case wasm::kExprF32x4Max: | 3402 case wasm::kExprF32x4Max: |
3403 return graph()->NewNode(jsgraph()->machine()->Float32x4Max(), inputs[0], | 3403 return graph()->NewNode(jsgraph()->machine()->Float32x4Max(), inputs[0], |
3404 inputs[1]); | 3404 inputs[1]); |
3405 case wasm::kExprF32x4Eq: | 3405 case wasm::kExprF32x4Eq: |
3406 return graph()->NewNode(jsgraph()->machine()->Float32x4Equal(), inputs[0], | 3406 return graph()->NewNode(jsgraph()->machine()->Float32x4Equal(), inputs[0], |
3407 inputs[1]); | 3407 inputs[1]); |
3408 case wasm::kExprF32x4Ne: | 3408 case wasm::kExprF32x4Ne: |
3409 return graph()->NewNode(jsgraph()->machine()->Float32x4NotEqual(), | 3409 return graph()->NewNode(jsgraph()->machine()->Float32x4NotEqual(), |
3410 inputs[0], inputs[1]); | 3410 inputs[0], inputs[1]); |
| 3411 // TODO(aseemgarg): Get rid of GreaterThan and GreaterThanEquals machine ops |
| 3412 // for all SIMD types. |
| 3413 case wasm::kExprF32x4Gt: |
| 3414 return graph()->NewNode(jsgraph()->machine()->Float32x4GreaterThan(), |
| 3415 inputs[0], inputs[1]); |
| 3416 case wasm::kExprF32x4Ge: |
| 3417 return graph()->NewNode( |
| 3418 jsgraph()->machine()->Float32x4GreaterThanOrEqual(), inputs[0], |
| 3419 inputs[1]); |
| 3420 case wasm::kExprF32x4Lt: |
| 3421 return graph()->NewNode(jsgraph()->machine()->Float32x4LessThan(), |
| 3422 inputs[0], inputs[1]); |
| 3423 case wasm::kExprF32x4Le: |
| 3424 return graph()->NewNode(jsgraph()->machine()->Float32x4LessThanOrEqual(), |
| 3425 inputs[0], inputs[1]); |
3411 case wasm::kExprI32x4Splat: | 3426 case wasm::kExprI32x4Splat: |
3412 return graph()->NewNode(jsgraph()->machine()->Int32x4Splat(), inputs[0]); | 3427 return graph()->NewNode(jsgraph()->machine()->Int32x4Splat(), inputs[0]); |
3413 case wasm::kExprI32x4SConvertF32x4: | 3428 case wasm::kExprI32x4SConvertF32x4: |
3414 return graph()->NewNode(jsgraph()->machine()->Int32x4FromFloat32x4(), | 3429 return graph()->NewNode(jsgraph()->machine()->Int32x4FromFloat32x4(), |
3415 inputs[0]); | 3430 inputs[0]); |
3416 case wasm::kExprI32x4UConvertF32x4: | 3431 case wasm::kExprI32x4UConvertF32x4: |
3417 return graph()->NewNode(jsgraph()->machine()->Uint32x4FromFloat32x4(), | 3432 return graph()->NewNode(jsgraph()->machine()->Uint32x4FromFloat32x4(), |
3418 inputs[0]); | 3433 inputs[0]); |
3419 case wasm::kExprI32x4Neg: | 3434 case wasm::kExprI32x4Neg: |
3420 return graph()->NewNode(jsgraph()->machine()->Int32x4Neg(), inputs[0]); | 3435 return graph()->NewNode(jsgraph()->machine()->Int32x4Neg(), inputs[0]); |
(...skipping 793 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4214 function_->code_end_offset - function_->code_start_offset, | 4229 function_->code_end_offset - function_->code_start_offset, |
4215 codegen_ms); | 4230 codegen_ms); |
4216 } | 4231 } |
4217 | 4232 |
4218 return code; | 4233 return code; |
4219 } | 4234 } |
4220 | 4235 |
4221 } // namespace compiler | 4236 } // namespace compiler |
4222 } // namespace internal | 4237 } // namespace internal |
4223 } // namespace v8 | 4238 } // namespace v8 |
OLD | NEW |