LoopVectorize: Vectorize math builtin calls.
authorBenjamin Kramer <benny.kra@googlemail.com>
Wed, 27 Feb 2013 15:24:19 +0000 (15:24 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Wed, 27 Feb 2013 15:24:19 +0000 (15:24 +0000)
commit2fe71f8f7e678174ba217d3d16525092805ad45b
tree2a7c8c39d45019a50ffd9dfc90209366a77f8f4d
parentf404449e23a8584bff19eb5db49e1dc1161afdef
LoopVectorize: Vectorize math builtin calls.

This properly asks TargetLibraryInfo if a call is available and if it is, it
can be translated into the corresponding LLVM builtin. We don't vectorize sqrt()
yet because I'm not sure about the semantics for negative numbers. The other
intrinsic should be exact equivalents to the libm functions.

Differential Revision: http://llvm-reviews.chandlerc.com/D465

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@176188 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/Vectorize/LoopVectorize.cpp
test/Transforms/LoopVectorize/intrinsic.ll