I recently tracing channels to binaryen and some minimal tracing to
`wasm-emscripten-finalize`.   You might be able to get some clues from
adding `--debug=emscripten` to the command line.

On Wed, Jan 22, 2020 at 12:52 PM Alon Zakai <[email protected]> wrote:

> Oh, wow, it shouldn't be anything like that...
>
> If you built binaryen by yourself, I'd make sure that's not a debug build.
> Another thing is to check you don't set BINARYEN_CORES=1 in the environment
> (which would prevent an almost linear speedup with more cores). And in a
> very big project perhaps it takes enough memory to cause swapping, so
> checking peak memory usage etc. might be interesting.
>
> If those aren't it, I'd run it in a profiler to see what's taking so long.
> If you can share the file I can take a look too.
>
> - Alon
>
>
>
>
> On Wed, Jan 22, 2020 at 11:31 AM Patrik Weiskircher <[email protected]>
> wrote:
>
>> Hi!
>>
>> I'm working at PSPDFKit trying to upgrade our Web viewer from Emscripten
>> version 1.38.31 to 1.39.6.
>> I got everything working so far, I'm just having a little trouble with
>> the linking speed. Everything goes fine and quick
>> enough until we hit linking the library - specifically the
>> `wasm-emscripten-finalize` step.
>>
>> The exact command line is this:
>> > /opt/emsdk/upstream/bin/wasm-emscripten-finalize --detect-features
>> --global-base=1024 --check-stack-overflow \
>> > /tmp/emscripten_temp_rjgvGG/pspdfkit.wasm.wasm -o
>> /tmp/emscripten_temp_rjgvGG/pspdfkit.wasm.wasm.o.wasm
>>
>> This takes around 15 minutes. While this isn't a deal breaker, it does
>> make our CI quite slow and keeps agents occupied
>> longer than necessary. It'll also not be great when we have to debug a
>> problem on Emscripten in the future.
>>
>> I looked around on the GitHub issue board and also on the mailing list
>> but I couldn't find any information about this. I
>> understand we have quite a big code base and things will take some time -
>> I'm just wondering if anyone has any tips
>> on how I could debug what *exactly* takes this long or how to make this
>> any quicker?
>>
>> Thanks so much!
>> Patrik
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "emscripten-discuss" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/emscripten-discuss/cca83aa0-c022-4a94-8cc6-42063b5ccebc%40googlegroups.com
>> <https://groups.google.com/d/msgid/emscripten-discuss/cca83aa0-c022-4a94-8cc6-42063b5ccebc%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
> --
> You received this message because you are subscribed to the Google Groups
> "emscripten-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/emscripten-discuss/CAEX4NpREWRPRu1M%3DEx2t%2BQXkt7pQ64sgFC%2BaGU6h_H5vbX9ocA%40mail.gmail.com
> <https://groups.google.com/d/msgid/emscripten-discuss/CAEX4NpREWRPRu1M%3DEx2t%2BQXkt7pQ64sgFC%2BaGU6h_H5vbX9ocA%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/emscripten-discuss/CAL_va28KeT9VfF45%3D%3DAEmVSML79uB9L%2B%2BWJV6EG6%3DL3NoGtvjg%40mail.gmail.com.

Reply via email to