From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 48343 invoked by alias); 15 Dec 2017 13:20:39 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 48328 invoked by uid 89); 15 Dec 2017 13:20:39 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=promise X-HELO: mail-wm0-f44.google.com Received: from mail-wm0-f44.google.com (HELO mail-wm0-f44.google.com) (74.125.82.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 15 Dec 2017 13:20:38 +0000 Received: by mail-wm0-f44.google.com with SMTP id f206so17471664wmf.5 for ; Fri, 15 Dec 2017 05:20:37 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=CKd+75yBIaXQtbbai5GlVi6ED+Hikd6g9TL41iN49IQ=; b=hYCq9E3gLaziFM4gE4rMD0CtkpyqaSQYIUET0sEgy7ZO4b6+qfEnqSD6QCKO+HAr5J Enwf+0JI+GLbwHFxbHfaG+UyoY5naSPAJcvpeHOZbXW59H/aAy5jcr89BXRiqv70h24L yqMXkLqF4aCStI1od3Yq+NjxpGBrK9Y7yCmeSfr+G9QAXJYi0zrSHHiQektn2lBzTVfc eYIOxDWIcsjzg9k75uaIys9K/fNhsgU9EGsxD8wGIbJVVJ6KU6d/IUMQ7Qnt6FyRZna6 p0TFJByzsiPNQr/PhD2+Vr8Mnl7qzJ0jIskzAiA9vGoeQ1xYTgPeD5BjCPY5GbMLTir6 5A1g== X-Gm-Message-State: AKGB3mLUqDP5o+NppTm/Go9gAEpw5yAxNagyWRcHawKdtJ6rsaHCy2jw r0MpdIxxMFoUoYnTj83dgKz7jhHQZ+xJaD8/Mtw= X-Google-Smtp-Source: ACJfBot84SpzL9mA04LRj6Qcd6l/fQtZ/GaS1MjaAq4ZQsk1L5NKQDp+9TU7YrQ5lJuLvjOVpuAVk3GBNMKaff4hi+U= X-Received: by 10.80.208.195 with SMTP id g3mr7210121edf.246.1513344036135; Fri, 15 Dec 2017 05:20:36 -0800 (PST) MIME-Version: 1.0 Received: by 10.80.167.196 with HTTP; Fri, 15 Dec 2017 05:20:35 -0800 (PST) In-Reply-To: <87vah8nofj.fsf@linaro.org> References: <87wp3mxgir.fsf@linaro.org> <87bmkyxg9d.fsf@linaro.org> <87o9n0q1ey.fsf@linaro.org> <87vah8nofj.fsf@linaro.org> From: Richard Biener Date: Fri, 15 Dec 2017 13:20:00 -0000 Message-ID: Subject: Re: [05/nn] Add VEC_DUPLICATE_{CST,EXPR} and associated optab To: Richard Biener , GCC Patches , Richard Sandiford Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2017-12/txt/msg01043.txt.bz2 On Fri, Dec 15, 2017 at 1:52 PM, Richard Sandiford wrote: > Richard Biener writes: >> On Fri, Dec 15, 2017 at 1:29 AM, Richard Sandiford >> wrote: >>> This patch just adds VEC_DUPLICATE_EXPR, since the VEC_DUPLICATE_CST >>> isn't needed with the new VECTOR_CST layout. It's really just the >>> original patch with bits removed, but just in case: >>> >>> Tested on aarch64-linux-gnu, x86_64-linux-gnu and powerpc64-linux-gnu. >>> OK to install? >> >> To keep things simple at this point OK. Note that I'd eventually >> like to see this as VEC_PERM_EXPR . >> For reductions when we need { x, 0, ... } we now have to use a >> VEC_DUPLICATE_EXPR to make x a vector and then a VEC_PERM_EXPR >> to merge it with {0, ... }, right? Rather than VEC_PERM_EXPR > { 0, 1, 1, 1.... }> > > That's where the shift-left-and-insert-scalar thing (IFN_SHL_INSERT) > comes in. But yeah, allowing scalars as operands to VEC_PERM_EXPRs > would mean it could represent both VEC_DUPLICATE_EXPR and IFN_SHL_INSERT. > I guess the question is whether that's better than extending CONSTRUCTOR > (or a replacement) to use the VECTOR_CST encoding. I realise you don't > like CONSTRUCTOR in gimple though... > > I promise to look at either of those for GCC 9 if you think they're > better, but they'll be more invasive for other targets. Thanks. Richard. > Thanks, > Richard