Hey guys

We're seeing an issue with memory initializer generation for optimized JS 
builds of our C++ codebase where depending on the version of Python that's 
installed on your system, memory initializer generation may be broken. I've 
narrowed it down to a few lines of code in emcc.py:

src = re.sub(shared.JS.memory_initializer_pattern, repl, 
open(final).read(), count=1)

If you are building with Emscripten on Windows and have ActiveState Python 
32 bit installed on your system, the regex match will fail. I believe this 
may be a limitation of Python's regex engine - it cannot deal with large 
strings in the 100s of Kb range. I've forked a github repository that 
contains the repro:

https://github.com/achoudhury85/memoryinit_bug_repro

Just run python test.py . If you don't see the text "In Repl", then you 
have repro'd the bug - i.e., you won't be able to generate .mem files.

Thanks,
Arnab

-- 
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].
For more options, visit https://groups.google.com/d/optout.

Reply via email to