From patchwork Sat Mar 16 01:57:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 780743 Delivered-To: patch@linaro.org Received: by 2002:a5d:46c1:0:b0:33e:7753:30bd with SMTP id g1csp489441wrs; Fri, 15 Mar 2024 18:59:10 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWiXMeIzkXmo5rXOtCOhZG2BdgedzQUp/Zvsn77JD7MLlpKCr5YChf+ty14KdZbMhitrERIAIYwBI93tILhawvp X-Google-Smtp-Source: AGHT+IGeKNhAr1Oa6YI7pWUs5iZx59qhU9gft2k6y3w5Y7UCbDEI5/HYIGY6IM4sTlkVJh6zZJ9J X-Received: by 2002:a05:6808:d4e:b0:3c3:7ea0:cbf3 with SMTP id w14-20020a0568080d4e00b003c37ea0cbf3mr606940oik.15.1710554349944; Fri, 15 Mar 2024 18:59:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1710554349; cv=none; d=google.com; s=arc-20160816; b=DoNO5YLH8xzCa0eF6vs+1N8ipBuHcDxg0XKFEIz1wi9W2+4j2HkeVlAO+C2GrMc7cY SKAKVWXdMkwatLJ2Re2AYHpcz/Wi+cFb9k+ZZQ2Y+7v8QFjnVh3St8ddinVTDokxJpwj E0kvK5n/TMeirwnSxwb4I3jn/Z+BDRSdWlz6maZGfYa4JSNtcnWXm0vXK42OTBEho0f0 IQ5kqTV6EptXnEsDAGr3r+zOmFDumt4IE78IUwzyKFiW9NxLtfPk0V0OTKy2hehGlDxn Ykb3jUH+QJy54E89qaIqv2PSbM7pCRfuczDYprzVD9W6VDa7+C4CxMrNLoxydy6d+eKy bVSw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=a4/P6RWm6w7Ud7tHYlYhwMNF/R2rr67Q03MPgnoMVeQ=; fh=DfUxOGz7MnM49MBgqH5VPROGi+97fYtPWhcEZCG1Y5Q=; b=TzEGxl1HRhYC4FeSc6cRzbV/T3xry79EciPoelwqlPcElgbWG+8K9Yd7xvLNraXZ5Y Jn8ps830gNIjWgdG0/2UlxnLMbhD/7H2IEKG0IVV84D6hX2sIBGQwuezMfOj/cWDlcuB GHry2DbZjaeIxodW8Qmv2XZ+32kD9ahq7VRXGhO0sC09HWO8aVyhPMCaAj/ZxXZGRqec iGCYIuvR0epko248e5HAArfTQj3ukhvMdPmssfkRbPcA/IM3m+ZU1r3IJWftqYN4So8x WRwAQD5JxDP256VDSXi/ymkJVprF5OcemNxl1LzLjwynJ/j2UZraUYcmH5un9UBemNtl Iuuw==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=XT2cDvRc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id o6-20020a0562140e4600b00690db5d7f7bsi3871289qvc.373.2024.03.15.18.59.09 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 15 Mar 2024 18:59:09 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=XT2cDvRc; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rlJJH-0002xr-F6; Fri, 15 Mar 2024 21:58:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rlJJ4-0002ra-3g for qemu-devel@nongnu.org; Fri, 15 Mar 2024 21:57:54 -0400 Received: from mail-pj1-x1033.google.com ([2607:f8b0:4864:20::1033]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rlJJ2-0000lW-G7 for qemu-devel@nongnu.org; Fri, 15 Mar 2024 21:57:53 -0400 Received: by mail-pj1-x1033.google.com with SMTP id 98e67ed59e1d1-29de4c33441so1467807a91.1 for ; Fri, 15 Mar 2024 18:57:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1710554271; x=1711159071; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=a4/P6RWm6w7Ud7tHYlYhwMNF/R2rr67Q03MPgnoMVeQ=; b=XT2cDvRcs9v1z7XDuYkT2v6GLve2SGglhG7IgEKj/bMFS0PHH/mx0qqlrpU1CD9Bs7 R+1b+c9NHcGKR2+p5NMmh8T/ZRZnB5tlTBYtO7aWTt4J/5HDumo8ROVhekSIZVZ7Duv2 LQH71ChXGhcl2TVCjBY1GCFzfvSqcpm4Cft6KvDrcbRyVm+WppHEaidxyFu+ahlktpVF w/JFzKun4DZCEJRteFUvUQJ7vAHoiF65Vi9qbzmWzMd4pHFdFA6u1C57jgxkd7QiVX7L j3ofxdOr7mmCG63TNRz2tuyVsZcVCdZYcnC0uNyRLgHIXiyLSIoE8V89hNEHLnr94xl9 C3Iw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710554271; x=1711159071; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=a4/P6RWm6w7Ud7tHYlYhwMNF/R2rr67Q03MPgnoMVeQ=; b=jpJAZHexfk6WNN5adjRJArw5qLXdxTBw+jsKWrk4V2xKmw0YbIJhN++ZkiHD9GbVkY u1Kx8+gmZAHEXhWF5NTHlfQyt20whyQh/iHy7rKx07X4MRhlAfCPU2G8JeyFNXjCk++U dUffGUQKibYgMXeCmUDwsbHPG/DDIiI8Xkictz8i8qRxgVBZtJrrACyH/dloG19+TKNs sdhgRlCo4eNkPjz/OMX2E9XA8AsRHdmVfdKvnvq8qJ4EFiYY/Sv+Kum/mfd/KikReLoK 2qh+72tyrJy/fnadZdmcdmZA5W76nwsjY+IQYDTmNsv1jS8nXibeexJP0lCUZf5rl5ry NxBg== X-Gm-Message-State: AOJu0YwnMWe+gU/VPDd/ZYF/Sr5Ebyo53h3tCgkV04mwG8sJtIbe58D1 Ttd4VcMBr3qRxXHocZtzgQGsNSX19hb4wtYcnLxbIFnEgW7Irus6RWlaLA0xCJRa1KxPhUZ/Qgh D X-Received: by 2002:a17:903:943:b0:1de:de26:f6b3 with SMTP id ma3-20020a170903094300b001dede26f6b3mr6499331plb.26.1710554271164; Fri, 15 Mar 2024 18:57:51 -0700 (PDT) Received: from stoup.. (173-197-098-125.biz.spectrum.com. [173.197.98.125]) by smtp.gmail.com with ESMTPSA id b3-20020a170903228300b001dd42bbb08asm4592985plh.253.2024.03.15.18.57.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Mar 2024 18:57:50 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: pierrick.bouvier@linaro.org, alex.bennee@linaro.org Subject: [PATCH 13/22] tcg: Remove TCG_CALL_PLUGIN Date: Fri, 15 Mar 2024 15:57:11 -1000 Message-Id: <20240316015720.3661236-14-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240316015720.3661236-1-richard.henderson@linaro.org> References: <20240316015720.3661236-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::1033; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x1033.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Since we no longer emit plugin helpers during the initial code translation phase, we don't need to specially mark plugin helpers. Signed-off-by: Richard Henderson Reviewed-by: Pierrick Bouvier --- include/tcg/tcg.h | 2 -- plugins/core.c | 10 ++++------ tcg/tcg.c | 4 +--- 3 files changed, 5 insertions(+), 11 deletions(-) diff --git a/include/tcg/tcg.h b/include/tcg/tcg.h index 95a7f4d010..df66e8f012 100644 --- a/include/tcg/tcg.h +++ b/include/tcg/tcg.h @@ -353,8 +353,6 @@ typedef TCGv_ptr TCGv_env; #define TCG_CALL_NO_SIDE_EFFECTS 0x0004 /* Helper is G_NORETURN. */ #define TCG_CALL_NO_RETURN 0x0008 -/* Helper is part of Plugins. */ -#define TCG_CALL_PLUGIN 0x0010 /* convenience version of most used call flags */ #define TCG_CALL_NO_RWG TCG_CALL_NO_READ_GLOBALS diff --git a/plugins/core.c b/plugins/core.c index b0a2e80874..b0615f1e7f 100644 --- a/plugins/core.c +++ b/plugins/core.c @@ -339,9 +339,8 @@ void plugin_register_dyn_cb__udata(GArray **arr, void *udata) { static TCGHelperInfo info[3] = { - [QEMU_PLUGIN_CB_NO_REGS].flags = TCG_CALL_NO_RWG | TCG_CALL_PLUGIN, - [QEMU_PLUGIN_CB_R_REGS].flags = TCG_CALL_NO_WG | TCG_CALL_PLUGIN, - [QEMU_PLUGIN_CB_RW_REGS].flags = TCG_CALL_PLUGIN, + [QEMU_PLUGIN_CB_NO_REGS].flags = TCG_CALL_NO_RWG, + [QEMU_PLUGIN_CB_R_REGS].flags = TCG_CALL_NO_WG, /* * Match qemu_plugin_vcpu_udata_cb_t: * void (*)(uint32_t, void *) @@ -375,9 +374,8 @@ void plugin_register_vcpu_mem_cb(GArray **arr, !__builtin_types_compatible_p(qemu_plugin_meminfo_t, int32_t)); static TCGHelperInfo info[3] = { - [QEMU_PLUGIN_CB_NO_REGS].flags = TCG_CALL_NO_RWG | TCG_CALL_PLUGIN, - [QEMU_PLUGIN_CB_R_REGS].flags = TCG_CALL_NO_WG | TCG_CALL_PLUGIN, - [QEMU_PLUGIN_CB_RW_REGS].flags = TCG_CALL_PLUGIN, + [QEMU_PLUGIN_CB_NO_REGS].flags = TCG_CALL_NO_RWG, + [QEMU_PLUGIN_CB_R_REGS].flags = TCG_CALL_NO_WG, /* * Match qemu_plugin_vcpu_mem_cb_t: * void (*)(uint32_t, qemu_plugin_meminfo_t, uint64_t, void *) diff --git a/tcg/tcg.c b/tcg/tcg.c index 0bf218314b..363a065e28 100644 --- a/tcg/tcg.c +++ b/tcg/tcg.c @@ -2269,9 +2269,7 @@ static void tcg_gen_callN(void *func, TCGHelperInfo *info, #ifdef CONFIG_PLUGIN /* Flag helpers that may affect guest state */ - if (tcg_ctx->plugin_insn && - !(info->flags & TCG_CALL_PLUGIN) && - !(info->flags & TCG_CALL_NO_SIDE_EFFECTS)) { + if (tcg_ctx->plugin_insn && !(info->flags & TCG_CALL_NO_SIDE_EFFECTS)) { tcg_ctx->plugin_insn->calls_helpers = true; } #endif