SuccessChanges

Summary

  1. Use zu rather than llu format specifier for size_t (-Wformat warning fix). (details)
  2. debug_rnglists/symbolizing: reduce memory usage by not caching rnglists (details)
  3. Revert "[IRSim] Adding IR Instruction Mapper" (details)
  4. [gn build] Port a895040eb02 (details)
  5. Flush bitcode incrementally for LTO output (details)
  6. Add the header of std::min (details)
  7. Fix the arguments of std::min (details)
  8. [lldb] Return FileSP and StreamFileSP by value in IOHandler (NFC) (details)
Commit c140322819806cb292e079d62f2e9dbab697c08c by echristo
Use zu rather than llu format specifier for size_t (-Wformat warning fix).
The file was modifiedlldb/source/Expression/REPL.cpp
Commit 6a07f1edf8e6a172734286cd3ab5988313313d8f by dblaikie
debug_rnglists/symbolizing: reduce memory usage by not caching rnglists

This matches the debug_ranges behavior - though is currently implemented
differently. (the debug_ranges parsing was handled by creating a new
ranges parser during DIE address querying, and just destroying it after
the query - whereas the rnglists parser is a member of the DWARFUnit
currently - so the API doesn't cache anymore)

I think this could/should be improved by not parsing debug_rnglists
headers at all when dumping debug_info or symbolizing - do it the way
DWARF (roughly) intended: take the rnglists_base, add addr*index to it,
read the offset, parse the list at rnglists_base+offset. This would have
no error checking for valid index (because the number of valid indexes
is stored in the header, which has a negative offset from rnglists_base
- and is sort of only intended for use by dumpers, not by parsers going
from debug_info to a rnglist) or out of contribution bounds access
(since it wouldn't know the length of the contribution, also in the
header) - nor any error-checking that the rnglist contribution was using
the same properties as the debug_info (version, DWARF32/64, address
size, etc).
The file was modifiedllvm/include/llvm/DebugInfo/DWARF/DWARFListTable.h
Commit a895040eb022b8a621d8e85754f113d82e232ab1 by stilis
Revert "[IRSim] Adding IR Instruction Mapper"

This reverts commit b04c1a9d3127730c05e8a22a0e931a12a39528df.
The file was modifiedllvm/lib/Analysis/CMakeLists.txt
The file was modifiedllvm/unittests/Analysis/CMakeLists.txt
The file was removedllvm/lib/Analysis/IRSimilarityIdentifier.cpp
The file was removedllvm/include/llvm/Analysis/IRSimilarityIdentifier.h
The file was removedllvm/unittests/Analysis/IRSimilarityIdentifierTest.cpp
Commit 0dd4d70ec20cebb951bd2e0e6525b056fb8dc86c by llvmgnsyncbot
[gn build] Port a895040eb02
The file was modifiedllvm/utils/gn/secondary/llvm/unittests/Analysis/BUILD.gn
The file was modifiedllvm/utils/gn/secondary/llvm/lib/Analysis/BUILD.gn
Commit 11201315d5881a135faa5aa87f415ce03f99eb96 by jianzhouzh
Flush bitcode incrementally for LTO output

Bitcode writer does not flush buffer until the end by default. This is
fine to small bitcode files. When -flto,--plugin-opt=emit-llvm,-gmlt are
used, the final bitcode file is large, for example, >8G. Keeping all
data in memory consumes a lot of memory.

This change allows bitcode writer flush data to disk early when buffered
data size is above some threshold. This is only enabled when lld emits
LLVM bitcode.

One issue to address is backpatching bitcode: subblock length, function
body indexes, meta data indexes need to backfill. If buffer can be
flushed partially, we introduced raw_fd_stream that supports
read/seek/write, and enables backpatching bitcode flushed in disk.

Reviewed-by: tejohnson, MaskRay

Differential Revision: https://reviews.llvm.org/D86905
The file was modifiedllvm/include/llvm/Bitstream/BitstreamWriter.h
The file was modifiedllvm/lib/Bitcode/Writer/BitcodeWriter.cpp
The file was modifiedllvm/include/llvm/Bitcode/BitcodeWriter.h
The file was modifiedlld/ELF/LTO.cpp
Commit 352a55ef06a9dcb3dfeb45302e9789da24b513c3 by jianzhouzh
Add the header of std::min

fixing
https://github.com/llvm/llvm-project/commit/11201315d5881a135faa5aa87f415ce03f99eb96
The file was modifiedllvm/include/llvm/Bitstream/BitstreamWriter.h
Commit aec80c5cfd1bda8e630fca0f3ed2a84659f68635 by jianzhouzh
Fix the arguments of std::min

fixing
https://github.com/llvm/llvm-project/commit/11201315d5881a135faa5aa87f415ce03f99eb96
The file was modifiedllvm/include/llvm/Bitstream/BitstreamWriter.h
Commit 57dd92746a53526bd7a86c1cfc7c0dce57a2e170 by Jonas Devlieghere
[lldb] Return FileSP and StreamFileSP by value in IOHandler (NFC)

Smart pointers should be returned by value.
The file was modifiedlldb/source/Core/IOHandler.cpp
The file was modifiedlldb/include/lldb/Core/IOHandler.h