All symbols exported on wasm target

Sebastiaan Koppe mail at skoppe.eu
Sun Nov 4 21:22:07 UTC 2018


On Saturday, 3 November 2018 at 12:45:25 UTC, Johan Engelen wrote:
> On Saturday, 3 November 2018 at 11:12:42 UTC, Sebastiaan Koppe 
> wrote:
>> I am doing a lot of wasm [1] compilation with ldc lately, and 
>> I have noticed that all symbols get exported regardless of 
>> what I try. E.g. strip-all wont strip any, etc.
>
> You could testdrive this PR: 
> https://github.com/ldc-developers/ldc/pull/2894
>
> -Johan

The pull request works wonders! I just add 'export' where I need 
it, and voila!

I did notice some other garbage though... (compared to ldc1.12.0)

It might be completely unrelated to the pull request, but I 
noticed extra *__initZ wasm globals being generated (at least 50 
extra I never saw with 1.12), as well as _d_arraybounds, some 
toHash's and opEquals, and more static data in the data section 
(probably related to the __init's).

Need to check without the pull request...


More information about the digitalmars-d-ldc mailing list