On Wed, Jun 27, 2018 at 4:03 PM, Dan Williams <dan.j.williams@xxxxxxxxx> wrote: > On Wed, Jun 27, 2018 at 4:23 AM, Yigal Korman <yigal@xxxxxxxxxxxxx> wrote: >> Hi, >> I'm a bit late on this but I have a question about the original patch - >> I thought that in order for movnt (movntil, movntiq) to push the data >> into the persistency domain (ADR), >> one must work with length that is multiple of cacheline size, >> otherwise the write-combine buffers remain partially >> filled and you need to commit them with a fence (sfence) - which ruins >> the whole performance gain you got here. >> Am I wrong, are the write-combine buffers are part of the ADR domain >> or something? > > The intent is to allow a batch of memcpy_flushcache() calls followed > by a single sfence. Specifying a multiple of a cacheline size does not > necessarily help as sfence is still needed to make sure that the movnt > result has reached the ADR-safe domain. Oh, right, I see that dm-writecache calls writecache_commit_flushed which in turn calls wmb(). I keep confusing *_nocache (i.e. copy_user_nocache) that includes sfence and *_flushcache (i.e. memcpy_flushcache) that doesn't. Thanks for the clear up. -- dm-devel mailing list dm-devel@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/dm-devel