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

Side by Side Diff: src/compiler/type-hints.cc

Issue 1487973002: [turbofan] Add binary operation hints for javascript operators. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "src/compiler/type-hints.h"
6
7 namespace v8 {
8 namespace internal {
9 namespace compiler {
10
11 std::ostream& operator<<(std::ostream& os, BinaryOperationHints::Hint hint) {
12 switch (hint) {
13 case BinaryOperationHints::kNone:
14 return os << "None";
15 case BinaryOperationHints::kSignedSmall:
16 return os << "SignedSmall";
17 case BinaryOperationHints::kSigned32:
18 return os << "Signed32";
19 case BinaryOperationHints::kNumber:
20 return os << "Number";
21 case BinaryOperationHints::kString:
22 return os << "String";
23 case BinaryOperationHints::kAny:
24 return os << "Any";
25 }
26 UNREACHABLE();
27 return os;
28 }
29
30
31 std::ostream& operator<<(std::ostream& os, BinaryOperationHints hints) {
32 return os << hints.left() << "*" << hints.right() << "->" << hints.result();
33 }
34
35 } // namespace compiler
36 } // namespace internal
37 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698