[LLVMdev] SIMD trigonometry/logarithms?

David Tweed david.tweed at arm.com
Thu Feb 14 07:13:34 PST 2013


Hi,

Looks interesting, but the codebase appears to only do SSE*/AVX (no ARM NEON -- which obviously makes me sad -- , or other architectures). It might be useful if some of the tests which are "optimized" into things like "has_avx, because that implies we're capable of 256-bit vectorization" were deoptimized to first test in "generic terms" and only tested for a specific instruction set is being used at the point when the string for an actual intrinsic is needed.

 

Cheers,

Dave

 

 

From: llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] On Behalf Of Jose Fonseca
Sent: 14 February 2013 14:49
To: Dimitri Tcaciuc
Cc: llvmdev at cs.uiuc.edu
Subject: Re: [LLVMdev] SIMD trigonometry/logarithms?

 

FWIW, llvmpipe has C-binding code that generates (inlines) log/exp/pow/sin/cos functions of the fly, for an arbitrary number of elements (in most cases), and uses sse/avx intrinsics as available:

 

  http://cgit.freedesktop.org/mesa/mesa/tree/src/gallium/auxiliary/gallivm/lp_bld_arit.c

 

The precision is 20bits, which is enough for 3D. But it wouldn't be difficult to have more (or even variable) precision, by using higher degree approximating functions were appropriate.

 

The code is in a permissible license.

 

Jose

 

 

  _____  

Hi everyone,

 

I was looking at loop vectorizer code and wondered if there was any current or planned effort to introduce SIMD implementations of sin/cos/exp/log intrinsics (in particular for x86-64 backend)?

 

Cheers,

 

 

Dimitri.


_______________________________________________
LLVM Developers mailing list
LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev

 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130214/b2cad63d/attachment.html>


More information about the llvm-dev mailing list