From nobody Sun May 19 10:57:29 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1687346146; cv=none; d=zohomail.com; s=zohoarc; b=Yv4FcznpBnRgWpa/ShVGC4vvhdNMAvFiyDS7NtKHi9k3x8XA2DEDR4hx1aogYR8tE5HOuxDnjStU5mQueDbxsWgnlpyqVMuJBX15rX3NCsilaisSJ8S/52K29PkUD3O31rd/7EIlH3YJ9hhF+G8drM2JQT7hVol5GWBRgS8BeCU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1687346146; h=Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=BF7bvq7+IWyfrCATWCi++Znx31JboqJ4DiKQyx+7chM=; b=SFe22sb7+qBoVjT22cGjs8/imRYrmZgfoJdu+lk7TjOwYMW+iSV6XThsXXhMCSrYawPHBr1xSY/2fmpVGkzD7SWWh2GspvHJlL5KHEN6KdIaC61ncx5uabx+nJ2pNAXbaGbqFRZqtAVPIrZMrIx8I5vLFbnMK8Z3hxYxBMVfPsc= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1687346146659424.41651633027345; Wed, 21 Jun 2023 04:15:46 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qBvoC-0004qF-5O; Wed, 21 Jun 2023 07:15:32 -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 1qBvoA-0004ot-4f for qemu-devel@nongnu.org; Wed, 21 Jun 2023 07:15:30 -0400 Received: from mail-ej1-x62d.google.com ([2a00:1450: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 1qBvo4-0003LO-Dc for qemu-devel@nongnu.org; Wed, 21 Jun 2023 07:15:28 -0400 Received: by mail-ej1-x62d.google.com with SMTP id a640c23a62f3a-988e6fc41ccso348032566b.3 for ; Wed, 21 Jun 2023 04:15:23 -0700 (PDT) Received: from stoup.lan ([176.176.128.70]) by smtp.gmail.com with ESMTPSA id q10-20020a170906144a00b00987506c21b1sm2929972ejc.219.2023.06.21.04.15.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Jun 2023 04:15:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1687346122; x=1689938122; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=BF7bvq7+IWyfrCATWCi++Znx31JboqJ4DiKQyx+7chM=; b=vmYiLm0qHYYPjSGUnOXLgzcZPAfZQ19QFYxEwaaNpfKpLfcM0cvypEwfyxsOXDwuWZ Z+0yq007+AfUXDqKlxhPjMEuhDQFC5Rqgrfrm265DC1VcK43MmfN39viUAhBgoBpDtbZ jWcW2xq8XD9tY0bt6pMYzTW8QH16Rgm5VJLmNICqZcevm9Sv2mBGpd0IzLbsHaX5BQTG m/brLIThkbWIkserW8RGKXpdkNUWS63ZupyircIX5MmsA5N5tT3i9rAgylWHeyKIdol6 VC1VgDikU39GRDjtRpjAzzHjLu87uzPBDi7h4/hNuzPcGUD5uHzJLOOn6yrb++4zZVy5 O09A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687346122; x=1689938122; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=BF7bvq7+IWyfrCATWCi++Znx31JboqJ4DiKQyx+7chM=; b=EbagYXlY5JFuwH6znXtQEAvu3SvDHq3si0ln7achCewqG42uv8HM7eXDNrKm5bUmfL Rqy9FoMd8Zia5bOU6kszxwgHzBHPnQL3xjphgxep0ZEMwYV4+vrgObSZAXpkqFRqKajZ Z9/t7QdLtc/gdmtC9atccNT7jCAA/xNfzW4PPX2Hr9ZxN9EnC1rjSWrf3MN4vr778sgl Ik1FyEJrF7uqYJiuhumBesMOIWMB9OnqWvq2vhWioj+PQJ+vKNPLA4RkuoO48BgrfXH5 ksJdqo1A4az3D0Kkrav8MS5NxfczGfmMu01FP9waZgXlayjh1UXToYDjEiSwAzie/FNb efpQ== X-Gm-Message-State: AC+VfDz3BhupzjYXvcG0LiJrOfizNkGniTf9rSygmbCOrAmFmlQbFtq2 xH8/B+O3CZmeyfmE2Fpny9I2sacsBs3TG/Ttuh1y5mJZ X-Google-Smtp-Source: ACHHUZ43vZ37QKR/WlSMjG8wd4oenogmgVwWkaqgzLodthBC9C0NDXozzGiGt/TELnXCv7FAgCYodA== X-Received: by 2002:a17:906:db0d:b0:982:80b7:ad4c with SMTP id xj13-20020a170906db0d00b0098280b7ad4cmr12163777ejb.16.1687346122234; Wed, 21 Jun 2023 04:15:22 -0700 (PDT) From: Richard Henderson To: qemu-devel@nongnu.org Cc: alex.bennee@linaro.org Subject: [PATCH v3] tests/plugin: Remove duplicate insn log from libinsn.so Date: Wed, 21 Jun 2023 13:15:20 +0200 Message-Id: <20230621111520.1390967-1-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a00:1450:4864:20::62d; envelope-from=richard.henderson@linaro.org; helo=mail-ej1-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, 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1687346147996100001 Content-Type: text/plain; charset="utf-8" This is a perfectly natural occurrence for x86 "rep movb", where the "rep" prefix forms a counted loop of the one insn. During the tests/tcg/multiarch/memory test, this logging is triggered over 350000 times. Within the context of cross-i386-tci build, which is already slow by nature, the logging is sufficient to push the test into timeout. Signed-off-by: Richard Henderson --- tests/plugin/insn.c | 9 +-------- tests/tcg/i386/Makefile.softmmu-target | 9 --------- tests/tcg/i386/Makefile.target | 6 ------ tests/tcg/x86_64/Makefile.softmmu-target | 9 --------- 4 files changed, 1 insertion(+), 32 deletions(-) diff --git a/tests/plugin/insn.c b/tests/plugin/insn.c index cd5ea5d4ae..9bd6e44f73 100644 --- a/tests/plugin/insn.c +++ b/tests/plugin/insn.c @@ -19,7 +19,6 @@ QEMU_PLUGIN_EXPORT int qemu_plugin_version =3D QEMU_PLUGI= N_VERSION; #define MAX_CPUS 8 /* lets not go nuts */ =20 typedef struct { - uint64_t last_pc; uint64_t insn_count; } InstructionCount; =20 @@ -51,13 +50,7 @@ static void vcpu_insn_exec_before(unsigned int cpu_index= , void *udata) { unsigned int i =3D cpu_index % MAX_CPUS; InstructionCount *c =3D &counts[i]; - uint64_t this_pc =3D GPOINTER_TO_UINT(udata); - if (this_pc =3D=3D c->last_pc) { - g_autofree gchar *out =3D g_strdup_printf("detected repeat executi= on @ 0x%" - PRIx64 "\n", this_pc); - qemu_plugin_outs(out); - } - c->last_pc =3D this_pc; + c->insn_count++; } =20 diff --git a/tests/tcg/i386/Makefile.softmmu-target b/tests/tcg/i386/Makefi= le.softmmu-target index ed922d59c8..5266f2335a 100644 --- a/tests/tcg/i386/Makefile.softmmu-target +++ b/tests/tcg/i386/Makefile.softmmu-target @@ -33,14 +33,5 @@ EXTRA_RUNS+=3D$(MULTIARCH_RUNS) =20 memory: CFLAGS+=3D-DCHECK_UNALIGNED=3D1 =20 -# non-inline runs will trigger the duplicate instruction heuristics in lib= insn.so -run-plugin-%-with-libinsn.so: - $(call run-test, $@, \ - $(QEMU) -monitor none -display none \ - -chardev file$(COMMA)path=3D$@.out$(COMMA)id=3Doutput \ - -plugin ../../plugin/libinsn.so$(COMMA)inline=3Don \ - -d plugin -D $*-with-libinsn.so.pout \ - $(QEMU_OPTS) $*) - # Running QEMU_OPTS+=3D-device isa-debugcon,chardev=3Doutput -device isa-debug-exit,= iobase=3D0xf4,iosize=3D0x4 -kernel diff --git a/tests/tcg/i386/Makefile.target b/tests/tcg/i386/Makefile.target index 821822ed0c..f2ee7a4db7 100644 --- a/tests/tcg/i386/Makefile.target +++ b/tests/tcg/i386/Makefile.target @@ -63,12 +63,6 @@ else SKIP_I386_TESTS+=3Dtest-i386-fprem endif =20 -# non-inline runs will trigger the duplicate instruction heuristics in lib= insn.so -run-plugin-%-with-libinsn.so: - $(call run-test, $@, $(QEMU) $(QEMU_OPTS) \ - -plugin ../../plugin/libinsn.so$(COMMA)inline=3Don \ - -d plugin -D $*-with-libinsn.so.pout $*) - # Update TESTS I386_TESTS:=3D$(filter-out $(SKIP_I386_TESTS), $(ALL_X86_TESTS)) TESTS=3D$(MULTIARCH_TESTS) $(I386_TESTS) diff --git a/tests/tcg/x86_64/Makefile.softmmu-target b/tests/tcg/x86_64/Ma= kefile.softmmu-target index 7207fee94c..1bd763f2e6 100644 --- a/tests/tcg/x86_64/Makefile.softmmu-target +++ b/tests/tcg/x86_64/Makefile.softmmu-target @@ -33,14 +33,5 @@ EXTRA_RUNS+=3D$(MULTIARCH_RUNS) =20 memory: CFLAGS+=3D-DCHECK_UNALIGNED=3D1 =20 -# non-inline runs will trigger the duplicate instruction heuristics in lib= insn.so -run-plugin-%-with-libinsn.so: - $(call run-test, $@, \ - $(QEMU) -monitor none -display none \ - -chardev file$(COMMA)path=3D$@.out$(COMMA)id=3Doutput \ - -plugin ../../plugin/libinsn.so$(COMMA)inline=3Don \ - -d plugin -D $*-with-libinsn.so.pout \ - $(QEMU_OPTS) $*) - # Running QEMU_OPTS+=3D-device isa-debugcon,chardev=3Doutput -device isa-debug-exit,= iobase=3D0xf4,iosize=3D0x4 -kernel --=20 2.34.1