OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google, Inc. All Rights Reserved. | 2 * Copyright (C) 2010 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 | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
452 constructTreeFromCompactHTMLToken(*it); | 452 constructTreeFromCompactHTMLToken(*it); |
453 | 453 |
454 if (isStopped()) | 454 if (isStopped()) |
455 break; | 455 break; |
456 | 456 |
457 if (!m_triedLoadingLinkHeaders && document()->loader()) { | 457 if (!m_triedLoadingLinkHeaders && document()->loader()) { |
458 String linkHeader = document()->loader()->response().httpHeaderField
(HTTPNames::Link); | 458 String linkHeader = document()->loader()->response().httpHeaderField
(HTTPNames::Link); |
459 if (!linkHeader.isEmpty()) { | 459 if (!linkHeader.isEmpty()) { |
460 ASSERT(chunk); | 460 ASSERT(chunk); |
461 LinkLoader::loadLinksFromHeader(linkHeader, document()->loader()
->response().url(), | 461 LinkLoader::loadLinksFromHeader(linkHeader, document()->loader()
->response().url(), |
462 document(), NetworkHintsInterfaceImpl(), LinkLoader::OnlyLoa
dResources, &(chunk->viewport)); | 462 document(), LinkLoader::OnlyLoadResources, &(chunk->viewport
)); |
463 m_triedLoadingLinkHeaders = true; | 463 m_triedLoadingLinkHeaders = true; |
464 } | 464 } |
465 } | 465 } |
466 | 466 |
467 if (isWaitingForScripts()) { | 467 if (isWaitingForScripts()) { |
468 ASSERT(it + 1 == tokens->end()); // The </script> is assumed to be t
he last token of this bunch. | 468 ASSERT(it + 1 == tokens->end()); // The </script> is assumed to be t
he last token of this bunch. |
469 runScriptsForPausedTreeBuilder(); | 469 runScriptsForPausedTreeBuilder(); |
470 validateSpeculations(std::move(chunk)); | 470 validateSpeculations(std::move(chunk)); |
471 break; | 471 break; |
472 } | 472 } |
(...skipping 636 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1109 DEFINE_STATIC_LOCAL(CustomCountHistogram, successHistogram, ("PreloadSca
nner.DocumentWrite.ExecutionTime.Success", 1, 10000, 50)); | 1109 DEFINE_STATIC_LOCAL(CustomCountHistogram, successHistogram, ("PreloadSca
nner.DocumentWrite.ExecutionTime.Success", 1, 10000, 50)); |
1110 successHistogram.count(duration); | 1110 successHistogram.count(duration); |
1111 } else { | 1111 } else { |
1112 DEFINE_STATIC_LOCAL(CustomCountHistogram, failureHistogram, ("PreloadSca
nner.DocumentWrite.ExecutionTime.Failure", 1, 10000, 50)); | 1112 DEFINE_STATIC_LOCAL(CustomCountHistogram, failureHistogram, ("PreloadSca
nner.DocumentWrite.ExecutionTime.Failure", 1, 10000, 50)); |
1113 failureHistogram.count(duration); | 1113 failureHistogram.count(duration); |
1114 } | 1114 } |
1115 | 1115 |
1116 } | 1116 } |
1117 | 1117 |
1118 } // namespace blink | 1118 } // namespace blink |
OLD | NEW |