From patchwork Wed May 15 06:24:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Cui, Lili" X-Patchwork-Id: 1935269 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.a=rsa-sha256 header.s=Intel header.b=It/83dAE; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=2620:52:3:1:0:246e:9693:128c; helo=server2.sourceware.org; envelope-from=gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [IPv6:2620:52:3:1:0:246e:9693:128c]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4VfNVc1N8nz1ydW for ; Wed, 15 May 2024 16:24:40 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 41EB93849AEE for ; Wed, 15 May 2024 06:24:38 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.8]) by sourceware.org (Postfix) with ESMTPS id 01A363858D35 for ; Wed, 15 May 2024 06:24:16 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 01A363858D35 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=intel.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=intel.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 01A363858D35 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=192.198.163.8 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1715754258; cv=none; b=U9fBtmWhQkYuUJregmJovAmhMChHFUoa28x/9aGf9jE6t49zm6lMDnHMonHifT1Ijw9NevF/Ppi0ckT8adg+22lMRMBkMa6luj1RHbus9E96i6dIfKNnQxAeqC7ApJe6c3373GcCbc3Tx2/1CxwG9WqZbb0vaDVKjS2JX/dmWro= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1715754258; c=relaxed/simple; bh=lfQ2cjB8oDAlHs8BVTM+xlGM0YpRp2yE85AtX08qyY8=; h=DKIM-Signature:From:To:Subject:Date:Message-Id:MIME-Version; b=lcDO8+1Oc+1+JDiEzQAKkiJidiAadTdiZGyB3SVc846sTEkEPweHIfh5s0vpTR+PR/AuYVDk/J+PEYsWCLwIz49/lCVALQMNIrfBmAGVqCnZc0KLjH3Nxg2HjHVobR47eObpgRDsdhQJpNzM2alock967dQ9j898Ku9uzl3jpPQ= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1715754257; x=1747290257; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=lfQ2cjB8oDAlHs8BVTM+xlGM0YpRp2yE85AtX08qyY8=; b=It/83dAEzbx++OlZc8W/eRGK5602HBxzxwa8c3M2+HZtqEy2WAh3kfFU YC8+I7T9KdAHDinKty+OKPwREe/dVvIv2QQum+aPrBb6SklRsulrVnxgo r/nRsY1kWFcz60kNURAhV8ryx0HTWkf8N1BAeuL+8wRWsGYar3HoiXY1r yErz+1nzdNSq2ZkVvIgH7nlvI+EY9ho5er8xMwonZJhS1hYKmk/M9HTWh 5jkdNBpcmpmnVBI1KLuXSozY29XutTbjiCYJxA80Pct0HHQWw7D76YFfK 8NAcvD4iikSIag7e+dMAGcqskBjv7nnKzzhAV69lOTNJyQHsxDGwVZNed g==; X-CSE-ConnectionGUID: RiOY1fYaSlG5gbaflzVCBg== X-CSE-MsgGUID: H5SkMxJVT4qgWnypG3stmA== X-IronPort-AV: E=McAfee;i="6600,9927,11073"; a="29302477" X-IronPort-AV: E=Sophos;i="6.08,161,1712646000"; d="scan'208";a="29302477" Received: from fmviesa001.fm.intel.com ([10.60.135.141]) by fmvoesa102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 May 2024 23:24:16 -0700 X-CSE-ConnectionGUID: +IU26wEJQ+GD6Ga8TTlI8w== X-CSE-MsgGUID: L17ZksxOSFuLgBqcaRSVBg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,161,1712646000"; d="scan'208";a="62117531" Received: from scymds04.sc.intel.com ([10.82.73.238]) by fmviesa001.fm.intel.com with ESMTP; 14 May 2024 23:24:16 -0700 Received: from shgcc10.sh.intel.com (unknown [10.239.85.189]) by scymds04.sc.intel.com (Postfix) with ESMTP id 2FA512003A88; Tue, 14 May 2024 23:24:15 -0700 (PDT) From: "Cui, Lili" To: gcc-patches@gcc.gnu.org Cc: hongtao.liu@intel.com, ubizjak@gmail.com Subject: [PATCH 0/2] Support APX zero-upper Date: Wed, 15 May 2024 14:24:12 +0800 Message-Id: <20240515062414.3960582-1-lili.cui@intel.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+incoming=patchwork.ozlabs.org@gcc.gnu.org A bug was found when adding operand %ah to an invalid test case, so patch 1/2 was added to fix it. And made the following changes to the old patch. 1. Removed two redundant judgment codes in zu. 2. Added various types of register sizes in invalid test cases (found a bug about AH/BH/CH/DH). 3. Removed IMUL_Fixup and added a macros 'ZU' for imul and setcc. 4. Added VexWIG to EVEX format setzu/set to remove an ugly judgement. 5. Added more test cases for imulzu and setzu. *** BLURB HERE *** Cui, Lili (2): Add check for 8-bit old registers in EVEX format Support APX zero-upper gas/config/tc-i386.c | 17 ++- gas/testsuite/gas/i386/x86-64-apx-inval.l | 3 + gas/testsuite/gas/i386/x86-64-apx-inval.s | 2 + gas/testsuite/gas/i386/x86-64-apx-zu-intel.d | 78 +++++++++++++ gas/testsuite/gas/i386/x86-64-apx-zu-inval.l | 25 +++++ gas/testsuite/gas/i386/x86-64-apx-zu-inval.s | 28 +++++ gas/testsuite/gas/i386/x86-64-apx-zu.d | 78 +++++++++++++ gas/testsuite/gas/i386/x86-64-apx-zu.s | 73 ++++++++++++ gas/testsuite/gas/i386/x86-64.exp | 3 + opcodes/i386-dis-evex-prefix.h | 112 +++++++++++++++++++ opcodes/i386-dis-evex.h | 36 +++--- opcodes/i386-dis.c | 35 ++++++ opcodes/i386-gen.c | 1 + opcodes/i386-opc.h | 4 + opcodes/i386-opc.tbl | 6 + 15 files changed, 481 insertions(+), 20 deletions(-) create mode 100644 gas/testsuite/gas/i386/x86-64-apx-zu-intel.d create mode 100644 gas/testsuite/gas/i386/x86-64-apx-zu-inval.l create mode 100644 gas/testsuite/gas/i386/x86-64-apx-zu-inval.s create mode 100644 gas/testsuite/gas/i386/x86-64-apx-zu.d create mode 100644 gas/testsuite/gas/i386/x86-64-apx-zu.s