File: fmul_legacy.ll

package info (click to toggle)
llvm-toolchain-11 1%3A11.0.1-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 995,808 kB
  • sloc: cpp: 4,767,656; ansic: 760,916; asm: 477,436; python: 170,940; objc: 69,804; lisp: 29,914; sh: 23,855; f90: 18,173; pascal: 7,551; perl: 7,471; ml: 5,603; awk: 3,489; makefile: 2,573; xml: 915; cs: 573; fortran: 503; javascript: 452
file content (44 lines) | stat: -rw-r--r-- 2,218 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
; RUN: opt < %s -instsimplify -S | FileCheck %s

declare float @llvm.amdgcn.fmul.legacy(float, float)

define void @test(float* %p) {
; CHECK-LABEL: @test(
; CHECK-NEXT:    store volatile float 6.000000e+00, float* [[P:%.*]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    store volatile float 0.000000e+00, float* [[P]]
; CHECK-NEXT:    ret void
;
  %a = call float @llvm.amdgcn.fmul.legacy(float +2.0, float +3.0)
  store volatile float %a, float* %p
  %b = call float @llvm.amdgcn.fmul.legacy(float +2.0, float +0.0)
  store volatile float %b, float* %p
  %c = call float @llvm.amdgcn.fmul.legacy(float +2.0, float -0.0)
  store volatile float %c, float* %p
  %d = call float @llvm.amdgcn.fmul.legacy(float +0.0, float +0.0)
  store volatile float %d, float* %p
  %e = call float @llvm.amdgcn.fmul.legacy(float +0.0, float -0.0)
  store volatile float %e, float* %p
  %f = call float @llvm.amdgcn.fmul.legacy(float -0.0, float +0.0)
  store volatile float %f, float* %p
  %g = call float @llvm.amdgcn.fmul.legacy(float -0.0, float -0.0)
  store volatile float %g, float* %p
  %h = call float @llvm.amdgcn.fmul.legacy(float +0.0, float 0x7ff0000000000000) ; +inf
  store volatile float %h, float* %p
  %i = call float @llvm.amdgcn.fmul.legacy(float 0xfff0000000000000, float +0.0) ; -inf
  store volatile float %i, float* %p
  %j = call float @llvm.amdgcn.fmul.legacy(float 0x7ff0001000000000, float -0.0) ; +nan
  store volatile float %j, float* %p
  %k = call float @llvm.amdgcn.fmul.legacy(float -0.0, float 0xfff0000100000000) ; -nan
  store volatile float %k, float* %p
  ret void
}