LLDB  mainline
ValueObject.h
Go to the documentation of this file.
1 //===-- ValueObject.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_CORE_VALUEOBJECT_H
10 #define LLDB_CORE_VALUEOBJECT_H
11 
12 #include "lldb/Core/Value.h"
14 #include "lldb/Symbol/Type.h"
16 #include "lldb/Target/Process.h"
20 #include "lldb/Utility/Status.h"
21 #include "lldb/Utility/UserID.h"
22 #include "lldb/lldb-defines.h"
23 #include "lldb/lldb-enumerations.h"
24 #include "lldb/lldb-forward.h"
26 #include "lldb/lldb-types.h"
27 
28 #include "llvm/ADT/ArrayRef.h"
29 #include "llvm/ADT/Optional.h"
30 #include "llvm/ADT/SmallVector.h"
31 #include "llvm/ADT/StringRef.h"
32 
33 #include <functional>
34 #include <initializer_list>
35 #include <map>
36 #include <mutex>
37 #include <string>
38 #include <utility>
39 
40 #include <cstddef>
41 #include <cstdint>
42 
43 namespace lldb_private {
44 class Declaration;
45 class DumpValueObjectOptions;
46 class EvaluateExpressionOptions;
47 class ExecutionContextScope;
48 class Log;
49 class Scalar;
50 class Stream;
51 class SymbolContextScope;
52 class TypeFormatImpl;
53 class TypeSummaryImpl;
54 class TypeSummaryOptions;
55 
56 /// ValueObject:
57 ///
58 /// This abstract class provides an interface to a particular value, be it a
59 /// register, a local or global variable,
60 /// that is evaluated in some particular scope. The ValueObject also has the
61 /// capability of being the "child" of
62 /// some other variable object, and in turn of having children.
63 /// If a ValueObject is a root variable object - having no parent - then it must
64 /// be constructed with respect to some
65 /// particular ExecutionContextScope. If it is a child, it inherits the
66 /// ExecutionContextScope from its parent.
67 /// The ValueObject will update itself if necessary before fetching its value,
68 /// summary, object description, etc.
69 /// But it will always update itself in the ExecutionContextScope with which it
70 /// was originally created.
71 
72 /// A brief note on life cycle management for ValueObjects. This is a little
73 /// tricky because a ValueObject can contain
74 /// various other ValueObjects - the Dynamic Value, its children, the
75 /// dereference value, etc. Any one of these can be
76 /// handed out as a shared pointer, but for that contained value object to be
77 /// valid, the root object and potentially other
78 /// of the value objects need to stay around.
79 /// We solve this problem by handing out shared pointers to the Value Object and
80 /// any of its dependents using a shared
81 /// ClusterManager. This treats each shared pointer handed out for the entire
82 /// cluster as a reference to the whole
83 /// cluster. The whole cluster will stay around until the last reference is
84 /// released.
85 ///
86 /// The ValueObject mostly handle this automatically, if a value object is made
87 /// with a Parent ValueObject, then it adds
88 /// itself to the ClusterManager of the parent.
89 
90 /// It does mean that external to the ValueObjects we should only ever make
91 /// available ValueObjectSP's, never ValueObjects
92 /// or pointers to them. So all the "Root level" ValueObject derived
93 /// constructors should be private, and
94 /// should implement a Create function that new's up object and returns a Shared
95 /// Pointer that it gets from the GetSP() method.
96 ///
97 /// However, if you are making an derived ValueObject that will be contained in
98 /// a parent value object, you should just
99 /// hold onto a pointer to it internally, and by virtue of passing the parent
100 /// ValueObject into its constructor, it will
101 /// be added to the ClusterManager for the parent. Then if you ever hand out a
102 /// Shared Pointer to the contained ValueObject,
103 /// just do so by calling GetSP() on the contained object.
104 
105 class ValueObject {
106 public:
110  };
111 
121  };
122 
124  /// Out of data to parse.
126  /// Child element not found.
128  /// (Synthetic) child element not found.
130  /// [] only allowed for arrays.
132  /// . used when -> should be used.
134  /// -> used when . should be used.
136  /// ObjC ivar expansion not allowed.
138  /// [] not allowed by options.
140  /// [] not valid on objects other than scalars, pointers or arrays.
142  /// [] is good for arrays, but I cannot parse it.
144  /// [] is good for bitfields, but I cannot parse after it.
146  /// Something is malformed in he expression.
148  /// Impossible to apply & operator.
150  /// Impossible to apply * operator.
152  /// [] was expanded into a VOList.
154  /// getting the synthetic children failed.
157  };
158 
160  /// Anything but...
162  /// A bitfield.
164  /// A range [low-high].
166  /// A range [].
168  /// Several items in a VOList.
171  };
172 
174  /// Just return it.
176  /// Dereference the target.
178  /// Take target's address.
180  };
181 
194  };
195 
198  None,
199  ToSynthetic,
201  Both
202  };
203 
208 
210  bool dot = false, bool no_ivar = false, bool bitfield = true,
211  SyntheticChildrenTraversal synth_traverse =
214  m_allow_bitfields_syntax(bitfield),
215  m_synthetic_children_traversal(synth_traverse) {}
216 
219  return *this;
220  }
221 
224  return *this;
225  }
226 
228  m_no_fragile_ivar = false;
229  return *this;
230  }
231 
233  m_no_fragile_ivar = true;
234  return *this;
235  }
236 
239  return *this;
240  }
241 
243  m_allow_bitfields_syntax = false;
244  return *this;
245  }
246 
250  return *this;
251  }
252 
254  static GetValueForExpressionPathOptions g_default_options;
255 
256  return g_default_options;
257  }
258  };
259 
261  public:
262  EvaluationPoint();
263 
265  bool use_selected = false);
266 
267  EvaluationPoint(const EvaluationPoint &rhs);
268 
270 
272  return m_exe_ctx_ref;
273  }
274 
275  void SetIsConstant() {
276  SetUpdated();
278  }
279 
280  bool IsConstant() const { return !m_mod_id.IsValid(); }
281 
282  ProcessModID GetModID() const { return m_mod_id; }
283 
284  void SetUpdateID(ProcessModID new_id) { m_mod_id = new_id; }
285 
286  void SetNeedsUpdate() { m_needs_update = true; }
287 
288  void SetUpdated();
289 
290  bool NeedsUpdating(bool accept_invalid_exe_ctx) {
291  SyncWithProcessState(accept_invalid_exe_ctx);
292  return m_needs_update;
293  }
294 
295  bool IsValid() {
296  const bool accept_invalid_exe_ctx = false;
297  if (!m_mod_id.IsValid())
298  return false;
299  else if (SyncWithProcessState(accept_invalid_exe_ctx)) {
300  if (!m_mod_id.IsValid())
301  return false;
302  }
303  return true;
304  }
305 
306  void SetInvalid() {
307  // Use the stop id to mark us as invalid, leave the thread id and the
308  // stack id around for logging and history purposes.
310 
311  // Can't update an invalid state.
312  m_needs_update = false;
313  }
314 
315  private:
316  bool SyncWithProcessState(bool accept_invalid_exe_ctx);
317 
318  ProcessModID m_mod_id; // This is the stop id when this ValueObject was last
319  // evaluated.
321  bool m_needs_update = true;
322  };
323 
324  virtual ~ValueObject();
325 
326  const EvaluationPoint &GetUpdatePoint() const { return m_update_point; }
327 
329 
332  }
333 
334  lldb::TargetSP GetTargetSP() const {
336  }
337 
338  lldb::ProcessSP GetProcessSP() const {
340  }
341 
342  lldb::ThreadSP GetThreadSP() const {
344  }
345 
346  lldb::StackFrameSP GetFrameSP() const {
348  }
349 
350  void SetNeedsUpdate();
351 
353 
354  // this vends a TypeImpl that is useful at the SB API layer
355  virtual TypeImpl GetTypeImpl() { return TypeImpl(GetCompilerType()); }
356 
357  virtual bool CanProvideValue();
358 
359  // Subclasses must implement the functions below.
360  virtual llvm::Optional<uint64_t> GetByteSize() = 0;
361 
362  virtual lldb::ValueType GetValueType() const = 0;
363 
364  // Subclasses can implement the functions below.
366 
368 
370  return GetCompilerType().GetTypeName();
371  }
372 
375  }
376 
377  virtual uint32_t
378  GetTypeInfo(CompilerType *pointee_or_element_compiler_type = nullptr) {
379  return GetCompilerType().GetTypeInfo(pointee_or_element_compiler_type);
380  }
381 
382  virtual bool IsPointerType() { return GetCompilerType().IsPointerType(); }
383 
384  virtual bool IsArrayType() { return GetCompilerType().IsArrayType(); }
385 
386  virtual bool IsScalarType() { return GetCompilerType().IsScalarType(); }
387 
388  virtual bool IsPointerOrReferenceType() {
390  }
391 
392  virtual bool IsPossibleDynamicType();
393 
394  bool IsNilReference();
395 
397 
398  virtual bool IsBaseClass() { return false; }
399 
400  bool IsBaseClass(uint32_t &depth);
401 
402  virtual bool IsDereferenceOfParent() { return false; }
403 
404  bool IsIntegerType(bool &is_signed) {
405  return GetCompilerType().IsIntegerType(is_signed);
406  }
407 
408  virtual void GetExpressionPath(
409  Stream &s,
411 
412  lldb::ValueObjectSP GetValueForExpressionPath(
413  llvm::StringRef expression,
414  ExpressionPathScanEndReason *reason_to_stop = nullptr,
415  ExpressionPathEndResultType *final_value_type = nullptr,
416  const GetValueForExpressionPathOptions &options =
418  ExpressionPathAftermath *final_task_on_target = nullptr);
419 
420  virtual bool IsInScope() { return true; }
421 
422  virtual lldb::offset_t GetByteOffset() { return 0; }
423 
424  virtual uint32_t GetBitfieldBitSize() { return 0; }
425 
426  virtual uint32_t GetBitfieldBitOffset() { return 0; }
427 
428  bool IsBitfield() {
429  return (GetBitfieldBitSize() != 0) || (GetBitfieldBitOffset() != 0);
430  }
431 
432  virtual bool IsArrayItemForPointer() {
434  }
435 
436  virtual const char *GetValueAsCString();
437 
438  virtual bool GetValueAsCString(const lldb_private::TypeFormatImpl &format,
439  std::string &destination);
440 
441  bool GetValueAsCString(lldb::Format format, std::string &destination);
442 
443  virtual uint64_t GetValueAsUnsigned(uint64_t fail_value,
444  bool *success = nullptr);
445 
446  virtual int64_t GetValueAsSigned(int64_t fail_value, bool *success = nullptr);
447 
448  virtual bool SetValueFromCString(const char *value_str, Status &error);
449 
450  /// Return the module associated with this value object in case the value is
451  /// from an executable file and might have its data in sections of the file.
452  /// This can be used for variables.
453  virtual lldb::ModuleSP GetModule();
454 
455  ValueObject *GetRoot();
456 
457  /// Given a ValueObject, loop over itself and its parent, and its parent's
458  /// parent, .. until either the given callback returns false, or you end up at
459  /// a null pointer
460  ValueObject *FollowParentChain(std::function<bool(ValueObject *)>);
461 
462  virtual bool GetDeclaration(Declaration &decl);
463 
464  // The functions below should NOT be modified by subclasses
465  const Status &GetError();
466 
467  ConstString GetName() const { return m_name; }
468 
469  /// Returns a unique id for this ValueObject.
470  lldb::user_id_t GetID() const { return m_id.GetID(); }
471 
472  virtual lldb::ValueObjectSP GetChildAtIndex(size_t idx, bool can_create);
473 
474  // this will always create the children if necessary
475  lldb::ValueObjectSP GetChildAtIndexPath(llvm::ArrayRef<size_t> idxs,
476  size_t *index_of_error = nullptr);
477 
478  lldb::ValueObjectSP
479  GetChildAtIndexPath(llvm::ArrayRef<std::pair<size_t, bool>> idxs,
480  size_t *index_of_error = nullptr);
481 
482  // this will always create the children if necessary
483  lldb::ValueObjectSP GetChildAtNamePath(llvm::ArrayRef<ConstString> names,
484  ConstString *name_of_error = nullptr);
485 
486  lldb::ValueObjectSP
487  GetChildAtNamePath(llvm::ArrayRef<std::pair<ConstString, bool>> names,
488  ConstString *name_of_error = nullptr);
489 
490  virtual lldb::ValueObjectSP GetChildMemberWithName(ConstString name,
491  bool can_create);
492 
493  virtual size_t GetIndexOfChildWithName(ConstString name);
494 
495  size_t GetNumChildren(uint32_t max = UINT32_MAX);
496 
497  const Value &GetValue() const { return m_value; }
498 
499  Value &GetValue() { return m_value; }
500 
501  virtual bool ResolveValue(Scalar &scalar);
502 
503  // return 'false' whenever you set the error, otherwise callers may assume
504  // true means everything is OK - this will break breakpoint conditions among
505  // potentially a few others
506  virtual bool IsLogicalTrue(Status &error);
507 
508  virtual const char *GetLocationAsCString() {
510  }
511 
512  const char *
514 
515  bool
516  GetSummaryAsCString(TypeSummaryImpl *summary_ptr, std::string &destination,
518 
519  bool GetSummaryAsCString(std::string &destination,
520  const TypeSummaryOptions &options);
521 
522  bool GetSummaryAsCString(TypeSummaryImpl *summary_ptr,
523  std::string &destination,
524  const TypeSummaryOptions &options);
525 
526  const char *GetObjectDescription();
527 
529  ValueObjectRepresentationStyle val_obj_display,
530  lldb::Format custom_format);
531 
533  eDisable = false,
534  eAllow = true
535  };
536 
537  bool
539  ValueObjectRepresentationStyle val_obj_display =
541  lldb::Format custom_format = lldb::eFormatInvalid,
544  bool do_dump_error = true);
545  bool GetValueIsValid() const { return m_flags.m_value_is_valid; }
546 
547  // If you call this on a newly created ValueObject, it will always return
548  // false.
550 
551  bool UpdateValueIfNeeded(bool update_format = true);
552 
553  bool UpdateFormatsIfNeeded();
554 
555  lldb::ValueObjectSP GetSP() { return m_manager->GetSharedPointer(this); }
556 
557  /// Change the name of the current ValueObject. Should *not* be used from a
558  /// synthetic child provider as it would change the name of the non synthetic
559  /// child as well.
560  void SetName(ConstString name) { m_name = name; }
561 
562  virtual lldb::addr_t GetAddressOf(bool scalar_is_load_address = true,
563  AddressType *address_type = nullptr);
564 
565  lldb::addr_t GetPointerValue(AddressType *address_type = nullptr);
566 
567  lldb::ValueObjectSP GetSyntheticChild(ConstString key) const;
568 
569  lldb::ValueObjectSP GetSyntheticArrayMember(size_t index, bool can_create);
570 
571  lldb::ValueObjectSP GetSyntheticBitFieldChild(uint32_t from, uint32_t to,
572  bool can_create);
573 
574  lldb::ValueObjectSP GetSyntheticExpressionPathChild(const char *expression,
575  bool can_create);
576 
577  virtual lldb::ValueObjectSP
578  GetSyntheticChildAtOffset(uint32_t offset, const CompilerType &type,
579  bool can_create,
580  ConstString name_const_str = ConstString());
581 
582  virtual lldb::ValueObjectSP
583  GetSyntheticBase(uint32_t offset, const CompilerType &type, bool can_create,
584  ConstString name_const_str = ConstString());
585 
586  virtual lldb::ValueObjectSP GetDynamicValue(lldb::DynamicValueType valueType);
587 
589 
590  virtual lldb::ValueObjectSP GetStaticValue() { return GetSP(); }
591 
592  virtual lldb::ValueObjectSP GetNonSyntheticValue() { return GetSP(); }
593 
594  lldb::ValueObjectSP GetSyntheticValue();
595 
596  virtual bool HasSyntheticValue();
597 
598  virtual bool IsSynthetic() { return false; }
599 
600  lldb::ValueObjectSP
602  bool synthValue);
603 
604  virtual lldb::ValueObjectSP CreateConstantValue(ConstString name);
605 
606  virtual lldb::ValueObjectSP Dereference(Status &error);
607 
608  /// Creates a copy of the ValueObject with a new name and setting the current
609  /// ValueObject as its parent. It should be used when we want to change the
610  /// name of a ValueObject without modifying the actual ValueObject itself
611  /// (e.g. sythetic child provider).
612  virtual lldb::ValueObjectSP Clone(ConstString new_name);
613 
614  virtual lldb::ValueObjectSP AddressOf(Status &error);
615 
617 
619  AddressType address_type = eAddressTypeLoad) {}
620 
621  virtual lldb::ValueObjectSP Cast(const CompilerType &compiler_type);
622 
623  virtual lldb::ValueObjectSP CastPointerType(const char *name,
624  CompilerType &ast_type);
625 
626  virtual lldb::ValueObjectSP CastPointerType(const char *name,
627  lldb::TypeSP &type_sp);
628 
629  // The backing bits of this value object were updated, clear any descriptive
630  // string, so we know we have to refetch them.
631  virtual void ValueUpdated() {
635  }
636 
637  virtual bool IsDynamic() { return false; }
638 
639  virtual bool DoesProvideSyntheticValue() { return false; }
640 
643  }
644 
645  virtual void SetSyntheticChildrenGenerated(bool b) {
647  }
648 
650 
651  void Dump(Stream &s);
652 
653  void Dump(Stream &s, const DumpValueObjectOptions &options);
654 
655  static lldb::ValueObjectSP
656  CreateValueObjectFromExpression(llvm::StringRef name,
657  llvm::StringRef expression,
658  const ExecutionContext &exe_ctx);
659 
660  static lldb::ValueObjectSP
661  CreateValueObjectFromExpression(llvm::StringRef name,
662  llvm::StringRef expression,
663  const ExecutionContext &exe_ctx,
664  const EvaluateExpressionOptions &options);
665 
666  static lldb::ValueObjectSP
667  CreateValueObjectFromAddress(llvm::StringRef name, uint64_t address,
668  const ExecutionContext &exe_ctx,
669  CompilerType type);
670 
671  static lldb::ValueObjectSP
672  CreateValueObjectFromData(llvm::StringRef name, const DataExtractor &data,
673  const ExecutionContext &exe_ctx, CompilerType type);
674 
675  lldb::ValueObjectSP Persist();
676 
677  /// Returns true if this is a char* or a char[] if it is a char* and
678  /// check_pointer is true, it also checks that the pointer is valid.
679  bool IsCStringContainer(bool check_pointer = false);
680 
681  std::pair<size_t, bool>
682  ReadPointedString(lldb::DataBufferSP &buffer_sp, Status &error,
683  uint32_t max_length = 0, bool honor_array = true,
684  lldb::Format item_format = lldb::eFormatCharArray);
685 
686  virtual size_t GetPointeeData(DataExtractor &data, uint32_t item_idx = 0,
687  uint32_t item_count = 1);
688 
689  virtual uint64_t GetData(DataExtractor &data, Status &error);
690 
691  virtual bool SetData(DataExtractor &data, Status &error);
692 
693  virtual bool GetIsConstant() const { return m_update_point.IsConstant(); }
694 
695  bool NeedsUpdating() {
696  const bool accept_invalid_exe_ctx =
698  return m_update_point.NeedsUpdating(accept_invalid_exe_ctx);
699  }
700 
702 
703  lldb::Format GetFormat() const;
704 
705  virtual void SetFormat(lldb::Format format) {
706  if (format != m_format)
708  m_format = format;
709  }
710 
712 
715  }
716 
717  lldb::TypeSummaryImplSP GetSummaryFormat() {
719  return m_type_summary_sp;
720  }
721 
722  void SetSummaryFormat(lldb::TypeSummaryImplSP format) {
723  m_type_summary_sp = std::move(format);
725  }
726 
727  void SetValueFormat(lldb::TypeFormatImplSP format) {
728  m_type_format_sp = std::move(format);
730  }
731 
732  lldb::TypeFormatImplSP GetValueFormat() {
734  return m_type_format_sp;
735  }
736 
737  void SetSyntheticChildren(const lldb::SyntheticChildrenSP &synth_sp) {
738  if (synth_sp.get() == m_synthetic_children_sp.get())
739  return;
741  m_synthetic_children_sp = synth_sp;
742  }
743 
744  lldb::SyntheticChildrenSP GetSyntheticChildren() {
747  }
748 
749  // Use GetParent for display purposes, but if you want to tell the parent to
750  // update itself then use m_parent. The ValueObjectDynamicValue's parent is
751  // not the correct parent for displaying, they are really siblings, so for
752  // display it needs to route through to its grandparent.
753  virtual ValueObject *GetParent() { return m_parent; }
754 
755  virtual const ValueObject *GetParent() const { return m_parent; }
756 
758 
761  }
762 
764 
767  }
768 
769  /// Find out if a ValueObject might have children.
770  ///
771  /// This call is much more efficient than CalculateNumChildren() as
772  /// it doesn't need to complete the underlying type. This is designed
773  /// to be used in a UI environment in order to detect if the
774  /// disclosure triangle should be displayed or not.
775  ///
776  /// This function returns true for class, union, structure,
777  /// pointers, references, arrays and more. Again, it does so without
778  /// doing any expensive type completion.
779  ///
780  /// \return
781  /// Returns \b true if the ValueObject might have children, or \b
782  /// false otherwise.
783  virtual bool MightHaveChildren();
784 
785  virtual lldb::VariableSP GetVariable() { return nullptr; }
786 
787  virtual bool IsRuntimeSupportValue();
788 
789  virtual uint64_t GetLanguageFlags() { return m_language_flags; }
790 
791  virtual void SetLanguageFlags(uint64_t flags) { m_language_flags = flags; }
792 
793 protected:
795 
797  public:
799 
800  bool HasChildAtIndex(size_t idx) {
801  std::lock_guard<std::recursive_mutex> guard(m_mutex);
802  return (m_children.find(idx) != m_children.end());
803  }
804 
806  std::lock_guard<std::recursive_mutex> guard(m_mutex);
807  const auto iter = m_children.find(idx);
808  return ((iter == m_children.end()) ? nullptr : iter->second);
809  }
810 
811  void SetChildAtIndex(size_t idx, ValueObject *valobj) {
812  // we do not need to be mutex-protected to make a pair
813  ChildrenPair pair(idx, valobj);
814  std::lock_guard<std::recursive_mutex> guard(m_mutex);
815  m_children.insert(pair);
816  }
817 
818  void SetChildrenCount(size_t count) { Clear(count); }
819 
820  size_t GetChildrenCount() { return m_children_count; }
821 
822  void Clear(size_t new_count = 0) {
823  std::lock_guard<std::recursive_mutex> guard(m_mutex);
824  m_children_count = new_count;
825  m_children.clear();
826  }
827 
828  private:
829  typedef std::map<size_t, ValueObject *> ChildrenMap;
830  typedef ChildrenMap::iterator ChildrenIterator;
831  typedef ChildrenMap::value_type ChildrenPair;
832  std::recursive_mutex m_mutex;
834  size_t m_children_count = 0;
835  };
836 
837  // Classes that inherit from ValueObject can see and modify these
838 
839  /// The parent value object, or nullptr if this has no parent.
840  ValueObject *m_parent = nullptr;
841  /// The root of the hierarchy for this ValueObject (or nullptr if never
842  /// calculated).
843  ValueObject *m_root = nullptr;
844  /// Stores both the stop id and the full context at which this value was last
845  /// updated. When we are asked to update the value object, we check whether
846  /// the context & stop id are the same before updating.
848  /// The name of this object.
850  /// A data extractor that can be used to extract the value.
853  /// An error object that can describe any errors that occur when updating
854  /// values.
856  /// Cached value string that will get cleared if/when the value is updated.
858  /// Cached old value string from the last time the value was gotten
860  /// Cached location string that will get cleared if/when the value is updated.
862  /// Cached summary string that will get cleared if/when the value is updated.
864  /// Cached result of the "object printer". This differs from the summary
865  /// in that the summary is consed up by us, the object_desc_string is builtin.
867  /// If the type of the value object should be overridden, the type to impose.
869 
870  /// This object is managed by the root object (any ValueObject that gets
871  /// created without a parent.) The manager gets passed through all the
872  /// generations of dependent objects, and will keep the whole cluster of
873  /// objects alive as long as a shared pointer to any of them has been handed
874  /// out. Shared pointers to value objects must always be made with the GetSP
875  /// method.
877 
879  std::map<ConstString, ValueObject *> m_synthetic_children;
880 
884 
885  /// We have to hold onto a shared pointer to this one because it is created
886  /// as an independent ValueObjectConstResult, which isn't managed by us.
887  lldb::ValueObjectSP m_addr_of_valobj_sp;
888 
892  lldb::TypeSummaryImplSP m_type_summary_sp;
893  lldb::TypeFormatImplSP m_type_format_sp;
894  lldb::SyntheticChildrenSP m_synthetic_children_sp;
897 
898  llvm::SmallVector<uint8_t, 16> m_value_checksum;
899 
901 
902  uint64_t m_language_flags = 0;
903 
904  /// Unique identifier for every value object.
906 
907  // Utility class for initializing all bitfields in ValueObject's constructors.
908  // FIXME: This could be done via default initializers once we have C++20.
909  struct Bitflags {
917  m_value_is_valid = false;
918  m_value_did_change = false;
919  m_children_count_valid = false;
920  m_old_value_valid = false;
921  m_is_deref_of_parent = false;
923  m_is_bitfield_for_scalar = false;
924  m_is_child_at_offset = false;
925  m_is_getting_summary = false;
928  }
929  } m_flags;
930 
931  friend class ValueObjectChild;
932  friend class ExpressionVariable; // For SetName
933  friend class Target; // For SetName
935  friend class ValueObjectSynthetic; // For ClearUserVisibleData
936 
937  /// Use this constructor to create a "root variable object". The ValueObject
938  /// will be locked to this context through-out its lifespan.
940  AddressType child_ptr_or_ref_addr_type = eAddressTypeLoad);
941 
942  /// Use this constructor to create a ValueObject owned by another ValueObject.
943  /// It will inherit the ExecutionContext of its parent.
944  ValueObject(ValueObject &parent);
945 
947 
948  virtual bool UpdateValue() = 0;
949 
951  return eLazyBoolCalculate;
952  }
953 
954  virtual void CalculateDynamicValue(lldb::DynamicValueType use_dynamic);
955 
957  return lldb::eNoDynamicValues;
958  }
959 
960  virtual bool HasDynamicValueTypeInfo() { return false; }
961 
962  virtual void CalculateSyntheticValue();
963 
964  /// Should only be called by ValueObject::GetChildAtIndex().
965  ///
966  /// \return A ValueObject managed by this ValueObject's manager.
967  virtual ValueObject *CreateChildAtIndex(size_t idx,
968  bool synthetic_array_member,
969  int32_t synthetic_index);
970 
971  /// Should only be called by ValueObject::GetNumChildren().
972  virtual size_t CalculateNumChildren(uint32_t max = UINT32_MAX) = 0;
973 
974  void SetNumChildren(size_t num_children);
975 
976  void SetValueDidChange(bool value_changed) {
977  m_flags.m_value_did_change = value_changed;
978  }
979 
980  void SetValueIsValid(bool valid) { m_flags.m_value_is_valid = valid; }
981 
984 
985  void AddSyntheticChild(ConstString key, ValueObject *valobj);
986 
988 
990 
991  // Subclasses must implement the functions below.
992 
993  virtual CompilerType GetCompilerTypeImpl() = 0;
994 
995  const char *GetLocationAsCStringImpl(const Value &value,
996  const DataExtractor &data);
997 
998  bool IsChecksumEmpty() { return m_value_checksum.empty(); }
999 
1001 
1002 protected:
1003  virtual void DoUpdateChildrenAddressType(ValueObject &valobj) { return; };
1004 
1005 private:
1009  }
1010 
1011  lldb::ValueObjectSP GetValueForExpressionPath_Impl(
1012  llvm::StringRef expression_cstr,
1013  ExpressionPathScanEndReason *reason_to_stop,
1014  ExpressionPathEndResultType *final_value_type,
1015  const GetValueForExpressionPathOptions &options,
1016  ExpressionPathAftermath *final_task_on_target);
1017 
1018  ValueObject(const ValueObject &) = delete;
1019  const ValueObject &operator=(const ValueObject &) = delete;
1020 };
1021 
1022 } // namespace lldb_private
1023 
1024 #endif // LLDB_CORE_VALUEOBJECT_H
lldb_private::ValueObject::IsBitfield
bool IsBitfield()
Definition: ValueObject.h:428
lldb_private::ValueObject::MaybeCalculateCompleteType
virtual CompilerType MaybeCalculateCompleteType()
Definition: ValueObject.cpp:246
lldb_private::ValueObject::ChildrenManager::ChildrenManager
ChildrenManager()
Definition: ValueObject.h:798
lldb_private::ValueObject::GetLiveAddress
virtual lldb::addr_t GetLiveAddress()
Definition: ValueObject.h:616
lldb_private::ValueObject::PrintableRepresentationSpecialCases
PrintableRepresentationSpecialCases
Definition: ValueObject.h:532
lldb_private::ValueObject::eExpressionPathScanEndReasonNoSuchChild
@ eExpressionPathScanEndReasonNoSuchChild
Child element not found.
Definition: ValueObject.h:127
lldb_private::ValueObject::GetData
virtual uint64_t GetData(DataExtractor &data, Status &error)
Definition: ValueObject.cpp:765
lldb_private::CompilerType::IsPointerOrReferenceType
bool IsPointerOrReferenceType(CompilerType *pointee_type=nullptr) const
Definition: CompilerType.cpp:166
lldb_private::ValueObject::eExpressionPathAftermathTakeAddress
@ eExpressionPathAftermathTakeAddress
Take target's address.
Definition: ValueObject.h:179
lldb_private::ValueObject::GetValueForExpressionPath
lldb::ValueObjectSP GetValueForExpressionPath(llvm::StringRef expression, ExpressionPathScanEndReason *reason_to_stop=nullptr, ExpressionPathEndResultType *final_value_type=nullptr, const GetValueForExpressionPathOptions &options=GetValueForExpressionPathOptions::DefaultOptions(), ExpressionPathAftermath *final_task_on_target=nullptr)
Definition: ValueObject.cpp:1988
lldb_private::ValueObject::GetByteOffset
virtual lldb::offset_t GetByteOffset()
Definition: ValueObject.h:422
lldb_private::ValueObject::GetValueForExpressionPathOptions::SyntheticChildrenTraversal::FromSynthetic
@ FromSynthetic
lldb_private::ValueObject::GetValueAsUnsigned
virtual uint64_t GetValueAsUnsigned(uint64_t fail_value, bool *success=nullptr)
Definition: ValueObject.cpp:1090
lldb_private::ExecutionContext
Definition: ExecutionContext.h:292
lldb_private::ValueObject::eClearUserVisibleDataItemsDescription
@ eClearUserVisibleDataItemsDescription
Definition: ValueObject.h:187
lldb_private::ValueObject::GetChildAtIndexPath
lldb::ValueObjectSP GetChildAtIndexPath(llvm::ArrayRef< size_t > idxs, size_t *index_of_error=nullptr)
Definition: ValueObject.cpp:396
lldb_private::ValueObject::IsInScope
virtual bool IsInScope()
Definition: ValueObject.h:420
lldb_private::ValueObject::GetValueForExpressionPathOptions::DontAllowBitfieldSyntax
GetValueForExpressionPathOptions & DontAllowBitfieldSyntax()
Definition: ValueObject.h:242
lldb_private::ValueObject::ChildrenManager::m_children_count
size_t m_children_count
Definition: ValueObject.h:834
lldb_private::ValueObject::operator=
const ValueObject & operator=(const ValueObject &)=delete
lldb_private::ValueObject::CanProvideValue
virtual bool CanProvideValue()
Definition: ValueObject.cpp:3103
lldb_private::ValueObject::eExpressionPathAftermathNothing
@ eExpressionPathAftermathNothing
Just return it.
Definition: ValueObject.h:175
lldb_private::ValueObject::IsRuntimeSupportValue
virtual bool IsRuntimeSupportValue()
Definition: ValueObject.cpp:1578
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::ValueObject::EvaluationPoint::SetIsConstant
void SetIsConstant()
Definition: ValueObject.h:275
lldb_private::ValueObject::~ValueObject
virtual ~ValueObject()
lldb_private::ProcessModID::SetInvalid
void SetInvalid()
Definition: Process.h:276
lldb_private::ValueObject::GetUpdatePoint
const EvaluationPoint & GetUpdatePoint() const
Definition: ValueObject.h:326
lldb_private::ValueObject::GetValueForExpressionPathOptions
Definition: ValueObject.h:196
lldb_private::ProcessModID::IsValid
bool IsValid() const
Definition: Process.h:278
lldb_private::ValueObject::IsNilReference
bool IsNilReference()
Definition: ValueObject.cpp:1595
lldb::Format
Format
Display format definitions.
Definition: lldb-enumerations.h:155
lldb_private::ValueObject::SetLanguageFlags
virtual void SetLanguageFlags(uint64_t flags)
Definition: ValueObject.h:791
lldb_private::ValueObject::ChildrenManager::ChildrenIterator
ChildrenMap::iterator ChildrenIterator
Definition: ValueObject.h:830
lldb_private::ValueObject::GetValue
const Value & GetValue() const
Definition: ValueObject.h:497
lldb_private::TypeSummaryImpl
Definition: TypeSummary.h:45
lldb_private::ValueObject::IsDynamic
virtual bool IsDynamic()
Definition: ValueObject.h:637
lldb_private::ValueObject::GetPointeeData
virtual size_t GetPointeeData(DataExtractor &data, uint32_t item_idx=0, uint32_t item_count=1)
Definition: ValueObject.cpp:663
lldb_private::Value
Definition: Value.h:38
lldb::eNoDynamicValues
@ eNoDynamicValues
Definition: lldb-enumerations.h:495
lldb_private::ClusterManager::GetSharedPointer
std::shared_ptr< T > GetSharedPointer(T *desired_object)
Definition: SharedCluster.h:40
lldb_private::ValueObject::Persist
lldb::ValueObjectSP Persist()
Definition: ValueObject.cpp:3113
lldb_private::ValueObject::eClearUserVisibleDataItemsLocation
@ eClearUserVisibleDataItemsLocation
Definition: ValueObject.h:186
lldb_private::ValueObject::IsSynthetic
virtual bool IsSynthetic()
Definition: ValueObject.h:598
lldb_private::ValueObject::m_manager
ValueObjectManager * m_manager
This object is managed by the root object (any ValueObject that gets created without a parent....
Definition: ValueObject.h:876
lldb_private::ExecutionContextRef::GetThreadSP
lldb::ThreadSP GetThreadSP() const
Get accessor that creates a strong reference from the weak thread reference contained in this object.
Definition: ExecutionContext.cpp:580
lldb_private::ValueObject::GetValueForExpressionPathOptions::SetSyntheticChildrenTraversal
GetValueForExpressionPathOptions & SetSyntheticChildrenTraversal(SyntheticChildrenTraversal traverse)
Definition: ValueObject.h:248
lldb_private::ValueObject::eValueObjectRepresentationStyleValue
@ eValueObjectRepresentationStyleValue
Definition: ValueObject.h:113
lldb_private::ValueObject::EvaluationPoint::SetUpdated
void SetUpdated()
Definition: ValueObject.cpp:2922
lldb-defines.h
lldb_private::ValueObject::eExpressionPathScanEndReasonRangeOperatorInvalid
@ eExpressionPathScanEndReasonRangeOperatorInvalid
[] not valid on objects other than scalars, pointers or arrays.
Definition: ValueObject.h:141
lldb_private::ValueObject::ChildrenManager::m_children
ChildrenMap m_children
Definition: ValueObject.h:833
lldb_private::ValueObject::Bitflags::m_is_getting_summary
bool m_is_getting_summary
Definition: ValueObject.h:914
lldb_private::UserID
Definition: UserID.h:31
lldb_private::AddressType
AddressType
Definition: lldb-private-enumerations.h:30
lldb_private::ValueObject::GetValueForExpressionPathOptions::SyntheticChildrenTraversal::None
@ None
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::ValueObject::m_name
ConstString m_name
The name of this object.
Definition: ValueObject.h:849
lldb_private::Scalar
Definition: Scalar.h:34
lldb_private::ValueObject::FollowParentChain
ValueObject * FollowParentChain(std::function< bool(ValueObject *)>)
Given a ValueObject, loop over itself and its parent, and its parent's parent, .
Definition: ValueObject.cpp:3040
lldb_private::ClusterManager
Definition: SharedCluster.h:22
lldb_private::ValueObject::GetValueDidChange
bool GetValueDidChange()
Definition: ValueObject.h:549
lldb_private::ValueObject::eClearUserVisibleDataItemsSummary
@ eClearUserVisibleDataItemsSummary
Definition: ValueObject.h:185
lldb_private::ValueObject::GetValueForExpressionPathOptions::GetValueForExpressionPathOptions
GetValueForExpressionPathOptions(bool dot=false, bool no_ivar=false, bool bitfield=true, SyntheticChildrenTraversal synth_traverse=SyntheticChildrenTraversal::ToSynthetic)
Definition: ValueObject.h:209
lldb_private::ValueObject::m_location_str
std::string m_location_str
Cached location string that will get cleared if/when the value is updated.
Definition: ValueObject.h:861
lldb_private::ValueObject::m_object_desc_str
std::string m_object_desc_str
Cached result of the "object printer".
Definition: ValueObject.h:866
lldb_private::EvaluateExpressionOptions
Definition: Target.h:259
lldb_private::ValueObject::SetValueDidChange
void SetValueDidChange(bool value_changed)
Definition: ValueObject.h:976
lldb_private::ValueObject::GetPointerValue
lldb::addr_t GetPointerValue(AddressType *address_type=nullptr)
Definition: ValueObject.cpp:1436
lldb_private::ValueObject::GetValueAsSigned
virtual int64_t GetValueAsSigned(int64_t fail_value, bool *success=nullptr)
Definition: ValueObject.cpp:1108
lldb_private::ValueObject::GetQualifiedRepresentationIfAvailable
lldb::ValueObjectSP GetQualifiedRepresentationIfAvailable(lldb::DynamicValueType dynValue, bool synthValue)
Definition: ValueObject.cpp:2598
lldb::LanguageType
LanguageType
Programming language type.
Definition: lldb-enumerations.h:436
lldb_private::ValueObject::ValueObject
ValueObject(ExecutionContextScope *exe_scope, ValueObjectManager &manager, AddressType child_ptr_or_ref_addr_type=eAddressTypeLoad)
Use this constructor to create a "root variable object".
Definition: ValueObject.cpp:91
lldb_private::ValueObject::IsSyntheticChildrenGenerated
virtual bool IsSyntheticChildrenGenerated()
Definition: ValueObject.h:641
lldb_private::ValueObject::eExpressionPathAftermathDereference
@ eExpressionPathAftermathDereference
Dereference the target.
Definition: ValueObject.h:177
lldb_private::ValueObject::m_summary_str
std::string m_summary_str
Cached summary string that will get cleared if/when the value is updated.
Definition: ValueObject.h:863
lldb::offset_t
uint64_t offset_t
Definition: lldb-types.h:87
lldb_private::ValueObject::m_override_type
CompilerType m_override_type
If the type of the value object should be overridden, the type to impose.
Definition: ValueObject.h:868
lldb_private::ValueObject::GetBitfieldBitSize
virtual uint32_t GetBitfieldBitSize()
Definition: ValueObject.h:424
lldb_private::ValueObject::SetPreferredDisplayLanguage
void SetPreferredDisplayLanguage(lldb::LanguageType lt)
Definition: ValueObject.h:713
lldb_private::ValueObject::IsPointerType
virtual bool IsPointerType()
Definition: ValueObject.h:382
lldb_private::ValueObject::GetValueForExpressionPathOptions::DoCheckDotVsArrowSyntax
GetValueForExpressionPathOptions & DoCheckDotVsArrowSyntax()
Definition: ValueObject.h:217
lldb_private::ValueObject::m_value_checksum
llvm::SmallVector< uint8_t, 16 > m_value_checksum
Definition: ValueObject.h:898
lldb_private::Stream
Definition: Stream.h:28
lldb_private::ValueObject::m_children
ChildrenManager m_children
Definition: ValueObject.h:878
lldb::addr_t
uint64_t addr_t
Definition: lldb-types.h:83
lldb_private::ValueObject::eValueObjectRepresentationStyleName
@ eValueObjectRepresentationStyleName
Definition: ValueObject.h:119
lldb_private::ValueObject::m_synthetic_value
ValueObject * m_synthetic_value
Definition: ValueObject.h:882
lldb_private::ValueObject::GetRoot
ValueObject * GetRoot()
Definition: ValueObject.cpp:3031
lldb_private::ValueObject::IsArrayType
virtual bool IsArrayType()
Definition: ValueObject.h:384
lldb_private::ValueObject::GetQualifiedTypeName
virtual ConstString GetQualifiedTypeName()
Definition: ValueObject.h:369
lldb_private::LazyBool
LazyBool
Definition: lldb-private-enumerations.h:115
lldb_private::ValueObject::GetValueForExpressionPathOptions::SyntheticChildrenTraversal
SyntheticChildrenTraversal
Definition: ValueObject.h:197
lldb_private::ValueObject::IsPointerOrReferenceType
virtual bool IsPointerOrReferenceType()
Definition: ValueObject.h:388
lldb_private::ValueObject::m_preferred_display_language
lldb::LanguageType m_preferred_display_language
Definition: ValueObject.h:900
lldb_private::ValueObject::GetDataExtractor
DataExtractor & GetDataExtractor()
Definition: ValueObject.cpp:278
lldb_private::ValueObject::m_synthetic_children
std::map< ConstString, ValueObject * > m_synthetic_children
Definition: ValueObject.h:879
lldb-private-enumerations.h
lldb_private::Target
Definition: Target.h:451
lldb_private::ValueObject::m_old_value_str
std::string m_old_value_str
Cached old value string from the last time the value was gotten.
Definition: ValueObject.h:859
lldb_private::ValueObject::GetTypeName
virtual ConstString GetTypeName()
Definition: ValueObject.h:365
lldb_private::ValueObject::GetManager
ValueObjectManager * GetManager()
Definition: ValueObject.h:946
lldb_private::ValueObject::GetExpressionPath
virtual void GetExpressionPath(Stream &s, GetExpressionPathFormat=eGetExpressionPathFormatDereferencePointers)
Definition: ValueObject.cpp:1893
lldb_private::ValueObject::UpdateChildrenAddressType
void UpdateChildrenAddressType()
Definition: ValueObject.h:1007
lldb_private::ValueObject::eValueObjectRepresentationStyleLocation
@ eValueObjectRepresentationStyleLocation
Definition: ValueObject.h:116
Process.h
lldb_private::ValueObject::Bitflags::Bitflags
Bitflags()
Definition: ValueObject.h:916
lldb_private::ValueObject::GetExpressionPathFormat
GetExpressionPathFormat
Definition: ValueObject.h:107
lldb_private::ValueObject::SetIsConstant
void SetIsConstant()
Definition: ValueObject.h:701
lldb_private::ValueObject::GetError
const Status & GetError()
Definition: ValueObject.cpp:283
lldb_private::ValueObject::GetValueForExpressionPathOptions::m_no_fragile_ivar
bool m_no_fragile_ivar
Definition: ValueObject.h:205
lldb_private::ValueObject::IsUninitializedReference
bool IsUninitializedReference()
Definition: ValueObject.cpp:1602
lldb_private::ValueObject::eClearUserVisibleDataItemsAllStrings
@ eClearUserVisibleDataItemsAllStrings
Definition: ValueObject.h:189
lldb_private::ValueObject::GetDynamicValue
virtual lldb::ValueObjectSP GetDynamicValue(lldb::DynamicValueType valueType)
Definition: ValueObject.cpp:1835
lldb_private::ValueObject::EvaluationPoint::SetUpdateID
void SetUpdateID(ProcessModID new_id)
Definition: ValueObject.h:284
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::EvaluationPoint::IsConstant
bool IsConstant() const
Definition: ValueObject.h:280
lldb_private::ValueObject::eClearUserVisibleDataItemsValue
@ eClearUserVisibleDataItemsValue
Definition: ValueObject.h:184
lldb_private::TypeFormatImpl
Definition: TypeFormat.h:24
lldb_private::ValueObject::GetValueForExpressionPathOptions::m_check_dot_vs_arrow_syntax
bool m_check_dot_vs_arrow_syntax
Definition: ValueObject.h:204
lldb_private::ValueObject::GetValueForExpressionPathOptions::SyntheticChildrenTraversal::Both
@ Both
lldb_private::ValueObject::GetChildAtIndex
virtual lldb::ValueObjectSP GetChildAtIndex(size_t idx, bool can_create)
Definition: ValueObject.cpp:375
lldb_private::ValueObject::GetProcessSP
lldb::ProcessSP GetProcessSP() const
Definition: ValueObject.h:338
lldb_private::ValueObject::CreateValueObjectFromExpression
static lldb::ValueObjectSP CreateValueObjectFromExpression(llvm::StringRef name, llvm::StringRef expression, const ExecutionContext &exe_ctx)
Definition: ValueObject.cpp:2962
lldb_private::ValueObject::SetSyntheticChildrenGenerated
virtual void SetSyntheticChildrenGenerated(bool b)
Definition: ValueObject.h:645
lldb_private::ValueObject::SetSyntheticChildren
void SetSyntheticChildren(const lldb::SyntheticChildrenSP &synth_sp)
Definition: ValueObject.h:737
error
static llvm::raw_ostream & error(Stream &strm)
Definition: CommandReturnObject.cpp:17
lldb_private::ValueObject::GetSummaryFormat
lldb::TypeSummaryImplSP GetSummaryFormat()
Definition: ValueObject.h:717
lldb_private::ValueObject::m_address_type_of_ptr_or_ref_children
AddressType m_address_type_of_ptr_or_ref_children
Definition: ValueObject.h:896
lldb_private::ValueObject::GetSymbolContextScope
virtual SymbolContextScope * GetSymbolContextScope()
Definition: ValueObject.cpp:2953
lldb_private::ValueObject::m_deref_valobj
ValueObject * m_deref_valobj
Definition: ValueObject.h:883
lldb_private::ValueObject::eExpressionPathScanEndReasonRangeOperatorExpanded
@ eExpressionPathScanEndReasonRangeOperatorExpanded
[] was expanded into a VOList.
Definition: ValueObject.h:153
lldb_private::ValueObject::eExpressionPathScanEndReasonNoSuchSyntheticChild
@ eExpressionPathScanEndReasonNoSuchSyntheticChild
(Synthetic) child element not found.
Definition: ValueObject.h:129
lldb_private::ValueObject::GetValue
Value & GetValue()
Definition: ValueObject.h:499
lldb_private::ValueObject::MightHaveChildren
virtual bool MightHaveChildren()
Find out if a ValueObject might have children.
Definition: ValueObject.cpp:513
lldb_private::ValueObject::EvaluationPoint::SetInvalid
void SetInvalid()
Definition: ValueObject.h:306
lldb_private::ValueObject::ExpressionPathEndResultType
ExpressionPathEndResultType
Definition: ValueObject.h:159
lldb_private::ValueObject::ValueUpdated
virtual void ValueUpdated()
Definition: ValueObject.h:631
lldb_private::ValueObject::m_last_format_mgr_revision
uint32_t m_last_format_mgr_revision
Definition: ValueObject.h:891
lldb_private::ValueObject::SetValueFormat
void SetValueFormat(lldb::TypeFormatImplSP format)
Definition: ValueObject.h:727
lldb_private::ValueObject::eExpressionPathEndResultTypeUnboundedRange
@ eExpressionPathEndResultTypeUnboundedRange
A range [].
Definition: ValueObject.h:167
lldb_private::DataExtractor
Definition: DataExtractor.h:48
lldb_private::eAddressTypeInvalid
@ eAddressTypeInvalid
Definition: lldb-private-enumerations.h:31
lldb_private::ValueObject::Dereference
virtual lldb::ValueObjectSP Dereference(Status &error)
Definition: ValueObject.cpp:2633
lldb_private::ValueObject::GetStaticValue
virtual lldb::ValueObjectSP GetStaticValue()
Definition: ValueObject.h:590
lldb_private::ValueObject::NeedsUpdating
bool NeedsUpdating()
Definition: ValueObject.h:695
lldb_private::ExecutionContextScope
Definition: ExecutionContextScope.h:32
lldb_private::ValueObject::GetID
lldb::user_id_t GetID() const
Returns a unique id for this ValueObject.
Definition: ValueObject.h:470
lldb_private::ValueObject::IsPossibleDynamicType
virtual bool IsPossibleDynamicType()
Definition: ValueObject.cpp:1569
lldb_private::ValueObject::CalculateNumChildren
virtual size_t CalculateNumChildren(uint32_t max=UINT32_MAX)=0
Should only be called by ValueObject::GetNumChildren().
lldb_private::ValueObject::GetDynamicValueTypeImpl
virtual lldb::DynamicValueType GetDynamicValueTypeImpl()
Definition: ValueObject.h:956
lldb_private::ValueObject::IsBaseClass
virtual bool IsBaseClass()
Definition: ValueObject.h:398
lldb_private::ValueObject::GetChildMemberWithName
virtual lldb::ValueObjectSP GetChildMemberWithName(ConstString name, bool can_create)
Definition: ValueObject.cpp:468
lldb_private::ValueObject::eExpressionPathScanEndReasonArrayRangeOperatorMet
@ eExpressionPathScanEndReasonArrayRangeOperatorMet
[] is good for arrays, but I cannot parse it.
Definition: ValueObject.h:143
lldb_private::ValueObject::GetFormat
lldb::Format GetFormat() const
Definition: ValueObject.cpp:3069
lldb_private::ValueObject::eClearUserVisibleDataItemsAll
@ eClearUserVisibleDataItemsAll
Definition: ValueObject.h:193
lldb_private::ValueObject::ExpressionPathAftermath
ExpressionPathAftermath
Definition: ValueObject.h:173
lldb_private::ValueObject::SetPreferredDisplayLanguageIfNeeded
void SetPreferredDisplayLanguageIfNeeded(lldb::LanguageType)
Definition: ValueObject.cpp:3098
lldb_private::ValueObject::GetSP
lldb::ValueObjectSP GetSP()
Definition: ValueObject.h:555
lldb_private::ValueObject::eExpressionPathScanEndReasonBitfieldRangeOperatorMet
@ eExpressionPathScanEndReasonBitfieldRangeOperatorMet
[] is good for bitfields, but I cannot parse after it.
Definition: ValueObject.h:145
lldb_private::ValueObject::EvaluationPoint::m_mod_id
ProcessModID m_mod_id
Definition: ValueObject.h:318
lldb_private::ValueObject::m_user_id_of_forced_summary
ProcessModID m_user_id_of_forced_summary
Definition: ValueObject.h:895
lldb_private::ValueObject::SetAddressTypeOfChildren
void SetAddressTypeOfChildren(AddressType at)
Definition: ValueObject.h:759
lldb_private::ValueObject::ChildrenManager::GetChildAtIndex
ValueObject * GetChildAtIndex(size_t idx)
Definition: ValueObject.h:805
lldb_private::ValueObject::IsDereferenceOfParent
virtual bool IsDereferenceOfParent()
Definition: ValueObject.h:402
lldb_private::ValueObject::GetNonSyntheticValue
virtual lldb::ValueObjectSP GetNonSyntheticValue()
Definition: ValueObject.h:592
lldb_private::ValueObject::UpdateValue
virtual bool UpdateValue()=0
lldb_private::ValueObject::ResolveValue
virtual bool ResolveValue(Scalar &scalar)
Definition: ValueObject.cpp:332
lldb_private::ValueObject::GetValueForExpressionPathOptions::DefaultOptions
static const GetValueForExpressionPathOptions DefaultOptions()
Definition: ValueObject.h:253
lldb_private::ValueObject::eValueObjectRepresentationStyleChildrenCount
@ eValueObjectRepresentationStyleChildrenCount
Definition: ValueObject.h:117
lldb_private::ValueObject::eExpressionPathScanEndReasonDereferencingFailed
@ eExpressionPathScanEndReasonDereferencingFailed
Impossible to apply * operator.
Definition: ValueObject.h:151
Type.h
lldb_private::ValueObject::CreateValueObjectFromAddress
static lldb::ValueObjectSP CreateValueObjectFromAddress(llvm::StringRef name, uint64_t address, const ExecutionContext &exe_ctx, CompilerType type)
Definition: ValueObject.cpp:2985
lldb_private::ValueObject::m_last_format
lldb::Format m_last_format
Definition: ValueObject.h:890
lldb_private::ValueObject::ReadPointedString
std::pair< size_t, bool > ReadPointedString(lldb::DataBufferSP &buffer_sp, Status &error, uint32_t max_length=0, bool honor_array=true, lldb::Format item_format=lldb::eFormatCharArray)
Definition: ValueObject.cpp:860
lldb_private::ValueObject::CalculateSyntheticValue
virtual void CalculateSyntheticValue()
Definition: ValueObject.cpp:1800
lldb_private::ValueObject::GetTypeImpl
virtual TypeImpl GetTypeImpl()
Definition: ValueObject.h:355
lldb_private::ValueObject::EvaluationPoint::GetModID
ProcessModID GetModID() const
Definition: ValueObject.h:282
lldb_private::ValueObject::Bitflags
Definition: ValueObject.h:909
lldb_private::ValueObject::eExpressionPathScanEndReasonFragileIVarNotAllowed
@ eExpressionPathScanEndReasonFragileIVarNotAllowed
ObjC ivar expansion not allowed.
Definition: ValueObject.h:137
lldb_private::ValueObject::Bitflags::m_is_array_item_for_pointer
bool m_is_array_item_for_pointer
Definition: ValueObject.h:912
lldb_private::ValueObject::ChildrenManager
Definition: ValueObject.h:796
lldb_private::ValueObject::SetLiveAddress
virtual void SetLiveAddress(lldb::addr_t addr=LLDB_INVALID_ADDRESS, AddressType address_type=eAddressTypeLoad)
Definition: ValueObject.h:618
lldb_private::ConstString
Definition: ConstString.h:40
lldb_private::ValueObject::GetValueForExpressionPathOptions::m_allow_bitfields_syntax
bool m_allow_bitfields_syntax
Definition: ValueObject.h:206
lldb_private::ValueObject::GetValueFormat
lldb::TypeFormatImplSP GetValueFormat()
Definition: ValueObject.h:732
lldb_private::ValueObject::GetSyntheticBitFieldChild
lldb::ValueObjectSP GetSyntheticBitFieldChild(uint32_t from, uint32_t to, bool can_create)
Definition: ValueObject.cpp:1645
lldb_private::ValueObject::eExpressionPathScanEndReasonDotInsteadOfArrow
@ eExpressionPathScanEndReasonDotInsteadOfArrow
. used when -> should be used.
Definition: ValueObject.h:133
lldb_private::ValueObject::CalculateDynamicValue
virtual void CalculateDynamicValue(lldb::DynamicValueType use_dynamic)
Definition: ValueObject.cpp:1821
lldb-enumerations.h
lldb_private::ValueObject::UpdateValueIfNeeded
bool UpdateValueIfNeeded(bool update_format=true)
Definition: ValueObject.cpp:111
lldb_private::ValueObject::ChildrenManager::HasChildAtIndex
bool HasChildAtIndex(size_t idx)
Definition: ValueObject.h:800
lldb_private::ValueObject::eValueObjectRepresentationStyleLanguageSpecific
@ eValueObjectRepresentationStyleLanguageSpecific
Definition: ValueObject.h:115
lldb_private::ValueObject::eExpressionPathScanEndReasonTakingAddressFailed
@ eExpressionPathScanEndReasonTakingAddressFailed
Impossible to apply & operator.
Definition: ValueObject.h:149
lldb_private::ValueObject::CastPointerType
virtual lldb::ValueObjectSP CastPointerType(const char *name, CompilerType &ast_type)
Definition: ValueObject.cpp:2773
lldb_private::ExecutionContextRef::GetFrameSP
lldb::StackFrameSP GetFrameSP() const
Get accessor that creates a strong reference from the weak frame reference contained in this object.
Definition: ExecutionContext.cpp:605
lldb_private::ValueObject::GetIndexOfChildWithName
virtual size_t GetIndexOfChildWithName(ConstString name)
Definition: ValueObject.cpp:462
lldb_private::ValueObject::GetValueForExpressionPathOptions::DontAllowFragileIVar
GetValueForExpressionPathOptions & DontAllowFragileIVar()
Definition: ValueObject.h:232
lldb_private::ValueObject::GetSyntheticChildAtOffset
virtual lldb::ValueObjectSP GetSyntheticChildAtOffset(uint32_t offset, const CompilerType &type, bool can_create, ConstString name_const_str=ConstString())
Definition: ValueObject.cpp:1679
lldb_private::ValueObject::ClearUserVisibleDataItems
ClearUserVisibleDataItems
Definition: ValueObject.h:182
lldb_private::ValueObject::GetObjectDescription
const char * GetObjectDescription()
Definition: ValueObject.cpp:999
lldb_private::ValueObject::ChildrenManager::m_mutex
std::recursive_mutex m_mutex
Definition: ValueObject.h:832
lldb_private::ValueObject::CreateConstantValue
virtual lldb::ValueObjectSP CreateConstantValue(ConstString name)
Definition: ValueObject.cpp:2569
lldb_private::ValueObject::SetSummaryFormat
void SetSummaryFormat(lldb::TypeSummaryImplSP format)
Definition: ValueObject.h:722
lldb_private::ValueObject::eExpressionPathScanEndReasonEndOfString
@ eExpressionPathScanEndReasonEndOfString
Out of data to parse.
Definition: ValueObject.h:125
lldb_private::ValueObject::m_synthetic_children_sp
lldb::SyntheticChildrenSP m_synthetic_children_sp
Definition: ValueObject.h:894
lldb_private::ValueObject::Bitflags::m_is_deref_of_parent
bool m_is_deref_of_parent
Definition: ValueObject.h:912
lldb_private::ValueObject::GetParent
virtual ValueObject * GetParent()
Definition: ValueObject.h:753
lldb_private::ValueObject::eExpressionPathScanEndReasonUnknown
@ eExpressionPathScanEndReasonUnknown
Definition: ValueObject.h:156
lldb::DynamicValueType
DynamicValueType
Definition: lldb-enumerations.h:494
lldb_private::ValueObject::m_type_format_sp
lldb::TypeFormatImplSP m_type_format_sp
Definition: ValueObject.h:893
lldb_private::ValueObject::GetParent
virtual const ValueObject * GetParent() const
Definition: ValueObject.h:755
lldb_private::ValueObject::GetExecutionContextRef
const ExecutionContextRef & GetExecutionContextRef() const
Definition: ValueObject.h:330
lldb_private::ValueObject::GetThreadSP
lldb::ThreadSP GetThreadSP() const
Definition: ValueObject.h:342
lldb_private::ValueObject::Cast
virtual lldb::ValueObjectSP Cast(const CompilerType &compiler_type)
Definition: ValueObject.cpp:2765
lldb_private::ValueObject::eExpressionPathScanEndReasonUnexpectedSymbol
@ eExpressionPathScanEndReasonUnexpectedSymbol
Something is malformed in he expression.
Definition: ValueObject.h:147
lldb_private::CompilerType::IsIntegerType
bool IsIntegerType(bool &is_signed) const
Definition: CompilerType.cpp:141
string
string(SUBSTRING ${p} 10 -1 pStripped) if($
Definition: Plugins/CMakeLists.txt:40
lldb_private::eAddressTypeLoad
@ eAddressTypeLoad
Address is an address as in the current target inferior process.
Definition: lldb-private-enumerations.h:34
lldb_private::ValueObject::eExpressionPathEndResultTypeBitfield
@ eExpressionPathEndResultTypeBitfield
A bitfield.
Definition: ValueObject.h:163
lldb_private::ValueObject::m_format
lldb::Format m_format
Definition: ValueObject.h:889
lldb_private::ValueObject::GetSyntheticArrayMember
lldb::ValueObjectSP GetSyntheticArrayMember(size_t index, bool can_create)
Definition: ValueObject.cpp:1618
CompilerType.h
lldb_private::ValueObject::ChildrenManager::SetChildAtIndex
void SetChildAtIndex(size_t idx, ValueObject *valobj)
Definition: ValueObject.h:811
lldb_private::ValueObject::eClearUserVisibleDataItemsNothing
@ eClearUserVisibleDataItemsNothing
Definition: ValueObject.h:183
lldb_private::ValueObject::SetName
void SetName(ConstString name)
Change the name of the current ValueObject.
Definition: ValueObject.h:560
lldb_private::ValueObject::IsLogicalTrue
virtual bool IsLogicalTrue(Status &error)
Definition: ValueObject.cpp:350
UserID.h
lldb_private::SymbolContextScope
Definition: SymbolContextScope.h:64
lldb_private::UserID::GetID
lldb::user_id_t GetID() const
Get accessor for the user ID.
Definition: UserID.h:47
lldb_private::ValueObject::EvaluationPoint::NeedsUpdating
bool NeedsUpdating(bool accept_invalid_exe_ctx)
Definition: ValueObject.h:290
lldb_private::ValueObject::GetValueType
virtual lldb::ValueType GetValueType() const =0
lldb_private::ValueObject::eExpressionPathEndResultTypeValueObjectList
@ eExpressionPathEndResultTypeValueObjectList
Several items in a VOList.
Definition: ValueObject.h:169
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-types.h
lldb_private::ValueObject::m_update_point
EvaluationPoint m_update_point
Stores both the stop id and the full context at which this value was last updated.
Definition: ValueObject.h:847
lldb_private::ValueObject::GetSummaryAsCString
const char * GetSummaryAsCString(lldb::LanguageType lang=lldb::eLanguageTypeUnknown)
Definition: ValueObject.cpp:629
lldb_private::ValueObject::GetBitfieldBitOffset
virtual uint32_t GetBitfieldBitOffset()
Definition: ValueObject.h:426
lldb_private::ValueObject::GetNonBaseClassParent
ValueObject * GetNonBaseClassParent()
Definition: ValueObject.cpp:1868
lldb_private::CompilerType::IsScalarType
bool IsScalarType() const
Definition: CompilerType.cpp:223
lldb_private::ValueObject::GetNumChildren
size_t GetNumChildren(uint32_t max=UINT32_MAX)
Definition: ValueObject.cpp:496
lldb_private::ValueObject::eValueObjectRepresentationStyleExpressionPath
@ eValueObjectRepresentationStyleExpressionPath
Definition: ValueObject.h:120
lldb_private::ValueObject::Bitflags::m_value_is_valid
bool m_value_is_valid
Definition: ValueObject.h:910
lldb_private::ValueObject::GetValueAsCString
virtual const char * GetValueAsCString()
Definition: ValueObject.cpp:1049
lldb_private::ValueObject::Bitflags::m_is_bitfield_for_scalar
bool m_is_bitfield_for_scalar
Definition: ValueObject.h:913
lldb_private::ExpressionVariable
Definition: ExpressionVariable.h:23
lldb_private::ValueObject::GetIsConstant
virtual bool GetIsConstant() const
Definition: ValueObject.h:693
lldb_private::ValueObject::eExpressionPathScanEndReasonArrowInsteadOfDot
@ eExpressionPathScanEndReasonArrowInsteadOfDot
-> used when . should be used.
Definition: ValueObject.h:135
lldb_private::ValueObject::HasDynamicValueTypeInfo
virtual bool HasDynamicValueTypeInfo()
Definition: ValueObject.h:960
lldb_private::ValueObject::m_language_flags
uint64_t m_language_flags
Definition: ValueObject.h:902
lldb_private::Status
Definition: Status.h:44
lldb_private::ValueObject
ValueObject:
Definition: ValueObject.h:105
lldb_private::ValueObject::IsCStringContainer
bool IsCStringContainer(bool check_pointer=false)
Returns true if this is a char* or a char[] if it is a char* and check_pointer is true,...
Definition: ValueObject.cpp:646
lldb_private::ValueObject::eGetExpressionPathFormatHonorPointers
@ eGetExpressionPathFormatHonorPointers
Definition: ValueObject.h:109
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
uint32_t
lldb_private::ValueObject::GetSyntheticChildren
lldb::SyntheticChildrenSP GetSyntheticChildren()
Definition: ValueObject.h:744
lldb_private::ValueObject::Bitflags::m_value_did_change
bool m_value_did_change
Definition: ValueObject.h:910
lldb_private::ValueObject::Clone
virtual lldb::ValueObjectSP Clone(ConstString new_name)
Creates a copy of the ValueObject with a new name and setting the current ValueObject as its parent.
Definition: ValueObject.cpp:2769
lldb_private::ValueObject::CreateChildAtIndex
virtual ValueObject * CreateChildAtIndex(size_t idx, bool synthetic_array_member, int32_t synthetic_index)
Should only be called by ValueObject::GetChildAtIndex().
Definition: ValueObject.cpp:531
lldb_private::ValueObject::EvaluationPoint::SyncWithProcessState
bool SyncWithProcessState(bool accept_invalid_exe_ctx)
Definition: ValueObject.cpp:2855
lldb_private::ValueObject::GetUpdatePoint
EvaluationPoint & GetUpdatePoint()
Definition: ValueObject.h:328
lldb_private::ValueObject::EvaluationPoint::~EvaluationPoint
~EvaluationPoint()
lldb_private::ValueObject::EvaluationPoint::IsValid
bool IsValid()
Definition: ValueObject.h:295
lldb_private::ValueObject::m_value
Value m_value
Definition: ValueObject.h:852
lldb_private::CompilerType::IsPointerType
bool IsPointerType(CompilerType *pointee_type=nullptr) const
Definition: CompilerType.cpp:157
lldb_private::ValueObjectConstResultImpl
A class wrapping common implementation details for operations in ValueObjectConstResult ( & Child ) t...
Definition: ValueObjectConstResultImpl.h:32
lldb_private::ValueObject::m_id
UserID m_id
Unique identifier for every value object.
Definition: ValueObject.h:905
lldb_private::ProcessModID
Definition: Process.h:222
lldb_private::ValueObject::m_parent
ValueObject * m_parent
The parent value object, or nullptr if this has no parent.
Definition: ValueObject.h:840
lldb_private::ValueObject::GetCompilerTypeImpl
virtual CompilerType GetCompilerTypeImpl()=0
lldb_private::ValueObject::eExpressionPathScanEndReasonSyntheticValueMissing
@ eExpressionPathScanEndReasonSyntheticValueMissing
getting the synthetic children failed.
Definition: ValueObject.h:155
lldb_private::ValueObject::PrintableRepresentationSpecialCases::eDisable
@ eDisable
lldb_private::CompilerType::GetTypeName
ConstString GetTypeName() const
Definition: CompilerType.cpp:277
lldb_private::ValueObject::DoesProvideSyntheticValue
virtual bool DoesProvideSyntheticValue()
Definition: ValueObject.h:639
lldb_private::CompilerType::GetTypeInfo
uint32_t GetTypeInfo(CompilerType *pointee_or_element_compiler_type=nullptr) const
Definition: CompilerType.cpp:290
lldb_private::ValueObject::GetValueForExpressionPathOptions::m_synthetic_children_traversal
SyntheticChildrenTraversal m_synthetic_children_traversal
Definition: ValueObject.h:207
lldb_private::ValueObject::GetDeclaration
virtual bool GetDeclaration(Declaration &decl)
Definition: ValueObject.cpp:1550
lldb_private::ValueObject::eExpressionPathEndResultTypePlain
@ eExpressionPathEndResultTypePlain
Anything but...
Definition: ValueObject.h:161
lldb_private::ValueObject::eGetExpressionPathFormatDereferencePointers
@ eGetExpressionPathFormatDereferencePointers
Definition: ValueObject.h:108
lldb_private::CompilerType::IsArrayType
bool IsArrayType(CompilerType *element_type=nullptr, uint64_t *size=nullptr, bool *is_incomplete=nullptr) const
Definition: CompilerType.cpp:49
lldb_private::ValueObject::EvaluationPoint
Definition: ValueObject.h:260
UINT32_MAX
#define UINT32_MAX
Definition: lldb-defines.h:31
lldb_private::ValueObject::GetValueForExpressionPathOptions::DoAllowBitfieldSyntax
GetValueForExpressionPathOptions & DoAllowBitfieldSyntax()
Definition: ValueObject.h:237
lldb_private::ValueObject::GetCompilerType
CompilerType GetCompilerType()
Definition: ValueObject.h:352
lldb_private::ValueObject::UpdateFormatsIfNeeded
bool UpdateFormatsIfNeeded()
Definition: ValueObject.cpp:202
lldb_private::ValueObject::m_root
ValueObject * m_root
The root of the hierarchy for this ValueObject (or nullptr if never calculated).
Definition: ValueObject.h:843
lldb_private::ValueObject::Bitflags::m_children_count_valid
bool m_children_count_valid
Definition: ValueObject.h:911
lldb_private::TypeSummaryOptions
Definition: TypeSummary.h:26
lldb_private::ValueObject::GetDynamicValueType
lldb::DynamicValueType GetDynamicValueType()
Definition: ValueObject.cpp:3059
lldb_private::ValueObject::Bitflags::m_is_child_at_offset
bool m_is_child_at_offset
Definition: ValueObject.h:913
lldb::eFormatCharArray
@ eFormatCharArray
Print characters with no single quotes, used for character arrays that can contain non printable char...
Definition: lldb-enumerations.h:193
lldb_private::ValueObject::eValueObjectRepresentationStyleType
@ eValueObjectRepresentationStyleType
Definition: ValueObject.h:118
lldb_private::ValueObject::GetSyntheticChild
lldb::ValueObjectSP GetSyntheticChild(ConstString key) const
Definition: ValueObject.cpp:1560
lldb_private::ValueObject::ChildrenManager::ChildrenMap
std::map< size_t, ValueObject * > ChildrenMap
Definition: ValueObject.h:829
lldb_private::ValueObject::GetSyntheticBase
virtual lldb::ValueObjectSP GetSyntheticBase(uint32_t offset, const CompilerType &type, bool can_create, ConstString name_const_str=ConstString())
Definition: ValueObject.cpp:1716
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::ValueObject::GetTypeInfo
virtual uint32_t GetTypeInfo(CompilerType *pointee_or_element_compiler_type=nullptr)
Definition: ValueObject.h:378
LLDB_INVALID_ADDRESS
#define LLDB_INVALID_ADDRESS
Definition: lldb-defines.h:86
lldb_private::ValueObject::ValueObjectManager
ClusterManager< ValueObject > ValueObjectManager
Definition: ValueObject.h:794
lldb_private::ValueObject::GetValueIsValid
bool GetValueIsValid() const
Definition: ValueObject.h:545
DataExtractor.h
lldb_private::CompilerType
Generic representation of a type in a programming language.
Definition: CompilerType.h:33
lldb_private::ValueObject::GetLocationAsCString
virtual const char * GetLocationAsCString()
Definition: ValueObject.h:508
lldb_private::ValueObject::m_value_str
std::string m_value_str
Cached value string that will get cleared if/when the value is updated.
Definition: ValueObject.h:857
lldb-forward.h
lldb_private::ValueObject::GetVariable
virtual lldb::VariableSP GetVariable()
Definition: ValueObject.h:785
lldb_private::ValueObject::SetHasCompleteType
void SetHasCompleteType()
Definition: ValueObject.h:765
lldb_private::ValueObject::HasSpecialPrintableRepresentation
bool HasSpecialPrintableRepresentation(ValueObjectRepresentationStyle val_obj_display, lldb::Format custom_format)
Definition: ValueObject.cpp:1130
lldb_private::ValueObject::ExpressionPathScanEndReason
ExpressionPathScanEndReason
Definition: ValueObject.h:123
lldb_private::ValueObject::DoUpdateChildrenAddressType
virtual void DoUpdateChildrenAddressType(ValueObject &valobj)
Definition: ValueObject.h:1003
lldb_private::ValueObject::IsScalarType
virtual bool IsScalarType()
Definition: ValueObject.h:386
lldb_private::DumpValueObjectOptions
Definition: DumpValueObjectOptions.h:22
lldb_private::ValueObject::EvaluationPoint::m_exe_ctx_ref
ExecutionContextRef m_exe_ctx_ref
Definition: ValueObject.h:320
Status.h
lldb::user_id_t
uint64_t user_id_t
Definition: lldb-types.h:84
lldb_private::ValueObject::EvaluationPoint::SetNeedsUpdate
void SetNeedsUpdate()
Definition: ValueObject.h:286
lldb_private::ValueObject::SetData
virtual bool SetData(DataExtractor &data, Status &error)
Definition: ValueObject.cpp:783
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::AddSyntheticChild
void AddSyntheticChild(ConstString key, ValueObject *valobj)
Definition: ValueObject.cpp:1555
lldb_private::ValueObject::m_flags
struct lldb_private::ValueObject::Bitflags m_flags
lldb_private::TypeImpl
Definition: Type.h:238
lldb_private::eLazyBoolCalculate
@ eLazyBoolCalculate
Definition: lldb-private-enumerations.h:115
lldb_private::ValueObject::GetAddressOf
virtual lldb::addr_t GetAddressOf(bool scalar_is_load_address=true, AddressType *address_type=nullptr)
Definition: ValueObject.cpp:1399
SharedCluster.h
lldb_private::ExecutionContextRef::GetTargetSP
lldb::TargetSP GetTargetSP() const
Get accessor that creates a strong reference from the weak target reference contained in this object.
Definition: ExecutionContext.cpp:566
lldb_private::ValueObject::EvaluationPoint::GetExecutionContextRef
const ExecutionContextRef & GetExecutionContextRef() const
Definition: ValueObject.h:271
lldb_private::ValueObject::GetChildAtNamePath
lldb::ValueObjectSP GetChildAtNamePath(llvm::ArrayRef< ConstString > names, ConstString *name_of_error=nullptr)
Definition: ValueObject.cpp:429
lldb_private::ValueObject::SetNumChildren
void SetNumChildren(size_t num_children)
Definition: ValueObject.cpp:526
lldb_private::CompilerType::GetMinimumLanguage
lldb::LanguageType GetMinimumLanguage()
Definition: CompilerType.cpp:298
lldb_private::ValueObject::PrintableRepresentationSpecialCases::eAllow
@ eAllow
lldb_private::ValueObjectSynthetic
A ValueObject that obtains its children from some source other than real information.
Definition: ValueObjectSyntheticFilter.h:35
lldb_private::ValueObject::Bitflags::m_did_calculate_complete_objc_class_type
bool m_did_calculate_complete_objc_class_type
Definition: ValueObject.h:914
lldb_private::ValueObject::eExpressionPathEndResultTypeInvalid
@ eExpressionPathEndResultTypeInvalid
Definition: ValueObject.h:170
lldb_private::ValueObject::Bitflags::m_old_value_valid
bool m_old_value_valid
Definition: ValueObject.h:911
lldb_private::ValueObject::GetValueForExpressionPathOptions::SyntheticChildrenTraversal::ToSynthetic
@ ToSynthetic
ConstString.h
lldb_private::ValueObject::GetTargetSP
lldb::TargetSP GetTargetSP() const
Definition: ValueObject.h:334
lldb_private::ValueObject::ValueObjectRepresentationStyle
ValueObjectRepresentationStyle
Definition: ValueObject.h:112
lldb_private::ValueObject::CanUpdateWithInvalidExecutionContext
virtual LazyBool CanUpdateWithInvalidExecutionContext()
Definition: ValueObject.h:950
lldb_private::ValueObject::CreateValueObjectFromData
static lldb::ValueObjectSP CreateValueObjectFromData(llvm::StringRef name, const DataExtractor &data, const ExecutionContext &exe_ctx, CompilerType type)
Definition: ValueObject.cpp:3011
lldb_private::ValueObject::m_dynamic_value
ValueObject * m_dynamic_value
Definition: ValueObject.h:881
lldb_private::ValueObject::ChildrenManager::ChildrenPair
ChildrenMap::value_type ChildrenPair
Definition: ValueObject.h:831
lldb_private::ValueObject::EvaluationPoint::EvaluationPoint
EvaluationPoint()
Definition: ValueObject.cpp:2802
lldb_private::ValueObject::DumpPrintableRepresentation
bool DumpPrintableRepresentation(Stream &s, ValueObjectRepresentationStyle val_obj_display=eValueObjectRepresentationStyleSummary, lldb::Format custom_format=lldb::eFormatInvalid, PrintableRepresentationSpecialCases special=PrintableRepresentationSpecialCases::eAllow, bool do_dump_error=true)
Definition: ValueObject.cpp:1163
lldb_private::ValueObject::ClearDynamicTypeInformation
void ClearDynamicTypeInformation()
Definition: ValueObject.cpp:236
lldb_private::ValueObject::Bitflags::m_is_synthetic_children_generated
bool m_is_synthetic_children_generated
Definition: ValueObject.h:915
lldb_private::ValueObject::ChildrenManager::GetChildrenCount
size_t GetChildrenCount()
Definition: ValueObject.h:820
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::ValueObject::AddressOf
virtual lldb::ValueObjectSP AddressOf(Status &error)
Definition: ValueObject.cpp:2722
lldb_private::ValueObject::EvaluationPoint::m_needs_update
bool m_needs_update
Definition: ValueObject.h:321
lldb_private::ValueObject::HasSyntheticValue
virtual bool HasSyntheticValue()
Definition: ValueObject.cpp:1857
lldb_private::ExecutionContextRef::GetProcessSP
lldb::ProcessSP GetProcessSP() const
Get accessor that creates a strong reference from the weak process reference contained in this object...
Definition: ExecutionContext.cpp:573
lldb_private::ValueObject::Dump
void Dump(Stream &s)
Definition: ValueObject.cpp:2562
lldb_private::ValueObject::GetLocationAsCStringImpl
const char * GetLocationAsCStringImpl(const Value &value, const DataExtractor &data)
Definition: ValueObject.cpp:288
lldb_private::ValueObject::eExpressionPathEndResultTypeBoundedRange
@ eExpressionPathEndResultTypeBoundedRange
A range [low-high].
Definition: ValueObject.h:165
lldb_private::ValueObjectChild
A child of another ValueObject.
Definition: ValueObjectChild.h:29
lldb_private::ValueObject::IsChecksumEmpty
bool IsChecksumEmpty()
Definition: ValueObject.h:998
lldb_private::ValueObject::eClearUserVisibleDataItemsSyntheticChildren
@ eClearUserVisibleDataItemsSyntheticChildren
Definition: ValueObject.h:188
lldb_private::Declaration
Definition: Declaration.h:24
lldb_private::ValueObject::eValueObjectRepresentationStyleSummary
@ eValueObjectRepresentationStyleSummary
Definition: ValueObject.h:114
lldb_private::ValueObject::IsIntegerType
bool IsIntegerType(bool &is_signed)
Definition: ValueObject.h:404
lldb_private::ValueObject::ChildrenManager::Clear
void Clear(size_t new_count=0)
Definition: ValueObject.h:822
lldb_private::ValueObject::eExpressionPathScanEndReasonRangeOperatorNotAllowed
@ eExpressionPathScanEndReasonRangeOperatorNotAllowed
[] not allowed by options.
Definition: ValueObject.h:139
lldb_private::ValueObject::GetLanguageFlags
virtual uint64_t GetLanguageFlags()
Definition: ValueObject.h:789
lldb_private::ValueObject::eExpressionPathScanEndReasonEmptyRangeNotAllowed
@ eExpressionPathScanEndReasonEmptyRangeNotAllowed
[] only allowed for arrays.
Definition: ValueObject.h:131
lldb_private::ValueObject::GetSyntheticValue
lldb::ValueObjectSP GetSyntheticValue()
Definition: ValueObject.cpp:1848
lldb_private::ValueObject::GetFrameSP
lldb::StackFrameSP GetFrameSP() const
Definition: ValueObject.h:346
Value.h
lldb_private::ValueObject::GetValueForExpressionPathOptions::DoAllowFragileIVar
GetValueForExpressionPathOptions & DoAllowFragileIVar()
Definition: ValueObject.h:227
lldb_private::ExecutionContextRef
Execution context objects refer to objects in the execution of the program that is being debugged.
Definition: ExecutionContext.h:72
lldb_private::ValueObject::m_type_summary_sp
lldb::TypeSummaryImplSP m_type_summary_sp
Definition: ValueObject.h:892
lldb_private::ValueObject::GetSyntheticExpressionPathChild
lldb::ValueObjectSP GetSyntheticExpressionPathChild(const char *expression, bool can_create)
Definition: ValueObject.cpp:1772
lldb_private::ValueObject::m_addr_of_valobj_sp
lldb::ValueObjectSP m_addr_of_valobj_sp
We have to hold onto a shared pointer to this one because it is created as an independent ValueObject...
Definition: ValueObject.h:887
lldb::eFormatDefault
@ eFormatDefault
Definition: lldb-enumerations.h:156
ExecutionContext.h
lldb_private::ValueObject::IsArrayItemForPointer
virtual bool IsArrayItemForPointer()
Definition: ValueObject.h:432
lldb_private::ValueObject::GetAddressTypeOfChildren
AddressType GetAddressTypeOfChildren()
Definition: ValueObject.cpp:3050
lldb_private::ValueObject::GetObjectRuntimeLanguage
virtual lldb::LanguageType GetObjectRuntimeLanguage()
Definition: ValueObject.h:373
lldb::eFormatInvalid
@ eFormatInvalid
Definition: lldb-enumerations.h:157
lldb_private::ValueObject::GetByteSize
virtual llvm::Optional< uint64_t > GetByteSize()=0
lldb_private::ValueObject::ChildrenManager::SetChildrenCount
void SetChildrenCount(size_t count)
Definition: ValueObject.h:818
lldb_private::ValueObject::GetValueForExpressionPathOptions::DontCheckDotVsArrowSyntax
GetValueForExpressionPathOptions & DontCheckDotVsArrowSyntax()
Definition: ValueObject.h:222
lldb_private::ValueObject::SetNeedsUpdate
void SetNeedsUpdate()
Definition: ValueObject.cpp:229
lldb_private::ValueObject::GetValueForExpressionPath_Impl
lldb::ValueObjectSP GetValueForExpressionPath_Impl(llvm::StringRef expression_cstr, ExpressionPathScanEndReason *reason_to_stop, ExpressionPathEndResultType *final_value_type, const GetValueForExpressionPathOptions &options, ExpressionPathAftermath *final_task_on_target)
Definition: ValueObject.cpp:2056