[slf4j-dev] svn commit: r1210 - slf4j/trunk/slf4j-api/src/test/java/org/slf4j/helpers

Thorbjørn Ravn Andersen ravn at runjva.com
Mon Oct 27 19:36:47 CET 2008


Ceki Gulcu skrev:
>
> Thorbjørn Ravn Andersen wrote:
>   
>> Ceki Gulcu skrev:
>>     
>>> Thorbjørn Ravn Andersen wrote:
>>>   
>>>       
>>>> I have been wondering what exactly it is that you are trying to do?  Is 
>>>> it trying to establish a unit for CPU usage from which you can establish 
>>>> an upper bound for how long a given test may take?
>>>>     
>>>>         
>>> Something like that. By measure the time it takes to perform a number of 
>>> operations (combination of random number generation and sorting), we can roughly 
>>> estimate the power of the host CPU. It then becomes possible to calibrate 
>>> performance tests.
>>>   
>>>       
>> I think that this approach is too brittle to handle the advances in 
>> hardware and JIT technology without eventually breaking.
>>     
>
> I do not thing the present approach is too brittle to take advantage of the 
> hardware and advances in JIT technology. The numbers should actually evolve with 
> advances JIT technology and/or hardware. From your previous message, I was under 
> the impression that you had not read the code. Have you read the code?
>
>   
Superficially.  It looked to me as you were calibrating using a sort 
(due to the checkins handling the different algorithms in the Windows 
and Linux JVM's), which may or may not be relevant for logging 
performance as the operations done are different.
>> How about setting an absolute time limit for each test after which a 
>> watchdog kills it to avoid infinite looping, and then simply measure 
>> each test, collect the test results as well as your basic time unit, and 
>> then do an analysis afterwards?  The build should only break if the hard 
>> limits were reached.
>>     
>
> As far as I am concerned, and unless evidence suggests otherwise, the current 
> tests are fine.
>
>   
>> Otherwise you may have a situation where people may be unable to build 
>> from source :-S
>>     
>
> Are you speculating or has this happened to you? If you are
> speculating, I mean no offense, but I rather we invested our resources
> elsewhere rather than in hypotheticals. However, if you have actually
> had trouble building SLF4J, please tell me more.
>   
Yes.  I had a performance test fail on me, otherwise I would not have 
brought up the issue.

It was a while ago so I believe that it was on my elderly Pentium II 
Linux box at work.  It does not happen on my MacBook.  I'll have a look.


/Thorbjørn



More information about the slf4j-dev mailing list