[llvm] r201937 - Move get[S|U]LEB128Size() to LEB128.h.
Logan Chien
tzuhsiang.chien at gmail.com
Sat Feb 22 07:51:28 PST 2014
Hi Rafael,
I have changed them to non-inline function in r201939.
I have checked the size of these function on x86_64. It seems that the
size impact are minor. These function only needs 148 bytes and
libLLVMSupport.a has 660379 in its text segment (i.e. the percentage is
0.02224%.)
IMO, I would prefer to put them with encodeSLEB128() because I feel that it
is a more straightforward for the developer to include LEB128.h for
getSLEB128Size() in comparison with some MC layer header.
Sincerely,
Logan
On Sat, Feb 22, 2014 at 10:45 PM, Rafael EspĂndola <
rafael.espindola at gmail.com> wrote:
> > I have changed these functions to inline functions because the existing
> > functions in LEB128.h are inline functions. Besides, these functions are
> > small enough to be inlined. It you have some concern, I can move the
> > function definition to lib/Support/LEB128.cpp.
>
> Please do. Until we know they are hot on some use case it is better to
> have them out of line.
>
> I also worry about Support growing more functionality that is only
> used by a small part of LLVM. How about making this functions in the
> llvm namespace, but implementing them in MC?
>
> Cheers,
> Rafael
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140222/c30a3018/attachment.html>
More information about the llvm-commits
mailing list