From nobody Mon May 6 12:02:17 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=1596461370; cv=none; d=zohomail.com; s=zohoarc; b=KU/RYjbIUnjOc8tIiV0fCtNpMMecYNF9MP/HhDuWfhdH08GhSYkoXTkdB+ULEE0iPK6OcBGMsgvKsA3x4A+qjLtPpzxWgW7VDXGJDoNbmvNNez2q4en5phbefV2rfAKXu9WTLJmyVW1QlanNBvaXxOszdVSoSemdQGl8WgbLPhE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1596461370; h=Content-Transfer-Encoding:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=AyFACLs1JXpjGZamPbhug492vRl8MO0LxHw3leLeOJY=; b=LyiI1jFd8QticwzHMQHzf4XIvahLQzlwBJb7ox+2rXd5xollFD9iXgWEvntCJhIPI1KJY7KLSyKNtCgpPbMzQeySEcrHXei5139nHf0VlynP6mFZRbX4NLCGu8X/lWZdKHtYnQImGLFu0TmddZQTxfSebdbPTlF5v0snvOg5jaA= 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) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1596461370801190.15522963205422; Mon, 3 Aug 2020 06:29:30 -0700 (PDT) Received: from localhost ([::1]:40168 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1k2aWu-0006Tl-36 for importer@patchew.org; Mon, 03 Aug 2020 09:29:28 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49988) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1k2aVq-0005Y5-FL for qemu-devel@nongnu.org; Mon, 03 Aug 2020 09:28:22 -0400 Received: from mail-wm1-x344.google.com ([2a00:1450:4864:20::344]:52513) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1k2aVn-0004Rb-VP for qemu-devel@nongnu.org; Mon, 03 Aug 2020 09:28:22 -0400 Received: by mail-wm1-x344.google.com with SMTP id x5so14329698wmi.2 for ; Mon, 03 Aug 2020 06:28:18 -0700 (PDT) Received: from orth.archaic.org.uk (orth.archaic.org.uk. [81.2.115.148]) by smtp.gmail.com with ESMTPSA id l1sm26508028wrb.12.2020.08.03.06.28.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 03 Aug 2020 06:28:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=AyFACLs1JXpjGZamPbhug492vRl8MO0LxHw3leLeOJY=; b=X7aFV4F42hecCsGW9+iHhpQSqD6Mjv1znBSbF1rrrUrbeqpid8cHtc/TEqca8L+nh2 MG/7gwmmOFCQTPZY1X0+VIwvfkhTsuOAr5RernW6JBENEVls95NwFoXVqaEAbP1J8WMl nTLP2l0L+VjAb3bHiDba3vevzoYugfUue0vwEAx2Z6rWvMqzif9235fG1Geng1mLHjJU l6Z+w+eQBbC5l4iJniwlxlG1YEejc825+3IfnfMojxFqChJKKqcEt63xDKs47tE8jbuu xP5B+qDVVdsAyNzMbyGCkPcbEYcRZQ/unYkW1h90Cxq+SV65CY7MAD9h2zYIWcZ3gAGm Nb8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=AyFACLs1JXpjGZamPbhug492vRl8MO0LxHw3leLeOJY=; b=AIsgMzhexqmly4Nw24cAkaK4HPAdI10EtVjp8wWpaP6ZOFSwoe+HIt/b7qMBR38pyq ZTuvOMsEAxgAMyTCMCgiK0bxGflr+lpX5LOA7N6+9fQnmvoZXJxyHr+CuyPrwK2G3wR/ NT4kH8vQvWeYVAMBXE5ztI6xy3uHiMa0pAGW7yW3wJf3UHQclKaz0pO8UQEakFkIhLOI mivEy2c8b6KNvKvSmdogsfeTU/BkC2qzUxvwGpfloxBAWpAhQVrVnYTx03yqJ3hEyPc7 t+F2XIdTSKf1O4ygX6AKiMoi6wZ8YUKLe/1i/ho9wojS2hCEmDV+DRjoe5dIcko4WzJr nyzg== X-Gm-Message-State: AOAM531w6xD/kQJDrRwz0DNKNLAVYTu3WHvKsdww/o7/dzOtZSE9mfik a/fGjQFa0LEdeJlYj60S4y0WiQ== X-Google-Smtp-Source: ABdhPJypDnZ9XBzlIWTSF8JCykOKTgBtAywcwsDMh26hmcRVGIKea0nclVxOLJ0nHS1D0wtSi33XQw== X-Received: by 2002:a7b:ce81:: with SMTP id q1mr85393wmj.24.1596461297424; Mon, 03 Aug 2020 06:28:17 -0700 (PDT) From: Peter Maydell To: qemu-arm@nongnu.org, qemu-devel@nongnu.org Subject: [PATCH] target/arm/translate.c: Delete/amend incorrect comments Date: Mon, 3 Aug 2020 14:28:15 +0100 Message-Id: <20200803132815.3861-1-peter.maydell@linaro.org> X-Mailer: git-send-email 2.20.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::344; envelope-from=peter.maydell@linaro.org; helo=mail-wm1-x344.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 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" X-ZohoMail-DKIM: pass (identity @linaro.org) Content-Type: text/plain; charset="utf-8" In arm_tr_init_disas_context() we have a FIXME comment that suggests "cpu_M0 can probably be the same as cpu_V0". This isn't in fact possible: cpu_V0 is used as a temporary inside gen_iwmmxt_shift(), and that function is called in various places where cpu_M0 contains a live value (i.e. between gen_op_iwmmxt_movq_M0_wRn() and gen_op_iwmmxt_movq_wRn_M0() calls). Remove the comment. We also have a comment on the declarations of cpu_V0/V1/M0 which claims they're "for efficiency". This isn't true with modern TCG, so replace this comment with one which notes that they're only used with the iwmmxt decode. Signed-off-by: Peter Maydell Reviewed-by: Richard Henderson --- In an ideal world we would clean up the iwmmxt decode to remove cpu_V0, cpu_v1 and cpu_M0 entirely -- they're only used as temporaries, and in a modern coding style we would just create and dispose of more carefully scoped TCG temps as we needed them. --- target/arm/translate.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/arm/translate.c b/target/arm/translate.c index 27bf6cd8b51..87235db4640 100644 --- a/target/arm/translate.c +++ b/target/arm/translate.c @@ -59,8 +59,9 @@ #define IS_USER(s) (s->user) #endif =20 -/* We reuse the same 64-bit temporaries for efficiency. */ +/* These are TCG temporaries used only by the legacy iwMMXt decoder */ static TCGv_i64 cpu_V0, cpu_V1, cpu_M0; +/* These are TCG globals which alias CPUARMState fields */ static TCGv_i32 cpu_R[16]; TCGv_i32 cpu_CF, cpu_NF, cpu_VF, cpu_ZF; TCGv_i64 cpu_exclusive_addr; @@ -8552,7 +8553,6 @@ static void arm_tr_init_disas_context(DisasContextBas= e *dcbase, CPUState *cs) =20 cpu_V0 =3D tcg_temp_new_i64(); cpu_V1 =3D tcg_temp_new_i64(); - /* FIXME: cpu_M0 can probably be the same as cpu_V0. */ cpu_M0 =3D tcg_temp_new_i64(); } =20 --=20 2.20.1