This is not really about JavaScript – it’s more about the browser and the way it’s handling JavaScript.
Each browser is doing this differently, but most modern browsers won’t let JavaScript take 100% of the resources to prevent the client machine from crashing.
Bottom line you can’t do such thing with client side scripting, you’ll have to use “real” application with full access to the computer.
0
solved How do I time JavaScript code?