[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [dm-devel] [PATCH] PROBLEM: SSD access time with dm-crypt is way too high



On 01/10/2011 06:19 PM, Mikulas Patocka wrote:
> Try this patch. I coded it long time ago, but it was forgotten somehow.

No, it was not forgotten, I just do not like this approach :)

> +  	/*
> +	 * The last io submitted to io_queue and crypt_queue.
> +	 * This pointers are not protected by any locks and thus must not be
> +	 * dereferenced --- they may contain garbage. The only allowed operation
> +	 * is to compare these pointers with current io being processed. If they
> +	 * match, the block device queue should be unplugged.
> +	 */
> +	struct dm_crypt_io *io_queue_last_io;
> +	struct dm_crypt_io *crypt_queue_last_io;

We can now process ios in parallel on different CPUs, that code will
rewrite the context struct on every IO and at least it will cause cache bouncing.
(it will not apply on current code anyway, see patches in linux-next)

And I think it can kill performance is some cases (if the requests are submitted
such way that you will call unplug after every io.)

We need something clever here - I wonder if fixing the reverted fb1e753 can
help here....

Milan


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]