LLDB  mainline
ValueObjectSyntheticFilter.cpp
Go to the documentation of this file.
1 //===-- ValueObjectSyntheticFilter.cpp ------------------------------------===//
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 
10 
11 #include "lldb/Core/Value.h"
12 #include "lldb/Core/ValueObject.h"
15 #include "lldb/Utility/Log.h"
16 #include "lldb/Utility/Logging.h"
17 #include "lldb/Utility/Status.h"
18 
19 #include "llvm/ADT/STLExtras.h"
20 
21 namespace lldb_private {
22 class Declaration;
23 }
24 
25 using namespace lldb_private;
26 
28 public:
30  : SyntheticChildrenFrontEnd(backend) {}
31 
32  size_t CalculateNumChildren() override { return m_backend.GetNumChildren(); }
33 
34  lldb::ValueObjectSP GetChildAtIndex(size_t idx) override {
35  return m_backend.GetChildAtIndex(idx, true);
36  }
37 
38  size_t GetIndexOfChildWithName(ConstString name) override {
39  return m_backend.GetIndexOfChildWithName(name);
40  }
41 
42  bool MightHaveChildren() override { return true; }
43 
44  bool Update() override { return false; }
45 };
46 
48  lldb::SyntheticChildrenSP filter)
49  : ValueObject(parent), m_synth_sp(std::move(filter)), m_children_byindex(),
50  m_name_toindex(), m_synthetic_children_cache(),
51  m_synthetic_children_count(UINT32_MAX),
52  m_parent_type_name(parent.GetTypeName()),
53  m_might_have_children(eLazyBoolCalculate),
54  m_provides_value(eLazyBoolCalculate) {
55  SetName(parent.GetName());
56  // Copying the data of an incomplete type won't work as it has no byte size.
60 }
61 
63 
65  return m_parent->GetCompilerType();
66 }
67 
69  return m_parent->GetTypeName();
70 }
71 
74 }
75 
77  if (ConstString synth_name = m_synth_filter_up->GetSyntheticTypeName())
78  return synth_name;
79 
80  return m_parent->GetDisplayTypeName();
81 }
82 
85 
89 
90  if (max < UINT32_MAX) {
91  size_t num_children = m_synth_filter_up->CalculateNumChildren(max);
92  LLDB_LOGF(log,
93  "[ValueObjectSynthetic::CalculateNumChildren] for VO of name "
94  "%s and type %s, the filter returned %zu child values",
95  GetName().AsCString(), GetTypeName().AsCString(), num_children);
96  return num_children;
97  } else {
98  size_t num_children = (m_synthetic_children_count =
99  m_synth_filter_up->CalculateNumChildren(max));
100  LLDB_LOGF(log,
101  "[ValueObjectSynthetic::CalculateNumChildren] for VO of name "
102  "%s and type %s, the filter returned %zu child values",
103  GetName().AsCString(), GetTypeName().AsCString(), num_children);
104  return num_children;
105  }
106 }
107 
108 lldb::ValueObjectSP
110  if (!m_parent)
111  return lldb::ValueObjectSP();
112  if (IsDynamic() && GetDynamicValueType() == valueType)
113  return GetSP();
114  return m_parent->GetDynamicValue(valueType);
115 }
116 
120  (m_synth_filter_up->MightHaveChildren() ? eLazyBoolYes : eLazyBoolNo);
122 }
123 
124 llvm::Optional<uint64_t> ValueObjectSynthetic::GetByteSize() {
125  return m_parent->GetByteSize();
126 }
127 
129  return m_parent->GetValueType();
130 }
131 
133  ValueObject *valobj_for_frontend = m_parent;
134  if (m_synth_sp->WantsDereference())
135  {
137  if (type.IsValid() && type.IsPointerOrReferenceType())
138  {
139  Status error;
140  lldb::ValueObjectSP deref_sp = m_parent->Dereference(error);
141  if (error.Success())
142  valobj_for_frontend = deref_sp.get();
143  }
144  }
145  m_synth_filter_up = (m_synth_sp->GetFrontEnd(*valobj_for_frontend));
146  if (!m_synth_filter_up)
147  m_synth_filter_up = std::make_unique<DummySyntheticFrontEnd>(*m_parent);
148 }
149 
152 
153  SetValueIsValid(false);
154  m_error.Clear();
155 
156  if (!m_parent->UpdateValueIfNeeded(false)) {
157  // our parent could not update.. as we are meaningless without a parent,
158  // just stop
159  if (m_parent->GetError().Fail())
161  return false;
162  }
163 
164  // regenerate the synthetic filter if our typename changes
165  // <rdar://problem/12424824>
166  ConstString new_parent_type_name = m_parent->GetTypeName();
167  if (new_parent_type_name != m_parent_type_name) {
168  LLDB_LOGF(log,
169  "[ValueObjectSynthetic::UpdateValue] name=%s, type changed "
170  "from %s to %s, recomputing synthetic filter",
171  GetName().AsCString(), m_parent_type_name.AsCString(),
172  new_parent_type_name.AsCString());
173  m_parent_type_name = new_parent_type_name;
175  }
176 
177  // let our backend do its update
178  if (!m_synth_filter_up->Update()) {
179  LLDB_LOGF(log,
180  "[ValueObjectSynthetic::UpdateValue] name=%s, synthetic "
181  "filter said caches are stale - clearing",
182  GetName().AsCString());
183  // filter said that cached values are stale
184  {
185  std::lock_guard<std::mutex> guard(m_child_mutex);
186  m_children_byindex.clear();
187  m_name_toindex.clear();
188  }
189  // usually, an object's value can change but this does not alter its
190  // children count for a synthetic VO that might indeed happen, so we need
191  // to tell the upper echelons that they need to come back to us asking for
192  // children
194  {
195  std::lock_guard<std::mutex> guard(m_child_mutex);
197  }
200  } else {
201  LLDB_LOGF(log,
202  "[ValueObjectSynthetic::UpdateValue] name=%s, synthetic "
203  "filter said caches are still valid",
204  GetName().AsCString());
205  }
206 
208 
209  lldb::ValueObjectSP synth_val(m_synth_filter_up->GetSyntheticValue());
210 
211  if (synth_val && synth_val->CanProvideValue()) {
212  LLDB_LOGF(log,
213  "[ValueObjectSynthetic::UpdateValue] name=%s, synthetic "
214  "filter said it can provide a value",
215  GetName().AsCString());
216 
218  CopyValueData(synth_val.get());
219  } else {
220  LLDB_LOGF(log,
221  "[ValueObjectSynthetic::UpdateValue] name=%s, synthetic "
222  "filter said it will not provide a value",
223  GetName().AsCString());
224 
226  // Copying the data of an incomplete type won't work as it has no byte size.
229  }
230 
231  SetValueIsValid(true);
232  return true;
233 }
234 
235 lldb::ValueObjectSP ValueObjectSynthetic::GetChildAtIndex(size_t idx,
236  bool can_create) {
238 
239  LLDB_LOGF(log,
240  "[ValueObjectSynthetic::GetChildAtIndex] name=%s, retrieving "
241  "child at index %zu",
242  GetName().AsCString(), idx);
243 
245 
246  ValueObject *valobj;
247  bool child_is_cached;
248  {
249  std::lock_guard<std::mutex> guard(m_child_mutex);
250  auto cached_child_it = m_children_byindex.find(idx);
251  child_is_cached = cached_child_it != m_children_byindex.end();
252  if (child_is_cached)
253  valobj = cached_child_it->second;
254  }
255 
256  if (!child_is_cached) {
257  if (can_create && m_synth_filter_up != nullptr) {
258  LLDB_LOGF(log,
259  "[ValueObjectSynthetic::GetChildAtIndex] name=%s, child at "
260  "index %zu not cached and will be created",
261  GetName().AsCString(), idx);
262 
263  lldb::ValueObjectSP synth_guy = m_synth_filter_up->GetChildAtIndex(idx);
264 
265  LLDB_LOGF(
266  log,
267  "[ValueObjectSynthetic::GetChildAtIndex] name=%s, child at index "
268  "%zu created as %p (is "
269  "synthetic: %s)",
270  GetName().AsCString(), idx, static_cast<void *>(synth_guy.get()),
271  synth_guy.get()
272  ? (synth_guy->IsSyntheticChildrenGenerated() ? "yes" : "no")
273  : "no");
274 
275  if (!synth_guy)
276  return synth_guy;
277 
278  {
279  std::lock_guard<std::mutex> guard(m_child_mutex);
280  if (synth_guy->IsSyntheticChildrenGenerated())
281  m_synthetic_children_cache.push_back(synth_guy);
282  m_children_byindex[idx] = synth_guy.get();
283  }
284  synth_guy->SetPreferredDisplayLanguageIfNeeded(
286  return synth_guy;
287  } else {
288  LLDB_LOGF(log,
289  "[ValueObjectSynthetic::GetChildAtIndex] name=%s, child at "
290  "index %zu not cached and cannot "
291  "be created (can_create = %s, synth_filter = %p)",
292  GetName().AsCString(), idx, can_create ? "yes" : "no",
293  static_cast<void *>(m_synth_filter_up.get()));
294 
295  return lldb::ValueObjectSP();
296  }
297  } else {
298  LLDB_LOGF(log,
299  "[ValueObjectSynthetic::GetChildAtIndex] name=%s, child at "
300  "index %zu cached as %p",
301  GetName().AsCString(), idx, static_cast<void *>(valobj));
302 
303  return valobj->GetSP();
304  }
305 }
306 
307 lldb::ValueObjectSP
309  bool can_create) {
311 
312  uint32_t index = GetIndexOfChildWithName(name);
313 
314  if (index == UINT32_MAX)
315  return lldb::ValueObjectSP();
316 
317  return GetChildAtIndex(index, can_create);
318 }
319 
322 
323  uint32_t found_index = UINT32_MAX;
324  bool did_find;
325  {
326  std::lock_guard<std::mutex> guard(m_child_mutex);
327  auto name_to_index = m_name_toindex.find(name.GetCString());
328  did_find = name_to_index != m_name_toindex.end();
329  if (did_find)
330  found_index = name_to_index->second;
331  }
332 
333  if (!did_find && m_synth_filter_up != nullptr) {
334  uint32_t index = m_synth_filter_up->GetIndexOfChildWithName(name);
335  if (index == UINT32_MAX)
336  return index;
337  std::lock_guard<std::mutex> guard(m_child_mutex);
338  m_name_toindex[name.GetCString()] = index;
339  return index;
340  } else if (!did_find && m_synth_filter_up == nullptr)
341  return UINT32_MAX;
342  else /*if (iter != m_name_toindex.end())*/
343  return found_index;
344 }
345 
347 
349  return m_parent->GetSP();
350 }
351 
353  m_value = (source->UpdateValueIfNeeded(), source->GetValue());
355  m_error = m_value.GetValueAsData(&exe_ctx, m_data, GetModule().get());
356 }
357 
359  if (!UpdateValueIfNeeded())
360  return false;
362  return true;
363  return m_parent->CanProvideValue();
364 }
365 
366 bool ValueObjectSynthetic::SetValueFromCString(const char *value_str,
367  Status &error) {
368  return m_parent->SetValueFromCString(value_str, error);
369 }
370 
372  if (m_parent) {
374  m_parent->SetFormat(format);
375  }
376  this->ValueObject::SetFormat(format);
378 }
379 
381  lldb::LanguageType lang) {
383  if (m_parent)
385 }
386 
389  if (m_parent)
392  } else
394 }
395 
397  if (m_parent)
399  return false;
400 }
401 
403  if (m_parent)
406 }
407 
409  if (m_parent)
410  return m_parent->GetDeclaration(decl);
411 
412  return ValueObject::GetDeclaration(decl);
413 }
414 
416  if (m_parent)
417  return m_parent->GetLanguageFlags();
418  return this->ValueObject::GetLanguageFlags();
419 }
420 
422  if (m_parent)
423  m_parent->SetLanguageFlags(flags);
424  else
425  this->ValueObject::SetLanguageFlags(flags);
426 }
DummySyntheticFrontEnd::GetIndexOfChildWithName
size_t GetIndexOfChildWithName(ConstString name) override
Definition: ValueObjectSyntheticFilter.cpp:38
lldb_private::CompilerType::IsPointerOrReferenceType
bool IsPointerOrReferenceType(CompilerType *pointee_type=nullptr) const
Definition: CompilerType.cpp:166
lldb_private::ExecutionContext
Definition: ExecutionContext.h:292
lldb_private::ValueObject::IsInScope
virtual bool IsInScope()
Definition: ValueObject.h:420
lldb_private::ValueObject::CanProvideValue
virtual bool CanProvideValue()
Definition: ValueObject.cpp:3103
lldb_private::ValueObjectSynthetic::m_provides_value
LazyBool m_provides_value
Definition: ValueObjectSyntheticFilter.h:159
lldb_private::ValueObjectSynthetic::m_synthetic_children_cache
SyntheticChildrenCache m_synthetic_children_cache
Guarded by m_child_mutex;.
Definition: ValueObjectSyntheticFilter.h:149
lldb_private::ValueObject::ClearUserVisibleData
void ClearUserVisibleData(uint32_t items=ValueObject::eClearUserVisibleDataItemsAllStrings)
Definition: ValueObject.cpp:2929
lldb_private::ValueObject::SetValueIsValid
void SetValueIsValid(bool valid)
Definition: ValueObject.h:980
lldb_private::ValueObjectSynthetic::SetPreferredDisplayLanguage
void SetPreferredDisplayLanguage(lldb::LanguageType)
Definition: ValueObjectSyntheticFilter.cpp:380
lldb::Format
Format
Display format definitions.
Definition: lldb-enumerations.h:155
lldb_private::ValueObjectSynthetic::GetByteSize
llvm::Optional< uint64_t > GetByteSize() override
Definition: ValueObjectSyntheticFilter.cpp:124
lldb_private::ValueObject::SetLanguageFlags
virtual void SetLanguageFlags(uint64_t flags)
Definition: ValueObject.h:791
lldb_private::ValueObject::GetValue
const Value & GetValue() const
Definition: ValueObject.h:497
lldb_private::ValueObjectSynthetic::GetDynamicValueType
virtual lldb::DynamicValueType GetDynamicValueType()
Definition: ValueObjectSyntheticFilter.h:79
lldb_private::Value::GetValueAsData
Status GetValueAsData(ExecutionContext *exe_ctx, DataExtractor &data, Module *module)
Definition: Value.cpp:301
lldb_private::ValueObjectSynthetic::m_synthetic_children_count
uint32_t m_synthetic_children_count
Definition: ValueObjectSyntheticFilter.h:153
lldb_private::ValueObjectSynthetic::m_synth_filter_up
std::unique_ptr< SyntheticChildrenFrontEnd > m_synth_filter_up
Definition: ValueObjectSyntheticFilter.h:134
lldb_private::ValueObjectSynthetic::IsDynamic
bool IsDynamic() override
Definition: ValueObjectSyntheticFilter.h:71
lldb_private::ValueObjectSynthetic::CreateSynthFilter
virtual void CreateSynthFilter()
Definition: ValueObjectSyntheticFilter.cpp:132
lldb_private::ValueObject::SetFormat
virtual void SetFormat(lldb::Format format)
Definition: ValueObject.h:705
lldb_private::eLazyBoolYes
@ eLazyBoolYes
Definition: lldb-private-enumerations.h:115
lldb_private::CompilerType::IsCompleteType
bool IsCompleteType() const
Definition: CompilerType.cpp:83
LLDB_LOGF
#define LLDB_LOGF(log,...)
Definition: Log.h:249
lldb_private::ValueObjectSynthetic::SetSyntheticChildrenGenerated
void SetSyntheticChildrenGenerated(bool b) override
Definition: ValueObjectSyntheticFilter.cpp:402
lldb_private::ValueObjectSynthetic::SetLanguageFlags
void SetLanguageFlags(uint64_t flags) override
Definition: ValueObjectSyntheticFilter.cpp:421
lldb::LanguageType
LanguageType
Programming language type.
Definition: lldb-enumerations.h:436
lldb_private::SyntheticChildrenFrontEnd
Definition: TypeSynthetic.h:27
DummySyntheticFrontEnd::Update
bool Update() override
Definition: ValueObjectSyntheticFilter.cpp:44
lldb_private::ValueObject::IsSyntheticChildrenGenerated
virtual bool IsSyntheticChildrenGenerated()
Definition: ValueObject.h:641
lldb_private::ConstString::AsCString
const char * AsCString(const char *value_if_empty=nullptr) const
Get the string value as a C string.
Definition: ConstString.h:193
lldb_private::ValueObject::SetPreferredDisplayLanguage
void SetPreferredDisplayLanguage(lldb::LanguageType lt)
Definition: ValueObject.h:713
lldb_private::ValueObjectSynthetic::~ValueObjectSynthetic
~ValueObjectSynthetic() override
lldb_private::ValueObject::ValueObjectSynthetic
friend class ValueObjectSynthetic
Definition: ValueObject.h:935
lldb_private::ValueObject::GetQualifiedTypeName
virtual ConstString GetQualifiedTypeName()
Definition: ValueObject.h:369
lldb_private::ValueObjectSynthetic::GetDynamicValue
lldb::ValueObjectSP GetDynamicValue(lldb::DynamicValueType valueType) override
Definition: ValueObjectSyntheticFilter.cpp:109
lldb_private::ValueObject::m_preferred_display_language
lldb::LanguageType m_preferred_display_language
Definition: ValueObject.h:900
lldb_private::ValueObjectSynthetic::UpdateValue
bool UpdateValue() override
Definition: ValueObjectSyntheticFilter.cpp:150
lldb_private::ValueObjectSynthetic::m_name_toindex
NameToIndexMap m_name_toindex
Guarded by m_child_mutex;.
Definition: ValueObjectSyntheticFilter.h:147
lldb_private::ValueObjectSynthetic::m_child_mutex
std::mutex m_child_mutex
Definition: ValueObjectSyntheticFilter.h:143
lldb_private::ValueObject::GetTypeName
virtual ConstString GetTypeName()
Definition: ValueObject.h:365
lldb_private::ValueObject::GetError
const Status & GetError()
Definition: ValueObject.cpp:283
ValueObjectSyntheticFilter.h
lldb_private::ValueObject::GetDynamicValue
virtual lldb::ValueObjectSP GetDynamicValue(lldb::DynamicValueType valueType)
Definition: ValueObject.cpp:1835
lldb_private::ValueObjectSynthetic::IsSyntheticChildrenGenerated
bool IsSyntheticChildrenGenerated() override
Definition: ValueObjectSyntheticFilter.cpp:396
lldb_private::ValueObject::m_data
DataExtractor m_data
A data extractor that can be used to extract the value.
Definition: ValueObject.h:851
lldb_private::ValueObject::SetSyntheticChildrenGenerated
virtual void SetSyntheticChildrenGenerated(bool b)
Definition: ValueObject.h:645
error
static llvm::raw_ostream & error(Stream &strm)
Definition: CommandReturnObject.cpp:17
lldb_private::ValueObjectSynthetic::MightHaveChildren
bool MightHaveChildren() override
Find out if a ValueObject might have children.
Definition: ValueObjectSyntheticFilter.cpp:117
lldb_private::ValueObjectSynthetic::CalculateNumChildren
size_t CalculateNumChildren(uint32_t max) override
Should only be called by ValueObject::GetNumChildren().
Definition: ValueObjectSyntheticFilter.cpp:83
lldb_private::ValueObjectSynthetic::GetChildAtIndex
lldb::ValueObjectSP GetChildAtIndex(size_t idx, bool can_create) override
Definition: ValueObjectSyntheticFilter.cpp:235
lldb_private::ValueObject::Dereference
virtual lldb::ValueObjectSP Dereference(Status &error)
Definition: ValueObject.cpp:2633
Log.h
lldb_private::ValueObject::eClearUserVisibleDataItemsAll
@ eClearUserVisibleDataItemsAll
Definition: ValueObject.h:193
lldb_private::ValueObject::GetSP
lldb::ValueObjectSP GetSP()
Definition: ValueObject.h:555
lldb_private::ValueObjectSynthetic::GetDisplayTypeName
ConstString GetDisplayTypeName() override
Definition: ValueObjectSyntheticFilter.cpp:76
lldb_private::Status::Fail
bool Fail() const
Test for error condition.
Definition: Status.cpp:182
lldb_private::ValueObjectSynthetic::m_might_have_children
LazyBool m_might_have_children
Definition: ValueObjectSyntheticFilter.h:157
lldb_private::ConstString
Definition: ConstString.h:40
lldb_private::ValueObject::UpdateValueIfNeeded
bool UpdateValueIfNeeded(bool update_format=true)
Definition: ValueObject.cpp:111
lldb_private::GetLogIfAllCategoriesSet
Log * GetLogIfAllCategoriesSet(uint32_t mask)
Definition: Logging.cpp:58
lldb_private::ValueObjectSynthetic::m_synth_sp
lldb::SyntheticChildrenSP m_synth_sp
Definition: ValueObjectSyntheticFilter.h:133
lldb_private::ValueObjectSynthetic::GetValueType
lldb::ValueType GetValueType() const override
Definition: ValueObjectSyntheticFilter.cpp:128
lldb::DynamicValueType
DynamicValueType
Definition: lldb-enumerations.h:494
lldb_private::ValueObject::GetExecutionContextRef
const ExecutionContextRef & GetExecutionContextRef() const
Definition: ValueObject.h:330
LIBLLDB_LOG_DATAFORMATTERS
#define LIBLLDB_LOG_DATAFORMATTERS
Definition: Logging.h:43
lldb_private::ValueObjectSynthetic::GetDeclaration
bool GetDeclaration(Declaration &decl) override
Definition: ValueObjectSyntheticFilter.cpp:408
lldb_private::ValueObject::SetName
void SetName(ConstString name)
Change the name of the current ValueObject.
Definition: ValueObject.h:560
lldb_private::CompilerType::IsValid
bool IsValid() const
Definition: CompilerType.h:72
lldb_private::ValueObjectSynthetic::GetPreferredDisplayLanguage
lldb::LanguageType GetPreferredDisplayLanguage() override
Definition: ValueObjectSyntheticFilter.cpp:387
ValueObject.h
lldb_private::ValueObject::GetValueType
virtual lldb::ValueType GetValueType() const =0
lldb_private::ValueObject::SetValueFromCString
virtual bool SetValueFromCString(const char *value_str, Status &error)
Definition: ValueObject.cpp:1465
lldb_private::ValueObject::GetPreferredDisplayLanguage
virtual lldb::LanguageType GetPreferredDisplayLanguage()
Definition: ValueObject.cpp:3079
lldb_private::ValueObjectSynthetic::IsInScope
bool IsInScope() override
Definition: ValueObjectSyntheticFilter.cpp:346
lldb_private::ValueObjectSynthetic::GetCompilerTypeImpl
CompilerType GetCompilerTypeImpl() override
Definition: ValueObjectSyntheticFilter.cpp:64
DummySyntheticFrontEnd::GetChildAtIndex
lldb::ValueObjectSP GetChildAtIndex(size_t idx) override
Definition: ValueObjectSyntheticFilter.cpp:34
lldb_private::Status
Definition: Status.h:44
lldb_private::ValueObject
ValueObject:
Definition: ValueObject.h:105
lldb_private::ValueObjectSynthetic::GetLanguageFlags
uint64_t GetLanguageFlags() override
Definition: ValueObjectSyntheticFilter.cpp:415
lldb_private::ValueObject::GetName
ConstString GetName() const
Definition: ValueObject.h:467
lldb::ValueType
ValueType
Definition: lldb-enumerations.h:315
lldb::eLanguageTypeUnknown
@ eLanguageTypeUnknown
Unknown or invalid language value.
Definition: lldb-enumerations.h:437
lldb_private::ValueObjectSynthetic::CanProvideValue
bool CanProvideValue() override
Definition: ValueObjectSyntheticFilter.cpp:358
uint32_t
lldb_private::eLazyBoolNo
@ eLazyBoolNo
Definition: lldb-private-enumerations.h:115
TypeSynthetic.h
lldb_private::ValueObjectSynthetic::CopyValueData
void CopyValueData(ValueObject *source)
Definition: ValueObjectSyntheticFilter.cpp:352
lldb_private::ValueObject::m_value
Value m_value
Definition: ValueObject.h:852
lldb_private::ValueObject::m_parent
ValueObject * m_parent
The parent value object, or nullptr if this has no parent.
Definition: ValueObject.h:840
DummySyntheticFrontEnd
Definition: ValueObjectSyntheticFilter.cpp:27
lldb_private::ValueObject::GetDeclaration
virtual bool GetDeclaration(Declaration &decl)
Definition: ValueObject.cpp:1550
DummySyntheticFrontEnd::MightHaveChildren
bool MightHaveChildren() override
Definition: ValueObjectSyntheticFilter.cpp:42
UINT32_MAX
#define UINT32_MAX
Definition: lldb-defines.h:31
lldb_private::ValueObject::GetCompilerType
CompilerType GetCompilerType()
Definition: ValueObject.h:352
lldb_private::ValueObject::Bitflags::m_children_count_valid
bool m_children_count_valid
Definition: ValueObject.h:911
lldb_private::ValueObject::GetModule
virtual lldb::ModuleSP GetModule()
Return the module associated with this value object in case the value is from an executable file and ...
Definition: ValueObject.cpp:3024
lldb_private::ConstString::GetCString
const char * GetCString() const
Get the string value as a C string.
Definition: ConstString.h:216
lldb_private::CompilerType
Generic representation of a type in a programming language.
Definition: CompilerType.h:33
DummySyntheticFrontEnd::DummySyntheticFrontEnd
DummySyntheticFrontEnd(ValueObject &backend)
Definition: ValueObjectSyntheticFilter.cpp:29
Status.h
lldb_private::ValueObjectSynthetic::GetTypeName
ConstString GetTypeName() override
Definition: ValueObjectSyntheticFilter.cpp:68
lldb_private::ValueObject::GetDisplayTypeName
virtual ConstString GetDisplayTypeName()
Definition: ValueObject.h:367
lldb_private
A class that represents a running process on the host machine.
Definition: SBCommandInterpreterRunOptions.h:16
lldb_private::ValueObject::m_flags
struct lldb_private::ValueObject::Bitflags m_flags
lldb_private::eLazyBoolCalculate
@ eLazyBoolCalculate
Definition: lldb-private-enumerations.h:115
lldb_private::ValueObjectSynthetic::m_parent_type_name
ConstString m_parent_type_name
Definition: ValueObjectSyntheticFilter.h:155
lldb_private::ValueObjectSynthetic::GetChildMemberWithName
lldb::ValueObjectSP GetChildMemberWithName(ConstString name, bool can_create) override
Definition: ValueObjectSyntheticFilter.cpp:308
lldb_private::Status::Clear
void Clear()
Clear the object state.
Definition: Status.cpp:168
Logging.h
lldb_private::Log
Definition: Log.h:49
lldb_private::ValueObject::m_error
Status m_error
An error object that can describe any errors that occur when updating values.
Definition: ValueObject.h:855
lldb_private::ValueObjectSynthetic::SetValueFromCString
bool SetValueFromCString(const char *value_str, Status &error) override
Definition: ValueObjectSyntheticFilter.cpp:366
lldb_private::Declaration
Definition: Declaration.h:24
lldb_private::ValueObjectSynthetic::GetNonSyntheticValue
lldb::ValueObjectSP GetNonSyntheticValue() override
Definition: ValueObjectSyntheticFilter.cpp:348
lldb_private::ValueObjectSynthetic::GetIndexOfChildWithName
size_t GetIndexOfChildWithName(ConstString name) override
Definition: ValueObjectSyntheticFilter.cpp:320
lldb_private::ValueObjectSynthetic::GetQualifiedTypeName
ConstString GetQualifiedTypeName() override
Definition: ValueObjectSyntheticFilter.cpp:72
DummySyntheticFrontEnd::CalculateNumChildren
size_t CalculateNumChildren() override
Definition: ValueObjectSyntheticFilter.cpp:32
lldb_private::ValueObject::GetLanguageFlags
virtual uint64_t GetLanguageFlags()
Definition: ValueObject.h:789
Value.h
lldb_private::ValueObjectSynthetic::SetFormat
void SetFormat(lldb::Format format) override
Definition: ValueObjectSyntheticFilter.cpp:371
ExecutionContext.h
lldb_private::ValueObjectSynthetic::m_children_byindex
ByIndexMap m_children_byindex
Guarded by m_child_mutex;.
Definition: ValueObjectSyntheticFilter.h:145
lldb_private::ValueObject::GetByteSize
virtual llvm::Optional< uint64_t > GetByteSize()=0