31 uint32_t addr_byte_size,
37 addr_byte_size, address))
44 uint32_t addr_byte_size,
49 m_data.SetByteOrder(byte_order);
50 m_data.SetAddressByteSize(addr_byte_size);
60 std::shared_ptr<ValueObjectManager> manager_sp =
74 if (!
m_data.GetSharedDataBuffer()) {
75 DataBufferSP shared_data_buffer(
76 new DataBufferHeap(data.GetDataStart(), data.GetByteSize()));
77 m_data.SetData(shared_data_buffer);
82 m_value.SetCompilerType(compiler_type);
94 std::shared_ptr<ValueObjectManager> manager_sp =
97 data_sp, data_byte_order, data_addr_size,
106 std::shared_ptr<ValueObjectManager> manager_sp =
117 std::shared_ptr<ValueObjectManager> manager_sp =
130 m_data.SetByteOrder(data_byte_order);
131 m_data.SetAddressByteSize(data_addr_size);
133 m_value.GetScalar() = (uintptr_t)data_sp->GetBytes();
135 m_value.SetCompilerType(compiler_type);
146 std::shared_ptr<ValueObjectManager> manager_sp =
149 address, address_type, addr_byte_size))
159 m_data.SetAddressByteSize(addr_byte_size);
162 switch (address_type) {
176 m_value.SetCompilerType(compiler_type);
187 std::shared_ptr<ValueObjectManager> manager_sp =
219 m_value.SetCompilerType(compiler_type);
233 return m_value.GetCompilerType();
251 return llvm::createStringError(
"unknown size of const result");
256llvm::Expected<uint32_t>
261 return children_count;
262 return *children_count <= max ? *children_count : max;
292 uint32_t offset,
const CompilerType &type,
bool can_create,
294 return m_impl.GetSyntheticChildAtOffset(offset, type, can_create,
304 return m_impl.GetAddressOf(scalar_is_load_address);
309 uint32_t item_count) {
310 return m_impl.GetPointeeData(data, item_idx, item_count);
332 return m_impl.Cast(compiler_type);
static llvm::raw_ostream & error(Stream &strm)
Generic representation of a type in a programming language.
lldb::LanguageType GetMinimumLanguage()
ConstString GetDisplayTypeName() const
llvm::Expected< uint64_t > GetByteSize(ExecutionContextScope *exe_scope) const
Return the size of the type in bytes.
ConstString GetTypeName(bool BaseOnly=false) const
llvm::Expected< uint32_t > GetNumChildren(bool omit_empty_base_classes, const ExecutionContext *exe_ctx) const
A uniqued constant string class.
"lldb/Target/ExecutionContextScope.h" Inherit from this if your object can reconstruct its execution ...
virtual void CalculateExecutionContext(ExecutionContext &exe_ctx)=0
Reconstruct the object's execution context into sc.
"lldb/Target/ExecutionContext.h" A class that contains an execution context.
ExecutionContextScope * GetBestExecutionContextScope() const
Process * GetProcessPtr() const
Returns a pointer to the process object.
A class that describes an executable image and its associated object and symbol files.
A plug-in interface definition class for debugging a process.
bool IsPossibleDynamicValue(ValueObject &in_value)
lldb::ValueObjectSP AddressOf(Status &error) override
ValueObjectConstResultImpl m_impl
bool IsInScope() override
lldb::ValueObjectSP Dereference(Status &error) override
AddrAndType GetAddressOf(bool scalar_is_load_address=true) override
void SetByteSize(size_t size)
bool UpdateValue() override
CompilerType GetCompilerTypeImpl() override
ConstString GetTypeName() override
lldb::ValueObjectSP DoCast(const CompilerType &compiler_type) override
std::optional< uint64_t > m_byte_size
lldb::ValueObjectSP GetSyntheticChildAtOffset(uint32_t offset, const CompilerType &type, bool can_create, ConstString name_const_str=ConstString()) override
lldb::ValueObjectSP GetDynamicValue(lldb::DynamicValueType valueType) override
~ValueObjectConstResult() override
llvm::Expected< uint32_t > CalculateNumChildren(uint32_t max) override
Should only be called by ValueObject::GetNumChildren().
lldb::ValueType GetValueType() const override
llvm::Expected< uint64_t > GetByteSize() override
ConstString GetDisplayTypeName() override
size_t GetPointeeData(DataExtractor &data, uint32_t item_idx=0, uint32_t item_count=1) override
ValueObjectConstResult(ExecutionContextScope *exe_scope, ValueObjectManager &manager, lldb::ByteOrder byte_order, uint32_t addr_byte_size, lldb::addr_t address)
lldb::LanguageType GetPreferredDisplayLanguage() override
static lldb::ValueObjectSP Create(ExecutionContextScope *exe_scope, lldb::ByteOrder byte_order, uint32_t addr_byte_size, lldb::addr_t address=LLDB_INVALID_ADDRESS, ValueObjectManager *manager=nullptr)
These routines create ValueObjectConstResult ValueObjects from various data sources.
A ValueObject that represents memory at a given address, viewed as some set lldb type.
void SetValueIsValid(bool valid)
virtual uint64_t GetData(DataExtractor &data, Status &error)
ClusterManager< ValueObject > ValueObjectManager
ValueObject(ExecutionContextScope *exe_scope, ValueObjectManager &manager, AddressType child_ptr_or_ref_addr_type=eAddressTypeLoad)
Use this constructor to create a "root variable object".
Status m_error
An error object that can describe any errors that occur when updating values.
DataExtractor m_data
A data extractor that can be used to extract the value.
lldb::LanguageType m_preferred_display_language
static ValueObjectManagerSP CreateManagerIfEmpty(ValueObjectManager *&manager)
If manager is null, makes a new ValueObjectManager and sets manager to the new ValueObjectManager.
CompilerType GetCompilerType()
std::shared_ptr< ValueObjectManager > ValueObjectManagerSP
ConstString m_name
The name of this object.
ValueObject * m_dynamic_value
const ExecutionContextRef & GetExecutionContextRef() const
void SetAddressTypeOfChildren(AddressType at)
@ HostAddress
A host address value (for memory in the process that < A is using liblldb).
@ FileAddress
A file address value.
@ LoadAddress
A load address value.
@ Scalar
A raw scalar value.
A class that represents a running process on the host machine.
@ eAddressTypeFile
Address is an address as found in an object or symbol file.
@ eAddressTypeLoad
Address is an address as in the current target inferior process.
@ eAddressTypeHost
Address is an address in the process that is running this code.
std::shared_ptr< lldb_private::ValueObject > ValueObjectSP
LanguageType
Programming language type.
@ eLanguageTypeUnknown
Unknown or invalid language value.
ByteOrder
Byte ordering definitions.
@ eValueTypeConstResult
constant result variables
std::shared_ptr< lldb_private::DataBuffer > DataBufferSP