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

Unified Diff: third_party/WebKit/Source/core/html/parser/BackgroundHTMLParser.cpp

Issue 2181943002: Rename ParsedChunk to TokenizedChunk in core/html/parser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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
Index: third_party/WebKit/Source/core/html/parser/BackgroundHTMLParser.cpp
diff --git a/third_party/WebKit/Source/core/html/parser/BackgroundHTMLParser.cpp b/third_party/WebKit/Source/core/html/parser/BackgroundHTMLParser.cpp
index 2481625632d884b49b75ed3081823bb4bbc04486..7577fea9e593a744f153f68401257b5f43fca721 100644
--- a/third_party/WebKit/Source/core/html/parser/BackgroundHTMLParser.cpp
+++ b/third_party/WebKit/Source/core/html/parser/BackgroundHTMLParser.cpp
@@ -110,7 +110,7 @@ BackgroundHTMLParser::BackgroundHTMLParser(PassRefPtr<WeakReference<BackgroundHT
, m_preloadScanner(wrapUnique(new TokenPreloadScanner(documentURL, std::move(cachedDocumentParameters), mediaValuesCachedData)))
, m_decoder(std::move(config->decoder))
, m_loadingTaskRunner(std::move(loadingTaskRunner))
- , m_parsedChunkQueue(config->parsedChunkQueue.release())
+ , m_tokenizedChunkQueue(config->tokenizedChunkQueue.release())
, m_startingScript(false)
, m_lastBytesReceivedTime(0.0)
{
@@ -177,7 +177,7 @@ void BackgroundHTMLParser::resumeFrom(std::unique_ptr<Checkpoint> checkpoint)
m_input.rewindTo(checkpoint->inputCheckpoint, checkpoint->unparsedInput);
m_preloadScanner->rewindTo(checkpoint->preloadScannerCheckpoint);
m_startingScript = false;
- m_parsedChunkQueue->clear();
+ m_tokenizedChunkQueue->clear();
m_lastBytesReceivedTime = monotonicallyIncreasingTimeMS();
pumpTokenizer();
}
@@ -289,7 +289,7 @@ void BackgroundHTMLParser::sendTokensToMainThread()
#endif
double chunkStartTime = monotonicallyIncreasingTimeMS();
- std::unique_ptr<HTMLDocumentParser::ParsedChunk> chunk = wrapUnique(new HTMLDocumentParser::ParsedChunk);
+ std::unique_ptr<HTMLDocumentParser::TokenizedChunk> chunk = wrapUnique(new HTMLDocumentParser::TokenizedChunk);
TRACE_EVENT_WITH_FLOW0("blink,loading", "BackgroundHTMLParser::sendTokensToMainThread", chunk.get(), TRACE_EVENT_FLAG_FLOW_OUT);
if (!m_pendingPreloads.isEmpty()) {
@@ -311,13 +311,13 @@ void BackgroundHTMLParser::sendTokensToMainThread()
chunk->likelyDocumentWriteScriptIndices.swap(m_likelyDocumentWriteScriptIndices);
m_startingScript = false;
- bool isEmpty = m_parsedChunkQueue->enqueue(std::move(chunk));
+ bool isEmpty = m_tokenizedChunkQueue->enqueue(std::move(chunk));
DEFINE_STATIC_LOCAL(CustomCountHistogram, chunkEnqueueTime, ("Parser.ChunkEnqueueTime", 1, 10000, 50));
chunkEnqueueTime.count(monotonicallyIncreasingTimeMS() - chunkStartTime);
if (isEmpty) {
- runOnMainThread(&HTMLDocumentParser::notifyPendingParsedChunks, m_parser);
+ runOnMainThread(&HTMLDocumentParser::notifyPendingTokenizedChunks, m_parser);
}
m_pendingTokens = wrapUnique(new CompactHTMLTokenStream);

Powered by Google App Engine
This is Rietveld 408576698