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

Side by Side Diff: third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp

Issue 2627953005: Make workers inherit the large heap limit of the main isolate. (Closed)
Patch Set: fix tests Created 3 years, 11 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
395 std::unique_ptr<WorkerSettings> workerSettings = 395 std::unique_ptr<WorkerSettings> workerSettings =
396 WTF::wrapUnique(new WorkerSettings(document->settings())); 396 WTF::wrapUnique(new WorkerSettings(document->settings()));
397 std::unique_ptr<WorkerThreadStartupData> startupData = 397 std::unique_ptr<WorkerThreadStartupData> startupData =
398 WorkerThreadStartupData::create( 398 WorkerThreadStartupData::create(
399 m_url, m_loadingDocument->userAgent(), m_mainScriptLoader->script(), 399 m_url, m_loadingDocument->userAgent(), m_mainScriptLoader->script(),
400 nullptr, startMode, 400 nullptr, startMode,
401 contentSecurityPolicy ? contentSecurityPolicy->headers().get() 401 contentSecurityPolicy ? contentSecurityPolicy->headers().get()
402 : nullptr, 402 : nullptr,
403 m_mainScriptLoader->getReferrerPolicy(), starterOrigin, workerClients, 403 m_mainScriptLoader->getReferrerPolicy(), starterOrigin, workerClients,
404 m_mainScriptLoader->responseAddressSpace(), 404 m_mainScriptLoader->responseAddressSpace(),
405 m_mainScriptLoader->originTrialTokens(), std::move(workerSettings)); 405 m_mainScriptLoader->originTrialTokens(), std::move(workerSettings),
406 WorkerV8Settings::Default());
406 407
407 // SharedWorker can sometimes run tasks that are initiated by/associated with 408 // SharedWorker can sometimes run tasks that are initiated by/associated with
408 // a document's frame but these documents can be from a different process. So 409 // a document's frame but these documents can be from a different process. So
409 // we intentionally populate the task runners with null document in order to 410 // we intentionally populate the task runners with null document in order to
410 // use the thread's default task runner. Note that |m_document| should not be 411 // use the thread's default task runner. Note that |m_document| should not be
411 // used as it's a dummy document for loading that doesn't represent the frame 412 // used as it's a dummy document for loading that doesn't represent the frame
412 // of any associated document. 413 // of any associated document.
413 m_parentFrameTaskRunners = ParentFrameTaskRunners::create(nullptr); 414 m_parentFrameTaskRunners = ParentFrameTaskRunners::create(nullptr);
414 415
415 m_loaderProxy = WorkerLoaderProxy::create(this); 416 m_loaderProxy = WorkerLoaderProxy::create(this);
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
465 if (devtoolsAgent) 466 if (devtoolsAgent)
466 devtoolsAgent->dispatchOnInspectorBackend(sessionId, callId, method, 467 devtoolsAgent->dispatchOnInspectorBackend(sessionId, callId, method,
467 message); 468 message);
468 } 469 }
469 470
470 WebSharedWorker* WebSharedWorker::create(WebSharedWorkerClient* client) { 471 WebSharedWorker* WebSharedWorker::create(WebSharedWorkerClient* client) {
471 return new WebSharedWorkerImpl(client); 472 return new WebSharedWorkerImpl(client);
472 } 473 }
473 474
474 } // namespace blink 475 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/WebEmbeddedWorkerImpl.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698