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

Unified Diff: test/cctest/compiler/test-codegen-deopt.cc

Issue 517323002: Make FrameStates recursive (to be used for inlining). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: jarin's comments. Created 6 years, 4 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/raw-machine-assembler.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/compiler/test-codegen-deopt.cc
diff --git a/test/cctest/compiler/test-codegen-deopt.cc b/test/cctest/compiler/test-codegen-deopt.cc
index e11fc552d8ed561771615f55c7e77234792b927c..4e27fe41c638c6eddb7106941c2a9ed295af49bf 100644
--- a/test/cctest/compiler/test-codegen-deopt.cc
+++ b/test/cctest/compiler/test-codegen-deopt.cc
@@ -114,7 +114,6 @@ class TrivialDeoptCodegenTester : public DeoptCodegenTester {
}
Schedule* BuildGraphAndSchedule(Graph* graph) {
- Isolate* isolate = info.isolate();
CommonOperatorBuilder common(zone());
// Manually construct a schedule for the function below:
@@ -128,12 +127,6 @@ class TrivialDeoptCodegenTester : public DeoptCodegenTester {
RawMachineAssembler m(graph, &descriptor_builder);
- Handle<Object> undef_object =
- Handle<Object>(isolate->heap()->undefined_value(), isolate);
- PrintableUnique<Object> undef_constant =
- PrintableUnique<Object>::CreateUninitialized(zone(), undef_object);
- Node* undef_node = m.NewNode(common.HeapConstant(undef_constant));
-
Handle<JSFunction> deopt_function =
NewFunction("function deopt() { %DeoptimizeFunction(foo); }; deopt");
PrintableUnique<Object> deopt_fun_constant =
@@ -142,16 +135,17 @@ class TrivialDeoptCodegenTester : public DeoptCodegenTester {
bailout_id = GetCallBailoutId();
- Node* parameters = m.NewNode(common.StateValues(1), undef_node);
+ Node* parameters = m.NewNode(common.StateValues(1), m.UndefinedConstant());
Node* locals = m.NewNode(common.StateValues(0));
Node* stack = m.NewNode(common.StateValues(0));
- Node* state_node = m.NewNode(common.FrameState(bailout_id, kIgnoreOutput),
- parameters, locals, stack, undef_node);
+ Node* state_node =
+ m.NewNode(common.FrameState(bailout_id, kIgnoreOutput), parameters,
+ locals, stack, m.UndefinedConstant(), m.UndefinedConstant());
- m.CallJS0(deopt_fun_node, undef_node, state_node);
+ m.CallJS0(deopt_fun_node, m.UndefinedConstant(), state_node);
- m.Return(undef_node);
+ m.Return(m.UndefinedConstant());
// Schedule the graph:
Schedule* schedule = m.Export();
@@ -230,7 +224,6 @@ class TrivialRuntimeDeoptCodegenTester : public DeoptCodegenTester {
}
Schedule* BuildGraphAndSchedule(Graph* graph) {
- Isolate* isolate = info.isolate();
CommonOperatorBuilder common(zone());
// Manually construct a schedule for the function below:
@@ -244,27 +237,22 @@ class TrivialRuntimeDeoptCodegenTester : public DeoptCodegenTester {
RawMachineAssembler m(graph, &descriptor_builder);
- Handle<Object> undef_object =
- Handle<Object>(isolate->heap()->undefined_value(), isolate);
- PrintableUnique<Object> undef_constant =
- PrintableUnique<Object>::CreateUninitialized(zone(), undef_object);
- Node* undef_node = m.NewNode(common.HeapConstant(undef_constant));
-
PrintableUnique<Object> this_fun_constant =
PrintableUnique<Object>::CreateUninitialized(zone(), function);
Node* this_fun_node = m.NewNode(common.HeapConstant(this_fun_constant));
bailout_id = GetCallBailoutId();
- Node* parameters = m.NewNode(common.StateValues(1), undef_node);
+ Node* parameters = m.NewNode(common.StateValues(1), m.UndefinedConstant());
Node* locals = m.NewNode(common.StateValues(0));
Node* stack = m.NewNode(common.StateValues(0));
- Node* state_node = m.NewNode(common.FrameState(bailout_id, kIgnoreOutput),
- parameters, locals, stack, undef_node);
+ Node* state_node =
+ m.NewNode(common.FrameState(bailout_id, kIgnoreOutput), parameters,
+ locals, stack, m.UndefinedConstant(), m.UndefinedConstant());
m.CallRuntime1(Runtime::kDeoptimizeFunction, this_fun_node, state_node);
- m.Return(undef_node);
+ m.Return(m.UndefinedConstant());
// Schedule the graph:
Schedule* schedule = m.Export();
« no previous file with comments | « src/compiler/raw-machine-assembler.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698