I like that kind of noise because these numbers are very informative. And they 
show that pharo can be used in heavy scenarios, too

> Am 10.12.2017 um 19:14 schrieb Sven Van Caekenberghe <[email protected]>:
> 
> @ Henrik
> 
> Arg, arg, arg, yes of course. 
> I actually did think about that, but still did not look carefully enough !! 
> Really stupid of me.
> 
> It is even worse because I wrote that code ...
> 
> Now, the #printOn: of BenchmarkResult is much clearer, less confusing:
> 
> ZnClient new in: [ :client |
>    [ client get: 'http://localhost:8080' ] benchFor: 5 seconds ]. 
> 
> a BenchmarkResult(14,732 iterations in 5 seconds. 2,946 per second)
> 
> vs
> 
> ZnClient new in: [ :client |
>    client loggingOff.
>    [ client get: 'http://localhost:8080' ] benchFor: 5 seconds ].
> 
> a BenchmarkResult(42 iterations in 5 seconds 88 milliseconds. 8.255 per 
> second)
> 
> Still the same issue with $, and $. in frequency, but the iteration count is 
> crystal clear.
> 
> The reason #bench works like that is backwards compatibility at the time we 
> introduced that.
> 
> @ Ben
> 
> Yes, I should have looked at the other side as well, to confirm things 
> actually happened as I imagined them (the did not).
> 
> Thx and sorry for the noise.
> 
> Sven
> 
>> On 10 Dec 2017, at 18:00, Henrik-Nergaard <[email protected]> wrote:
>> 
>> Hi Sven,
>> 
>> What you are seeing is most likely a $, vs $. issue.
>> See BenchmarkResult >>#printFrequenceOn: it uses both decimal and thousand
>> separators.
>> 
>> If i run this code:
>> -----------------------------------------
>> | counter |
>> counter :=
>> ZnClient new in: [ :client |
>> client loggingOff.
>> [ client get: 'http://localhost:8080'. counter ] bench 
>> ].
>> counter.
>> -----------------------------------------
>> 
>> Then i get 9035 ('1,773 per second') when no inspector is open, and only 22
>> ('5.995 per second') when inspecting the logs.
>> 
>> Best regards,
>> Henrik
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> --
>> Sent from: http://forum.world.st/Pharo-Smalltalk-Developers-f1294837.html
>> 

Reply via email to