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

Side by Side Diff: test/cctest/compiler/test-codegen-deopt.cc

Issue 663333003: [turbofan] use ZonePool in most places in the compiler pipeline a temp zone is used. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: rebase Created 6 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/compiler/register-allocator.cc ('k') | test/cctest/compiler/test-control-reducer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 #include "test/cctest/cctest.h" 6 #include "test/cctest/cctest.h"
7 7
8 #include "src/compiler/code-generator.h" 8 #include "src/compiler/code-generator.h"
9 #include "src/compiler/common-operator.h" 9 #include "src/compiler/common-operator.h"
10 #include "src/compiler/graph.h" 10 #include "src/compiler/graph.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 OFStream os(stdout); 63 OFStream os(stdout);
64 if (FLAG_trace_turbo) { 64 if (FLAG_trace_turbo) {
65 os << *schedule; 65 os << *schedule;
66 } 66 }
67 67
68 // Initialize the codegen and generate code. 68 // Initialize the codegen and generate code.
69 Linkage* linkage = new (scope_->main_zone()) Linkage(&info); 69 Linkage* linkage = new (scope_->main_zone()) Linkage(&info);
70 code = new v8::internal::compiler::InstructionSequence(scope_->main_zone(), 70 code = new v8::internal::compiler::InstructionSequence(scope_->main_zone(),
71 graph, schedule); 71 graph, schedule);
72 SourcePositionTable source_positions(graph); 72 SourcePositionTable source_positions(graph);
73 InstructionSelector selector(linkage, code, schedule, &source_positions); 73 InstructionSelector selector(scope_->main_zone(), linkage, code, schedule,
74 &source_positions);
74 selector.SelectInstructions(); 75 selector.SelectInstructions();
75 76
76 if (FLAG_trace_turbo) { 77 if (FLAG_trace_turbo) {
77 os << "----- Instruction sequence before register allocation -----\n" 78 os << "----- Instruction sequence before register allocation -----\n"
78 << *code; 79 << *code;
79 } 80 }
80 81
81 Frame frame; 82 Frame frame;
82 RegisterAllocator allocator(&frame, &info, code); 83 RegisterAllocator allocator(scope_->main_zone(), &frame, &info, code);
83 CHECK(allocator.Allocate()); 84 CHECK(allocator.Allocate());
84 85
85 if (FLAG_trace_turbo) { 86 if (FLAG_trace_turbo) {
86 os << "----- Instruction sequence after register allocation -----\n" 87 os << "----- Instruction sequence after register allocation -----\n"
87 << *code; 88 << *code;
88 } 89 }
89 90
90 compiler::CodeGenerator generator(&frame, linkage, code); 91 compiler::CodeGenerator generator(&frame, linkage, code);
91 result_code = generator.GenerateCode(); 92 result_code = generator.GenerateCode();
92 93
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 Handle<Object> result; 310 Handle<Object> result;
310 bool has_pending_exception = 311 bool has_pending_exception =
311 !Execution::Call(isolate, t.function, 312 !Execution::Call(isolate, t.function,
312 isolate->factory()->undefined_value(), 0, NULL, 313 isolate->factory()->undefined_value(), 0, NULL,
313 false).ToHandle(&result); 314 false).ToHandle(&result);
314 CHECK(!has_pending_exception); 315 CHECK(!has_pending_exception);
315 CHECK(result->SameValue(Smi::FromInt(42))); 316 CHECK(result->SameValue(Smi::FromInt(42)));
316 } 317 }
317 318
318 #endif 319 #endif
OLDNEW
« no previous file with comments | « src/compiler/register-allocator.cc ('k') | test/cctest/compiler/test-control-reducer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698