From nobody Mon Feb 9 12:14:53 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 149910011184061.05821671838953; Mon, 3 Jul 2017 09:41:51 -0700 (PDT) Received: from localhost ([::1]:36297 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dS4Q1-0005gc-I8 for importer@patchew.org; Mon, 03 Jul 2017 12:41:49 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51671) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dS4KK-0000n6-Ce for qemu-devel@nongnu.org; Mon, 03 Jul 2017 12:35:57 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dS4KJ-00082t-Bo for qemu-devel@nongnu.org; Mon, 03 Jul 2017 12:35:56 -0400 Received: from mail-wm0-x243.google.com ([2a00:1450:400c:c09::243]:36626) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dS4KJ-00081q-5x for qemu-devel@nongnu.org; Mon, 03 Jul 2017 12:35:55 -0400 Received: by mail-wm0-x243.google.com with SMTP id y5so21473998wmh.3 for ; Mon, 03 Jul 2017 09:35:55 -0700 (PDT) Received: from 640k.lan (94-39-191-51.adsl-ull.clienti.tiscali.it. [94.39.191.51]) by smtp.gmail.com with ESMTPSA id r5sm4867459wmr.9.2017.07.03.09.35.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 03 Jul 2017 09:35:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=+kKRFe/7jdaPNT+Uyjweb4zIltEquSRqd+hMrfASLAo=; b=t5obti3kY2CQm9E5HFpjGnI4OYqDiPZRuSnCWZjMOWGN3/B2ucUahzf4a8Ic9bacLb rVE1V31GZfOq76pNrUTmgcJsk6rWopvF6+mAz2Yr0UtqkKorKoZj4kHSbpyJWtpShAMF mgqw72I48RLgxAU9onSowKnuL4wQVIiAdSh6FLfeBA0lW7NfPthPPgqD22zBgFHEZmyd 3gEgDLCzWTInlsAVwoYPawV3xI9r6+NHwQ0v+Z8ou7aPvXvl/Q1q8zxkOgA6z839YQbi Bsx9yhtMwoUsvC3wPMap8v1f8/ffsX/eYVqZuBAaJZNzea/aSDe5w0vFX3mGxHSuDVT7 /VNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=+kKRFe/7jdaPNT+Uyjweb4zIltEquSRqd+hMrfASLAo=; b=GmUhJru2gps4+gJCLi78VduP9mp1mehWuqnKV7keJqjNQ3MSQrXu45bQIZnGSOSJXO OrrTZW1McBhqRb/dxUC4za79W4RtvrfmnsM+9ywPbO/M0ZVJmJ6Vt0GQQfKXUCI5b9WK ZsfO9o6p3h+C+pqTdVf1O3s5gAnvewEu2eM7AN+MvVvK91Ny/qbuqoKfdbLRt9jNTzkP EDuC5GmtLkuOC+TXvt7c7c73kVSPaXwHjQE2+JZlYoH/4ojj/mv0VdFfQ2zXUFSNW9M2 ekdDxOTf/mcGb8iyBfOT/UHyxVzYTIykmrdQTIQ01590teDSp8QFvofOBEedHef5OPj7 gmCw== X-Gm-Message-State: AKS2vOyzKO3J+QeDWyRX+4Yi6kp7IYncyPPgfI1kMdYiPkJyF6YyF8da k5FmHKH33GW80db2vmU= X-Received: by 10.28.137.146 with SMTP id l140mr23925622wmd.101.1499099754008; Mon, 03 Jul 2017 09:35:54 -0700 (PDT) From: Paolo Bonzini To: qemu-devel@nongnu.org Date: Mon, 3 Jul 2017 18:34:40 +0200 Message-Id: <1499099693-22903-10-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1499099693-22903-1-git-send-email-pbonzini@redhat.com> References: <1499099693-22903-1-git-send-email-pbonzini@redhat.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:400c:c09::243 Subject: [Qemu-devel] [PATCH 09/22] monitor: disable "info jit" and "info opcount" if !TCG X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: yang.zhong@intel.com, thuth@redhat.com, a.rigo@virtualopensystems.com, anthony.xu@intel.com, rth@twiddle.net Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Signed-off-by: Paolo Bonzini Reviewed-by: Richard Henderson --- accel/tcg/translate-all.c | 5 +++++ hmp-commands-info.hx | 4 ++++ monitor.c | 2 ++ 3 files changed, 11 insertions(+) diff --git a/accel/tcg/translate-all.c b/accel/tcg/translate-all.c index 4c1d8c9..093207a 100644 --- a/accel/tcg/translate-all.c +++ b/accel/tcg/translate-all.c @@ -1851,6 +1851,11 @@ void dump_exec_info(FILE *f, fprintf_function cpu_fp= rintf) =20 tb_lock(); =20 + if (!tcg_enabled()) { + cpu_fprintf(f, "TCG not enabled\n"); + return; + } + target_code_size =3D 0; max_target_code_size =3D 0; cross_page =3D 0; diff --git a/hmp-commands-info.hx b/hmp-commands-info.hx index ba98e58..07500ef 100644 --- a/hmp-commands-info.hx +++ b/hmp-commands-info.hx @@ -261,6 +261,7 @@ STEXI Show memory tree. ETEXI =20 +#if defined(CONFIG_TCG) { .name =3D "jit", .args_type =3D "", @@ -268,6 +269,7 @@ ETEXI .help =3D "show dynamic compiler info", .cmd =3D hmp_info_jit, }, +#endif =20 STEXI @item info jit @@ -275,6 +277,7 @@ STEXI Show dynamic compiler info. ETEXI =20 +#if defined(CONFIG_TCG) { .name =3D "opcount", .args_type =3D "", @@ -282,6 +285,7 @@ ETEXI .help =3D "show dynamic compiler opcode counters", .cmd =3D hmp_info_opcount, }, +#endif =20 STEXI @item info opcount diff --git a/monitor.c b/monitor.c index 4031876..d8ac20f 100644 --- a/monitor.c +++ b/monitor.c @@ -1098,6 +1098,7 @@ static void hmp_info_registers(Monitor *mon, const QD= ict *qdict) } } =20 +#ifdef CONFIG_TCG static void hmp_info_jit(Monitor *mon, const QDict *qdict) { if (!tcg_enabled()) { @@ -1113,6 +1114,7 @@ static void hmp_info_opcount(Monitor *mon, const QDic= t *qdict) { dump_opcount_info((FILE *)mon, monitor_fprintf); } +#endif =20 static void hmp_info_history(Monitor *mon, const QDict *qdict) { --=20 1.8.3.1