The SpiderMonkey js shell supports passing command line arguments to the scripts being executed by way of a global 'arguments' variable.
Created attachment 19310 [details] work in progress
Created attachment 19328 [details] patch
This definitely works well, and allowed generation of performance data for http://shootout.alioth.debian.org
Comment on attachment 19328 [details] patch r=me, provided you ensure run-javscriptcore-tests and run-sunspider still work correctly
Created attachment 19330 [details] updated patch
Created attachment 19331 [details] updated without build issues
Comment on attachment 19331 [details] updated without build issues r=me
Landed in r30553.