From patchwork Thu Aug 31 20:30:16 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: 719022 Delivered-To: patch@linaro.org Received: by 2002:adf:e5c2:0:b0:31d:da82:a3b4 with SMTP id a2csp688940wrn; Thu, 31 Aug 2023 13:31:36 -0700 (PDT) X-Google-Smtp-Source: AGHT+IG+NIK8nQA7trSm/+qDD3+Dx0Kfc45o9sU6H+wtnZtixyhFTMWlb/AkP7NqCgmBxe3sj3R/ X-Received: by 2002:a05:620a:25d1:b0:767:dbe5:1f2f with SMTP id y17-20020a05620a25d100b00767dbe51f2fmr537346qko.35.1693513895207; Thu, 31 Aug 2023 13:31:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1693513895; cv=none; d=google.com; s=arc-20160816; b=fzBUQt8Tr1L0e9ND5dHDNnMSEDATkrhYQ4TXiKZ+KnS3ejo1szeNlRS1X0Bo0mWZID BqDz4ETWYzn4W69ZqqSGabWQSITYCgmElx8xdAkEmuR4VBAW/yXEOOKoqllnhqSIVlQZ UAfmjVHHYBXhMZk61rphDThDQoXpNFj6VPs0pmQcdw0X62/O+15UkZaPUAqxxIZ5/qcN H0MhFhatmPEaBIOBAxOzWtfgjH59Yn8uf/uIwvGtelHOghvuU5Ih3Np/C7FN1zHpU31i ZdLbeatkglAlm+Ro6hlwUP4GG2S3FnnouX+WrS7fXR3xmfrLA10C9KHjtlnzswebY2ku lXig== 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=GPoMTlp876b4GOvagv/YEBtZYu5eWFRVSdZFP4aw4Ic=; fh=b1bGX1gthWRc+b0P2ZUA4luCnLR4+eQBBX4GbGYn2tc=; b=NYhG0x0PPRhONJmUXyPeYUZMe0obU6VMmoFLHZUiMVCVrR0+sEZqs0i0+MuZMTZZ2g ADk8m9iz6SpabIRCVng4Px59h++P1rMPInUkQ2FCy2K2ql2GqAI4X92ARBoocmLA2txd mogGnflsWcy/keyssk9cE/GKRv8XbSsJPWP4eCGzU1KFXfd7Rf9Ww02XUP1Z+5JS6+lR 5Cg9lssQrPUBJSTcEyqfNPY/Y6TttK6K1nifOPOXd7seTm8svlhg3aSJ9Sf+xInB7Kcr 1tqgx/didwA+7YM1GQpgZ+pwLvBYs7csEZ6HguCJujPA6uyuKMvNlYWmh5xt4OnJuIzj OT3A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=rVaHC0UQ; 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 v11-20020a05620a0f0b00b0076c7efa5c38si1500930qkl.616.2023.08.31.13.31.35 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 31 Aug 2023 13:31:35 -0700 (PDT) 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=rVaHC0UQ; 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 1qboJZ-000058-8s; Thu, 31 Aug 2023 16:30:53 -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 1qboJD-0008W0-Cm for qemu-devel@nongnu.org; Thu, 31 Aug 2023 16:30:32 -0400 Received: from mail-ej1-x62f.google.com ([2a00:1450:4864:20::62f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qboJB-0002Zk-1D for qemu-devel@nongnu.org; Thu, 31 Aug 2023 16:30:31 -0400 Received: by mail-ej1-x62f.google.com with SMTP id a640c23a62f3a-99bcfe28909so140399566b.3 for ; Thu, 31 Aug 2023 13:30:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1693513827; x=1694118627; 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=GPoMTlp876b4GOvagv/YEBtZYu5eWFRVSdZFP4aw4Ic=; b=rVaHC0UQAlTx0n+qDCiwgcD/ypK5+rMl/oLyBfsgmsddH+6gohCXq0o6/dX2S+DNwx EXKr1VWpTQfyLcuMR/oQLaj470dGkWzat1Gbxk3zqHUitox5quv1BIHxvsdNHcLF2vNA u/Y58mIbhPWrnaB3HvA3SrViKmOdFZh7xAhjAH2Lb3zPcEFer2EyTERO1S5nMa6uqGoO 80jzQfMWglXQi9rhn6SE/Psm38xdlD7T+WURJ1U6TGNf7FAZLq1OdoUC6guzR1xLwCkq 3qt3GJqtZ9TCFqo3Its25bl5RchzaCw3PpCMV6iTjHHZWO7ROEZpSbYpwT95Lmk0zhI0 90wA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693513827; x=1694118627; 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=GPoMTlp876b4GOvagv/YEBtZYu5eWFRVSdZFP4aw4Ic=; b=kcal+G/Q9dFAm+BSSF3kbvPUY7b8l2yyrwhieowakAwLT+p83zEbUIZzp1AZAfgTrt bQXdDx9MrT1af8fuOst18d0Z51nF20342OBpURrK24pe4S/502a4RWU+4oEZqNluJerG bYDBNZr9K7Uk8XdQomo469Vxl0app9bOt90VIZEB4LI9fogZb6IZiKZAOyR7mlnlZ0kD /mAly5rgd3Sz6b65Dc/JK7RXTc0s/pLQVLUvuBluWc5rjcbgjf7EPFr+OZ5vLP3CuQmT E8ZL1Hsqbd/qUfv/Cf9B2pDV4kqa3Tyz/OMXODe9kNOnVioOjKV1HcdNot0aXUhIljhg TIEA== X-Gm-Message-State: AOJu0YxDoxDumfCjwiPdlECcaPkKoIxTN9mKfyTM0wiKuWXx64klRiQy 15ti/QKQ19Bn1Z15MRGY1zedS5EgtCSmTlbd2+I= X-Received: by 2002:a17:906:5a5b:b0:9a1:db2e:9dbf with SMTP id my27-20020a1709065a5b00b009a1db2e9dbfmr278843ejc.14.1693513826789; Thu, 31 Aug 2023 13:30:26 -0700 (PDT) Received: from m1x-phil.lan ([176.187.199.245]) by smtp.gmail.com with ESMTPSA id qq7-20020a17090720c700b00992afee724bsm1121684ejb.76.2023.08.31.13.30.25 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Thu, 31 Aug 2023 13:30:26 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Jiaxun Yang , Aurelien Jarno , Aleksandar Rikalo Subject: [PATCH v2 0/7] target/mips: Convert Loongson LEXT opcodes to decodetree Date: Thu, 31 Aug 2023 22:30:16 +0200 Message-ID: <20230831203024.87300-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::62f; envelope-from=philmd@linaro.org; helo=mail-ej1-x62f.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 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 Respin of old series... Since v1 [*]: - Fixed '!is_double' check (rth) - Rebased (removing tcg_temp_free calls) - Simplified MULT[U].G (rth) - Added R-b Cover from v1: Loongson is next step in the "MIPS decodetree conversion" epic. Start with the simplest extension. The diffstat addition comes from the TCG functions expanded. The code is easier to review now. IMO this is also a good template to show how easy a decodetree conversion can be (and how nice the .decode file is to review) :P Please review, Phil. Based-on: <20230831201140.85799-1-philmd@linaro.org> "target/mips: Simplify Loongson MULTU.G opcode" [*] https://lore.kernel.org/qemu-devel/20210112215504.2093955-1-f4bug@amsat.org/ Philippe Mathieu-Daudé (7): target/mips: Simplify Loongson MULTU.G opcode target/mips: Re-introduce OPC_ADDUH_QB_DSP and OPC_MUL_PH_DSP target/mips: Convert Loongson DDIV.G opcodes to decodetree target/mips: Convert Loongson DIV.G opcodes to decodetree target/mips: Convert Loongson [D]DIVU.G opcodes to decodetree target/mips: Convert Loongson [D]MOD[U].G opcodes to decodetree target/mips: Convert Loongson [D]MULT[U].G opcodes to decodetree target/mips/tcg/translate.h | 1 + target/mips/tcg/godson2.decode | 27 +++ target/mips/tcg/loong-ext.decode | 28 +++ target/mips/tcg/loong_translate.c | 307 ++++++++++++++++++++++++++++++ target/mips/tcg/translate.c | 264 +------------------------ target/mips/tcg/meson.build | 3 + 6 files changed, 376 insertions(+), 254 deletions(-) create mode 100644 target/mips/tcg/godson2.decode create mode 100644 target/mips/tcg/loong-ext.decode create mode 100644 target/mips/tcg/loong_translate.c