[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16702772#comment-16702772 ] Zheng Hu commented on HBASE-21459: -- bq. But where do I look to see JMH w/o patch vs JMH w/ patch? [~stack], JMH w/o patch ? you mean want to know what's the extra time cost after introducing checkKeyValueBytes ? In the JMH testing, we can conclude that the extra time cost <= 0.061(us). Thanks. > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, jmh-testing.log, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16702749#comment-16702749 ] stack commented on HBASE-21459: --- Thanks [~openinx] ... But where do I look to see JMH w/o patch vs JMH w/ patch? And as over in the original issue, I'd prefer we avoid double parse of the KV. > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, jmh-testing.log, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16702677#comment-16702677 ] Zheng Hu commented on HBASE-21459: -- Ping [~stack] & [~Apache9] & [~anoop.hbase]. > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, jmh-testing.log, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16701319#comment-16701319 ] Zheng Hu commented on HBASE-21459: -- [~stack], I made two test: 1. benchmark the checkKeyValueBytes() method by using JMH framework to exclude the JIT's impact. the result is here: https://issues.apache.org/jira/secure/attachment/12949680/jmh-testing.log . I think we can mainly focuse on the last part in the result, it means the avg time cost after call the checkKeyValueBytes multiple times (diff rowKey, tagSize, valuleLen etc..) {code} Benchmark(input) Mode Cnt ScoreError Units TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 1,1,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 1,100,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 1,1,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes10,1,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 10,100,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes10,1,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,1,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,100,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,1,0 avgt 10 0.024 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 1,1,1 avgt 10 0.029 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 1,100,1 avgt 10 0.030 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 1,1,1 avgt 10 0.029 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes10,1,1 avgt 10 0.030 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 10,100,1 avgt 10 0.030 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes10,1,1 avgt 10 0.029 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,1,1 avgt 10 0.030 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,100,1 avgt 10 0.029 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,1,1 avgt 10 0.029 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes1,1,10 avgt 10 0.062 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 1,100,10 avgt 10 0.060 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes1,1,10 avgt 10 0.060 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 10,1,10 avgt 10 0.060 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 10,100,10 avgt 10 0.061 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 10,1,10 avgt 10 0.061 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,1,10 avgt 10 0.061 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes100,100,10 avgt 10 0.061 ± 0.001 us/op TestCheckKeyValueBytes.benchmarkCheckKeyValueBytes 100,1,10 avgt 10 0.061 ± 0.001 us/op {code} 2. benchmark the checkKeyValueBytes method directly by using patch [1], the result is here: [2]. Also indicate: in diff cases (rowLen, valueLen, tagSize, rowSize), the avg time cost (ns/op) after call the method multiple times. Currently, I'm focusing on testing the single method, not by starting cluster with the validatation patch or without patch... I think the single method performance is enough to proof that it has minor impact on the read/write performance. Thanks. 1. https://issues.apache.org/jira/secure/attachment/12949036/0002-Benchmark-the-checkKeyValueBytes.patch 2. https://issues.apache.org/jira/secure/attachment/12949038/result.txt > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, jmh-testing.log, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16700858#comment-16700858 ] stack commented on HBASE-21459: --- Thanks. How do I read the result? How do I read before and after? > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, jmh-testing.log, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16700421#comment-16700421 ] Zheng Hu commented on HBASE-21459: -- Testing method: {code} git am 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch git am 0001-Benchmark-the-checkKeyValueBytes.patch mvn clean package assembly:single -DskipTests nohup ./bin/hbase org.apache.hadoop.hbase.codec.TestCheckKeyValueBytes > jmh-testing.log 2>&1 & {code} > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, jmh-testing.log, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16700410#comment-16700410 ] Zheng Hu commented on HBASE-21459: -- Upload the result which tested by useing the JMH patch 0001-Benchmark-the-checkKeyValueBytes.patch. The avg time cost is about 0.006(us), we can conclude that the checkKeyValueBytes should not be much impact on the performance. [~stack], [~Apache9], [~anoop.hbase], FYI. > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, jmh-testing.log, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16700241#comment-16700241 ] Zheng Hu commented on HBASE-21459: -- Uploaded a patch to benchmark the checkKeyValueBytes by using JMH (Exclude the impact from JIT). > More benchmark for evaluating the checkKeyValueBytes's performance > -- > > Key: HBASE-21459 > URL: https://issues.apache.org/jira/browse/HBASE-21459 > Project: HBase > Issue Type: Sub-task >Reporter: Zheng Hu >Assignee: Zheng Hu >Priority: Major > Attachments: 0001-Benchmark-the-checkKeyValueBytes.patch, > 0001-HBASE-21401-Sanity-check-in-BaseDecoder-parseCell.patch, > 0002-Benchmark-the-checkKeyValueBytes.patch, result.txt > > > See : > https://issues.apache.org/jira/browse/HBASE-21401?focusedCommentId=16678091=com.atlassian.jira.plugin.system.issuetabpanels%3Acomment-tabpanel#comment-16678091 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (HBASE-21459) More benchmark for evaluating the checkKeyValueBytes's performance
[ https://issues.apache.org/jira/browse/HBASE-21459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16694612#comment-16694612 ] Zheng Hu commented on HBASE-21459: -- I made a benchmark by using the attached two patches. the result are following: {code} ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 0]: cost 24.455735 ms. AverageTime: 244.557350 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 10, rowSize: 10, tagSize: 0]: cost 4.169941 ms. AverageTime: 41.699410 ns/op. ==> Case#[rowKeyLen: 1, valueLen:100, rowSize: 10, tagSize: 0]: cost 9.161555 ms. AverageTime: 91.615550 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1000, rowSize: 10, tagSize: 0]: cost 14.971228 ms. AverageTime: 149.712280 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 0]: cost 16.853123 ms. AverageTime: 168.531230 ns/op. ==> Case#[rowKeyLen: 10, valueLen: 1, rowSize: 10, tagSize: 0]: cost 2.649421 ms. AverageTime: 26.494210 ns/op. ==> Case#[rowKeyLen: 10, valueLen: 10, rowSize: 10, tagSize: 0]: cost 2.682410 ms. AverageTime: 26.824100 ns/op. ==> Case#[rowKeyLen: 10, valueLen:100, rowSize: 10, tagSize: 0]: cost 6.160953 ms. AverageTime: 61.609530 ns/op. ==> Case#[rowKeyLen: 10, valueLen: 1000, rowSize: 10, tagSize: 0]: cost 11.206499 ms. AverageTime: 112.064990 ns/op. ==> Case#[rowKeyLen: 10, valueLen: 1, rowSize: 10, tagSize: 0]: cost 17.023290 ms. AverageTime: 170.232900 ns/op. ==> Case#[rowKeyLen:100, valueLen: 1, rowSize: 10, tagSize: 0]: cost 7.058629 ms. AverageTime: 70.586290 ns/op. ==> Case#[rowKeyLen:100, valueLen: 10, rowSize: 10, tagSize: 0]: cost 8.355807 ms. AverageTime: 83.558070 ns/op. ==> Case#[rowKeyLen:100, valueLen:100, rowSize: 10, tagSize: 0]: cost 11.544705 ms. AverageTime: 115.447050 ns/op. ==> Case#[rowKeyLen:100, valueLen: 1000, rowSize: 10, tagSize: 0]: cost 11.213508 ms. AverageTime: 112.135080 ns/op. ==> Case#[rowKeyLen:100, valueLen: 1, rowSize: 10, tagSize: 0]: cost 18.694530 ms. AverageTime: 186.945300 ns/op. ==> Case#[rowKeyLen: 1000, valueLen: 1, rowSize: 10, tagSize: 0]: cost 11.008197 ms. AverageTime: 110.081970 ns/op. ==> Case#[rowKeyLen: 1000, valueLen: 10, rowSize: 10, tagSize: 0]: cost 15.400079 ms. AverageTime: 154.000790 ns/op. ==> Case#[rowKeyLen: 1000, valueLen:100, rowSize: 10, tagSize: 0]: cost 13.814295 ms. AverageTime: 138.142950 ns/op. ==> Case#[rowKeyLen: 1000, valueLen: 1000, rowSize: 10, tagSize: 0]: cost 16.416853 ms. AverageTime: 164.168530 ns/op. ==> Case#[rowKeyLen: 1000, valueLen: 1, rowSize: 10, tagSize: 0]: cost 19.091859 ms. AverageTime: 190.918590 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 0]: cost 17.234383 ms. AverageTime: 172.343830 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 10, rowSize: 10, tagSize: 0]: cost 17.164031 ms. AverageTime: 171.640310 ns/op. ==> Case#[rowKeyLen: 1, valueLen:100, rowSize: 10, tagSize: 0]: cost 18.860970 ms. AverageTime: 188.609700 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1000, rowSize: 10, tagSize: 0]: cost 19.732930 ms. AverageTime: 197.329300 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 0]: cost 22.953708 ms. AverageTime: 229.537080 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 1]: cost 26.222976 ms. AverageTime: 262.229760 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 1]: cost 17.838703 ms. AverageTime: 178.387030 ns/op. ==> Case#[rowKeyLen: 10, valueLen: 1, rowSize: 10, tagSize: 1]: cost 9.773222 ms. AverageTime: 97.732220 ns/op. ==> Case#[rowKeyLen: 10, valueLen: 1, rowSize: 10, tagSize: 1]: cost 18.582515 ms. AverageTime: 185.825150 ns/op. ==> Case#[rowKeyLen:100, valueLen: 1, rowSize: 10, tagSize: 1]: cost 12.375640 ms. AverageTime: 123.756400 ns/op. ==> Case#[rowKeyLen:100, valueLen: 1, rowSize: 10, tagSize: 1]: cost 22.710159 ms. AverageTime: 227.101590 ns/op. ==> Case#[rowKeyLen: 1000, valueLen: 1, rowSize: 10, tagSize: 1]: cost 15.640302 ms. AverageTime: 156.403020 ns/op. ==> Case#[rowKeyLen: 1000, valueLen: 1, rowSize: 10, tagSize: 1]: cost 24.651799 ms. AverageTime: 246.517990 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 1]: cost 21.160981 ms. AverageTime: 211.609810 ns/op. ==> Case#[rowKeyLen: 1, valueLen: 1, rowSize: 10, tagSize: 1]: cost 27.480982 ms.