forked from OSchip/llvm-project
[X86] Regenerate scalar stack reload test
llvm-svn: 295195
This commit is contained in:
parent
e14bd4246d
commit
d811bdd61a
|
@ -1,9 +1,11 @@
|
|||
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
|
||||
; RUN: llc < %s -march=x86 -mattr=+sse2 | FileCheck %s
|
||||
; PR2656
|
||||
|
||||
target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:128:128"
|
||||
target triple = "i686-apple-darwin9.4.0"
|
||||
%struct.anon = type <{ float, float }>
|
||||
|
||||
%struct.anon = type <{ float, float }>
|
||||
@.str = internal constant [17 x i8] c"pt: %.0f, %.0f\0A\00\00" ; <[17 x i8]*> [#uses=1]
|
||||
|
||||
; We can not fold either stack load into an 'xor' instruction because that
|
||||
|
@ -13,12 +15,21 @@ target triple = "i686-apple-darwin9.4.0"
|
|||
|
||||
define void @foo(%struct.anon* byval %p) nounwind {
|
||||
; CHECK-LABEL: foo:
|
||||
; CHECK: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
|
||||
; CHECK: ## BB#0: ## %entry
|
||||
; CHECK-NEXT: subl $28, %esp
|
||||
; CHECK-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
|
||||
; CHECK-NEXT: movss {{.*#+}} xmm1 = mem[0],zero,zero,zero
|
||||
; CHECK-NEXT: movaps {{.*#+}} xmm2 = [-0.000000e+00,-0.000000e+00,-0.000000e+00,-0.000000e+00]
|
||||
; CHECK-NEXT: xorps %xmm2, %xmm0
|
||||
; CHECK-NEXT: cvtss2sd %xmm0, %xmm0
|
||||
; CHECK-NEXT: xorps %xmm2, %xmm1
|
||||
; CHECK-NEXT: cvtss2sd %xmm1, %xmm1
|
||||
; CHECK-NEXT: movsd %xmm1, {{[0-9]+}}(%esp)
|
||||
; CHECK-NEXT: movsd %xmm0, {{[0-9]+}}(%esp)
|
||||
; CHECK-NEXT: movl $_.str, (%esp)
|
||||
; CHECK-NEXT: calll _printf
|
||||
; CHECK-NEXT: addl $28, %esp
|
||||
; CHECK-NEXT: retl
|
||||
entry:
|
||||
%tmp = getelementptr %struct.anon, %struct.anon* %p, i32 0, i32 0 ; <float*> [#uses=1]
|
||||
%tmp1 = load float, float* %tmp ; <float> [#uses=1]
|
||||
|
@ -40,13 +51,19 @@ declare i32 @printf(...)
|
|||
|
||||
define double @PR22371(double %x) {
|
||||
; CHECK-LABEL: PR22371:
|
||||
; CHECK: movsd 16(%esp), %xmm0
|
||||
; CHECK-NEXT: andps LCPI1_0, %xmm0
|
||||
; CHECK-NEXT: movlps %xmm0, (%esp)
|
||||
; CHECK: ## BB#0:
|
||||
; CHECK-NEXT: subl $12, %esp
|
||||
; CHECK-NEXT: Lcfi0:
|
||||
; CHECK-NEXT: .cfi_def_cfa_offset 16
|
||||
; CHECK-NEXT: movsd {{.*#+}} xmm0 = mem[0],zero
|
||||
; CHECK-NEXT: andps LCPI1_0, %xmm0
|
||||
; CHECK-NEXT: movlps %xmm0, (%esp)
|
||||
; CHECK-NEXT: fldl (%esp)
|
||||
; CHECK-NEXT: addl $12, %esp
|
||||
; CHECK-NEXT: retl
|
||||
%call = tail call double @fabs(double %x) #0
|
||||
ret double %call
|
||||
}
|
||||
|
||||
declare double @fabs(double) #0
|
||||
attributes #0 = { readnone }
|
||||
|
||||
|
|
Loading…
Reference in New Issue