| Index: third_party/WebKit/Source/bindings/core/v8/ScriptStreamer.cpp
|
| diff --git a/third_party/WebKit/Source/bindings/core/v8/ScriptStreamer.cpp b/third_party/WebKit/Source/bindings/core/v8/ScriptStreamer.cpp
|
| index 94bb106cede79388baf860788d27fae901f18d82..eb5221a57f355e672ea12af083355ca0c78c9853 100644
|
| --- a/third_party/WebKit/Source/bindings/core/v8/ScriptStreamer.cpp
|
| +++ b/third_party/WebKit/Source/bindings/core/v8/ScriptStreamer.cpp
|
| @@ -280,10 +280,12 @@ private:
|
| ASSERT(lengthOfBOM == 0 || m_queueTailPosition == 0);
|
|
|
| CachedMetadataHandler* cacheHandler = streamer->resource()->cacheHandler();
|
| - if (cacheHandler && cacheHandler->cachedMetadata(V8ScriptRunner::tagForCodeCache(cacheHandler))) {
|
| - // The resource has a code cache, so it's unnecessary to stream and
|
| - // parse the code. Cancel the streaming and resume the non-streaming
|
| - // code path.
|
| + if (cacheHandler && (cacheHandler->shouldAggressivelyCache() || cacheHandler->cachedMetadata(V8ScriptRunner::tagForCodeCache(cacheHandler)))) {
|
| + // When we should aggressively cache the code cache, we can't use
|
| + // SourceStream because currently V8ScriptRunner doesn't supoprt
|
| + // code caching with SourceStream. And if the resource has a code
|
| + // cache, it's unnecessary to stream and parse the code.
|
| + // Cancel the streaming and resume the non-streaming code path.
|
| streamer->suppressStreaming();
|
| cancel();
|
| return;
|
|
|