xref: /aosp_15_r20/external/llvm/test/CodeGen/X86/fsxor-alignment.ll (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -march=x86 -mattr=+sse2 -enable-unsafe-fp-math | \
2*9880d681SAndroid Build Coastguard Worker; RUN:  grep -v sp | grep xorps | count 2
3*9880d681SAndroid Build Coastguard Worker
4*9880d681SAndroid Build Coastguard Worker; Don't fold the incoming stack arguments into the xorps instructions used
5*9880d681SAndroid Build Coastguard Worker; to do floating-point negations, because the arguments aren't vectors
6*9880d681SAndroid Build Coastguard Worker; and aren't vector-aligned.
7*9880d681SAndroid Build Coastguard Worker
8*9880d681SAndroid Build Coastguard Workerdefine void @foo(float* %p, float* %q, float %s, float %y) {
9*9880d681SAndroid Build Coastguard Worker  %ss = fsub float -0.0, %s
10*9880d681SAndroid Build Coastguard Worker  %yy = fsub float -0.0, %y
11*9880d681SAndroid Build Coastguard Worker  store float %ss, float* %p
12*9880d681SAndroid Build Coastguard Worker  store float %yy, float* %q
13*9880d681SAndroid Build Coastguard Worker  ret void
14*9880d681SAndroid Build Coastguard Worker}
15