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

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

Issue 1859763005: [crankshaft] Fix environment handling after leaving inlined tail call. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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') | src/crankshaft/lithium.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 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 13144 matching lines...) Expand 10 before | Expand all | Expand 10 after
13155 } 13155 }
13156 new_env->ClearHistory(); 13156 new_env->ClearHistory();
13157 return new_env; 13157 return new_env;
13158 } 13158 }
13159 13159
13160 void HEnvironment::MarkAsTailCaller() { 13160 void HEnvironment::MarkAsTailCaller() {
13161 DCHECK_EQ(JS_FUNCTION, frame_type()); 13161 DCHECK_EQ(JS_FUNCTION, frame_type());
13162 frame_type_ = TAIL_CALLER_FUNCTION; 13162 frame_type_ = TAIL_CALLER_FUNCTION;
13163 } 13163 }
13164 13164
13165 void HEnvironment::ClearTailCallerMark() {
13166 DCHECK_EQ(TAIL_CALLER_FUNCTION, frame_type());
13167 frame_type_ = JS_FUNCTION;
13168 }
13169
13165 HEnvironment* HEnvironment::CopyForInlining( 13170 HEnvironment* HEnvironment::CopyForInlining(
13166 Handle<JSFunction> target, int arguments, FunctionLiteral* function, 13171 Handle<JSFunction> target, int arguments, FunctionLiteral* function,
13167 HConstant* undefined, InliningKind inlining_kind, 13172 HConstant* undefined, InliningKind inlining_kind,
13168 TailCallMode syntactic_tail_call_mode) const { 13173 TailCallMode syntactic_tail_call_mode) const {
13169 DCHECK_EQ(JS_FUNCTION, frame_type()); 13174 DCHECK_EQ(JS_FUNCTION, frame_type());
13170 13175
13171 // Outer environment is a copy of this one without the arguments. 13176 // Outer environment is a copy of this one without the arguments.
13172 int arity = function->scope()->num_parameters(); 13177 int arity = function->scope()->num_parameters();
13173 13178
13174 HEnvironment* outer = Copy(); 13179 HEnvironment* outer = Copy();
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
13565 isolate()->GetHTracer()->TraceHydrogen(name(), graph_); 13570 isolate()->GetHTracer()->TraceHydrogen(name(), graph_);
13566 } 13571 }
13567 13572
13568 #ifdef DEBUG 13573 #ifdef DEBUG
13569 graph_->Verify(false); // No full verify. 13574 graph_->Verify(false); // No full verify.
13570 #endif 13575 #endif
13571 } 13576 }
13572 13577
13573 } // namespace internal 13578 } // namespace internal
13574 } // namespace v8 13579 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/hydrogen.h ('k') | src/crankshaft/lithium.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698