From patchwork Wed Aug 14 23:36:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 819156 Delivered-To: patch@linaro.org Received: by 2002:adf:cd01:0:b0:367:895a:4699 with SMTP id w1csp921063wrm; Wed, 14 Aug 2024 16:38:27 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXKpDiRWtq++T4Oi78GAk/SlJOMBquf2z+6knjcTN7SV0LZmRRfNfENuZ4eibve1Wb4Dy+nPn/BZFHU6M1tDDqi X-Google-Smtp-Source: AGHT+IH6sqPXIpOzWHQHjecLZDbu3Ct5VLNA9eTrsADis5h0y07ws7jlq7j/H3HLu1xtvpkp35Pf X-Received: by 2002:a05:6214:4685:b0:6b2:cf9e:866 with SMTP id 6a1803df08f44-6bf5d15a546mr45137156d6.4.1723678707578; Wed, 14 Aug 2024 16:38:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1723678707; cv=none; d=google.com; s=arc-20160816; b=LTFCO2TDF8fKNK+yeE/Ep4v+j1C1RrIRYl2CLU7/N74N5eGYQ09aQbe4s4wvtyxUl0 hSwhW6IQ4HIJmwrvn/lgwNl1I4CQVmZF/F/gJ9DEUV/Of8x83z9Z4kbHmg10UHxtmMGP 2G3vGp+s4cy6ptdb3qT90rdLs1sIAqFVRIWfmKvMGuBdGLEjd7Jzf3nofbU4Z7laivDU cD0VHJptATfIpnd8fgp32/3l4CNPOs8m7BuKAG90NLgUA3NFRy12id54fxlX8UY51lFf iBvJRw0VYAOjB+nV2y4rzdVbKUtLsWb+6MQ0VvDAfDzV/Xl+K4oXfAnUm6CoTmv81iQm gNdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=I0fMYCzEpAflnqdXJ+mHKpT1nx2a+UfFr0qfxTWmEKw=; fh=oXkr8tRtU3V0Y/ys4wmfLP1vjmnh5XTVxxercrnp+aA=; b=CzKKF2hFS5RWH3+yfCj/qaxi/M2c3FXbtPzI5mPtJe5PCxt1ub025QPREzX72Cae66 ia2t2lnxrt6HAJ0GBBW8W4lAJJxZEiyc76aBkPXN3eIL/4SgdpWMEfcjHnDQzimLsNmP bP0dGyBD8hICxSy7bZ357Unw1vTQ7BRuOwXveD4+vZrIhoesAtfmZaNzABAb68eIWTc8 wF03Gc0sj2rSZy6RVnVE+ZGimNP2LQFpDvhGKNKdU9gEdpw9pvkxARkCGrNxC2jDAgQt juNcBbndDRO8sA0vUg1u3SUKwD02PbGQat+dbEv6PwNfs2yPbbx+Z3fXNwAg/UvS0biH uCcA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=qEDVlhdf; 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-6bf6feec68esi3642516d6.359.2024.08.14.16.38.27 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 14 Aug 2024 16:38:27 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=qEDVlhdf; 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 1seNY4-0001dJ-E0; Wed, 14 Aug 2024 19:37:00 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1seNY3-0001cq-Pf for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:36:59 -0400 Received: from mail-oa1-x2c.google.com ([2001:4860:4864:20::2c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1seNY2-0006Vt-Az for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:36:59 -0400 Received: by mail-oa1-x2c.google.com with SMTP id 586e51a60fabf-26ff51294c4so340074fac.3 for ; Wed, 14 Aug 2024 16:36:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723678616; x=1724283416; 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=I0fMYCzEpAflnqdXJ+mHKpT1nx2a+UfFr0qfxTWmEKw=; b=qEDVlhdfP5D+8PmPImILA+del3wTY+XKpl1XKwhLzzkr3jR6N0o6x/61UHdPdeuImh PoBQ+ca2wa3J1UN90BEM5q7L/7/w3p2rEXOpnjWIWnRBQcIhGfbXLfI0Qy/3bRLdn3eW /TCCt5878TjbsaG9q1FWz5hMkNGDW60kMt0RT/+2y0dvMnrQq6lYYdKQxCsQaxklSsgK NAZCV5HCO9/VkbhJ/tf2EsljnzMXG/WFXKKp04BZ7KPgSB82oER0qCh0d9PC4xx4kPk8 SoWxiRuxvHY57Fn6pBYvEVkBd1kqL8Gxf5DpVHITLbPn5KadZF1j/miz2npUdqJmc9Ae GkZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723678616; x=1724283416; 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=I0fMYCzEpAflnqdXJ+mHKpT1nx2a+UfFr0qfxTWmEKw=; b=rqxwMG4HKH7z6DTol++Vyxdx0BymIgnZyDOeYiA4Pnz+zJpbTwb8LzkZs5nIuUvC5P DfCTMmgUJ+5TGZNX0zeYmq63xCmKlD2jEvSybza4jrg32wB0P4MD/giGSq4mUBI4Aipk 4G4recDQbWjwNL2kSpRcxNnNeCJ7VJ3bBAYZeuJ8KL0gTZOke+dov7JM5emQHh1lelwK wOccmEm0fosi0aKDDDiP2zqX5SH49UruusK51O/JuYxV5uQJmA5HU5BAMRHg67nALVH9 cBmwBq5Vg6rJC9Dk3EJgkEJLDqvn4ghw5oT5J4E/Krbuh4yrLdReujuaLL2u6AuTFDG0 hn/A== X-Gm-Message-State: AOJu0YxP5XlN2NXrky1Df+fypqXymTWFudg1CKSTmAAUW8UkWTYaAxAw G3OodzTaJ4NyhxMDf2yu/nJHo7dKnn2CzKnZ0vtEygyjD7pgmz/YxUlUMf+Xc/ne6j3ywrsh7kD qcAE= X-Received: by 2002:a05:6871:205:b0:260:e7ed:27f4 with SMTP id 586e51a60fabf-26fe5a97efemr5249384fac.27.1723678615795; Wed, 14 Aug 2024 16:36:55 -0700 (PDT) Received: from linaro.vn.shawcable.net ([2604:3d08:9384:1d00::b861]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7127aef57dfsm112164b3a.115.2024.08.14.16.36.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 16:36:55 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Paolo Bonzini , Mahmoud Mandour , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Alexandre Iooss , Thomas Huth , Pierrick Bouvier , =?utf-8?q?Marc-Andr=C3=A9_L?= =?utf-8?q?ureau?= , =?utf-8?q?Philippe_Mathieu?= =?utf-8?q?-Daud=C3=A9?= Subject: [PATCH 1/6] contrib/plugins/execlog: fix warning Date: Wed, 14 Aug 2024 16:36:40 -0700 Message-Id: <20240814233645.944327-2-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240814233645.944327-1-pierrick.bouvier@linaro.org> References: <20240814233645.944327-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::2c; envelope-from=pierrick.bouvier@linaro.org; helo=mail-oa1-x2c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Found on debian stable. ../contrib/plugins/execlog.c: In function ‘vcpu_tb_trans’: ../contrib/plugins/execlog.c:236:22: error: declaration of ‘n’ shadows a previous local [-Werror=shadow=local] 236 | for (int n = 0; n < all_reg_names->len; n++) { | ^ ../contrib/plugins/execlog.c:184:12: note: shadowed declaration is here 184 | size_t n = qemu_plugin_tb_n_insns(tb); | Signed-off-by: Pierrick Bouvier Reviewed-by: Thomas Huth Reviewed-by: Alexandre Iooss --- contrib/plugins/execlog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/plugins/execlog.c b/contrib/plugins/execlog.c index 1c1601cc0b4..d67d0107613 100644 --- a/contrib/plugins/execlog.c +++ b/contrib/plugins/execlog.c @@ -181,8 +181,8 @@ static void vcpu_tb_trans(qemu_plugin_id_t id, struct qemu_plugin_tb *tb) bool check_regs_this = rmatches; bool check_regs_next = false; - size_t n = qemu_plugin_tb_n_insns(tb); - for (size_t i = 0; i < n; i++) { + size_t n_insns = qemu_plugin_tb_n_insns(tb); + for (size_t i = 0; i < n_insns; i++) { char *insn_disas; uint64_t insn_vaddr; From patchwork Wed Aug 14 23:36:41 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 819157 Delivered-To: patch@linaro.org Received: by 2002:adf:cd01:0:b0:367:895a:4699 with SMTP id w1csp921069wrm; Wed, 14 Aug 2024 16:38:29 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWdk9fLGUK2iwdgHeNm2R+qHxH9zMr97DHQyQamS29Y+SvU04MQ8FdON+51mJCaFDP3RWIY0NtlTPJFGrCp0dcz X-Google-Smtp-Source: AGHT+IHPOE3RP8Ca+1rIzgHlyWzrzDk0dOZWqakKIS0RKe10zyuxC+e5QlRn2+6o+Ao2iRgzBDcS X-Received: by 2002:a05:622a:1b0a:b0:451:d55e:4f55 with SMTP id d75a77b69052e-453678456e0mr25086191cf.4.1723678709699; Wed, 14 Aug 2024 16:38:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1723678709; cv=none; d=google.com; s=arc-20160816; b=RO4E2NtQr7lllJbL9om+2PKK35zs0ZlBU4v5wVmVzwZYrwxUv7CjVrbW+CbFn4EHFH wcM4h5QHq0X4e6C6isf0rd0w1YvtKEuNhdUadnfXRf8NocJfH7gebwOWPYki1L3h8Wlq eMZgc81hyHX4J0jx7ciOU5iVzReNZCqUqSHiTyQNv2UgEk4MpmEIpVKM11FwYW5HIlNI UbCk/36HUcWPt1FAD70nWXabpWbsjEFRDsI+0eH2m3vz1OZdCWBSTSvOKs4wehwSzJGV I/UrCP5L3FtRmY55OBCSy7BGhh6sNYaaKvp0EStkOMHlRejHMTALwzIZ6YwmoR7xM2J2 Qu5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=tYFEGUaBbs4kAr/qhpAyjUWtir2g5OojC1AciDAIaeA=; fh=oXkr8tRtU3V0Y/ys4wmfLP1vjmnh5XTVxxercrnp+aA=; b=Daf376lEvN/jYmki2caNfHtMwe3K5yJePCDF6vExm3YTC2DILK3xmAODdG5tiuWscQ 37ZkZBvItopi7jgBggE/O0zff0TQHXe3esvWsboT4mwGJXl4Wx0g0iDRm50S16okISmr lg65hIOrbVlCI6ByRFP4z155ePpXLJuba7u0uNnc2vZrfzHa5iM+jF6ePJqGh9VDqrh3 0PJlpTHBo9vd79+Mb9Zy4tr5HZJZAiYeFoMwmp9FUPewvyS9cIp0MXhckLV+amfNTPo7 9lycv7kXqsQSodgte4XqDsGKRRICwrP/1Ual3UsZl/XTCMiocN/gNHcVAqUj+uQS/unj 5/Ow==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="a/wh6CFn"; 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-4536a005da9si3883421cf.215.2024.08.14.16.38.29 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 14 Aug 2024 16:38:29 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="a/wh6CFn"; 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 1seNY8-0001rh-1J; Wed, 14 Aug 2024 19:37:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1seNY5-0001fz-2v for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:01 -0400 Received: from mail-pf1-x42a.google.com ([2607:f8b0:4864:20::42a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1seNY2-0006Vx-L1 for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:00 -0400 Received: by mail-pf1-x42a.google.com with SMTP id d2e1a72fcca58-70d316f0060so1060332b3a.1 for ; Wed, 14 Aug 2024 16:36:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723678617; x=1724283417; 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=tYFEGUaBbs4kAr/qhpAyjUWtir2g5OojC1AciDAIaeA=; b=a/wh6CFnrZF+SvqoJIGBE0rNFFquOHRbtwPbnEWcv8oMl8VhVYfthVt9q1NUnieat3 +7rbaWV8I8wR+9dL5Hmj3nsTmr/SAhOZgr6bZT3O+laOETH0ck9mL2Si3+SdbD1qt1DO 4ouyKh8wgsQuTzg2cBwSE+panYpQwHeWJSrGSA8HreEH3ChfFMKAXC9HcQOqZN/xIhgL vzZjIdWtIM2uzfJQh8A/rGuvU83DFZv+pDfz+KGgjugTlbAPZLwzrn4NRxVT5VqcstO0 ZyH2zr75LCc6Zg+y4+DX9iZUaI/mP/bc8JdrHvTpbrj1fGkzIVFCecw52Xx7vESl0cAS zMbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723678617; x=1724283417; 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=tYFEGUaBbs4kAr/qhpAyjUWtir2g5OojC1AciDAIaeA=; b=kcg/dFiHURQKvb9T3glR38e6Y4OH2Te7S4/heaUex1/jhcvfj+CJYayp/pIAD/hK0s nBHNr12gPno4Jn+hUH/Kowtupff1XQKDLBAnAHiH8soezGwT8EFq84NXwstzqb2Gxqbv l3rW20gigE2Jy658cuuI/sjqTeQMbtgw7Q5Rr5pzXDl8ar/0hAuKwMONDG0821PsELx9 kGxJ6a+lw7Yq4GMgyEmBWDCrh0/OwU91XB3vrrUmycJj0MPbbptTsh3xhEVnFbEqHe4K lw6V6Jm+d2T9ARvxKE08mRTvMiSghXFZysCMobl/T65iSZXiTA2bo6TSmosZbQR2BHWT HCHg== X-Gm-Message-State: AOJu0Yxpxrb99TdXswdYzHu7LrAa4LmUozzgMhotK5EKKz9bLCLQr0Sm ozaN1C5tsh0c76Yn59NhUGbJGjyon6oY1tcsBdg2uN2wwZWVU3RPhcSLFwF02NcnNzmDspJZLrJ 0hUg= X-Received: by 2002:a05:6a20:c508:b0:1c0:f630:97a5 with SMTP id adf61e73a8af0-1c8f859e750mr1567761637.10.1723678617181; Wed, 14 Aug 2024 16:36:57 -0700 (PDT) Received: from linaro.vn.shawcable.net ([2604:3d08:9384:1d00::b861]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7127aef57dfsm112164b3a.115.2024.08.14.16.36.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 16:36:56 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Paolo Bonzini , Mahmoud Mandour , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Alexandre Iooss , Thomas Huth , Pierrick Bouvier , =?utf-8?q?Marc-Andr=C3=A9_L?= =?utf-8?q?ureau?= , =?utf-8?q?Philippe_Mathieu?= =?utf-8?q?-Daud=C3=A9?= Subject: [PATCH 2/6] contrib/plugins/cache: fix warning when compiling on 32bits host Date: Wed, 14 Aug 2024 16:36:41 -0700 Message-Id: <20240814233645.944327-3-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240814233645.944327-1-pierrick.bouvier@linaro.org> References: <20240814233645.944327-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42a; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pf1-x42a.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Found on debian stable (i386). ../contrib/plugins/cache.c: In function 'vcpu_tb_trans': ../contrib/plugins/cache.c:477:30: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast] 477 | effective_addr = (uint64_t) qemu_plugin_insn_haddr(insn); | Signed-off-by: Pierrick Bouvier --- contrib/plugins/cache.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/contrib/plugins/cache.c b/contrib/plugins/cache.c index 512ef6776b7..82ed734d6d4 100644 --- a/contrib/plugins/cache.c +++ b/contrib/plugins/cache.c @@ -471,12 +471,12 @@ 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; + uintptr_t effective_addr; if (sys) { - effective_addr = (uint64_t) qemu_plugin_insn_haddr(insn); + effective_addr = (uintptr_t) qemu_plugin_insn_haddr(insn); } else { - effective_addr = (uint64_t) qemu_plugin_insn_vaddr(insn); + effective_addr = (uintptr_t) qemu_plugin_insn_vaddr(insn); } /* From patchwork Wed Aug 14 23:36:42 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 819152 Delivered-To: patch@linaro.org Received: by 2002:adf:cd01:0:b0:367:895a:4699 with SMTP id w1csp920983wrm; Wed, 14 Aug 2024 16:38:03 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWR59n4TzG2s/wtoIfN/aXmXAhJQFSlE8lW2TvRXOMLgOybr3qYdigTVuM4ZcFTKnS2kLJQohpNRwwpv1KU8r7V X-Google-Smtp-Source: AGHT+IFCKEAOX8N2Ko9kag10y4YH0UPaeRx7RkVXWh25gzadMrCSr9ii0lDN0bZnd+N2rR3p5WwQ X-Received: by 2002:a05:620a:24d4:b0:79e:fbef:d23e with SMTP id af79cd13be357-7a4ee335132mr503684485a.17.1723678682876; Wed, 14 Aug 2024 16:38:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1723678682; cv=none; d=google.com; s=arc-20160816; b=Vset/MOYosVfwQhPLHDT3ii9quvY1SJIFZtMtp5cOIfSq8bGIcd8wbJfj5OgpFouNP 91yZmHazIiLXCsbUSx4KmAwXYIigWGBY57FORYVmN/8Aw3lF2nfb1FEuRmA95MCTjaHe Nv8/pxvO18V+ApI6zoZifiAdzk8795egacAhTL2IaDSG6UUo6xNaXMGPwHVizKxy4nha GUq3sVLOA5jGmCTUW9FPXMptG5Z+LhFv7Cm245aA7q55OVZYLD2WvhgYNZM6zZkQh0mY qIeOamV8N9/bw/bHsE/V/6yVe+3CZ0QqFxK+tpOKcYilyRy7/Jj9kO+XAPyk9Wewyjo3 sPQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=OHisr3UikbRag7D0QJ33pcI9STMq6DpazTYXpbTOwMY=; fh=oXkr8tRtU3V0Y/ys4wmfLP1vjmnh5XTVxxercrnp+aA=; b=wBkYSdyhMpKsYcvsM0SUgYT99MNdew3YhrzSa2bzFAuG87+0MIvyL1UQc15MjVuxFL 6TWvOas2f6SXbjbPU7cqTAzfhDNyVt4gUU9ZyKRldUsXYA/yL8duOlilJmwjrvdj5LB7 ySWXWftF8+Nrtb6qmbf2GS/XePqrX/SR36CWZl1KcB1JFjD1sVvqct4WfKaYzUHM39Ac qP/cGBli8oMY/dnlvw8la3IOHhPjwVVqx8d9m5S0C6fxOGenzy3RuT5jlH/GF87orA2h HGc9I4dh60eBwVqvPPev4eQ37SYWp87ckVQVxVce8bqbKmIjLuDTr/7RoLO7zoEECjq4 6vQQ==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HBLcCOEg; 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-7a4ff0e5979si45358185a.450.2024.08.14.16.38.02 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 14 Aug 2024 16:38:02 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HBLcCOEg; 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 1seNY6-0001kV-8U; Wed, 14 Aug 2024 19:37:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1seNY5-0001hB-B2 for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:01 -0400 Received: from mail-pf1-x42c.google.com ([2607:f8b0:4864:20::42c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1seNY3-0006W9-Oc for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:01 -0400 Received: by mail-pf1-x42c.google.com with SMTP id d2e1a72fcca58-70d18d4b94cso276342b3a.2 for ; Wed, 14 Aug 2024 16:36:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723678618; x=1724283418; 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=OHisr3UikbRag7D0QJ33pcI9STMq6DpazTYXpbTOwMY=; b=HBLcCOEgy0DeFQZLiiV76slyZ9lgCegKElLLLIVNeseNl0Q+gYs9oauvw2tGIJjxmh od5kaI5mcalpQWoz6Z9OZIAhXNN3vQvjxbywkZoOOOPQ7xe9Swhb6bbTfO5aSELPbDpd DnyJG7v9GHwqoyF3mAeTRMaC8QFGnI47HGIeB8lpfj3auROc9yI8BH6TpmhDlvPsupJy 7z/Uy9Ny62CbxAVPDuaw33mdE6gNjXH4oVxyzy2GoV3aFZQ6sP/7vTOBwGuhqlNPUgn8 HvZvRwtJaaWVEXpxOwESdNf98Un24oJf6HI4X+I56baF3Gaa1+n07niWKN0fPykh0vec 37Yg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723678618; x=1724283418; 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=OHisr3UikbRag7D0QJ33pcI9STMq6DpazTYXpbTOwMY=; b=vvRPne89dE5AQbmPH+bRZRXyKR0lT6IsEb4u0coXNVWO0nxHljWgsit92KhZN0wFvw FNt0PVC6drFhNBRK2f32V8/1a9Xxv+9w93PxYRfC8QGK43feX88KbWY7VCaxVzLu6m4W nErOEL3N1WCbz6qZg8jLBUrSSVoWQLu/kTUw0FzU5MKQVFRKnVxqW56tZARORr5f2ru1 YJ8doIN4v8f4wsXBQ3iMIvdiAiGPUIH2EEyvn7WtCfZbtLaz0m8DNy9XTeCxScPOBKW+ ZHhmucZP/FwxWdrlUGuzwO5FCHDRHpinBcrT/JYMPS94TaD7dpq9l+VUn6FxxdrRkNve yA4A== X-Gm-Message-State: AOJu0Yyg0vmenKneoAU5Axr7VP/ttzve3fi05hfK18qYpqFQVPo8OEWc oQ7SBPwvtxJtU+PCGL/oPy0AXLpiboSMdScKenLercIjiCHaNG7zpHSvHI7tQinKbT6Tku1qbLz aMk0= X-Received: by 2002:a05:6a20:6f0e:b0:1c8:92ed:7c5e with SMTP id adf61e73a8af0-1c8eaeb3b5emr5140262637.23.1723678618196; Wed, 14 Aug 2024 16:36:58 -0700 (PDT) Received: from linaro.vn.shawcable.net ([2604:3d08:9384:1d00::b861]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7127aef57dfsm112164b3a.115.2024.08.14.16.36.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 16:36:57 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Paolo Bonzini , Mahmoud Mandour , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Alexandre Iooss , Thomas Huth , Pierrick Bouvier , =?utf-8?q?Marc-Andr=C3=A9_L?= =?utf-8?q?ureau?= , =?utf-8?q?Philippe_Mathieu?= =?utf-8?q?-Daud=C3=A9?= Subject: [PATCH 3/6] contrib/plugins/hwprofile: fix warning when compiling on 32bits host Date: Wed, 14 Aug 2024 16:36:42 -0700 Message-Id: <20240814233645.944327-4-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240814233645.944327-1-pierrick.bouvier@linaro.org> References: <20240814233645.944327-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42c; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pf1-x42c.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Found on debian stable (i386). ../contrib/plugins/hwprofile.c: In function 'new_location': ../contrib/plugins/hwprofile.c:172:32: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] 172 | g_hash_table_insert(table, (gpointer) off_or_pc, loc); | ^ ../contrib/plugins/hwprofile.c: In function 'vcpu_haddr': ../contrib/plugins/hwprofile.c:227:19: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast] 227 | off = (uint64_t) udata; | ^ ../contrib/plugins/hwprofile.c:232:62: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] 232 | (gpointer) off); | ^ ../contrib/plugins/hwprofile.c: In function 'vcpu_tb_trans': ../contrib/plugins/hwprofile.c:250:26: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] 250 | gpointer udata = (gpointer) (source ? qemu_plugin_insn_vaddr(insn) : 0); | Signed-off-by: Pierrick Bouvier --- contrib/plugins/hwprofile.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/contrib/plugins/hwprofile.c b/contrib/plugins/hwprofile.c index 739ac0c66b5..ee94a74ad94 100644 --- a/contrib/plugins/hwprofile.c +++ b/contrib/plugins/hwprofile.c @@ -165,7 +165,7 @@ static DeviceCounts *new_count(const char *name, uint64_t base) return count; } -static IOLocationCounts *new_location(GHashTable *table, uint64_t off_or_pc) +static IOLocationCounts *new_location(GHashTable *table, uintptr_t off_or_pc) { IOLocationCounts *loc = g_new0(IOLocationCounts, 1); loc->off_or_pc = off_or_pc; @@ -201,7 +201,7 @@ static void vcpu_haddr(unsigned int cpu_index, qemu_plugin_meminfo_t meminfo, return; } else { const char *name = qemu_plugin_hwaddr_device_name(hwaddr); - uint64_t off = qemu_plugin_hwaddr_phys_addr(hwaddr); + uintptr_t off = qemu_plugin_hwaddr_phys_addr(hwaddr); bool is_write = qemu_plugin_mem_is_store(meminfo); DeviceCounts *counts; @@ -224,7 +224,7 @@ 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 = (uintptr_t) udata; } if (pattern || source) { @@ -247,7 +247,8 @@ 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); + gpointer udata = (gpointer) ( + source ? (uintptr_t) qemu_plugin_insn_vaddr(insn) : 0); qemu_plugin_register_vcpu_mem_cb(insn, vcpu_haddr, QEMU_PLUGIN_CB_NO_REGS, rw, udata); From patchwork Wed Aug 14 23:36:43 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 819158 Delivered-To: patch@linaro.org Received: by 2002:adf:cd01:0:b0:367:895a:4699 with SMTP id w1csp921071wrm; Wed, 14 Aug 2024 16:38:30 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCU8Abirp1G1hksCEX4Q18CyCFv1YfM5IPWgYFWh4mdQlW1AqWJTPtUQXNonnBHn0ztGO44UD90TKC10oJzfI+zs X-Google-Smtp-Source: AGHT+IFAlDJb0mGGJc+7cg6vUD6mpEmlig2FhbW1ENSEQ5c/VgQ9HNTuV+G/F3AX+PP/KF8xECPF X-Received: by 2002:a05:620a:d8b:b0:79f:750:e5df with SMTP id af79cd13be357-7a4ee3e82e7mr491099885a.66.1723678709914; Wed, 14 Aug 2024 16:38:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1723678709; cv=none; d=google.com; s=arc-20160816; b=FDAX+H9fOMM00K/UhTxh5JQRaPtJjCUVYy8VyIyywrEyui2UyUByL5nkCWo+7hAW5B Zqm779THVF3gMihYVi4GjUu356m8dcF2IKdhdkEbKi4W7NtqQLtSetSAjrhVJMm1H/4O AVxRG1s12naFUnl4EDXQzb0ukTD7e99vdtMx/8rF1RLPb64JzafwUpTG6MUHFvY3J05/ 9yx6vFTd+zPIj/5fmVP9fZ8VQPlauL6WTmq9DnlSPoXvmvvtVT/50fQWqnH2+jmCaPWE ssZpJRdE7O5OcqdmlUgI5yt8x6YkxGq9ALEQTYILFjKAHDPmnSg60wXtg+qJ+hlIVMw/ IrwQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=bzoJvs+/ktmRvV/uludFrSeMjpPKw38xy+lGwp2LWAA=; fh=oXkr8tRtU3V0Y/ys4wmfLP1vjmnh5XTVxxercrnp+aA=; b=sVG3jE8G3F+QYDMzLzdszrfoPliv9xONArBbw7N9y3/lZgSVyfDMWgafEF6vPOA0m8 z7QIY/eKPTFfuUTkruFAXvb7VE49CP+vfuLC+YWyUzF+3p+3pXlyzbGUo2QAoJuBrdcX iwqediP+lj0CV3ffpaVMsmHIjuv/HumG+Pvqn7tSxXRTeJml/E+uyuUbkpsoUFYb6qS6 Dx3JqHaVy580GhkpOIjy5T6DH2ljjSIGPlLKX6ybqy0tBryhokgw0LoAbR2bvMXLBVji ED8NcIAIqqvBhbTs0sSltuWNRQc3N1/s+cBfCKhdZM1NcUS/ZHz4yvgDYZ12eLj0my6B PYHg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=CqIMZho1; 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-7a4ff114a68si42932885a.660.2024.08.14.16.38.29 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 14 Aug 2024 16:38:29 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=CqIMZho1; 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 1seNYA-00023A-ST; Wed, 14 Aug 2024 19:37:06 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1seNY6-0001ki-8h for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:02 -0400 Received: from mail-pf1-x42b.google.com ([2607:f8b0:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1seNY4-0006WR-Lt for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:02 -0400 Received: by mail-pf1-x42b.google.com with SMTP id d2e1a72fcca58-70f5ef740b7so319819b3a.2 for ; Wed, 14 Aug 2024 16:37:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723678619; x=1724283419; 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=bzoJvs+/ktmRvV/uludFrSeMjpPKw38xy+lGwp2LWAA=; b=CqIMZho1iQIzGr/SHFL9AtS4K0w0BAfgozvIyT26wP3J+eJxtF5m/jjt/1CPhiSrRm 35XlCvnFZbumzBuKYuGA3yhf12ZpuC5lvrxdYI++XzXmPqytzGrt0jJDzRmg5eu+jy6c 0TLXGD5YnTp4JI3qwobtYD4LQ/k13bQ5WU6UOqpC3d3tTSiSGoS0+QzKZEnsp41aei2v HlgHHW/A6cvcJ+59fOrdQLsu2KvXlHXiNjQQnn8McqPKGN2UkjHz8bXWVpWPuk1LwEV8 okfrsylTxNa7u9CoH4I3fE0rVK9pNvAnEk79xpO0FXpFG/Cn+shmisCAxzedYBzuv23o d6IQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723678619; x=1724283419; 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=bzoJvs+/ktmRvV/uludFrSeMjpPKw38xy+lGwp2LWAA=; b=L8H/DJ00/ipzbaUmNqyiaytLkFhm6zZcOTthgQhb9kHjKc42+EFZiWHzwBP31GLgZj MBqWNTC5D5eoS/RMFXW49g485VtzPXdV3gFT8eL5CtcSxfLGi2CmJCOzt0fh4CI8EmcK iUyhXjyF69+mKAB5wY3n2dxxEg4TxP8qDb9vRpv4JqJcqAaFlYxazhkUXmsnQNgN2kAI VIEc0NQ9btHFGWXt/JpN0efsaWsVGa0M3Z6SETZQVnyJJth8PFPV1OgrW/nJgLxC71k9 m39Xb2UGHy+krRXKbj+ujlZMoNfVHG9T6Uz1GRXTedC9vFwUEo1WduoSxpfwcJxBil5A fZag== X-Gm-Message-State: AOJu0Ywo4uJcrpnd44ZeNueVgJKMzRNevs3X+q3IpSa3yR9MoNZxBJwC 8o2yLWe07xBGgMGuNxkapvBeBGXoX/+xiN/yY/OeKcyCTbXWNGg5R1EtV8IQ4DUMdtqZqwELE3K h1gs= X-Received: by 2002:a05:6a00:1ad1:b0:706:29e6:2ed2 with SMTP id d2e1a72fcca58-712670fa392mr6336540b3a.5.1723678619237; Wed, 14 Aug 2024 16:36:59 -0700 (PDT) Received: from linaro.vn.shawcable.net ([2604:3d08:9384:1d00::b861]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7127aef57dfsm112164b3a.115.2024.08.14.16.36.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 16:36:58 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Paolo Bonzini , Mahmoud Mandour , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Alexandre Iooss , Thomas Huth , Pierrick Bouvier , =?utf-8?q?Marc-Andr=C3=A9_L?= =?utf-8?q?ureau?= , =?utf-8?q?Philippe_Mathieu?= =?utf-8?q?-Daud=C3=A9?= Subject: [PATCH 4/6] contrib/plugins/hotblocks: fix warning when compiling on 32bits host Date: Wed, 14 Aug 2024 16:36:43 -0700 Message-Id: <20240814233645.944327-5-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240814233645.944327-1-pierrick.bouvier@linaro.org> References: <20240814233645.944327-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42b; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pf1-x42b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Found on debian stable (i386). ../contrib/plugins/hotblocks.c: In function 'vcpu_tb_trans': ../contrib/plugins/hotblocks.c:117:56: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] 117 | cnt = (ExecCount *) g_hash_table_lookup(hotblocks, (gconstpointer) hash); | ^ ../contrib/plugins/hotblocks.c:126:40: error: cast to pointer from integer of different size [-Werror=int-to-pointer-cast] 126 | g_hash_table_insert(hotblocks, (gpointer) hash, (gpointer) cnt); | Signed-off-by: Pierrick Bouvier --- contrib/plugins/hotblocks.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/plugins/hotblocks.c b/contrib/plugins/hotblocks.c index 02bc5078bdd..d540f1b7f0b 100644 --- a/contrib/plugins/hotblocks.c +++ b/contrib/plugins/hotblocks.c @@ -109,9 +109,9 @@ static void vcpu_tb_exec(unsigned int cpu_index, void *udata) 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); + uintptr_t pc = qemu_plugin_tb_vaddr(tb); size_t insns = qemu_plugin_tb_n_insns(tb); - uint64_t hash = pc ^ insns; + uintptr_t hash = pc ^ insns; g_mutex_lock(&lock); cnt = (ExecCount *) g_hash_table_lookup(hotblocks, (gconstpointer) hash); From patchwork Wed Aug 14 23:36:44 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 819154 Delivered-To: patch@linaro.org Received: by 2002:adf:cd01:0:b0:367:895a:4699 with SMTP id w1csp921057wrm; Wed, 14 Aug 2024 16:38:25 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXIfbatNj0Ju9ZvJLlPuCoUFN4XdrGy7DU5p5qOdrpRcGKDjBYcoA11wu2cO3PhSVoLXXtQbIOX0B+fvLPREksF X-Google-Smtp-Source: AGHT+IH2Mvvq08KXfNcfeN6WmBlvHGuon3uW36ScrYcT2xITFREWTAnBItEFBGByZys/7njKlIAB X-Received: by 2002:a05:622a:4cce:b0:447:eaf9:5a08 with SMTP id d75a77b69052e-4535ba9ee8amr61184341cf.17.1723678705023; Wed, 14 Aug 2024 16:38:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1723678705; cv=none; d=google.com; s=arc-20160816; b=ywof1QBcqjB7TWcUsAeQqdBqCnHKqQ71QXi+iGSt9d90TgN1IM1mSwOebHE0lcmQ5W BYsU+OsBFUSJcOF2dmBZrPxCvKEnG5bP9Fw/nFFOJJnPf8cDBD8WcHlPIdHCN/PuepFq nz5keGO+Ur+j4G+J4oc0m6gZcKutXpI0Td+sVE1HxWKAgUJVNJM0qRiqpLBtq9ysoR4W Ur6Uz36t7T3StH2qs8NKvy86dm0ql7mYkFsAW4KCtXTFCSQaAblsv4PtRfXZPg9ejflh d3xL74tLou9NL0C+gVe0jizsya0KHSlPiYfpeSrhPww/SfVP26CVeRPG2uWjn8qyDr+s pf5g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=6xxCvfMwAVvNf1Qjn5/JJVvbogoK1VhpQom3xuwjm28=; fh=oXkr8tRtU3V0Y/ys4wmfLP1vjmnh5XTVxxercrnp+aA=; b=veE2bAZ3jCbqyZfd7SNn/0DdT538f5OQ3dgPlHc5nnM5+ZDWYXJhQO2m0AuiT7Nyga gpfxVmNYAwz4MFCMFGF1PDyCBTnIOZgx8GidXBKDqgQBAR6leyRWw4JqnNL6gl01TKHn SNnjnZT3s5VawSoTftPjHcZhsdmstwm8L9wzRimQRx5d+V6yegeg56UHLlaspPoVSKUg rZaJj5OKQl0tM13S5LPQZUlh3qvANshfCTTGoqjAB0bGUAzI9KomuktSyieMcngcE0VV H8UURSWkhvLSh4Xt06cVxjRAqD1pN1BrJJN8E9s04UfIGnZSNIrXeAQQYpaxyBHhmy8X Nm6A==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aiQWDBY6; 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-45369fe62d1si4117321cf.4.2024.08.14.16.38.24 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 14 Aug 2024 16:38:25 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aiQWDBY6; 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 1seNY8-0001to-Jm; Wed, 14 Aug 2024 19:37:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1seNY7-0001p8-D1 for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:03 -0400 Received: from mail-pf1-x42b.google.com ([2607:f8b0:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1seNY5-0006Wa-PL for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:03 -0400 Received: by mail-pf1-x42b.google.com with SMTP id d2e1a72fcca58-710bdddb95cso243734b3a.3 for ; Wed, 14 Aug 2024 16:37:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723678620; x=1724283420; 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=6xxCvfMwAVvNf1Qjn5/JJVvbogoK1VhpQom3xuwjm28=; b=aiQWDBY6zf8f1lj7oc9D7HtAADOZBVFGBccCyPqKtc+1BOlfwk++OO4SoDNC8NJr4B qwNAoT/qeqWHHrOysJwV+A40oMgbQ0EHTKGmHy0sIDOynHUws1e7+MQeq901lfUy1Mzs oiURi0WKVHYkErEenCH/8bRx8DQb5YRsU3wBBlY+LAnAgXIjQB8crsedJJ8AqtmXnhf1 HxJnnq6Ei6V8wIq29qZaeosok+ZWmBiPTih1VosHFfjWsAIoodST/5moYFAc5bj10A1l v/KRiUBBsQX6i5aUoyiI66/ZWQ04IlYYwA80Qz0lIandR5YhTClnyGEkdzr7PHu6ijVe y4CQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723678620; x=1724283420; 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=6xxCvfMwAVvNf1Qjn5/JJVvbogoK1VhpQom3xuwjm28=; b=aVQ9ld/3zI15o0MbWpr991vQP/+OMe+PbQPRABH6qokz8p6cPZjg/beDavBHrASUoB Hx76TrrDIMPDxwGuQftnr+86QBA07a8qEnGd8lPoKLij6di3i+hM9YNsNiOP5LK9yu5O tlLpwwL/wSswGWOdwmx/gcW0tOLbzKIfR5v2IwmbQK1ZwV+Al0FpUsT5naOEhAuYYpVu EQSkqPr4ZMigwBqScfnKiWnz4hFm9YEV57Y5xR9xPiBSUv7/SYR4R6Ngzc6nERfOyg+F 8eM/+/W5p/FV42w8MnWCFRGCzBHGEzSjC5ToUicqNhKsnKLafvDGrF8oOIaNwDGiGlcn HeyA== X-Gm-Message-State: AOJu0YxLUHk4vqBwMCSUc0O5xsp1MF/9LnQxkyH3TsjEUSLqKc7M0/VP 6M1+RLKWcimvvDQvE0Sg0BfmNw4cuQ/mc6JUMMiVBvJsHc4yhHFMF5NgqaqA4InuKnlUTYe45Ad UFBw= X-Received: by 2002:a05:6a20:d49b:b0:1c6:b364:dbd1 with SMTP id adf61e73a8af0-1c8eae6f450mr6196973637.19.1723678620260; Wed, 14 Aug 2024 16:37:00 -0700 (PDT) Received: from linaro.vn.shawcable.net ([2604:3d08:9384:1d00::b861]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7127aef57dfsm112164b3a.115.2024.08.14.16.36.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 16:36:59 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Paolo Bonzini , Mahmoud Mandour , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Alexandre Iooss , Thomas Huth , Pierrick Bouvier , =?utf-8?q?Marc-Andr=C3=A9_L?= =?utf-8?q?ureau?= , =?utf-8?q?Philippe_Mathieu?= =?utf-8?q?-Daud=C3=A9?= Subject: [PATCH 5/6] meson: build contrib/plugins with meson Date: Wed, 14 Aug 2024 16:36:44 -0700 Message-Id: <20240814233645.944327-6-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240814233645.944327-1-pierrick.bouvier@linaro.org> References: <20240814233645.944327-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42b; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pf1-x42b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tried to unify this meson.build with tests/tcg/plugins/meson.build but the resulting modules are not output in the right directory. Originally proposed by Anton Kochkov, thank you! Solves: https://gitlab.com/qemu-project/qemu/-/issues/1710 Signed-off-by: Pierrick Bouvier --- meson.build | 4 ++++ contrib/plugins/meson.build | 23 +++++++++++++++++++++++ 2 files changed, 27 insertions(+) create mode 100644 contrib/plugins/meson.build diff --git a/meson.build b/meson.build index 52e5aa95cc0..4efe1e782ba 100644 --- a/meson.build +++ b/meson.build @@ -3627,6 +3627,10 @@ subdir('accel') subdir('plugins') subdir('ebpf') +if 'CONFIG_TCG' in config_all_accel + subdir('contrib/plugins') +endif + common_user_inc = [] subdir('common-user') diff --git a/contrib/plugins/meson.build b/contrib/plugins/meson.build new file mode 100644 index 00000000000..a0e026d25e2 --- /dev/null +++ b/contrib/plugins/meson.build @@ -0,0 +1,23 @@ +t = [] +if get_option('plugins') + foreach i : ['cache', 'drcov', 'execlog', 'hotblocks', 'hotpages', 'howvec', + 'hwprofile', 'ips', 'lockstep', 'stoptrigger'] + if host_os == 'windows' + t += shared_module(i, files(i + '.c') + 'win32_linker.c', + include_directories: '../../include/qemu', + link_depends: [win32_qemu_plugin_api_lib], + link_args: ['-Lplugins', '-lqemu_plugin_api'], + dependencies: glib) + + else + t += shared_module(i, files(i + '.c'), + include_directories: '../../include/qemu', + dependencies: glib) + endif + endforeach +endif +if t.length() > 0 + alias_target('contrib-plugins', t) +else + run_target('contrib-plugins', command: find_program('true')) +endif From patchwork Wed Aug 14 23:36:45 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 819153 Delivered-To: patch@linaro.org Received: by 2002:adf:cd01:0:b0:367:895a:4699 with SMTP id w1csp921029wrm; Wed, 14 Aug 2024 16:38:12 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCWek+hzTyVJTjXsWYrpYWu1fC9lE9e079rwME3tpuJFjuDwOMPjplhhwClpcv5j/MucSALfyg==@linaro.org X-Google-Smtp-Source: AGHT+IE9kZS6XsV0OdoHsNz//WTUQlAyzsqHIMEVUbPlcnsPRNqM76llzJc54V/KUhWqZKVPm90h X-Received: by 2002:a05:622a:4c8e:b0:453:57b0:8814 with SMTP id d75a77b69052e-453678456ebmr25107871cf.6.1723678692475; Wed, 14 Aug 2024 16:38:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1723678692; cv=none; d=google.com; s=arc-20160816; b=g1p8122lXT+b9NCefRKp9W+i3obJHS1WGmT2CQ+64xSfPGbeVf+JOjOubNJNG9uPfd uaW5f+PyLURAyBVie/SUr3ldFtOx8F6Hs3RsvcXE7MZpoUKfT+uiCbuU0eogKbhyUfsW 3jp+bahwmL7m1V1a08HuMfUJ977xBYiFliAhu6M9tUBMBT0p502ymPuzg4qnefJ1/oY/ WLxfr5p+R85IEY9Or7X0pEh2OlFHQ1FqOnj1+bmuwOhkO2rBGFprZc1B5biqr9jltTfO GRUoKAw4N+lKyEbXHZKGkJCvXotf0OtuYtiTx3es95J3/IqgLehnPa9LuBooJZLwrhCP zb/g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=88ldzGJFn7KJzwoVt5WZkhf1Vk0R2+WAedFjkHAyIrQ=; fh=oXkr8tRtU3V0Y/ys4wmfLP1vjmnh5XTVxxercrnp+aA=; b=J5xlo6Urn/iloYtelfPH3Os0HAIN025HKj2ApNsgJ0iehEa/hpS7unLI/CYtiNhxDV eblQKt4af8VKw8LQT2iT7MGSVJr7rdExlhXoTFEf3LYP17NP82psx5QIBPDwlGDKHp2t 2wiRlUE6jy8gsnEJuy/2P5AGy9maDawbCtdHaMIEEUjFOZpdlIzzAUfFrzfVs0kvFgHK Rz7vu9vj1m/HiJa2m7CDgZNZRwLA+4lQqP5tF209xFCc7Xh+wYLrGZ1nwuF/PS3VHJFE qw+WZkUP0Ek8W2E5N5pg+xmgPSUD+5VJcUME0k1urqmv2+qTycNP3vfa/JD4IhbBHq2h wFiw==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=K48EKCOZ; 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-4536a0073b8si3959691cf.227.2024.08.14.16.38.12 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 14 Aug 2024 16:38:12 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=K48EKCOZ; 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 1seNYB-00024M-56; Wed, 14 Aug 2024 19:37:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1seNY8-0001uI-Ly for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:04 -0400 Received: from mail-pf1-x436.google.com ([2607:f8b0:4864:20::436]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1seNY6-0006Ws-Rt for qemu-devel@nongnu.org; Wed, 14 Aug 2024 19:37:04 -0400 Received: by mail-pf1-x436.google.com with SMTP id d2e1a72fcca58-710dc3015bfso273299b3a.0 for ; Wed, 14 Aug 2024 16:37:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1723678621; x=1724283421; 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=88ldzGJFn7KJzwoVt5WZkhf1Vk0R2+WAedFjkHAyIrQ=; b=K48EKCOZiqaOEnnrsAxehpKQQee4Xd53aDD8XexaqAVE4E3n2RN9B102AMf/wv+zrL eHpSpbNr2T9heS/H8YQc0JXGsXc3bqF7mxXfn5jYyPSuqwQBjWiKPuz64nHRWALfyCa+ coFvQ5bYcCCdyO8+mMdI83stQTrPvOV5Ll4Hwt5gzOTUpqKHh1yvBnLHs6wk+0pIfH8O pVVArkbkMJVwicQDt7kro+6RQit464eUnn5NMTilI4SAN1TyRAqv2lIhiqRtoPThQY13 wX21eA9IYjVPiv3VSH/PbV0JyIsZ2kP6NUxBF4GaSKD6B2eLoEepKrGoYwiQrVoZp2DM PNMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723678621; x=1724283421; 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=88ldzGJFn7KJzwoVt5WZkhf1Vk0R2+WAedFjkHAyIrQ=; b=hW3JorGDnA5z23NTW9mjjA5dli3kM/XS5G74DX7QQ17jmhCl5eokPfaJ9E9vAdW9vS zd4JuGYkBqGuhz5/M9N0IzhgbEB29T5ybN7BZugbzOFWdmFCNso4NQScky0fisGsoeuM VWCedHwPi9zVu0/zX0i1x2HQAix601xHyCwCQNX2BO8V1A5gIo82EqW5ex0daupgTsZN b6fstnDx8uI+ONpbPTT2y1owYbNQR9xC0e0q9h2M+Qsm85zr7nB/0mu6eMjWm0pEFbIT aVhIgmh0C7jMPIMImh4kz3sKUgbHqSPQjNq2F29dLSFAk5FsBZe5oVL7SsTwmhA5Asnv FZXQ== X-Gm-Message-State: AOJu0YzRAxqNbO+EoVCGt7lYX9JXfOiaA/h1eTmFQp75BbI/3Urbi1MY oN3BexRu4UuOXpWBfzI2i7NmTYztIvIBBfLNB2ddKnoYMrUsSWJMhKQiqbgmle2C6yQJZXXE127 W/vI= X-Received: by 2002:a05:6a20:85af:b0:1c8:de01:e7e5 with SMTP id adf61e73a8af0-1c8f85c7766mr1325780637.15.1723678621299; Wed, 14 Aug 2024 16:37:01 -0700 (PDT) Received: from linaro.vn.shawcable.net ([2604:3d08:9384:1d00::b861]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-7127aef57dfsm112164b3a.115.2024.08.14.16.37.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 16:37:00 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Paolo Bonzini , Mahmoud Mandour , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Alexandre Iooss , Thomas Huth , Pierrick Bouvier , =?utf-8?q?Marc-Andr=C3=A9_L?= =?utf-8?q?ureau?= , =?utf-8?q?Philippe_Mathieu?= =?utf-8?q?-Daud=C3=A9?= Subject: [PATCH 6/6] contrib/plugins: remove Makefile for contrib/plugins Date: Wed, 14 Aug 2024 16:36:45 -0700 Message-Id: <20240814233645.944327-7-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240814233645.944327-1-pierrick.bouvier@linaro.org> References: <20240814233645.944327-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::436; envelope-from=pierrick.bouvier@linaro.org; helo=mail-pf1-x436.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Now replaced by meson build. Signed-off-by: Pierrick Bouvier --- configure | 18 --------- Makefile | 10 ----- contrib/plugins/Makefile | 85 ---------------------------------------- 3 files changed, 113 deletions(-) delete mode 100644 contrib/plugins/Makefile diff --git a/configure b/configure index 019fcbd0ef7..2c0f708cd0a 100755 --- a/configure +++ b/configure @@ -1030,7 +1030,6 @@ if test "$static" = "yes" ; then fi if test "$plugins" != "no"; then plugins=yes - subdirs="$subdirs contrib/plugins" fi cat > $TMPC << EOF @@ -1531,7 +1530,6 @@ LINKS="$LINKS .gdbinit scripts" # scripts needed by relative path in .gdbinit LINKS="$LINKS tests/avocado tests/data" LINKS="$LINKS tests/qemu-iotests/check tests/qemu-iotests/Makefile" LINKS="$LINKS python" -LINKS="$LINKS contrib/plugins/Makefile " for f in $LINKS ; do if [ -e "$source_path/$f" ]; then symlink "$source_path/$f" "$f" @@ -1614,22 +1612,6 @@ if test "$default_targets" = "yes"; then echo "CONFIG_DEFAULT_TARGETS=y" >> $config_host_mak fi -# contrib/plugins configuration -echo "# Automatically generated by configure - do not modify" > contrib/plugins/$config_host_mak -echo "SRC_PATH=$source_path/contrib/plugins" >> contrib/plugins/$config_host_mak -echo "PKG_CONFIG=${pkg_config}" >> contrib/plugins/$config_host_mak -echo "CC=$cc $CPU_CFLAGS" >> contrib/plugins/$config_host_mak -echo "CFLAGS=${CFLAGS-$default_cflags} $EXTRA_CFLAGS" >> contrib/plugins/$config_host_mak -if test "$host_os" = windows; then - echo "DLLTOOL=$dlltool" >> contrib/plugins/$config_host_mak -fi -if test "$host_os" = darwin; then - echo "CONFIG_DARWIN=y" >> contrib/plugins/$config_host_mak -fi -if test "$host_os" = windows; then - echo "CONFIG_WIN32=y" >> contrib/plugins/$config_host_mak -fi - # tests/tcg configuration mkdir -p tests/tcg echo "# Automatically generated by configure - do not modify" > tests/tcg/$config_host_mak diff --git a/Makefile b/Makefile index 02a257584ba..e474fbe50de 100644 --- a/Makefile +++ b/Makefile @@ -186,11 +186,6 @@ SUBDIR_RULES=$(foreach t, all clean distclean, $(addsuffix /$(t), $(SUBDIRS))) $(SUBDIR_RULES): $(call quiet-command,$(MAKE) $(SUBDIR_MAKEFLAGS) -C $(dir $@) V="$(V)" TARGET_DIR="$(dir $@)" $(notdir $@),) -ifneq ($(filter contrib/plugins, $(SUBDIRS)),) -.PHONY: plugins -plugins: contrib/plugins/all -endif - .PHONY: recurse-all recurse-clean recurse-all: $(addsuffix /all, $(SUBDIRS)) recurse-clean: $(addsuffix /clean, $(SUBDIRS)) @@ -306,11 +301,6 @@ help: $(call print-help,cscope,Generate cscope index) $(call print-help,sparse,Run sparse on the QEMU source) @echo '' -ifneq ($(filter contrib/plugins, $(SUBDIRS)),) - @echo 'Plugin targets:' - $(call print-help,plugins,Build the example TCG plugins) - @echo '' -endif @echo 'Cleaning targets:' $(call print-help,clean,Remove most generated files but keep the config) $(call print-help,distclean,Remove all generated files) diff --git a/contrib/plugins/Makefile b/contrib/plugins/Makefile deleted file mode 100644 index edf256cd9d1..00000000000 --- a/contrib/plugins/Makefile +++ /dev/null @@ -1,85 +0,0 @@ -# -*- Mode: makefile -*- -# -# This Makefile example is fairly independent from the main makefile -# so users can take and adapt it for their build. We only really -# include config-host.mak so we don't have to repeat probing for -# programs that the main configure has already done for us. -# - -include config-host.mak - -TOP_SRC_PATH = $(SRC_PATH)/../.. - -VPATH += $(SRC_PATH) - -NAMES := -NAMES += execlog -NAMES += hotblocks -NAMES += hotpages -NAMES += howvec - -# The lockstep example communicates using unix sockets, -# and can't be easily made to work on windows. -ifneq ($(CONFIG_WIN32),y) -NAMES += lockstep -endif - -NAMES += hwprofile -NAMES += cache -NAMES += drcov -NAMES += ips -NAMES += stoptrigger - -ifeq ($(CONFIG_WIN32),y) -SO_SUFFIX := .dll -LDLIBS += $(shell $(PKG_CONFIG) --libs glib-2.0) -else -SO_SUFFIX := .so -endif - -SONAMES := $(addsuffix $(SO_SUFFIX),$(addprefix lib,$(NAMES))) - -# The main QEMU uses Glib extensively so it is perfectly fine to use it -# in plugins (which many example do). -PLUGIN_CFLAGS := $(shell $(PKG_CONFIG) --cflags glib-2.0) -PLUGIN_CFLAGS += -fPIC -Wall -PLUGIN_CFLAGS += -I$(TOP_SRC_PATH)/include/qemu - -# Helper that honours V=1 so we get some output when compiling -quiet-@ = $(if $(V),,@$(if $1,printf " %-7s %s\n" "$(strip $1)" "$(strip $2)" && )) -quiet-command = $(call quiet-@,$2,$3)$1 - -# for including , in command strings -COMMA := , - -all: $(SONAMES) - -%.o: %.c - $(call quiet-command, \ - $(CC) $(CFLAGS) $(PLUGIN_CFLAGS) -c -o $@ $<, \ - BUILD, plugin $@) - -ifeq ($(CONFIG_WIN32),y) -lib%$(SO_SUFFIX): %.o win32_linker.o ../../plugins/libqemu_plugin_api.a - $(call quiet-command, \ - $(CC) -shared -o $@ $^ $(LDLIBS), \ - LINK, plugin $@) -else ifeq ($(CONFIG_DARWIN),y) -lib%$(SO_SUFFIX): %.o - $(call quiet-command, \ - $(CC) -bundle -Wl$(COMMA)-undefined$(COMMA)dynamic_lookup -o $@ $^ $(LDLIBS), \ - LINK, plugin $@) -else -lib%$(SO_SUFFIX): %.o - $(call quiet-command, \ - $(CC) -shared -o $@ $^ $(LDLIBS), \ - LINK, plugin $@) -endif - - -clean: - rm -f *.o *$(SO_SUFFIX) *.d - rm -Rf .libs - -.PHONY: all clean -.SECONDARY: