blob: 7c102270a87c8fac256447ed28756d73dd596122 [file] [log] [blame]
Raphael Isemann80814282020-01-24 08:23:27 +01001//===-- SBAddress.cpp -----------------------------------------------------===//
Chris Lattner30fdc8d2010-06-08 16:52:24 +00002//
Chandler Carruth2946cd72019-01-19 08:50:56 +00003// 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
Chris Lattner30fdc8d2010-06-08 16:52:24 +00006//
7//===----------------------------------------------------------------------===//
8
9#include "lldb/API/SBAddress.h"
Jonas Devliegherebaf56642019-03-06 00:06:00 +000010#include "SBReproducerPrivate.h"
Jonas Devliegherebd4bf822019-03-06 00:05:55 +000011#include "Utils.h"
Chris Lattner30fdc8d2010-06-08 16:52:24 +000012#include "lldb/API/SBProcess.h"
Greg Claytoncac9c5f2011-09-24 00:52:29 +000013#include "lldb/API/SBSection.h"
Caroline Ticedde9cff2010-09-20 05:20:02 +000014#include "lldb/API/SBStream.h"
Chris Lattner30fdc8d2010-06-08 16:52:24 +000015#include "lldb/Core/Address.h"
Greg Clayton05d2b7f2011-03-31 01:08:07 +000016#include "lldb/Core/Module.h"
Zachary Turner32abc6e2015-03-03 19:23:09 +000017#include "lldb/Symbol/LineEntry.h"
Greg Claytonaf67cec2010-12-20 20:49:23 +000018#include "lldb/Target/Target.h"
Zachary Turnerbf9a7732017-02-02 21:39:50 +000019#include "lldb/Utility/StreamString.h"
Chris Lattner30fdc8d2010-06-08 16:52:24 +000020
21using namespace lldb;
Caroline Ticeceb6b132010-10-26 03:11:13 +000022using namespace lldb_private;
Chris Lattner30fdc8d2010-06-08 16:52:24 +000023
Jonas Devliegherebaf56642019-03-06 00:06:00 +000024SBAddress::SBAddress() : m_opaque_up(new Address()) {
25 LLDB_RECORD_CONSTRUCTOR_NO_ARGS(SBAddress);
26}
Chris Lattner30fdc8d2010-06-08 16:52:24 +000027
Jonas Devlieghere6cd4a4c2020-09-25 11:15:44 -070028SBAddress::SBAddress(const Address &address)
29 : m_opaque_up(std::make_unique<Address>(address)) {}
Chris Lattner30fdc8d2010-06-08 16:52:24 +000030
Jonas Devlieghered5b44032019-02-13 06:25:41 +000031SBAddress::SBAddress(const SBAddress &rhs) : m_opaque_up(new Address()) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +000032 LLDB_RECORD_CONSTRUCTOR(SBAddress, (const lldb::SBAddress &), rhs);
33
Jonas Devliegherebd4bf822019-03-06 00:05:55 +000034 m_opaque_up = clone(rhs.m_opaque_up);
Chris Lattner30fdc8d2010-06-08 16:52:24 +000035}
36
Kate Stoneb9c1b512016-09-06 20:57:50 +000037SBAddress::SBAddress(lldb::SBSection section, lldb::addr_t offset)
Jonas Devliegherebaf56642019-03-06 00:06:00 +000038 : m_opaque_up(new Address(section.GetSP(), offset)) {
39 LLDB_RECORD_CONSTRUCTOR(SBAddress, (lldb::SBSection, lldb::addr_t), section,
40 offset);
41}
Greg Clayton819134a2012-02-04 02:58:17 +000042
Greg Clayton00e6fbf2011-07-22 16:46:35 +000043// Create an address by resolving a load address using the supplied target
Kate Stoneb9c1b512016-09-06 20:57:50 +000044SBAddress::SBAddress(lldb::addr_t load_addr, lldb::SBTarget &target)
Jonas Devlieghered5b44032019-02-13 06:25:41 +000045 : m_opaque_up(new Address()) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +000046 LLDB_RECORD_CONSTRUCTOR(SBAddress, (lldb::addr_t, lldb::SBTarget &),
47 load_addr, target);
48
Kate Stoneb9c1b512016-09-06 20:57:50 +000049 SetLoadAddress(load_addr, target);
Greg Clayton00e6fbf2011-07-22 16:46:35 +000050}
51
Jonas Devlieghere866b7a62020-02-17 22:57:06 -080052SBAddress::~SBAddress() = default;
Greg Clayton00e6fbf2011-07-22 16:46:35 +000053
Kate Stoneb9c1b512016-09-06 20:57:50 +000054const SBAddress &SBAddress::operator=(const SBAddress &rhs) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +000055 LLDB_RECORD_METHOD(const lldb::SBAddress &,
56 SBAddress, operator=,(const lldb::SBAddress &), rhs);
57
Jonas Devliegherebd4bf822019-03-06 00:05:55 +000058 if (this != &rhs)
59 m_opaque_up = clone(rhs.m_opaque_up);
Jonas Devlieghere306809f2019-04-03 21:31:22 +000060 return LLDB_RECORD_RESULT(*this);
Chris Lattner30fdc8d2010-06-08 16:52:24 +000061}
62
Nitesh Jaindd125942017-05-04 11:34:42 +000063bool lldb::operator==(const SBAddress &lhs, const SBAddress &rhs) {
64 if (lhs.IsValid() && rhs.IsValid())
65 return lhs.ref() == rhs.ref();
66 return false;
67}
68
Pavel Labath4bc05002019-04-02 10:18:46 +000069bool SBAddress::operator!=(const SBAddress &rhs) const {
70 LLDB_RECORD_METHOD_CONST(bool, SBAddress, operator!=,(const SBAddress &),
71 &rhs);
72
73 return !(*this == rhs);
74}
75
Kate Stoneb9c1b512016-09-06 20:57:50 +000076bool SBAddress::IsValid() const {
Jonas Devliegherebaf56642019-03-06 00:06:00 +000077 LLDB_RECORD_METHOD_CONST_NO_ARGS(bool, SBAddress, IsValid);
Pavel Labath7f5237b2019-03-11 13:58:46 +000078 return this->operator bool();
79}
80SBAddress::operator bool() const {
81 LLDB_RECORD_METHOD_CONST_NO_ARGS(bool, SBAddress, operator bool);
Jonas Devliegherebaf56642019-03-06 00:06:00 +000082
Konrad Kleine248a1302019-05-23 11:14:47 +000083 return m_opaque_up != nullptr && m_opaque_up->IsValid();
Kate Stoneb9c1b512016-09-06 20:57:50 +000084}
85
Jonas Devliegherebaf56642019-03-06 00:06:00 +000086void SBAddress::Clear() {
87 LLDB_RECORD_METHOD_NO_ARGS(void, SBAddress, Clear);
88
Jonas Devlieghere1c0bbe42020-06-24 16:25:05 -070089 m_opaque_up = std::make_unique<Address>();
Jonas Devliegherebaf56642019-03-06 00:06:00 +000090}
Kate Stoneb9c1b512016-09-06 20:57:50 +000091
92void SBAddress::SetAddress(lldb::SBSection section, lldb::addr_t offset) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +000093 LLDB_RECORD_METHOD(void, SBAddress, SetAddress,
94 (lldb::SBSection, lldb::addr_t), section, offset);
95
Kate Stoneb9c1b512016-09-06 20:57:50 +000096 Address &addr = ref();
97 addr.SetSection(section.GetSP());
98 addr.SetOffset(offset);
99}
100
Jonas Devlieghere6cd4a4c2020-09-25 11:15:44 -0700101void SBAddress::SetAddress(const Address &address) { ref() = address; }
Kate Stoneb9c1b512016-09-06 20:57:50 +0000102
103lldb::addr_t SBAddress::GetFileAddress() const {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000104 LLDB_RECORD_METHOD_CONST_NO_ARGS(lldb::addr_t, SBAddress, GetFileAddress);
105
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000106 if (m_opaque_up->IsValid())
107 return m_opaque_up->GetFileAddress();
Kate Stoneb9c1b512016-09-06 20:57:50 +0000108 else
109 return LLDB_INVALID_ADDRESS;
110}
111
112lldb::addr_t SBAddress::GetLoadAddress(const SBTarget &target) const {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000113 LLDB_RECORD_METHOD_CONST(lldb::addr_t, SBAddress, GetLoadAddress,
114 (const lldb::SBTarget &), target);
115
Kate Stoneb9c1b512016-09-06 20:57:50 +0000116 lldb::addr_t addr = LLDB_INVALID_ADDRESS;
117 TargetSP target_sp(target.GetSP());
118 if (target_sp) {
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000119 if (m_opaque_up->IsValid()) {
Kate Stoneb9c1b512016-09-06 20:57:50 +0000120 std::lock_guard<std::recursive_mutex> guard(target_sp->GetAPIMutex());
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000121 addr = m_opaque_up->GetLoadAddress(target_sp.get());
Kate Stoneb9c1b512016-09-06 20:57:50 +0000122 }
123 }
124
Kate Stoneb9c1b512016-09-06 20:57:50 +0000125 return addr;
Chris Lattner30fdc8d2010-06-08 16:52:24 +0000126}
127
Kate Stoneb9c1b512016-09-06 20:57:50 +0000128void SBAddress::SetLoadAddress(lldb::addr_t load_addr, lldb::SBTarget &target) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000129 LLDB_RECORD_METHOD(void, SBAddress, SetLoadAddress,
130 (lldb::addr_t, lldb::SBTarget &), load_addr, target);
131
Kate Stoneb9c1b512016-09-06 20:57:50 +0000132 // Create the address object if we don't already have one
133 ref();
134 if (target.IsValid())
135 *this = target.ResolveLoadAddress(load_addr);
136 else
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000137 m_opaque_up->Clear();
Caroline Ticeceb6b132010-10-26 03:11:13 +0000138
Adrian Prantl05097242018-04-30 16:49:04 +0000139 // Check if we weren't were able to resolve a section offset address. If we
140 // weren't it is ok, the load address might be a location on the stack or
141 // heap, so we should just have an address with no section and a valid offset
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000142 if (!m_opaque_up->IsValid())
143 m_opaque_up->SetOffset(load_addr);
Kate Stoneb9c1b512016-09-06 20:57:50 +0000144}
145
146bool SBAddress::OffsetAddress(addr_t offset) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000147 LLDB_RECORD_METHOD(bool, SBAddress, OffsetAddress, (lldb::addr_t), offset);
148
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000149 if (m_opaque_up->IsValid()) {
150 addr_t addr_offset = m_opaque_up->GetOffset();
Kate Stoneb9c1b512016-09-06 20:57:50 +0000151 if (addr_offset != LLDB_INVALID_ADDRESS) {
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000152 m_opaque_up->SetOffset(addr_offset + offset);
Kate Stoneb9c1b512016-09-06 20:57:50 +0000153 return true;
Caroline Ticeceb6b132010-10-26 03:11:13 +0000154 }
Kate Stoneb9c1b512016-09-06 20:57:50 +0000155 }
156 return false;
Chris Lattner30fdc8d2010-06-08 16:52:24 +0000157}
158
Kate Stoneb9c1b512016-09-06 20:57:50 +0000159lldb::SBSection SBAddress::GetSection() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000160 LLDB_RECORD_METHOD_NO_ARGS(lldb::SBSection, SBAddress, GetSection);
161
Kate Stoneb9c1b512016-09-06 20:57:50 +0000162 lldb::SBSection sb_section;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000163 if (m_opaque_up->IsValid())
164 sb_section.SetSP(m_opaque_up->GetSection());
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000165 return LLDB_RECORD_RESULT(sb_section);
Greg Clayton00e6fbf2011-07-22 16:46:35 +0000166}
167
Kate Stoneb9c1b512016-09-06 20:57:50 +0000168lldb::addr_t SBAddress::GetOffset() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000169 LLDB_RECORD_METHOD_NO_ARGS(lldb::addr_t, SBAddress, GetOffset);
170
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000171 if (m_opaque_up->IsValid())
172 return m_opaque_up->GetOffset();
Kate Stoneb9c1b512016-09-06 20:57:50 +0000173 return 0;
Chris Lattner30fdc8d2010-06-08 16:52:24 +0000174}
175
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000176Address *SBAddress::operator->() { return m_opaque_up.get(); }
Kate Stoneb9c1b512016-09-06 20:57:50 +0000177
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000178const Address *SBAddress::operator->() const { return m_opaque_up.get(); }
Kate Stoneb9c1b512016-09-06 20:57:50 +0000179
180Address &SBAddress::ref() {
Konrad Kleine248a1302019-05-23 11:14:47 +0000181 if (m_opaque_up == nullptr)
Jonas Devlieghere1c0bbe42020-06-24 16:25:05 -0700182 m_opaque_up = std::make_unique<Address>();
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000183 return *m_opaque_up;
Greg Claytoncac9c5f2011-09-24 00:52:29 +0000184}
185
Kate Stoneb9c1b512016-09-06 20:57:50 +0000186const Address &SBAddress::ref() const {
Adrian Prantl05097242018-04-30 16:49:04 +0000187 // This object should already have checked with "IsValid()" prior to calling
188 // this function. In case you didn't we will assert and die to let you know.
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000189 assert(m_opaque_up.get());
190 return *m_opaque_up;
Greg Clayton13d19502012-01-29 06:07:39 +0000191}
Greg Claytoncac9c5f2011-09-24 00:52:29 +0000192
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000193Address *SBAddress::get() { return m_opaque_up.get(); }
Kate Stoneb9c1b512016-09-06 20:57:50 +0000194
195bool SBAddress::GetDescription(SBStream &description) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000196 LLDB_RECORD_METHOD(bool, SBAddress, GetDescription, (lldb::SBStream &),
197 description);
198
Kate Stoneb9c1b512016-09-06 20:57:50 +0000199 // Call "ref()" on the stream to make sure it creates a backing stream in
200 // case there isn't one already...
201 Stream &strm = description.ref();
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000202 if (m_opaque_up->IsValid()) {
Konrad Kleine248a1302019-05-23 11:14:47 +0000203 m_opaque_up->Dump(&strm, nullptr, Address::DumpStyleResolvedDescription,
Kate Stoneb9c1b512016-09-06 20:57:50 +0000204 Address::DumpStyleModuleWithFileAddress, 4);
Kate Stoneb9c1b512016-09-06 20:57:50 +0000205 } else
206 strm.PutCString("No value");
207
208 return true;
Greg Clayton09960032010-09-10 18:31:35 +0000209}
Chris Lattner30fdc8d2010-06-08 16:52:24 +0000210
Kate Stoneb9c1b512016-09-06 20:57:50 +0000211SBModule SBAddress::GetModule() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000212 LLDB_RECORD_METHOD_NO_ARGS(lldb::SBModule, SBAddress, GetModule);
213
Kate Stoneb9c1b512016-09-06 20:57:50 +0000214 SBModule sb_module;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000215 if (m_opaque_up->IsValid())
216 sb_module.SetSP(m_opaque_up->GetModule());
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000217 return LLDB_RECORD_RESULT(sb_module);
Chris Lattner30fdc8d2010-06-08 16:52:24 +0000218}
219
Kate Stoneb9c1b512016-09-06 20:57:50 +0000220SBSymbolContext SBAddress::GetSymbolContext(uint32_t resolve_scope) {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000221 LLDB_RECORD_METHOD(lldb::SBSymbolContext, SBAddress, GetSymbolContext,
222 (uint32_t), resolve_scope);
223
Kate Stoneb9c1b512016-09-06 20:57:50 +0000224 SBSymbolContext sb_sc;
Zachary Turner991e4452018-10-25 20:45:19 +0000225 SymbolContextItem scope = static_cast<SymbolContextItem>(resolve_scope);
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000226 if (m_opaque_up->IsValid())
227 m_opaque_up->CalculateSymbolContext(&sb_sc.ref(), scope);
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000228 return LLDB_RECORD_RESULT(sb_sc);
Greg Clayton09960032010-09-10 18:31:35 +0000229}
230
Kate Stoneb9c1b512016-09-06 20:57:50 +0000231SBCompileUnit SBAddress::GetCompileUnit() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000232 LLDB_RECORD_METHOD_NO_ARGS(lldb::SBCompileUnit, SBAddress, GetCompileUnit);
233
Kate Stoneb9c1b512016-09-06 20:57:50 +0000234 SBCompileUnit sb_comp_unit;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000235 if (m_opaque_up->IsValid())
236 sb_comp_unit.reset(m_opaque_up->CalculateSymbolContextCompileUnit());
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000237 return LLDB_RECORD_RESULT(sb_comp_unit);
Chris Lattner30fdc8d2010-06-08 16:52:24 +0000238}
239
Kate Stoneb9c1b512016-09-06 20:57:50 +0000240SBFunction SBAddress::GetFunction() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000241 LLDB_RECORD_METHOD_NO_ARGS(lldb::SBFunction, SBAddress, GetFunction);
242
Kate Stoneb9c1b512016-09-06 20:57:50 +0000243 SBFunction sb_function;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000244 if (m_opaque_up->IsValid())
245 sb_function.reset(m_opaque_up->CalculateSymbolContextFunction());
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000246 return LLDB_RECORD_RESULT(sb_function);
Caroline Tice750cd172010-10-26 23:49:36 +0000247}
Chris Lattner30fdc8d2010-06-08 16:52:24 +0000248
Kate Stoneb9c1b512016-09-06 20:57:50 +0000249SBBlock SBAddress::GetBlock() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000250 LLDB_RECORD_METHOD_NO_ARGS(lldb::SBBlock, SBAddress, GetBlock);
251
Kate Stoneb9c1b512016-09-06 20:57:50 +0000252 SBBlock sb_block;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000253 if (m_opaque_up->IsValid())
254 sb_block.SetPtr(m_opaque_up->CalculateSymbolContextBlock());
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000255 return LLDB_RECORD_RESULT(sb_block);
Caroline Ticedde9cff2010-09-20 05:20:02 +0000256}
Greg Clayton05d2b7f2011-03-31 01:08:07 +0000257
Kate Stoneb9c1b512016-09-06 20:57:50 +0000258SBSymbol SBAddress::GetSymbol() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000259 LLDB_RECORD_METHOD_NO_ARGS(lldb::SBSymbol, SBAddress, GetSymbol);
260
Kate Stoneb9c1b512016-09-06 20:57:50 +0000261 SBSymbol sb_symbol;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000262 if (m_opaque_up->IsValid())
263 sb_symbol.reset(m_opaque_up->CalculateSymbolContextSymbol());
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000264 return LLDB_RECORD_RESULT(sb_symbol);
Greg Clayton05d2b7f2011-03-31 01:08:07 +0000265}
266
Kate Stoneb9c1b512016-09-06 20:57:50 +0000267SBLineEntry SBAddress::GetLineEntry() {
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000268 LLDB_RECORD_METHOD_NO_ARGS(lldb::SBLineEntry, SBAddress, GetLineEntry);
269
Kate Stoneb9c1b512016-09-06 20:57:50 +0000270 SBLineEntry sb_line_entry;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000271 if (m_opaque_up->IsValid()) {
Kate Stoneb9c1b512016-09-06 20:57:50 +0000272 LineEntry line_entry;
Jonas Devlieghered5b44032019-02-13 06:25:41 +0000273 if (m_opaque_up->CalculateSymbolContextLineEntry(line_entry))
Kate Stoneb9c1b512016-09-06 20:57:50 +0000274 sb_line_entry.SetLineEntry(line_entry);
275 }
Jonas Devliegherebaf56642019-03-06 00:06:00 +0000276 return LLDB_RECORD_RESULT(sb_line_entry);
Greg Clayton7e9b1fd2011-08-12 21:40:01 +0000277}
Michal Gornyae211ec2019-03-19 17:13:13 +0000278
279namespace lldb_private {
280namespace repro {
281
282template <>
283void RegisterMethods<SBAddress>(Registry &R) {
284 LLDB_REGISTER_CONSTRUCTOR(SBAddress, ());
285 LLDB_REGISTER_CONSTRUCTOR(SBAddress, (const lldb::SBAddress &));
286 LLDB_REGISTER_CONSTRUCTOR(SBAddress, (lldb::SBSection, lldb::addr_t));
287 LLDB_REGISTER_CONSTRUCTOR(SBAddress, (lldb::addr_t, lldb::SBTarget &));
288 LLDB_REGISTER_METHOD(const lldb::SBAddress &,
289 SBAddress, operator=,(const lldb::SBAddress &));
Pavel Labath4bc05002019-04-02 10:18:46 +0000290 LLDB_REGISTER_METHOD_CONST(bool,
291 SBAddress, operator!=,(const lldb::SBAddress &));
Michal Gornyae211ec2019-03-19 17:13:13 +0000292 LLDB_REGISTER_METHOD_CONST(bool, SBAddress, IsValid, ());
293 LLDB_REGISTER_METHOD_CONST(bool, SBAddress, operator bool, ());
294 LLDB_REGISTER_METHOD(void, SBAddress, Clear, ());
295 LLDB_REGISTER_METHOD(void, SBAddress, SetAddress,
296 (lldb::SBSection, lldb::addr_t));
297 LLDB_REGISTER_METHOD_CONST(lldb::addr_t, SBAddress, GetFileAddress, ());
298 LLDB_REGISTER_METHOD_CONST(lldb::addr_t, SBAddress, GetLoadAddress,
299 (const lldb::SBTarget &));
300 LLDB_REGISTER_METHOD(void, SBAddress, SetLoadAddress,
301 (lldb::addr_t, lldb::SBTarget &));
302 LLDB_REGISTER_METHOD(bool, SBAddress, OffsetAddress, (lldb::addr_t));
303 LLDB_REGISTER_METHOD(lldb::SBSection, SBAddress, GetSection, ());
304 LLDB_REGISTER_METHOD(lldb::addr_t, SBAddress, GetOffset, ());
305 LLDB_REGISTER_METHOD(bool, SBAddress, GetDescription, (lldb::SBStream &));
306 LLDB_REGISTER_METHOD(lldb::SBModule, SBAddress, GetModule, ());
307 LLDB_REGISTER_METHOD(lldb::SBSymbolContext, SBAddress, GetSymbolContext,
308 (uint32_t));
309 LLDB_REGISTER_METHOD(lldb::SBCompileUnit, SBAddress, GetCompileUnit, ());
310 LLDB_REGISTER_METHOD(lldb::SBFunction, SBAddress, GetFunction, ());
311 LLDB_REGISTER_METHOD(lldb::SBBlock, SBAddress, GetBlock, ());
312 LLDB_REGISTER_METHOD(lldb::SBSymbol, SBAddress, GetSymbol, ());
313 LLDB_REGISTER_METHOD(lldb::SBLineEntry, SBAddress, GetLineEntry, ());
314}
315
316}
317}