File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -111,6 +111,22 @@ void gdb_value_extractort::analyze_symbols(const std::vector<irep_idt> &symbols)
111
111
CHECK_RETURN (value.pointee .empty () || (id == value.pointee ));
112
112
113
113
values.insert ({value.address , symbol_expr});
114
+
115
+ const symbolt &symbol = ns.lookup (id);
116
+ const symbol_exprt actual_expr = symbol.symbol_expr ();
117
+ if (actual_expr.type ().id () != ID_pointer)
118
+ {
119
+ memory_map[id2string (id)] = value;
120
+ continue ;
121
+ }
122
+
123
+ const std::string c_symbol = c_converter.convert (actual_expr);
124
+ const pointer_valuet &symbol_value = gdb_api.get_memory (c_symbol);
125
+ size_t symbol_size = gdb_api.query_malloc_size (c_symbol);
126
+
127
+ if (symbol_size > 1 )
128
+ dynamically_allocated.emplace_back (symbol_value.address , symbol_size, id);
129
+ memory_map[id2string (id)] = symbol_value;
114
130
}
115
131
116
132
for (const auto &id : symbols)
You can’t perform that action at this time.
0 commit comments