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/simplified-lowering.h" | 5 #include "src/compiler/simplified-lowering.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "src/address-map.h" | 9 #include "src/address-map.h" |
10 #include "src/base/bits.h" | 10 #include "src/base/bits.h" |
(...skipping 551 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
562 VisitNode(node, info->truncation(), nullptr); | 562 VisitNode(node, info->truncation(), nullptr); |
563 TRACE(" ==> output "); | 563 TRACE(" ==> output "); |
564 PrintOutputInfo(info); | 564 PrintOutputInfo(info); |
565 TRACE("\n"); | 565 TRACE("\n"); |
566 } | 566 } |
567 } | 567 } |
568 | 568 |
569 void Run(SimplifiedLowering* lowering) { | 569 void Run(SimplifiedLowering* lowering) { |
570 RunTruncationPropagationPhase(); | 570 RunTruncationPropagationPhase(); |
571 | 571 |
572 if (lowering->flags() & SimplifiedLowering::kTypeFeedbackEnabled) { | 572 // Run type propagation. |
573 ResetNodeInfoState(); | 573 ResetNodeInfoState(); |
574 RunTypePropagationPhase(); | 574 RunTypePropagationPhase(); |
575 } | |
576 | 575 |
577 // Run lowering and change insertion phase. | 576 // Run lowering and change insertion phase. |
578 TRACE("--{Simplified lowering phase}--\n"); | 577 TRACE("--{Simplified lowering phase}--\n"); |
579 phase_ = LOWER; | 578 phase_ = LOWER; |
580 // Process nodes from the collected {nodes_} vector. | 579 // Process nodes from the collected {nodes_} vector. |
581 for (NodeVector::iterator i = nodes_.begin(); i != nodes_.end(); ++i) { | 580 for (NodeVector::iterator i = nodes_.begin(); i != nodes_.end(); ++i) { |
582 Node* node = *i; | 581 Node* node = *i; |
583 NodeInfo* info = GetInfo(node); | 582 NodeInfo* info = GetInfo(node); |
584 TRACE(" visit #%d: %s\n", node->id(), node->op()->mnemonic()); | 583 TRACE(" visit #%d: %s\n", node->id(), node->op()->mnemonic()); |
585 // Reuse {VisitNode()} so the representation rules are in one place. | 584 // Reuse {VisitNode()} so the representation rules are in one place. |
(...skipping 2697 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3283 isolate(), graph()->zone(), callable.descriptor(), 0, flags, | 3282 isolate(), graph()->zone(), callable.descriptor(), 0, flags, |
3284 Operator::kNoProperties); | 3283 Operator::kNoProperties); |
3285 to_number_operator_.set(common()->Call(desc)); | 3284 to_number_operator_.set(common()->Call(desc)); |
3286 } | 3285 } |
3287 return to_number_operator_.get(); | 3286 return to_number_operator_.get(); |
3288 } | 3287 } |
3289 | 3288 |
3290 } // namespace compiler | 3289 } // namespace compiler |
3291 } // namespace internal | 3290 } // namespace internal |
3292 } // namespace v8 | 3291 } // namespace v8 |
OLD | NEW |