1e8d8bef9SDimitry Andric //===- LiveDebugValues.cpp - Tracking Debug Value MIs ---------*- C++ -*---===// 2e8d8bef9SDimitry Andric // 3e8d8bef9SDimitry Andric // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4e8d8bef9SDimitry Andric // See https://llvm.org/LICENSE.txt for license information. 5e8d8bef9SDimitry Andric // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6e8d8bef9SDimitry Andric // 7e8d8bef9SDimitry Andric //===----------------------------------------------------------------------===// 8e8d8bef9SDimitry Andric 9*fe6060f1SDimitry Andric #ifndef LLVM_LIB_CODEGEN_LIVEDEBUGVALUES_LIVEDEBUGVALUES_H 10*fe6060f1SDimitry Andric #define LLVM_LIB_CODEGEN_LIVEDEBUGVALUES_LIVEDEBUGVALUES_H 11*fe6060f1SDimitry Andric 12e8d8bef9SDimitry Andric #include "llvm/CodeGen/MachineFunction.h" 13e8d8bef9SDimitry Andric #include "llvm/CodeGen/TargetPassConfig.h" 14e8d8bef9SDimitry Andric 15e8d8bef9SDimitry Andric namespace llvm { 16e8d8bef9SDimitry Andric 17e8d8bef9SDimitry Andric // Inline namespace for types / symbols shared between different 18e8d8bef9SDimitry Andric // LiveDebugValues implementations. 19e8d8bef9SDimitry Andric inline namespace SharedLiveDebugValues { 20e8d8bef9SDimitry Andric 21e8d8bef9SDimitry Andric // Expose a base class for LiveDebugValues interfaces to inherit from. This 22e8d8bef9SDimitry Andric // allows the generic LiveDebugValues pass handles to call into the 23e8d8bef9SDimitry Andric // implementation. 24e8d8bef9SDimitry Andric class LDVImpl { 25e8d8bef9SDimitry Andric public: 26e8d8bef9SDimitry Andric virtual bool ExtendRanges(MachineFunction &MF, TargetPassConfig *TPC) = 0; 27e8d8bef9SDimitry Andric virtual ~LDVImpl() {} 28e8d8bef9SDimitry Andric }; 29e8d8bef9SDimitry Andric 30e8d8bef9SDimitry Andric } // namespace SharedLiveDebugValues 31e8d8bef9SDimitry Andric 32e8d8bef9SDimitry Andric // Factory functions for LiveDebugValues implementations. 33e8d8bef9SDimitry Andric extern LDVImpl *makeVarLocBasedLiveDebugValues(); 34e8d8bef9SDimitry Andric extern LDVImpl *makeInstrRefBasedLiveDebugValues(); 35e8d8bef9SDimitry Andric } // namespace llvm 36*fe6060f1SDimitry Andric 37*fe6060f1SDimitry Andric #endif // LLVM_LIB_CODEGEN_LIVEDEBUGVALUES_LIVEDEBUGVALUES_H 38