Lines Matching refs:offset
102 SLICER_EXTRA(auto offset = data.size()); in WriteEncodedValue()
190 auto ptr = data.ptr<const dex::u1>(offset); in WriteEncodedValue()
191 auto size = data.size() - offset; in WriteEncodedValue()
227 dex::u4 offset = section.SectionOffset(); in CopySection() local
229 SLICER_CHECK(offset >= sizeof(dex::Header)); in CopySection()
230 SLICER_CHECK(offset + size <= image_size); in CopySection()
232 ::memcpy(image + offset, section.data(), size); in CopySection()
257 dex::u4 offset = 0; in CreateImage() local
261 offset += sizeof(dex::Header); in CreateImage()
262 offset += dex_->string_ids.Init(offset, dex_ir_->strings.size()); in CreateImage()
263 offset += dex_->type_ids.Init(offset, dex_ir_->types.size()); in CreateImage()
264 offset += dex_->proto_ids.Init(offset, dex_ir_->protos.size()); in CreateImage()
265 offset += dex_->field_ids.Init(offset, dex_ir_->fields.size()); in CreateImage()
266 offset += dex_->method_ids.Init(offset, dex_ir_->methods.size()); in CreateImage()
267 offset += dex_->class_defs.Init(offset, dex_ir_->classes.size()); in CreateImage()
270 SLICER_CHECK(offset % 4 == 0); in CreateImage()
271 const dex::u4 data_offset = offset; in CreateImage()
275 offset += CreateStringDataSection(offset); in CreateImage()
276 offset += CreateTypeListsSection(offset); in CreateImage()
277 offset += CreateDebugInfoSection(offset); in CreateImage()
278 offset += CreateEncodedArrayItemSection(offset); in CreateImage()
279 offset += CreateCodeItemSection(offset); in CreateImage()
280 offset += CreateClassDataSection(offset); in CreateImage()
281 offset += CreateAnnItemSection(offset); in CreateImage()
282 offset += CreateAnnSetsSection(offset); in CreateImage()
283 offset += CreateAnnSetRefListsSection(offset); in CreateImage()
284 offset += CreateAnnDirectoriesSection(offset); in CreateImage()
285 offset += CreateMapSection(offset); in CreateImage()
295 SLICER_CHECK(offset % 4 == 0); in CreateImage()
296 const dex::u4 image_size = offset; in CreateImage()
371 dex::u4 offset = section.AddItem(); in CreateStringDataSection() local
373 dexStringId->string_data_off = section.AbsoluteOffset(offset); in CreateStringDataSection()
388 map_item.offset = section.SectionOffset(); in AddMapItem()
404 headerItem.offset = 0; in CreateMapSection()
427 SLICER_CHECK(a.offset != b.offset); in CreateMapSection()
428 return a.offset < b.offset; in CreateMapSection()
443 dex::u4& offset = node_offset_[ir_node.get()]; in CreateAnnItemSection() local
444 SLICER_CHECK(offset == 0); in CreateAnnItemSection()
445 offset = WriteAnnotationItem(ir_node.get()); in CreateAnnItemSection()
457 dex::u4& offset = node_offset_[ir_node.get()]; in CreateAnnSetsSection() local
458 SLICER_CHECK(offset == 0); in CreateAnnSetsSection()
459 offset = WriteAnnotationSet(ir_node.get()); in CreateAnnSetsSection()
470 dex::u4& offset = node_offset_[ir_node.get()]; in CreateAnnSetRefListsSection() local
471 SLICER_CHECK(offset == 0); in CreateAnnSetRefListsSection()
472 offset = WriteAnnotationSetRefList(ir_node.get()); in CreateAnnSetRefListsSection()
483 dex::u4& offset = node_offset_[ir_type_list.get()]; in CreateTypeListsSection() local
484 SLICER_CHECK(offset == 0); in CreateTypeListsSection()
485 offset = WriteTypeList(ir_type_list->types); in CreateTypeListsSection()
496 dex::u4& offset = node_offset_[ir_node.get()]; in CreateCodeItemSection() local
497 SLICER_CHECK(offset == 0); in CreateCodeItemSection()
498 offset = WriteCode(ir_node.get()); in CreateCodeItemSection()
510 dex::u4& offset = node_offset_[ir_node.get()]; in CreateDebugInfoSection() local
511 SLICER_CHECK(offset == 0); in CreateDebugInfoSection()
512 offset = WriteDebugInfo(ir_node.get()); in CreateDebugInfoSection()
637 dex::u4 offset = data.AddItem(4); in WriteTypeList() local
642 return data.AbsoluteOffset(offset); in WriteTypeList()
650 dex::u4 offset = data.AddItem(); in WriteAnnotationItem() local
653 return data.AbsoluteOffset(offset); in WriteAnnotationItem()
663 dex::u4 offset = data.AddItem(4); in WriteAnnotationSet() local
668 return data.AbsoluteOffset(offset); in WriteAnnotationSet()
679 dex::u4 offset = data.AddItem(4); in WriteAnnotationSetRefList() local
684 return data.AbsoluteOffset(offset); in WriteAnnotationSetRefList()
695 dex::u4& offset = node_offset_[ir_annotations]; in WriteClassAnnotations() local
696 if (offset == 0) { in WriteClassAnnotations()
738 offset = data.AddItem(4); in WriteClassAnnotations()
743 offset = data.AbsoluteOffset(offset); in WriteClassAnnotations()
745 return offset; in WriteClassAnnotations()
753 dex::u4 offset = data.AddItem(); in WriteDebugInfo() local
818 return data.AbsoluteOffset(offset); in WriteDebugInfo()
825 auto offset = dex_->code.Push(instructions); in WriteInstructions() local
826 dex::u2* ptr = dex_->code.ptr<dex::u2>(offset); in WriteInstructions()
968 dex::u4 offset = data.AddItem(4); in WriteCode() local
975 return data.AbsoluteOffset(offset); in WriteCode()
1021 dex::u4 offset = data.AddItem(); in WriteClassData() local
1048 return data.AbsoluteOffset(offset); in WriteClassData()
1057 dex::u4& offset = node_offset_[ir_class->static_init]; in WriteClassStaticValues() local
1058 if (offset == 0) { in WriteClassStaticValues()
1060 offset = data.AddItem(); in WriteClassStaticValues()
1062 offset = data.AbsoluteOffset(offset); in WriteClassStaticValues()
1064 return offset; in WriteClassStaticValues()
1110 dex::u4 offset = it->second; in FilePointer() local
1111 SLICER_CHECK(offset > 0); in FilePointer()
1112 return offset; in FilePointer()