From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24865 invoked by alias); 27 Sep 2013 15:19:51 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 24856 invoked by uid 89); 27 Sep 2013 15:19:50 -0000 Received: from service87.mimecast.com (HELO service87.mimecast.com) (91.220.42.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 27 Sep 2013 15:19:50 +0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.1 required=5.0 tests=AWL,BAYES_50,RCVD_IN_DNSWL_LOW,RP_MATCHES_RCVD,SPAM_SUBJECT,SPF_PASS autolearn=no version=3.3.2 X-HELO: service87.mimecast.com Received: from cam-owa1.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.21]) by service87.mimecast.com; Fri, 27 Sep 2013 16:19:47 +0100 Received: from e103625-lin.cambridge.arm.com ([10.1.255.212]) by cam-owa1.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.0); Fri, 27 Sep 2013 16:19:45 +0100 Date: Fri, 27 Sep 2013 15:19:00 -0000 From: Vidya Praveen To: Richard Biener Cc: "gcc@gcc.gnu.org" , "ook@ucw.cz" Subject: Re: [RFC] Vectorization of indexed elements Message-ID: <20130927151945.GB861@e103625-lin.cambridge.arm.com> References: <20130909172533.GA25330@e103625-lin.cambridge.arm.com> <20130924150425.GE22907@e103625-lin.cambridge.arm.com> <20130927145008.GA861@e103625-lin.cambridge.arm.com> MIME-Version: 1.0 In-Reply-To: <20130927145008.GA861@e103625-lin.cambridge.arm.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-MC-Unique: 113092716194701601 Content-Type: text/plain; charset=WINDOWS-1252 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-IsSubscribed: yes X-SW-Source: 2013-09/txt/msg00239.txt.bz2 On Fri, Sep 27, 2013 at 03:50:08PM +0100, Vidya Praveen wrote: [...] > > > I can't really insist on the single lane load.. something like: > > >=20 > > > vc:V4SI[0] =3D c > > > vt:V4SI =3D vec_duplicate:V4SI (vec_select:SI vc:V4SI 0) > > > va:V4SI =3D vb:V4SI vt:V4SI > > >=20 > > > Or is there any other way to do this? > >=20 > > Can you elaborate on "I can't really insist on the single lane load"? > > What's the single lane load in your example?=20 >=20 > Loading just one lane of the vector like this: >=20 > vc:V4SI[0] =3D c // from the above scalar example >=20 > or=20 >=20 > vc:V4SI[0] =3D c[2]=20 >=20 > is what I meant by single lane load. In this example: >=20 > t =3D c[2]=20 > ... > vb:v4si =3D b[0:3]=20 > vc:v4si =3D { t, t, t, t } > va:v4si =3D vb:v4si vc:v4si=20 >=20 > If we are expanding the CONSTRUCTOR as vec_duplicate at vec_init, I cannot > insist 't' to be vector and t =3D c[2] to be vect_t[0] =3D c[2] (which co= uld be=20 > seen as vec_select:SI (vect_t 0) ).=20 >=20 > > I'd expect the instruction > > pattern as quoted to just work (and I hope we expand an uniform > > constructor { a, a, a, a } properly using vec_duplicate). >=20 > As much as I went through the code, this is only done using vect_init. It= is > not expanded as vec_duplicate from, for example, store_constructor() of e= xpr.c Do you see any issues if we expand such constructor as vec_duplicate direct= ly=20 instead of going through vect_init way?=20 VP