//===- LiveRangeCalc.h - Calculate live ranges -----------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// // // The LiveRangeCalc class can be used to implement the computation of // live ranges from scratch. // It caches information about values in the CFG to speed up repeated // operations on the same live range. The cache can be shared by // non-overlapping live ranges. SplitKit uses that when computing the live // range of split products. // // A low-level interface is available to clients that know where a variable is // live, but don't know which value it has as every point. LiveRangeCalc will // propagate values down the dominator tree, and even insert PHI-defs where // needed. SplitKit uses this faster interface when possible. // //===----------------------------------------------------------------------===// #ifndef LLVM_CODEGEN_LIVERANGECALC_H #define LLVM_CODEGEN_LIVERANGECALC_H #include "llvm/ADT/ArrayRef.h" #include "llvm/ADT/BitVector.h" #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/IndexedMap.h" #include "llvm/ADT/SmallVector.h" #include "llvm/CodeGen/LiveInterval.h" #include "llvm/CodeGen/MachineBasicBlock.h" #include "llvm/CodeGen/SlotIndexes.h" #include <utility> namespace llvm { template <class NodeT> class DomTreeNodeBase; class MachineDominatorTree; class MachineFunction; class MachineRegisterInfo; MachineDomTreeNode; class LiveRangeCalc { … }; } // end namespace llvm #endif // LLVM_CODEGEN_LIVERANGECALC_H