On Mon, May 18, 2020 at 10:30 AM J Decker <[email protected]> wrote:

>
>
> On Mon, May 18, 2020 at 6:02 AM Eric Mandel <[email protected]>
> wrote:
>
>> Hi Talha,
>>
>> Our browser-based astronomical image display (https://js9.si.edu) is
>> transformed into a full desktop app using Electron and a few hundred lines
>> of wrapper code. Having the same code base for both environments is a huge
>> benefit. We also very cautiously allow use of Electron's node capabilities
>> to make the underlying file system available on the desktop app.The main
>> drawback for us (compared to a pure desktop app using Aqua or X11) is lack
>> of mmap() and the limit on the amount of available memory: our files are
>> large (> 100Mb) or even huge (> 1Gb) and special techniques are required to
>> cut down on memory use.
>>
>
> re no mmap...
> https://www.npmjs.com/package/sack.vfs  has a mapFile() function which
> isn't very complex itself, that just returns an ArrayBuffer...
> https://github.com/d3x0r/sack.vfs/blob/master/src/vfs_module.cc#L921-L960
>
>

Sadly even if node supports mmap, using methods such as this,  there is no
way (today) to make that usable by a WebAssebmly module.


>
> Also, `--max-old-space-size=8192 ` should also work as an electron option
> to increase the JS heap size. (which apparently needs to be wrapped in an
> option https://github.com/electron/electron/issues/2056    
> --js-flags='--max-old-space-size=10192'
> )
>
>
>
>> We use Emscripten to compile cpu-intensive astronomical i/o,
>> reprojection, and world coordinate system libraries to wasm. Although the
>> results run at near-native speed thanks to Emscripten, our data processing
>> takes much more time than an ordinary web app. As a result, we probably
>> don't notice Electron-specific inefficiencies that others might.
>>
>> Regards,
>>
>> Eric
>>
>> --
>> 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/7017d53b-c824-4ea3-a5f8-1e6c941f48b6%40googlegroups.com
>> <https://groups.google.com/d/msgid/emscripten-discuss/7017d53b-c824-4ea3-a5f8-1e6c941f48b6%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/CAA2GJqU24CyweeeR7hpwzm5MsGNtijY9nsRJm4V2O8xDUDQ_uw%40mail.gmail.com
> <https://groups.google.com/d/msgid/emscripten-discuss/CAA2GJqU24CyweeeR7hpwzm5MsGNtijY9nsRJm4V2O8xDUDQ_uw%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_va2-xE4Rv%2B3FPsP0F7y82a1sKZHsm5Zn706_51K-_-Yo2PQ%40mail.gmail.com.

Reply via email to