forked from nodejs/node
-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathloop-peeling-phase.cc
More file actions
29 lines (24 loc) · 1.34 KB
/
loop-peeling-phase.cc
File metadata and controls
29 lines (24 loc) · 1.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// Copyright 2023 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "src/compiler/turboshaft/loop-peeling-phase.h"
#include "src/compiler/turboshaft/copying-phase.h"
#include "src/compiler/turboshaft/loop-peeling-reducer.h"
#include "src/compiler/turboshaft/machine-optimization-reducer.h"
#include "src/compiler/turboshaft/required-optimization-reducer.h"
#include "src/compiler/turboshaft/value-numbering-reducer.h"
#include "src/compiler/turboshaft/variable-reducer.h"
#include "src/numbers/conversions-inl.h"
namespace v8::internal::compiler::turboshaft {
void LoopPeelingPhase::Run(Zone* temp_zone) {
// Note that for wasm-gc it is relevant that the MachineOptimizationReducer is
// run prior to other phases. Any attempt to skip the loop peeling phase (e.g.
// if no loops are present) should evaluate how to run the
// MachineOptimizationReducer then.
turboshaft::CopyingPhase<turboshaft::LoopPeelingReducer,
turboshaft::VariableReducer,
turboshaft::MachineOptimizationReducer,
turboshaft::RequiredOptimizationReducer,
turboshaft::ValueNumberingReducer>::Run<true>(temp_zone);
}
} // namespace v8::internal::compiler::turboshaft