Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-10 08:43:32

0001 //===- MachineSSAContext.h --------------------------------------*- C++ -*-===//
0002 //
0003 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
0004 // See https://llvm.org/LICENSE.txt for license information.
0005 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
0006 //
0007 //===----------------------------------------------------------------------===//
0008 /// \file
0009 ///
0010 /// This file declares a specialization of the GenericSSAContext<X>
0011 /// template class for Machine IR.
0012 ///
0013 //===----------------------------------------------------------------------===//
0014 
0015 #ifndef LLVM_CODEGEN_MACHINESSACONTEXT_H
0016 #define LLVM_CODEGEN_MACHINESSACONTEXT_H
0017 
0018 #include "llvm/ADT/GenericSSAContext.h"
0019 #include "llvm/CodeGen/MachineBasicBlock.h"
0020 #include "llvm/Support/Printable.h"
0021 
0022 namespace llvm {
0023 class MachineInstr;
0024 class MachineFunction;
0025 class Register;
0026 
0027 inline auto instrs(const MachineBasicBlock &BB) { return BB.instrs(); }
0028 
0029 template <> struct GenericSSATraits<MachineFunction> {
0030   using BlockT = MachineBasicBlock;
0031   using FunctionT = MachineFunction;
0032   using InstructionT = MachineInstr;
0033   using ValueRefT = Register;
0034   using ConstValueRefT = Register;
0035   using UseT = MachineOperand;
0036 };
0037 
0038 using MachineSSAContext = GenericSSAContext<MachineFunction>;
0039 } // namespace llvm
0040 
0041 #endif // LLVM_CODEGEN_MACHINESSACONTEXT_H