From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 110396 invoked by alias); 25 Nov 2019 16:53:37 -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 110386 invoked by uid 89); 25 Nov 2019 16:53:37 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-7.9 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 spammy=sincos, __builtin_cexpi, H*MI:@protonmail.com, protonmailcom X-HELO: mail-40135.protonmail.ch Received: from mail-40135.protonmail.ch (HELO mail-40135.protonmail.ch) (185.70.40.135) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 25 Nov 2019 16:53:35 +0000 Date: Mon, 25 Nov 2019 16:53:00 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=default; t=1574700812; bh=LtuGL8G8gURCKk6Ctv4V0YcoI+MrpZkvR98V3+RuziY=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References: Feedback-ID:From; b=CTtS5kKW55TEX4nANY2i0txLo5afBpyWW4ir3pq+mW/fHxseILuogb+ripE/hn8tz tNoxv4te9tzkY1O5yjHQWjFF4YiGowCS5nSztxxhxNI0rILOqS81rFLLQ6VD/JrNJL JsGcvI7MLe9P4ipy1T+ckpmJn8BDbZK9Aa+/uuvw= To: Richard Biener From: GT Cc: "gcc@gcc.gnu.org" , Szabolcs Nagy , nd , Bill Schmidt Reply-To: GT Subject: Re: PPC64 libmvec implementation of sincos Message-ID: In-Reply-To: <3F536966-92DE-49A3-A432-5646981EE26F@gmail.com> References: <0728c06a-d506-e8e8-c4a5-9187a7047f5f@arm.com> <3F536966-92DE-49A3-A432-5646981EE26F@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-SW-Source: 2019-11/txt/msg00206.txt.bz2 > > > > i wonder if gcc can auto-vectorize scalar sincos > > calls, the vectorizer seems to want the calls to > > have no side-effect, but attribute pure or const > > is not appropriate for sincos (which has no return > > value but takes writable pointer args) > > We have __builtin_cexpi for that but not sure if any of the mechanisms ca= n provide a mapping to a vectorized variant. > 1. Using flags -fopt-info-all and -fopt-info-internals, the failure to vect= orize sincos is reported as "unsupported data-type: complex double". The default GCC beh= avior is to replace sincos calls with calls to __builtin_cexpi. 2. Using flags -fno-builtin-sincos and -fno-builtin-cexpi, the failure to v= ectorize sincos is different. In this case, the failure to vectorize is due to "numb= er of iterations could not be computed". No calls to __builtin_cexpi; sincos calls retained. Questions: 1. Should we aim to provide a vectorized version of __builtin_cexpi? If so,= it would have to be a PPC64-only vector __builtin-cexpi, right? 2. Or should we require that vectorized sincos be available only when -fno-= builtin-sincos flag is used in compilation? I don't think we need to fix both types of vectorization failures in order = to obtain sincos vectorization. Thanks. Bert.