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

Unified Diff: src/parsing/parse-info.h

Issue 2650883002: Reland: [Compiler] Enable handles created during parsing and scope analysis to be deferred. (Closed)
Patch Set: Remove unused variable Created 3 years, 10 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 | « src/handles.h ('k') | src/parsing/parse-info.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parsing/parse-info.h
diff --git a/src/parsing/parse-info.h b/src/parsing/parse-info.h
index b3f47692a19da613363e8220abf74c69903c33eb..83b7f79f5fbc8f84bf150ac5b9e2cb1ffbc0dafb 100644
--- a/src/parsing/parse-info.h
+++ b/src/parsing/parse-info.h
@@ -22,6 +22,7 @@ class AccountingAllocator;
class AstRawString;
class AstValueFactory;
class DeclarationScope;
+class DeferredHandles;
class FunctionLiteral;
class ScriptData;
class SharedFunctionInfo;
@@ -45,6 +46,12 @@ class V8_EXPORT_PRIVATE ParseInfo {
std::shared_ptr<Zone> zone_shared() const { return zone_; }
+ void set_deferred_handles(std::shared_ptr<DeferredHandles> deferred_handles);
+ void set_deferred_handles(DeferredHandles* deferred_handles);
+ std::shared_ptr<DeferredHandles> deferred_handles() const {
+ return deferred_handles_;
+ }
+
// Convenience accessor methods for flags.
#define FLAG_ACCESSOR(flag, getter, setter) \
bool getter() const { return GetFlag(flag); } \
@@ -201,8 +208,12 @@ class V8_EXPORT_PRIVATE ParseInfo {
}
void ReopenHandlesInNewHandleScope() {
- shared_ = Handle<SharedFunctionInfo>(*shared_);
- script_ = Handle<Script>(*script_);
+ if (!script_.is_null()) {
+ script_ = Handle<Script>(*script_);
+ }
+ if (!shared_.is_null()) {
+ shared_ = Handle<SharedFunctionInfo>(*shared_);
+ }
Handle<ScopeInfo> outer_scope_info;
if (maybe_outer_scope_info_.ToHandle(&outer_scope_info)) {
maybe_outer_scope_info_ = Handle<ScopeInfo>(*outer_scope_info);
@@ -266,6 +277,7 @@ class V8_EXPORT_PRIVATE ParseInfo {
//----------- Output of parsing and scope analysis ------------------------
FunctionLiteral* literal_;
+ std::shared_ptr<DeferredHandles> deferred_handles_;
void SetFlag(Flag f) { flags_ |= f; }
void SetFlag(Flag f, bool v) { flags_ = v ? flags_ | f : flags_ & ~f; }
« no previous file with comments | « src/handles.h ('k') | src/parsing/parse-info.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698