Message ID | 20230309075710.2236986-1-collison@rivosinc.com |
---|---|
State | Accepted |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp157321wrd; Wed, 8 Mar 2023 23:57:42 -0800 (PST) X-Google-Smtp-Source: AK7set/SJjurWrx+oP8B3iARV+PLiHDJucm6huNkB/xongUa3BP/YtGeucM00Ay9cWwas7r+bumM X-Received: by 2002:a17:907:6d08:b0:8ed:5af8:d4ba with SMTP id sa8-20020a1709076d0800b008ed5af8d4bamr22104487ejc.38.1678348662039; Wed, 08 Mar 2023 23:57:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1678348662; cv=none; d=google.com; s=arc-20160816; b=CqSGUOLgXSr8IQOHameEt31AlIGCRmzitehmBzM+zgyDBWrk2H5kkAbdVVZER2MCxK kVYDAzy5FTZG2NilJpnrJKcM/qCmmzlbFGh054jDeVzzoDVVBbl4Zy0V4pUxj8klCkge x1+cj92iM7QQhxtk7VmtZzuhNOmWiMUymsnQEJ+cplDMxnLAkizFVFKiKr0Q8VliN9J4 tansUFbtO5tGl49v9RGxwFC2R991L5GUkCp9KUaxTpbxI7ZfQ0J5qvUbGjsm/eumTzEf gMhe43XXqXdSPTZzavL562IK/s7qqSPiPMMYHeJrtOfCDJ7HNam2/6ZySZiiBXRmAoJ9 l/gQ== 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:to:from:dkim-signature :dmarc-filter:delivered-to; bh=+5hWU4/8tn1U8pDEvKdWZoTWuVyuHDl60N8RSd74Dso=; b=RDgZ4kIXm4QlbeDb6rQguHQAhJ3OvoMD/86Qjxyn3hvMT4+iZW3biTeAIfWMZmRYvR EMbOVs1FWxV6QX7CXvmo2HbnFKS6TqnambqTRfK+MaEtC9F2A8rcx9y9vpjOVgMALR8B prUi6ddesIaxmev6JxnDYfhTdCPUyVif4QbMHmWpBLSXc1x1qQM4V7fVpIEagnvL8hox 5elH4tz1zHt/cC7nHkIYDE1TS+VWpei2SC7n451yrXQIn5woeNC6WuV2S2o2LdiBmVM9 04TwBAUHEtui7zig8LlUZeRJ4lY3BZlfk7JvkEa1PBXRTQxiOTbIh0mEY2BOwfGwhvwW PlEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b="M/wE9wLk"; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id f22-20020a1709067f9600b008d10fe78243si12369692ejr.878.2023.03.08.23.57.41 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 Mar 2023 23:57:42 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b="M/wE9wLk"; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org" Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 16F7E385842B for <ouuuleilei@gmail.com>; Thu, 9 Mar 2023 07:57:38 +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 60F253858D37 for <gcc-patches@gcc.gnu.org>; Thu, 9 Mar 2023 07:57:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 60F253858D37 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 c3so1110777qtc.8 for <gcc-patches@gcc.gnu.org>; Wed, 08 Mar 2023 23:57:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; t=1678348631; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:from:to:cc:subject:date:message-id:reply-to; bh=+5hWU4/8tn1U8pDEvKdWZoTWuVyuHDl60N8RSd74Dso=; b=M/wE9wLkdpfzVA+5+wqHAKWlHDNigrAQJahOuYFyDP391CUjjW9PlMGujZKM/s+IqM ssvluKhhvj06tHbnWm5/rkxUgXqhlUzorFcXJBFG2rJq6NtozLnh+D/djUmx+BDAs0yA 0tCVZeFZH+J0p3lMlfxxczefti5pyFl+20ORRwitCTfIEdsl0Ppvxz8rMn73K+0QcruQ Y/gZgovCZtcsgypKgZ1W040gYbqTKM+hddxs2gKvnN74lHrW8JGYq/snsyDTZ966qt0X ULIv7CpuUlYAfHudPBJWKTs+byOcPYb0bcGLSXb8WaKbVXlqkUuqYnaIjR+XAnm7mpgc Bosw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678348631; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=+5hWU4/8tn1U8pDEvKdWZoTWuVyuHDl60N8RSd74Dso=; b=FNff8H+q+m1TutmMziWAFbCpf0iDOgch8r7qKN9UkQiss2HThFs3ygt/8+poK6c6JQ IkFTynDNTdimnxRsSiaa0+0dCLeYdA26gxxxJExfHIzc+YM9JouYVqxCz3tNXKk4m1lp fDIZJICRgnGBeQO1zdfIkClrvKn+T9BOgbCY06yc1GvCLyX7omXjl9afoVUihckLA2Rg y8Kt4G1unPuzqmcG97Sj50rlCmyGblDqhuu89lKCkS5p/JnEl6gEuQkEEswujiMR8iZy 8Xa9qLcuD6I8H/2YoRvxHwApurHlOSG66gK4xJcIpJXVWOAl6/jvV4/8VPhrSOYnzXdE rNXw== X-Gm-Message-State: AO0yUKUfpnD0f3CSM/uFJa6m9n18RqsLzRMhSOJnM3HCVUYPCH43tn8P iQB7JnmvQJchb33KZnPbbyBuWRI5ZXOl6hUpybA= X-Received: by 2002:ac8:5c02:0:b0:3bf:dc2e:ce5d with SMTP id i2-20020ac85c02000000b003bfdc2ece5dmr40136052qti.4.1678348631581; Wed, 08 Mar 2023 23:57:11 -0800 (PST) Received: from system76-pc.ba.rivosinc.com ([136.57.172.92]) by smtp.gmail.com with ESMTPSA id 136-20020a37088e000000b00742a252ba06sm12952067qki.135.2023.03.08.23.57.11 for <gcc-patches@gcc.gnu.org> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 08 Mar 2023 23:57:11 -0800 (PST) From: Michael Collison <collison@rivosinc.com> To: gcc-patches@gcc.gnu.org Subject: [PATCH v2] vect: Check that vector factor is a compile-time constant Date: Thu, 9 Mar 2023 02:57:10 -0500 Message-Id: <20230309075710.2236986-1-collison@rivosinc.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-12.6 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, 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 <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1759876126859367635?= X-GMAIL-MSGID: =?utf-8?q?1759876126859367635?= |
Series |
[v2] vect: Check that vector factor is a compile-time constant
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | success | Github commit url |
Commit Message
Michael Collison
March 9, 2023, 7:57 a.m. UTC
2023-03-05 Michael Collison <collison@rivosinc.com> * tree-vect-loop-manip.cc (vect_do_peeling): Use result of constant_lower_bound instead of vf in case vf is not a compile time constant. --- gcc/tree-vect-loop-manip.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Comments
On Thu, Mar 9, 2023 at 8:57 AM Michael Collison <collison@rivosinc.com> wrote: OK. Thanks, Richard. > 2023-03-05 Michael Collison <collison@rivosinc.com> > > * tree-vect-loop-manip.cc (vect_do_peeling): Use > result of constant_lower_bound instead of vf in case > vf is not a compile time constant. > --- > gcc/tree-vect-loop-manip.cc | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/gcc/tree-vect-loop-manip.cc b/gcc/tree-vect-loop-manip.cc > index d88edafa018..f60fa50e8f4 100644 > --- a/gcc/tree-vect-loop-manip.cc > +++ b/gcc/tree-vect-loop-manip.cc > @@ -2921,7 +2921,7 @@ vect_do_peeling (loop_vec_info loop_vinfo, tree niters, tree nitersm1, > if (new_var_p) > { > value_range vr (type, > - wi::to_wide (build_int_cst (type, vf)), > + wi::to_wide (build_int_cst (type, lowest_vf)), > wi::to_wide (TYPE_MAX_VALUE (type))); > set_range_info (niters, vr); > } > -- > 2.34.1 >
diff --git a/gcc/tree-vect-loop-manip.cc b/gcc/tree-vect-loop-manip.cc index d88edafa018..f60fa50e8f4 100644 --- a/gcc/tree-vect-loop-manip.cc +++ b/gcc/tree-vect-loop-manip.cc @@ -2921,7 +2921,7 @@ vect_do_peeling (loop_vec_info loop_vinfo, tree niters, tree nitersm1, if (new_var_p) { value_range vr (type, - wi::to_wide (build_int_cst (type, vf)), + wi::to_wide (build_int_cst (type, lowest_vf)), wi::to_wide (TYPE_MAX_VALUE (type))); set_range_info (niters, vr); }