@@ -90,7 +90,7 @@ def create_map_debug_info(module, map_global, map_name, map_params):
90
90
# Create array type for map type field (array of 1 unsigned int)
91
91
array_subrange = module .add_debug_info ("DISubrange" , {"count" : 1 })
92
92
array_type = module .add_debug_info ("DICompositeType" , {
93
- "tag" : 17 , # "DW_TAG_array_type"
93
+ "tag" : 1 , # "DW_TAG_array_type"
94
94
"baseType" : uint_type ,
95
95
"size" : 32 ,
96
96
"elements" : [array_subrange ]
@@ -122,6 +122,7 @@ def create_map_debug_info(module, map_global, map_name, map_params):
122
122
})
123
123
124
124
# Create struct members
125
+ # scope field does not appear for some reason
125
126
type_member = module .add_debug_info ("DIDerivedType" , {
126
127
"tag" : 13 , # "DW_TAG_member"
127
128
"name" : "type" ,
@@ -161,12 +162,10 @@ def create_map_debug_info(module, map_global, map_name, map_params):
161
162
# Create the struct type
162
163
struct_type = module .add_debug_info ("DICompositeType" , {
163
164
"tag" : 19 , # DW_TAG_structure_type
164
- "name" : "anon" , # Anonymous struct
165
165
"file" : file_metadata ,
166
166
"size" : 256 , # 4 * 64-bit pointers
167
- "align" : 64 ,
168
167
"elements" : [type_member , max_entries_member , key_member , value_member ]
169
- })
168
+ }, is_distinct = True )
170
169
171
170
# Create global variable debug info
172
171
global_var = module .add_debug_info ("DIGlobalVariable" , {
@@ -176,7 +175,7 @@ def create_map_debug_info(module, map_global, map_name, map_params):
176
175
"type" : struct_type ,
177
176
"isLocal" : False ,
178
177
"isDefinition" : True
179
- })
178
+ }, is_distinct = True )
180
179
181
180
# Create global variable expression
182
181
global_var_expr = module .add_debug_info ("DIGlobalVariableExpression" , {
0 commit comments