From patchwork Thu Oct 25 17:28:44 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Fredrik Noring X-Patchwork-Id: 10656331 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 8F9B313BF for ; Thu, 25 Oct 2018 18:01:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 843742C34C for ; Thu, 25 Oct 2018 18:01:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 780B02C33F; Thu, 25 Oct 2018 18:01:42 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id F226B2C34F for ; Thu, 25 Oct 2018 18:01:41 +0000 (UTC) Received: from localhost ([::1]:56239 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gFjwz-0004gC-8y for patchwork-qemu-devel@patchwork.kernel.org; Thu, 25 Oct 2018 14:01:41 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:43053) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gFjRD-0004rk-VC for qemu-devel@nongnu.org; Thu, 25 Oct 2018 13:28:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gFjRA-0005DP-S2 for qemu-devel@nongnu.org; Thu, 25 Oct 2018 13:28:51 -0400 Received: from pio-pvt-msa1.bahnhof.se ([79.136.2.40]:35942) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gFjRA-00056q-Em for qemu-devel@nongnu.org; Thu, 25 Oct 2018 13:28:48 -0400 Received: from localhost (localhost [127.0.0.1]) by pio-pvt-msa1.bahnhof.se (Postfix) with ESMTP id 5C43F3F499; Thu, 25 Oct 2018 19:28:46 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at bahnhof.se Received: from pio-pvt-msa1.bahnhof.se ([127.0.0.1]) by localhost (pio-pvt-msa1.bahnhof.se [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id U4E9PJi5KKCj; Thu, 25 Oct 2018 19:28:45 +0200 (CEST) Received: from localhost (h-41-252.A163.priv.bahnhof.se [46.59.41.252]) (Authenticated sender: mb547485) by pio-pvt-msa1.bahnhof.se (Postfix) with ESMTPA id 256AA3F421; Thu, 25 Oct 2018 19:28:45 +0200 (CEST) Date: Thu, 25 Oct 2018 19:28:44 +0200 From: Fredrik Noring To: Aleksandar Markovic , Aurelien Jarno , Philippe =?utf-8?q?Mathieu-Daud?= =?utf-8?q?=C3=A9?= Message-ID: MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 79.136.2.40 Subject: [Qemu-devel] [PATCH 00/11] target/mips: Amend R5900 support X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?utf-8?q?J=C3=BCrgen?= Urban , qemu-devel@nongnu.org, "Maciej W. Rozycki" Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP This series amends the R5900 support with the following noncritical features: - The vendor-specific Application-Specific Extension (ASE) ASE_MMI is renamed to ASE_TOSHIBA_MMI, because several vendors have multimedia instruction (MMI) sets and other extensions of various kinds. ASE vendor namespaces make it clear these are not generic architectural features and also avoid name clashes. - The R5900 LQ and SQ instructions are now also covered by the Toshiba MMI ASE, as per the TX79 manual[1]. - The three-operand MADD and MADDU instructions specific to the R5900 and the Toshiba TX19, TX39 and TX79 cores are now supported and tested by the R5900 TCG test suite. - The three-operand MADD1 and MADDU1 pipeline 1 instructions specific to the R5900 and the Toshiba TX79 core are now supported and tested by the R5900 TCG test suite. - The membership field of struct mips_opcode is now uint64_t instead of unsigned long, that is too small in 32-bit builds. - R5900 disassembly constants are defined. - The R5900 instructions DIV1, DIVU1, MFLO, MTLO, MFHI, MTHI, MULT1 and MULTU1 are now disassembled. Unfortunately, the opcodes for MADD1 and MADDU1 clash with the opcodes for CLZ and CLO, resulting in incorrect disassembly. MADD1 and MADDU1 are therefore left undefined. This series has been successfully built with the 16 different build configurations {gcc,clang} x -m{32,64} x mips{,64}el-{linux-user,softmmu} in addition to successfully completing the R5900 test suite cd tests/tcg/mips/mipsr5900 && make check Reference: [1] "Toshiba TX System RISC TX79 Core Architecture", Toshiba Corporation, section B.3.2, p. B-4, . Fredrik Noring (9): target/mips: Rename ASE_MMI to ASE_TOSHIBA_MMI, with Toshiba namespace target/mips: R5900 LQ and SQ also belong to the Toshiba MMI ASE target/mips: Support R5900 three-operand MADD1 and MADDU1 tests/tcg/mips: Test R5900 three-operand MADD tests/tcg/mips: Test R5900 three-operand MADD1 tests/tcg/mips: Test R5900 three-operand MADDU tests/tcg/mips: Test R5900 three-operand MADDU1 disas/mips: Define R5900 disassembly constants disas/mips: Disassemble R5900 DIV[U]1, M{F,T}{LO,HI}1 and MULT[U]1 Philippe Mathieu-Daudé (2): target/mips: Support Toshiba specific three-operand MADD and MADDU disas/mips: Increase 'member of ISAs' flag holder size disas/mips.c | 22 ++++++++- target/mips/mips-defs.h | 2 +- target/mips/translate.c | 77 ++++++++++++++++++++++++++---- target/mips/translate_init.inc.c | 2 +- tests/tcg/mips/mipsr5900/Makefile | 2 + tests/tcg/mips/mipsr5900/madd.c | 78 +++++++++++++++++++++++++++++++ tests/tcg/mips/mipsr5900/maddu.c | 70 +++++++++++++++++++++++++++ 7 files changed, 240 insertions(+), 13 deletions(-) create mode 100644 tests/tcg/mips/mipsr5900/madd.c create mode 100644 tests/tcg/mips/mipsr5900/maddu.c