[ 
https://issues.apache.org/jira/browse/LANG-1576?focusedWorklogId=468406&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-468406
 ]

ASF GitHub Bot logged work on LANG-1576:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 10/Aug/20 04:52
            Start Date: 10/Aug/20 04:52
    Worklog Time Spent: 10m 
      Work Description: XenoAmess edited a comment on pull request #565:
URL: https://github.com/apache/commons-lang/pull/565#issuecomment-671160146


   Hi.
   I re-changed some codes and run a performance test.
   In short,
   ```
   Benchmark                                          (data)  (name)  Mode  Cnt 
     Score      Error  Units
   StringUtilsChompTest.singleString                    NULL     old  avgt    5 
     2.751 ?   0.091  ns/op
   
   StringUtilsChompTest.singleString                    NULL     new  avgt    5 
     2.767 ?   0.182  ns/op
   
   StringUtilsChompTest.singleString                   CHAR0     old  avgt    5 
     3.687 ?   2.040  ns/op
   
   StringUtilsChompTest.singleString                   CHAR0     new  avgt    5 
     3.221 ?   0.070  ns/op
   
   StringUtilsChompTest.singleString                CHAR0_CR     old  avgt    5 
     3.757 ?   0.249  ns/op
   
   StringUtilsChompTest.singleString                CHAR0_CR     new  avgt    5 
     3.718 ?   0.171  ns/op
   
   StringUtilsChompTest.singleString                CHAR0_LF     old  avgt    5 
     3.780 ?   0.362  ns/op
   
   StringUtilsChompTest.singleString                CHAR0_LF     new  avgt    5 
     3.829 ?   0.456  ns/op
   
   StringUtilsChompTest.singleString             CHAR0_CR_LF     old  avgt    5 
     9.466 ?   0.550  ns/op
   
   StringUtilsChompTest.singleString             CHAR0_CR_LF     new  avgt    5 
     9.506 ?   0.441  ns/op
   
   StringUtilsChompTest.singleString                   CHAR1     old  avgt    5 
     4.035 ?   1.104  ns/op
   
   StringUtilsChompTest.singleString                   CHAR1     new  avgt    5 
     3.780 ?   0.239  ns/op
   
   StringUtilsChompTest.singleString                CHAR1_CR     old  avgt    5 
    18.910 ?   2.074  ns/op
   
   StringUtilsChompTest.singleString                CHAR1_CR     new  avgt    5 
    19.492 ?   1.942  ns/op
   
   StringUtilsChompTest.singleString                CHAR1_LF     old  avgt    5 
    19.429 ?   1.860  ns/op
   
   StringUtilsChompTest.singleString                CHAR1_LF     new  avgt    5 
    22.080 ?   6.952  ns/op
   
   StringUtilsChompTest.singleString             CHAR1_CR_LF     old  avgt    5 
    22.026 ?   2.968  ns/op
   
   StringUtilsChompTest.singleString             CHAR1_CR_LF     new  avgt    5 
    18.868 ?   1.075  ns/op
   
   StringUtilsChompTest.singleString                   CHAR2     old  avgt    5 
     4.068 ?   0.168  ns/op
   
   StringUtilsChompTest.singleString                   CHAR2     new  avgt    5 
     3.896 ?   0.361  ns/op
   
   StringUtilsChompTest.singleString                CHAR2_CR     old  avgt    5 
    17.723 ?   0.809  ns/op
   
   StringUtilsChompTest.singleString                CHAR2_CR     new  avgt    5 
    19.235 ?   0.502  ns/op
   
   StringUtilsChompTest.singleString                CHAR2_LF     old  avgt    5 
    21.363 ?   1.176  ns/op
   
   StringUtilsChompTest.singleString                CHAR2_LF     new  avgt    5 
    21.182 ?   1.029  ns/op
   
   StringUtilsChompTest.singleString             CHAR2_CR_LF     old  avgt    5 
    21.532 ?   1.032  ns/op
   
   StringUtilsChompTest.singleString             CHAR2_CR_LF     new  avgt    5 
    21.420 ?   2.569  ns/op
   
   StringUtilsChompTest.test_Random_Strings_New          N/A     N/A  avgt    5 
 70565.068 ?2096.854  ns/op
   
   StringUtilsChompTest.test_Random_Strings_Old          N/A     N/A  avgt    5 
 77950.673 ?2115.093  ns/op
   ```
    detailed report at https://pastebin.ubuntu.com/p/bTNkPGpSpV/
   
   @sebbASF yes, the performance test shows the original condition struction is 
not bad as I thought at beginning, and revert to original condition struction 
will not harm performance.
   so according to the "minimal change" principle, I changed the codes to looks 
more likely to original.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 468406)
    Time Spent: 5.5h  (was: 5h 20m)

> refine StringUtils.chomp
> ------------------------
>
>                 Key: LANG-1576
>                 URL: https://issues.apache.org/jira/browse/LANG-1576
>             Project: Commons Lang
>          Issue Type: Sub-task
>            Reporter: Jin Xu
>            Priority: Minor
>          Time Spent: 5.5h
>  Remaining Estimate: 0h
>
> [https://github.com/apache/commons-lang/pull/565]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to