[PATCH] D44847: [profile] Fix value profile runtime merging issues

Rong Xu via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 30 13:49:23 PDT 2018


I checked the assembly in
clang_rt.profile-i386.dir/  and
clang_rt.profile-x86_64.dir/

Both are inlined.

On Fri, Mar 30, 2018 at 1:43 PM David Li via Phabricator <
reviews at reviews.llvm.org> wrote:

> davidxl added inline comments.
>
>
> ================
> Comment at: lib/profile/InstrProfilingValue.c:138
>                                   uint32_t CounterIndex) {
> +  __llvm_profile_instrument_target_value(TargetValue, Data, CounterIndex,
> 1);
> +
> ----------------
> Is this call getting inlined in the library build? If not, it will
> introduce unnecessary overhead.
>
> One way to avoid this is to define a static always inline function, and
> then make the two APIs as wrappers to that common function.
>
>
> https://reviews.llvm.org/D44847
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180330/213a2a17/attachment.html>


More information about the llvm-commits mailing list