[lkml]   [2018]   [Sep]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFCv2 00/48] perf tools: Add threads to record command

* Namhyung Kim <> wrote:

> > > The stays as a single file.
> I'm not sure we really need to keep it as a single file. As it's a
> kind of big changes, we might consider breaking compatibility and use
> a directory structure.

Agreed - and to make use of the highly scalable Linux VFS implementation we should
attempt to use per CPU file resources as well.

Any cross-CPU contention should stick out like a sore thumb.

> > There is usage of Posix threading API but there is no
> > its implementation in the patch series, to avoid dependency
> > on externally coded designs in the core of the tool.
> Do you mean it needs to implement its own threading? I don't think
> that's what Ingo wanted to.

Yeah, I didn't mean that: every libc hoping to work on Linux implements a pthread API, plus the
pthread APIs we are using are really just narrow wrappers on top of system calls that were
written with libc pthread APIs in mind. So it's not a problem to rely on pthreads.h. (And if we
have trouble with any particular pthread detail we can single out specific functionality and
not use it or use our own implementation.)

The AIO library is another matter: it's a family of interfaces with complex libc specific
design choices that cannot be influenced.

I.e. my suggestion was to keep using pthreads APIs like we do today, but not use the libc AIO
library. Not because there's any problem with glibc AIO: but because basic event flow is a core
competency of perf that we want to implement ourselves.

Is this clearer?



 \ /
  Last update: 2018-09-14 11:34    [W:0.127 / U:0.248 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site