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

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

Issue 727323002: [turbofan] move register allocation phases to pipeline (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years, 1 month 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
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 65acfcc688645b3aa075855c6e8e43dc62990316..3b68470a62fc16dac9e6bce119711a79d0446bcb 100644
--- a/test/cctest/compiler/test-codegen-deopt.cc
+++ b/test/cctest/compiler/test-codegen-deopt.cc
@@ -64,38 +64,10 @@ class DeoptCodegenTester {
os << *schedule;
}
- // Initialize the codegen and generate code.
Linkage* linkage = new (scope_->main_zone()) Linkage(info.zone(), &info);
- InstructionBlocks* instruction_blocks =
- TestInstrSeq::InstructionBlocksFor(scope_->main_zone(), schedule);
- code = new (scope_->main_zone())
- TestInstrSeq(scope_->main_zone(), instruction_blocks);
- SourcePositionTable source_positions(graph);
- InstructionSelector selector(scope_->main_zone(), graph, linkage, code,
- schedule, &source_positions);
- selector.SelectInstructions();
-
- if (FLAG_trace_turbo) {
- PrintableInstructionSequence printable = {
- RegisterConfiguration::ArchDefault(), code};
- os << "----- Instruction sequence before register allocation -----\n"
- << printable;
- }
-
- Frame frame;
- RegisterAllocator allocator(RegisterConfiguration::ArchDefault(),
- scope_->main_zone(), &frame, code);
- CHECK(allocator.Allocate());
-
- if (FLAG_trace_turbo) {
- PrintableInstructionSequence printable = {
- RegisterConfiguration::ArchDefault(), code};
- os << "----- Instruction sequence after register allocation -----\n"
- << printable;
- }
-
- compiler::CodeGenerator generator(&frame, linkage, code, &info);
- result_code = generator.GenerateCode();
+ Pipeline pipeline(&info);
+ result_code =
+ pipeline.GenerateCodeForMachineGraph(linkage, graph, schedule);
#ifdef OBJECT_PRINT
if (FLAG_print_opt_code || FLAG_trace_turbo) {

Powered by Google App Engine
This is Rietveld 408576698