From nobody Mon Feb 9 20:35:17 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of _spf.google.com designates 209.85.208.68 as permitted sender) client-ip=209.85.208.68; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-ed1-f68.google.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of _spf.google.com designates 209.85.208.68 as permitted sender) smtp.mailfrom=philippe.mathieu.daude@gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1607459870; cv=none; d=zohomail.com; s=zohoarc; b=cwAMnOpmhderoeizXds71jJnuvJ1rTy+I3fdw12JR6BmgWPutW76UNHW4sSZ8Vjlmg/tvZNFEILUHZ72MRCX0dKMVs50yaj6TxkOQSot89VAOTqyN6PljQFiYpERW+EbYnSsT49GiiyxotcGDcCw2bj9I4lt0je9aEkF4ctVEuw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1607459870; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Sender:Subject:To; bh=0z868/KbdDk2Xlh007u1U18hSib0SeCI76U0+Y0b5XM=; b=khSEEbE0PTFVeJgrblIjBqog/ySr/iRrd098rIzP9wRPtReEttlKySZ0mwWko4nmOP8fyYukyq7JSa44fZYLIwSpcVIudgSF+4yktJAkvaOMurRTWIJPp5ala9NUUTjvANIN0Zn0pcc9Keq19XjrmI2FwDtwhWvlwMZbxi09d/s= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of _spf.google.com designates 209.85.208.68 as permitted sender) smtp.mailfrom=philippe.mathieu.daude@gmail.com Received: from mail-ed1-f68.google.com (mail-ed1-f68.google.com [209.85.208.68]) by mx.zohomail.com with SMTPS id 1607459870144818.3894420340749; Tue, 8 Dec 2020 12:37:50 -0800 (PST) Received: by mail-ed1-f68.google.com with SMTP id c7so18977088edv.6 for ; Tue, 08 Dec 2020 12:37:49 -0800 (PST) Return-Path: Return-Path: Received: from x1w.redhat.com (101.red-88-21-206.staticip.rima-tde.net. [88.21.206.101]) by smtp.gmail.com with ESMTPSA id v2sm9475230ejq.109.2020.12.08.12.37.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Dec 2020 12:37:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=0z868/KbdDk2Xlh007u1U18hSib0SeCI76U0+Y0b5XM=; b=Mij3zzPEiWTVyRfAz1dZRhxAJAUjpc94sNwFkJc2Qbp4XCJyd6SKeZhkzLaHCRDqod y6hmFcY0rbghCwvaqtLaYhtFJG/8gdwGd++ma3Erb3kX5QuvtjPcaZNenxmkA2Xxvxkb v/xHY2dNGb46LzE5j2SNK+KusYTJ6u98rg6j/mPrn1uFHTobxB5oM3QC+pBwW8Mh1zrR 15+52KM81Vzhraa4c/E8uvYc0QmT3g8CCuuKXT0VIShkCRf/zV7mdUUetH9p6soWNUi0 aMq5pk4+PCcj8owrtJc8imVKJvOZ3vJwnbTptHqial+4Z+HtHw2tGv5M0Hr2ZCcVhgtq bmhA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=0z868/KbdDk2Xlh007u1U18hSib0SeCI76U0+Y0b5XM=; b=dmKVOntnxwHVLDnY6c5yao4YCiJhBc/e+MFd+eeCK5iDJ5o6l3t/MYtPgLC2gVuWTR n4/2sldKJsTg5r6eccxNyLzuubDSFH+zMSb5KXd4LphYQlmDopEaR38j+m7guFMHOtGb cJGFmd8bruuBviDRhZYxhOnVGDm8b5p5+Trb/6KoHZvDXSvuCmOBagM8wbZmaxNg0Ofo FE+dQV1l1ygKxxgSlqrDWwLR8k2zZf1B67TBm1JLN2hIR7a9VdOWqhXGlBSwLNVnGjBK J7wsbIeWTsfkiMirq9PEWMfjRh9234EOLb2slsBWHhMK8sxsl0MEAZxh8J1hs9F/nVrQ nofw== X-Gm-Message-State: AOAM533SwSjlCv7iqCrV6BCoagplHhMzM1otpbuV4mfpu+S8UdPHC1dl ZTBoZtOMnlDJUZWR97tyxfI= X-Google-Smtp-Source: ABdhPJwp2liU+5QJaRAuh8gM4IaP2n3LoOxP8WFuAziirwd87L9HPNkg7g3lXZa1OjYnuBuEvpC8hw== X-Received: by 2002:a05:6402:1c8a:: with SMTP id cy10mr26202803edb.151.1607459868348; Tue, 08 Dec 2020 12:37:48 -0800 (PST) Sender: =?UTF-8?Q?Philippe_Mathieu=2DDaud=C3=A9?= From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Aurelien Jarno , Aleksandar Rikalo , Jiaxun Yang , Richard Henderson Subject: [PATCH 08/13] target/mips: Convert Rel6 CACHE/PREF opcodes to decodetree Date: Tue, 8 Dec 2020 21:36:59 +0100 Message-Id: <20201208203704.243704-9-f4bug@amsat.org> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20201208203704.243704-1-f4bug@amsat.org> References: <20201208203704.243704-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @gmail.com) CACHE/PREF opcodes have been removed from the Release 6. Add a single decodetree entry for the opcodes, triggering Reserved Instruction if ever used. Remove unreachable check_insn_opc_removed() calls. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Richard Henderson --- target/mips/isa-mips32r6.decode | 3 +++ target/mips/translate.c | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/target/mips/isa-mips32r6.decode b/target/mips/isa-mips32r6.dec= ode index 7b12a1bff25..e3b3934539a 100644 --- a/target/mips/isa-mips32r6.decode +++ b/target/mips/isa-mips32r6.decode @@ -19,3 +19,6 @@ LSA 000000 ..... ..... ..... 000 .. 00010= 1 @lsa REMOVED 010011 ----- ----- ----- ----- ------ # COP1X (COP3) =20 REMOVED 011100 ----- ----- ----- ----- ------ # SPECIAL2 + +REMOVED 101111 ----- ----- ---------------- # CACHE +REMOVED 110011 ----- ----- ---------------- # PREF diff --git a/target/mips/translate.c b/target/mips/translate.c index 81ca1d45063..ba1b2360c50 100644 --- a/target/mips/translate.c +++ b/target/mips/translate.c @@ -28667,7 +28667,6 @@ static void decode_opc(CPUMIPSState *env, DisasCont= ext *ctx) gen_st_cond(ctx, rt, rs, imm, MO_TESL, false); break; case OPC_CACHE: - check_insn_opc_removed(ctx, ISA_MIPS32R6); check_cp0_enabled(ctx); check_insn(ctx, ISA_MIPS3 | ISA_MIPS32); if (ctx->hflags & MIPS_HFLAG_ITC_CACHE) { @@ -28676,7 +28675,6 @@ static void decode_opc(CPUMIPSState *env, DisasCont= ext *ctx) /* Treat as NOP. */ break; case OPC_PREF: - check_insn_opc_removed(ctx, ISA_MIPS32R6); if (ctx->insn_flags & INSN_R5900) { /* Treat as NOP. */ } else { --=20 2.26.2