| 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/compiler/instruction-selector-impl.h" | 5 #include "src/compiler/instruction-selector-impl.h" |
| 6 #include "src/compiler/node-matchers.h" | 6 #include "src/compiler/node-matchers.h" |
| 7 #include "src/compiler/node-properties-inl.h" | 7 #include "src/compiler/node-properties-inl.h" |
| 8 | 8 |
| 9 namespace v8 { | 9 namespace v8 { |
| 10 namespace internal { | 10 namespace internal { |
| (...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 void InstructionSelector::VisitWord32Shr(Node* node) { | 264 void InstructionSelector::VisitWord32Shr(Node* node) { |
| 265 VisitShift(this, node, kIA32Shr); | 265 VisitShift(this, node, kIA32Shr); |
| 266 } | 266 } |
| 267 | 267 |
| 268 | 268 |
| 269 void InstructionSelector::VisitWord32Sar(Node* node) { | 269 void InstructionSelector::VisitWord32Sar(Node* node) { |
| 270 VisitShift(this, node, kIA32Sar); | 270 VisitShift(this, node, kIA32Sar); |
| 271 } | 271 } |
| 272 | 272 |
| 273 | 273 |
| 274 void InstructionSelector::VisitWord32Ror(Node* node) { |
| 275 VisitShift(this, node, kIA32Ror); |
| 276 } |
| 277 |
| 278 |
| 274 void InstructionSelector::VisitInt32Add(Node* node) { | 279 void InstructionSelector::VisitInt32Add(Node* node) { |
| 275 VisitBinop(this, node, kIA32Add); | 280 VisitBinop(this, node, kIA32Add); |
| 276 } | 281 } |
| 277 | 282 |
| 278 | 283 |
| 279 void InstructionSelector::VisitInt32Sub(Node* node) { | 284 void InstructionSelector::VisitInt32Sub(Node* node) { |
| 280 IA32OperandGenerator g(this); | 285 IA32OperandGenerator g(this); |
| 281 Int32BinopMatcher m(node); | 286 Int32BinopMatcher m(node); |
| 282 if (m.left().Is(0)) { | 287 if (m.left().Is(0)) { |
| 283 Emit(kIA32Neg, g.DefineSameAsFirst(node), g.Use(m.right().node())); | 288 Emit(kIA32Neg, g.DefineSameAsFirst(node), g.Use(m.right().node())); |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 551 if (descriptor->kind() == CallDescriptor::kCallAddress && | 556 if (descriptor->kind() == CallDescriptor::kCallAddress && |
| 552 buffer.pushed_count > 0) { | 557 buffer.pushed_count > 0) { |
| 553 DCHECK(deoptimization == NULL && continuation == NULL); | 558 DCHECK(deoptimization == NULL && continuation == NULL); |
| 554 Emit(kPopStack | MiscField::encode(buffer.pushed_count), NULL); | 559 Emit(kPopStack | MiscField::encode(buffer.pushed_count), NULL); |
| 555 } | 560 } |
| 556 } | 561 } |
| 557 | 562 |
| 558 } // namespace compiler | 563 } // namespace compiler |
| 559 } // namespace internal | 564 } // namespace internal |
| 560 } // namespace v8 | 565 } // namespace v8 |
| OLD | NEW |