<div dir="ltr">Thank you for finding this out. Fixed in r248526.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Sep 22, 2015 at 12:50 AM, Denis Protivensky via llvm-commits <span dir="ltr"><<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
On 09/21/2015 10:41 PM, Rui Ueyama via llvm-commits wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Author: ruiu<br>
Date: Mon Sep 21 14:41:38 2015<br>
New Revision: 248202<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=248202&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=248202&view=rev</a><br>
Log:<br>
COFF: Improve section hash value.<br>
<br>
std::distance(C->Relocs.end(), C->Relocs.begin()) is the same as NumRelocs<br>
which is already added to the hash value. What we are missing here is the<br>
section size.<br>
<br>
Modified:<br>
     lld/trunk/COFF/ICF.cpp<br>
<br>
Modified: lld/trunk/COFF/ICF.cpp<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/ICF.cpp?rev=248202&r1=248201&r2=248202&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/ICF.cpp?rev=248202&r1=248201&r2=248202&view=diff</a><br>
==============================================================================<br>
--- lld/trunk/COFF/ICF.cpp (original)<br>
+++ lld/trunk/COFF/ICF.cpp Mon Sep 21 14:41:38 2015<br>
@@ -86,7 +86,7 @@ uint64_t ICF::getHash(SectionChunk *C) {<br>
                        hash_value(C->SectionName),<br>
                        C->NumRelocs,<br>
                        uint32_t(C->Header->SizeOfRawData),<br>
-                      std::distance(C->Relocs.end(), C->Relocs.begin()),<br>
+                      uint32_t(C->Header->SizeOfRawData),<br>
</blockquote></span>
Is that correct that you now use the same value twice (the first is above the deleted line)?<div class="HOEnZb"><div class="h5"><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
                        C->Checksum);<br>
  }<br>
  <br>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits</a><br>
</blockquote>
<br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits</a><br>
</div></div></blockquote></div><br></div>