Merge pull request #784 from julian-seward1/issue779

Only create copy_nop instructions for types for which an encoding exi…
This commit is contained in:
julian-seward1
2019-06-05 15:05:56 +02:00
committed by GitHub
5 changed files with 67 additions and 9 deletions

View File

@@ -0,0 +1,23 @@
test compile
target x86_64
; Filed as https://github.com/CraneStation/cranelift/issues/779
;
; The copy_nop optimisation to reload (see Issue 773) was creating
; copy_nop instructions for types for which there were no encoding.
function u0:0(i64, i64, i64) system_v {
sig0 = () system_v
sig1 = (i16) system_v
fn1 = u0:94 sig0
fn2 = u0:95 sig1
ebb0(v0: i64, v1: i64, v2: i64):
v3 = iconst.i16 0
jump ebb1(v3)
ebb1(v4: i16):
call fn1()
call fn2(v4)
jump ebb1(v4)
}