//===- PHITransAddr.h - PHI Translation for Addresses -----------*- 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 // //===----------------------------------------------------------------------===// // // This file declares the PHITransAddr class. // //===----------------------------------------------------------------------===// #ifndef LLVM_ANALYSIS_PHITRANSADDR_H #define LLVM_ANALYSIS_PHITRANSADDR_H #include "llvm/ADT/SmallVector.h" #include "llvm/IR/Instruction.h" namespace llvm { class AssumptionCache; class DominatorTree; class DataLayout; class TargetLibraryInfo; /// PHITransAddr - An address value which tracks and handles phi translation. /// As we walk "up" the CFG through predecessors, we need to ensure that the /// address we're tracking is kept up to date. For example, if we're analyzing /// an address of "&A[i]" and walk through the definition of 'i' which is a PHI /// node, we *must* phi translate i to get "&A[j]" or else we will analyze an /// incorrect pointer in the predecessor block. /// /// This is designed to be a relatively small object that lives on the stack and /// is copyable. /// class PHITransAddr { … }; } // end namespace llvm #endif