Cuberite Forum
r245 question - Printable Version

+- Cuberite Forum (https://forum.cuberite.org)
+-- Forum: Cuberite (https://forum.cuberite.org/forum-4.html)
+--- Forum: Development (https://forum.cuberite.org/forum-13.html)
+--- Thread: r245 question (/thread-336.html)



r245 question - tbar - 02-10-2012

In revision 245 the log message states:
Quote:Author: madmaxoft: MTRand class is not created in each tick, therefore much improving tick-thread time (now uses ~5 % CPU instead of one full core)

This sounds like a massive improvement but is it? How should I interpret the message above?


RE: r245 question - xoft - 02-10-2012

I'ts not really massive, but still is quite a lot Smile

On my QuadCore, the tick thread was hogging one core all the time (-> 25 % total CPU) before the change. After the change, the thread is using only about 5 % of the total CPU. Both values were measured with 1 player on the server, 17 chunks viewdistance.

This means that it now runs at least 5 times faster, maybe even more, because a thread can't run faster than one-core-at-a-time.

Note, however, that this was a debug build. In a release build this needn't be so noticable.


RE: r245 question - FakeTruth - 02-10-2012

It was even worse on Linux before, because the Linux version of MTRand reads a file each time it's createdTongue


RE: r245 question - tbar - 02-10-2012

That _does_ sound massiveBig Grin