| 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 919 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 930 } | 930 } |
| 931 | 931 |
| 932 void HTMLDocumentParser::resumeParsingAfterScriptExecution() | 932 void HTMLDocumentParser::resumeParsingAfterScriptExecution() |
| 933 { | 933 { |
| 934 ASSERT(!isExecutingScript()); | 934 ASSERT(!isExecutingScript()); |
| 935 ASSERT(!isWaitingForScripts()); | 935 ASSERT(!isWaitingForScripts()); |
| 936 | 936 |
| 937 if (m_haveBackgroundParser) { | 937 if (m_haveBackgroundParser) { |
| 938 validateSpeculations(std::move(m_lastChunkBeforeScript)); | 938 validateSpeculations(std::move(m_lastChunkBeforeScript)); |
| 939 ASSERT(!m_lastChunkBeforeScript); | 939 ASSERT(!m_lastChunkBeforeScript); |
| 940 pumpPendingSpeculations(); | 940 if (true || RuntimeEnabledFeatures::yieldAfterScriptExecutionEnabled())
{ |
| 941 m_parserScheduler->scheduleForResume(); |
| 942 } else { |
| 943 pumpPendingSpeculations(); |
| 944 } |
| 941 return; | 945 return; |
| 942 } | 946 } |
| 943 | 947 |
| 944 m_insertionPreloadScanner.reset(); | 948 m_insertionPreloadScanner.reset(); |
| 945 pumpTokenizerIfPossible(); | 949 pumpTokenizerIfPossible(); |
| 946 endIfDelayed(); | 950 endIfDelayed(); |
| 947 } | 951 } |
| 948 | 952 |
| 949 void HTMLDocumentParser::appendCurrentInputStreamToPreloadScannerAndScan() | 953 void HTMLDocumentParser::appendCurrentInputStreamToPreloadScannerAndScan() |
| 950 { | 954 { |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1139 (*closure)(); | 1143 (*closure)(); |
| 1140 return; | 1144 return; |
| 1141 case Asynchronous: | 1145 case Asynchronous: |
| 1142 m_loadingTaskRunner->postTask(BLINK_FROM_HERE, std::move(closure)); | 1146 m_loadingTaskRunner->postTask(BLINK_FROM_HERE, std::move(closure)); |
| 1143 return; | 1147 return; |
| 1144 } | 1148 } |
| 1145 NOTREACHED(); | 1149 NOTREACHED(); |
| 1146 } | 1150 } |
| 1147 | 1151 |
| 1148 } // namespace blink | 1152 } // namespace blink |
| OLD | NEW |