|
[
Permlink
| « Hide
]
Chris Douglas added a comment - 15/May/08 10:20 PM
This returns the same results as the original, save for values <= 0, which neither support.
-1 overall. Here are the results of testing the latest attachment
http://issues.apache.org/jira/secure/attachment/12382141/3398-0.patch against trunk revision 656852. +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/2481/testReport/ This message is automatically generated. -1 overall. Here are the results of testing the latest attachment
http://issues.apache.org/jira/secure/attachment/12382146/3398-1.patch against trunk revision 656852. +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/2482/testReport/ This message is automatically generated. Code looks fine. The values are same for both the implementations. Some comments as to what is done could be useful. I compared the two implementations
Assuming that the map runtime can vary from 300sec to 10,000 secs and the maximum number of times getClosestPowerOf2() will be invoked is 1,000,000. Thanks for the review and benchmarks. It's obvious that this isn't an important optimization (hence "trivial"), but it was a fun problem.
Added some documentation and an explicit check for value leq 0 to make its behavior clearer. if (value < 0), why not return -getClosestPowerOf2(-value-1)?
Mathematically, we should throw an exception (Math.log() returns NaN for -ve numbers and -infinity for 0) when value <= 0 since logarithm is undefined.
-1 overall. Here are the results of testing the latest attachment
http://issues.apache.org/jira/secure/attachment/12382208/3398-2.patch against trunk revision 656939. +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. -1 core tests. The patch failed core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/2493/testReport/ This message is automatically generated.
+1. Alright, alright, you pedants.
+1 3398-3.patch looks good
-1 overall. Here are the results of testing the latest attachment
http://issues.apache.org/jira/secure/attachment/12382331/3398-3.patch against trunk revision 657965. +1 @author. The patch does not contain any @author tags. -1 tests included. The patch doesn't appear to include any new or modified tests. +1 javadoc. The javadoc tool did not generate any warning messages. +1 javac. The applied patch does not increase the total number of javac compiler warnings. +1 findbugs. The patch does not introduce any new Findbugs warnings. +1 release audit. The applied patch does not increase the total number of release audit warnings. +1 core tests. The patch passed core unit tests. +1 contrib tests. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/2500/testReport/ This message is automatically generated. Integrated in Hadoop-trunk #499 (See http://hudson.zones.apache.org/hudson/job/Hadoop-trunk/499/
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||