Lines Matching refs:map
33 DexDataMap* map = NULL; in dexDataMapAlloc() local
41 map = (DexDataMap*) malloc(size); in dexDataMapAlloc()
43 if (map == NULL) { in dexDataMapAlloc()
47 map->count = 0; in dexDataMapAlloc()
48 map->max = maxCount; in dexDataMapAlloc()
49 map->offsets = (u4*) (map + 1); in dexDataMapAlloc()
50 map->types = (u2*) (map->offsets + maxCount); in dexDataMapAlloc()
52 return map; in dexDataMapAlloc()
58 void dexDataMapFree(DexDataMap* map) { in dexDataMapFree() argument
64 free(map); in dexDataMapFree()
71 void dexDataMapAdd(DexDataMap* map, u4 offset, u2 type) { in dexDataMapAdd() argument
72 assert(map != NULL); in dexDataMapAdd()
73 assert(map->count < map->max); in dexDataMapAdd()
75 if ((map->count != 0) && in dexDataMapAdd()
76 (map->offsets[map->count - 1] >= offset)) { in dexDataMapAdd()
78 map->offsets[map->count - 1], offset); in dexDataMapAdd()
82 map->offsets[map->count] = offset; in dexDataMapAdd()
83 map->types[map->count] = type; in dexDataMapAdd()
84 map->count++; in dexDataMapAdd()
91 int dexDataMapGet(DexDataMap* map, u4 offset) { in dexDataMapGet() argument
92 assert(map != NULL); in dexDataMapGet()
96 int max = map->count - 1; in dexDataMapGet()
97 u4* offsets = map->offsets; in dexDataMapGet()
109 return map->types[guessIdx]; in dexDataMapGet()
122 bool dexDataMapVerify(DexDataMap* map, u4 offset, u2 type) { in dexDataMapVerify() argument
123 int found = dexDataMapGet(map, offset); in dexDataMapVerify()