64-bit shared counter
From: Terje Mathisen (terje.mathisen_at_hda.hydro.com)
Date: 03/23/04
- Next message: Matt Taylor: "Re: 64-bit shared counter"
- Previous message: wolfgang kern: "Re: Question from a newbie: How do you specify an address to jump to in hex?"
- Next in thread: Matt Taylor: "Re: 64-bit shared counter"
- Reply: Matt Taylor: "Re: 64-bit shared counter"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 23 Mar 2004 13:31:56 +0000 (UTC)
(posted AND emailed)
Matt, I implemented and tested my idea for a shared 64-bit (or larger)
counter, when running with two counting threads on a dual 2.8 GHz Xeon
it takes about half a minute to wrap around the low part.
I.e. this corresponds to about 80 ns for each LOCK XADD operation.
It scaled quite nicely, when I ran four counting threads (one for each
virtual cpu on this hyperthreading-enabled machine), it took about 38
seconds.
Assuming this as the worst case, it would take about 5000 seconds for
the same 128 wraparounds that you are testing with now, compared to 70 K
for your current code. Even if you have significantly slower cpus, your
memory interface shouldn't be too dissimilar. What other stuff is going
on here?
Terje
-- - <Terje.Mathisen@hda.hydro.com> "almost all programming can be viewed as an exercise in caching"
- Next message: Matt Taylor: "Re: 64-bit shared counter"
- Previous message: wolfgang kern: "Re: Question from a newbie: How do you specify an address to jump to in hex?"
- Next in thread: Matt Taylor: "Re: 64-bit shared counter"
- Reply: Matt Taylor: "Re: 64-bit shared counter"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]