23 :
Bitstream(Encoded), ContainerType(ContainerType) {}
32 R.push_back(RecordID);
56 auto Abbrev = std::make_shared<BitCodeAbbrev>();
68 auto Abbrev = std::make_shared<BitCodeAbbrev>();
87 auto Abbrev = std::make_shared<BitCodeAbbrev>();
111 auto Abbrev = std::make_shared<BitCodeAbbrev>();
133 auto Abbrev = std::make_shared<BitCodeAbbrev>();
147 auto Abbrev = std::make_shared<BitCodeAbbrev>();
160 auto Abbrev = std::make_shared<BitCodeAbbrev>();
172 auto Abbrev = std::make_shared<BitCodeAbbrev>();
188 auto Abbrev = std::make_shared<BitCodeAbbrev>();
235 uint64_t ContainerVersion, std::optional<uint64_t> RemarkVersion,
236 std::optional<const StringTable *> StrTab,
237 std::optional<StringRef> Filename) {
250 assert(StrTab != std::nullopt && *StrTab !=
nullptr);
252 assert(Filename != std::nullopt);
256 assert(RemarkVersion != std::nullopt);
260 assert(RemarkVersion != std::nullopt);
262 assert(StrTab != std::nullopt && *StrTab !=
nullptr);
282 if (
const std::optional<RemarkLocation> &Loc =
Remark.
Loc) {
300 unsigned Key = StrTab.
add(Arg.
Key).first;
301 unsigned Val = StrTab.
add(Arg.
Val).first;
302 bool HasDebugLoc = Arg.
Loc != std::nullopt;
334 "For SerializerMode::Standalone, a pre-filled string table needs to "
347 StrTab = std::move(StrTabIn);
359 : std::optional<const StringTable *>(std::nullopt));
365 "The Block info block and the meta block were not emitted yet.");
372 raw_ostream &
OS, std::optional<StringRef> ExternalFilename) {
377 return std::make_unique<BitstreamMetaSerializer>(
381 &*
StrTab, ExternalFilename);
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
BitCodeAbbrevOp - This describes one or more operands in an abbreviation.
void Emit(uint32_t Val, unsigned NumBits)
void EmitRecordWithBlob(unsigned Abbrev, const Container &Vals, StringRef Blob)
EmitRecordWithBlob - Emit the specified record to the stream, using an abbrev that includes a blob at...
unsigned EmitBlockInfoAbbrev(unsigned BlockID, std::shared_ptr< BitCodeAbbrev > Abbv)
EmitBlockInfoAbbrev - Emit a DEFINE_ABBREV record for the specified BlockID.
void EnterBlockInfoBlock()
EnterBlockInfoBlock - Start emitting the BLOCKINFO_BLOCK.
void EnterSubblock(unsigned BlockID, unsigned CodeLen)
void EmitRecordWithAbbrev(unsigned Abbrev, const Container &Vals)
EmitRecordWithAbbrev - Emit a record with the specified abbreviation.
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
void push_back(const T &Elt)
pointer data()
Return a pointer to the vector's buffer, even if empty().
StringRef - Represent a constant reference to a string, i.e.
This class implements an extremely fast bulk output stream that can only output to a stream.
raw_ostream & write(unsigned char C)
A raw_ostream that writes to an std::string.
@ C
The default llvm calling convention, compatible with C.
@ BLOCKINFO_CODE_BLOCKNAME
@ BLOCKINFO_CODE_SETRECORDNAME
This is an optimization pass for GlobalISel generic memory operations.
void append_range(Container &C, Range &&R)
Wrapper function to append range R to container C.