From patchwork Tue Dec 17 22:38:15 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851459 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp615410wrq; Tue, 17 Dec 2024 14:40:54 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCUEZB8wmhMwQOaKbmcH46+jBJEYa6fUdMxTpGHwy0+pJppkYe2Y4tLqUik3XS3bcnpCLH58Cg==@linaro.org X-Google-Smtp-Source: AGHT+IHSqXYCGc1fKSLKWMiO4WlTrH3Z/fYm/yyrXyO4obd3rdSz1QGo/jqItl7POOYDdKs3DZRw X-Received: by 2002:a05:6214:48b:b0:6d8:8874:2126 with SMTP id 6a1803df08f44-6dd091ad6a8mr14816876d6.11.1734475253958; Tue, 17 Dec 2024 14:40:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475253; cv=none; d=google.com; s=arc-20240605; b=JR/5+chQ/8N0i45jmLFmnZN4DMhVOXsu4WGEPZ24H4EAejye1hXIYebQDK3UWhYsz2 C5uQD0Sqj0YnXS4RU72biDkL6KzhR5gVApSdIQpNbsxSEk0QMIHYJLn/JY6BvxA/6de6 Fu5Rewf5jWulxC50wYo6+00eEBLoZ3MxovUGgcMaRlVN2ZId4BP8pHrZ//PmLVxv9gQi GcnxLnJ0bcVm4xz3Trxf++ZzoPQpkrmqlYwEuy4D7A9pxq/5/L6JChFjZEa6YWI445g9 Pwywjvcw5clB8AEEkROzilJ98KVxtTszAl5X6G7pA2C7u2iuTQDArhASZMuVNaDv41nF 6QHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=cpYSyAxaLUq+FGwtpjTxiPWQf+sG11OxsgGPSOFXX90=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=b1kqeeuZTNYlRcKYo0P4xzT1bRsXQ9zni8Mgh2PxLXcJmqTDZj9KaQOS+nkVAl+xyq jg86NStObwroq8sOXWsl2Tl9FMMuKCFZXWPBr2K4B6VlpQJ9okHTW/msu974plLXhgHG HVu7xv34hPWTSvOuiYqLXew62QN7wEpzefEw7jGKWq0cK3PgzhATR5khHK11jP3sKxGV 9szD2W9IUwx0Pc65R63zZgSDvwG6OX4gHnriyFx+SrtbPwDGzK0cmArgdFHCY+i6qTIL FDBy7IJNYAbXx22NMQjZ+lu9NISGNB45vqk/y74pZWmkk9BwHMamCT0mQXbFvcLjjXwY 0SKQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RpVSQbpd; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 6a1803df08f44-6dccd34e4e1si121485306d6.226.2024.12.17.14.40.53 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:40:53 -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=pass header.i=@linaro.org header.s=google header.b=RpVSQbpd; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgD6-0005LA-7l; Tue, 17 Dec 2024 17:38:36 -0500 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 1tNgD4-0005KL-Sb for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:34 -0500 Received: from mail-pl1-x632.google.com ([2607:f8b0:4864:20::632]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD3-0008Py-CC for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:34 -0500 Received: by mail-pl1-x632.google.com with SMTP id d9443c01a7336-21619108a6bso44649785ad.3 for ; Tue, 17 Dec 2024 14:38:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475111; x=1735079911; 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=cpYSyAxaLUq+FGwtpjTxiPWQf+sG11OxsgGPSOFXX90=; b=RpVSQbpdWQtYS7GSDup6V/gJGbHnXQOc6EwCfYkYq9/JUC+N+guasQ9JPO++lVwH2a aG46RKmUNBa98xhFgRqHFmkgsmpVq6ZUc0OgC+rpBZJzU/RCyNOZWHsP6xBEGIaYNAC5 DrR85nd+eaVO9VQd3IlS1HgT2MeMLieZEXrAZ6hSazpBgNsCkq4GB8LEe3zyO+rknBXv KmjS35kV7APxF/9p+J4quE7FbaIvHMk0m5j1KmfjeQkc6rtPk4WPF+Cx3sE+pF3gkEqo S4NPpzpxUFSiogMghgGWCAm81fz3AWPQY014IySEA9O8ZeeaD/zI/GtWF5AEKQvEjVTr RDZQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475111; x=1735079911; 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=cpYSyAxaLUq+FGwtpjTxiPWQf+sG11OxsgGPSOFXX90=; b=gUg1unI4tjvtDv9x1bggSXBvQrPAm9U17QqK21EZfc0J9Dapwh+DlXqJjnDOJllSxd XtejdZbE1gSFHGKPeseT/grxJnMDk0mPpihGMirc+WCn83/mwT6R8zaAqDUXnFIMOSZk +vw8zFVN239O0Ed95/qUQ3wCcLZ68m5e9flbhhLrYGp6J0pj22+CdEA6Tje4CBGVC8vH IziZZRheLOfhHhRdx4TEt34GmjpBU1PRJ0TJ3BcsWopwca0cimbiZfnv1UyAc1GrVlO8 LgymLoTyYuHU0cgNYQvv7zrn4w2NMoPJDX0Rgrskmvt1Fwxb0hXPJGWoRvsTw9G1jRsu 1x/A== X-Gm-Message-State: AOJu0Yys6yCf97Zl3s+ZRZhVb7wVOzoujxVX+2DcaqG1ei1frjDwlE4A g5aifaEUgnniYT0XbhNHrDH6K1mgIdA9x0WTYIolHTSPVz9MsLPsVPN+eG1HjhVUvBTLeOvd92x loys= X-Gm-Gg: ASbGncs9DuhI036Zx2cpzUCNM8A3eKYtAvYGVvXixtxPmpRStkrn+cvIfmzeXXXaJ3+ m7zesD+VJ9WkUYkgzXTFau4ryKuig7RX0PMn1Rchs7UZTEv5r8a15zkABQQ0dRsVVPZ7FPhvGuS I4uzyPpVbTm3xN5XcLtO+lcMh7ND+PaUeRxQ0ri6EIuQD/VEOLUrRyistSGYreZbYhCdO2lAzqO mH19QMwdrSM82ZtRYAhmIg+WIyjsDHi8s4617icyq3Tc8HjqkvDXDIZ X-Received: by 2002:a17:902:e88e:b0:216:6283:5a8c with SMTP id d9443c01a7336-218d7249598mr7645705ad.39.1734475111497; Tue, 17 Dec 2024 14:38:31 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:31 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 01/11] tests/tcg/plugins/insn: remove unused callback parameter Date: Tue, 17 Dec 2024 14:38:15 -0800 Message-Id: <20241217223825.2895749-2-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::632; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x632.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 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 Signed-off-by: Pierrick Bouvier --- tests/tcg/plugins/insn.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/tcg/plugins/insn.c b/tests/tcg/plugins/insn.c index baf2d07205d..0c723cb9ed8 100644 --- a/tests/tcg/plugins/insn.c +++ b/tests/tcg/plugins/insn.c @@ -150,10 +150,8 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) qemu_plugin_register_vcpu_insn_exec_inline_per_vcpu( insn, QEMU_PLUGIN_INLINE_ADD_U64, insn_count, 1); } else { - uint64_t vaddr = qemu_plugin_insn_vaddr(insn); qemu_plugin_register_vcpu_insn_exec_cb( - insn, vcpu_insn_exec_before, QEMU_PLUGIN_CB_NO_REGS, - GUINT_TO_POINTER(vaddr)); + insn, vcpu_insn_exec_before, QEMU_PLUGIN_CB_NO_REGS, NULL); } if (do_size) { From patchwork Tue Dec 17 22:38:16 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851451 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp614866wrq; Tue, 17 Dec 2024 14:39:26 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCUQByG+TfbFOPhw4+UR1z5j5eonRFbEtJMNvrmtilvLjFbtFV2hbWzfAL6jvxZffDiKkALPzQ==@linaro.org X-Google-Smtp-Source: AGHT+IGR+hXHKfEzzNzu8qC3yS6NTE9KfdbNIja5GgS4fDh9162Em4gBTLBFmIgU0ByAflscHw2R X-Received: by 2002:ac8:7f4e:0:b0:466:b29a:816d with SMTP id d75a77b69052e-46908db2144mr10134851cf.3.1734475165688; Tue, 17 Dec 2024 14:39:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475165; cv=none; d=google.com; s=arc-20240605; b=UGLISlV0n+6N3OVDwuAcUPH1zUvcUUJN516Cdw5k3FRAzDxbcYwGEg6gi6k5xHcho/ 0Ar1akYPAycQlgmkl+tj00f213pukRuJ6lEK0dcJJct3F12T1F9e+CtMjLSa3dSFdbMJ Pxbs/bre28BriZBOcbTm4M9EpP2ClEJr/tPaonGkeBxY9OzXqkmHhP5UOFboveJib9HC ZKFZ8PbxTlyHZGk33/EygKT5P/nw2QAuFHhBeyknKcKlkxGq1QFgYPTvdjgeElVVwSSj ur0WTQS+t/9Qaln4Ot2er/r1/WY6ZIndQs7UI83JBfTaMwFE0BDwmFccyCqL8mpj6eu3 s7cw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=kntzVB1MiyL7bevKjAuLTyrUWmHMkhYgMIBRD8JjWYI=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=NYLT5AWN+fJVR6P33VoAd6XDo2huzWGKgKGKL9N642AMUT6VUlCcGNw3fSxozXyHST U5TmdtCdpxUvOXBfI8jQE+eAHZ2oNzHWgQU6iDbjXorgoJsXbFWwbQDGoc6v0j775ijt 13+SVGn5GVtTgJKS6/Lcn0Y6WHSZo5zgm17i9YZUSUAnz+gcYzdD9EoIdz6rMB+AxUtl PzllCuKDxmXHM6CogM28Onz/XJisZho2N+jr0f1NoO7Hm2sZaShH279p4ik9Bi+toPFH RHBlAEdmj2zpL5VUe8y++tNDw3SG2+8RnpASivanV0tbm7UzAb25AewMl4QAEC68BVdr L/Pw==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="jka0e2/r"; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d75a77b69052e-467b2ecf225si105750071cf.372.2024.12.17.14.39.25 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39: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=pass header.i=@linaro.org header.s=google header.b="jka0e2/r"; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgD9-0005Ly-Ma; Tue, 17 Dec 2024 17:38:39 -0500 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 1tNgD7-0005LF-Ja for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:37 -0500 Received: from mail-pl1-x634.google.com ([2607:f8b0:4864:20::634]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD3-0008Q9-Rj for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:37 -0500 Received: by mail-pl1-x634.google.com with SMTP id d9443c01a7336-2166f1e589cso60826695ad.3 for ; Tue, 17 Dec 2024 14:38:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475112; x=1735079912; 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=kntzVB1MiyL7bevKjAuLTyrUWmHMkhYgMIBRD8JjWYI=; b=jka0e2/rf1fDc5ExS59m06zL3kXhOAxCTG5Hz+s8CplkqIHkVPmFGGxGwhKOlrEElj c3MwdfqjiO1kCZdYkYwLUlHRFCRiER89tg6Gg2gIncm/44O7ZNbY/1HziSUdTDuEisWw 3S8Vrkcdmap0n92u/YDL57XHtrE1KzceKcSQdXEvn0Bn6QC3gUvhOMFy7HIyfeIpJD98 UVruR/+dDSIWHXEfI/dKzRbBRjauQ0oGs4o/pkL/djaZKt4nzlE1ZSfqMLY47VL/wIIP EOu/fQB9iZdswXjc2R2HlSolElQCksUswt/Kns1uVWC6mmbtYPrPwBV89mWBZmbxuq5q p6og== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475112; x=1735079912; 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=kntzVB1MiyL7bevKjAuLTyrUWmHMkhYgMIBRD8JjWYI=; b=e4RSpQsQbJh47hgAOGryD2lFXN85vJ85OzSk+0P36YPOziv9JvzL2yKsuql2Zn6+Vk mCiilNmwPQmbryNlVRMoMLXkckMYYVjZQlRGc/+3LEjLSen8xa6CYggxwnrN3bUbfw+5 FQnwDyvUYd0lvuzSPgZ+8fQ+r6zV2IhTWQnYMHdlbR8c+3zEX+RNoT6CVmI9Mdt5tf1m WgKv8piCwl8Mx76GKPT5lpWm8oS3DNjuSGW0w19jU8JsYDTy1WmiY9sykmNUoJWr3R7g MhmSAdtECZLP5JnUmk4bx+gCMp85iI5T2vI0WQVfHvq+bzE62u/wQCMrnWLkgAlBGBfZ pPiw== X-Gm-Message-State: AOJu0YwoFKxeSG5YK0eU+ie+nWyiRfOqJpxW3Rv6pkro/yOxQ8Jo78zz +3xbQQ2aGGEg03mjBTC/2rmZNdIDUTrVHuY6V5su+e2nTQvDC0O9eD2O8R7rC+ypwRFH6u6a31G zCiA= X-Gm-Gg: ASbGncu4FpBY4Q2LYMd2DxES+TUGk9XxY/MF7kJU1pB2ofC/WQi4dRNOhCiMtuoCZqi oJnDhuJLK1gQg4ckKYcyLOclvJDtvwIkY81T60GDTtkVqcDSazFVIWYI+r4nm99t2MH8mVVtwiR EP39oFfDR6c+R5nAxF28JEus+hRuK5Zoxpt5JMolJ91IDjUj2W96mnfIblciUv4pRo6sy4eY4Yg 0zOVbzkgwWa41ssUi8ayyiEtPK9ZHxkh+hW1gMDdAW/teUU68Rt5qPP X-Received: by 2002:a17:902:c94f:b0:216:281f:820d with SMTP id d9443c01a7336-218d6fd4bdamr6186205ad.11.1734475112348; Tue, 17 Dec 2024 14:38:32 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:31 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 02/11] contrib/plugins/howvec: ensure we don't regress if this plugin is extended Date: Tue, 17 Dec 2024 14:38:16 -0800 Message-Id: <20241217223825.2895749-3-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::634; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x634.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 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 Signed-off-by: Pierrick Bouvier --- contrib/plugins/howvec.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/contrib/plugins/howvec.c b/contrib/plugins/howvec.c index 9be67f74534..2aa9029c3f0 100644 --- a/contrib/plugins/howvec.c +++ b/contrib/plugins/howvec.c @@ -253,6 +253,8 @@ static struct qemu_plugin_scoreboard *find_counter( int i; uint64_t *cnt = NULL; uint32_t opcode = 0; + /* if opcode is greater than 32 bits, we should refactor insn hash table. */ + G_STATIC_ASSERT(sizeof(opcode) == sizeof(uint32_t)); InsnClassExecCount *class = NULL; /* @@ -284,7 +286,7 @@ static struct qemu_plugin_scoreboard *find_counter( g_mutex_lock(&lock); icount = (InsnExecCount *) g_hash_table_lookup(insns, - GUINT_TO_POINTER(opcode)); + (gpointer)(intptr_t) opcode); if (!icount) { icount = g_new0(InsnExecCount, 1); @@ -295,8 +297,7 @@ static struct qemu_plugin_scoreboard *find_counter( qemu_plugin_scoreboard_new(sizeof(uint64_t)); icount->count = qemu_plugin_scoreboard_u64(score); - g_hash_table_insert(insns, GUINT_TO_POINTER(opcode), - (gpointer) icount); + g_hash_table_insert(insns, (gpointer)(intptr_t) opcode, icount); } g_mutex_unlock(&lock); From patchwork Tue Dec 17 22:38:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851456 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp615070wrq; Tue, 17 Dec 2024 14:39:56 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCVbVKpGwdHbTcP4v35IuGv+42ctfGWlK+NsDo5tvwq8z9jelNUMVY3yj4W/LZBkgVoItdDWMw==@linaro.org X-Google-Smtp-Source: AGHT+IEsDuXP6g/55W5+9v+Q2NGA/WmQZUk0RvrBh3h1rgOL9qXVjzWSx/sWsslmCAD5g1mGaAtN X-Received: by 2002:a05:620a:1a0d:b0:7b6:dac1:cb81 with SMTP id af79cd13be357-7b8636e9464mr95876785a.1.1734475196495; Tue, 17 Dec 2024 14:39:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475196; cv=none; d=google.com; s=arc-20240605; b=KU2FxbB6R3pljmI0BZnXtMEPjcsoZopcQFnJRO0QF9waY0yVPKydZ5kkjQR9lOkxOR NRTZs4t8B3QdVoUphwNIjMfc/oVsiW7l4pciXvQE1//UNuR0mnvvtlCAQ9KdF2NsMQRL Tl2gC/CQOOoPtyiHM1eD3imgXhFEUKVb6cTjPahANGZ799pO3e93QToK5qILq+FmPpxX mWLVuxmxKpq5Hfh7P2K1VPge8l2Z8p86ILQ7pYv7/EDV2HTtBfgmtwaMJVX0GyPyh8G+ gfaCesU5hiitj1T4/dBmbnIOH76shIVy8D0hi1HWANDsyKV0QoB2q+08khz0xLwngyUe khxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=rYQneB+NKqjuG7StTn0XWLjAkA1JJLLeS7nr+5pDNNk=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=LbmVQ/YFrKk0aiyF29g1TcbE2UyW0DmEEoMHwlOW7e3R686rwUgigojXML9s3Z4N8O hS/AMnYUH9cdDACumPCNc/BuH3XUHnndu2lt0lYhUXazI6j0wdvqwaaO6uxFsTzEye/c 5Pw/NHA4xQxngfZ5HXxzmG214PKYznm2Ink+plEx1fjbfvlSQI31P6ZTuX/JdpoKQafQ RdAmm+22ggQ15JdT1L+xbsnCrVuep/LYT1SfnbAiWnT77Z6LcVdHKea0dM0MxCPAsRSz tbHxJA7RrJdEWjgZbZlCduB6uaIxmiRGo3z8eC93F5R+69SCQ4/q664n8S7sxLSYyK5V /aoA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="QfQwUY/m"; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id af79cd13be357-7b7048f31d5si1060894685a.634.2024.12.17.14.39.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39:56 -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=pass header.i=@linaro.org header.s=google header.b="QfQwUY/m"; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDA-0005M7-8f; Tue, 17 Dec 2024 17:38:40 -0500 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 1tNgD9-0005LN-0F for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:39 -0500 Received: from mail-pl1-x630.google.com ([2607:f8b0:4864:20::630]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD6-0008QK-N2 for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:38 -0500 Received: by mail-pl1-x630.google.com with SMTP id d9443c01a7336-216401de828so47026345ad.3 for ; Tue, 17 Dec 2024 14:38:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475113; x=1735079913; 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=rYQneB+NKqjuG7StTn0XWLjAkA1JJLLeS7nr+5pDNNk=; b=QfQwUY/maau59D4gTf2aCDO6uKr4ZwnoNrv3lJzhjQCi7o3qBhMDjfseOWp6l98e66 gu8KnxTILNks2p1rHAsBLOHrLbZWdBhDlJJ5Qlsc6QgxwPBpK2KY9bkHrdrCg2iwlAPn VQxnl4QU1v/hkw/TdkSsbzZ8c03/FWPzq9vtOxZRQBEmvXJztbHY5Lx67mg1skXHNGTS 5FvxlpORiNHBtYvmk6OliR1LmRxI54mxngSUXbJA67FvwwozFDx39q2yjRgKPd1D6Oop cBps+x6cIV6NUF0R+OqtzUALJRXPIU6AbHa4TUg3+I9SUB4RXXE2MBMBqC5la00NvEvs ufng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475113; x=1735079913; 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=rYQneB+NKqjuG7StTn0XWLjAkA1JJLLeS7nr+5pDNNk=; b=ILO5HnevVs9yw7p7QhFiXvq6yfZ0bytKS+EoTpmCFCcWiCoVED24FgrlO5IzumtGU7 /hdcqvdsUOBDxt8J87t/1vBa8LDidTsNMBQVf0N+MfCo3AtVPM1ihcKP+nSrCrcvN1hA e1q7a3j2JyKtabKqDDvHfuvbI1kOomZ5hDIdaDDmYG/els9jlaILt4Og6DHzxFFngNtD idQ07tqNasdQMKPEuyyOFSF4J3XLBSdBKuV26Xq+rLWZMOYmgzMHJWmF4d5mDypLxwt0 lLB/6NRHY9Qv2u+fIldR/0lsXeDO6mjbE7Ke8xUKNzE0HNwo/mAHR3iRerJQ0UDuONFU DsZA== X-Gm-Message-State: AOJu0YxnMakLIfAO3jjBOQRxnn+Nqi9tj9iWoa2q5WPqbMWB2qt3fTSq os3tBDyfwjsDVJ8M4/5K1LhOtPeEFf7yG77DSrjg0HfhgB89/N4pQqyWlZlLwsZBp5tXLPLnCFj CnOo= X-Gm-Gg: ASbGncslKhUWzmX1dfjALTpsTVIPbzjUwhxQiDe9zbCUTiRljvv+q7mxVEk1izZrOHE 5VC2bP1CbZrtXDDMtXcpjNh7McvkoQaIbV7r+TT2CHXIqvBBP1WXHWP4zh4b2WaV2zj82xgHs2+ vc7g+4TIFAfQ1OXX/QI6xbHvFPMW9j/oEhLt0axo68uOlXcocYTCsOEqajpydhuNaGeSv3BEg6Q f8SG0b0NY5NXLa0/rsu4SJiLsH5rgR6+QSAQfg6oL3s4lgM6JQ6ipkW X-Received: by 2002:a17:902:d552:b0:216:5448:22a4 with SMTP id d9443c01a7336-218d6fbf48dmr9236895ad.10.1734475113239; Tue, 17 Dec 2024 14:38:33 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:32 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 03/11] tests/tcg/plugins/syscall: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:17 -0800 Message-Id: <20241217223825.2895749-4-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::630; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x630.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 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 Signed-off-by: Pierrick Bouvier --- tests/tcg/plugins/syscall.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/tcg/plugins/syscall.c b/tests/tcg/plugins/syscall.c index ff452178b18..47aad55fc1b 100644 --- a/tests/tcg/plugins/syscall.c +++ b/tests/tcg/plugins/syscall.c @@ -76,12 +76,12 @@ static int64_t write_sysno = -1; static SyscallStats *get_or_create_entry(int64_t num) { SyscallStats *entry = - (SyscallStats *) g_hash_table_lookup(statistics, GINT_TO_POINTER(num)); + (SyscallStats *) g_hash_table_lookup(statistics, &num); if (!entry) { entry = g_new0(SyscallStats, 1); entry->num = num; - g_hash_table_insert(statistics, GINT_TO_POINTER(num), (gpointer) entry); + g_hash_table_insert(statistics, &entry->num, entry); } return entry; @@ -232,7 +232,7 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_install(qemu_plugin_id_t id, } if (!do_print) { - statistics = g_hash_table_new_full(NULL, g_direct_equal, NULL, g_free); + statistics = g_hash_table_new_full(g_int64_hash, g_int64_equal, NULL, g_free); } if (do_log_writes) { From patchwork Tue Dec 17 22:38:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851453 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp614955wrq; Tue, 17 Dec 2024 14:39:36 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCX4Si4VmdZT+nwrbV35eKiGizI7q/ndJ3XIAqWZc6qWdcfTG1hDlTMPmtkzYWkYURD/9eDYHA==@linaro.org X-Google-Smtp-Source: AGHT+IGGd/H4RUu6jjG1HGWxuviKai3fAcYTLtTC/LKPpb+sWgx9OBD/wqVN/RtJf6Df92VJNXHS X-Received: by 2002:ad4:5c64:0:b0:6d8:ac5d:b83e with SMTP id 6a1803df08f44-6dd092640d5mr14135996d6.47.1734475176385; Tue, 17 Dec 2024 14:39:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475176; cv=none; d=google.com; s=arc-20240605; b=OqzUkL8fWWHTj8tAwHq4YksxlOcfZK8m0GnleaGAscwX+hOrlvGKwaltrQQJfl8mDR 6oBp+I8N8IO+Ee3xaV1ulMNEJW+a9HxdC2J3W+Tx96n4QYLcf/j9RibwIY2Ipt5G7Hoj WUMa0v412IR3tUZAVHWrhBoPd2VE7BIQ/q3nIlyNdNoshQjncnJmfTPI81eExw01j0fc 8n7WE2SkYLjRMJFCmQCJcwZC/VALFnj09Zek4xcb9ks5VVKUyZOGSQr9WBCrBwnke44o 3VHIKykEiUA1299KRDY+s8OdFPLjDxbOHr1z9Ynv1Gy5pcqqg/tqu9zbIbiVSRaO3BAc ew0Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=rWJG60kb5t0dGokgOb8XWZnNeuJ8T72pjzJRQxGzMOY=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=C511xaEBINbYBo8KGEYpl1f9LbWmvU+yxF8NSjid5hXoF3VvTnn9TKpCe+bl9It28w taiw/dVF5Wqlcy/GscvYH1tI95sYKCFr5PT4JdXD4o+DhFs8VL+deF8XVFyxClmhLXu/ pFbyUBWMuZJGT8gMF1/gXSueT6SoFAQ/Q94WUqQhlO/SSVtMoz1yyrnLTg+fnHJecNpG dkD79MSLHJ5s3ukU9xij0zA/fRV/lkf3xRxy5t7nlHkATTf7k8j7M9QtPKUnmfZ3qOXe 9/G2o6LNMzRTAIhsuMsoBM5eGr3Wg7BGs7YgsMpM8IqRvk+9Njs68t8vPR7CmQkOHsHw rTzQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=krBFBrwG; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 6a1803df08f44-6dcf62e730bsi31852926d6.426.2024.12.17.14.39.36 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39:36 -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=pass header.i=@linaro.org header.s=google header.b=krBFBrwG; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDD-0005OB-7d; Tue, 17 Dec 2024 17:38:43 -0500 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 1tNgDB-0005NH-LS for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:41 -0500 Received: from mail-pl1-x632.google.com ([2607:f8b0:4864:20::632]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD5-0008QX-Lf for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:41 -0500 Received: by mail-pl1-x632.google.com with SMTP id d9443c01a7336-21634338cfdso70159465ad.2 for ; Tue, 17 Dec 2024 14:38:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475114; x=1735079914; 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=rWJG60kb5t0dGokgOb8XWZnNeuJ8T72pjzJRQxGzMOY=; b=krBFBrwG8AjIFDCCGxgjcFxTSWeuVKxXuGf90gPjzUgcOgbTdfjO/ZP1LdixetY4NH Eovy6VHCjOJh1nN5dQKdcrc6cwhUhWZKhLIY3JXuk7XR0Makn/RDHgglvN6+Vy2o+/72 7OH6WJ6pUf0NuFyXEfLaFA1B9KdQZ+4aO7C+ebDveTlwOlldHR2zow72Dv+YyIF70CMq yoOLlMGV16RdGYIcB0sBfIjCwLVhiw/bY1tvaiamodtYInSExD8Xoc3/LAlReCHpKnqu fj7rt4lDGjaJ36CrQI21ScnC+1NFOpAF22kHrwjRusJNhRsnDB4gK+jVM1w0H2tfYIku 4coA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475114; x=1735079914; 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=rWJG60kb5t0dGokgOb8XWZnNeuJ8T72pjzJRQxGzMOY=; b=nB7nqYbFNjeklc9CcPHhQsvXRSGg3yFp99r8lAml14Sx2PoJKUp4YW/mKPk5Idw11Y lcokXUrx75XuZ9WKhdV2F8NhA4UFR4MEL09YUiVhQ2Dl10SLzzwOM2ulI/NAMlCjRIu7 77reiq6aaI7rf6XXFAX5D4OQGAMqE26OWfySWYCvjoBocZBryfC/lUlmfAoPb9Btt/XZ qtQLq86uZOLOp86hyjnH+fTa1BEvnKhIW/BHQtTZ2+x93sx5iK7JrBDL2Zap+izFMil+ X1sjbU/9H06Ass13rHErapjVqUdE4ayEySFWb+Iog3W1I+Xd/FnKP1rvdJ8guwm0n5z7 6xRw== X-Gm-Message-State: AOJu0Yyy8WROtrLYXlJALKUUPzRPBoIiorbengrj5QnLysX43Ldr6Aiz ZCw0ZlToMvLVSaJxgSBX31ZhEa6V/bi6XRvK6NGI9+c8yyLsMDqe42b/E5XgrPB2SxLbKi8sA1z dSWI= X-Gm-Gg: ASbGncuTA0ZFU9ncF+BekSEdXpGTPMEuDpyGDSb6QI4QbfIObWJKC+seUc3QolktvcE rq9pq87GLNUsjOoZEhwLxwTu4MCr8sKQWVEf0PQvyfxs3oZBr+mzZbzH7tCGyc/8+RKTK6DlB++ FVAzNwXkGMWy5xNert8FjN/dymM0PN2371d8KY0Df4aMc5DFjOTVWD3Jkk7OZE9jznOOk+Hzfde EFE2sW0x1GvMDIvD1h6Bxl06+YGJmbXSqkNx89X2gFteDkPpiZFxAbR X-Received: by 2002:a17:903:944:b0:217:803a:e47a with SMTP id d9443c01a7336-218d6fcd456mr10047585ad.4.1734475114139; Tue, 17 Dec 2024 14:38:34 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:33 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 04/11] tests/tcg/plugins/mem: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:18 -0800 Message-Id: <20241217223825.2895749-5-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::632; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x632.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 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 Signed-off-by: Pierrick Bouvier --- tests/tcg/plugins/mem.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/tcg/plugins/mem.c b/tests/tcg/plugins/mem.c index b0fa8a9f277..d87d6628e09 100644 --- a/tests/tcg/plugins/mem.c +++ b/tests/tcg/plugins/mem.c @@ -135,14 +135,14 @@ static void update_region_info(uint64_t region, uint64_t offset, g_assert(offset + size <= region_size); g_mutex_lock(&lock); - ri = (RegionInfo *) g_hash_table_lookup(regions, GUINT_TO_POINTER(region)); + ri = (RegionInfo *) g_hash_table_lookup(regions, ®ion); if (!ri) { ri = g_new0(RegionInfo, 1); ri->region_address = region; ri->data = g_malloc0(region_size); ri->seen_all = true; - g_hash_table_insert(regions, GUINT_TO_POINTER(region), (gpointer) ri); + g_hash_table_insert(regions, &ri->region_address, ri); } if (is_store) { @@ -392,7 +392,7 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_install(qemu_plugin_id_t id, if (do_region_summary) { region_mask = (region_size - 1); - regions = g_hash_table_new(NULL, g_direct_equal); + regions = g_hash_table_new(g_int64_hash, g_int64_equal); } counts = qemu_plugin_scoreboard_new(sizeof(CPUCount)); From patchwork Tue Dec 17 22:38:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851454 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp614992wrq; Tue, 17 Dec 2024 14:39:42 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCXPJOw5pF1NkOpG2CA/bCmkVJmYyrC+sGfojMQTWIifUyHpxtjitWI7CAY8s9QmIv+rvvC/cA==@linaro.org X-Google-Smtp-Source: AGHT+IHlSuLm7RMx0PEFBzEmmA9sYR7Muog0HW8pLPW4fzUiekbE99p+3HfN2FVSMuORdpOOqUEj X-Received: by 2002:ad4:5ca4:0:b0:6cb:99db:bdd5 with SMTP id 6a1803df08f44-6dd09242337mr11558676d6.39.1734475181941; Tue, 17 Dec 2024 14:39:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475181; cv=none; d=google.com; s=arc-20240605; b=jwFI29wtb/edmEVNTBbVyjr/fyEl6X4CpPfh9uAHb+KMcFHbB8prdHxEXyvNKhFE4r yZY6Pxmkq9K6GGqM6/F7JzozI3/vJIkq64qTvG1ts6rMwaMLhGgi93XE0gIlhRKJRPrJ /c6rX/gtUPeRZ1g8GicpHBHjrm+JV+dII9YIwxoZIuR+qFGM0cKikJPWQRHb2Jbz997d 7XLg+yBa6w00k+RAod+G9xwZeRWik4M7DrPDH+sfhf+hRfqknBmMhTLkMkRxV6cMr2lU tkot2KLW5c7XXsdwIrvHWFIzUZ/jkC/MpSzPkiTbL8Jsy9bhFHiWf0dX9N9sycoT9x2i 9nWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=E0X1MlNNMfXe3fyFvrKoslEpzjFsMN2sr/cA5ARxGXA=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=iySBKLTQdtjOd+Jg0Td2fuRkibgaJi4OhTLC6TrrAwGwlICAwVA9ylix3yOvMNPjke wLvPNxiKpq+Yr+tQzES0zPPdkAULnrOC3vM0RwiyV/GY1sAEhKaNrt1Ouy8LqSp4Nyoc ljcjbem7J7SzMKvh6nHReX8Iry52cXfV3TzbzttYfEWyeXDKNaf3qjuxg81zPr3b45LU uvUPTu7yYQK0STp7kTrOkY8AuT6P52kMuAKZ302wggHiAt+iKQxW8ytcLPHz4LtzWw3J UeWkBlCJOlG7SK8lC1z/JxBNNfP9sFTZpf02HV7ekK0S99mjQSvo7jtT8HZtQtv8Jhvj wxTg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=En8MBjG7; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 6a1803df08f44-6dccd34a8ddsi111551696d6.260.2024.12.17.14.39.41 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39:41 -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=pass header.i=@linaro.org header.s=google header.b=En8MBjG7; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDC-0005N3-Dk; Tue, 17 Dec 2024 17:38:42 -0500 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 1tNgD9-0005LP-1r for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:39 -0500 Received: from mail-pl1-x62e.google.com ([2607:f8b0:4864:20::62e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD6-0008Qn-8z for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:38 -0500 Received: by mail-pl1-x62e.google.com with SMTP id d9443c01a7336-21670dce0a7so64801135ad.1 for ; Tue, 17 Dec 2024 14:38:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475115; x=1735079915; 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=E0X1MlNNMfXe3fyFvrKoslEpzjFsMN2sr/cA5ARxGXA=; b=En8MBjG74MYHh3CQGaJsTTwsEVOiFBur494oFJnlmwUQ5qDyZ5FY6aqjM4bIXGUOB1 xrdllORmBOdZJLFatBYRInrS/8VSUmp8xatIsZ60HK2Xym33JyjkDPX3HQAr3c/NktVO tJ8IykShlXF0+zq/3EQVSqqm2spsvi8VElIcGj4NYTaSqO4e7dUI/mOWN6fg0C/F85ZV FaRIysa9LTImTmB6iJ5mszej1CdznMZsHJY9F26htbVFleId8lOtrF+sIpi01Ye1PQDF RhAGlNYjS4ACz9/C0/HaNSmuwNFouBGB33nkF2VyHAbyMc1Vk3ZxFO0yXGy/VxGKddSL sVHQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475115; x=1735079915; 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=E0X1MlNNMfXe3fyFvrKoslEpzjFsMN2sr/cA5ARxGXA=; b=Cp1wxnF5SNe3IZLajFdbg/gVjCHQfF2zzo+2YRnMz2NqDO28RJcjaqY5IiTMbzB0i5 LD2+dSMJG8SM9L0kT/Dy0hofQm6zGhM2K3PWKUmLliEr1fXRNRMp5BEzYKIJv+yaI9Ar IhmUSLpe8yP57FwwnT7kdGa3JQLC4itEWjCwRrH4B76hL7/sDct0mumEH9qCGoUzvnUN ZWnGzrEAllLTxLQBQG+AAjEavfWqxt6C4NrAp8gDUCL+gtlA7OTW3rTqGnreohuf3TR4 9oHCslRmF7gRZdQKWxByIenPPZb0BiI9hKkskoEQ1/M0Yfk2ywPW9m2NLjgcSg0f5gAo zCDg== X-Gm-Message-State: AOJu0YxnrwmkVsLsULL5KChTBi5Cxz6cx7X9tp0WVv8iIDDIezkRt4q8 L3vcnliAHYKl/+z7DxBLCJDQSjN8FUpuXjNF8Kkahrb09qlxWdw4qm1zEpgRbmG3NcWuC0SraYp +T8E= X-Gm-Gg: ASbGncsI05Ur1+ATfnbu/tTWWAhGqPJDbJY6yoHwnvxHqCe6z6K9mw6gKc4m8gShJQF HjW2mx2Ac82dz+rzmo4njqPg6J+FS+9QnLfpf1hOCTe4zOdwIZir06wd0xg1AA5FZVlGw9YYHzr eGDjyigWwr0DsSg1FtBoGhEoLxUR5iRo3bnqEHlNu1Mllgc0q+yoMeOACftPXchJf1t0zFRXe7t 7g8vyfL/C0r6nP62kCY4WeDXzAUDcNvyIHpqiA9Mm3VhztLj4+yn22N X-Received: by 2002:a17:902:f68e:b0:215:7421:262 with SMTP id d9443c01a7336-218d6fc12bbmr8686415ad.12.1734475115015; Tue, 17 Dec 2024 14:38:35 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:34 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 05/11] contrib/plugins/stoptrigger: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:19 -0800 Message-Id: <20241217223825.2895749-6-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62e; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x62e.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 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 Signed-off-by: Pierrick Bouvier --- contrib/plugins/stoptrigger.c | 48 ++++++++++++++++++++--------------- 1 file changed, 27 insertions(+), 21 deletions(-) diff --git a/contrib/plugins/stoptrigger.c b/contrib/plugins/stoptrigger.c index 03ee22f4c6a..b3a6ed66a7b 100644 --- a/contrib/plugins/stoptrigger.c +++ b/contrib/plugins/stoptrigger.c @@ -21,9 +21,11 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_version = QEMU_PLUGIN_VERSION; /* Scoreboard to track executed instructions count */ typedef struct { uint64_t insn_count; + uint64_t current_pc; } InstructionsCount; static struct qemu_plugin_scoreboard *insn_count_sb; static qemu_plugin_u64 insn_count; +static qemu_plugin_u64 current_pc; static uint64_t icount; static int icount_exit_code; @@ -34,6 +36,11 @@ static bool exit_on_address; /* Map trigger addresses to exit code */ static GHashTable *addrs_ht; +typedef struct { + uint64_t exit_addr; + int exit_code; +} ExitInfo; + static void exit_emulation(int return_code, char *message) { qemu_plugin_outs(message); @@ -43,23 +50,18 @@ static void exit_emulation(int return_code, char *message) static void exit_icount_reached(unsigned int cpu_index, void *udata) { - uint64_t insn_vaddr = GPOINTER_TO_UINT(udata); + uint64_t insn_vaddr = qemu_plugin_u64_get(current_pc, cpu_index); char *msg = g_strdup_printf("icount reached at 0x%" PRIx64 ", exiting\n", insn_vaddr); - exit_emulation(icount_exit_code, msg); } static void exit_address_reached(unsigned int cpu_index, void *udata) { - uint64_t insn_vaddr = GPOINTER_TO_UINT(udata); - char *msg = g_strdup_printf("0x%" PRIx64 " reached, exiting\n", insn_vaddr); - int exit_code; - - exit_code = GPOINTER_TO_INT( - g_hash_table_lookup(addrs_ht, GUINT_TO_POINTER(insn_vaddr))); - - exit_emulation(exit_code, msg); + ExitInfo *ei = udata; + g_assert(ei); + char *msg = g_strdup_printf("0x%" PRIx64 " reached, exiting\n", ei->exit_addr); + exit_emulation(ei->exit_code, msg); } static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) @@ -67,23 +69,25 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) size_t tb_n = qemu_plugin_tb_n_insns(tb); for (size_t i = 0; i < tb_n; i++) { struct qemu_plugin_insn *insn = qemu_plugin_tb_get_insn(tb, i); - gpointer insn_vaddr = GUINT_TO_POINTER(qemu_plugin_insn_vaddr(insn)); + uint64_t insn_vaddr = qemu_plugin_insn_vaddr(insn); if (exit_on_icount) { /* Increment and check scoreboard for each instruction */ qemu_plugin_register_vcpu_insn_exec_inline_per_vcpu( insn, QEMU_PLUGIN_INLINE_ADD_U64, insn_count, 1); + qemu_plugin_register_vcpu_insn_exec_inline_per_vcpu( + insn, QEMU_PLUGIN_INLINE_STORE_U64, current_pc, insn_vaddr); qemu_plugin_register_vcpu_insn_exec_cond_cb( insn, exit_icount_reached, QEMU_PLUGIN_CB_NO_REGS, - QEMU_PLUGIN_COND_EQ, insn_count, icount + 1, insn_vaddr); + QEMU_PLUGIN_COND_EQ, insn_count, icount + 1, NULL); } if (exit_on_address) { - if (g_hash_table_contains(addrs_ht, insn_vaddr)) { + ExitInfo *ei = g_hash_table_lookup(addrs_ht, &insn_vaddr); + if (ei) { /* Exit triggered by address */ qemu_plugin_register_vcpu_insn_exec_cb( - insn, exit_address_reached, QEMU_PLUGIN_CB_NO_REGS, - insn_vaddr); + insn, exit_address_reached, QEMU_PLUGIN_CB_NO_REGS, ei); } } } @@ -99,11 +103,13 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, int argc, char **argv) { - addrs_ht = g_hash_table_new(NULL, g_direct_equal); + addrs_ht = g_hash_table_new_full(g_int64_hash, g_int64_equal, NULL, g_free); insn_count_sb = qemu_plugin_scoreboard_new(sizeof(InstructionsCount)); insn_count = qemu_plugin_scoreboard_u64_in_struct( insn_count_sb, InstructionsCount, insn_count); + current_pc = qemu_plugin_scoreboard_u64_in_struct( + insn_count_sb, InstructionsCount, current_pc); for (int i = 0; i < argc; i++) { char *opt = argv[i]; @@ -124,13 +130,13 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_install(qemu_plugin_id_t id, exit_on_icount = true; } else if (g_strcmp0(tokens[0], "addr") == 0) { g_auto(GStrv) addr_tokens = g_strsplit(tokens[1], ":", 2); - uint64_t exit_addr = g_ascii_strtoull(addr_tokens[0], NULL, 0); - int exit_code = 0; + ExitInfo *ei = g_malloc(sizeof(ExitInfo)); + ei->exit_addr = g_ascii_strtoull(addr_tokens[0], NULL, 0); + ei->exit_code = 0; if (addr_tokens[1]) { - exit_code = g_ascii_strtoull(addr_tokens[1], NULL, 0); + ei->exit_code = g_ascii_strtoull(addr_tokens[1], NULL, 0); } - g_hash_table_insert(addrs_ht, GUINT_TO_POINTER(exit_addr), - GINT_TO_POINTER(exit_code)); + g_hash_table_insert(addrs_ht, &ei->exit_addr, ei); exit_on_address = true; } else { fprintf(stderr, "option parsing failed: %s\n", opt); From patchwork Tue Dec 17 22:38:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851457 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp615392wrq; Tue, 17 Dec 2024 14:40:49 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCXQzWOv9f/uYrG+MBI83xAU/XbPSWzPq/iFyytvqd8P1+AecHjpZuw/hSitTTif5pT2W5ul6Q==@linaro.org X-Google-Smtp-Source: AGHT+IHvLwgX5kzbRakNN3POtBDsFlKbgnEXNnsi2YSMvCMiuPL0VxVC6jo1blwmteaxlUEGEv+4 X-Received: by 2002:a05:6214:1cc2:b0:6d8:a730:110d with SMTP id 6a1803df08f44-6dd090a7118mr14462386d6.0.1734475249200; Tue, 17 Dec 2024 14:40:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475249; cv=none; d=google.com; s=arc-20240605; b=OUytQRop+itQIprrbNvUG0ycZ6DHLl7jZAOHPvjb1hTmdkPZzocZFsl4sD4bzoAkIk HpPvusT9oKX1OsOl3D31L30m5Ie359SUbWmw2XbTXI2JPNFTeKGvx1KQrbMn0fYqP5gu MXxNvyvSw/90tzZmpAhviiml2uktwVkdTiBVCwBGdyYW9dRstLxOnTgLHik3mZLiFFMO 6OLXYsm7OBKCVsyi1C5pewWeMuQsLQQ319J2HAkWYZT19yNFgCS1RCpiQsNZ/A3s4r/K 0A0e3QJgCCKrEltNv9GJFEPWH559WUeRuxsxRpj0m97NjlDv33CmZhDMrQs3kMUi6BSI vFFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=7+nQuV745MSVduGtVwWvyxFW8ma4a2v2SK14uCf1mjQ=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=UwCLad1myIJcV++TiIyvDyBM8E9ZfoZzBnz0OfmMlUHAntKuTef2YWNH7rCXnE0csS jF+05FcIcqo0/4dxqIkKrpxVzBDZfh9r5pH7uHMzw+k13fYMJshoMRVt0+CRqkAhX/0D fz0lOgmwctGzB/7M4Uff8icPdmvA4YVjHVZIK7p3Ic6itxqffV7u+0P/kjCziF4cqyn9 t2WpNBFNOCC3nme6aQzfJh2qQuxy289/NPJ9POiV/0kyhoor5BljA0ous0Qak6MbzEAH b5UO3s5tpQf7xogbakPP9en+oBpKUwclAVVe5weXJfwK4pBUiRjDPOxag83lmTiVOSuP cwLw==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kPPHoLCR; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 6a1803df08f44-6dccd34d779si109765136d6.262.2024.12.17.14.40.49 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:40:49 -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=pass header.i=@linaro.org header.s=google header.b=kPPHoLCR; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDA-0005Mb-OW; Tue, 17 Dec 2024 17:38:40 -0500 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 1tNgD9-0005LO-1o for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:39 -0500 Received: from mail-pl1-x62e.google.com ([2607:f8b0:4864:20::62e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD7-0008Qv-4V for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:38 -0500 Received: by mail-pl1-x62e.google.com with SMTP id d9443c01a7336-2163dc5155fso51077075ad.0 for ; Tue, 17 Dec 2024 14:38:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475116; x=1735079916; 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=7+nQuV745MSVduGtVwWvyxFW8ma4a2v2SK14uCf1mjQ=; b=kPPHoLCR0u8ugTSQQMdt+HX83bUSVPMirb0nDnCxeMU2fWAapZYmF3OCkIcev/OVYr LlT4pC7CSnUEDhLztLEj+oZLo8dCowuGh+IHrvTvG7OZSUU3JtuHYOT10hPCp/283Y8V QQl3d/Pjf6OcNFJvzkZA0RUC6eKlCn+9rWjsWLQt8zJNNWf3LK2SOm0KDzHXXmFaTAHb /Aemvthn3byEGu+gfJZgHGa2qShIODSXMtc+LlmJKK9lwl9ee5KXVv8nL+hOdOUNDbWz icaIKWDj/WEFukpwVOw8EzXHHUlEn/qApNhI1gZuL2va9pWurHacc9WxhwWIRAFMGf9C FFeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475116; x=1735079916; 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=7+nQuV745MSVduGtVwWvyxFW8ma4a2v2SK14uCf1mjQ=; b=B2eRqdCLaOoDkQ/jE1fFPrlDsk8D9XlgMiVTpeJogwye/sC7PmBrWPQZ7tuQZt7uM1 9jv/ivlYiVz0iq1JVs/aXuo8BWI1QgIf78FLFcW0G//LWMedwEtf9lCxTHWA3e1lKGIV 0tZiAj2wnu2xLaZHIJDvw1eGs8MsDVx0HAooKx42DZDezadUJ9wyc2RDebb7kA/3E1Qm 6ewd7ZQ+YZR+JdSfQm2FiRyVl2QYNptWVC53za/moX9g5fsqG0afdvWHnUadbGEftMY2 2HIF1afcdQN7SnUSO7V+vBvvX8wLOPjjZeVQxBErdN/AJHzysYHH0GWVKoReY8vf9GlQ aZWg== X-Gm-Message-State: AOJu0Yz9Nrkqr5QgEO7oZesYDMjwfPNZwf6icDfJv5u85UCUIFO4/Ucw OCSvWnjSyLXgZwJebwg+o8U3VkWjxlYAcCl71GQH2jrbCz8IGpsceqZe+vKgcHH8BBjwJrm6pZw 9+xw= X-Gm-Gg: ASbGncvgqbR2rh14DK9p2Wl9gfdHrmPPl656hC1xZ5MWCSjNsPAcYrxiKLdyqQ27F1b uzHGu/om/5wPCKEgyZ6zbhdrq9mfB6LHuLloodRmk31MBVgrk2cTkilJ+BsNRJvAw2JdRJlvoYo 27xk0wNVNWULdxTSeYDan9ODjhzZ2cAABCyjclLiyCvDVpXziJWcDhdseyvecrJVuQxv7JI50EA bQQDa++zlZXW6SpKzgZLjYkzhIxMmJ3ut+oFov8tVFK0ySYT89xq168 X-Received: by 2002:a17:902:d2cc:b0:215:b8b6:d2ea with SMTP id d9443c01a7336-218d6fe4940mr5700635ad.15.1734475115897; Tue, 17 Dec 2024 14:38:35 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:35 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 06/11] contrib/plugins/cache: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:20 -0800 Message-Id: <20241217223825.2895749-7-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62e; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x62e.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 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 Signed-off-by: Pierrick Bouvier --- contrib/plugins/cache.c | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/contrib/plugins/cache.c b/contrib/plugins/cache.c index 512ef6776b7..7baff868609 100644 --- a/contrib/plugins/cache.c +++ b/contrib/plugins/cache.c @@ -208,7 +208,7 @@ static int fifo_get_first_block(Cache *cache, int set) static void fifo_update_on_miss(Cache *cache, int set, int blk_idx) { GQueue *q = cache->sets[set].fifo_queue; - g_queue_push_head(q, GINT_TO_POINTER(blk_idx)); + g_queue_push_head(q, (gpointer)(intptr_t) blk_idx); } static void fifo_destroy(Cache *cache) @@ -471,13 +471,8 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) n_insns = qemu_plugin_tb_n_insns(tb); for (i = 0; i < n_insns; i++) { struct qemu_plugin_insn *insn = qemu_plugin_tb_get_insn(tb, i); - uint64_t effective_addr; - - if (sys) { - effective_addr = (uint64_t) qemu_plugin_insn_haddr(insn); - } else { - effective_addr = (uint64_t) qemu_plugin_insn_vaddr(insn); - } + uint64_t effective_addr = sys ? (uintptr_t) qemu_plugin_insn_haddr(insn) : + qemu_plugin_insn_vaddr(insn); /* * Instructions might get translated multiple times, we do not create @@ -485,14 +480,13 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) * entry from the hash table and register it for the callback again. */ g_mutex_lock(&hashtable_lock); - data = g_hash_table_lookup(miss_ht, GUINT_TO_POINTER(effective_addr)); + data = g_hash_table_lookup(miss_ht, &effective_addr); if (data == NULL) { data = g_new0(InsnData, 1); data->disas_str = qemu_plugin_insn_disas(insn); data->symbol = qemu_plugin_insn_symbol(insn); data->addr = effective_addr; - g_hash_table_insert(miss_ht, GUINT_TO_POINTER(effective_addr), - (gpointer) data); + g_hash_table_insert(miss_ht, &data->addr, data); } g_mutex_unlock(&hashtable_lock); @@ -853,7 +847,7 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, qemu_plugin_register_vcpu_tb_trans_cb(id, vcpu_tb_trans); qemu_plugin_register_atexit_cb(id, plugin_exit, NULL); - miss_ht = g_hash_table_new_full(NULL, g_direct_equal, NULL, insn_free); + miss_ht = g_hash_table_new_full(g_int64_hash, g_int64_equal, NULL, insn_free); return 0; } From patchwork Tue Dec 17 22:38:21 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851449 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp614855wrq; Tue, 17 Dec 2024 14:39:25 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCU5wq+NknseMoSpmOXdAehw5Jc87VFx3Nb5RSVp9QbpfQRyJ+tn9cBAmOxN5X0/2cHwi83fsg==@linaro.org X-Google-Smtp-Source: AGHT+IFBmSV+l9A9CvRBLepwnBZ3/rrT8QFWZZBTuzTx3nIBPnF+inQ70dwVfLNplQ+xJ8/QEjPq X-Received: by 2002:a05:6214:e49:b0:6d1:7433:3670 with SMTP id 6a1803df08f44-6dd091927f5mr14177506d6.4.1734475164727; Tue, 17 Dec 2024 14:39:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475164; cv=none; d=google.com; s=arc-20240605; b=Hi2QFzQnrwXr6whuQNrJsKwfcZ8MetcCAxrvUbYVlzCLkjO/hT01cQltnb8p2nfTnh XYRE9O3wdN5IkMHLVSc5nGqbHyRhyvUtnj1zWTep37UFyBQia6L69y29bxOq31lhAyZQ jJBEVMXluN4M2LSnIBlOYv/5PoqWeXY8MxJKKf4zHHC9FwCo21QamoxiCCHkTViU9fI3 fEO2XWy8WrDLB6zD641/Wvx5329bpLk8jXnbZhe1e2xYfoAB1Sk5vs1yozNpSmgN8hjs gt7dAJdfm5Xh3YFzxIBL0TRk6WDcrd3ewLNbKcNhMpsQuQqPy07kKINqGeVQebkbgotZ vonw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=gSO3SqC3k3PD4UDj10nreaVmTIRbnjLL+fnwPXL6Pds=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=kBUvBxqPc2200+RC4AoEWgD+HxoFQ/1JQQO+KVMHcti4Q12V4mLAZw+9vfhyUcS+Df liKBvHdIPM8zumKSzFPx/Kcfxl/5OMF8vWYBrNEFd92WCjvpohnJ2xaV6BDUaoEvez8f 1mfZqDqV0PSfLDlEEhz4S73p+JjiyAIAFc5mgoKa8D1TFz+qzLMiOQveqWA2keqp0dBb TqrLtCpD0ZDqt/2i8c6Z3GsZ/fIlFzU5c00y46GFJpvMjERQyCnwebsFSD54vvS0FsD1 T2cSALUgLpLebXiRwPYGkbN4nPIVQtDb1Hfuuf1ST0RbWGOmXKb7NqwAuvltuiSTq/zN LeMQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=iAQ1m3xR; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 6a1803df08f44-6dccd3b80besi109538986d6.552.2024.12.17.14.39.24 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39:24 -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=pass header.i=@linaro.org header.s=google header.b=iAQ1m3xR; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDD-0005O6-73; Tue, 17 Dec 2024 17:38:43 -0500 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 1tNgDA-0005MP-GD for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:40 -0500 Received: from mail-pl1-x630.google.com ([2607:f8b0:4864:20::630]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD8-0008R6-2z for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:40 -0500 Received: by mail-pl1-x630.google.com with SMTP id d9443c01a7336-21670dce0a7so64801355ad.1 for ; Tue, 17 Dec 2024 14:38:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475117; x=1735079917; 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=gSO3SqC3k3PD4UDj10nreaVmTIRbnjLL+fnwPXL6Pds=; b=iAQ1m3xRzzMpmce7MRQ7weAI8b57xQxUdzDK95p4N9LsL/QgHdqn4KfsaBHx6RwzvJ J3C1d7n+dBkB1NQiTac+ZB2pge1cgsoLzPGbeDMpqlPMzh2mcGeX7UsnH/PwxRTF7+Vg r7W0O1mYGNwHvAnJ11doYZRsujy/QdRi/uDu14HVKfuOgu0cvMIXGDKTamv7zVfLC9i5 5dGWxOF04lx6wX0wa7jl65EASga47r124xzijPXH025p5H63cNmbecaE3l35kvsrfAtV 8xyxmXuwROnqdoduHN6QDtgRl4X8wL6z/FVtD8BvHKetihHw+clMMyLfRzXKGblT8iiU +j/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475117; x=1735079917; 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=gSO3SqC3k3PD4UDj10nreaVmTIRbnjLL+fnwPXL6Pds=; b=AU+Olr7LNm8RvXN8rRBAbLl7Cp/HCAnOQA244UKcHYxTKFsD/0i800Xi3HcsfJF1Ie Hj7+2NN1sHAyyn3G5DA5AZkxSnSjqn3Csi5nHwvz4zue2rIZcRXzTIAsQEpc+zDz7JpV e6F+6jcJCirnXuFY4nNyx9UgbaPSDgpeTtgFwKTOW1HV72Uj+dleLCvcP5OHqerjMKVf f4tV5IqqaeunvQfrwnl9Skp8HD6SCmQtNdV04h8uIADODF9rBi6aaIGZSoP/xm+JTLXt IxLwmkEaiKKe3dYQjvBrkHOgFyEGrs6FU4tTPlAZT1DH7OMzKlKqcB1Cy0GoQAa5jvS4 UxGg== X-Gm-Message-State: AOJu0Yyd16nVj00qXLA8m9VTes3uXIPMSPJFnp7IM/noZxH5vwLWaBkX fNbY40Wh2nQ3AYBEixa0WRjXclulckNfqiuDrIgMBP1uE44Cd/1VPkPNEPz+bQmSMsZm3S5lMYk S3b0= X-Gm-Gg: ASbGncsZtbSUu2Sj322O1mdfsUiQZjf4MCDSL0bsIjz1REJjcCFGOGVKPZOMYBIe5v1 Gv8EvcnexdvvRn4Z3JNM2sjqhBtAQghJO5bxzx2tgs7zcmX2+2pVA19mKgCoIC1l3N0O8aCJG3k 1oHBdPRXzjJlK6S0HDsoIS3Khwjy/CSru2c/G3J6Fu4W5Xk4vrpJA+E5qxRc6iFWXBJstRfMDQh Q5g+aN2XOpfGE+6RJ6uyCtwfobwCg866Vzh4Qd7l+8el9elS+2zRWgq X-Received: by 2002:a17:902:fc47:b0:215:853d:38 with SMTP id d9443c01a7336-218d70f6e34mr8595865ad.25.1734475116839; Tue, 17 Dec 2024 14:38:36 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:36 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 07/11] contrib/plugins/hotblocks: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:21 -0800 Message-Id: <20241217223825.2895749-8-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::630; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x630.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 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 Signed-off-by: Pierrick Bouvier --- contrib/plugins/hotblocks.c | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/contrib/plugins/hotblocks.c b/contrib/plugins/hotblocks.c index 02bc5078bdd..f12bfb7a267 100644 --- a/contrib/plugins/hotblocks.c +++ b/contrib/plugins/hotblocks.c @@ -29,7 +29,7 @@ static guint64 limit = 20; * * The internals of the TCG are not exposed to plugins so we can only * get the starting PC for each block. We cheat this slightly by - * xor'ing the number of instructions to the hash to help + * checking the number of instructions as well to help * differentiate. */ typedef struct { @@ -50,6 +50,20 @@ static gint cmp_exec_count(gconstpointer a, gconstpointer b) return count_a > count_b ? -1 : 1; } +static guint exec_count_hash(gconstpointer v) +{ + const ExecCount *e = v; + return e->start_addr ^ e->insns; +} + +static gboolean exec_count_equal(gconstpointer v1, gconstpointer v2) +{ + const ExecCount *ea = v1; + const ExecCount *eb = v2; + return (ea->start_addr == eb->start_addr) && + (ea->insns == eb->insns); +} + static void exec_count_free(gpointer key, gpointer value, gpointer user_data) { ExecCount *cnt = value; @@ -91,7 +105,7 @@ static void plugin_exit(qemu_plugin_id_t id, void *p) static void plugin_init(void) { - hotblocks = g_hash_table_new(NULL, g_direct_equal); + hotblocks = g_hash_table_new(exec_count_hash, exec_count_equal); } static void vcpu_tb_exec(unsigned int cpu_index, void *udata) @@ -111,10 +125,15 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) ExecCount *cnt; uint64_t pc = qemu_plugin_tb_vaddr(tb); size_t insns = qemu_plugin_tb_n_insns(tb); - uint64_t hash = pc ^ insns; g_mutex_lock(&lock); - cnt = (ExecCount *) g_hash_table_lookup(hotblocks, (gconstpointer) hash); + { + ExecCount e; + e.start_addr = pc; + e.insns = insns; + cnt = (ExecCount *) g_hash_table_lookup(hotblocks, &e); + } + if (cnt) { cnt->trans_count++; } else { @@ -123,7 +142,7 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) cnt->trans_count = 1; cnt->insns = insns; cnt->exec_count = qemu_plugin_scoreboard_new(sizeof(uint64_t)); - g_hash_table_insert(hotblocks, (gpointer) hash, (gpointer) cnt); + g_hash_table_insert(hotblocks, cnt, cnt); } g_mutex_unlock(&lock); From patchwork Tue Dec 17 22:38:22 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851448 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp614849wrq; Tue, 17 Dec 2024 14:39:24 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCWSj59U72C5dyaouLpuoHbPevTxQOJEyOuJrfBhEnsozdwxNQ5wsMLXLfOsJpfKTwVOw8Xkgw==@linaro.org X-Google-Smtp-Source: AGHT+IGDBE86CKKpYAzKQhEhAbLfntArcK1V6mMCPLyAwI+3/GZYcS+M8XBRZJWKegxNYTnduoRr X-Received: by 2002:a05:6214:c6e:b0:6d4:215d:91c3 with SMTP id 6a1803df08f44-6dd091db2aamr14851156d6.28.1734475163983; Tue, 17 Dec 2024 14:39:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475163; cv=none; d=google.com; s=arc-20240605; b=WuNZxdIzHQs98zm8pqKqwgsh46Di/60H42HBraSF5Jo9ZHkPsDmotlaK0HtpfMLYk8 pM43d+li7XssEDVCmAY+lSYkJPeJGYpfpemjnAGQgjdOK12l2jADwgJhvzL54vsCqZXs gtQDEXBChTpDE37VuOj1NkSo2ljhRviB7EtvYGo1glyAU1uXaZcninMdgEENq3zu0lYw SU5BF+tZAILi5rjiUf0Amyex48mcp4965S0a1viqdWx/cthJ++d73DJ/RLPBZaLQgsG0 70tgLjZckku2REsJ8DKg0JAeJD3M5ln952Jjfa7psBpnAILDpCpfoAIUWWUcCh6sXb+x ndeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=n/SJ8lccCav6ChcddekLPgsSkxigdbVgR6d9YvtHR4g=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=gD2ZXbmhWEAOs5+WNMQKlQ9QPhX7LGiUHUhe4PurNkxJssZo9ZBzoV4jLFGO0SE7Tx 9JJR34L5evRSjA4Aqfs99odmnUfNPJa+6g1tJFHUUjz7GTjXzFlDD3hZxObFq34wobnz OwVS4NuSLVcfCBhOsSyzW+mJuZrnMO/brk0wzOMAy6ws4EZzaLjX2KgNd7HLQboedZaz KCJMurcUDw7GN1Rk5b6G4BdYAyLkh1Ch+Mg2e3EAFR7aaOGJ77nZgeYJwSQv2vhSBG7K XfGjoyYpm/SF7yT72HCp8+5EozsZ3dZIuUV+6OLdssUh+ZZ6aBZLVU8MvWmleDX25n9A qm6A==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=EVZCPNmq; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 6a1803df08f44-6dccd34b476si104546006d6.185.2024.12.17.14.39.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39:23 -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=pass header.i=@linaro.org header.s=google header.b=EVZCPNmq; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDC-0005Nv-T5; Tue, 17 Dec 2024 17:38:43 -0500 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 1tNgDA-0005Mg-Q1 for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:40 -0500 Received: from mail-pl1-x62c.google.com ([2607:f8b0:4864:20::62c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgD9-0008RM-3G for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:40 -0500 Received: by mail-pl1-x62c.google.com with SMTP id d9443c01a7336-2166022c5caso46791865ad.2 for ; Tue, 17 Dec 2024 14:38:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475118; x=1735079918; 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=n/SJ8lccCav6ChcddekLPgsSkxigdbVgR6d9YvtHR4g=; b=EVZCPNmq+Y0Kx1X4rWnupSux7MF18Kx0VpLrF/nMeFGcyMlAtxHFuUTqyE+NK+dTTF sLusVFVbBzCo0g+OTqG3p7DslhJDrQHgcm8FIOK03a0EOvQmSzcgUvKdFd+NYOaAcaIJ 1O9d5cX+/Wo6muUXcswRDzoIr+TIg0kKPfRIf9kCHjLWS2+QN/2dnSo0dj02KhhnE73R KD6Q4rm8yReI0cuKERhR+0h57Dvscqkwm6OftqYC/q3c8QKTtY62e9qQJPya25LoOoFb u0ilVt4Z6IeIEhdOIL8uJQwxP9yiJszogHvYUuxfg8sfJC5Jje0eTvXuwf/yXMUdszY5 ft3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475118; x=1735079918; 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=n/SJ8lccCav6ChcddekLPgsSkxigdbVgR6d9YvtHR4g=; b=gZoY/dIglsfYVtDbSZK5F+vEn+kB48/SlkiuQFDRHY3Bg/5QdnnLsLupjPrF4ver0d UO5vjP+lvCxCJDaSDfCkeVhw3gK8BGJBE2ObSvQgc1Z/Ygb0KlL8zJYY4nXQ1WWMjXVB YWOMGzDmE7iUbi+Z+uLngMbB/3hkXm0Oi7kKyCqrrNGC0U5J0vJNjwqJz3IhI0bGz5G8 ywJb3E5doNDwKHuQHzg6B8JNJq7r3FksJs/2diWFr1bNg45YxY83pAqpCP+GuKqINkY7 FVtZ/jDpwtVIAlGe056WdTmMcjTyyDpvigFLgQaS9UFdBqD9vB9r+O6nQKAwsjCaOzCR bvkg== X-Gm-Message-State: AOJu0Yw4wHV0THWVieJzpXIUXrXnjXBQxFQs61lkHEofmUze989vmIoe tTdUK+qdWTKRIbX9wx8cxfl2tv47f+HzPiwFhe25Q6hlbAGtFrSvwLTktEUCSqWwMAiF+F57i0S /yac= X-Gm-Gg: ASbGnctgggYqW3thnhRpgctfLRCYF3XZB6UmBPiaShW1XEhlAp6MKilZjOM5rI0Eqwq MjL2lERX123XjVgyj8WgIO9sSqZaqYfLRjVG40dCPe6C9wdlkTBlkWBF8Im6oZDhCR5q1IPfy8J OrQ5F+vwzOhQJFiqQ7MDpIEVrz7Pa+7b3i9YE3A5vgO+JYxA5ArIHJ5mjI86X6ni17JoJ8vWKMT V/Zd3iyTQRgbhqveoVBasnjRdzjZujJHkwJdOaNqU7gKURrgl7wM2KL X-Received: by 2002:a17:902:e741:b0:216:386e:dbc with SMTP id d9443c01a7336-218d6fdfd08mr8068185ad.13.1734475117772; Tue, 17 Dec 2024 14:38:37 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:37 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 08/11] contrib/plugins/cflow: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:22 -0800 Message-Id: <20241217223825.2895749-9-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62c; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x62c.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 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 Signed-off-by: Pierrick Bouvier --- contrib/plugins/cflow.c | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/contrib/plugins/cflow.c b/contrib/plugins/cflow.c index b39974d1cf3..930ecb46fcd 100644 --- a/contrib/plugins/cflow.c +++ b/contrib/plugins/cflow.c @@ -76,6 +76,8 @@ typedef struct { /* We use this to track the current execution state */ typedef struct { + /* address of current translated block */ + uint64_t tb_pc; /* address of end of block */ uint64_t end_block; /* next pc after end of block */ @@ -85,6 +87,7 @@ typedef struct { } VCPUScoreBoard; /* descriptors for accessing the above scoreboard */ +static qemu_plugin_u64 tb_pc; static qemu_plugin_u64 end_block; static qemu_plugin_u64 pc_after_block; static qemu_plugin_u64 last_pc; @@ -189,10 +192,11 @@ static void plugin_exit(qemu_plugin_id_t id, void *p) static void plugin_init(void) { g_mutex_init(&node_lock); - nodes = g_hash_table_new(NULL, g_direct_equal); + nodes = g_hash_table_new(g_int64_hash, g_int64_equal); state = qemu_plugin_scoreboard_new(sizeof(VCPUScoreBoard)); /* score board declarations */ + tb_pc = qemu_plugin_scoreboard_u64_in_struct(state, VCPUScoreBoard, tb_pc); end_block = qemu_plugin_scoreboard_u64_in_struct(state, VCPUScoreBoard, end_block); pc_after_block = qemu_plugin_scoreboard_u64_in_struct(state, VCPUScoreBoard, @@ -215,10 +219,10 @@ static NodeData *fetch_node(uint64_t addr, bool create_if_not_found) NodeData *node = NULL; g_mutex_lock(&node_lock); - node = (NodeData *) g_hash_table_lookup(nodes, (gconstpointer) addr); + node = (NodeData *) g_hash_table_lookup(nodes, &addr); if (!node && create_if_not_found) { node = create_node(addr); - g_hash_table_insert(nodes, (gpointer) addr, (gpointer) node); + g_hash_table_insert(nodes, &node->addr, node); } g_mutex_unlock(&node_lock); return node; @@ -234,7 +238,7 @@ static void vcpu_tb_branched_exec(unsigned int cpu_index, void *udata) uint64_t lpc = qemu_plugin_u64_get(last_pc, cpu_index); uint64_t ebpc = qemu_plugin_u64_get(end_block, cpu_index); uint64_t npc = qemu_plugin_u64_get(pc_after_block, cpu_index); - uint64_t pc = GPOINTER_TO_UINT(udata); + uint64_t pc = qemu_plugin_u64_get(tb_pc, cpu_index); /* return early for address 0 */ if (!lpc) { @@ -305,10 +309,11 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) * handle both early block exits and normal branches in the * callback if we hit it. */ - gpointer udata = GUINT_TO_POINTER(pc); + qemu_plugin_register_vcpu_tb_exec_inline_per_vcpu( + tb, QEMU_PLUGIN_INLINE_STORE_U64, tb_pc, pc); qemu_plugin_register_vcpu_tb_exec_cond_cb( tb, vcpu_tb_branched_exec, QEMU_PLUGIN_CB_NO_REGS, - QEMU_PLUGIN_COND_NE, pc_after_block, pc, udata); + QEMU_PLUGIN_COND_NE, pc_after_block, pc, NULL); /* * Now we can set start/end for this block so the next block can From patchwork Tue Dec 17 22:38:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851455 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp615003wrq; Tue, 17 Dec 2024 14:39:43 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCWg44iv7XQ36a2SLWgXLJfMD1jNWZxoT2lQCNT8p6SC18TrbNVxSQ+68bTD3HxUJ0vPuqo8Uw==@linaro.org X-Google-Smtp-Source: AGHT+IFPJW3Pp4PH3Z2FAMKpE+M5HhuYUbZ+Zau3Zy/FEl92ks0pH58QIzKi4Fb6uF1BXdflI7ju X-Received: by 2002:a05:620a:404b:b0:7b7:5d6:3976 with SMTP id af79cd13be357-7b8638bff37mr93751785a.58.1734475183136; Tue, 17 Dec 2024 14:39:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475183; cv=none; d=google.com; s=arc-20240605; b=IvVzzDVlsbFZ7A2/P/lcjxi5MdPNmZXeb/HFD6tp0gVBxxGSEtC2+z079PqRbIKnU0 9MJ7dN6sDNTf1zEJQb9bFtDRdQ2HIo3DFDNN35O3ynO++8i0YexNW3OfHnRiWKQOCd7H YXshwTR3UjognJlhg9+URH+WSa4vfHQ/RF4l1i8DeWnnVZHtigheVSKp8/X9gohzM4Z6 sHkxP2EwyJ07TWWn/1b5lvFgpzDgzf9Br0HY+crSUEnNt0kSKjNenlAx/cGeuDzhnvjf a3OPjGXsWjJI9ejo0QdAhEIK/6/1fNPESy7EnzA2iXXHQr+uQu9+d1cfQjEcubl1+v9n /bZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=crzqjDJBZdpI+EWDwy4Pgv4ZHNVlbcwq1nqGrijGMLQ=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=cvxL9VGnpuflXMZvZwhLWEt0HoPf2I/leWOKYrJ68JICHneo66pGJ1g/ezx7YZ+zBq QX+E5Ku+yhmmzbRO0k6JJAVFLr9Ir0j0IwDoUQexFdxLClbvw3NIEmfBakKF1k+qR9EC kdZ88UMgLQmphztF1QK/vC6xnJ48lVX2R3GzriETjC+fsLkM4INCjeue3DcyI0PPwxe9 r9a58SiTS6aMWd23KVXmkBe8xEPeAWEe/R8QojjtfpArKzXC4rw6XQ9Dav04nlpMr85E K0WEXiP8nBmIIKIhZIh+nMSyrDpunDVBbo8PL92p0Q1cDSKIXaT+WXZSwiel+oQ/qpw0 ACiA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=GBakGgpd; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id af79cd13be357-7b7048be853si1072737885a.264.2024.12.17.14.39.42 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39:43 -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=pass header.i=@linaro.org header.s=google header.b=GBakGgpd; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDH-0005Pv-44; Tue, 17 Dec 2024 17:38:47 -0500 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 1tNgDF-0005On-IY for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:45 -0500 Received: from mail-pl1-x62d.google.com ([2607:f8b0:4864:20::62d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgDC-0008Rv-M9 for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:44 -0500 Received: by mail-pl1-x62d.google.com with SMTP id d9443c01a7336-2166f1e589cso60827445ad.3 for ; Tue, 17 Dec 2024 14:38:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475118; x=1735079918; 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=crzqjDJBZdpI+EWDwy4Pgv4ZHNVlbcwq1nqGrijGMLQ=; b=GBakGgpdlKbZZ+Bgs/BvkKHoBFTS690D/DbyPL1d8Sd2B6ZnKz8cDqAdSncW31wNfa IK0bHrX9rGBfzFxZdFIj54wHLkYrjphIHSR9A1X8+RDJLcH1/UI/wPv2WSe08TxvDbnC jhdD3G5vbr2iiHmY1sapgVaIhGE4kZWLpiqfDBqZpIo+ldZ04nxw2+aiX9FZX+iHxpYa xsphDre0CyDgnzFtC+4f13Fe6V0aP7Wg9NKxqYEzBQtGfaK3xa1gbN3SlrcEmIJLJflo 2cwU9YNPzx9sIRtHr3uPIhjJfLn1yORmkDbO72O+TNBVEb1hOOsLXBUXr57s8KHyrZgH 4ygg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475118; x=1735079918; 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=crzqjDJBZdpI+EWDwy4Pgv4ZHNVlbcwq1nqGrijGMLQ=; b=MSsK2ea2BN51O6JahGzeNK+zamO0TgIq03+Dre1yNSSa8pNsxRdXURLvjAYGcoC8xh 05lfYS3ugiDE+Y9D26a/UNriIdGfP0RbrY30A9QwJem8rxQwsBNfqQLu8tSsD/uS7Gvp 7ISwmmBTPJ4Kg7PwC/uSUNAXrJxEo3yi+XUbGHpYyPd0l2e7wcieEZ70+6X2jLTSvrKZ 17QHieexdLP7MQOW6709kyold1Qh0aA9EoZi54QkUA0RadyUE1tXT8VDSIROxiu4Wim/ qzHV7NkcEFlkLEbuq1l9yJjwZ0fkH4Yy16M07O+YjxWCZt4/8/IP2NRnvWjv/2a0pBAZ LeAA== X-Gm-Message-State: AOJu0YxNjzNF5Q+47G5zyPw2JEQ1a+up9qDW+SaP39DrtzcG+jUiZ95W bBdQOj2C6Sf2QxcuUCJCMihwCVoHO0Elvj/qJvP7e4Jh3plPbEzJmm0fpd62UVMFY6oUIXf89XI vxqQ= X-Gm-Gg: ASbGnct+pU8wvOzuvKbl7h6zT6RtLOITrjF6ZDq2uMfq9YTZ1pzZNMvWVHYKo0OowA0 cOYK0Wp14fDUYUfgZx2wfDasbGAouVb2VA1WmiIBoFI+h/dbBRXl6Thekgr6/EH5sv9XvGjCfhQ OyE/BRbmHQYCnU4nVYDIICLGArgYrnPHv5h1MLsiFMMh2hmZJ5OZUDj4Mc58FsUCuOjsREeMRXq t5yaVzyEwFxmBgUpIuofnSgZSfe2YR8yjD3NRQQTQwslwAYkDamFoXX X-Received: by 2002:a17:903:1250:b0:215:6f9b:e447 with SMTP id d9443c01a7336-218d722d546mr5866875ad.30.1734475118667; Tue, 17 Dec 2024 14:38:38 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:38 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 09/11] contrib/plugins/hwprofile: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:23 -0800 Message-Id: <20241217223825.2895749-10-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62d; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x62d.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 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 Signed-off-by: Pierrick Bouvier --- contrib/plugins/hwprofile.c | 27 ++++++++++++++++----------- 1 file changed, 16 insertions(+), 11 deletions(-) diff --git a/contrib/plugins/hwprofile.c b/contrib/plugins/hwprofile.c index 739ac0c66b5..2a4cbc47d40 100644 --- a/contrib/plugins/hwprofile.c +++ b/contrib/plugins/hwprofile.c @@ -43,6 +43,8 @@ typedef struct { static GMutex lock; static GHashTable *devices; +static struct qemu_plugin_scoreboard *source_pc_scoreboard; +static qemu_plugin_u64 source_pc; /* track the access pattern to a piece of HW */ static bool pattern; @@ -159,7 +161,7 @@ static DeviceCounts *new_count(const char *name, uint64_t base) count->name = name; count->base = base; if (pattern || source) { - count->detail = g_hash_table_new(NULL, NULL); + count->detail = g_hash_table_new(g_int64_hash, g_int64_equal); } g_hash_table_insert(devices, (gpointer) name, count); return count; @@ -169,7 +171,7 @@ static IOLocationCounts *new_location(GHashTable *table, uint64_t off_or_pc) { IOLocationCounts *loc = g_new0(IOLocationCounts, 1); loc->off_or_pc = off_or_pc; - g_hash_table_insert(table, (gpointer) off_or_pc, loc); + g_hash_table_insert(table, &loc->off_or_pc, loc); return loc; } @@ -224,12 +226,12 @@ static void vcpu_haddr(unsigned int cpu_index, qemu_plugin_meminfo_t meminfo, /* either track offsets or source of access */ if (source) { - off = (uint64_t) udata; + off = qemu_plugin_u64_get(source_pc, cpu_index); } if (pattern || source) { IOLocationCounts *io_count = g_hash_table_lookup(counts->detail, - (gpointer) off); + &off); if (!io_count) { io_count = new_location(counts->detail, off); } @@ -247,10 +249,14 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) for (i = 0; i < n; i++) { struct qemu_plugin_insn *insn = qemu_plugin_tb_get_insn(tb, i); - gpointer udata = (gpointer) (source ? qemu_plugin_insn_vaddr(insn) : 0); + if (source) { + uint64_t pc = qemu_plugin_insn_vaddr(insn); + qemu_plugin_register_vcpu_mem_inline_per_vcpu( + insn, rw, QEMU_PLUGIN_INLINE_STORE_U64, + source_pc, pc); + } qemu_plugin_register_vcpu_mem_cb(insn, vcpu_haddr, - QEMU_PLUGIN_CB_NO_REGS, - rw, udata); + QEMU_PLUGIN_CB_NO_REGS, rw, NULL); } } @@ -306,10 +312,9 @@ int qemu_plugin_install(qemu_plugin_id_t id, const qemu_info_t *info, return -1; } - /* Just warn about overflow */ - if (info->system.smp_vcpus > 64 || - info->system.max_vcpus > 64) { - fprintf(stderr, "hwprofile: can only track up to 64 CPUs\n"); + if (source) { + source_pc_scoreboard = qemu_plugin_scoreboard_new(sizeof(uint64_t)); + source_pc = qemu_plugin_scoreboard_u64(source_pc_scoreboard); } plugin_init(); From patchwork Tue Dec 17 22:38:24 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851450 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp614864wrq; Tue, 17 Dec 2024 14:39:25 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCXckVmkx8KuZ+0tgGMXBjhFUHMMgHJJm+JRGM9gKaB4XPoby35Z+DYfRmEU5H8AsBxdxOuKGg==@linaro.org X-Google-Smtp-Source: AGHT+IFnSo8vrdOf189c8a/Lm63PSlJm6O2dgIub3yDMKV1DsMiBJ8rIEu81FZ0+JFUg4LqBxOHQ X-Received: by 2002:a05:620a:4103:b0:7b1:12f5:7af5 with SMTP id af79cd13be357-7b8636e8502mr83121585a.3.1734475165574; Tue, 17 Dec 2024 14:39:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475165; cv=none; d=google.com; s=arc-20240605; b=S6SqYPowXyazYAa7wdQ+KUVhtJR3Hje89/L1wVPQmy9L5yakNsF2ocCZq3FdAuGRzg 6nmg8h2VAttmnXT2oK3i8SmqowrV8XZhilKQn/w/NhVFe43d9nStT64EV614m4c+N1qu 8QrbaRuKj0BYUlIDke9UX3HPyE+B7gfPbgL0/tRE9AONANgEIsnBykaYu4r+1sJaudQJ ZnktjRgsB5VKjAwpYZc8n9qB6YwN/n3r6/rt5eJUODIiecunRBmQb4cLGzta9jewTc+3 FVAn5pceaSTkx+JxBIBZDLJRgz+sOE1H0O3eL4HGt5IOTXpgHUIu3Z6o6Rdp+z8CwP0c 0KXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=TUx/z/kSAyzvf2YQEv1ycgw2smpEnSTqQjMUa4oS88s=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=gqxk9ph8J6rYlNkcmh8kd6ZIsLgLzH83VReP9ZNbfdfxA2vu2x9Pz+yrjS+UFLZBKa yicYjteGu3myzkBk6f8vCEfzUgmkB8XV3mpnlsb0nYP/6itRgC9DQWQwpts5H67z3wx7 7KZu4EQ80Lxn5suSGoQtaMac+1ZfNFETBpbIr3uRr6/Yc/Yxu2t9+V+NrMrAdLorjJEw iPFO9U29tvEN4/ZaSiM9mDXKTSDIfBkfVJ/LflZslrNhFujoY2xNa6RlLZVHM6ge7x81 SVgUwkRdK+H3tKKSO+ODI7vE9F/L0cLXBR6S3Yb8SEBS3wlnnKAVFtbBTZuj8cXQvAoU qzdA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dGsTA6a2; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id af79cd13be357-7b7048e44f1si1291706885a.552.2024.12.17.14.39.25 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39: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=pass header.i=@linaro.org header.s=google header.b=dGsTA6a2; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDE-0005Oo-Ms; Tue, 17 Dec 2024 17:38:44 -0500 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 1tNgDC-0005NX-Ja for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:42 -0500 Received: from mail-pl1-x636.google.com ([2607:f8b0:4864:20::636]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgDB-0008SJ-4U for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:42 -0500 Received: by mail-pl1-x636.google.com with SMTP id d9443c01a7336-21619108a6bso44650615ad.3 for ; Tue, 17 Dec 2024 14:38:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475119; x=1735079919; 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=TUx/z/kSAyzvf2YQEv1ycgw2smpEnSTqQjMUa4oS88s=; b=dGsTA6a27CRLRR0SkoTzkDvDT4QSGAmcYpjbnId48ypKSJWdedJu7btzVkSNaEvB/j GxvjshG4+Urcq8sTX6AAon+15G1tLItGSlthU00N/izQ/cUwOQuwxX6f9uZzlWNcd3DJ 2n66znSXOu0BBlwo4BPRtKWMBf68ZsUMSZtKP4UuPcwfxm5QOHg18Uy1+2xrdqXWQDcC XaYrb5Az/ioxMgJ6FOU79rH1Y9EA6sW5x592gFeTnJiKg3PbEk0LoyCpXsAUcmVjLGTI y5hv6TVk7I6Q9oc1zHiat89zaEGfdzJ6H4+xf8XcAzcUva7BjgNK374U8g4xYphLSteX gSKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475119; x=1735079919; 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=TUx/z/kSAyzvf2YQEv1ycgw2smpEnSTqQjMUa4oS88s=; b=tq1s/9lC7HMpIKqePxTYekCikZBQF0b6Ywjxu2xLKKuXiIPz3W+tj1b89tm/FQaQp3 MO4Q2mkG98wk0aoHRJdCDiNZZaNj64J6S9deB08sPv3EcoRhO9Fd3JR0+MSROauoDknB sTgi1WNmT9K2db4jOO8KHeUON8cbuovEGX14lcUN7iSHBeFRf5Ylbxm79viKYlbRMtJD g5ZAV6dfXsWw9L8a1XeQULrHe2CifrJWzOOxpe5WwY94HlDZFcocTJay8HYlqEx5+BLU J5i8jsE7O3KuJFB12CKvVuq4xniuWUXzMRFBYf6E88PtUCgH7cIC0g4hy/Gv1QBYqwUm HJbQ== X-Gm-Message-State: AOJu0YzEc7+bDUn1HaeBiGqtTY65XSbCpGtjJZOc4XzRxVk41Y2rnTDD cQ3VR40KA6xrloXFdZFniMhqMhXVXf4xZiStQfUZnYG0QnzAaL2vsMDhGouHZ03T4ezn3OLugLF GnLg= X-Gm-Gg: ASbGncsroFAS0vuhdGJRRHW9iRMbtW/7oOPzBFHE0f8Er/9DQYW60fQrueH5hCHv8Yo his1FyABr/sa7tPMPvb1tm86GGyS6gibY7HWnjq8t+f4Utcd9AdlVUmdbvMWXI3mAd4FNWx5zX5 LAlzeDjPqvP0d4zH3fNZvy+enUDGp/2a6ePdFTA8M84TUVEW0+52A+cOjdeXAZ5+WU4/y1bv+NM KPn587M7jQ3mpCG4/c5XWo+fXUPIy8hdngEWqK0OqAvkD3pg9pH6sgp X-Received: by 2002:a17:902:e741:b0:216:6fbc:3904 with SMTP id d9443c01a7336-218d6fe1aacmr8664245ad.13.1734475119543; Tue, 17 Dec 2024 14:38:39 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:39 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 10/11] contrib/plugins/hotpages: fix 32-bit build Date: Tue, 17 Dec 2024 14:38:24 -0800 Message-Id: <20241217223825.2895749-11-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::636; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x636.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 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 Signed-off-by: Pierrick Bouvier --- contrib/plugins/hotpages.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/contrib/plugins/hotpages.c b/contrib/plugins/hotpages.c index 8316ae50c72..c6e64937194 100644 --- a/contrib/plugins/hotpages.c +++ b/contrib/plugins/hotpages.c @@ -103,7 +103,7 @@ static void plugin_exit(qemu_plugin_id_t id, void *p) static void plugin_init(void) { page_mask = (page_size - 1); - pages = g_hash_table_new(NULL, g_direct_equal); + pages = g_hash_table_new(g_int64_hash, g_int64_equal); } static void vcpu_haddr(unsigned int cpu_index, qemu_plugin_meminfo_t meminfo, @@ -130,12 +130,12 @@ static void vcpu_haddr(unsigned int cpu_index, qemu_plugin_meminfo_t meminfo, page &= ~page_mask; g_mutex_lock(&lock); - count = (PageCounters *) g_hash_table_lookup(pages, GUINT_TO_POINTER(page)); + count = (PageCounters *) g_hash_table_lookup(pages, &page); if (!count) { count = g_new0(PageCounters, 1); count->page_address = page; - g_hash_table_insert(pages, GUINT_TO_POINTER(page), (gpointer) count); + g_hash_table_insert(pages, &count->page_address, count); } if (qemu_plugin_mem_is_store(meminfo)) { count->writes++; From patchwork Tue Dec 17 22:38:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 851452 Delivered-To: patch@linaro.org Received: by 2002:a5d:4888:0:b0:385:e875:8a9e with SMTP id g8csp614898wrq; Tue, 17 Dec 2024 14:39:29 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCXirHi3k8DuWUJ+pOB/s/rlrHi4/JkprIKeAlqV6n1Qu4VXVOmh0UgpNiWj35ZQO+0MjkO5tQ==@linaro.org X-Google-Smtp-Source: AGHT+IGQyY9BAkbil+5Gyq1B/il1B/5jyuebCf6HFNqnO2pU6YvFup3VbQNpINQO5YlY4MBjwprN X-Received: by 2002:a05:622a:120a:b0:467:6e25:3f3d with SMTP id d75a77b69052e-46908df58f8mr9357361cf.15.1734475169715; Tue, 17 Dec 2024 14:39:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1734475169; cv=none; d=google.com; s=arc-20240605; b=QCwMNIlDI2U7Ss+9Qo+aBrqkRHVpl9Ut24cMn/5XJ4vWYK5PHkqj6tyXX/mgVCXyQh Ly0iBRct0T0U8aQVkcPHcHsM0oL1fuuM5CaO22QU6YoOpgyX7EIsK3m4bDXi/ENIEthB 20Yk5syW63mtDahFBvGnMrs9ibzkEFEsTQvgYCqPoyCwZtYSBClBK6dBvfft4WUxlde2 WAaAnbk9s6pJrSNHikCqhHzRRWzYZBgRJGA8no3qZjOZUpavs0EY0VnqQlOwv/7HRmts a89ZTEsq4EUMHmDqGPENCUwidmbrdQvi1ejUmMkLkhp0IwmAHyN/tCdz4zKozu9uiP2+ TksQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=3xW+LPUYaCaHyMzbWV59CTTMsUuCbv/1PDmcaQ3NGQk=; fh=+NflhOdr9R5O8MPEqbGfWeoDmt6zsMvcpjNabm4DZ9U=; b=WUogC7tgz5iSM2Q2TYwLyGRJ8jGQ7xMh28wVP9sh3Dvxt3EUcr06MBu1mj/iIxO5Xx WVxHr/WovKilB3976TsvuAjVFfpZnP8/RMVvBz9QPx/dWowboumqnis60HPdP65PVUD3 WvagIAxe91vP/qbFtj7JczX3mD/gA20r48aEAmoAf8gMkNT0gr6NXRa6XJ2c4rNfIl0Y /CfxLENkQqogFyyNmeSkyRHHbrDhT1Mf7I3/g01LI/1Am2czYSxkHwQnFsxpaYsX9Lg0 1EGvcNhavQcVuHb9ExY6BBye0o0gGN/3+gnhz2ZYOrcOCX8Rnwhd0snDKhydoCwfM5H0 1+xg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=CCkjTQjL; 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; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d75a77b69052e-467b2c965f0si105013231cf.130.2024.12.17.14.39.29 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 17 Dec 2024 14:39:29 -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=pass header.i=@linaro.org header.s=google header.b=CCkjTQjL; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNgDG-0005Pk-4d; Tue, 17 Dec 2024 17:38:46 -0500 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 1tNgDE-0005OX-9N for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:44 -0500 Received: from mail-pl1-x62b.google.com ([2607:f8b0:4864:20::62b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tNgDC-0008T3-Qx for qemu-devel@nongnu.org; Tue, 17 Dec 2024 17:38:44 -0500 Received: by mail-pl1-x62b.google.com with SMTP id d9443c01a7336-216426b0865so51614165ad.0 for ; Tue, 17 Dec 2024 14:38:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1734475120; x=1735079920; 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=3xW+LPUYaCaHyMzbWV59CTTMsUuCbv/1PDmcaQ3NGQk=; b=CCkjTQjLWhM9bTrMnw0zuaonvWrLDP3CTK9/ldWFAWCsMw1GNnotodJk27GEXj44By RNw+7LDssKn6TzSh3nN6Mh1Gs8D0lKpe5QvxztDJXAFLAkQc+K5gTsA8I5Lpga8V+Eo2 tv/guzw1njU8WQmHm/7dhRvz7iuodDmBe2GMgXhMrlUEd1bUZ1wq6C+X0fl+kDRFD6Ew qgW+7GtWBgL3ZwROkKx0pwZQhvUQIP3eLAxHkSpy0zHCSmEHaDjkT2if2qvUegGM2WRP Ryzj3xQvA39AKlC4xKWvH2+xgtBmrwUgD9DqIIaE9cPHJmiSiLOvDLuhPkN9wLctP1Xj DuOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734475120; x=1735079920; 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=3xW+LPUYaCaHyMzbWV59CTTMsUuCbv/1PDmcaQ3NGQk=; b=sZ0NiYjM3tr2uhefi976Bj5VjooQVYjRkvGitt99RvjBlXOSupzUzTul7nHnXZhzSH /+MlAOeIHDKqrfTgSy20wv4Qc2oElyFD204ZmgQ/QQOpbipLPMXjILvxD1Z9XIQVRr1D CFtsHeFhE+9aNmzHw4MtYuQv7KEyUpEDOfHhNtrMYBhDjVEYQGw+rigyTtVf3GnUWWR0 3wWurx2LXp/hLS7K8KRMBvB55k/RtY2T/XGweqFmdiVzHBFtZHo9zTWV+3yEpmoYuq/Z VM34XquigS3IFJb07S2Swr40f6UXCd2iHzQK1BFmvIzNHuJ8ExJyKhPqQL6UOYBIzwZn rEGA== X-Gm-Message-State: AOJu0YxR31AwYQr8umhPshMVoODVBdU+TAWoQaNa1aBqGLLlCq9VahCQ P4EQfhikhPy2PoKIR5l0WktLZacDCCiLNOO0CRYbVhgJq0xw535JmaFgY734EYsTUZpghaUi0Fk kus0= X-Gm-Gg: ASbGnctzEoE4ZfZ/prvWFZU3asBQ5LgmlNzSTE4wYKaXaXPSC9+eaerbpvAGlhkZF2W dpSOeiR2kZZxO5OErNQHJlabJnidCyQlFcEmebHowlVx0SYCL+QxOC4mUxt3NEaSoUHEeEAwTyz +TY+xt/oYxcUiEMPG9/BRSZbrX1gfJvaa9wfvEFvBLf4rhUbVTFTPjzr2IieMIVBnREEZ1LVwTE ZWBoTxRxYFPDG8LCq+IH0Fs61onvfUPwUVnPa7jUDgMc4bmol79vjdi X-Received: by 2002:a17:902:e807:b0:216:30f9:93d4 with SMTP id d9443c01a7336-218d6fbe4e3mr8318695ad.8.1734475120440; Tue, 17 Dec 2024 14:38:40 -0800 (PST) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-218a1dccb03sm64869465ad.98.2024.12.17.14.38.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Dec 2024 14:38:40 -0800 (PST) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: Paolo Bonzini , philmd@linaro.org, Mahmoud Mandour , richard.henderson@linaro.org, Pierrick Bouvier , =?utf-8?q?Alex_Benn=C3=A9e?= , Thomas Huth , Alexandre Iooss Subject: [PATCH v2 11/11] configure: reenable plugins by default for 32-bit hosts Date: Tue, 17 Dec 2024 14:38:25 -0800 Message-Id: <20241217223825.2895749-12-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> References: <20241217223825.2895749-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::62b; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pl1-x62b.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 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 Signed-off-by: Pierrick Bouvier --- configure | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/configure b/configure index 18336376bff..02f1dd2311f 100755 --- a/configure +++ b/configure @@ -528,25 +528,6 @@ case "$cpu" in ;; esac -# Now we have our CPU_CFLAGS we can check if we are targeting a 32 or -# 64 bit host. - -check_64bit_host() { -cat > $TMPC <