diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-01-14 18:10:42 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-01-14 18:10:42 -0800 |
commit | cb50975f3a139fa7bfe72b3df5a422dfa7a24b25 (patch) | |
tree | bfd0099b6a006382090f21c27f1c67b5de0ae8cf | |
parent | ed8723d8761fbf5be179f3fc492e4ffab71597f9 (diff) |
use tempBigInt properly in asm
-rwxr-xr-x | emscripten.py | 2 | ||||
-rw-r--r-- | src/parseTools.js | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/emscripten.py b/emscripten.py index 08bb6d3c..50d7f6c5 100755 --- a/emscripten.py +++ b/emscripten.py @@ -382,7 +382,7 @@ var asmPre = (function(env, buffer) { ''' % (asm_setup,) + '\n' + asm_global_vars + ''' var __THREW__ = 0; var undef = 0; - var tempInt = 0, tempValue = 0; + var tempInt = 0, tempBigInt = 0, tempValue = 0; ''' + ''.join([''' var tempRet%d = 0;''' % i for i in range(10)]) + '\n' + asm_global_funcs + ''' function stackAlloc(size) { diff --git a/src/parseTools.js b/src/parseTools.js index b435855d..dfb121a4 100644 --- a/src/parseTools.js +++ b/src/parseTools.js @@ -1197,7 +1197,7 @@ function makeSetValue(ptr, pos, value, type, noNeedFirst, ignore, align, noSafe, ret += 'tempBigInt=' + value + sep; for (var i = 0; i < bytes; i++) { ret += makeSetValue(ptr, getFastValue(pos, '+', i), 'tempBigInt&0xff', 'i8', noNeedFirst, ignore, 1); - if (i < bytes-1) ret += sep + 'tempBigInt>>=8' + sep; + if (i < bytes-1) ret += sep + 'tempBigInt = tempBigInt>>8' + sep; } } } else { |