llvm.exp.f32 didn't work


I found that llvm.exp.f32 didn’t work but sqrt works well.

I implemented a function like

define inlinehint float “my_exp”(float %.value) {
%0 = call float @llvm.exp.f32(float %.value)
ret float %0

declare float @llvm.exp.f32(float) nounwind readonly

But it generates following ASM:

00280072 movups xmm0,xmmword ptr [esp+8]
00280077 movss dword ptr [esp],xmm0
0028007C call 00000000
00280081 pop eax

As you seen, line 0028007C will call CRT exp I think, but it calls NULL pointer.

But sqrt is right.

005000D1 movss xmm0,dword ptr [esp+0Ch]
005000D7 movss dword ptr [esp],xmm0
005000DC call 00490018
005000E1 mov eax,dword ptr [esp+8]

Could you give me some help ? Thanks !

And sorry, my platform is MSVC 2010, x86, debug, windows 7, LLVM 3.0.

在 2012年3月31日 上午10:50,空明流转 <wuye9036@gmail.com>写道: