[PATCH] D63232: [Coverage] Load code coverage data from archives

Max Moroz via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 13 10:34:50 PDT 2019


Dor1s accepted this revision.
Dor1s added a comment.

Thanks for the replies, Vedant. Still LGTM!



================
Comment at: llvm/lib/ProfileData/Coverage/CoverageMappingReader.cpp:597
+    if (Error E =
+            readCoverageMappingData<uint32_t, support::endianness::little>(
+                Reader->ProfileNames, Coverage, Reader->MappingRecords,
----------------
vsk wrote:
> Dor1s wrote:
> > I think we can make it a bit more concise (2 branches instead of 4) by passing `Endian` as a template parameter. May need a separate check though to make sure it's either `support::endianness::little` or `support::endianness::big`.
> As 'Endian' is not a constant-expression, I don't think it's possible to pass it in as a template parameter. I think it could be passed as a regular parameter, but that would eliminate two branches here while adding two branches to 'readCoverageMappingData'.
Ah, good point, my bad!


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D63232/new/

https://reviews.llvm.org/D63232





More information about the llvm-commits mailing list