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

Side by Side Diff: src/crankshaft/hydrogen.cc

Issue 1872833002: [compiler] Move tracing from backends to compiler. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@local_cleanup-compiler-simplify-5
Patch Set: Rebased. Created 4 years, 8 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/crankshaft/hydrogen.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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/crankshaft/hydrogen.h" 5 #include "src/crankshaft/hydrogen.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "src/allocation-site-scopes.h" 9 #include "src/allocation-site-scopes.h"
10 #include "src/ast/ast-numbering.h" 10 #include "src/ast/ast-numbering.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 return AbortOptimization(kTooManyParameters); 125 return AbortOptimization(kTooManyParameters);
126 } 126 }
127 127
128 if (info()->is_osr() && 128 if (info()->is_osr() &&
129 LUnallocated::TooManyParametersOrStackSlots(scope->num_parameters(), 129 LUnallocated::TooManyParametersOrStackSlots(scope->num_parameters(),
130 scope->num_stack_slots())) { 130 scope->num_stack_slots())) {
131 // Crankshaft would require too many Lithium operands. 131 // Crankshaft would require too many Lithium operands.
132 return AbortOptimization(kTooManyParametersLocals); 132 return AbortOptimization(kTooManyParametersLocals);
133 } 133 }
134 134
135 if (FLAG_trace_opt) {
136 OFStream os(stdout);
137 os << "[compiling method " << Brief(*info()->closure())
138 << " using Crankshaft";
139 if (info()->is_osr()) os << " OSR";
140 os << "]" << std::endl;
141 }
142
143 if (FLAG_trace_hydrogen) { 135 if (FLAG_trace_hydrogen) {
144 isolate()->GetHTracer()->TraceCompilation(info()); 136 isolate()->GetHTracer()->TraceCompilation(info());
145 } 137 }
146 138
147 // Type-check the function. 139 // Type-check the function.
148 AstTyper(info()->isolate(), info()->zone(), info()->closure(), 140 AstTyper(info()->isolate(), info()->zone(), info()->closure(),
149 info()->scope(), info()->osr_ast_id(), info()->literal()) 141 info()->scope(), info()->osr_ast_id(), info()->literal())
150 .Run(); 142 .Run();
151 143
152 // Optimization could have been disabled by the parser. Note that this check 144 // Optimization could have been disabled by the parser. Note that this check
(...skipping 13550 matching lines...) Expand 10 before | Expand all | Expand 10 after
13703 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); 13695 isolate()->GetHTracer()->TraceHydrogen(name(), graph_);
13704 } 13696 }
13705 13697
13706 #ifdef DEBUG 13698 #ifdef DEBUG
13707 graph_->Verify(false); // No full verify. 13699 graph_->Verify(false); // No full verify.
13708 #endif 13700 #endif
13709 } 13701 }
13710 13702
13711 } // namespace internal 13703 } // namespace internal
13712 } // namespace v8 13704 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/hydrogen.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698