Are There Plans to Go 64-Bit For Emscripten

319 views
Skip to first unread message

awt

unread,
Apr 25, 2016, 2:00:53 AM4/25/16
to emscripten-discuss
Hi,

I understand that Emscripten is 32-bit now. Are there plans to go 64-bit and will going 64-bit actually bring about any benefits for asm.js?

Brion Vibber

unread,
Apr 25, 2016, 3:06:32 AM4/25/16
to emscripte...@googlegroups.com
On Monday, April 25, 2016, awt <knigh...@gmail.com> wrote:
Hi,

I understand that Emscripten is 32-bit now. Are there plans to go 64-bit and will going 64-bit actually bring about any benefits for asm.js?

JavaScript cannot natively represent 64-bit integers, so this isn't really feasible yet in a way that will perform well. I know WebAssembly has already plans for a future 64-bit addressing mode, but that's not in the initial implementation stage either.


If JS and/or wasm get native 64-bit integers and a Uint64Array interface to access them in memory atomically, then that should become possible some day. :)

Main benefit of 64-bit _addressing_ is that you can make use of more than 4 GB of memory; this may be relevant for large games, scientific processing etc, but is probably less important for the asm.js/wasm apps than it is for the browsers that host them.

(The larger address space could also be useful for memory-mapping resources, but I have no idea how feasible that is in asm.js/wasm world.)

Some applications may benefit from native 64-bit _arithmetic_ as well in key performance areas.

-- brion

キャロウ マーク

unread,
Apr 25, 2016, 5:52:23 AM4/25/16
to emscripte...@googlegroups.com

On Apr 25, 2016, at 3:00 PM, awt <knigh...@gmail.com> wrote:

I understand that Emscripten is 32-bit now. Are there plans to go 64-bit and will going 64-bit actually bring about any benefits for asm.js?

Emscripten itself *is* 64 bit. The 32-bit version was dropped years ago, if it ever existed. As for the code Emscripten generates, see Brion’s answer.

Regards

    -Mark
Reply all
Reply to author
Forward
0 new messages