the nerd
2008-03-24 10:48:23
Yes this is another prime finder, but I didn't copy code, i created it from scratch. (I only discovered that there are other when I posted this).
I created the script as a demostration of what I call "multi-script". The first thing you will notice is that there two scripts involved not one (i dont no if any one else has tried this). This allowes to run a slow bit of code at the same time as a fast bit of code without slowing down thee fast bit of code. I relies on the SCAR's inter SCAR messaging ability.
The script can run both in "multi-script" mode or single script mode (except the report client). In this script all of the reports are handled by a client script. This is because creating the report takes alot of time compared to finding prime numbers.
To use multi-script mode open prime finder script in one window, and the report client in a second window. (Must be different windows, not tabs!!!!)
Start the script in any order, they will wait for each other for up to a minute. You can sart the report client even if the prime finder is running, they will detect each other and switch to multi-script mode.
If the report client stops then the prime finder will switch to single script mode. If the prime finder stops then the report client will terminate.
If you download the script can you please post benchmarks.
Post the following information.
Time taken to discover 10,000 primes in multi-script mode.
Time taken to discover 10,000 primes in single-script mode.
CPU configeration:
Hyper threading
Multi-core (number of cores)
Single core (nothing special)
EDIT: I have uploaded a new version with an auto benchmark.
EDIT: Current Script does not work. Will update at a later date. Sorry
I created the script as a demostration of what I call "multi-script". The first thing you will notice is that there two scripts involved not one (i dont no if any one else has tried this). This allowes to run a slow bit of code at the same time as a fast bit of code without slowing down thee fast bit of code. I relies on the SCAR's inter SCAR messaging ability.
The script can run both in "multi-script" mode or single script mode (except the report client). In this script all of the reports are handled by a client script. This is because creating the report takes alot of time compared to finding prime numbers.
To use multi-script mode open prime finder script in one window, and the report client in a second window. (Must be different windows, not tabs!!!!)
Start the script in any order, they will wait for each other for up to a minute. You can sart the report client even if the prime finder is running, they will detect each other and switch to multi-script mode.
If the report client stops then the prime finder will switch to single script mode. If the prime finder stops then the report client will terminate.
If you download the script can you please post benchmarks.
Post the following information.
Time taken to discover 10,000 primes in multi-script mode.
Time taken to discover 10,000 primes in single-script mode.
CPU configeration:
Hyper threading
Multi-core (number of cores)
Single core (nothing special)
EDIT: I have uploaded a new version with an auto benchmark.
EDIT: Current Script does not work. Will update at a later date. Sorry