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

Unified Diff: src/compiler-dispatcher/compiler-dispatcher-job.h

Issue 2193813002: Add parser finalization step (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates 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
« no previous file with comments | « no previous file | src/compiler-dispatcher/compiler-dispatcher-job.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler-dispatcher/compiler-dispatcher-job.h
diff --git a/src/compiler-dispatcher/compiler-dispatcher-job.h b/src/compiler-dispatcher/compiler-dispatcher-job.h
index 0a6ff20930615aff16017dba2289cfe301e842ca..64df14e1e441fafee78bb767e03b1f9e7a8c1cae 100644
--- a/src/compiler-dispatcher/compiler-dispatcher-job.h
+++ b/src/compiler-dispatcher/compiler-dispatcher-job.h
@@ -18,6 +18,7 @@ class Isolate;
class JSFunction;
class ParseInfo;
class Parser;
+class String;
class UnicodeCache;
class Utf16CharacterStream;
class Zone;
@@ -26,6 +27,9 @@ enum class CompileJobStatus {
kInitial,
kReadyToParse,
kParsed,
+ kReadyToCompile,
+ kFailed,
+ kDone,
};
class CompilerDispatcherJob {
@@ -45,10 +49,22 @@ class CompilerDispatcherJob {
// Transition from kReadyToParse to kParsed.
void Parse();
+ // Transition from kParsed to kReadyToCompile (or kFailed).
+ void FinalizeParsingOnMainThread();
+
+ // Transition from kFailed to kDone.
+ void ReportErrorsOnMainThread();
+
+ // Transition from any state to kInitial and free all resources.
+ void ResetOnMainThread();
+
private:
+ void InternalizeParsingResult();
+
CompileJobStatus status_ = CompileJobStatus::kInitial;
Isolate* isolate_;
Handle<JSFunction> function_; // Global handle.
+ Handle<String> source_; // Global handle.
size_t max_stack_size_;
// Members required for parsing.
« no previous file with comments | « no previous file | src/compiler-dispatcher/compiler-dispatcher-job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698