From patchwork Mon Dec 11 09:13:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 752503 Delivered-To: patch@linaro.org Received: by 2002:a5d:4c83:0:b0:333:3a04:f257 with SMTP id z3csp1197392wrs; Mon, 11 Dec 2023 01:15:02 -0800 (PST) X-Google-Smtp-Source: AGHT+IEhVrifaMnZGmriV+TYK9yEtCPJqI09D5iV1IdMwmfIcP2qId7fPj3YASAZoL3fvELy4csQ X-Received: by 2002:a05:6808:201e:b0:3b9:ec87:849 with SMTP id q30-20020a056808201e00b003b9ec870849mr5265809oiw.74.1702286102047; Mon, 11 Dec 2023 01:15:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702286102; cv=none; d=google.com; s=arc-20160816; b=opraUSGCIqKbtLeXBEA9kxwTDGTbwXl/XJNajVLQYti/R3PbJ8VJ6fBEPHzShgkHon Crw0uU07GfEIOXbwrsaxEeiuzV1shLfepx0xNIppsZ3vClRPJX9U8MXZ4y/z9mBVjs4+ 1KZZhYpNcIGmpqQWa5YL8Y48HEpwQxd2HQfSuAzOQxOW8VEA5IE6jylVa2l7GD/fl/1V c5TKhk3rbI7AJu9YRSFVa+G1WguWyfTIfq8K2qjWixccShqsmnWjDA8qKvF17ixBKqR9 RGFCBEDJu1wxJUPiJnDjstCOVSlcfefRHw6tY1U7AEELI8uelKMGolQXdxsNt2n8noac SE3g== 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=l1cZ8rGcMVRz/ykfSTmDydjLIdSR950YfUbOQT8uOwo=; fh=f1WUYuFnVBAEIncgxZ+HIUkw3mzwzJ7NOR6vwyn/FI0=; b=dVKFVifyhxfIDSpusk5gRQjMHk3TQbi99GH/DL+HIUq4tliR1KTISVpAingEmZcQf6 ZAnCKREOCPXFkFd8zvBhZOXhmoZkiF/lmGisUP5+H12B+T6V6WEUkZ59BcYznOKzcwFl qUQUWc2/HEfA0UAiosV+eiD3wyXAs5QZIUBC9CX/7doWt1ODRZc6cyOlOJhYPp+uHmYi yGFNphAVg96bxUogL1OTeZ1L76NJrMAqs7Lts5vuCOVR1XyANvKPS5y6bNsFmYVaS1KE zqdgqeoKGnXvEnqdQRpFqciE2ge/A6OWvlC66xq40kEe164vcGK/5CXuphTPVXHPboQ/ /TBA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=KGgKrk+8; 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 r17-20020a05622a035100b00425a1900d5csi7043094qtw.240.2023.12.11.01.15.01 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 11 Dec 2023 01:15:02 -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=KGgKrk+8; 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 1rCcMP-0001Pc-CQ; Mon, 11 Dec 2023 04:13:57 -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 1rCcMO-0001PP-Ab for qemu-devel@nongnu.org; Mon, 11 Dec 2023 04:13:56 -0500 Received: from mail-wr1-x42c.google.com ([2a00:1450: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 1rCcMM-0004LJ-8b for qemu-devel@nongnu.org; Mon, 11 Dec 2023 04:13:56 -0500 Received: by mail-wr1-x42c.google.com with SMTP id ffacd0b85a97d-3332efd75c9so3883228f8f.2 for ; Mon, 11 Dec 2023 01:13:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1702286032; x=1702890832; 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=l1cZ8rGcMVRz/ykfSTmDydjLIdSR950YfUbOQT8uOwo=; b=KGgKrk+8Bf+dJFtmWBVg05DLPWCHtxY9yGBJjbllP2Lvb1Wg0lHq/GJwex8pu/V2Af FsQbUUqcIburb+I1T0hEKbTVAaL1gbEWPyU9e+drtGMLt/WFaaML334dQOmfJ5jIpaEv A1b8QgduwjDegIPPlMsQ9KKxinm9fx5Ia+9To22Xsmv20fbNjqbyPECtAr0AGD3XlCzk +dbZWCGsELBT03VGUREWxswvqLFPxQFRdE8MUCM4SJaT8kH6f1kClnDti9P3VuIgmlBz YrUI12QtnqN/+kVIvBI615LmBBb9CKBKhsjfb808CN2cM8m3fbjMolf8FSiTxiWP4vj9 DjnQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702286032; x=1702890832; 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=l1cZ8rGcMVRz/ykfSTmDydjLIdSR950YfUbOQT8uOwo=; b=ZUBpBE6DvzyLmG/0XD6N8sdhpG1FchPKODWrXt6MraQALxKSzmQneECE9uEwEYgHD8 VA4pgKGCBZAQUq2tiHgPiaqjdJQt2L5LeqWKNyMvMIV0EcbgfUbwS7YAsVnIXa1JusKK rqXzHrXAegRwuwEdj4m5ZXX8dzRQzcIdnOCo/2+vLgmN+JGm5sxxRbFAhY4qqqObSnVC eFPiGK9C4mjs7QysZM8E6z2IMZu8CPaxxWnYL7UiX3TqC7g9qyEC/8eAIZEywZgEtEur JEHsv5AIVh3DuqUjoWIp4gh73Omre+o5Ualps5K4NghxBlHJM9xfkRXQZSWLglTrx9Gw 9u2g== X-Gm-Message-State: AOJu0Yx27Mfl0nRcFVJ/G2J+xsTFd72lPt7E7qphaL+/XBvvmHT4VVkA XHkGvXN0sWxlmtG5tib+pvFCQw== X-Received: by 2002:a5d:54c4:0:b0:333:49a8:73ea with SMTP id x4-20020a5d54c4000000b0033349a873eamr839277wrv.249.1702286032722; Mon, 11 Dec 2023 01:13:52 -0800 (PST) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id d16-20020a5d4f90000000b0033349bccac6sm8151663wru.1.2023.12.11.01.13.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 11 Dec 2023 01:13:51 -0800 (PST) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id AFD245FBEA; Mon, 11 Dec 2023 09:13:46 +0000 (GMT) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: John Snow , Eduardo Habkost , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Paolo Bonzini , Wainer dos Santos Moschetta , Cleber Rosa , =?utf-8?q?Marc-Andr=C3=A9_Lureau?= , Beraldo Leal , Richard Henderson , Pavel Dovgalyuk , =?utf-8?q?Alex_Benn=C3=A9e?= , Pavel Dovgalyuk Subject: [PATCH v2 07/16] replay: add proper kdoc for ReplayState Date: Mon, 11 Dec 2023 09:13:36 +0000 Message-Id: <20231211091346.14616-8-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231211091346.14616-1-alex.bennee@linaro.org> References: <20231211091346.14616-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::42c; envelope-from=alex.bennee@linaro.org; helo=mail-wr1-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 Remove the non-standard comment formatting and move the descriptions into a proper kdoc comment. Message-Id: <20231205204106.95531-7-alex.bennee@linaro.org> Reviewed-by: Pavel Dovgalyuk Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée --- replay/replay-internal.h | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/replay/replay-internal.h b/replay/replay-internal.h index 516147ddbc..98ca3748ed 100644 --- a/replay/replay-internal.h +++ b/replay/replay-internal.h @@ -63,24 +63,31 @@ enum ReplayEvents { EVENT_COUNT }; +/** + * typedef ReplayState - global tracking Replay state + * + * This structure tracks where we are in the current ReplayState + * including the logged events from the recorded replay stream. Some + * of the data is also stored/restored from VMStateDescription when VM + * save/restore events take place. + * + * @cached_clock: Cached clocks values + * @current_icount: number of processed instructions + * @instruction_count: number of instructions until next event + * @data_kind: current event + * @has_unread_data: 1 if event not yet processed + * @file_offset: offset into replay log at replay snapshot + * @block_request_id: current serialised block request id + * @read_event_id: current async read event id + */ typedef struct ReplayState { - /*! Cached clock values. */ int64_t cached_clock[REPLAY_CLOCK_COUNT]; - /*! Current icount - number of processed instructions. */ uint64_t current_icount; - /*! Number of instructions to be executed before other events happen. */ int instruction_count; - /*! Type of the currently executed event. */ unsigned int data_kind; - /*! Flag which indicates that event is not processed yet. */ unsigned int has_unread_data; - /*! Temporary variable for saving current log offset. */ uint64_t file_offset; - /*! Next block operation id. - This counter is global, because requests from different - block devices should not get overlapping ids. */ uint64_t block_request_id; - /*! Asynchronous event id read from the log */ uint64_t read_event_id; } ReplayState; extern ReplayState replay_state;