Simple messages-per-second test (~195kHz at present)

This commit is contained in:
Tony Garnock-Jones 2018-04-08 12:06:37 +01:00
parent eb24d566e9
commit bd9dcb61ca
1 changed files with 9 additions and 1 deletions

View File

@ -626,6 +626,13 @@
(lambda ()
(schedule-script!
(current-dataspace)
#;(lambda ()
(spawn (on (message $v)
(if (= v 10000000)
(stop-current-facet)
(send! (+ v 1))))
(on-start (send! 0)))
)
(lambda ()
(spawn (field [current-value 0])
(assert (box-state (current-value)))
@ -640,7 +647,8 @@
(on (asserted (box-state $v))
(log-info "client: learned that box's value is now ~v" v)
(send! (set-box (+ v 1)))))
)))))
)
))))
(require racket/pretty)
;; (pretty-print ds)