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-generic-lowering.h" | 5 #include "src/compiler/js-generic-lowering.h" |
6 | 6 |
7 #include "src/ast/ast.h" | 7 #include "src/ast/ast.h" |
8 #include "src/builtins/builtins-constructor.h" | 8 #include "src/builtins/builtins-constructor.h" |
9 #include "src/code-factory.h" | 9 #include "src/code-factory.h" |
10 #include "src/code-stubs.h" | 10 #include "src/code-stubs.h" |
(...skipping 650 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
661 if (use->opcode() == IrOpcode::kIfSuccess) { | 661 if (use->opcode() == IrOpcode::kIfSuccess) { |
662 use->ReplaceUses(merge); | 662 use->ReplaceUses(merge); |
663 merge->ReplaceInput(1, use); | 663 merge->ReplaceInput(1, use); |
664 } | 664 } |
665 } | 665 } |
666 | 666 |
667 // Turn the stack check into a runtime call. | 667 // Turn the stack check into a runtime call. |
668 ReplaceWithRuntimeCall(node, Runtime::kStackGuard); | 668 ReplaceWithRuntimeCall(node, Runtime::kStackGuard); |
669 } | 669 } |
670 | 670 |
| 671 void JSGenericLowering::LowerJSDebugger(Node* node) { |
| 672 CallDescriptor::Flags flags = FrameStateFlagForCall(node); |
| 673 Callable callable = CodeFactory::HandleDebuggerStatement(isolate()); |
| 674 ReplaceWithStubCall(node, callable, flags); |
| 675 } |
671 | 676 |
672 Zone* JSGenericLowering::zone() const { return graph()->zone(); } | 677 Zone* JSGenericLowering::zone() const { return graph()->zone(); } |
673 | 678 |
674 | 679 |
675 Isolate* JSGenericLowering::isolate() const { return jsgraph()->isolate(); } | 680 Isolate* JSGenericLowering::isolate() const { return jsgraph()->isolate(); } |
676 | 681 |
677 | 682 |
678 Graph* JSGenericLowering::graph() const { return jsgraph()->graph(); } | 683 Graph* JSGenericLowering::graph() const { return jsgraph()->graph(); } |
679 | 684 |
680 | 685 |
681 CommonOperatorBuilder* JSGenericLowering::common() const { | 686 CommonOperatorBuilder* JSGenericLowering::common() const { |
682 return jsgraph()->common(); | 687 return jsgraph()->common(); |
683 } | 688 } |
684 | 689 |
685 | 690 |
686 MachineOperatorBuilder* JSGenericLowering::machine() const { | 691 MachineOperatorBuilder* JSGenericLowering::machine() const { |
687 return jsgraph()->machine(); | 692 return jsgraph()->machine(); |
688 } | 693 } |
689 | 694 |
690 } // namespace compiler | 695 } // namespace compiler |
691 } // namespace internal | 696 } // namespace internal |
692 } // namespace v8 | 697 } // namespace v8 |
OLD | NEW |