LLVM 24.0.0git
MachineModuleSlotTracker.h
Go to the documentation of this file.
1//===-- llvm/CodeGen/MachineModuleInfo.h ------------------------*- 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//===----------------------------------------------------------------------===//
8
9#ifndef LLVM_CODEGEN_MACHINEMODULESLOTTRACKER_H
10#define LLVM_CODEGEN_MACHINEMODULESLOTTRACKER_H
11
17
18namespace llvm {
19
20class Function;
22class MachineFunction;
23class Module;
24
26
28 const MachineFunction *TheMF;
29 MachineMDNodeListType MachineMDNodes;
30 SmallPtrSet<const DILocation *, 4> InlineDebugLocations;
31
32 void collectMachineFunctionMetadata(
34 SmallVectorImpl<const MDNode *> *DebugLocations = nullptr) const;
35
36public:
39
40 /// Renumber module and machine metadata for canonical MIR output.
43 bool shouldPrintDebugLocationInline(const DILocation *DL) const override;
44};
45
46} // namespace llvm
47
48#endif // LLVM_CODEGEN_MACHINEMODULESLOTTRACKER_H
MachineBasicBlock MachineBasicBlock::iterator DebugLoc DL
#define LLVM_ABI
Definition Compiler.h:215
This file defines the SmallPtrSet class.
This file defines the SmallVector class.
This class contains meta information specific to a module.
MachineModuleSlotTracker(MFGetterFnT Fn, const MachineFunction *MF)
bool shouldPrintDebugLocationInline(const DILocation *DL) const override
Return whether a debug location should be printed inline instead of by ID.
void collectMachineMDNodes(MachineMDNodeListType &L) const
void renumberMetadataForAssembly()
Renumber module and machine metadata for canonical MIR output.
Root of the metadata hierarchy.
Definition Metadata.h:64
ModuleSlotTracker(SlotTracker &Machine, const Module *M, const Function *F=nullptr)
Wrap a preinitialized SlotTracker.
SmallVector< std::pair< unsigned, const MDNode * >, 0 > MachineMDNodeListType
A Module instance is used to store all the information related to an LLVM module.
Definition Module.h:68
SmallPtrSet - This class implements a set which is optimized for holding SmallSize or less elements.
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
An efficient, type-erasing, non-owning reference to a callable.
This is an optimization pass for GlobalISel generic memory operations.
function_ref< MachineFunction *(const Function &)> MFGetterFnT