This is an archive of the discontinued LLVM Phabricator instance.

[WebAssembly] Honor --allow-undefined even for explicit exports
ClosedPublic

Authored by sbc100 on Mar 7 2018, 5:07 PM.

Details

Summary

When a symbol is exported via --export=foo but --allow-undefined
is also specified, the symbol is now allowed to be undefined.
Previously we were special casing such symbols.

This combinations of behavior is exactly what emescripten
requires. Although we are trying hard not to allow emscripten
specific features in lld, this one makes sense.

Enforce this behavior by added this case to test/wasm/undefined.ll.

Diff Detail

Repository
rL LLVM

Event Timeline

sbc100 created this revision.Mar 7 2018, 5:07 PM
sbc100 added a reviewer: ncw.Mar 7 2018, 5:08 PM
sbc100 added a reviewer: ruiu.
ruiu accepted this revision.Mar 7 2018, 5:13 PM

LGTM

This revision is now accepted and ready to land.Mar 7 2018, 5:13 PM
sbc100 updated this revision to Diff 137518.Mar 7 2018, 5:14 PM
  • remove extra line
This revision was automatically updated to reflect the committed changes.