Re: [PATCH v2 6/8] kvm tools: Add rwlock wrapper

Ingo Molnar
2011-05-30T19:33:14Z

* Avi Kivity <avi@redhat.com> wrote:

> > Also, a profile of a typical kernel build shows:
> >
> > 0.69% cc1 [kernel.kallsyms] [k] clear_page_c
> > 0.49% cc1 [kernel.kallsyms] [k] page_fault
> >
> > So while we could improve it, the question is, can we do this without
> > accidentally slowing things down by more than 0.69%? And kernel
> > builds are a pretty clear_page_c() intense workload.
>
> I usually see much higher clear_page_c, but I'm using a pretty old
> system for most of my testing.

Well, clear_page_c() is still the most expensive kernel function.

I'd suggest using a modern system *and* using percise PEBS profiling
via perf record -e cycles:pp - otherwise it's easy to see profiling
artifacts, especially in and around short functions like
clear_page_c().

Thanks,

Ingo