Re: The thread ring problem

2009-05-29 Thread Kevin Downey
t; (/ (- 24319344452689 22651751153117) 600.0) >>> > 27.79322165954 >>> >>> > 2009/5/29 Christian Vest Hansen >>> >>> >> On Fri, May 29, 2009 at 4:29 PM, Laurent PETIT >>> >> wrote: >>> >> > when I t

Re: The thread ring problem

2009-05-29 Thread Laurent PETIT
ed for the benchmark) >> >> >> Oh, right. I only noticed the 1000 mentioned at the bottom. Also, the >> >> (time ...) makes no sense. >> >> >> > How would one fix this? >> >> >> With a CountDownLatch? That's what I'

Re: The thread ring problem

2009-05-29 Thread Sean Devlin
> > 2009/5/29 Christian Vest Hansen : > > >> >> For kicks, I made an implementation* using agents: > > >> >>http://gist.github.com/119946 > > >> >> I think that you may not want to use the STM so much and instead > >> >> figur

Re: The thread ring problem

2009-05-29 Thread Laurent PETIT
http://gist.github.com/119946 >> >> >> >> I think that you may not want to use the STM so much and instead >> >> figure out a different approach to sending the token around the ring. >> >> >> >> *it may be a bit liberal in its inter

Re: The thread ring problem

2009-05-29 Thread Alvaro Vilanova Vidal
erent approach to sending the token around the ring. > >> > >> *it may be a bit liberal in its interpretation of the rules... didn't > >> read them that carefully. > >> > >> On Fri, May 29, 2009 at 2:32 PM, Alvaro Vilanova Vidal < > alv...@gmai

Re: The thread ring problem

2009-05-29 Thread Christian Vest Hansen
aro Vilanova Vidal >> wrote: >>> >>> Hi everyone, >>> I am a newbie in clojure world, so I have some newbie's questions :) To >>> learn about clojure, I am trying to do the thread ring problem of clgb in >>> clojure. The rules of problem are here,

Re: The thread ring problem

2009-05-29 Thread Michael Wood
On Fri, May 29, 2009 at 3:29 PM, Christian Vest Hansen wrote: > > For kicks, I made an implementation* using agents: > > http://gist.github.com/119946 The call to time returns almost immediately and the actual result takes much longer to appear (with large values of token). How would one fix th

Re: The thread ring problem

2009-05-29 Thread Laurent PETIT
32 PM, Alvaro Vilanova Vidal >> wrote: >>> >>> Hi everyone, >>> I am a newbie in clojure world, so I have some newbie's questions :) To >>> learn about clojure, I am trying to do the thread ring problem of clgb in >>> clojure. The rules of problem

Re: The thread ring problem

2009-05-29 Thread Laurent PETIT
rules... didn't > read them that carefully. > > On Fri, May 29, 2009 at 2:32 PM, Alvaro Vilanova Vidal > wrote: >> >> Hi everyone, >> I am a newbie in clojure world, so I have some newbie's questions :) To >> learn about clojure, I am trying to do the th

Re: The thread ring problem

2009-05-29 Thread graham
Have you seen the example on the agents page of the main clojure site? http://clojure.org/agents --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegrou

Re: The thread ring problem

2009-05-29 Thread Christian Vest Hansen
read them that carefully. On Fri, May 29, 2009 at 2:32 PM, Alvaro Vilanova Vidal wrote: > > Hi everyone, > I am a newbie in clojure world, so I have some newbie's questions :) To > learn about clojure, I am trying to do the thread ring problem of clgb in > clojure. The rules of

The thread ring problem

2009-05-29 Thread Alvaro Vilanova Vidal
Hi everyone, I am a newbie in clojure world, so I have some newbie's questions :) To learn about clojure, I am trying to do the thread ring problem of clgb in clojure. The rules of problem are here<http://shootout.alioth.debian.org/u64q/benchmark.php?test=threadring&lang=all#about>,