From patchwork Tue Jan 16 03:33:38 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 124578 Delivered-To: patch@linaro.org Received: by 10.46.64.148 with SMTP id r20csp875270lje; Mon, 15 Jan 2018 19:34:36 -0800 (PST) X-Google-Smtp-Source: ACJfBos0nv0Ius/oAWNV4/tgV3UBU/CLwrv3PKSTWRvZ0VHqQx1g0F5LfshnrpNYr/F1wPEDQUn+ X-Received: by 10.129.154.146 with SMTP id r140mr5411799ywg.442.1516073676311; Mon, 15 Jan 2018 19:34:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516073676; cv=none; d=google.com; s=arc-20160816; b=f8k5FoU+FIQFFL+N7cdiuQRPyociRIl80vKn+mfaE99ZE9UaVNgC3Cq4otphgTnUFF SNflF02SgJns569Yx8znmH2HFAUcx2MxviFXMTB2t2Uf+55EcSlBoZoeZxDLs6bj2fJC djOSuItupgi5DiweTDm+ha5qR4jFt5/F0NK2pc/pozeHrpobr1HJkxEdP4M5PYi089jG NAR7GzBs2pXN5XZVUOIQOJxxf6pDGMMYYt+AHsGJDINf7XurCTzXKur7fuv3JbuKM1Vq PrB2lyVK5dKmqPMYCm2kAf5D0eRAo8/SYQ2mLFMAy6PViFyRFxxt346XWCgCXFkoa23a /AOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject :content-transfer-encoding:mime-version:message-id:date:to:from :dkim-signature:arc-authentication-results; bh=1iJtWYrdVrkxCaec8/vazqUVM+vPRenhcNbt8dIkDLM=; b=J9OeHdthG8ulumKBvaRaIjH6CxvIl/wmGyymk92jX2a8UV7MuI0AFTqD51DjxsiZzG egfa18v4oGuOdJoq3ZU0QK/oRJscnWRSERbtxDDBlprzDgCDsyFEbBd6nutEKd6sHZCx tmXpSW8iI690ouRQPmu5YAs0o5gnId56lqt5tZlRg9R7agBA4IxDmQ6b5NXbwaVhd9qW 7HVv/3gBYshESQ4ldkE6vz5hGC/DxigkTrLhBrRit5nK3PUeVixkY8vNpVuZXNHU9PYI +GkqxtLYU7LQdvb5wovS+D2F0/lfCj+v17X+22tiEpc7cII9eNZAcPgwFnYGxtGXB/kP +uyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=hzkm5odB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom=qemu-devel-bounces+patch=linaro.org@nongnu.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id a75si274480ywh.437.2018.01.15.19.34.36 for (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 15 Jan 2018 19:34:36 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=hzkm5odB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) smtp.mailfrom=qemu-devel-bounces+patch=linaro.org@nongnu.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1]:59081 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ebI1D-0004le-Ma for patch@linaro.org; Mon, 15 Jan 2018 22:34:35 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59502) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ebI0r-0004l0-NX for qemu-devel@nongnu.org; Mon, 15 Jan 2018 22:34:14 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ebI0o-000386-K6 for qemu-devel@nongnu.org; Mon, 15 Jan 2018 22:34:13 -0500 Received: from mail-pf0-x22d.google.com ([2607:f8b0:400e:c00::22d]:45420) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ebI0o-00037r-DJ for qemu-devel@nongnu.org; Mon, 15 Jan 2018 22:34:10 -0500 Received: by mail-pf0-x22d.google.com with SMTP id a88so7487056pfe.12 for ; Mon, 15 Jan 2018 19:34:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=1iJtWYrdVrkxCaec8/vazqUVM+vPRenhcNbt8dIkDLM=; b=hzkm5odBS4x0FnzLCKJESTnAnwbldXjmEBZT8EGSE7PdR2TQJ/92Cqhk/c+LLbDLgE qfHnUpe9KiaXq0wVI+4hxzEojLG7WvmrsAeH3tdkDSPHOVfE7QVaYEPjaDz4HzbxMCaS LCq9brGhKjGvpB5QHhUVIdww8bHFOibA2sTGY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=1iJtWYrdVrkxCaec8/vazqUVM+vPRenhcNbt8dIkDLM=; b=Vk/iO8wUB9tB2ZDe81V+kjzn7IiaQOMeB7LFUEYKkufcJgdKjmlT4uf8Zpi/EhEn86 ivNa1a16v75T1XfGl8/9moLyVV5Nx5WeQuMzlWs1xX6/5YpEilFrLBr7ZaqpASJPNzxR WSfTM5OhBLFqMPpWEo/GZOPUG0xTtdFcZI2ajb095tmCY1fXLptG5J3KOT5qxETy9dbz 7pFi13Bym1KfNzylRcxQa7NOR9dBp9yGfg8nLOZSOTOvMHrn9h6EyOki4A93edfntLtK cYW67rgJ0Y0qrKMdD/xdGbxR8v+mhdCfGSDlz106OLqFC503VU4E000kxE3Lj2S7s8ja 3ivQ== X-Gm-Message-State: AKGB3mIWRlcFUjqq9/o8xq9Fimq9bT30+sMfGRLafLWnt2RjH5QNM3Ya b8AieEc175oPjmVB/YvfKebEykibQ3g= X-Received: by 10.99.65.70 with SMTP id o67mr29528882pga.125.1516073648909; Mon, 15 Jan 2018 19:34:08 -0800 (PST) Received: from cloudburst.twiddle.net.com (24-181-135-57.dhcp.knwc.wa.charter.com. [24.181.135.57]) by smtp.gmail.com with ESMTPSA id c83sm1281024pfk.8.2018.01.15.19.34.06 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 15 Jan 2018 19:34:07 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Date: Mon, 15 Jan 2018 19:33:38 -0800 Message-Id: <20180116033404.31532-1-richard.henderson@linaro.org> X-Mailer: git-send-email 2.14.3 MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:400e:c00::22d Subject: [Qemu-devel] [PATCH v9 00/26] tcg: generic vector operations 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: peter.maydell@linaro.org Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: "Qemu-devel" I think this will be the last revision before queueing for pull. Peter, the target/arm patches here are primarily for testing, without having to go all the way through to SVE. It also shows how the generic vector interface ought to be used. I'm happy to drop the patches from the tcg pull and feed them through target-arm.next, or keep them here as you wish. r~ Minor changes since v8: * Reduce some code duplication within the patches. * Add vector op scalar interface. Minor changes since v7: * Rearranged the patches into groups for readability. * Squished the tcg/i386 patches. * Fixed an encoding bug for vmovd xmm, reg (Kirill). * Fixed expansion bugs for i386 sar, trn. Minor changes since v6: * Two bugs fixed pointed out by Kirill. * Allow for 4 and 5 operand operations. Richard Henderson (26): tcg: Allow multiple word entries into the constant pool tcg: Add types and basic operations for host vectors tcg: Standardize integral arguments to expanders tcg: Add generic vector expanders tcg: Add generic vector ops for interleave tcg: Add generic vector ops for constant shifts tcg: Add generic vector ops for comparisons tcg: Add generic vector ops for multiplication tcg: Add generic vector ops for extension tcg: Add generic helpers for saturating arithmetic tcg: Loosen vec_gen_op* typecheck rules tcg: Add generic vector helpers with a scalar immediate operand tcg: Add generic vector helpers with a scalar variable operand tcg/optimize: Handle vector opcodes during optimize target/arm: Align vector registers target/arm: Use vector infrastructure for aa64 add/sub/logic target/arm: Use vector infrastructure for aa64 mov/not/neg target/arm: Use vector infrastructure for aa64 dup/movi target/arm: Use vector infrastructure for aa64 zip/uzp/trn/xtn target/arm: Use vector infrastructure for aa64 constant shifts target/arm: Use vector infrastructure for aa64 compares target/arm: Use vector infrastructure for aa64 multiplies target/arm: Use vector infrastructure for aa64 widening shifts target/arm: Use vector infrastructure for aa64 orr/bic immediate tcg/i386: Add vector operations tcg/aarch64: Add vector operations Makefile.target | 4 +- accel/tcg/tcg-runtime.h | 141 +++ target/arm/cpu.h | 2 +- tcg/aarch64/tcg-target.h | 30 +- tcg/aarch64/tcg-target.opc.h | 3 + tcg/i386/tcg-target.h | 46 +- tcg/i386/tcg-target.opc.h | 13 + tcg/tcg-gvec-desc.h | 49 + tcg/tcg-op-gvec.h | 319 +++++ tcg/tcg-op.h | 67 +- tcg/tcg-opc.h | 59 + tcg/tcg.h | 84 ++ accel/tcg/tcg-runtime-gvec.c | 1064 +++++++++++++++++ target/arm/translate-a64.c | 1106 ++++++++++++------ tcg/aarch64/tcg-target.inc.c | 674 ++++++++++- tcg/i386/tcg-target.inc.c | 1331 ++++++++++++++++++++- tcg/optimize.c | 150 +-- tcg/tcg-op-gvec.c | 2653 ++++++++++++++++++++++++++++++++++++++++++ tcg/tcg-op-vec.c | 566 +++++++++ tcg/tcg-op.c | 42 +- tcg/tcg-pool.inc.c | 115 +- tcg/tcg.c | 144 ++- accel/tcg/Makefile.objs | 2 +- tcg/README | 148 +++ 24 files changed, 8244 insertions(+), 568 deletions(-) create mode 100644 tcg/aarch64/tcg-target.opc.h create mode 100644 tcg/i386/tcg-target.opc.h create mode 100644 tcg/tcg-gvec-desc.h create mode 100644 tcg/tcg-op-gvec.h create mode 100644 accel/tcg/tcg-runtime-gvec.c create mode 100644 tcg/tcg-op-gvec.c create mode 100644 tcg/tcg-op-vec.c -- 2.14.3