Lines Matching refs:Ctx
70 static uint8_t readUint8(WasmObjectFile::ReadContext &Ctx) { in readUint8() argument
71 if (Ctx.Ptr == Ctx.End) in readUint8()
73 return *Ctx.Ptr++; in readUint8()
76 static uint32_t readUint32(WasmObjectFile::ReadContext &Ctx) { in readUint32() argument
77 if (Ctx.Ptr + 4 > Ctx.End) in readUint32()
79 uint32_t Result = support::endian::read32le(Ctx.Ptr); in readUint32()
80 Ctx.Ptr += 4; in readUint32()
84 static int32_t readFloat32(WasmObjectFile::ReadContext &Ctx) { in readFloat32() argument
85 if (Ctx.Ptr + 4 > Ctx.End) in readFloat32()
88 memcpy(&Result, Ctx.Ptr, sizeof(Result)); in readFloat32()
89 Ctx.Ptr += sizeof(Result); in readFloat32()
93 static int64_t readFloat64(WasmObjectFile::ReadContext &Ctx) { in readFloat64() argument
94 if (Ctx.Ptr + 8 > Ctx.End) in readFloat64()
97 memcpy(&Result, Ctx.Ptr, sizeof(Result)); in readFloat64()
98 Ctx.Ptr += sizeof(Result); in readFloat64()
102 static uint64_t readULEB128(WasmObjectFile::ReadContext &Ctx) { in readULEB128() argument
105 uint64_t Result = decodeULEB128(Ctx.Ptr, &Count, Ctx.End, &Error); in readULEB128()
108 Ctx.Ptr += Count; in readULEB128()
112 static StringRef readString(WasmObjectFile::ReadContext &Ctx) { in readString() argument
113 uint32_t StringLen = readULEB128(Ctx); in readString()
114 if (Ctx.Ptr + StringLen > Ctx.End) in readString()
117 StringRef(reinterpret_cast<const char *>(Ctx.Ptr), StringLen); in readString()
118 Ctx.Ptr += StringLen; in readString()
122 static int64_t readLEB128(WasmObjectFile::ReadContext &Ctx) { in readLEB128() argument
125 uint64_t Result = decodeSLEB128(Ctx.Ptr, &Count, Ctx.End, &Error); in readLEB128()
128 Ctx.Ptr += Count; in readLEB128()
132 static uint8_t readVaruint1(WasmObjectFile::ReadContext &Ctx) { in readVaruint1() argument
133 int64_t Result = readLEB128(Ctx); in readVaruint1()
139 static int32_t readVarint32(WasmObjectFile::ReadContext &Ctx) { in readVarint32() argument
140 int64_t Result = readLEB128(Ctx); in readVarint32()
146 static uint32_t readVaruint32(WasmObjectFile::ReadContext &Ctx) { in readVaruint32() argument
147 uint64_t Result = readULEB128(Ctx); in readVaruint32()
153 static int64_t readVarint64(WasmObjectFile::ReadContext &Ctx) { in readVarint64() argument
154 return readLEB128(Ctx); in readVarint64()
157 static uint64_t readVaruint64(WasmObjectFile::ReadContext &Ctx) { in readVaruint64() argument
158 return readULEB128(Ctx); in readVaruint64()
161 static uint8_t readOpcode(WasmObjectFile::ReadContext &Ctx) { in readOpcode() argument
162 return readUint8(Ctx); in readOpcode()
166 WasmObjectFile::ReadContext &Ctx) { in readInitExpr() argument
167 auto Start = Ctx.Ptr; in readInitExpr()
170 Expr.Inst.Opcode = readOpcode(Ctx); in readInitExpr()
173 Expr.Inst.Value.Int32 = readVarint32(Ctx); in readInitExpr()
176 Expr.Inst.Value.Int64 = readVarint64(Ctx); in readInitExpr()
179 Expr.Inst.Value.Float32 = readFloat32(Ctx); in readInitExpr()
182 Expr.Inst.Value.Float64 = readFloat64(Ctx); in readInitExpr()
185 Expr.Inst.Value.Global = readULEB128(Ctx); in readInitExpr()
188 wasm::ValType Ty = static_cast<wasm::ValType>(readULEB128(Ctx)); in readInitExpr()
200 uint8_t EndOpcode = readOpcode(Ctx); in readInitExpr()
206 Ctx.Ptr = Start; in readInitExpr()
208 uint8_t Opcode = readOpcode(Ctx); in readInitExpr()
216 readULEB128(Ctx); in readInitExpr()
226 Expr.Body = ArrayRef<uint8_t>(Start, Ctx.Ptr - Start); in readInitExpr()
239 static wasm::WasmLimits readLimits(WasmObjectFile::ReadContext &Ctx) { in readLimits() argument
241 Result.Flags = readVaruint32(Ctx); in readLimits()
242 Result.Minimum = readVaruint64(Ctx); in readLimits()
244 Result.Maximum = readVaruint64(Ctx); in readLimits()
248 static wasm::WasmTableType readTableType(WasmObjectFile::ReadContext &Ctx) { in readTableType() argument
250 TableType.ElemType = readUint8(Ctx); in readTableType()
251 TableType.Limits = readLimits(Ctx); in readTableType()
255 static Error readSection(WasmSection &Section, WasmObjectFile::ReadContext &Ctx, in readSection() argument
257 Section.Offset = Ctx.Ptr - Ctx.Start; in readSection()
258 Section.Type = readUint8(Ctx); in readSection()
260 uint32_t Size = readVaruint32(Ctx); in readSection()
264 if (Ctx.Ptr + Size > Ctx.End) in readSection()
269 SectionCtx.Start = Ctx.Ptr; in readSection()
270 SectionCtx.Ptr = Ctx.Ptr; in readSection()
271 SectionCtx.End = Ctx.Ptr + Size; in readSection()
276 Ctx.Ptr += SectionNameSize; in readSection()
286 Section.Content = ArrayRef<uint8_t>(Ctx.Ptr, Size); in readSection()
287 Ctx.Ptr += Size; in readSection()
301 ReadContext Ctx; in WasmObjectFile() local
302 Ctx.Start = getData().bytes_begin(); in WasmObjectFile()
303 Ctx.Ptr = Ctx.Start + 4; in WasmObjectFile()
304 Ctx.End = Ctx.Start + getData().size(); in WasmObjectFile()
306 if (Ctx.Ptr + 4 > Ctx.End) { in WasmObjectFile()
312 Header.Version = readUint32(Ctx); in WasmObjectFile()
321 while (Ctx.Ptr < Ctx.End) { in WasmObjectFile()
323 if ((Err = readSection(Sec, Ctx, Checker))) in WasmObjectFile()
333 ReadContext Ctx; in parseSection() local
334 Ctx.Start = Sec.Content.data(); in parseSection()
335 Ctx.End = Ctx.Start + Sec.Content.size(); in parseSection()
336 Ctx.Ptr = Ctx.Start; in parseSection()
339 return parseCustomSection(Sec, Ctx); in parseSection()
341 return parseTypeSection(Ctx); in parseSection()
343 return parseImportSection(Ctx); in parseSection()
345 return parseFunctionSection(Ctx); in parseSection()
347 return parseTableSection(Ctx); in parseSection()
349 return parseMemorySection(Ctx); in parseSection()
351 return parseTagSection(Ctx); in parseSection()
353 return parseGlobalSection(Ctx); in parseSection()
355 return parseExportSection(Ctx); in parseSection()
357 return parseStartSection(Ctx); in parseSection()
359 return parseElemSection(Ctx); in parseSection()
361 return parseCodeSection(Ctx); in parseSection()
363 return parseDataSection(Ctx); in parseSection()
365 return parseDataCountSection(Ctx); in parseSection()
372 Error WasmObjectFile::parseDylinkSection(ReadContext &Ctx) { in parseDylinkSection() argument
376 DylinkInfo.MemorySize = readVaruint32(Ctx); in parseDylinkSection()
377 DylinkInfo.MemoryAlignment = readVaruint32(Ctx); in parseDylinkSection()
378 DylinkInfo.TableSize = readVaruint32(Ctx); in parseDylinkSection()
379 DylinkInfo.TableAlignment = readVaruint32(Ctx); in parseDylinkSection()
380 uint32_t Count = readVaruint32(Ctx); in parseDylinkSection()
382 DylinkInfo.Needed.push_back(readString(Ctx)); in parseDylinkSection()
385 if (Ctx.Ptr != Ctx.End) in parseDylinkSection()
391 Error WasmObjectFile::parseDylink0Section(ReadContext &Ctx) { in parseDylink0Section() argument
396 const uint8_t *OrigEnd = Ctx.End; in parseDylink0Section()
397 while (Ctx.Ptr < OrigEnd) { in parseDylink0Section()
398 Ctx.End = OrigEnd; in parseDylink0Section()
399 uint8_t Type = readUint8(Ctx); in parseDylink0Section()
400 uint32_t Size = readVaruint32(Ctx); in parseDylink0Section()
403 Ctx.End = Ctx.Ptr + Size; in parseDylink0Section()
407 DylinkInfo.MemorySize = readVaruint32(Ctx); in parseDylink0Section()
408 DylinkInfo.MemoryAlignment = readVaruint32(Ctx); in parseDylink0Section()
409 DylinkInfo.TableSize = readVaruint32(Ctx); in parseDylink0Section()
410 DylinkInfo.TableAlignment = readVaruint32(Ctx); in parseDylink0Section()
413 Count = readVaruint32(Ctx); in parseDylink0Section()
415 DylinkInfo.Needed.push_back(readString(Ctx)); in parseDylink0Section()
419 uint32_t Count = readVaruint32(Ctx); in parseDylink0Section()
421 DylinkInfo.ExportInfo.push_back({readString(Ctx), readVaruint32(Ctx)}); in parseDylink0Section()
426 uint32_t Count = readVaruint32(Ctx); in parseDylink0Section()
429 {readString(Ctx), readString(Ctx), readVaruint32(Ctx)}); in parseDylink0Section()
435 Ctx.Ptr += Size; in parseDylink0Section()
438 if (Ctx.Ptr != Ctx.End) { in parseDylink0Section()
444 if (Ctx.Ptr != Ctx.End) in parseDylink0Section()
450 Error WasmObjectFile::parseNameSection(ReadContext &Ctx) { in parseNameSection() argument
455 while (Ctx.Ptr < Ctx.End) { in parseNameSection()
456 uint8_t Type = readUint8(Ctx); in parseNameSection()
457 uint32_t Size = readVaruint32(Ctx); in parseNameSection()
458 const uint8_t *SubSectionEnd = Ctx.Ptr + Size; in parseNameSection()
463 uint32_t Count = readVaruint32(Ctx); in parseNameSection()
465 uint32_t Index = readVaruint32(Ctx); in parseNameSection()
466 StringRef Name = readString(Ctx); in parseNameSection()
502 Ctx.Ptr += Size; in parseNameSection()
505 if (Ctx.Ptr != SubSectionEnd) in parseNameSection()
510 if (Ctx.Ptr != Ctx.End) in parseNameSection()
516 Error WasmObjectFile::parseLinkingSection(ReadContext &Ctx) { in parseLinkingSection() argument
519 LinkingData.Version = readVaruint32(Ctx); in parseLinkingSection()
527 const uint8_t *OrigEnd = Ctx.End; in parseLinkingSection()
528 while (Ctx.Ptr < OrigEnd) { in parseLinkingSection()
529 Ctx.End = OrigEnd; in parseLinkingSection()
530 uint8_t Type = readUint8(Ctx); in parseLinkingSection()
531 uint32_t Size = readVaruint32(Ctx); in parseLinkingSection()
534 Ctx.End = Ctx.Ptr + Size; in parseLinkingSection()
537 if (Error Err = parseLinkingSectionSymtab(Ctx)) in parseLinkingSection()
541 uint32_t Count = readVaruint32(Ctx); in parseLinkingSection()
546 DataSegments[I].Data.Name = readString(Ctx); in parseLinkingSection()
547 DataSegments[I].Data.Alignment = readVaruint32(Ctx); in parseLinkingSection()
548 DataSegments[I].Data.LinkingFlags = readVaruint32(Ctx); in parseLinkingSection()
553 uint32_t Count = readVaruint32(Ctx); in parseLinkingSection()
557 Init.Priority = readVaruint32(Ctx); in parseLinkingSection()
558 Init.Symbol = readVaruint32(Ctx); in parseLinkingSection()
568 if (Error Err = parseLinkingSectionComdat(Ctx)) in parseLinkingSection()
572 Ctx.Ptr += Size; in parseLinkingSection()
575 if (Ctx.Ptr != Ctx.End) in parseLinkingSection()
579 if (Ctx.Ptr != OrigEnd) in parseLinkingSection()
585 Error WasmObjectFile::parseLinkingSectionSymtab(ReadContext &Ctx) { in parseLinkingSectionSymtab() argument
586 uint32_t Count = readVaruint32(Ctx); in parseLinkingSectionSymtab()
616 Info.Kind = readUint8(Ctx); in parseLinkingSectionSymtab()
617 Info.Flags = readVaruint32(Ctx); in parseLinkingSectionSymtab()
622 Info.ElementIndex = readVaruint32(Ctx); in parseLinkingSectionSymtab()
628 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
637 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
650 Info.ElementIndex = readVaruint32(Ctx); in parseLinkingSectionSymtab()
660 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
669 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
682 Info.ElementIndex = readVaruint32(Ctx); in parseLinkingSectionSymtab()
692 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
701 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
714 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
716 auto Index = readVaruint32(Ctx); in parseLinkingSectionSymtab()
720 auto Offset = readVaruint64(Ctx); in parseLinkingSectionSymtab()
721 auto Size = readVaruint64(Ctx); in parseLinkingSectionSymtab()
738 Info.ElementIndex = readVaruint32(Ctx); in parseLinkingSectionSymtab()
746 Info.ElementIndex = readVaruint32(Ctx); in parseLinkingSectionSymtab()
756 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
766 Info.Name = readString(Ctx); in parseLinkingSectionSymtab()
800 Error WasmObjectFile::parseLinkingSectionComdat(ReadContext &Ctx) { in parseLinkingSectionComdat() argument
801 uint32_t ComdatCount = readVaruint32(Ctx); in parseLinkingSectionComdat()
804 StringRef Name = readString(Ctx); in parseLinkingSectionComdat()
810 uint32_t Flags = readVaruint32(Ctx); in parseLinkingSectionComdat()
815 uint32_t EntryCount = readVaruint32(Ctx); in parseLinkingSectionComdat()
817 unsigned Kind = readVaruint32(Ctx); in parseLinkingSectionComdat()
818 unsigned Index = readVaruint32(Ctx); in parseLinkingSectionComdat()
856 Error WasmObjectFile::parseProducersSection(ReadContext &Ctx) { in parseProducersSection() argument
858 uint32_t Fields = readVaruint32(Ctx); in parseProducersSection()
860 StringRef FieldName = readString(Ctx); in parseProducersSection()
878 uint32_t ValueCount = readVaruint32(Ctx); in parseProducersSection()
881 StringRef Name = readString(Ctx); in parseProducersSection()
882 StringRef Version = readString(Ctx); in parseProducersSection()
891 if (Ctx.Ptr != Ctx.End) in parseProducersSection()
897 Error WasmObjectFile::parseTargetFeaturesSection(ReadContext &Ctx) { in parseTargetFeaturesSection() argument
899 uint32_t FeatureCount = readVaruint32(Ctx); in parseTargetFeaturesSection()
902 Feature.Prefix = readUint8(Ctx); in parseTargetFeaturesSection()
912 Feature.Name = std::string(readString(Ctx)); in parseTargetFeaturesSection()
920 if (Ctx.Ptr != Ctx.End) in parseTargetFeaturesSection()
927 Error WasmObjectFile::parseRelocSection(StringRef Name, ReadContext &Ctx) { in parseRelocSection() argument
928 uint32_t SectionIndex = readVaruint32(Ctx); in parseRelocSection()
933 uint32_t RelocCount = readVaruint32(Ctx); in parseRelocSection()
938 uint32_t type = readVaruint32(Ctx); in parseRelocSection()
940 Reloc.Offset = readVaruint32(Ctx); in parseRelocSection()
945 Reloc.Index = readVaruint32(Ctx); in parseRelocSection()
996 Reloc.Addend = readVarint32(Ctx); in parseRelocSection()
1006 Reloc.Addend = readVarint64(Ctx); in parseRelocSection()
1012 Reloc.Addend = readVarint32(Ctx); in parseRelocSection()
1018 Reloc.Addend = readVarint64(Ctx); in parseRelocSection()
1024 Reloc.Addend = readVarint32(Ctx); in parseRelocSection()
1057 if (Ctx.Ptr != Ctx.End) in parseRelocSection()
1063 Error WasmObjectFile::parseCustomSection(WasmSection &Sec, ReadContext &Ctx) { in parseCustomSection() argument
1065 if (Error Err = parseDylinkSection(Ctx)) in parseCustomSection()
1068 if (Error Err = parseDylink0Section(Ctx)) in parseCustomSection()
1071 if (Error Err = parseNameSection(Ctx)) in parseCustomSection()
1074 if (Error Err = parseLinkingSection(Ctx)) in parseCustomSection()
1077 if (Error Err = parseProducersSection(Ctx)) in parseCustomSection()
1080 if (Error Err = parseTargetFeaturesSection(Ctx)) in parseCustomSection()
1083 if (Error Err = parseRelocSection(Sec.Name, Ctx)) in parseCustomSection()
1089 Error WasmObjectFile::parseTypeSection(ReadContext &Ctx) { in parseTypeSection() argument
1090 uint32_t Count = readVaruint32(Ctx); in parseTypeSection()
1094 uint8_t Form = readUint8(Ctx); in parseTypeSection()
1099 uint32_t ParamCount = readVaruint32(Ctx); in parseTypeSection()
1102 uint32_t ParamType = readUint8(Ctx); in parseTypeSection()
1105 uint32_t ReturnCount = readVaruint32(Ctx); in parseTypeSection()
1107 uint32_t ReturnType = readUint8(Ctx); in parseTypeSection()
1112 if (Ctx.Ptr != Ctx.End) in parseTypeSection()
1118 Error WasmObjectFile::parseImportSection(ReadContext &Ctx) { in parseImportSection() argument
1119 uint32_t Count = readVaruint32(Ctx); in parseImportSection()
1124 Im.Module = readString(Ctx); in parseImportSection()
1125 Im.Field = readString(Ctx); in parseImportSection()
1126 Im.Kind = readUint8(Ctx); in parseImportSection()
1130 Im.SigIndex = readVaruint32(Ctx); in parseImportSection()
1137 Im.Global.Type = readUint8(Ctx); in parseImportSection()
1138 Im.Global.Mutable = readVaruint1(Ctx); in parseImportSection()
1141 Im.Memory = readLimits(Ctx); in parseImportSection()
1146 Im.Table = readTableType(Ctx); in parseImportSection()
1157 if (readUint8(Ctx) != 0) // Reserved 'attribute' field in parseImportSection()
1160 Im.SigIndex = readVaruint32(Ctx); in parseImportSection()
1171 if (Ctx.Ptr != Ctx.End) in parseImportSection()
1177 Error WasmObjectFile::parseFunctionSection(ReadContext &Ctx) { in parseFunctionSection() argument
1178 uint32_t Count = readVaruint32(Ctx); in parseFunctionSection()
1182 uint32_t Type = readVaruint32(Ctx); in parseFunctionSection()
1190 if (Ctx.Ptr != Ctx.End) in parseFunctionSection()
1196 Error WasmObjectFile::parseTableSection(ReadContext &Ctx) { in parseTableSection() argument
1198 uint32_t Count = readVaruint32(Ctx); in parseTableSection()
1202 T.Type = readTableType(Ctx); in parseTableSection()
1212 if (Ctx.Ptr != Ctx.End) in parseTableSection()
1218 Error WasmObjectFile::parseMemorySection(ReadContext &Ctx) { in parseMemorySection() argument
1219 uint32_t Count = readVaruint32(Ctx); in parseMemorySection()
1222 auto Limits = readLimits(Ctx); in parseMemorySection()
1227 if (Ctx.Ptr != Ctx.End) in parseMemorySection()
1233 Error WasmObjectFile::parseTagSection(ReadContext &Ctx) { in parseTagSection() argument
1235 uint32_t Count = readVaruint32(Ctx); in parseTagSection()
1239 if (readUint8(Ctx) != 0) // Reserved 'attribute' field in parseTagSection()
1242 uint32_t Type = readVaruint32(Ctx); in parseTagSection()
1252 if (Ctx.Ptr != Ctx.End) in parseTagSection()
1258 Error WasmObjectFile::parseGlobalSection(ReadContext &Ctx) { in parseGlobalSection() argument
1260 uint32_t Count = readVaruint32(Ctx); in parseGlobalSection()
1265 Global.Type.Type = readUint8(Ctx); in parseGlobalSection()
1266 Global.Type.Mutable = readVaruint1(Ctx); in parseGlobalSection()
1267 if (Error Err = readInitExpr(Global.InitExpr, Ctx)) in parseGlobalSection()
1271 if (Ctx.Ptr != Ctx.End) in parseGlobalSection()
1277 Error WasmObjectFile::parseExportSection(ReadContext &Ctx) { in parseExportSection() argument
1278 uint32_t Count = readVaruint32(Ctx); in parseExportSection()
1282 Ex.Name = readString(Ctx); in parseExportSection()
1283 Ex.Kind = readUint8(Ctx); in parseExportSection()
1284 Ex.Index = readVaruint32(Ctx); in parseExportSection()
1312 if (Ctx.Ptr != Ctx.End) in parseExportSection()
1395 Error WasmObjectFile::parseStartSection(ReadContext &Ctx) { in parseStartSection() argument
1396 StartFunction = readVaruint32(Ctx); in parseStartSection()
1403 Error WasmObjectFile::parseCodeSection(ReadContext &Ctx) { in parseCodeSection() argument
1405 uint32_t FunctionCount = readVaruint32(Ctx); in parseCodeSection()
1413 const uint8_t *FunctionStart = Ctx.Ptr; in parseCodeSection()
1414 uint32_t Size = readVaruint32(Ctx); in parseCodeSection()
1415 const uint8_t *FunctionEnd = Ctx.Ptr + Size; in parseCodeSection()
1417 Function.CodeOffset = Ctx.Ptr - FunctionStart; in parseCodeSection()
1419 Function.CodeSectionOffset = FunctionStart - Ctx.Start; in parseCodeSection()
1422 uint32_t NumLocalDecls = readVaruint32(Ctx); in parseCodeSection()
1426 Decl.Count = readVaruint32(Ctx); in parseCodeSection()
1427 Decl.Type = readUint8(Ctx); in parseCodeSection()
1431 uint32_t BodySize = FunctionEnd - Ctx.Ptr; in parseCodeSection()
1432 Function.Body = ArrayRef<uint8_t>(Ctx.Ptr, BodySize); in parseCodeSection()
1435 Ctx.Ptr += BodySize; in parseCodeSection()
1436 assert(Ctx.Ptr == FunctionEnd); in parseCodeSection()
1438 if (Ctx.Ptr != Ctx.End) in parseCodeSection()
1444 Error WasmObjectFile::parseElemSection(ReadContext &Ctx) { in parseElemSection() argument
1445 uint32_t Count = readVaruint32(Ctx); in parseElemSection()
1449 Segment.Flags = readVaruint32(Ctx); in parseElemSection()
1459 Segment.TableNumber = readVaruint32(Ctx); in parseElemSection()
1471 if (Error Err = readInitExpr(Segment.Offset, Ctx)) in parseElemSection()
1476 Segment.ElemKind = readUint8(Ctx); in parseElemSection()
1498 uint32_t NumElems = readVaruint32(Ctx); in parseElemSection()
1500 Segment.Functions.push_back(readVaruint32(Ctx)); in parseElemSection()
1504 if (Ctx.Ptr != Ctx.End) in parseElemSection()
1510 Error WasmObjectFile::parseDataSection(ReadContext &Ctx) { in parseDataSection() argument
1512 uint32_t Count = readVaruint32(Ctx); in parseDataSection()
1519 Segment.Data.InitFlags = readVaruint32(Ctx); in parseDataSection()
1522 ? readVaruint32(Ctx) in parseDataSection()
1525 if (Error Err = readInitExpr(Segment.Data.Offset, Ctx)) in parseDataSection()
1532 uint32_t Size = readVaruint32(Ctx); in parseDataSection()
1533 if (Size > (size_t)(Ctx.End - Ctx.Ptr)) in parseDataSection()
1536 Segment.Data.Content = ArrayRef<uint8_t>(Ctx.Ptr, Size); in parseDataSection()
1542 Segment.SectionOffset = Ctx.Ptr - Ctx.Start; in parseDataSection()
1543 Ctx.Ptr += Size; in parseDataSection()
1546 if (Ctx.Ptr != Ctx.End) in parseDataSection()
1552 Error WasmObjectFile::parseDataCountSection(ReadContext &Ctx) { in parseDataCountSection() argument
1553 DataCount = readVaruint32(Ctx); in parseDataCountSection()