Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1410256 > unrolled thread

Re: [PATCH v2 0/8] zram: switch to crypto api

Started bySergey Senozhatsky <sergey.senozhatsky@gmail.com>
First post2016-05-31 14:30 +0200
Last post2016-06-01 03:00 +0200
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.


Contents

  Re: [PATCH v2 0/8] zram: switch to crypto api Sergey Senozhatsky <sergey.senozhatsky@gmail.com> - 2016-05-31 14:30 +0200
    Re: [PATCH v2 0/8] zram: switch to crypto api Andrew Morton <akpm@linux-foundation.org> - 2016-05-31 21:10 +0200
      Re: [PATCH v2 0/8] zram: switch to crypto api Sergey Senozhatsky <sergey.senozhatsky.work@gmail.com> - 2016-06-01 03:00 +0200

#1410256 — Re: [PATCH v2 0/8] zram: switch to crypto api

FromSergey Senozhatsky <sergey.senozhatsky@gmail.com>
Date2016-05-31 14:30 +0200
SubjectRe: [PATCH v2 0/8] zram: switch to crypto api
Message-ID<rEQY3-2DM-41@gated-at.bofh.it>
On (05/31/16 21:20), Sergey Senozhatsky wrote:
>   This has started as a 'add zlib support' work, but after some
> thinking I saw no blockers for a bigger change -- a switch to
> crypto API.
> 
>   We don't have an idle zstreams list anymore and our write path
> now works absolutely differently, preventing preemption during
> compression. This removes possibilities of read paths preempting
> writes at wrong places and opens the door for a move from custom
> LZO/LZ4 compression backends implementation to a more generic one,
> using crypto compress API.
> 
>   This patch set also eliminates the need of a new context-less
> crypto API interface, which was quite hard to sell, so we can
> move along faster.

forgot to attach some benchmarks:

(x86_64, 4GB, zram-perf script)

perf reported run-time fio (max jobs=3)

test-fio-zram-842
     197.907655282 seconds time elapsed
     201.623142884 seconds time elapsed
     226.854291345 seconds time elapsed
test-fio-zram-DEFLATE
     253.259516155 seconds time elapsed
     258.148563401 seconds time elapsed
     290.251909365 seconds time elapsed
test-fio-zram-LZ4
      27.022598717 seconds time elapsed
      29.580522717 seconds time elapsed
      33.293463430 seconds time elapsed
test-fio-zram-LZ4HC
      56.393954615 seconds time elapsed
      74.904659747 seconds time elapsed
     101.940998564 seconds time elapsed
test-fio-zram-LZO
      28.155948075 seconds time elapsed
      30.390036330 seconds time elapsed
      34.455773159 seconds time elapsed


zram mm_stat-s (max fio jobs=3)

test-fio-zram-842
mm_stat (jobs1): 3221225472 673185792 690266112        0 690266112        0        0
mm_stat (jobs2): 3221225472 673185792 690266112        0 690266112        0        0
mm_stat (jobs3): 3221225472 673185792 690266112        0 690266112        0        0
test-fio-zram-DEFLATE
mm_stat (jobs1): 3221225472  24379392  37761024        0  37761024        0        0
mm_stat (jobs2): 3221225472  24379392  37761024        0  37761024        0        0
mm_stat (jobs3): 3221225472  24379392  37761024        0  37761024        0        0
test-fio-zram-LZ4
mm_stat (jobs1): 3221225472  23592960  37761024        0  37761024        0        0
mm_stat (jobs2): 3221225472  23592960  37761024        0  37761024        0        0
mm_stat (jobs3): 3221225472  23592960  37761024        0  37761024        0        0
test-fio-zram-LZ4HC
mm_stat (jobs1): 3221225472  23592960  37761024        0  37761024        0        0
mm_stat (jobs2): 3221225472  23592960  37761024        0  37761024        0        0
mm_stat (jobs3): 3221225472  23592960  37761024        0  37761024        0        0
test-fio-zram-LZO
mm_stat (jobs1): 3221225472  34603008  50335744        0  50335744        0        0
mm_stat (jobs2): 3221225472  34603008  50335744        0  50335744        0        0
mm_stat (jobs3): 3221225472  34603008  50335744        0  50339840        0        0


	-ss

[toc] | [next] | [standalone]


#1410546

FromAndrew Morton <akpm@linux-foundation.org>
Date2016-05-31 21:10 +0200
Message-ID<rEXd7-6Ej-9@gated-at.bofh.it>
In reply to#1410256
On Tue, 31 May 2016 21:29:18 +0900 Sergey Senozhatsky <sergey.senozhatsky@gmail.com> wrote:

> forgot to attach some benchmarks:
> 
> (x86_64, 4GB, zram-perf script)
> 
> perf reported run-time fio (max jobs=3)
> 
> test-fio-zram-842
>      197.907655282 seconds time elapsed
>      201.623142884 seconds time elapsed
>      226.854291345 seconds time elapsed
> test-fio-zram-DEFLATE
>      253.259516155 seconds time elapsed
>      258.148563401 seconds time elapsed
>      290.251909365 seconds time elapsed
> test-fio-zram-LZ4
>       27.022598717 seconds time elapsed
>       29.580522717 seconds time elapsed
>       33.293463430 seconds time elapsed
> test-fio-zram-LZ4HC
>       56.393954615 seconds time elapsed
>       74.904659747 seconds time elapsed
>      101.940998564 seconds time elapsed
> test-fio-zram-LZO
>       28.155948075 seconds time elapsed
>       30.390036330 seconds time elapsed
>       34.455773159 seconds time elapsed

I'm having trouble understanding the benchmark results.  What is being
compared to what and which was faster and how much?

[toc] | [prev] | [next] | [standalone]


#1410710

FromSergey Senozhatsky <sergey.senozhatsky.work@gmail.com>
Date2016-06-01 03:00 +0200
Message-ID<rF2FP-1kF-3@gated-at.bofh.it>
In reply to#1410546
On (05/31/16 12:07), Andrew Morton wrote:
> > test-fio-zram-842
> >      197.907655282 seconds time elapsed
> >      201.623142884 seconds time elapsed
> >      226.854291345 seconds time elapsed
> > test-fio-zram-DEFLATE
> >      253.259516155 seconds time elapsed
> >      258.148563401 seconds time elapsed
> >      290.251909365 seconds time elapsed
> > test-fio-zram-LZ4
> >       27.022598717 seconds time elapsed
> >       29.580522717 seconds time elapsed
> >       33.293463430 seconds time elapsed
> > test-fio-zram-LZ4HC
> >       56.393954615 seconds time elapsed
> >       74.904659747 seconds time elapsed
> >      101.940998564 seconds time elapsed
> > test-fio-zram-LZO
> >       28.155948075 seconds time elapsed
> >       30.390036330 seconds time elapsed
> >       34.455773159 seconds time elapsed
> 
> I'm having trouble understanding the benchmark results.  What is being
> compared to what and which was faster and how much?

Hello,

'benchmarking' was probably a bit too strong word to use here. basically,
I performed fio test with the increasing number of parallel jobs (max to 3)
on a 3G zram device, using `static' data and the following crypto comp
algorithms:
	842, deflate, lz4, lz4hc, lzo

the output was:
 - test running time (which can tell us what algorithms performs faster)
and
 - zram mm_stat (which tells the compressed memory size, max used memory, etc).

it's just for information. for example, LZ4HC has twice the running time
of LZO, but the compressed memory size is: 23592960 vs 34603008 bytes.

	-ss

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web