1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 12:12:47 +01:00
llvm-mirror/include/llvm/Bitcode
Duncan P. N. Exon Smith 7b1e6b8367 Bitcode: Collect all MDString records into a single blob
Optimize output of MDStrings in bitcode.  This emits them in big blocks
(currently 1024) in a pair of records:
  - BULK_STRING_SIZES: the sizes of the strings in the block, and
  - BULK_STRING_DATA: a single blob, which is the concatenation of all
    the strings.

Inspired by Mehdi's similar patch, http://reviews.llvm.org/D18342, this
should (a) slightly reduce bitcode size, since there is less record
overhead, and (b) greatly improve reading speed, since blobs are super
cheap to deserialize.

I needed to add support for blobs to streaming input to get the test
suite passing.
  - StreamingMemoryObject::getPointer reads ahead and returns the
    address of the blob.
  - To avoid a possible reallocation of StreamingMemoryObject::Bytes,
    BitstreamCursor::readRecord needs to move the call to JumpToEnd
    forward so that getPointer is the last bitstream operation.

llvm-svn: 264409
2016-03-25 14:40:18 +00:00
..
BitCodes.h
BitcodeWriterPass.h [ThinLTO] Renaming of function index to module summary index (NFC) 2016-03-15 00:04:37 +00:00
BitstreamReader.h
BitstreamWriter.h
LLVMBitCodes.h Bitcode: Collect all MDString records into a single blob 2016-03-25 14:40:18 +00:00
ReaderWriter.h [ThinLTO] Renaming of function index to module summary index (NFC) 2016-03-15 00:04:37 +00:00