From patchwork Mon Mar 6 03:13:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Collison X-Patchwork-Id: 55556 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 96DB8385B52F for ; Mon, 6 Mar 2023 03:13:36 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-qt1-x82b.google.com (mail-qt1-x82b.google.com [IPv6:2607:f8b0:4864:20::82b]) by sourceware.org (Postfix) with ESMTPS id 101E43858D28 for ; Mon, 6 Mar 2023 03:13:18 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 101E43858D28 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=rivosinc.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=rivosinc.com Received: by mail-qt1-x82b.google.com with SMTP id cf14so9201226qtb.10 for ; Sun, 05 Mar 2023 19:13:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:content-language:to:subject:from :user-agent:mime-version:date:message-id:from:to:cc:subject:date :message-id:reply-to; bh=Z3MCZeaFdeyOXVjulIHl+7xHCNUmVMXtwhjOIVYZzYM=; b=3R42MRdezyh2JeM83J8Juzje0qZdrcz5u8KDGknvAWukayriwyjja1Y1Tx8r7MjlvL wmm53tE40FKQiCzEMhlGRFQRybmQPQ5RhVVKrv+0PlFnrY2XDiCjP0WWvsGudqa/PcIa v6xcCpe4EXWEA1S59s6wqkWiBS6AKDfvBkgVMMFC6J1UqeesmsUbf8/Wzsveeg5sFFyp uBVMgyLLY3fTFJssc/6ouBxq+zUgcPbwYY1rgV9hdyCHe1VuHE/S1ezxcwlK1fwEvDCQ 74KlqJygKrMHDkquQVKSx6gHxhx5W8tkGXXxDk0b33kEdQ8h2iBQ55GcwCGYBAH2lUgw Q8YA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:content-language:to:subject:from :user-agent:mime-version:date:message-id:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=Z3MCZeaFdeyOXVjulIHl+7xHCNUmVMXtwhjOIVYZzYM=; b=RVUxxO1+CY6aZGfblQpFK8T0p88o+BJu8JOxvdZjNlgH7fYC6BCf0jB2teCDSb04we fZbIKwxfoscgF0hABCg2jIz6r2esIq7BmxRzkrIJ4unbKyTN9Bn5JDIzi2qpNM9o60o3 cZ8C2TIARIQZzVDhoCKoRGy2gjqC1mSiEbVuCO3iQJlJQdwviCxzUzNrEovdgzu3lb0E Ro2R9sK64fCfCECb5Hz9YN6xMeFtnNgJDiMaXYeizKBEKq3mbAMvlZyhm1YLA68Qzz5y EIkdrNeuSrqbcAW9H00ZzkCzIg35+5Xqw+WbVIrVoTXjWxqB0BV+CKBw3673p7AFbSHm kdvA== X-Gm-Message-State: AO0yUKVqfHk1AcRkRf3vIkMNe2gOWDrv4oaO+XhdtweGjXWfBYy8Rm2J DXsqv80Bz7cHMQi/KS9/+2v5NIlac0TvYcce+DU= X-Google-Smtp-Source: AK7set8T7+yfuevkU0GU5wBUX8Mf9NUjgjkhl8Mnr1rKUQWU5O4sXutWF/QsZtv3SOchacAXM5NZZQ== X-Received: by 2002:ac8:7e8b:0:b0:3bf:cfe0:1f2c with SMTP id w11-20020ac87e8b000000b003bfcfe01f2cmr14675677qtj.35.1678072396903; Sun, 05 Mar 2023 19:13:16 -0800 (PST) Received: from [192.168.86.117] ([136.57.172.92]) by smtp.gmail.com with ESMTPSA id e15-20020ac85dcf000000b003bfad864e81sm6825359qtx.69.2023.03.05.19.13.16 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 05 Mar 2023 19:13:16 -0800 (PST) Message-ID: <6ffdeeb4-8523-03f7-eb30-ee3e5886afad@rivosinc.com> Date: Sun, 5 Mar 2023 22:13:16 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.7.1 From: Michael Collison Subject: [PATCH v2 00/07] RISC-V: autovec: Add auto-vectorization support To: gcc-patches Content-Language: en-US X-Spam-Status: No, score=-6.3 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, 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.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" This series of patches adds foundational support for RISC-V autovectorization support. These patches are based on the current upstream rvv vector intrinsic support and is not a new implementation. Most of the implementation consists of adding the new vector cost model, the autovectorization patterns themselves and target hooks.This implementation only provides support for integer addition and subtraction as a proof of concept. This patch set should not be construed to be feature complete. Based on conversations with the community these patches are intended to lay the groundwork for feature completion and collaboration within the RISC-V community.In version 1 of this patch submission I neglected to indicate that these patches are largely based off the work of Juzhe Zhong (juzhe.zhong@rivai.ai) of RiVAI. More specifically the rvv-next branch at:https://github.com/riscv-collab/riscv-gcc.git is the foundation of this patch set. I want to publicly apologize to Juzhe and RiVIA for not attributing their work visibly and publicly.As discussed on this list, if these patches are approved they will be merged into a "auto-vectorization" branch once gcc-13 branches for release.There are two known issues related to crashes (assert failures) associated with tree vectorization; one of which I have sent a patch for and have received feedback. Changes in v2 - Updated ChangeLog entry to include RiVAI contributions - Fixed ChangeLog email formatting - Fixed gnu formatting issues in the code