Test Failure: Transforms/ExpandLargeFpConvert/X86/expand-large-fp-convert-si129tofp.ll

Test source: git

Log:

Source: <stdin>
ERROR: Unsupported type: x86_fp80

----------------------------------------
define half @si129tohalf(i129 %a) {
#0:
  %conv = sitofp i129 %a to half
  ret half %conv
}
=>
define half @si129tohalf(i129 %a) {
itofp-entry:
  %#0 = icmp eq i129 %a, 0
  br i1 %#0, label %itofp-return, label %itofp-if-end

itofp-if-end:
  %#1 = ashr i129 %a, 128
  %#2 = xor i129 %#1, %a
  %#3 = sub i129 %#2, %#1
  %#4 = ctlz i129 %#3, 1
  %#5 = trunc i129 %#4 to i32
  %#6 = sub i32 129, %#5
  %#7 = sub i32 128, %#5
  %#8 = icmp sgt i32 %#6, 24
  br i1 %#8, label %itofp-if-then4, label %itofp-if-else

itofp-if-then4:
  switch i32 %#6, label %itofp-sw-default [
    i32 25, label %itofp-sw-bb
    i32 26, label %itofp-sw-epilog
  ]

itofp-sw-default:
  %#9 = sub i32 103, %#5
  %#10 = zext i32 %#9 to i129
  %#11 = lshr i129 %#3, %#10
  %#12 = add i32 %#5, 26
  %#13 = zext i32 %#12 to i129
  %#14 = lshr i129 680564733841876926926749214863536422911, %#13
  %#15 = and i129 %#14, %#3
  %#16 = icmp ne i129 %#15, 0
  %#17 = zext i1 %#16 to i129
  %#18 = or i129 %#11, %#17
  br label %itofp-sw-epilog

itofp-sw-bb:
  %#19 = shl i129 %#3, 1
  br label %itofp-sw-epilog

itofp-sw-epilog:
  %#20 = phi i129 [ %#18, %itofp-sw-default ], [ %#3, %itofp-if-then4 ], [ %#19, %itofp-sw-bb ]
  %#21 = trunc i129 %#20 to i32
  %#22 = lshr i32 %#21, 2
  %#23 = and i32 %#22, 1
  %#24 = zext i32 %#23 to i129
  %#25 = or i129 %#20, %#24
  %#26 = add i129 %#25, 1
  %#27 = ashr i129 %#26, 2
  %a3 = and i129 %#26, 67108864
  %#28 = icmp eq i129 %a3, 0
  %#29 = trunc i129 %#27 to i32
  br i1 %#28, label %itofp-if-end26, label %itofp-if-then20

itofp-if-then20:
  %#32 = ashr i129 %#26, 3
  %#33 = trunc i129 %#32 to i32
  br label %itofp-if-end26

itofp-if-else:
  %#36 = add i32 %#5, 4294967191
  %#37 = zext i32 %#36 to i129
  %#38 = shl i129 %#3, %#37
  %#39 = trunc i129 %#38 to i32
  br label %itofp-if-end26

itofp-if-end26:
  %#42 = phi i32 [ %#33, %itofp-if-then20 ], [ %#29, %itofp-sw-epilog ], [ %#39, %itofp-if-else ]
  %#43 = phi i32 [ %#6, %itofp-if-then20 ], [ %#7, %itofp-sw-epilog ], [ %#7, %itofp-if-else ]
  %#44 = trunc i129 %#1 to i32
  %#45 = and i32 %#44, 2147483648
  %#46 = shl i32 %#43, 23
  %#47 = add i32 %#46, 1065353216
  %#48 = and i32 %#42, 8388607
  %#49 = or i32 %#48, %#45
  %#50 = or i32 %#49, %#47
  %#51 = bitcast i32 %#50 to float
  %#52 = fptrunc float %#51 to half
  br label %itofp-return

itofp-return:
  %#53 = phi half [ %#52, %itofp-if-end26 ], [ 0x0000, %itofp-entry ]
  ret half %#53
}
Transformation doesn't verify! (unsound)
ERROR: Source is more defined than target

Example:
i129 %a = poison

Source:
half %conv = poison

Target:
i1 %#0 = poison
UB triggered on br


Pass: 
Command line: '/home/nlopes/llvm/build/bin/opt' '-load=/home/nlopes/alive2/build/tv/tv.so' '-tv-exit-on-error' '-tv' '-S' '-mtriple=x86_64--' '-expand-large-fp-convert' '-tv' '-tv-smt-to=20000' '-tv-report-dir=/home/nlopes/alive2/build/logs' '-tv-smt-stats'


------------------- SMT STATS -------------------
Num queries: 7
Num invalid: 0
Num skips:   0
Num trivial: 0 (0.0%)
Num timeout: 0 (0.0%)
Num errors:  0 (0.0%)
Num SAT:     7 (100.0%)
Num UNSAT:   0 (0.0%)
Alive2: Transform doesn't verify; aborting!

stderr:

RUN: at line 2: /home/nlopes/alive2/build/opt-alive.sh -S -mtriple=x86_64-- -expand-large-fp-convert < /bitbucket/nlopes/llvm/llvm/test/Transforms/ExpandLargeFpConvert/X86/expand-large-fp-convert-si129tofp.ll | /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/ExpandLargeFpConvert/X86/expand-large-fp-convert-si129tofp.ll
+ /home/nlopes/alive2/build/opt-alive.sh -S -mtriple=x86_64-- -expand-large-fp-convert
+ /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/ExpandLargeFpConvert/X86/expand-large-fp-convert-si129tofp.ll

FileCheck error: '<stdin>' is empty.
FileCheck command line:  /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/ExpandLargeFpConvert/X86/expand-large-fp-convert-si129tofp.ll

 

<-- Back