Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1582491 > unrolled thread
| Started by | ebiederm@xmission.com (Eric W. Biederman) |
|---|---|
| First post | 2017-02-16 12:40 +0100 |
| Last post | 2017-02-20 07:30 +0100 |
| Articles | 3 — 3 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH v6 1/3] perf: add PERF_RECORD_NAMESPACES to include namespaces related info ebiederm@xmission.com (Eric W. Biederman) - 2017-02-16 12:40 +0100
Re: [PATCH v6 1/3] perf: add PERF_RECORD_NAMESPACES to include namespaces related info Peter Zijlstra <peterz@infradead.org> - 2017-02-16 12:50 +0100
Re: [PATCH v6 1/3] perf: add PERF_RECORD_NAMESPACES to include namespaces related info Hari Bathini <hbathini@linux.vnet.ibm.com> - 2017-02-20 07:30 +0100
| From | ebiederm@xmission.com (Eric W. Biederman) |
|---|---|
| Date | 2017-02-16 12:40 +0100 |
| Subject | Re: [PATCH v6 1/3] perf: add PERF_RECORD_NAMESPACES to include namespaces related info |
| Message-ID | <tbszM-5Ab-11@gated-at.bofh.it> |
> +/*
> + * The maximum size of the name of each namespace
> + */
> +#define NS_NAME_SIZE 8
> +
> +struct perf_ns_link_info {
> + char name[NS_NAME_SIZE];
> + __u64 dev;
> + __u64 ino;
> +};
Ugh. I missed the name the first time around.
That really looks like useless clutter. You already know the index so
the name doesn't add any information, so unless I am missing something
that name will just slow down the perf kernel implementation with
useless work.
The userspace reader can have the information just as reliably by
looking at the index and indexing into a table.
The set of namespaces changes slowly enough that this is not likely to
be a problem in practice. Especially as perf is released with the
kernel.
Plus who knows how long the name of the next namespace is going to be.
Eric
[toc] | [next] | [standalone]
| From | Peter Zijlstra <peterz@infradead.org> |
|---|---|
| Date | 2017-02-16 12:50 +0100 |
| Subject | Re: [PATCH v6 1/3] perf: add PERF_RECORD_NAMESPACES to include namespaces related info |
| Message-ID | <tbsJt-5E4-37@gated-at.bofh.it> |
| In reply to | #1582491 |
On Fri, Feb 17, 2017 at 12:25:27AM +1300, Eric W. Biederman wrote:
> > +/*
> > + * The maximum size of the name of each namespace
> > + */
> > +#define NS_NAME_SIZE 8
> > +
> > +struct perf_ns_link_info {
> > + char name[NS_NAME_SIZE];
> > + __u64 dev;
> > + __u64 ino;
> > +};
>
> Ugh. I missed the name the first time around.
>
> That really looks like useless clutter. You already know the index so
> the name doesn't add any information, so unless I am missing something
> that name will just slow down the perf kernel implementation with
> useless work.
>
> The userspace reader can have the information just as reliably by
> looking at the index and indexing into a table.
>
> The set of namespaces changes slowly enough that this is not likely to
> be a problem in practice. Especially as perf is released with the
> kernel.
Right; Hari, please ditch that name thing.
[toc] | [prev] | [next] | [standalone]
| From | Hari Bathini <hbathini@linux.vnet.ibm.com> |
|---|---|
| Date | 2017-02-20 07:30 +0100 |
| Subject | Re: [PATCH v6 1/3] perf: add PERF_RECORD_NAMESPACES to include namespaces related info |
| Message-ID | <tcPDY-13R-3@gated-at.bofh.it> |
| In reply to | #1582491 |
Hi Eric,
On Thursday 16 February 2017 04:55 PM, Eric W. Biederman wrote:
>> +/*
>> + * The maximum size of the name of each namespace
>> + */
>> +#define NS_NAME_SIZE 8
>> +
>> +struct perf_ns_link_info {
>> + char name[NS_NAME_SIZE];
>> + __u64 dev;
>> + __u64 ino;
>> +};
> Ugh. I missed the name the first time around.
>
> That really looks like useless clutter. You already know the index so
> the name doesn't add any information, so unless I am missing something
> that name will just slow down the perf kernel implementation with
> useless work.
>
> The userspace reader can have the information just as reliably by
> looking at the index and indexing into a table.
>
> The set of namespaces changes slowly enough that this is not likely to
> be a problem in practice. Especially as perf is released with the
> kernel.
>
> Plus who knows how long the name of the next namespace is going to be.
>
Agreed. Will drop name field from the structure and use an indexing
table to get names in userspace..
Thanks
Hari
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web