From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-4.2 required=3.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,SPF_HELO_PASS,SPF_PASS, T_BULK_RE_SUSP_NTLD,T_FROM_SUSPICIOUS_NTLD shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id 03F231F45F for ; Sun, 5 May 2019 20:53:27 +0000 (UTC) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:references:in-reply-to:from:date :message-id:subject:to:content-type; q=dns; s=default; b=yYWgZ6t j0zkRk/prr6juE29CPdsn3Ouefz/nXlNSB6PBBb16UMtAVF48gm+/FlmnwTFdqH1 7Qbd2+NOeJgzwEQU1eZTbLx/g4Ken+H9XrVFZ2c2vcYmNVYOnid/1a33XxJQCkYJ mRVnMC70Iv+PQkA9MoXZDIugfZBfQQGPHkDo= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:mime-version:references:in-reply-to:from:date :message-id:subject:to:content-type; s=default; bh=gSduTZs9a8w6A 9eiW5TBn5/c+74=; b=v9CwpRP3LWFqqOLiEPjGK/mpuPOYcS4mkmxN1Br676mOa F9tN3rNOqbMsQ6gWR4x0/S8TQEX0axa58O0FbxN/YouGuvZPYdyqmL/KR3vyKPCe hPZ7pB+CNs0t/1n1wiJDyJmpTmZ2zAhEVCoaFoEotIFYGgmxphyqFaB4q5S8zs= Received: (qmail 63308 invoked by alias); 5 May 2019 20:53:25 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 63296 invoked by uid 89); 5 May 2019 20:53:25 -0000 Authentication-Results: sourceware.org; auth=none X-HELO: git.icu MIME-Version: 1.0 References: <20190505203438.28140-1-shawn@git.icu> In-Reply-To: <20190505203438.28140-1-shawn@git.icu> From: Shawn Landden Date: Sun, 5 May 2019 15:53:10 -0500 Message-ID: Subject: Re: [RFC][PATCH] powerpc: add libmvec implementations of log and logf To: libc-alpha@sourceware.org Content-Type: text/plain; charset="UTF-8" On Sun, May 5, 2019 at 3:34 PM Shawn Landden wrote: > > The ABI spec[1] Is x86 specific. I removed the arch field, > because this can be handled using IFUNC (the vector width is > part of the name). > > GCC will have to be taught about these. I forgot to mentions some things. The log function has better accuracy than scalar log due to the use of fused-multiply-add. Sadly this means I don't have a good way to test this function's accuracy. Perhaps it is better to produce the same results as those functions, in which case I will remove the FMA and add the additional table. Alternatively we could use FMA for the scalar log as well. [BZ #24208] > > When fed numbers in the range of 0 to 2^32 (as doubles) the vector log > is about 75% faster than scalar log. > > When fed numbers in the range of 0 to 2^16 (as floats) the vector logf > is about 30% faster than scalar logf. This should probably be faster, > and did not spend much time in perf looking into this.[2] > > logf requires Power 7 > log requires Power 8 > (according to gcc allowing them to be compiled with -mcpu=powerx) >