Message ID | 20181209193749.12277-17-cota@braap.org |
---|---|
State | New |
Headers | show
Return-Path: <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=nongnu.org (client-ip=2001:4830:134:3::11; helo=lists.gnu.org; envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org; receiver=<UNKNOWN>) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=braap.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=braap.org header.i=@braap.org header.b="BhzKKJDU"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.b="UPDkUCIB"; dkim-atps=neutral Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43CcKk06Zzz9s2P for <incoming@patchwork.ozlabs.org>; Mon, 10 Dec 2018 06:51:54 +1100 (AEDT) Received: from localhost ([::1]:56459 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>) id 1gW57H-0006hI-Hu for incoming@patchwork.ozlabs.org; Sun, 09 Dec 2018 14:51:51 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33407) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <cota@braap.org>) id 1gW4uF-0001SS-9A for qemu-devel@nongnu.org; Sun, 09 Dec 2018 14:38:24 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <cota@braap.org>) id 1gW4uD-0005t5-BC for qemu-devel@nongnu.org; Sun, 09 Dec 2018 14:38:23 -0500 Received: from wout2-smtp.messagingengine.com ([64.147.123.25]:33515) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from <cota@braap.org>) id 1gW4uC-0004zU-TZ for qemu-devel@nongnu.org; Sun, 09 Dec 2018 14:38:21 -0500 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 6273CF5B; Sun, 9 Dec 2018 14:38:04 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Sun, 09 Dec 2018 14:38:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=braap.org; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-type:content-transfer-encoding; s=mesmtp; bh=IxB+NparCJlR1fefrnKMz9sA2cT9U+kwIe97h3XyXJM=; b=BhzKKJDUJoIE 7vsF3cMV8nviDOpUDRbjMuoSmdRaPWgxAoessZAKLqnERKSLqkigMx1aHcWMCKIb ETXXysgqBEpZrozlDgMBYEcqJU54ljigPgu+PnaevPguHBAeu4HCNofaJbwUV3Ia lfBBqDY6S4QnjWySbvYIscPHw+PJn2c= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=IxB+NparCJlR1fefrnKMz9sA2cT9U+kwIe97h3XyX JM=; b=UPDkUCIB/In2glM+4HBOJTQA8OZCqxg0LXRTXezOXlf8MZ1PW5CJ6A9Me TciAYWu/YJCFcVyrmAFOjguk2sp0dYzr/cuaOMExI5WZT+110QHvy/lpuzBgbRMC wVhSFxGeDu4CkgJ0EGYCX6Gw1JKDVlICFLT8kUWSicNuS80WhfnvUTraA/MuzqBx UnPCsVpfvGXjc9CuTd+twO5ZUghwDOmgaA0l9WbooRT/C9PVQxgp0peRDAin8Bm+ O0sZW4WheS31H6rfVR+ULU4dUWpSfn6QjtVgSLGV3m/rXICf6W1weUZpbizEmy/b O/ivy564VTxrfqxAAD7+Vx66QEljw== X-ME-Sender: <xms:G28NXJ7vgQ8tVR25wP9MkjHOVd-1p73sCfiIY-HIkrQDGKnGv5Uk8g> X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedtkedrudegfedguddvkecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfhuthenuceurghilhhouhhtmecu fedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvufffkf fojghfgggtgfesthekredtredtjeenucfhrhhomhepfdfgmhhilhhiohcuifdrucevohht rgdfuceotghothgrsegsrhgrrghprdhorhhgqeenucfkphepuddvkedrheelrddvtddrvd duieenucfrrghrrghmpehmrghilhhfrhhomheptghothgrsegsrhgrrghprdhorhhgnecu vehluhhsthgvrhfuihiivgeptd X-ME-Proxy: <xmx:G28NXGNBMausOcq9Dr-mnKQu9AMr-osR3qODPkWCjJEzW57DF470EQ> <xmx:G28NXFK_RHqI2Ezj9_HGGLcBoaMYWcqRzYsVXkC0vHduwiOQL-XsbQ> <xmx:G28NXPFqm3YpbE_pH1CHJzkf6mcxrNgCFq2dhlvVjMMjJYt0wnXCsw> <xmx:G28NXFSMM6Bqg0RuV_67hkLKCV_mbfMQndKDmQRMcVeLcr7msuWDTg> <xmx:G28NXDEjDlnFAS9dhIdA6VZH7XmAYAHiWcwIe4gpMISxqs-0reiJNg> <xmx:HG8NXJBiaSmgTeBaJ8fMpD49Z0qqt57nljCzvIYCIlodKYiQFs0DZg> Received: from localhost (flamenco.cs.columbia.edu [128.59.20.216]) by mail.messagingengine.com (Postfix) with ESMTPA id 930D8102F2; Sun, 9 Dec 2018 14:38:03 -0500 (EST) From: "Emilio G. Cota" <cota@braap.org> To: qemu-devel@nongnu.org Date: Sun, 9 Dec 2018 14:37:27 -0500 Message-Id: <20181209193749.12277-17-cota@braap.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20181209193749.12277-1-cota@braap.org> References: <20181209193749.12277-1-cota@braap.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 64.147.123.25 Subject: [Qemu-devel] [RFC v2 16/38] translate-all: notify plugin code of tb_flush X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <http://lists.nongnu.org/archive/html/qemu-devel/> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Cc: Richard Henderson <richard.henderson@linaro.org>, =?utf-8?q?Alex_Benn?= =?utf-8?b?w6ll?= <alex.bennee@linaro.org>, Pavel Dovgalyuk <Pavel.Dovgaluk@ispras.ru> Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" <qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org> |
Series |
Plugin support
|
expand
|
diff --git a/accel/tcg/translate-all.c b/accel/tcg/translate-all.c index 62d5e13185..aaa8193ceb 100644 --- a/accel/tcg/translate-all.c +++ b/accel/tcg/translate-all.c @@ -1232,6 +1232,8 @@ static gboolean tb_host_size_iter(gpointer key, gpointer value, gpointer data) /* flush all the translation blocks */ static void do_tb_flush(CPUState *cpu, run_on_cpu_data tb_flush_count) { + bool did_flush = false; + mmap_lock(); /* If it is already been done on request of another CPU, * just retry. @@ -1239,6 +1241,7 @@ static void do_tb_flush(CPUState *cpu, run_on_cpu_data tb_flush_count) if (tb_ctx.tb_flush_count != tb_flush_count.host_int) { goto done; } + did_flush = true; if (DEBUG_TB_FLUSH_GATE) { size_t nb_tbs = tcg_nb_tbs(); @@ -1263,6 +1266,9 @@ static void do_tb_flush(CPUState *cpu, run_on_cpu_data tb_flush_count) done: mmap_unlock(); + if (did_flush) { + qemu_plugin_flush_cb(); + } } void tb_flush(CPUState *cpu)