Re: [PATCH] fs: seq_file: optimize seq_pad()

2014-09-10 Thread Dmitry Voytik
On Wed, Sep 10, 2014 at 5:21 PM, Al Viro wrote: > On Wed, Sep 10, 2014 at 01:20:19PM +0400, Dmitry Voytik wrote: >> Use seq_putc() instead of seq_printf() in seq_pad() because the >> former is faster. > > _Solitary_ seq_putc() is certainly going to be faster, but that loop... > Do you have profili

Re: [PATCH] fs: seq_file: optimize seq_pad()

2014-09-10 Thread Al Viro
On Wed, Sep 10, 2014 at 01:20:19PM +0400, Dmitry Voytik wrote: > Use seq_putc() instead of seq_printf() in seq_pad() because the > former is faster. _Solitary_ seq_putc() is certainly going to be faster, but that loop... Do you have profiling results, or is it just an apriori "printf must be slooo

[PATCH] fs: seq_file: optimize seq_pad()

2014-09-10 Thread Dmitry Voytik
Use seq_putc() instead of seq_printf() in seq_pad() because the former is faster. Signed-off-by: Dmitry Voytik --- fs/seq_file.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/fs/seq_file.c b/fs/seq_file.c index 3857b72..fef338e 100644 --- a/fs/seq_file.c +++ b/fs/seq_