[sanitizer] Improve FreeBSD ASLR detection
[llvm-project.git] / llvm / lib / CodeGen / LiveDebugValues / LiveDebugValues.h
blob8f0b2ec3e1fc547f9ff5a5b03009d7f21cffed57
1 //===- LiveDebugValues.cpp - Tracking Debug Value MIs ---------*- C++ -*---===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #ifndef LLVM_LIB_CODEGEN_LIVEDEBUGVALUES_LIVEDEBUGVALUES_H
10 #define LLVM_LIB_CODEGEN_LIVEDEBUGVALUES_LIVEDEBUGVALUES_H
12 #include "llvm/CodeGen/MachineDominators.h"
13 #include "llvm/CodeGen/MachineFunction.h"
14 #include "llvm/CodeGen/TargetPassConfig.h"
15 #include "llvm/ADT/Triple.h"
17 namespace llvm {
19 // Inline namespace for types / symbols shared between different
20 // LiveDebugValues implementations.
21 inline namespace SharedLiveDebugValues {
23 // Expose a base class for LiveDebugValues interfaces to inherit from. This
24 // allows the generic LiveDebugValues pass handles to call into the
25 // implementation.
26 class LDVImpl {
27 public:
28 virtual bool ExtendRanges(MachineFunction &MF, MachineDominatorTree *DomTree,
29 TargetPassConfig *TPC, unsigned InputBBLimit,
30 unsigned InputDbgValLimit) = 0;
31 virtual ~LDVImpl() {}
34 } // namespace SharedLiveDebugValues
36 // Factory functions for LiveDebugValues implementations.
37 extern LDVImpl *makeVarLocBasedLiveDebugValues();
38 extern LDVImpl *makeInstrRefBasedLiveDebugValues();
40 extern bool debuginfoShouldUseDebugInstrRef(const Triple &T);
42 } // namespace llvm
44 #endif // LLVM_LIB_CODEGEN_LIVEDEBUGVALUES_LIVEDEBUGVALUES_H