This is an archive of the discontinued LLVM Phabricator instance.

[WebAssembly] Test types only used by call_indirect are GC'd correctly
AbandonedPublic

Authored by ncw on Feb 28 2018, 10:43 AM.

Details

Reviewers
sbc100
Summary

I don't think it's covered by any existing tests?

Here we have a type which is called with call_indirect but not used anywhere else in the file.

Event Timeline

ncw created this revision.Feb 28 2018, 10:43 AM

I believe this is already tested in lld/test/wasm/call-indirect.ll:

; Indirect function call where no function actually has this type.               
; Ensures that the type entry is still created in this case.                     
define void @call_ptr(i64 (i64)* %arg) {                                         
  %1 = call i64 %arg(i64 1)                                                      
  ret void                                                                       
}
ncw abandoned this revision.Feb 28 2018, 1:39 PM

D'oh, missed it... OK, I guess this one is a waste of space.