This is an archive of the discontinued LLVM Phabricator instance.

[WebAssembly] Only mark non-hidden symbols as live if they are also defined
ClosedPublic

Authored by sbc100 on Jun 18 2018, 2:56 PM.

Diff Detail

Repository
rL LLVM

Event Timeline

sbc100 created this revision.Jun 18 2018, 2:56 PM
sbc100 added a reviewer: ruiu.Jun 18 2018, 2:58 PM
sbc100 added a reviewer: ncw.Jun 19 2018, 10:46 AM

Gentle ping..

sbc100 updated this revision to Diff 152186.Jun 20 2018, 3:50 PM
  • rebase
ncw accepted this revision.Jun 21 2018, 2:22 AM

Looks good. I'm deducing that when you removed the "hidden" from "used_undef_fn" and "unused_undef_fn", the test then failed - and then the code change makes it pass again. Makes sense.

We could also explicitly test everything - by adding used_undef_hidden_fn/used_undef_public_fn/unused_undef_hidden_fn/unused_undef_public_fn, and the same for the globals as well. Might be worth it, just to cover all the cases.

test/wasm/gc-imports.ll
3 ↗(On Diff #152186)

Could also remove -print-gc-sections here (or check/assert that its output matches what we expect). I think the checks were lost in all the debate about where and whether different section/function/global types would be reported...

This revision is now accepted and ready to land.Jun 21 2018, 2:22 AM
ncw added a comment.Jun 21 2018, 2:23 AM

I've been quiet for a while as well ... I keep meaning to get back to my patch queue and try and get them reviewed and submitted. I have a couple of features completed or mostly-completed, I just need a few days away from my main job to get them back on track! Maybe it's time to get LLD ready for native-exception "sections" as well - that's a feature I'm really hoping will arrive soon in WebAssembly.

This revision was automatically updated to reflect the committed changes.