I have a Corei7 920 Processor and a super-clocked GTX 260 running on my machine with Windows 7. I tried running this using IE, Firefox and Safari (on my hackmac) and all of the browsers hung. 50% of the processor was dedicated to the process. IE 8 was the only browser that stopped the script after giving me a warning.

I’d suggest two things:
- Put a limit on the recursion.
- Put Idle cycles in the loop, which would allow the processor to cool down.

That’s odd… just tested it on my old 1.2 ghz windows machine and it ran slow, but it didn’t hang. What version of the flash player are you using?

There is a limit on the recursion and it can be tweaked in the code by changing the maxBranches. The idle cycles aren’t necessary as you can just change the delay on line 41 from 10 ms to 100ms… or you could even use a slightly random ms so that not all the branches are running at the same time.

Anyone else experience a hang like the one Mohammad describes?

Post a Comment

Your email is never published nor shared. Required fields are marked *

Name*

Email*

Website

Comment

Currently you have JavaScript disabled. In order to post comments, please make sure JavaScript and Cookies are enabled, and reload the page.