Lines Matching refs:info
80 struct taginfo *info, *link; in _tnf_fini_tags() local
86 info = tnf->tag_table[i]; in _tnf_fini_tags()
87 while (info) { in _tnf_fini_tags()
89 link = info->link; in _tnf_fini_tags()
91 if (info->slotinfo) in _tnf_fini_tags()
92 free(info->slotinfo); in _tnf_fini_tags()
94 free(info); in _tnf_fini_tags()
96 info = link; in _tnf_fini_tags()
117 struct taginfo *bucket, *info; in _tnf_get_info() local
120 for (info = bucket; info; info = info->link) in _tnf_get_info()
121 if (info->tag == tag) in _tnf_get_info()
122 return (info); /* found it */ in _tnf_get_info()
139 struct taginfo *info; in _tnf_record_info() local
151 if ((info = tnf->tag_directory[index]) != NULL) in _tnf_record_info()
152 return (info); in _tnf_record_info()
154 info = _tnf_get_info(tnf, _tnf_get_tag(tnf, record)); in _tnf_record_info()
156 return ((tnf->tag_directory[index] = info)); in _tnf_record_info()
171 struct taginfo *info, *bucket; in add_info() local
175 info = (struct taginfo *)calloc(1, sizeof (struct taginfo)); in add_info()
178 info->tnf = tnf; in add_info()
179 info->tag = tag; in add_info()
180 info->name = _tnf_get_name(tnf, tag); in add_info()
181 info->props = _tnf_get_props(tnf, tag); in add_info()
182 info->kind = _tnf_get_kind(tnf, tag); in add_info()
183 info->size = _tnf_get_storage_size(tnf, tag); in add_info()
184 info->align = _tnf_get_align(tnf, tag); in add_info()
189 info->link = bucket; in add_info()
190 tnf->tag_table[hash] = info; in add_info()
194 info->meta = _tnf_get_info(tnf, meta); in add_info()
201 if (INFO_DERIVED(info)) in add_info()
202 return (init_derived_info(tnf, tag, info)); in add_info()
203 else if (INFO_STRUCT(info)) in add_info()
204 return (init_struct_info(tnf, tag, info)); in add_info()
205 else if (INFO_ARRAY(info)) in add_info()
206 return (init_array_info(tnf, tag, info)); in add_info()
207 else if (INFO_SCALAR(info)) in add_info()
208 return (init_scalar_info(tnf, tag, info)); in add_info()
210 return (init_abstract_info(tnf, tag, info)); in add_info()
220 init_abstract_info(TNF *tnf, tnf_ref32_t *tag, struct taginfo *info) in init_abstract_info() argument
222 if (INFO_SCALAR(info) || INFO_DERIVED(info) || in init_abstract_info()
223 INFO_STRUCT(info) || INFO_ARRAY(info)) in init_abstract_info()
225 if (info->size == (size_t)-1) in init_abstract_info()
227 return (info); in init_abstract_info()
235 init_derived_info(TNF *tnf, tnf_ref32_t *tag, struct taginfo *info) in init_derived_info() argument
239 if (!INFO_DERIVED(info)) in init_derived_info()
244 info->base = _tnf_get_info(tnf, base_tag); in init_derived_info()
246 return (info); in init_derived_info()
255 init_scalar_info(TNF *tnf, tnf_ref32_t *tag, struct taginfo *info) in init_scalar_info() argument
257 if ((!INFO_SCALAR(info)) || in init_scalar_info()
258 (INFO_DERIVED(info) || INFO_ARRAY(info) || INFO_STRUCT(info))) in init_scalar_info()
260 if (info->size == (size_t)-1) in init_scalar_info()
265 return (info); in init_scalar_info()
273 init_struct_info(TNF *tnf, tnf_ref32_t *tag, struct taginfo *info) in init_struct_info() argument
275 if ((!INFO_STRUCT(info)) || in init_struct_info()
276 (INFO_DERIVED(info) || INFO_ARRAY(info) || INFO_SCALAR(info))) in init_struct_info()
278 if (info->size == (size_t)-1) in init_struct_info()
282 init_slots(tnf, tag, info); in init_struct_info()
284 return (info); in init_struct_info()
292 init_array_info(TNF *tnf, tnf_ref32_t *tag, struct taginfo *info) in init_array_info() argument
297 if ((!INFO_ARRAY(info)) || in init_array_info()
298 (INFO_DERIVED(info) || INFO_STRUCT(info) || INFO_SCALAR(info))) in init_array_info()
302 defeat = (strcmp(info->name, TNF_N_ARRAY) == 0); in init_array_info()
305 if (!(INFO_TAGGED(info) && (info->size == (size_t)-1))) in init_array_info()
310 info->hdrsize = _tnf_get_header_size(tnf, tag); in init_array_info()
312 if (info->hdrsize != sizeof (struct tnf_array_hdr)) in init_array_info()
317 init_slots(tnf, tag, info); in init_array_info()
324 info->base = elt_tag ? _tnf_get_info(tnf, elt_tag): NULL; in init_array_info()
326 return (info); in init_array_info()
334 init_slots(TNF *tnf, tnf_ref32_t *tag, struct taginfo *info) in init_slots() argument
399 info->slotinfo = slotinfo; in init_slots()