~ubuntu-branches/ubuntu/quantal/llvm-3.1/quantal

« back to all changes in this revision

Viewing changes to test/Verifier/fpaccuracy.ll

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2012-04-14 18:28:54 UTC
  • mfrom: (1.1.4)
  • Revision ID: package-import@ubuntu.com-20120414182854-gmdspwc0z3uwed8s
Tags: 3.1~svn154750-1
New snapshot release

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
; RUN: not llvm-as < %s |& FileCheck %s
2
 
 
3
 
define void @foo(i32 %i, float %f, <2 x float> %g) {
4
 
  %s = add i32 %i, %i, !fpaccuracy !0
5
 
; CHECK: fpaccuracy requires a floating point result!
6
 
  %t = fadd float %f, %f, !fpaccuracy !1
7
 
; CHECK: fpaccuracy takes one operand!
8
 
  %u = fadd float %f, %f, !fpaccuracy !2
9
 
; CHECK: fpaccuracy takes one operand!
10
 
  %v = fadd float %f, %f, !fpaccuracy !3
11
 
; CHECK: fpaccuracy ULPs not a floating point number!
12
 
  %w = fadd float %f, %f, !fpaccuracy !0
13
 
; Above line is correct.
14
 
  %w2 = fadd <2 x float> %g, %g, !fpaccuracy !0
15
 
; Above line is correct.
16
 
  %x = fadd float %f, %f, !fpaccuracy !4
17
 
; CHECK: fpaccuracy ULPs is negative!
18
 
  %y = fadd float %f, %f, !fpaccuracy !5
19
 
; CHECK: fpaccuracy ULPs is negative!
20
 
  %z = fadd float %f, %f, !fpaccuracy !6
21
 
; CHECK: fpaccuracy ULPs not a normal number!
22
 
  ret void
23
 
}
24
 
 
25
 
!0 = metadata !{ float 1.0 }
26
 
!1 = metadata !{ }
27
 
!2 = metadata !{ float 1.0, float 1.0 }
28
 
!3 = metadata !{ i32 1 }
29
 
!4 = metadata !{ float -1.0 }
30
 
!5 = metadata !{ float -0.0 }
31
 
!6 = metadata !{ float 0x7FFFFFFF00000000 }