Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ;; Source code, avoids constant propagation
- ;;#include <math.h>
- ;;extern volatile float place, a, b;
- ;;__attribute__((noinline))
- ;;void foo() { place = copysignf(a, b); }
- ;; GCC 8.2, -O3 -march=skylake -c -ffast-math
- foo():
- vmovss xmm1, DWORD PTR b[rip]
- vmovss xmm0, DWORD PTR a[rip]
- vmovaps xmm2, xmm1
- vandps xmm2, xmm2, XMMWORD PTR .LC1[rip]
- vandps xmm0, xmm0, XMMWORD PTR .LC0[rip]
- vorps xmm0, xmm0, xmm2
- vmovss DWORD PTR place[rip], xmm0
- ret
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement