memory64
memory64 copied to clipboard
Performance compared to wasm32
I got some initial performance numbers by running the emscripten benchmark suite under v8:
v8 v8-wasm64
base64 1.000 1.234 size: 1.065
conditionals 1.000 1.003 size: 1.112
copy 1.000 0.997 size: 1.110
corrections 1.000 0.985 size: 1.109
corrections64 1.000 1.003 size: 1.110
fannkuch 1.000 1.161 size: 1.075
fasta_float 1.000 1.149 size: 1.075
havlak 1.000 1.370 size: 1.110
ifs 1.000 1.018 size: 1.110
matrix_multiply 1.000 1.162 size: 1.087
memops 1.000 1.163 size: 1.088
primes 1.000 1.016 size: 1.112
primes_nocheck 1.000 1.000 size: 2.020
skinning 1.000 1.040 size: 1.067
zzz_box2d 1.000 1.182 size: 1.043
mean 1.098 1.152 (-primes_nocheck: 1.090)
Looks like about 10% performance hit (presumably a combination of extra bounds checks and larger data structures), and about 10% code size increase. The size increase probably warrants more investigation since I wouldn't expect the larger pointer sizes to show up very much in the binary (just the static data structures of which I doubt there are that many).
I think the size regressions are because I was measuring both JS and wasm sizes. I will re-measure with just wasm sizes.
Do you know if this can still be considered as a good reference value?