| 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/ast.h" | 5 #include "src/ast.h" |
| 6 #include "src/ast-numbering.h" | 6 #include "src/ast-numbering.h" |
| 7 #include "src/compiler/access-builder.h" | 7 #include "src/compiler/access-builder.h" |
| 8 #include "src/compiler/ast-graph-builder.h" | 8 #include "src/compiler/ast-graph-builder.h" |
| 9 #include "src/compiler/common-operator.h" | 9 #include "src/compiler/common-operator.h" |
| 10 #include "src/compiler/generic-node-inl.h" | 10 #include "src/compiler/generic-node-inl.h" |
| (...skipping 391 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 402 if (FLAG_trace_turbo_inlining) { | 402 if (FLAG_trace_turbo_inlining) { |
| 403 SmartArrayPointer<char> name = function->shared()->DebugName()->ToCString(); | 403 SmartArrayPointer<char> name = function->shared()->DebugName()->ToCString(); |
| 404 PrintF("Inlining %s into %s\n", name.get(), | 404 PrintF("Inlining %s into %s\n", name.get(), |
| 405 info_->shared_info()->DebugName()->ToCString().get()); | 405 info_->shared_info()->DebugName()->ToCString().get()); |
| 406 } | 406 } |
| 407 | 407 |
| 408 Graph graph(info.zone()); | 408 Graph graph(info.zone()); |
| 409 JSGraph jsgraph(&graph, jsgraph_->common(), jsgraph_->javascript(), | 409 JSGraph jsgraph(&graph, jsgraph_->common(), jsgraph_->javascript(), |
| 410 jsgraph_->machine()); | 410 jsgraph_->machine()); |
| 411 | 411 |
| 412 AstGraphBuilder graph_builder(&info, &jsgraph); | 412 AstGraphBuilder graph_builder(local_zone_, &info, &jsgraph); |
| 413 graph_builder.CreateGraph(); | 413 graph_builder.CreateGraph(); |
| 414 Inlinee::UnifyReturn(&jsgraph); | 414 Inlinee::UnifyReturn(&jsgraph); |
| 415 | 415 |
| 416 CopyVisitor visitor(&graph, jsgraph_->graph(), info.zone()); | 416 CopyVisitor visitor(&graph, jsgraph_->graph(), info.zone()); |
| 417 visitor.CopyGraph(); | 417 visitor.CopyGraph(); |
| 418 | 418 |
| 419 Inlinee inlinee(visitor.GetCopy(graph.start()), visitor.GetCopy(graph.end())); | 419 Inlinee inlinee(visitor.GetCopy(graph.start()), visitor.GetCopy(graph.end())); |
| 420 | 420 |
| 421 Node* outer_frame_state = call.frame_state(); | 421 Node* outer_frame_state = call.frame_state(); |
| 422 // Insert argument adaptor frame if required. | 422 // Insert argument adaptor frame if required. |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 498 info_->shared_info()->DebugName()->ToCString().get()); | 498 info_->shared_info()->DebugName()->ToCString().get()); |
| 499 } | 499 } |
| 500 NodeProperties::ReplaceWithValue(call_node, r.first, r.second); | 500 NodeProperties::ReplaceWithValue(call_node, r.first, r.second); |
| 501 call_node->RemoveAllInputs(); | 501 call_node->RemoveAllInputs(); |
| 502 DCHECK_EQ(0, call_node->UseCount()); | 502 DCHECK_EQ(0, call_node->UseCount()); |
| 503 } | 503 } |
| 504 } | 504 } |
| 505 } | 505 } |
| 506 } | 506 } |
| 507 } // namespace v8::internal::compiler | 507 } // namespace v8::internal::compiler |
| OLD | NEW |