linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* seq_put_decimal_ull() et al
@ 2012-03-13 13:35 Alexey Dobriyan
  2012-03-13 13:41 ` Alexey Dobriyan
  2012-03-14  0:31 ` KAMEZAWA Hiroyuki
  0 siblings, 2 replies; 7+ messages in thread
From: Alexey Dobriyan @ 2012-03-13 13:35 UTC (permalink / raw)
  To: Andrew Morton, KAMEZAWA Hiroyuki; +Cc: Linux Kernel, Eric Dumazet

> Subject:    + procfs-add-num_to_str-to-speed-up-proc-stat-fix-2.patch added to -mm tree

I think the fix is to create proper binary interface for exporting
interrupt counts.
Programs can parse raw data equally well if programming language is
even minimally reasonable
(POSIX shell may not qualify, though).

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: seq_put_decimal_ull() et al
  2012-03-13 13:35 seq_put_decimal_ull() et al Alexey Dobriyan
@ 2012-03-13 13:41 ` Alexey Dobriyan
  2012-03-14  0:31 ` KAMEZAWA Hiroyuki
  1 sibling, 0 replies; 7+ messages in thread
From: Alexey Dobriyan @ 2012-03-13 13:41 UTC (permalink / raw)
  To: Andrew Morton, KAMEZAWA Hiroyuki; +Cc: Linux Kernel, Eric Dumazet

On Tue, Mar 13, 2012 at 4:35 PM, Alexey Dobriyan <adobriyan@gmail.com> wrote:
>> Subject:    + procfs-add-num_to_str-to-speed-up-proc-stat-fix-2.patch added to -mm tree
>
> I think the fix is to create proper binary interface for exporting
> interrupt counts.
> Programs can parse raw data equally well if programming language is
> even minimally reasonable
> (POSIX shell may not qualify, though).

Ugh, I meant a file with binary data, not complete fileless interface.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: seq_put_decimal_ull() et al
  2012-03-13 13:35 seq_put_decimal_ull() et al Alexey Dobriyan
  2012-03-13 13:41 ` Alexey Dobriyan
@ 2012-03-14  0:31 ` KAMEZAWA Hiroyuki
  2012-03-14  2:08   ` KAMEZAWA Hiroyuki
  1 sibling, 1 reply; 7+ messages in thread
From: KAMEZAWA Hiroyuki @ 2012-03-14  0:31 UTC (permalink / raw)
  To: Alexey Dobriyan; +Cc: Andrew Morton, Linux Kernel, Eric Dumazet

On Tue, 13 Mar 2012 15:35:54 +0200
Alexey Dobriyan <adobriyan@gmail.com> wrote:

> > Subject:    + procfs-add-num_to_str-to-speed-up-proc-stat-fix-2.patch added to -mm tree
> 
> I think the fix is to create proper binary interface for exporting
> interrupt counts.
> Programs can parse raw data equally well if programming language is
> even minimally reasonable
> (POSIX shell may not qualify, though).

Ok, please try with all tool-chain updates.
procps, top, sar, and more ?


Thanks,
-Kame


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: seq_put_decimal_ull() et al
  2012-03-14  0:31 ` KAMEZAWA Hiroyuki
@ 2012-03-14  2:08   ` KAMEZAWA Hiroyuki
  2012-03-16 11:16     ` Alexey Dobriyan
  0 siblings, 1 reply; 7+ messages in thread
From: KAMEZAWA Hiroyuki @ 2012-03-14  2:08 UTC (permalink / raw)
  To: KAMEZAWA Hiroyuki
  Cc: Alexey Dobriyan, Andrew Morton, Linux Kernel, Eric Dumazet

On Wed, 14 Mar 2012 09:31:56 +0900
KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:

> On Tue, 13 Mar 2012 15:35:54 +0200
> Alexey Dobriyan <adobriyan@gmail.com> wrote:
> 
> > > Subject:    + procfs-add-num_to_str-to-speed-up-proc-stat-fix-2.patch added to -mm tree
> > 
> > I think the fix is to create proper binary interface for exporting
> > interrupt counts.
> > Programs can parse raw data equally well if programming language is
> > even minimally reasonable
> > (POSIX shell may not qualify, though).
> 
> Ok, please try with all tool-chain updates.
> procps, top, sar, and more ?
> 
One concern is maintainance of 2 files of the same data.

Thanks,
-Kame


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: seq_put_decimal_ull() et al
  2012-03-14  2:08   ` KAMEZAWA Hiroyuki
@ 2012-03-16 11:16     ` Alexey Dobriyan
  2012-03-19  0:29       ` KAMEZAWA Hiroyuki
  0 siblings, 1 reply; 7+ messages in thread
From: Alexey Dobriyan @ 2012-03-16 11:16 UTC (permalink / raw)
  To: KAMEZAWA Hiroyuki; +Cc: Andrew Morton, Linux Kernel, Eric Dumazet

On Wed, Mar 14, 2012 at 5:08 AM, KAMEZAWA Hiroyuki
<kamezawa.hiroyu@jp.fujitsu.com> wrote:
> On Wed, 14 Mar 2012 09:31:56 +0900
> KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
>
>> On Tue, 13 Mar 2012 15:35:54 +0200
>> Alexey Dobriyan <adobriyan@gmail.com> wrote:
>>
>> > > Subject:    + procfs-add-num_to_str-to-speed-up-proc-stat-fix-2.patch added to -mm tree
>> >
>> > I think the fix is to create proper binary interface for exporting
>> > interrupt counts.
>> > Programs can parse raw data equally well if programming language is
>> > even minimally reasonable
>> > (POSIX shell may not qualify, though).
>>
>> Ok, please try with all tool-chain updates.
>> procps, top, sar, and more ?
>>

Well, why not?
We can tune print code or we can create maximally fast interface and forget.

> One concern is maintainance of 2 files of the same data.

The other is all those multiplying print functions.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: seq_put_decimal_ull() et al
  2012-03-16 11:16     ` Alexey Dobriyan
@ 2012-03-19  0:29       ` KAMEZAWA Hiroyuki
  2012-03-19 12:53         ` Alexey Dobriyan
  0 siblings, 1 reply; 7+ messages in thread
From: KAMEZAWA Hiroyuki @ 2012-03-19  0:29 UTC (permalink / raw)
  To: Alexey Dobriyan; +Cc: Andrew Morton, Linux Kernel, Eric Dumazet

(2012/03/16 20:16), Alexey Dobriyan wrote:

> On Wed, Mar 14, 2012 at 5:08 AM, KAMEZAWA Hiroyuki
> <kamezawa.hiroyu@jp.fujitsu.com> wrote:
>> On Wed, 14 Mar 2012 09:31:56 +0900
>> KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
>>
>>> On Tue, 13 Mar 2012 15:35:54 +0200
>>> Alexey Dobriyan <adobriyan@gmail.com> wrote:
>>>
>>>>> Subject:    + procfs-add-num_to_str-to-speed-up-proc-stat-fix-2.patch added to -mm tree
>>>>
>>>> I think the fix is to create proper binary interface for exporting
>>>> interrupt counts.
>>>> Programs can parse raw data equally well if programming language is
>>>> even minimally reasonable
>>>> (POSIX shell may not qualify, though).
>>>
>>> Ok, please try with all tool-chain updates.
>>> procps, top, sar, and more ?
>>>
> 
> Well, why not?
> We can tune print code or we can create maximally fast interface and forget.
> 

Do you have an idea where to place it ? 
/proc/stat_binary ?
/proc/binary/stat ?

Hm, to parse /proc/stat binary format, the user has to know the format of the
kernel version.

Do we show a format file as
/proc/binary/stat_format and show
# cat /proc/binary/stat_format
  =IHHHIHIQQQIHQQ...

as python's pack/unpack ? or
export the format via /usr/include/linux/proc_format.h ? as a structure ?

any better idea ?

Thanks,
-Kame








^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: seq_put_decimal_ull() et al
  2012-03-19  0:29       ` KAMEZAWA Hiroyuki
@ 2012-03-19 12:53         ` Alexey Dobriyan
  0 siblings, 0 replies; 7+ messages in thread
From: Alexey Dobriyan @ 2012-03-19 12:53 UTC (permalink / raw)
  To: KAMEZAWA Hiroyuki; +Cc: Andrew Morton, Linux Kernel, Eric Dumazet

On Mon, Mar 19, 2012 at 3:29 AM, KAMEZAWA Hiroyuki
<kamezawa.hiroyu@jp.fujitsu.com> wrote:
> (2012/03/16 20:16), Alexey Dobriyan wrote:
>
>> On Wed, Mar 14, 2012 at 5:08 AM, KAMEZAWA Hiroyuki
>> <kamezawa.hiroyu@jp.fujitsu.com> wrote:
>>> On Wed, 14 Mar 2012 09:31:56 +0900
>>> KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> wrote:
>>>
>>>> On Tue, 13 Mar 2012 15:35:54 +0200
>>>> Alexey Dobriyan <adobriyan@gmail.com> wrote:
>>>>
>>>>>> Subject:    + procfs-add-num_to_str-to-speed-up-proc-stat-fix-2.patch added to -mm tree
>>>>>
>>>>> I think the fix is to create proper binary interface for exporting
>>>>> interrupt counts.
>>>>> Programs can parse raw data equally well if programming language is
>>>>> even minimally reasonable
>>>>> (POSIX shell may not qualify, though).
>>>>
>>>> Ok, please try with all tool-chain updates.
>>>> procps, top, sar, and more ?
>>>>
>>
>> Well, why not?
>> We can tune print code or we can create maximally fast interface and forget.
>>
>
> Do you have an idea where to place it ?
> /proc/stat_binary ?
> /proc/binary/stat ?
>
> Hm, to parse /proc/stat binary format, the user has to know the format of the
> kernel version.
>
> Do we show a format file as
> /proc/binary/stat_format and show
> # cat /proc/binary/stat_format
>  =IHHHIHIQQQIHQQ...
>
> as python's pack/unpack ? or
> export the format via /usr/include/linux/proc_format.h ? as a structure ?
>
> any better idea ?

I'm thinking of separate file with interrupts statistics. Let's not
mix everything.
Hmm, let me see how top(1) parses /proc/interrupts.

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-03-19 12:53 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-13 13:35 seq_put_decimal_ull() et al Alexey Dobriyan
2012-03-13 13:41 ` Alexey Dobriyan
2012-03-14  0:31 ` KAMEZAWA Hiroyuki
2012-03-14  2:08   ` KAMEZAWA Hiroyuki
2012-03-16 11:16     ` Alexey Dobriyan
2012-03-19  0:29       ` KAMEZAWA Hiroyuki
2012-03-19 12:53         ` Alexey Dobriyan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).