
25 Dec
2010
25 Dec
'10
12:15 a.m.
On 25.12.2010, at 0:20, Henning Thielemann wrote:
On 13.12.2010 16:38, Pavel Perikov wrote:
Is it possible to make GHC-7.0.1 to generate intrinsic instructions instead of calls to C library to compute trigonometric functions?
As far as I remember GHC generates FPU instructions for sinus and friends with its native code generator. However, I noted that LLVM does not do this and always jumps into the C library, although it is documented otherwise. ok, I'm answering my own question here. -fasm indeed uses intrinsic operations in x87 mode. Sadly SSE does not have trigonometric and instructions, though series expansions using SSE2 instructions is usually _faster_ than fsin/fcos. So the behavior is expected.
P.