From patchwork Wed Feb 26 07:39:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 183899 Delivered-To: patch@linaro.org Received: by 2002:a92:1f12:0:0:0:0:0 with SMTP id i18csp2791199ile; Tue, 25 Feb 2020 23:45:25 -0800 (PST) X-Google-Smtp-Source: APXvYqyhYKEZASHozJtO2ZZyABxrkKUkMHJYwX3HFs5G3PS6G87XKpi1eEKMdEXJBmwkcJDP13YL X-Received: by 2002:a37:4a46:: with SMTP id x67mr3342491qka.160.1582703125326; Tue, 25 Feb 2020 23:45:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582703125; cv=none; d=google.com; s=arc-20160816; b=zFkf7Hz1GHWv08oPimFf1vYLIOgzJJVQwGNHy2tEgkH09XXBXbyYL3yjlRjSni5LKB d7tO46Gf7zclt9vzmntVQUD9CApV0YXil6MR/iD1qlAViIm1fKHjqY0BTM6VT46ESF3p cMky/5RUg9oEHJDHOnLG4G/OUb8vD7otZ1gctwWpB0BI7FHRtj/DO1nfqW3V9l3R0PUm 2EVSUI25MYuvk92JvQj6qhdeYdP2ZzPFkMmDXAwzjyegzOAN3c6kn9HBlvl0ltss4Qb1 VHB6YwMDhYX/m1yGMEfuCfoZq+kh7iqe0+/atr1GbBzDTS7PGaBtduJBdNNhsRWmmEAJ rBaQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc: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:to:from :dkim-signature; bh=mn3tZc+6oKOSCrxCoePvIC2GrhQUWPNKBtpwoHXLA0s=; b=pXxFFWo1udftCLwMaEeIqAfKDlatas1/tfKLXAdbrf+Cjy3sEUQcHn2dC8y6JOfrd2 xFW2TXwxrPxLtkuJQw6rM078s3c4GUjv9vS/TOx5NZnkATuJwfKS+geZ/fospaN4jc+C /BZbo8MZbmKXGLeejn0/Dd5lXqZSJiNA4Y7L9PQGwEUF1KKGVPNt1LEaIg6NTleTXELJ MC3MjL17EYd4sPErDXW0eIwOjDBkEg9gNlQ5eAn27nHRIkjgpbicYH7o7xzrBI7za6Ob 4LdN5b4JmxRezDgoZ5kkAY4IoCBHwwJ/RvCzHLqUsc/GsDo+0pqh3pLw0tIj0nspWm3j nYdw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=XpREKRW0; 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=fail (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 q10si548168qvo.107.2020.02.25.23.45.25 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 25 Feb 2020 23:45:25 -0800 (PST) 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=fail header.i=@linaro.org header.s=google header.b=XpREKRW0; 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=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:39350 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j6rNk-0002Iw-PA for patch@linaro.org; Wed, 26 Feb 2020 02:45:24 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:46182) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j6rIJ-0000ou-Dd for qemu-devel@nongnu.org; Wed, 26 Feb 2020 02:39:48 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j6rII-0002nJ-Dy for qemu-devel@nongnu.org; Wed, 26 Feb 2020 02:39:47 -0500 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]:56020) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j6rII-0002mH-7l for qemu-devel@nongnu.org; Wed, 26 Feb 2020 02:39:46 -0500 Received: by mail-wm1-x333.google.com with SMTP id q9so1780394wmj.5 for ; Tue, 25 Feb 2020 23:39:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=mn3tZc+6oKOSCrxCoePvIC2GrhQUWPNKBtpwoHXLA0s=; b=XpREKRW0Di0Rk/yV8URDk3aU1r91fPOfch/W/YTPH4sbpSQSMmcpzUwl3EYc9366ab HpayAecNgnu3yEn5qWNxI/NADPtl8APRhuZ7GAU1jEt+syCWZlGwpA1ZE0VCtX53GcpT 9YG4QsPo94C17IPfI9GOKP26FTMkraFqvoTGqzr6kA6eJ7QnZtz5DaJIBYrUptS3foaO lII68SQhTbWWgtkTQ2P2nLxtuN1nOYHsAB9GojL9dUgVCCOFkg2F0RWBoOzjVn6hfnI7 0jNrgVg3bdLNbeAYuQ/9tPy4Iy8+5OJt6W4swEM5ubZ8xkKXlt+qyjE8PKXlndzS55uy Kvrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=mn3tZc+6oKOSCrxCoePvIC2GrhQUWPNKBtpwoHXLA0s=; b=rke4X5nTJinT74U4IjktE9BG+soE3GZCrRyYnCL77XbeQZEQNnI7Z9K//+vOmicPUE JnstvrloRARtjiDNwAFoEgEXZkuGyEDazSBpZ/hxCtoJQXlRGWFHzS7Gq9l24wCTHKWD 5F+TMrTC8cFzXxGITmyGEPQwMenuc05ltN614qAQFy76jcWIC4j2ZeJhC2qj4i/t96aq I6+dDPmBixW3k6LLRh1SisZNpJhkXH4EPJXfNHCSMpxR/JQRROcToqkU/sNDYAlhDIC9 /gXHGP1cJ4xZv1Jcv8/ZMWtDLFeVFuEyx+raUEqdvfHBpgbhRg97AhKbRvhL+2Iq55DD ffDg== X-Gm-Message-State: APjAAAUlMchar2BcWQ1JntSG7wshIGGCxVcyFiovVso5mYII/xhCSia0 T6aRfBI1+XM+8pcS1IaKjSV1uYlNMng= X-Received: by 2002:a05:600c:414f:: with SMTP id h15mr215761wmm.130.1582702785249; Tue, 25 Feb 2020 23:39:45 -0800 (PST) Received: from zen.linaroharston ([51.148.130.216]) by smtp.gmail.com with ESMTPSA id w1sm1782448wmc.11.2020.02.25.23.39.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 25 Feb 2020 23:39:38 -0800 (PST) Received: from zen.home.arpa (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 254741FF9A; Wed, 26 Feb 2020 07:39:30 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: peter.maydell@linaro.org Subject: [PULL 10/19] docs/devel: document query handle lifetimes Date: Wed, 26 Feb 2020 07:39:20 +0000 Message-Id: <20200226073929.28237-11-alex.bennee@linaro.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200226073929.28237-1-alex.bennee@linaro.org> References: <20200226073929.28237-1-alex.bennee@linaro.org> MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::333 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , qemu-devel@nongnu.org, Robert Foley Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" I forgot to document the lifetime of handles in the developer documentation. Do so now. Signed-off-by: Alex Bennée Reviewed-by: Robert Foley Reviewed-by: Robert Foley Message-Id: <20200225124710.14152-11-alex.bennee@linaro.org> -- 2.20.1 diff --git a/docs/devel/tcg-plugins.rst b/docs/devel/tcg-plugins.rst index 718eef00f22..a05990906cc 100644 --- a/docs/devel/tcg-plugins.rst +++ b/docs/devel/tcg-plugins.rst @@ -51,8 +51,17 @@ about how QEMU's translation works to the plugins. While there are conceptions such as translation time and translation blocks the details are opaque to plugins. The plugin is able to query select details of instructions and system configuration only through the -exported *qemu_plugin* functions. The types used to describe -instructions and events are opaque to the plugins themselves. +exported *qemu_plugin* functions. + +Query Handle Lifetime +--------------------- + +Each callback provides an opaque anonymous information handle which +can usually be further queried to find out information about a +translation, instruction or operation. The handles themselves are only +valid during the lifetime of the callback so it is important that any +information that is needed is extracted during the callback and saved +by the plugin. Usage =====