Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(109)

Unified Diff: src/js/promise.js

Issue 2431793003: [promises] move PromiseResolveThenableJob debugging code to runtime function (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/heap-symbols.h ('k') | src/runtime/runtime.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/js/promise.js
diff --git a/src/js/promise.js b/src/js/promise.js
index dc6d8bf534287f7219f5f91a24965852eab70515..af1336c0141a9364bf07d13a321874243ee0d46e 100644
--- a/src/js/promise.js
+++ b/src/js/promise.js
@@ -295,18 +295,12 @@ function ResolvePromise(promise, resolution) {
if (IS_CALLABLE(then)) {
var callbacks = CreateResolvingFunctions(promise, false);
- var id, name, instrumenting = DEBUG_IS_ACTIVE;
- if (instrumenting) {
- if (IsPromise(resolution)) {
+ if (DEBUG_IS_ACTIVE && IsPromise(resolution)) {
// Mark the dependency of the new promise on the resolution
- SET_PRIVATE(resolution, promiseHandledBySymbol, promise);
- }
- id = %DebugNextMicrotaskId();
- name = "PromiseResolveThenableJob";
- %DebugAsyncTaskEvent("enqueue", id, name);
+ SET_PRIVATE(resolution, promiseHandledBySymbol, promise);
}
%EnqueuePromiseResolveThenableJob(
- resolution, then, callbacks.resolve, callbacks.reject, id, name);
+ resolution, then, callbacks.resolve, callbacks.reject);
return;
}
}
« no previous file with comments | « src/heap-symbols.h ('k') | src/runtime/runtime.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698