llvm/lib/Bitcode/Writer
Duncan P. N. Exon Smith d7084fcebd 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.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@264409 91177308-0d34-0410-b5e6-96231b3b80d8
2016-03-25 14:40:18 +00:00
..
BitcodeWriter.cpp Bitcode: Collect all MDString records into a single blob 2016-03-25 14:40:18 +00:00
BitcodeWriterPass.cpp [ThinLTO] Renaming of function index to module summary index (NFC) 2016-03-15 00:04:37 +00:00
BitWriter.cpp Introduce LLVMWriteBitcodeToMemoryBuffer C API function. 2014-10-14 00:30:59 +00:00
CMakeLists.txt modules: Add explicit dependency on intrinsics_gen 2015-06-16 00:44:12 +00:00
LLVMBuild.txt [ThinLTO] Support for reference graph in per-module and combined summary. 2016-03-11 18:52:24 +00:00
ValueEnumerator.cpp Bitcode: Collect all MDString records into a single blob 2016-03-25 14:40:18 +00:00
ValueEnumerator.h Bitcode: Collect all MDString records into a single blob 2016-03-25 14:40:18 +00:00