[PATCH] D48541: [Bitcode, Type] Assign deterministic IDs to unnamed types at creation time.

Florian Hahn via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 5 05:47:40 PDT 2018


fhahn updated this revision to Diff 154211.
fhahn retitled this revision from "[Function] Use deterministic IDs when mangling unnamed types." to "[Bitcode, Type] Assign deterministic IDs to unnamed types at creation time.".
fhahn edited the summary of this revision.
fhahn added a reviewer: reames.
fhahn added a comment.

I've updated the patch to generate the IDs for unnamed types at creation time and also updated the bitcode writer to write the unamed types first, in the order they were created. This way, the IDs matche between serializing and de-serializing.

This change changes the order types are written to the bytecode file, but that should be a backwards compatible change, because the order only affects mangling with this patch.


https://reviews.llvm.org/D48541

Files:
  include/llvm/IR/Type.h
  lib/Bitcode/Writer/ValueEnumerator.cpp
  lib/IR/Function.cpp
  lib/IR/LLVMContextImpl.h
  lib/IR/Type.cpp
  test/Bitcode/intrinsics-with-unnamed-types.ll
  test/Transforms/Util/PredicateInfo/unnamed-types.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D48541.154211.patch
Type: text/x-patch
Size: 6317 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180705/a36cffeb/attachment.bin>


More information about the llvm-commits mailing list