OLD | NEW |
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 #include "src/compiler/js-inlining.h" | 5 #include "src/compiler/js-inlining.h" |
6 | 6 |
7 #include "src/ast.h" | 7 #include "src/ast.h" |
8 #include "src/ast-numbering.h" | 8 #include "src/ast-numbering.h" |
9 #include "src/compiler.h" | 9 #include "src/compiler.h" |
10 #include "src/compiler/all-nodes.h" | 10 #include "src/compiler/all-nodes.h" |
(...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
407 CopyVisitor visitor(&graph, jsgraph_->graph(), &zone); | 407 CopyVisitor visitor(&graph, jsgraph_->graph(), &zone); |
408 visitor.CopyGraph(); | 408 visitor.CopyGraph(); |
409 | 409 |
410 Node* start = visitor.GetCopy(graph.start()); | 410 Node* start = visitor.GetCopy(graph.start()); |
411 Node* end = visitor.GetCopy(graph.end()); | 411 Node* end = visitor.GetCopy(graph.end()); |
412 Node* frame_state = call.frame_state(); | 412 Node* frame_state = call.frame_state(); |
413 | 413 |
414 // Insert argument adaptor frame if required. The callees formal parameter | 414 // Insert argument adaptor frame if required. The callees formal parameter |
415 // count (i.e. value outputs of start node minus target, receiver & context) | 415 // count (i.e. value outputs of start node minus target, receiver & context) |
416 // have to match the number of arguments passed to the call. | 416 // have to match the number of arguments passed to the call. |
417 DCHECK_EQ(parameter_count, start->op()->ValueOutputCount() - 3); | 417 DCHECK_EQ(static_cast<int>(parameter_count), |
| 418 start->op()->ValueOutputCount() - 3); |
418 if (call.formal_arguments() != parameter_count) { | 419 if (call.formal_arguments() != parameter_count) { |
419 frame_state = CreateArgumentsAdaptorFrameState(&call, info.shared_info()); | 420 frame_state = CreateArgumentsAdaptorFrameState(&call, info.shared_info()); |
420 } | 421 } |
421 | 422 |
422 return InlineCall(node, context, frame_state, start, end); | 423 return InlineCall(node, context, frame_state, start, end); |
423 } | 424 } |
424 | 425 |
425 } // namespace compiler | 426 } // namespace compiler |
426 } // namespace internal | 427 } // namespace internal |
427 } // namespace v8 | 428 } // namespace v8 |
OLD | NEW |