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

Side by Side Diff: src/compiler/frame-states.cc

Issue 1514413002: [Interpreter] Generate valid FrameStates in the Bytecode Graph Builder. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@int_materialize_sf
Patch Set: Add checks that environment doesn't change after state nodes are attached 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
« no previous file with comments | « src/compiler/frame-states.h ('k') | src/compiler/instruction.h » ('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 2015 the V8 project authors. All rights reserved. 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 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/base/functional.h" 5 #include "src/base/functional.h"
6 #include "src/compiler/frame-states.h" 6 #include "src/compiler/frame-states.h"
7 #include "src/handles-inl.h" 7 #include "src/handles-inl.h"
8 8
9 namespace v8 { 9 namespace v8 {
10 namespace internal { 10 namespace internal {
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 return base::hash_combine(static_cast<int>(info.type()), info.bailout_id(), 44 return base::hash_combine(static_cast<int>(info.type()), info.bailout_id(),
45 info.state_combine()); 45 info.state_combine());
46 } 46 }
47 47
48 48
49 std::ostream& operator<<(std::ostream& os, FrameStateType type) { 49 std::ostream& operator<<(std::ostream& os, FrameStateType type) {
50 switch (type) { 50 switch (type) {
51 case FrameStateType::kJavaScriptFunction: 51 case FrameStateType::kJavaScriptFunction:
52 os << "JS_FRAME"; 52 os << "JS_FRAME";
53 break; 53 break;
54 case FrameStateType::kInterpretedFunction:
55 os << "INTERPRETED_FRAME";
56 break;
54 case FrameStateType::kArgumentsAdaptor: 57 case FrameStateType::kArgumentsAdaptor:
55 os << "ARGUMENTS_ADAPTOR"; 58 os << "ARGUMENTS_ADAPTOR";
56 break; 59 break;
57 case FrameStateType::kConstructStub: 60 case FrameStateType::kConstructStub:
58 os << "CONSTRUCT_STUB"; 61 os << "CONSTRUCT_STUB";
59 break; 62 break;
60 } 63 }
61 return os; 64 return os;
62 } 65 }
63 66
64 67
65 std::ostream& operator<<(std::ostream& os, FrameStateInfo const& info) { 68 std::ostream& operator<<(std::ostream& os, FrameStateInfo const& info) {
66 os << info.type() << ", " << info.bailout_id() << ", " 69 os << info.type() << ", " << info.bailout_id() << ", "
67 << info.state_combine(); 70 << info.state_combine();
68 Handle<SharedFunctionInfo> shared_info; 71 Handle<SharedFunctionInfo> shared_info;
69 if (info.shared_info().ToHandle(&shared_info)) { 72 if (info.shared_info().ToHandle(&shared_info)) {
70 os << ", " << Brief(*shared_info); 73 os << ", " << Brief(*shared_info);
71 } 74 }
72 return os; 75 return os;
73 } 76 }
74 77
75 } // namespace compiler 78 } // namespace compiler
76 } // namespace internal 79 } // namespace internal
77 } // namespace v8 80 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/frame-states.h ('k') | src/compiler/instruction.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698