From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51211) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aYEuH-0000k9-Gq for qemu-devel@nongnu.org; Tue, 23 Feb 2016 10:29:46 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aYEuE-00026A-3J for qemu-devel@nongnu.org; Tue, 23 Feb 2016 10:29:45 -0500 Received: from mx2.parallels.com ([199.115.105.18]:57279) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aYEuD-000264-TJ for qemu-devel@nongnu.org; Tue, 23 Feb 2016 10:29:42 -0500 References: <1456239585-13324-1-git-send-email-den@openvz.org> <1456239585-13324-2-git-send-email-den@openvz.org> <20160223172048-mutt-send-email-mst@redhat.com> From: "Denis V. Lunev" Message-ID: <56CC7ADD.5080508@openvz.org> Date: Tue, 23 Feb 2016 18:29:33 +0300 MIME-Version: 1.0 In-Reply-To: <20160223172048-mutt-send-email-mst@redhat.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 1/2] virtio-balloon: export all balloon statistics List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Michael S. Tsirkin" Cc: Igor Redko , qemu-devel@nongnu.org On 02/23/2016 06:24 PM, Michael S. Tsirkin wrote: > On Tue, Feb 23, 2016 at 05:59:44PM +0300, Denis V. Lunev wrote: >> From: Igor Redko >> >> We are making experiments with different autoballooning strategies >> based on the guest behavior. Thus we need to experiment with different >> guest statistics. For now every counter change requires QEMU recompilation >> and dances with Libvirt. >> >> This patch introduces transport for unrecognized counters in virtio-balloon. >> This transport can be used for measuring benefits from using new >> balloon counters, before submitting any patches. Current alternative >> is 'guest-exec' transport which isn't made for such delicate matters >> and can influence test results. >> >> Originally all counters with tag >= VIRTIO_BALLOON_S_NR were ignored. >> Instead of this we keep first (VIRTIO_BALLOON_S_NR + 32) counters from the >> queue and pass unrecognized ones with the following names: 'x-stat-XXXX', >> where XXXX is a tag number in hex. Defined counters are reported with their >> regular names. >> >> Signed-off-by: Igor Redko >> Signed-off-by: Denis V. Lunev >> CC: Michael S. Tsirkin > This seems to open the ABI to abuse. > Seems like a reasonable way to experiment though. > How about adding this within #if 0 statements? > You can uncomment them for debugging ... I'd prefer to have this enabled. Why do you think that it opens "abuse" way? Actually the amount of host data is limited. If the guest will send fake stats before real ones - this guest is not cooperative and in this case the guest can hust ignore any balloon change requests.