I created an issue: https://github.com/kripken/emscripten/issues/3063.
Arve On Tue, Dec 9, 2014 at 10:20 PM, Arve Knudsen <[email protected]> wrote: > Well, I have no idea how to reduce it further because for one, I don't > know how to cause this issue otherwise, second, I can't reproduce the issue > when including chuck.js in a static Web page. The error only occurs for me > when I include chuck.js in a SPA (I first encountered it within a Meteor > application, so my current app is simpler). > > Arve > > On Tue, Dec 9, 2014 at 8:22 PM, Alon Zakai <[email protected]> wrote: > >> Yes, please try to reduce it to as small a testcase as you can. >> >> - Alon >> >> >> On Tue, Dec 9, 2014 at 1:45 AM, Arve Knudsen <[email protected]> >> wrote: >> >>> I've built now with -g and SAFE_HEAP=3, it makes no difference. I guess >>> I should file a bug? >>> On Dec 9, 2014 1:08 AM, "Alon Zakai" <[email protected]> wrote: >>> >>>> Possibly, but see tips in >>>> >>>> http://kripken.github.io/emscripten-site/docs/porting/Debugging.html >>>> >>>> , building with SAFE_HEAP and ASSERTIONS etc. can find undefined >>>> behavior. It is possible it only shows up in optimized builds (optimizer >>>> can take advantage of undefined behavior). >>>> >>>> - Alon >>>> >>>> >>>> On Sun, Dec 7, 2014 at 12:31 PM, Arve Knudsen <[email protected]> >>>> wrote: >>>> >>>>> Hi >>>>> >>>>> When including optimized (-O3) ChucK (https://github.com/aknuds1/chuck) >>>>> code in my app, it invariably breaks when loaded, with the following error >>>>> message: >>>>> >>>>> Invalid function pointer '0' called with signature 'ii'. Perhaps >>>>> this is an invalid value (e.g. caused by calling a virtual method on a >>>>> NULL >>>>> pointer)? Or calling a function with an incorrect type, which will fail? >>>>> (it is worth building your source files with -Werror (warnings are >>>>> errors), >>>>> as warnings can indicate undefined behavior which can cause this) >>>>> >>>>> The code doesn't break if I compile without optimization. I'm using >>>>> Emscripten 1.27.0. I've tested with both Chrome and Firefox on OS X. You >>>>> can try for yourselves at http://104.131.177.17/ (just check the >>>>> console after loading the page). >>>>> >>>>> Is this due to a bug in Emscripten? >>>>> >>>>> Arve >>>>> >>>>> -- >>>>> 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. >>>>> >>>> >>>> -- >>>> 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. >>>> >>> -- >>> 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. >>> >> >> -- >> 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. >> > > -- 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.
