Lines Matching +defs:read +defs:string
39 static std::string toString(bytecode::Section::ID sectionID) {
98 /// Returns true if the entire section has been read.
247 /// Parse a null-terminated string into `result` (without including the NUL
254 "malformed null-terminated string, no null character found");
369 /// This class is used to read references to the string section from the
373 /// Initialize the string section reader with the given section data.
376 /// Parse a shared string from the string section. The shared string is
377 /// encoded using an index to a corresponding string in the string section.
379 return parseEntry(reader, strings, result, "string");
382 /// Parse a shared string from the string section. The shared string is
383 /// encoded using an index to a corresponding string in the string section.
393 /// Parse a shared string from the string section. The shared string is
394 /// encoded using an index to a corresponding string in the string section.
397 return resolveEntry(reader, strings, index, result, "string");
419 for (StringRef &string : llvm::reverse(strings)) {
425 "string size exceeds the available data size");
428 // Extract the string from the data, dropping the null character.
430 string = StringRef(
437 // should be at the same offset as the first string.
534 /// This class is used to read the resource section from the bytecode.
554 llvm::StringMap<std::string> dialectResourceHandleRenamingMap;
582 FailureOr<std::string> parseAsString() const final {
584 return emitError() << "expected a string resource entry, but found a "
587 StringRef string;
588 if (failed(stringReader.parseString(reader, string)))
590 return string.str();
783 /// bytecode. Attribute and Type entries are read lazily on demand, so we use
882 /// The string section reader used to resolve string references when parsing
1084 LogicalResult read(Location fileLoc, DialectReader &dialectReader,
1109 // Setup a new reader to read from the `rawProperties` sub-buffer.
1183 // Ensure that we read everything from the section.
1264 callback->read(dialectReader, entry.dialect->name, entry.entry)))
1279 callback->read(dialectReader, entry.dialect->name, entry.entry)))
1309 /// This class is used to read a bytecode buffer and translate it into MLIR.
1332 LogicalResult read(Block *block,
1439 /// This struct represents the current read state of a range of regions. This
1450 /// The current regions being read.
1462 /// The current blocks of the region being read.
1466 /// The number of operations remaining to be read from the current block
1467 /// being read.
1470 /// A flag indicating if the regions being read are isolated from above.
1582 /// The version of the bytecode being read.
1585 /// The producer of the bytecode being read.
1631 LogicalResult BytecodeReader::Impl::read(
1680 // Process the string section first.
1784 /// for dialects, and the entryIdx represent the string itself.
2069 // A stack of operation regions currently being read from the bytecode.
2143 // Read in the next operation. We don't read its regions directly, we
2200 // When the regions have been fully parsed, pop them off of the read stack. If
2259 propertiesReader.read(fileLoc, dialectReader, &*opName, opState)))
2542 return impl->read(block, lazyOpsCallback);
2584 return reader.read(block, /*lazyOpsCallback=*/nullptr);