Dan Gohman | 0a06310 | 2009-09-08 23:54:48 +0000 | [diff] [blame] | 1 | ; RUN: llc < %s -march=x86 -mattr=+sse2 -enable-unsafe-fp-math | \ |
Dan Gohman | 8c89a50 | 2007-08-15 13:36:28 +0000 | [diff] [blame] | 2 | ; RUN: grep -v sp | grep xorps | count 2 |
Dan Gohman | 1182170 | 2007-07-27 17:16:43 +0000 | [diff] [blame] | 3 | |
| 4 | ; Don't fold the incoming stack arguments into the xorps instructions used |
| 5 | ; to do floating-point negations, because the arguments aren't vectors |
| 6 | ; and aren't vector-aligned. |
| 7 | |
| 8 | define void @foo(float* %p, float* %q, float %s, float %y) { |
Dan Gohman | 7ce405e | 2009-06-04 22:49:04 +0000 | [diff] [blame] | 9 | %ss = fsub float -0.0, %s |
| 10 | %yy = fsub float -0.0, %y |
Dan Gohman | 1182170 | 2007-07-27 17:16:43 +0000 | [diff] [blame] | 11 | store float %ss, float* %p |
| 12 | store float %yy, float* %q |
| 13 | ret void |
| 14 | } |