LLDB mainline
DWARFLocationExpression.h
Go to the documentation of this file.
1//===-- DWARFLocationExpression.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 LLDB_SOURCE_PLUGINS_SYMBOLFILE_NATIVEPDB_DWARFLOCATIONEXPRESSION_H
10#define LLDB_SOURCE_PLUGINS_SYMBOLFILE_NATIVEPDB_DWARFLOCATIONEXPRESSION_H
11
12#include "lldb/lldb-forward.h"
13#include "llvm/ADT/ArrayRef.h"
14#include "llvm/DebugInfo/CodeView/CodeView.h"
15#include "llvm/Support/Error.h"
16#include <map>
17
18namespace llvm {
19class APSInt;
20class StringRef;
21namespace codeview {
22class TypeIndex;
23}
24namespace pdb {
25class TpiStream;
26}
27} // namespace llvm
28namespace lldb_private {
29namespace npdb {
31 uint16_t reg_id;
32 uint16_t reg_offset;
33 bool is_at_reg = true;
34};
35
37MakeEnregisteredLocationExpression(llvm::codeview::RegisterId reg,
38 lldb::ModuleSP module);
39
40DWARFExpression MakeRegRelLocationExpression(llvm::codeview::RegisterId reg,
41 int32_t offset,
42 lldb::ModuleSP module);
44MakeRegRelIndirLocationExpression(llvm::codeview::RegisterId reg,
45 int32_t offset, int32_t offset_in_udt,
46 lldb::ModuleSP module);
47DWARFExpression MakeVFrameRelLocationExpression(llvm::StringRef fpo_program,
48 int32_t offset,
49 lldb::ModuleSP module);
50DWARFExpression MakeGlobalLocationExpression(uint16_t section, uint32_t offset,
51 lldb::ModuleSP module);
52llvm::Expected<DWARFExpression> MakeConstantLocationExpression(
53 llvm::codeview::TypeIndex underlying_ti, llvm::pdb::TpiStream &tpi,
54 const llvm::APSInt &constant, lldb::ModuleSP module);
56 const std::map<uint64_t, MemberValLocation> &offset_to_location,
57 std::map<uint64_t, size_t> &offset_to_size, size_t total_size,
58 lldb::ModuleSP module);
59} // namespace npdb
60} // namespace lldb_private
61
62#endif
"lldb/Expression/DWARFExpression.h" Encapsulates a DWARF location expression and interprets it.
DWARFExpression MakeRegRelIndirLocationExpression(llvm::codeview::RegisterId reg, int32_t offset, int32_t offset_in_udt, lldb::ModuleSP module)
DWARFExpression MakeRegRelLocationExpression(llvm::codeview::RegisterId reg, int32_t offset, lldb::ModuleSP module)
DWARFExpression MakeVFrameRelLocationExpression(llvm::StringRef fpo_program, int32_t offset, lldb::ModuleSP module)
llvm::Expected< DWARFExpression > MakeConstantLocationExpression(llvm::codeview::TypeIndex underlying_ti, llvm::pdb::TpiStream &tpi, const llvm::APSInt &constant, lldb::ModuleSP module)
DWARFExpression MakeGlobalLocationExpression(uint16_t section, uint32_t offset, lldb::ModuleSP module)
DWARFExpression MakeEnregisteredLocationExpressionForComposite(const std::map< uint64_t, MemberValLocation > &offset_to_location, std::map< uint64_t, size_t > &offset_to_size, size_t total_size, lldb::ModuleSP module)
DWARFExpression MakeEnregisteredLocationExpression(llvm::codeview::RegisterId reg, lldb::ModuleSP module)
A class that represents a running process on the host machine.
std::shared_ptr< lldb_private::Module > ModuleSP