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

Unified Diff: src/crankshaft/hydrogen.h

Issue 1930773003: [compiler] Untangle CompilationInfo allocated with new. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@local_cleanup-compiler-simplify-30
Patch Set: Fix initialization order. Created 4 years, 8 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/compiler/pipeline.cc ('k') | src/optimizing-compile-dispatcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/crankshaft/hydrogen.h
diff --git a/src/crankshaft/hydrogen.h b/src/crankshaft/hydrogen.h
index 27f368f0f9547d506cb1e710a322151845421c46..dd839253cfaa4b4f63ba23fefdb53196b6365648 100644
--- a/src/crankshaft/hydrogen.h
+++ b/src/crankshaft/hydrogen.h
@@ -13,6 +13,7 @@
#include "src/compiler.h"
#include "src/crankshaft/compilation-phase.h"
#include "src/crankshaft/hydrogen-instructions.h"
+#include "src/parsing/parser.h"
#include "src/zone.h"
namespace v8 {
@@ -32,8 +33,13 @@ class LiveRange;
class HCompilationJob final : public CompilationJob {
public:
- explicit HCompilationJob(CompilationInfo* info)
- : CompilationJob(info, "Crankshaft"), graph_(nullptr), chunk_(nullptr) {}
+ explicit HCompilationJob(Handle<JSFunction> function)
+ : CompilationJob(&info_, "Crankshaft"),
+ zone_(function->GetIsolate()->allocator()),
+ parse_info_(&zone_, function),
+ info_(&parse_info_, function),
+ graph_(nullptr),
+ chunk_(nullptr) {}
protected:
virtual Status CreateGraphImpl();
@@ -41,6 +47,9 @@ class HCompilationJob final : public CompilationJob {
virtual Status GenerateCodeImpl();
private:
+ Zone zone_;
+ ParseInfo parse_info_;
+ CompilationInfo info_;
HGraph* graph_;
LChunk* chunk_;
};
« no previous file with comments | « src/compiler/pipeline.cc ('k') | src/optimizing-compile-dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698