aboutsummaryrefslogtreecommitdiff
path: root/bench.tcl
diff options
context:
space:
mode:
authorantirez <antirez>2005-02-27 14:04:40 +0000
committerantirez <antirez>2005-02-27 14:04:40 +0000
commitaa9c81b676276a6367b8e30a40073569251c49fe (patch)
treefa4e8c0bf088965a942152675cebf4571ba9fd77 /bench.tcl
parent3b61d32c6d192a7200dbe76f4ba19dd4bc0aef4e (diff)
downloadjimtcl-aa9c81b676276a6367b8e30a40073569251c49fe.zip
jimtcl-aa9c81b676276a6367b8e30a40073569251c49fe.tar.gz
jimtcl-aa9c81b676276a6367b8e30a40073569251c49fe.tar.bz2
Pat's patch for [load] on win32!
Pat's match for nan/inf modified a bit.
Diffstat (limited to 'bench.tcl')
-rw-r--r--bench.tcl11
1 files changed, 11 insertions, 0 deletions
diff --git a/bench.tcl b/bench.tcl
index 6479599..37a905a 100644
--- a/bench.tcl
+++ b/bench.tcl
@@ -176,6 +176,16 @@ proc nestedloops {} {
}
}
+### ROTATE #####################################################################
+
+proc rotate {count} {
+ set v 1
+ for {set n 0} {$n < $count} {incr n} {
+ set v [expr {$v <<< 1}]
+ }
+}
+
+
### RUN ALL ####################################################################
bench {busy loop} {x}
@@ -186,3 +196,4 @@ bench {ary} {ary 100000}
bench {repeat} {use_repeat}
bench {upvar} {upvartest}
bench {nested loops} {nestedloops}
+bench {rotate} {rotate 100000} \ No newline at end of file