[PATCH] D33124: [ELF] - Detemplate GnuHashTableSection and SymbolTableSection sections.

Rafael Avila de Espindola via llvm-commits llvm-commits at lists.llvm.org
Mon May 15 07:52:35 PDT 2017


George Rimar <grimar at accesssoftek.com> writes:

>>The wins of being able to remove needles templates far exceeds the cost of and extra class IMHO.
>
>>
>>The write method is the only thing that needs ELFT, so the class is just syntax for holding a function pointer.
>>
>>I am definitely up for suggestions on how to remove these templates some other way, but keeping all this just because of write doesn't look like a good idea.
>>
>>Cheers,
>>Rafael
>
> +1. Total benefit from futher cleanup this allows probably more sensible than a lose from little class that was added.

D33153 has a good example. I initially detemplated .got in a similar way
to this change. With that not being a template, the relocation
processing could be detemplated, and that in turn allows for the
GotBaseSection to be removed.

It is just hard to see all the cases where we have templated code just
because it cyclically uses templated code.

Cheers,
Rafael


More information about the llvm-commits mailing list