ilovesoup / hyracks

Automatically exported from code.google.com/p/hyracks
Apache License 2.0
0 stars 0 forks source link

Division by zero in some tree tests #130

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
[What steps will reproduce the problem?]
Just run 'mvn clean install' on this particular machine (Centos 6 x64, Oracle 
JVM 7u45 via RPM). Tests will fail with this error. 

I am fairly certain this is due to the rather absurd number of processors 
available on the machine this occurs on (2x6core HT = 24 presented processors). 
In OrderedIndexMultiThreadTest:47, EXCESSIVE_NUM_THREADS is set to the number 
of processors times four. batchSize is defined at line 88 to be 
(NUM_OPERATIONS/numThreads)/4. 
So with 24 available processors, with EXCESSIVE_NUM_THREADS this yields  a 
batchSize of 0.520 which is turned into a 0 when cast to an int . Then, when 
this is passed to IndexMultiThreadTestDriver, line 50 fails because of numOps 
being divided by 0.  

Changing the NUM_THREADS for each kind of test in AccessMethodTestsConfig from 
200 to something higher that won't yield a batchSize<0 (e.x. 800) seems to stop 
this from happening. 

Original issue reported on code.google.com by ima...@uci.edu on 14 Jan 2014 at 11:42

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by ima...@uci.edu on 17 Jan 2014 at 8:32

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
possible patch

Original comment by westm...@gmail.com on 10 Mar 2014 at 10:46

Attachments:

GoogleCodeExporter commented 9 years ago
The patch looks correct to me. Added to master. Also it's been verified on a 
machine with 32 cores (by Till).

Original comment by zheilb...@gmail.com on 10 Mar 2014 at 11:51