search for: __builtin_ia32_pfadd

Displaying 2 results from an estimated 2 matches for "__builtin_ia32_pfadd".

2011 Apr 14
2
[LLVMdev] [x86 codegen] 3DNow! intrinsics not behaving as expected.
...lly got all of the 3DNow! instruction intrinsics and builtins into LLVM and Clang, however, while testing them, I've noticed that they produce incorrect results. For example: typedef float V2f __attribute__((vector_size(8))); int main() { V2f dest, a = {1.0, 3.0}, b = {10.0, 3.5}; dest = __builtin_ia32_pfadd(a, b); printf("(%f, %f)\n", dest[0], dest[1]); } Should output (11, 6.5). However, it outputs different values depending on the optimization level. Generally one of them is correct, and the other is -nan. I looked at the program using a debugger, and the pfadd instruction is executed...
2011 Apr 14
0
[LLVMdev] [x86 codegen] 3DNow! intrinsics not behaving as expected.
...ics and builtins > into LLVM and Clang, however, while testing them, I've noticed that > they produce incorrect results. > > For example: > > typedef float V2f __attribute__((vector_size(8))); > > int main() { >  V2f dest, a = {1.0, 3.0}, b = {10.0, 3.5}; >  dest = __builtin_ia32_pfadd(a, b); >  printf("(%f, %f)\n", dest[0], dest[1]); > } > > Should output (11, 6.5). However, it outputs different values > depending on the optimization level. Generally one of them is correct, > and the other is -nan. > > I looked at the program using a debugger, a...