[PATCH] D17529: ELF: Implement ICF.

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 24 09:53:22 PST 2016


ruiu added inline comments.

================
Comment at: ELF/ICF.cpp:168
@@ +167,3 @@
+                          Comparator Eq) {
+  // This loop sorts [Begin, End) so that all sections that are equal
+  // in terms of Eq are contiguous. The algorithm is quadratic
----------------
silvas wrote:
> I would say "rearranges" instead of "sorts", since "sort" implies an absolute order.
Done.

================
Comment at: ELF/ICF.cpp:169
@@ +168,3 @@
+  // This loop sorts [Begin, End) so that all sections that are equal
+  // in terms of Eq are contiguous. The algorithm is quadratic
+  // in the worse case, but that is not an issue in practice because
----------------
silvas wrote:
> I think it is worth clarifying that it is quadratic in the number of *distinct* sections.
Done.


http://reviews.llvm.org/D17529





More information about the llvm-commits mailing list