From patchwork Thu Dec 7 15:45:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 751072 Delivered-To: patch@linaro.org Received: by 2002:adf:a499:0:b0:333:3a04:f257 with SMTP id g25csp501932wrb; Thu, 7 Dec 2023 07:46:45 -0800 (PST) X-Google-Smtp-Source: AGHT+IEK+92hkWUTc4drgepmijgdgCOG9EUdcx880KTJi0/VLPPe4h6Ij7d0XNebla7kPRSPZx2T X-Received: by 2002:ac8:5813:0:b0:423:7c65:e4df with SMTP id g19-20020ac85813000000b004237c65e4dfmr3731939qtg.14.1701964005034; Thu, 07 Dec 2023 07:46:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701964005; cv=none; d=google.com; s=arc-20160816; b=sKJG/nl1rPSahbCuQuNHQ4M6q9U/+3rRW0E8qfQ6sB3wloMslhLcxcZlvMS5mSAXkx 7ExJw83jfmhGplxu7PH9tf7AAmF1oA1VpNwEAbWdJEa9T+BCLLlU0CpdmaVtyjf0lbXe GU3/nMqYG4ML2AwsUhE3EYxltMmb27GdbPVPfwQevb6ry7idS/tsBBjNAQDgckKMi65C rsOCE8whOvuTGIihqsdF/jS1ttP9uslUaHNHf+xXwLZEa1LlRuBHWyfgb+GKvQvf0neN YDXntf2CZBJmhJaGCiNQwkwrg/XOq0FtSGaeAOhmvFNF3adGJFGkyRl41eCCvX9YHFJm 2eNw== 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:message-id:date:subject:cc:to:from:dkim-signature; bh=qIgSJSXHt73pYKp369uQ7oGZDAJNmZg50+PsPECtSzM=; fh=A8ftaDMzewcMA0xKw++MSYMuCBPymoWdeCEx+9KcU8w=; b=d/Dviu0hkdBv1JIXMpEUBFeKo2GVUIxf69yjLMobG5Es9eFG1CEpji6GqP0W6FX2/P pDpavn/iaG8YbXvfTxZV5pMeUxa4eeZ+KnrHeCkGhrr1ixBOWt0kmv1/Ual/5jt5nS17 eL6HU3TvZ4N1Xs59Mv66lzWIHWqwxVVJyp61tCGGSGkDtzlEXbHgftPbHmO4HgdX5ojf LzJMvwKYGfaSIv1Dm5rwHrkuLUITvMfr5fkfFFiMG9Ik14aT5YNMyxPzDtwwhZeRPMjp 64aDZIE3tb4PMZNcz/ZfU8nkNJi4D9HNSFQoOK/9ZG7oN8cIFb2fAFB6opNZU1RFs89o bkXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=yPmOcxmt; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id bb21-20020a05622a1b1500b00423759c77cdsi30752qtb.523.2023.12.07.07.46.44 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 07 Dec 2023 07:46:45 -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=yPmOcxmt; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rBGZb-0000db-Ky; Thu, 07 Dec 2023 10:46:07 -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 1rBGZa-0000cH-49 for qemu-devel@nongnu.org; Thu, 07 Dec 2023 10:45:58 -0500 Received: from mail-ej1-x635.google.com ([2a00:1450:4864:20::635]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rBGZX-000288-82 for qemu-devel@nongnu.org; Thu, 07 Dec 2023 10:45:57 -0500 Received: by mail-ej1-x635.google.com with SMTP id a640c23a62f3a-a1db6c63028so117604666b.2 for ; Thu, 07 Dec 2023 07:45:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1701963953; x=1702568753; darn=nongnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=qIgSJSXHt73pYKp369uQ7oGZDAJNmZg50+PsPECtSzM=; b=yPmOcxmtk1uZRWr5zPeO3h132lPrZLZeOyb/rsCEz5o1FWpMqjIG5sSbC4BQgjv8Uf M00QUCIxBUZElgBEiDgoJOxlJLvnsTeltLPYQ6117WFYn0b1PccxkUMwWlgXKrSgQ/VV lQC0ReU0jn0C+5vuS75V9Mk0leu7Fear5HPRmEf4oteeIzDTBnFDa4csdu7MckFIWKyS nMABy5MDbI5GVVX1sHk8ITg4DbNxyb0ceBOTYCO4dNhiR5Q9DDtWal2/xwacAupZ8E/M tPhvklDURjArcv7/2tZKVXgWt8YHTiCgvTAkvo6u5NcISB3gsm3igAgqKSawX76SQLDy UtGg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701963953; x=1702568753; 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=qIgSJSXHt73pYKp369uQ7oGZDAJNmZg50+PsPECtSzM=; b=MP6wzZMMdc9uUoYKfAhfVdsapSCzbXipk573wAP3BRflnEOvzwc3oJv79/VkH4a8tJ j2pHabAAeOqIYCXsyGyvIsUUPIUrAkEL/hEFtEs52cRpuxDyLrxvwMGLJ+Ph+gVinNVd wXzNEuOjxbaM8r5ZX9OUewp3wV7OjGnP/5gx2FeRYzF6nuL9QmVO9cf1FZsnJZcXKxyP t6+y3CxL/9iJODXYjxyv75EyV/jQ3lQEMouztOp6JhrCh5a57jUzO+ENshRm/1BkmfLW cXnEVoHbDDTYqHnccLwv9ACyUbevIIok6WZNeKNYd9yLFk9RyHnEGB8VOLaVxjTpYEwn 4L4Q== X-Gm-Message-State: AOJu0YxdVozc13T5UgwXQVDdvIOz45wnCXTaMViVMNssaYccOzQ13jMr atkBmAtPFDzZjlJFySRaOWnrT/mkMUV81Az3mKQ= X-Received: by 2002:a17:907:ca1d:b0:9be:7b67:1674 with SMTP id uk29-20020a170907ca1d00b009be7b671674mr1542810ejc.3.1701963953651; Thu, 07 Dec 2023 07:45:53 -0800 (PST) Received: from m1x-phil.lan ([176.187.202.111]) by smtp.gmail.com with ESMTPSA id t15-20020a1709066bcf00b00a1b65249053sm969126ejs.128.2023.12.07.07.45.51 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Thu, 07 Dec 2023 07:45:53 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: qemu-arm@nongnu.org, Pavel Dovgalyuk , Fam Zheng , Stefan Hajnoczi , Richard Henderson , qemu-block@nongnu.org, Paolo Bonzini , Peter Maydell , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= Subject: [PATCH v2 0/5] sysemu/replay: Restrict icount to TCG system emulation Date: Thu, 7 Dec 2023 16:45:45 +0100 Message-ID: <20231207154550.65087-1-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::635; envelope-from=philmd@linaro.org; helo=mail-ej1-x635.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=unavailable 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 Slightly simplify non-TCG and user emulation code. Since v1: - Introduce enum of icount modes - Fix ARM INST_RETIRED event Philippe Mathieu-Daudé (5): sysemu/cpu-timers: Introduce ICountMode enumerator target/arm: Ensure icount is enabled when emulating INST_RETIRED util/async: Only call icount_notify_exit() if icount is enabled system/vl: Restrict icount to TCG emulation sysemu/replay: Restrict icount to system emulation include/sysemu/cpu-timers.h | 22 ++++++++++++++-------- include/sysemu/replay.h | 11 ++++++++--- accel/tcg/icount-common.c | 16 +++++++--------- stubs/icount.c | 29 ++--------------------------- system/cpu-timers.c | 2 +- system/vl.c | 6 +++++- target/arm/helper.c | 5 ++++- util/async.c | 16 +++++++++------- 8 files changed, 50 insertions(+), 57 deletions(-)