All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mike Snitzer <snitzer@redhat.com>
To: Eric Wheeler <ewheeler@ewheeler.net>
Cc: axboe@kernel.dk, dm-devel@redhat.com, ejt@redhat.com,
	LVM2 development <lvm-devel@redhat.com>
Subject: Re: dm thin: optimize away writing all zeroes to unprovisioned blocks
Date: Fri, 5 Dec 2014 09:47:39 -0500	[thread overview]
Message-ID: <20141205144739.GA26356@redhat.com> (raw)
In-Reply-To: <20141204153358.GA19315@redhat.com>

On Thu, Dec 04 2014 at 10:33am -0500,
Mike Snitzer <snitzer@redhat.com> wrote:

> From: Mike Snitzer <snitzer@redhat.com>
> Date: Thu, 4 Dec 2014 10:18:32 -0500
> Subject: [PATCH] dm thin: optimize away writing all zeroes to unprovisioned blocks
> 
> Introduce bio_is_zero_filled() and use it to optimize away writing all
> zeroes to unprovisioned blocks.  Subsequent reads to the associated
> unprovisioned blocks will be zero filled.
> 
> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
> Cc: Eric Wheeler <ewheeler@ewheeler.net>
> Cc: Jens Axboe <axboe@kernel.dk>

In testing this patch it is now quite clear that this change seriously
impacts test coverage in the device-mapper-test-suite because dmts'
wipe_device() uses /dev/zero as the ifile for dd to write to the disk.
As such, with this patch all tests expecting to see provisioned blocks
as a side-effect of wipe_device now fail (e.g. DiscardQuickTests).

So this change won't go upstream until full test coverage can be
restored in dmts.  I'll see what I can come up with but it is low
priority.

BTW, this also makes me wonder if this change will be extremely
unintuitive to existing or future user of DM thinp.  So much so that it
might be best to require a new thin-pool feature flag to enable this
optimization.

Mike

--
lvm-devel mailing list
lvm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/lvm-devel

WARNING: multiple messages have this Message-ID (diff)
From: Mike Snitzer <snitzer@redhat.com>
To: lvm-devel@redhat.com
Subject: dm thin: optimize away writing all zeroes to unprovisioned blocks
Date: Fri, 5 Dec 2014 09:47:39 -0500	[thread overview]
Message-ID: <20141205144739.GA26356@redhat.com> (raw)
In-Reply-To: <20141204153358.GA19315@redhat.com>

On Thu, Dec 04 2014 at 10:33am -0500,
Mike Snitzer <snitzer@redhat.com> wrote:

> From: Mike Snitzer <snitzer@redhat.com>
> Date: Thu, 4 Dec 2014 10:18:32 -0500
> Subject: [PATCH] dm thin: optimize away writing all zeroes to unprovisioned blocks
> 
> Introduce bio_is_zero_filled() and use it to optimize away writing all
> zeroes to unprovisioned blocks.  Subsequent reads to the associated
> unprovisioned blocks will be zero filled.
> 
> Signed-off-by: Mike Snitzer <snitzer@redhat.com>
> Cc: Eric Wheeler <ewheeler@ewheeler.net>
> Cc: Jens Axboe <axboe@kernel.dk>

In testing this patch it is now quite clear that this change seriously
impacts test coverage in the device-mapper-test-suite because dmts'
wipe_device() uses /dev/zero as the ifile for dd to write to the disk.
As such, with this patch all tests expecting to see provisioned blocks
as a side-effect of wipe_device now fail (e.g. DiscardQuickTests).

So this change won't go upstream until full test coverage can be
restored in dmts.  I'll see what I can come up with but it is low
priority.

BTW, this also makes me wonder if this change will be extremely
unintuitive to existing or future user of DM thinp.  So much so that it
might be best to require a new thin-pool feature flag to enable this
optimization.

Mike



  parent reply	other threads:[~2014-12-05 14:47 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-30 18:38 dm-thinp feature request: skip allocation on writes of all zeroes Eric Wheeler
2014-09-30 19:30 ` Zdenek Kabelac
2014-09-30 20:13 ` Mike Snitzer
2014-09-30 22:38   ` Eric Wheeler
2014-12-04  7:05 ` [PATCH] dm-thinp: skip allocation on writes of all zeros to unallocated blocks Eric Wheeler
2014-12-04  7:25   ` Eric Wheeler
2014-12-04 15:33     ` [PATCH] dm thin: optimize away writing all zeroes to unprovisioned blocks Mike Snitzer
2014-12-04 15:33       ` Mike Snitzer
2014-12-04 15:43       ` Mike Snitzer
2014-12-04 15:43         ` Mike Snitzer
2014-12-06 22:33         ` Eric Wheeler
2014-12-06 22:33           ` Eric Wheeler
2014-12-05 14:47       ` Mike Snitzer [this message]
2014-12-05 14:47         ` Mike Snitzer
2014-12-06 22:36         ` Eric Wheeler
2014-12-06 22:36           ` Eric Wheeler
2014-12-05 17:27       ` [PATCH] " Jens Axboe
2014-12-05 17:27         ` Jens Axboe
2014-12-05 18:33         ` Mike Snitzer
2014-12-05 18:33           ` Mike Snitzer
2014-12-06 22:40           ` Eric Wheeler
2014-12-06 22:40             ` Eric Wheeler
2014-12-07  1:41             ` [lvm-devel] " Jens Axboe
2014-12-07  1:41               ` Jens Axboe
2014-12-07  6:30               ` Eric Wheeler
2014-12-07  6:30                 ` Eric Wheeler
2014-12-07  6:45                 ` Eric Wheeler
2014-12-07  6:45                   ` Eric Wheeler
2014-12-08 16:57                 ` [lvm-devel] " Jens Axboe
2014-12-08 16:57                   ` Jens Axboe
2014-12-09  8:02                   ` Eric Wheeler
2014-12-09  8:02                     ` Eric Wheeler
2014-12-09 15:31                     ` [lvm-devel] " Jens Axboe
2014-12-09 15:31                       ` Jens Axboe
2014-12-09 15:41                       ` [lvm-devel] " Jens Axboe
2014-12-09 15:41                         ` Jens Axboe
2014-12-10  2:52                         ` [PATCH] " Eric Wheeler
2014-12-10  2:52                           ` Eric Wheeler
2015-01-26  2:53                       ` Eric Wheeler
2015-01-26  2:53                         ` Eric Wheeler
2015-02-15  0:31                         ` [lvm-devel] " Eric Wheeler
2015-02-15  0:31                           ` Eric Wheeler
2014-12-09 14:38                   ` Marian Csontos
2014-12-09 14:38                     ` Marian Csontos
2014-12-07  1:36           ` Jens Axboe
2014-12-07  1:36             ` Jens Axboe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20141205144739.GA26356@redhat.com \
    --to=snitzer@redhat.com \
    --cc=axboe@kernel.dk \
    --cc=dm-devel@redhat.com \
    --cc=ejt@redhat.com \
    --cc=ewheeler@ewheeler.net \
    --cc=lvm-devel@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.