Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(340)

Side by Side Diff: src/compiler/x64/instruction-selector-x64.cc

Issue 432373002: [turbofan] Add support for Int32SubWithOverflow. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/compiler/opcodes.h ('k') | test/cctest/compiler/test-instruction-selector-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 7
8 namespace v8 { 8 namespace v8 {
9 namespace internal { 9 namespace internal {
10 namespace compiler { 10 namespace compiler {
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
392 VisitBinop(selector, node, sub_opcode, false); 392 VisitBinop(selector, node, sub_opcode, false);
393 } 393 }
394 } 394 }
395 395
396 396
397 void InstructionSelector::VisitInt32Sub(Node* node) { 397 void InstructionSelector::VisitInt32Sub(Node* node) {
398 VisitSub<int32_t>(this, node, kX64Sub32, kX64Neg32); 398 VisitSub<int32_t>(this, node, kX64Sub32, kX64Neg32);
399 } 399 }
400 400
401 401
402 void InstructionSelector::VisitInt32SubWithOverflow(Node* node) {
403 VisitBinopWithOverflow(this, node, kX64Sub32);
404 }
405
406
402 void InstructionSelector::VisitInt64Sub(Node* node) { 407 void InstructionSelector::VisitInt64Sub(Node* node) {
403 VisitSub<int64_t>(this, node, kX64Sub, kX64Neg); 408 VisitSub<int64_t>(this, node, kX64Sub, kX64Neg);
404 } 409 }
405 410
406 411
407 static void VisitMul(InstructionSelector* selector, Node* node, 412 static void VisitMul(InstructionSelector* selector, Node* node,
408 ArchOpcode opcode) { 413 ArchOpcode opcode) {
409 X64OperandGenerator g(selector); 414 X64OperandGenerator g(selector);
410 Node* left = node->InputAt(0); 415 Node* left = node->InputAt(0);
411 Node* right = node->InputAt(1); 416 Node* right = node->InputAt(1);
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
725 ASSERT(deoptimization == NULL && continuation == NULL); 730 ASSERT(deoptimization == NULL && continuation == NULL);
726 Emit(kPopStack | MiscField::encode(buffer.pushed_count), NULL); 731 Emit(kPopStack | MiscField::encode(buffer.pushed_count), NULL);
727 } 732 }
728 } 733 }
729 734
730 #endif 735 #endif
731 736
732 } // namespace compiler 737 } // namespace compiler
733 } // namespace internal 738 } // namespace internal
734 } // namespace v8 739 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/opcodes.h ('k') | test/cctest/compiler/test-instruction-selector-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698