28 ValueObjectSP ptr_sp = obj->GetChildMemberWithName(
"__size_");
31 const size_t size = ptr_sp->GetValueAsUnsigned(0);
33 ptr_sp = obj->GetChildMemberWithName(
"__stride_");
36 const size_t stride = ptr_sp->GetValueAsUnsigned(0);
38 stream.
Printf(
"stride=%zu size=%zu", stride, size);
110 uint64_t offset = idx * m_stride * m_element_size;
111 offset = offset + m_start->GetValueAsUnsigned(0);
113 name.
Printf(
"[%" PRIu64
"]", (uint64_t)idx);
114 return CreateValueObjectFromAddress(name.
GetString(), offset,
115 m_backend.GetExecutionContextRef(),
125 return ChildCacheState::eRefetch;
128 if (std::optional<uint64_t> size = m_element_type.GetByteSize(
nullptr))
129 m_element_size = *size;
131 if (m_element_size == 0)
132 return ChildCacheState::eRefetch;
134 ValueObjectSP start = m_backend.GetChildMemberWithName(
"__vp_");
135 ValueObjectSP size = m_backend.GetChildMemberWithName(
"__size_");
136 ValueObjectSP stride = m_backend.GetChildMemberWithName(
"__stride_");
138 if (!start || !size || !stride)
139 return ChildCacheState::eRefetch;
141 m_start = start.get();
142 m_size = size->GetValueAsUnsigned(0);
143 m_stride = stride->GetValueAsUnsigned(0);
145 return ChildCacheState::eRefetch;
156 return std::numeric_limits<size_t>::max();
Generic representation of a type in a programming language.
CompilerType GetTypeTemplateArgument(size_t idx, bool expand_pack=false) const
size_t GetNumTemplateArguments(bool expand_pack=false) const
Return the number of template arguments the type has.
A uniqued constant string class.
const char * GetCString() const
Get the string value as a C string.
llvm::StringRef GetString() const
A stream class that can stream formatted output to a file.
size_t Printf(const char *format,...) __attribute__((format(printf
Output printf formatted output to the stream.
virtual lldb::ValueObjectSP GetNonSyntheticValue()
A class that represents a running process on the host machine.
ChildCacheState
Specifies if children need to be re-computed after a call to SyntheticChildrenFrontEnd::Update.
std::shared_ptr< lldb_private::ValueObject > ValueObjectSP