OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/crankshaft/s390/lithium-s390.h" | 5 #include "src/crankshaft/s390/lithium-s390.h" |
6 | 6 |
7 #include <sstream> | 7 #include <sstream> |
8 | 8 |
9 #include "src/crankshaft/hydrogen-osr.h" | 9 #include "src/crankshaft/hydrogen-osr.h" |
10 #include "src/crankshaft/lithium-inl.h" | 10 #include "src/crankshaft/lithium-inl.h" |
(...skipping 601 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
612 LOperand* right = UseFixedDouble(instr->right(), d2); | 612 LOperand* right = UseFixedDouble(instr->right(), d2); |
613 LArithmeticD* result = new (zone()) LArithmeticD(op, left, right); | 613 LArithmeticD* result = new (zone()) LArithmeticD(op, left, right); |
614 // We call a C function for double modulo. It can't trigger a GC. We need | 614 // We call a C function for double modulo. It can't trigger a GC. We need |
615 // to use fixed result register for the call. | 615 // to use fixed result register for the call. |
616 // TODO(fschneider): Allow any register as input registers. | 616 // TODO(fschneider): Allow any register as input registers. |
617 return MarkAsCall(DefineFixedDouble(result, d1), instr); | 617 return MarkAsCall(DefineFixedDouble(result, d1), instr); |
618 } else { | 618 } else { |
619 LOperand* left = UseRegisterAtStart(instr->BetterLeftOperand()); | 619 LOperand* left = UseRegisterAtStart(instr->BetterLeftOperand()); |
620 LOperand* right = UseRegisterAtStart(instr->BetterRightOperand()); | 620 LOperand* right = UseRegisterAtStart(instr->BetterRightOperand()); |
621 LArithmeticD* result = new (zone()) LArithmeticD(op, left, right); | 621 LArithmeticD* result = new (zone()) LArithmeticD(op, left, right); |
622 return DefineSameAsFirst(result); | 622 return CpuFeatures::IsSupported(VECTOR_FACILITY) |
| 623 ? DefineAsRegister(result) |
| 624 : DefineSameAsFirst(result); |
623 } | 625 } |
624 } | 626 } |
625 | 627 |
626 LInstruction* LChunkBuilder::DoArithmeticT(Token::Value op, | 628 LInstruction* LChunkBuilder::DoArithmeticT(Token::Value op, |
627 HBinaryOperation* instr) { | 629 HBinaryOperation* instr) { |
628 HValue* left = instr->left(); | 630 HValue* left = instr->left(); |
629 HValue* right = instr->right(); | 631 HValue* right = instr->right(); |
630 DCHECK(left->representation().IsTagged()); | 632 DCHECK(left->representation().IsTagged()); |
631 DCHECK(right->representation().IsTagged()); | 633 DCHECK(right->representation().IsTagged()); |
632 LOperand* context = UseFixed(instr->context(), cp); | 634 LOperand* context = UseFixed(instr->context(), cp); |
(...skipping 1512 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2145 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2147 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
2146 LOperand* object = UseRegister(instr->object()); | 2148 LOperand* object = UseRegister(instr->object()); |
2147 LOperand* index = UseTempRegister(instr->index()); | 2149 LOperand* index = UseTempRegister(instr->index()); |
2148 LLoadFieldByIndex* load = new (zone()) LLoadFieldByIndex(object, index); | 2150 LLoadFieldByIndex* load = new (zone()) LLoadFieldByIndex(object, index); |
2149 LInstruction* result = DefineSameAsFirst(load); | 2151 LInstruction* result = DefineSameAsFirst(load); |
2150 return AssignPointerMap(result); | 2152 return AssignPointerMap(result); |
2151 } | 2153 } |
2152 | 2154 |
2153 } // namespace internal | 2155 } // namespace internal |
2154 } // namespace v8 | 2156 } // namespace v8 |
OLD | NEW |