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

Side by Side Diff: src/compiler/node-matchers.h

Issue 951903003: [turbofan] Strength reduction for inline comparisons. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 10 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
« no previous file with comments | « src/compiler/machine-operator-reducer.cc ('k') | src/compiler/node-matchers.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 #ifndef V8_COMPILER_NODE_MATCHERS_H_ 5 #ifndef V8_COMPILER_NODE_MATCHERS_H_
6 #define V8_COMPILER_NODE_MATCHERS_H_ 6 #define V8_COMPILER_NODE_MATCHERS_H_
7 7
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "src/compiler/node.h" 10 #include "src/compiler/node.h"
(...skipping 10 matching lines...) Expand all
21 21
22 Node* node() const { return node_; } 22 Node* node() const { return node_; }
23 const Operator* op() const { return node()->op(); } 23 const Operator* op() const { return node()->op(); }
24 IrOpcode::Value opcode() const { return node()->opcode(); } 24 IrOpcode::Value opcode() const { return node()->opcode(); }
25 25
26 bool HasProperty(Operator::Property property) const { 26 bool HasProperty(Operator::Property property) const {
27 return op()->HasProperty(property); 27 return op()->HasProperty(property);
28 } 28 }
29 Node* InputAt(int index) const { return node()->InputAt(index); } 29 Node* InputAt(int index) const { return node()->InputAt(index); }
30 30
31 bool IsComparison() const;
32
31 #define DEFINE_IS_OPCODE(Opcode) \ 33 #define DEFINE_IS_OPCODE(Opcode) \
32 bool Is##Opcode() const { return opcode() == IrOpcode::k##Opcode; } 34 bool Is##Opcode() const { return opcode() == IrOpcode::k##Opcode; }
33 ALL_OP_LIST(DEFINE_IS_OPCODE) 35 ALL_OP_LIST(DEFINE_IS_OPCODE)
34 #undef DEFINE_IS_OPCODE 36 #undef DEFINE_IS_OPCODE
35 37
36 private: 38 private:
37 Node* node_; 39 Node* node_;
38 }; 40 };
39 41
40 42
(...skipping 468 matching lines...) Expand 10 before | Expand all | Expand 10 after
509 typedef BaseWithIndexAndDisplacementMatcher<Int32AddMatcher> 511 typedef BaseWithIndexAndDisplacementMatcher<Int32AddMatcher>
510 BaseWithIndexAndDisplacement32Matcher; 512 BaseWithIndexAndDisplacement32Matcher;
511 typedef BaseWithIndexAndDisplacementMatcher<Int64AddMatcher> 513 typedef BaseWithIndexAndDisplacementMatcher<Int64AddMatcher>
512 BaseWithIndexAndDisplacement64Matcher; 514 BaseWithIndexAndDisplacement64Matcher;
513 515
514 } // namespace compiler 516 } // namespace compiler
515 } // namespace internal 517 } // namespace internal
516 } // namespace v8 518 } // namespace v8
517 519
518 #endif // V8_COMPILER_NODE_MATCHERS_H_ 520 #endif // V8_COMPILER_NODE_MATCHERS_H_
OLDNEW
« no previous file with comments | « src/compiler/machine-operator-reducer.cc ('k') | src/compiler/node-matchers.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698