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/runtime/runtime-utils.h" | 5 #include "src/runtime/runtime-utils.h" |
6 | 6 |
7 #include "src/arguments.h" | 7 #include "src/arguments.h" |
8 #include "src/debug/debug-evaluate.h" | 8 #include "src/debug/debug-evaluate.h" |
9 #include "src/debug/debug-frames.h" | 9 #include "src/debug/debug-frames.h" |
10 #include "src/debug/debug-scopes.h" | 10 #include "src/debug/debug-scopes.h" |
(...skipping 1693 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1704 } | 1704 } |
1705 | 1705 |
1706 // Set one shot breakpoints for the suspended generator object. | 1706 // Set one shot breakpoints for the suspended generator object. |
1707 RUNTIME_FUNCTION(Runtime_DebugPrepareStepInSuspendedGenerator) { | 1707 RUNTIME_FUNCTION(Runtime_DebugPrepareStepInSuspendedGenerator) { |
1708 HandleScope scope(isolate); | 1708 HandleScope scope(isolate); |
1709 DCHECK_EQ(0, args.length()); | 1709 DCHECK_EQ(0, args.length()); |
1710 isolate->debug()->PrepareStepInSuspendedGenerator(); | 1710 isolate->debug()->PrepareStepInSuspendedGenerator(); |
1711 return isolate->heap()->undefined_value(); | 1711 return isolate->heap()->undefined_value(); |
1712 } | 1712 } |
1713 | 1713 |
| 1714 RUNTIME_FUNCTION(Runtime_DebugRecordAsyncFunction) { |
| 1715 HandleScope scope(isolate); |
| 1716 DCHECK_EQ(1, args.length()); |
| 1717 CONVERT_ARG_HANDLE_CHECKED(JSGeneratorObject, generator, 0); |
| 1718 isolate->debug()->RecordAsyncFunction(generator); |
| 1719 return isolate->heap()->undefined_value(); |
| 1720 } |
| 1721 |
1714 RUNTIME_FUNCTION(Runtime_DebugPushPromise) { | 1722 RUNTIME_FUNCTION(Runtime_DebugPushPromise) { |
1715 DCHECK(args.length() == 2); | 1723 DCHECK(args.length() == 2); |
1716 HandleScope scope(isolate); | 1724 HandleScope scope(isolate); |
1717 CONVERT_ARG_HANDLE_CHECKED(JSObject, promise, 0); | 1725 CONVERT_ARG_HANDLE_CHECKED(JSObject, promise, 0); |
1718 CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 1); | 1726 CONVERT_ARG_HANDLE_CHECKED(JSFunction, function, 1); |
1719 isolate->PushPromise(promise, function); | 1727 isolate->PushPromise(promise, function); |
1720 // If we are in step-in mode, flood the handler. | 1728 // If we are in step-in mode, flood the handler. |
1721 isolate->debug()->EnableStepIn(); | 1729 isolate->debug()->EnableStepIn(); |
1722 return isolate->heap()->undefined_value(); | 1730 return isolate->heap()->undefined_value(); |
1723 } | 1731 } |
(...skipping 21 matching lines...) Expand all Loading... |
1745 return Smi::FromInt(isolate->debug()->is_active()); | 1753 return Smi::FromInt(isolate->debug()->is_active()); |
1746 } | 1754 } |
1747 | 1755 |
1748 | 1756 |
1749 RUNTIME_FUNCTION(Runtime_DebugBreakInOptimizedCode) { | 1757 RUNTIME_FUNCTION(Runtime_DebugBreakInOptimizedCode) { |
1750 UNIMPLEMENTED(); | 1758 UNIMPLEMENTED(); |
1751 return NULL; | 1759 return NULL; |
1752 } | 1760 } |
1753 } // namespace internal | 1761 } // namespace internal |
1754 } // namespace v8 | 1762 } // namespace v8 |
OLD | NEW |