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

Side by Side Diff: src/compiler/pipeline.cc

Issue 1893283002: [turbofan] Remove dead code from the pipeline. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | 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/compiler/pipeline.h" 5 #include "src/compiler/pipeline.h"
6 6
7 #include <fstream> // NOLINT(readability/streams) 7 #include <fstream> // NOLINT(readability/streams)
8 #include <sstream> 8 #include <sstream>
9 9
10 #include "src/base/adapters.h" 10 #include "src/base/adapters.h"
(...skipping 839 matching lines...) Expand 10 before | Expand all | Expand 10 after
850 AddReducer(data, &graph_reducer, &dead_code_elimination); 850 AddReducer(data, &graph_reducer, &dead_code_elimination);
851 AddReducer(data, &graph_reducer, &simple_reducer); 851 AddReducer(data, &graph_reducer, &simple_reducer);
852 AddReducer(data, &graph_reducer, &value_numbering); 852 AddReducer(data, &graph_reducer, &value_numbering);
853 AddReducer(data, &graph_reducer, &lowering); 853 AddReducer(data, &graph_reducer, &lowering);
854 AddReducer(data, &graph_reducer, &machine_reducer); 854 AddReducer(data, &graph_reducer, &machine_reducer);
855 AddReducer(data, &graph_reducer, &common_reducer); 855 AddReducer(data, &graph_reducer, &common_reducer);
856 graph_reducer.ReduceGraph(); 856 graph_reducer.ReduceGraph();
857 } 857 }
858 }; 858 };
859 859
860 struct ComputeEffectSchedulePhase {
861 static const char* phase_name() { return "effect scheduling"; }
862
863 void Run(PipelineData* data, Zone* temp_zone) {
864 Schedule* schedule = Scheduler::ComputeSchedule(temp_zone, data->graph(),
865 Scheduler::kNoFlags);
866 if (FLAG_turbo_verify) ScheduleVerifier::Run(schedule);
867 data->set_schedule(schedule);
868 }
869 };
870
871 struct EffectScheduleTrimmingPhase {
872 static const char* phase_name() { return "effect schedule graph trimming"; }
873 void Run(PipelineData* data, Zone* temp_zone) {
874 GraphTrimmer trimmer(temp_zone, data->graph());
875 NodeVector roots(temp_zone);
876 data->jsgraph()->GetCachedNodes(&roots);
877 trimmer.TrimGraph(roots.begin(), roots.end());
878 }
879 };
880
881 struct EarlyGraphTrimmingPhase { 860 struct EarlyGraphTrimmingPhase {
882 static const char* phase_name() { return "early graph trimming"; } 861 static const char* phase_name() { return "early graph trimming"; }
883 void Run(PipelineData* data, Zone* temp_zone) { 862 void Run(PipelineData* data, Zone* temp_zone) {
884 GraphTrimmer trimmer(temp_zone, data->graph()); 863 GraphTrimmer trimmer(temp_zone, data->graph());
885 NodeVector roots(temp_zone); 864 NodeVector roots(temp_zone);
886 data->jsgraph()->GetCachedNodes(&roots); 865 data->jsgraph()->GetCachedNodes(&roots);
887 trimmer.TrimGraph(roots.begin(), roots.end()); 866 trimmer.TrimGraph(roots.begin(), roots.end());
888 } 867 }
889 }; 868 };
890 869
(...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after
1624 } 1603 }
1625 1604
1626 data->DeleteRegisterAllocationZone(); 1605 data->DeleteRegisterAllocationZone();
1627 } 1606 }
1628 1607
1629 Isolate* Pipeline::isolate() const { return info()->isolate(); } 1608 Isolate* Pipeline::isolate() const { return info()->isolate(); }
1630 1609
1631 } // namespace compiler 1610 } // namespace compiler
1632 } // namespace internal 1611 } // namespace internal
1633 } // namespace v8 1612 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698