mplemented a flush to be able to tell whenever all data was written.
Leonardo Bras (5):
QIOChannel: Add flags on io_writev and introduce io_flush callback
QIOChannelSocket: Implement io_writev zero copy flag & io_flush for
CONFIG_LINUX
migration: Add zero-copy-send parameter for
nism to disable it, so it can still be accessible to less
privileged users.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
include/io/channel-socket.h | 2 +
io/channel-socket.c | 108 ++--
2 files changed, 106 i
flags.
Signed-off-by: Leonardo Bras
---
include/io/channel.h| 38 -
chardev/char-io.c | 2 +-
hw/remote/mpqemu-link.c | 2 +-
io/channel-buffer.c | 1 +
io/channel-command.c| 1 +
io/channel-f
.
On non-Linux builds this parameter is compiled-out.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
qapi/migration.json | 24
migration/migration.h | 5 +
migration/migration.c | 32
migr
with zero-copy enabled, so disabling the feature should be necessary for
low-privileged users trying to perform multifd migrations.
Signed-off-by: Leonardo Bras
---
migration/multifd.h | 4 +++-
migration/migration.c | 11 ++-
migration/multifd.c
A lot of places check parameters.tls_creds in order to evaluate if TLS is
in use, and sometimes call migrate_get_current() just for that test.
Add new helper function migrate_use_tls() in order to simplify testing
for TLS usage.
Signed-off-by: Leonardo Bras
Reviewed-by: Juan Quintela
Reviewed
ltifd.
Results:
So far, the resource usage of __sys_sendmsg() reduced 15 times, and the
overall migration took 13-18% less time, based in synthetic workload.
The objective is to reduce migration time in hosts with heavy cpu usage.
Leonardo Bras (3):
io: Enable write flags for QIOChannel
io
that would benefit of zerocopy;
Step 3 is done with qio_channel_socket_errq_proc(), that runs after
SOCKET_ERRQ_THRESH (16k) iovs sent, dealing with any error found.
Signed-off-by: Leonardo Bras
---
include/io/channel-socket.h | 2 +
include/io/channel.h| 29 ++
io/channe
approach.
Signed-off-by: Leonardo Bras
---
migration/multifd-zlib.c | 7 ---
migration/multifd-zstd.c | 7 ---
migration/multifd.c | 9 ++---
migration/multifd.h | 3 ++-
4 files changed, 16 insertions(+), 10 deletions(-)
diff --git a/migration/multifd-zlib.c b/migration
abled for QIOChannelSocket, but can be easily
extended to any other QIOChannel implementation.
Signed-off-by: Leonardo Bras
---
chardev/char-io.c | 2 +-
hw/remote/mpqemu-link.c | 2 +-
include/io/channel.h| 56 -
io/ch
- Implemented a flush to be able to tell whenever all data was written.
Leonardo Bras (7):
QIOChannel: Add flags on io_writev and introduce io_flush callback
QIOChannelSocket: Implement io_writev zero copy flag & io_flush for
CONFIG_LINUX
migration: Add zero-copy-send parameter
flags.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
Reviewed-by: Juan Quintela
---
include/io/channel.h| 38 +-
chardev/char-io.c | 2 +-
hw/remote/mpqemu-link.c | 2 +-
io/channel-buf
.
On non-Linux builds this parameter is compiled-out.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
---
qapi/migration.json | 24
migration/migration.h | 5 +
migration/migration.c
nism to disable it, so it can still be accessible to less
privileged users.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
---
include/io/channel-socket.h | 2 +
io/channel-socket.c | 108 +
tion
with zero-copy enabled, so disabling the feature should be necessary for
low-privileged users trying to perform multifd migrations.
Signed-off-by: Leonardo Bras
---
migration/multifd.h | 2 ++
migration/migration.c | 11 ++-
migration/multifd.c
(This change is important to next patch on multifd zero copy
implementation, to make it sure an error in zero-copy flush does not go
unnoticed.
Signed-off-by: Leonardo Bras
---
migration/multifd.h | 2 +-
migration/multifd.c | 10 ++
migration/ram.c | 29 ++---
happening before. This only changes how a migration
with zero-copy-send=true works, not changing any current behavior for
migrations with zero-copy-send=false.
Signed-off-by: Leonardo Bras
---
migration/multifd.c | 29 ++---
1 file changed, 26 insertions(+), 3 deletions(-)
di
A lot of places check parameters.tls_creds in order to evaluate if TLS is
in use, and sometimes call migrate_get_current() just for that test.
Add new helper function migrate_use_tls() in order to simplify testing
for TLS usage.
Signed-off-by: Leonardo Bras
Reviewed-by: Juan Quintela
Reviewed
uffer memory in MSG_ZEROCOPY
send.
Changes since v1:
- Reimplemented the patchset using async_write + async_flush approach.
- Implemented a flush to be able to tell whenever all data was written.
Leonardo Bras (7):
QIOChannel: Add flags on io_writev and introduce io_flush callback
QIOChannelSoc
flags.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
Reviewed-by: Juan Quintela
---
include/io/channel.h| 38 +-
chardev/char-io.c | 2 +-
hw/remote/mpqemu-link.c | 2 +-
io/channel-buf
nism to disable it, so it can still be accessible to less
privileged users.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
---
include/io/channel-socket.h | 2 +
io/channel-socket.c | 108 +
.
On non-Linux builds this parameter is compiled-out.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
---
qapi/migration.json | 24
migration/migration.h | 5 +
migration/migration.c
happening before. This only changes how a migration
with zero-copy-send=true works, not changing any current behavior for
migrations with zero-copy-send=false.
Signed-off-by: Leonardo Bras
---
migration/multifd.c | 23 ---
1 file changed, 20 insertions(+), 3 deletions(-)
di
tion
with zero-copy enabled, so disabling the feature should be necessary for
low-privileged users trying to perform multifd migrations.
Signed-off-by: Leonardo Bras
---
migration/multifd.h | 2 ++
migration/migration.c | 11 ++-
migration/multifd.c
(This change is important to next patch on multifd zero copy
implementation, to make it sure an error in zero-copy flush does not go
unnoticed.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
---
migration/multifd.h | 2 +-
migration/multifd.c | 10 ++
A lot of places check parameters.tls_creds in order to evaluate if TLS is
in use, and sometimes call migrate_get_current() just for that test.
Add new helper function migrate_use_tls() in order to simplify testing
for TLS usage.
Signed-off-by: Leonardo Bras
Reviewed-by: Juan Quintela
Reviewed
.
On non-Linux builds this parameter is compiled-out.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
Acked-by: Markus Armbruster
---
qapi/migration.json | 24
migration/migration.h | 5 +
migr
A lot of places check parameters.tls_creds in order to evaluate if TLS is
in use, and sometimes call migrate_get_current() just for that test.
Add new helper function migrate_use_tls() in order to simplify testing
for TLS usage.
Signed-off-by: Leonardo Bras
Reviewed-by: Juan Quintela
Reviewed
(This change is important to next patch on multifd zero copy
implementation, to make it sure an error in zero-copy flush does not go
unnoticed.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
---
migration/multifd.h | 2 +-
migration/multifd.c | 10 ++
flags.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
Reviewed-by: Juan Quintela
---
include/io/channel.h| 38 +-
chardev/char-io.c | 2 +-
hw/remote/mpqemu-link.c | 2 +-
io/channel-buf
rite + async_flush approach.
- Implemented a flush to be able to tell whenever all data was written.
Leonardo Bras (7):
QIOChannel: Add flags on io_writev and introduce io_flush callback
QIOChannelSocket: Implement io_writev zero copy flag & io_flush for
CONFIG_LINUX
migration: Add z
nism to disable it, so it can still be accessible to less
privileged users.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
---
include/io/channel-socket.h | 2 +
io/channel-socket.c | 120 +
happening before. This only changes how a migration
with zero-copy-send=true works, not changing any current behavior for
migrations with zero-copy-send=false.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
migration/multifd.c | 22 +++-
tion
with zero-copy enabled, so disabling the feature should be necessary for
low-privileged users trying to perform multifd migrations.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
migration/multifd.h | 2 ++
migration/migration.c
Patch #1: One more fallback
- Patch #2: Fall back to sync if fails to lock buffer memory in MSG_ZEROCOPY
send.
Changes since v1:
- Reimplemented the patchset using async_write + async_flush approach.
- Implemented a flush to be able to tell whenever all data was written.
Leonardo Bras (7):
QIOC
nism to disable it, so it can still be accessible to less
privileged users.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
---
include/io/channel-socket.h | 2 +
io/channel-socket.c | 117 +
flags.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
Reviewed-by: Juan Quintela
---
include/io/channel.h| 38 +-
chardev/char-io.c | 2 +-
hw/remote/mpqemu-link.c | 2 +-
io/channel-buf
(This change is important to next patch on multifd zero copy
implementation, to make it sure an error in zero-copy flush does not go
unnoticed.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
---
migration/multifd.h | 2 +-
migration/multifd.c | 10 ++
.
On non-Linux builds this parameter is compiled-out.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
Acked-by: Markus Armbruster
---
qapi/migration.json | 24
migration/migration.h | 5 +
migr
A lot of places check parameters.tls_creds in order to evaluate if TLS is
in use, and sometimes call migrate_get_current() just for that test.
Add new helper function migrate_use_tls() in order to simplify testing
for TLS usage.
Signed-off-by: Leonardo Bras
Reviewed-by: Juan Quintela
Reviewed
happening before. This only changes how a migration
with zero-copy-send=true works, not changing any current behavior for
migrations with zero-copy-send=false.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
migration/multifd.c | 22 +++-
tion
with zero-copy enabled, so disabling the feature should be necessary for
low-privileged users trying to perform multifd migrations.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
migration/multifd.h | 2 ++
migration/migration.c
happening before. This only changes how a migration
with zero-copy-send=true works, not changing any current behavior for
migrations with zero-copy-send=false.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
migration/multifd.c | 22 +++-
mmand failed
===
As above error message suggests, 'struct __kernel_timespec' was already
defined by liburing/compat.h.
Fix alpine CI by adding test to disable liburing in configure step if a
redefinition happens between linux/errqueue.h and liburing/compat.h.
Signed-off-by: Leonar
- Several other small improvements
Changes since v2:
- Patch #1: One more fallback
- Patch #2: Fall back to sync if fails to lock buffer memory in MSG_ZEROCOPY
send.
Changes since v1:
- Reimplemented the patchset using async_write + async_flush approach.
- Implemented a flush to be able to t
flags.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
Reviewed-by: Juan Quintela
---
include/io/channel.h| 38 +-
chardev/char-io.c | 2 +-
hw/remote/mpqemu-link.c | 2 +-
io/channel-buf
.
On non-Linux builds this parameter is compiled-out.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
Acked-by: Markus Armbruster
---
qapi/migration.json | 24
migration/migration.h | 5 +
migr
nism to disable it, so it can still be accessible to less
privileged users.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Juan Quintela
---
include/io/channel-socket.h | 2 +
io/channel-socket.c | 116 +
tion
with zero-copy enabled, so disabling the feature should be necessary for
low-privileged users trying to perform multifd migrations.
Signed-off-by: Leonardo Bras
Reviewed-by: Peter Xu
Reviewed-by: Daniel P. Berrangé
---
migration/multifd.h | 2 ++
migration/migration.c
A lot of places check parameters.tls_creds in order to evaluate if TLS is
in use, and sometimes call migrate_get_current() just for that test.
Add new helper function migrate_use_tls() in order to simplify testing
for TLS usage.
Signed-off-by: Leonardo Bras
Reviewed-by: Juan Quintela
Reviewed
(This change is important to next patch on multifd zero copy
implementation, to make it sure an error in zero-copy flush does not go
unnoticed.
Signed-off-by: Leonardo Bras
Reviewed-by: Daniel P. Berrangé
Reviewed-by: Peter Xu
---
migration/multifd.h | 2 +-
migration/multifd.c | 10 ++
Hello Daniel, thanks for reviewing!
On Tue, Feb 1, 2022 at 6:35 AM Daniel P. Berrangé wrote:
>
> On Tue, Feb 01, 2022 at 03:28:59AM -0300, Leonardo Bras wrote:
> > Add flags to io_writev and introduce io_flush as optional callback to
> > QIOChannelClass, allowing the implement
Hello Peter,
On Mon, Feb 7, 2022 at 9:50 AM Peter Xu wrote:
>
> On Tue, Feb 01, 2022 at 03:28:59AM -0300, Leonardo Bras wrote:
> > Add flags to io_writev and introduce io_flush as optional callback to
> > QIOChannelClass, allowing the implementation of zero copy writes
Hello Peter, thanks for reviewing!
On Mon, Feb 7, 2022 at 11:22 PM Peter Xu wrote:
>
> On Tue, Feb 01, 2022 at 03:29:03AM -0300, Leonardo Bras wrote:
> > -void multifd_send_sync_main(QEMUFile *f)
> > +int multifd_send_sync_main(QEMUFile *f)
> > {
> > int i;
Hello Peter,
On Tue, Aug 31, 2021 at 6:24 PM Peter Xu wrote:
>
> On Tue, Aug 31, 2021 at 08:02:36AM -0300, Leonardo Bras wrote:
> > Results:
> > So far, the resource usage of __sys_sendmsg() reduced 15 times, and the
> > overall migration took 13-18% less time, bas
Hello Daniel, thank you for the feedback!
Comments inline.
On Tue, Aug 31, 2021 at 9:57 AM Daniel P. Berrangé wrote:
>
> On Tue, Aug 31, 2021 at 08:02:38AM -0300, Leonardo Bras wrote:
> > MSG_ZEROCOPY is a feature that enables copy avoidance in TCP/UDP socket
> > send ca
Thanks for this feedback Peter!
I ended up reading/replying the e-mails in thread order, so I may have
been redundant
with your argument, sorry about that.
I will add my comments inline, but I will add references to the
previous mail I sent
Daniel, so please read it too.
On Tue, Aug 31, 2021 at
Hello Daniel,.
A few more comments:
On Wed, Sep 1, 2021 at 5:51 AM Daniel P. Berrangé wrote:
>
> On Tue, Aug 31, 2021 at 04:27:04PM -0400, Peter Xu wrote:
> > On Tue, Aug 31, 2021 at 01:57:33PM +0100, Daniel P. Berrangé wrote:
> > > On Tue, Aug 31, 2021 at 08:02:38AM -0300
Hello Daniel, thanks for the feedback !
On Tue, Aug 31, 2021 at 10:17 AM Daniel P. Berrangé wrote:
>
> On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote:
> > Call qio_channel_set_zerocopy(true) in the start of every multifd thread.
> >
> > Change the send_writ
Hello Peter, thank you for this feedback!
On Tue, Aug 31, 2021 at 5:29 PM Peter Xu wrote:
> Yes it would be great to be a migration capability in parallel to multifd. At
> initial phase if it's easy to be implemented on multi-fd only, we can add a
> dependency between the caps. In the future we
A few more comments on this one:
On Wed, Sep 1, 2021 at 12:44 PM Daniel P. Berrangé wrote:
>
> > From the safe side we may want to only enable one of them until we prove
> > they'll work together I guess..
>
> MPTCP is good when we're network limited for migration
>
> KTLS will be good when we're
; On Tue, Aug 31, 2021 at 02:16:42PM +0100, Daniel P. Berrangé wrote:
> >>>> On Tue, Aug 31, 2021 at 08:02:39AM -0300, Leonardo Bras wrote:
> >>>>> Call qio_channel_set_zerocopy(true) in the start of every multifd
> >>>>> thread.
> >>>
Thanks for the feedback Eric!
On Wed, Sep 1, 2021 at 5:54 PM Eric Blake wrote:
>
> On Tue, Aug 31, 2021 at 08:02:37AM -0300, Leonardo Bras wrote:
> > Some syscalls used for writting, such as sendmsg(), accept flags that
> > can modify their behavior, even allowing the usage o
On Thu, Sep 2, 2021 at 5:21 AM Daniel P. Berrangé wrote:
>
> On Thu, Sep 02, 2021 at 04:22:55AM -0300, Leonardo Bras Soares Passos wrote:
> > Hello Daniel, thanks for the feedback !
> >
> > On Tue, Aug 31, 2021 at 10:17 AM Daniel P. Berrangé
> > wrote:
> > &
On Thu, Sep 2, 2021 at 5:47 AM Daniel P. Berrangé wrote:
>
> On Thu, Sep 02, 2021 at 03:38:11AM -0300, Leonardo Bras Soares Passos wrote:
> > Hello Daniel, thank you for the feedback!
> >
> > Comments inline.
> >
> > On Tue, Aug 31, 2021 at 9:57 AM Daniel P.
On Thu, Sep 2, 2021 at 6:20 AM Daniel P. Berrangé wrote:
>
> On Thu, Sep 02, 2021 at 05:52:15AM -0300, Leonardo Bras Soares Passos wrote:
> > On Thu, Sep 2, 2021 at 5:21 AM Daniel P. Berrangé
> > wrote:
> > >
> > > On Thu, Sep 02, 2021 at 04:22:55A
On Thu, Sep 2, 2021 at 6:50 AM Daniel P. Berrangé wrote:
>
> On Thu, Sep 02, 2021 at 06:34:01AM -0300, Leonardo Bras Soares Passos wrote:
> > On Thu, Sep 2, 2021 at 5:47 AM Daniel P. Berrangé
> > wrote:
> > >
> > > On Thu, Sep 02, 2021 at 03:38:11A
On Thu, Sep 2, 2021 at 6:59 AM Daniel P. Berrangé wrote:
>
> On Thu, Sep 02, 2021 at 06:49:06AM -0300, Leonardo Bras Soares Passos wrote:
> > On Thu, Sep 2, 2021 at 6:20 AM Daniel P. Berrangé
> > wrote:
> > >
> > > On Thu, Sep 02, 2021 at 05:52:15A
On Tue, Sep 7, 2021 at 1:44 PM Peter Xu wrote:
>
> On Thu, Sep 02, 2021 at 03:59:25AM -0300, Leonardo Bras Soares Passos wrote:
> > I also suggested something like that, but I thought it could be good if we
> > could
> > fall back to io_writev() if we didn't have the
On Tue, Sep 7, 2021 at 8:06 AM Dr. David Alan Gilbert
wrote:
> > Possibly, yes. This really need David G's input since he understands
> > the code in way more detail than me.
>
> Hmm I'm not entirely sure why we have the sync after each iteration;
> the case I can think of is if we're doing async
Could someone help me with that?
FWIW, what I had in mind for a (theoretical) migration setup with
io_async_writev() + io_async_flush():
- For guest RAM we can decide not to rw_lock memory on zerocopy,
because there is no need,
- For headers, we can decide to not use async (use io_writev() instead),
- flush() can happen each iteration of migration, or at each N
seconds, or at the end.
Thank you for the great discussion :)
Leonardo Bras
Thanks for reviewing, Juan!
On Fri, Feb 18, 2022 at 1:36 PM Juan Quintela wrote:
>
> Leonardo Bras wrote:
> > Add flags to io_writev and introduce io_flush as optional callback to
> > QIOChannelClass, allowing the implementation of zero copy writes by
> > subclasses.
Hello Juan, thanks for the feedback!
On Fri, Feb 18, 2022 at 1:57 PM Juan Quintela wrote:
>
> Leonardo Bras wrote:
> > Implement zero copy send on nocomp_send_write(), by making use of QIOChannel
> > writev + flags & flush interface.
> >
> > Change multifd_s
On Fri, Feb 18, 2022 at 2:36 PM Juan Quintela wrote:
>
> Leonardo Bras Soares Passos wrote:
> > Hello Peter, thanks for reviewing!
> >
> > On Mon, Feb 7, 2022 at 11:22 PM Peter Xu wrote:
> >>
> >> On Tue, Feb 01, 2022 at 03:29:03AM -0300, Leonardo Bras
On Mon, Feb 21, 2022 at 4:41 PM Leonardo Bras Soares Passos
wrote:
>
> Hello Juan, thanks for the feedback!
>
> On Fri, Feb 18, 2022 at 1:57 PM Juan Quintela wrote:
> >
> > Leonardo Bras wrote:
> > > Implement zero copy send on nocomp_send_write(), b
On Tue, Mar 1, 2022 at 12:57 AM Peter Xu wrote:
>
> On Fri, Feb 18, 2022 at 05:57:13PM +0100, Juan Quintela wrote:
> > I did a change on:
> >
> > commit d48c3a044537689866fe44e65d24c7d39a68868a
> > Author: Juan Quintela
> > Date: Fri Nov 19 15:35:58 2021 +0100
> >
> > multifd: Use a single
On Tue, Apr 26, 2022 at 9:59 AM Peter Xu wrote:
>
> On Mon, Apr 25, 2022 at 06:50:54PM -0300, Leonardo Bras wrote:
> > Even though multifd_send_sync_main() currently emits error_reports, it's
> > callers don't really check it before continuing.
> >
> > Chan
Hello Daniel, thank you for the feedback!
On Tue, Apr 26, 2022 at 5:11 AM Daniel P. Berrangé wrote:
>
> On Mon, Apr 25, 2022 at 06:50:55PM -0300, Leonardo Bras wrote:
> > Since d48c3a0445 ("multifd: Use a single writev on the send side"),
> > sending the header
Hello Peter, thanks for helping!
On Tue, Apr 26, 2022 at 1:02 PM Peter Xu wrote:
>
> Leo,
>
> This patch looks mostly good to me, a few nitpicks below.
>
> On Mon, Apr 25, 2022 at 06:50:56PM -0300, Leonardo Bras wrote:
[...]
> > }
> > +
> > +/*
&g
On Tue, Apr 26, 2022 at 8:26 PM Peter Xu wrote:
>
> On Tue, Apr 26, 2022 at 08:06:55PM -0300, Leonardo Bras wrote:
> > Since d48c3a0445 ("multifd: Use a single writev on the send side"),
> > sending the header packet and the memory pages happens in the same
> >
On Wed, Apr 27, 2022 at 5:46 AM Daniel P. Berrangé wrote:
>
> On Tue, Apr 26, 2022 at 08:06:56PM -0300, Leonardo Bras wrote:
> > Implement zero copy send on nocomp_send_write(), by making use of QIOChannel
> > writev + flags & flush interface.
> >
> >
On Wed, Apr 27, 2022 at 5:44 AM Daniel P. Berrangé wrote:
>
> On Tue, Apr 26, 2022 at 08:06:55PM -0300, Leonardo Bras wrote:
> > Since d48c3a0445 ("multifd: Use a single writev on the send side"),
> > sending the header packet and the memory pages happens in th
On Tue, Apr 26, 2022 at 8:26 PM Peter Xu wrote:
>
> On Tue, Apr 26, 2022 at 08:06:56PM -0300, Leonardo Bras wrote:
> > Implement zero copy send on nocomp_send_write(), by making use of QIOChannel
> > writev + flags & flush interface.
> >
> > Change multifd_s
On Thu, Apr 28, 2022 at 11:08 AM Dr. David Alan Gilbert
wrote:
>
> * Leonardo Bras (leob...@redhat.com) wrote:
> > This patch series intends to enable MSG_ZEROCOPY in QIOChannel, and make
> > use of it for multifd migration performance improvement, by reducing cpu
> >
On Wed, May 4, 2022 at 7:48 AM Markus Armbruster wrote:
>
> Leonardo Bras writes:
>
> > Add property that allows zero-copy migration of memory pages
> > on the sending side, and also includes a helper function
> > migrate_use_zero_copy_send() to check if it
On Wed, May 4, 2022 at 4:53 PM Peter Xu wrote:
>
> On Wed, May 04, 2022 at 04:18:31PM -0300, Leonardo Bras wrote:
> > +/*
> > + * Zero-copy defines bellow are included to avoid breaking builds on
> > systems
> > + * that don't support MSG_ZEROCOPY, while keepi
On Thu, May 5, 2022 at 5:05 AM Daniel P. Berrangé wrote:
>
> On Wed, May 04, 2022 at 04:18:31PM -0300, Leonardo Bras wrote:
> > For CONFIG_LINUX, implement the new zero copy flag and the optional callback
> > io_flush on QIOChannelSocket, but enables it only when MSG_ZEROC
On Thu, May 5, 2022 at 12:55 PM Daniel P. Berrangé wrote:
>
> On Thu, May 05, 2022 at 12:42:47PM -0300, Leonardo Bras Soares Passos wrote:
> >
> > Hello Daniel,
> >
> > But what if this gets compiled in a Linux system without MSG_ZEROCOPY
> > support?
> &
Hello 徐闯,
Thanks for reviewing!
On Wed, Jun 1, 2022 at 6:37 AM 徐闯 wrote:
[...]
> Hi, Leonardo. I'm also paying attention to the application of
> MSG_ZEROCOPY in live migration recently. I noticed that you defined a
> member `zero_copy_queued` in the struct QIOChannelSocket, but I can't
> find ou
Hello Peter,
On Wed, Jun 1, 2022 at 10:58 AM Peter Xu wrote:
>
[...]
> > Hi, Leonardo. I'm also paying attention to the application of MSG_ZEROCOPY
> > in live migration recently. I noticed that you defined a member
> > `zero_copy_queued` in the struct QIOChannelSocket, but I can't find out
> > w
On Wed, Jun 8, 2022 at 8:41 AM Peter Xu wrote:
>
> On Wed, Jun 08, 2022 at 02:37:28AM -0300, Leonardo Bras Soares Passos wrote:
> > (1) is not an option, as the interface currently uses ret=1 to make
> > sure MSG_ZEROCOPY is getting used,
> > I added that so the user of qi
Hello Peter,
On Wed, Jun 8, 2022 at 5:23 PM Peter Xu wrote:
[...]
> > In a previous iteration of the patchset, it was made clear that it's
> > desirable to detect when the kernel falls back to copying mechanism,
> > so the user of 'QIOChannelSocket' can switch to copying and avoid the
> > overhea
On Mon, Jun 13, 2022 at 7:53 PM Peter Xu wrote:
>
> On Mon, Jun 13, 2022 at 05:58:44PM -0300, Leonardo Bras Soares Passos wrote:
> > Hello Peter,
> >
> > On Wed, Jun 8, 2022 at 5:23 PM Peter Xu wrote:
> > [...]
> > > > In a previous iteration of
On Fri, May 26, 2023 at 5:04 AM Juan Quintela wrote:
>
> Leonardo Brás wrote:
> > On Mon, 2023-05-15 at 21:56 +0200, Juan Quintela wrote:
> >> We forget several places to add to trasferred amount of data. With
> >> this fixes I get:
> >>
> >>qemu_file_transferred() + multifd_bytes == transfe
On Fri, May 26, 2023 at 5:07 AM Juan Quintela wrote:
>
> Leonardo Brás wrote:
> > On Mon, 2023-05-15 at 21:56 +0200, Juan Quintela wrote:
> >> It is a time that needs to be cleaned each time cancel migration.
> >> Once there create migration_time_since() to calculate how time since a
> >> time in
On Fri, May 26, 2023 at 5:09 AM Juan Quintela wrote:
>
> Leonardo Brás wrote:
> > On Mon, 2023-05-15 at 21:56 +0200, Juan Quintela wrote:
> >> That is the moment we know we have transferred something.
> >>
> >> Signed-off-by: Juan Quintela
> >> Reviewed-by: Cédric Le Goater
> >> ---
> >> migra
On Fri, May 26, 2023 at 5:17 AM Juan Quintela wrote:
>
> Leonardo Brás wrote:
> > On Mon, 2023-05-15 at 21:57 +0200, Juan Quintela wrote:
> >> Signed-off-by: Juan Quintela
> >> Reviewed-by: Cédric Le Goater
> >> ---
> >> migration/migration-stats.h | 8 +++-
> >> migration/migration-stats.
gt; Already in tree.
>
> See explanation for the split on previous patch.
>
> The other reason for the split is that this part of the patch is trivial
> to review O:-)
:-)
>
> Later, Juan.
>
> >
> > Reviewed-by: Leonardo Bras
>
* the current chunk. So, we have to call qemu_update_position()
> >> - * later on when the actual write occurs.
> >> - */
> >> -if (bytes_sent) {
> >> -*bytes_sent = 1;
> >> -}
> >> -
> >> /*
> >> * Drain the Completion Queue if possible, but do not block,
> >> * just poll.
> >
> > Oh, so this one complements 13/16.
> > Since it doesn't do imaginary transfers anymore, there is no need to use
> > bytes_sent pointer to keep track of them anymore.
> >
> > Other than the pages_sent above that I couldn't understand:
> > Reviewed-by: Leonardo Bras
>
> Dropping that bit.
>
> Thanks.
>
eturn 0;
> >> }
> >
> > Humm, those are atomic ops, right?
> >
> > You think we could have 'multifd_bytes' and 'transferred' in the same
> > cacheline,
> > to avoid 2 cacheline bounces?
>
> Don't matter on next series.
>
> mig_stats.transferred is dropped.
>
> And transferred becomes:
>
> qemu_file_transferred + multifd_bytes + rdma_bytes.
>
> So everytime that we do a write, we only update one counter.
That's even better :)
Thanks!
>
> > Well, it's unrelated to this patchset, so:
> >
> > Reviewed-by: Leonardo Bras
>
100 matches
Mail list logo