delete called[array_idx]
return to_return
}
+function update_upper_bound(idx, val, count)
+{
+ count = array[idx]["count"]
+ if (count == "")
+ count = 1
+ array[idx]["count"] = count * val
+ array[idx]["upper_bound"] = array[idx]["upper_bound"] "[" val "]"
+}
function what_is(what_idx, type_idx, special, item, \
location, prev_location, prev_returned_size)
{
what_is(type_idx)
to_return = array[what_idx]["upper_bound"]
if ("" == to_return)
- to_return = 0
- returned_size = to_return * returned_size
- return leave(what_idx, "[" to_return "]")
+ to_return = "[0]"
+ returned_size = array[what_idx]["count"] * returned_size
+ return leave(what_idx, to_return)
break
case "structure_type":
print "struct {"
}
/^DW_AT_upper_bound/ {
match($0, /[[:digit:]]+/, temparray)
- array[parent[level-1]]["upper_bound"] = temparray[0] + 1
+ update_upper_bound(parent[level - 1], temparray[0] + 1)
}
/^DW_AT_count/ {
match($0, /[[:digit:]]+/, temparray)
- array[parent[level-1]]["upper_bound"] = temparray[0]
+ update_upper_bound(parent[level - 1], temparray[0])
}
/^Abbrev Number:[^(]+\(DW_TAG_/ {
if (match($0, /typedef|union_type|structure_type|pointer_type\
long long sll __attribute__((__aligned__(8)));
unsigned long long ull;
unsigned long ul;
- long asl[3];
+ long asl[3][5][7];
char f;
/* unsigned char mpers_end_filler_4[7]; */
} s;
unsigned long ul;
int si;
unsigned ui;
- short ss;
- unsigned short us;
+ short ss[7][9];
+ unsigned short us[4];
char sc;
unsigned char uc;
- } u[3];
+ } u[3][2];
short f[0];
} sample_struct;
#include MPERS_DEFS
int64_t sll;
uint64_t ull;
uint${size}_t ul;
-int${size}_t asl[3];
+int${size}_t asl[3][5][7];
char f;
unsigned char mpers_end_filler_4[7];
} ATTRIBUTE_PACKED s;
uint${size}_t ul;
int32_t si;
uint32_t ui;
-int16_t ss;
-uint16_t us;
+int16_t ss[7][9];
+uint16_t us[4];
char sc;
unsigned char uc;
-} u[3];
+} u[3][2];
int16_t f[0];
} ATTRIBUTE_PACKED ${mpers_name}_sample_struct;
#define MPERS_${mpers_name}_sample_struct ${mpers_name}_sample_struct