@@ -155,58 +155,6 @@ ValueObject::ValueObject(ExecutionContextScope *exe_scope,
155
155
// Destructor
156
156
ValueObject::~ValueObject () {}
157
157
158
- void ValueObject::UpdateChildrenAddressType () {
159
- Value::ValueType value_type = m_value.GetValueType ();
160
- ExecutionContext exe_ctx (GetExecutionContextRef ());
161
- Process *process = exe_ctx.GetProcessPtr ();
162
- const bool process_is_alive = process && process->IsAlive ();
163
- const uint32_t type_info = GetCompilerType ().GetTypeInfo ();
164
- const bool is_pointer_or_ref =
165
- (type_info & (lldb::eTypeIsPointer | lldb::eTypeIsReference)) != 0 ;
166
-
167
- switch (value_type) {
168
- case Value::eValueTypeFileAddress:
169
- // If this type is a pointer, then its children will be considered load
170
- // addresses if the pointer or reference is dereferenced, but only if
171
- // the process is alive.
172
- //
173
- // There could be global variables like in the following code:
174
- // struct LinkedListNode { Foo* foo; LinkedListNode* next; };
175
- // Foo g_foo1;
176
- // Foo g_foo2;
177
- // LinkedListNode g_second_node = { &g_foo2, NULL };
178
- // LinkedListNode g_first_node = { &g_foo1, &g_second_node };
179
- //
180
- // When we aren't running, we should be able to look at these variables
181
- // using the "target variable" command. Children of the "g_first_node"
182
- // always will be of the same address type as the parent. But children
183
- // of the "next" member of LinkedListNode will become load addresses if
184
- // we have a live process, or remain a file address if it was a file
185
- // address.
186
- if (process_is_alive && is_pointer_or_ref)
187
- SetAddressTypeOfChildren (eAddressTypeLoad);
188
- else
189
- SetAddressTypeOfChildren (eAddressTypeFile);
190
- break ;
191
- case Value::eValueTypeHostAddress:
192
- // Same as above for load addresses, except children of pointer or refs
193
- // are always load addresses. Host addresses are used to store freeze
194
- // dried variables. If this type is a struct, the entire struct
195
- // contents will be copied into the heap of the
196
- // LLDB process, but we do not currently follow any pointers.
197
- if (is_pointer_or_ref)
198
- SetAddressTypeOfChildren (eAddressTypeLoad);
199
- else
200
- SetAddressTypeOfChildren (eAddressTypeHost);
201
- break ;
202
- case Value::eValueTypeLoadAddress:
203
- case Value::eValueTypeScalar:
204
- case Value::eValueTypeVector:
205
- SetAddressTypeOfChildren (eAddressTypeLoad);
206
- break ;
207
- }
208
- }
209
-
210
158
bool ValueObject::UpdateValueIfNeeded (bool update_format) {
211
159
212
160
bool did_change_formats = false ;
@@ -280,7 +228,6 @@ bool ValueObject::UpdateValueIfNeeded(bool update_format) {
280
228
SetValueIsValid (success);
281
229
282
230
if (success) {
283
- UpdateChildrenAddressType ();
284
231
const uint64_t max_checksum_size = 128 ;
285
232
m_data.Checksum (m_value_checksum, max_checksum_size);
286
233
} else {
0 commit comments