[PATCH] D14053: Optimize StringTableBuilder

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 26 13:31:46 PDT 2015


On Mon, Oct 26, 2015 at 1:21 PM, Jim Grosbach <grosbach at apple.com> wrote:

> grosbach added a subscriber: grosbach.
> grosbach added a comment.
>
> Cool. AFAIK, the only reason for the array_pod_sort() before was "seems
> good enough for now."
>
>
> ================
> Comment at: lib/MC/StringTableBuilder.cpp:33
> @@ +32,3 @@
> +// because it does not compare characters that we already know the same.
> +static void qsort(StringPair **Begin, StringPair **End, int Pos) {
> +tailcall:
> ----------------
> Can we use a different name? Function names that collide with the C
> standard library are bountiful opportunities for confusion later.
>

Sure.


>
> Relatedly, perhaps this helper function, or a generalized version of it,
> should go into STLExtras.h next to array_pod_sort?
>

That's a good idea. I'll send a code review to you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151026/20183115/attachment.html>


More information about the llvm-commits mailing list