urlyy opened a new pull request, #2716:
URL: https://github.com/apache/fory/pull/2716

   
   ## What does this PR do?
   Use SIMD to se/de string
   
   ## Related issues
   close #2713 
   close #2658
   
   ## Benchmark
   ```
   Write Latin-1 SIMD size 100
                           time:   [119.07 ns 119.88 ns 120.74 ns]
   Found 1 outliers among 100 measurements (1.00%)
     1 (1.00%) high mild
   
   Write Latin-1 Standard size 100
                           time:   [327.71 ns 329.71 ns 332.30 ns]
   Found 9 outliers among 100 measurements (9.00%)
     8 (8.00%) high mild
     1 (1.00%) high severe
   
   Write Latin-1 SIMD size 1000
                           time:   [826.19 ns 827.90 ns 829.97 ns]
   Found 1 outliers among 100 measurements (1.00%)
     1 (1.00%) high mild
   
   Write Latin-1 Standard size 1000
                           time:   [2.3436 µs 2.3459 µs 2.3488 µs]
   Found 8 outliers among 100 measurements (8.00%)
     1 (1.00%) low mild
     4 (4.00%) high mild
     3 (3.00%) high severe
   
   Write Latin-1 SIMD size 10000
                           time:   [7.0065 µs 7.0100 µs 7.0138 µs]
   Found 2 outliers among 100 measurements (2.00%)
     1 (1.00%) high mild
     1 (1.00%) high severe
   
   Write Latin-1 Standard size 10000
                           time:   [21.003 µs 21.030 µs 21.064 µs]
   Found 11 outliers among 100 measurements (11.00%)
     1 (1.00%) low mild
     3 (3.00%) high mild
     7 (7.00%) high severe
   
   Write Latin-1 SIMD size 100000
                           time:   [71.804 µs 71.995 µs 72.170 µs]
   Found 2 outliers among 100 measurements (2.00%)
     1 (1.00%) low mild
     1 (1.00%) high mild
   
   Write Latin-1 Standard size 100000
                           time:   [211.09 µs 211.51 µs 211.93 µs]
   Found 5 outliers among 100 measurements (5.00%)
     2 (2.00%) low mild
     1 (1.00%) high mild
     2 (2.00%) high severe
   
   Write UTF-8 SIMD size 100
                           time:   [136.54 ns 136.63 ns 136.74 ns]
   Found 8 outliers among 100 measurements (8.00%)
     6 (6.00%) high mild
     2 (2.00%) high severe
   
   Write UTF-8 Standard size 100
                           time:   [4.2362 µs 4.2396 µs 4.2431 µs]
   Found 6 outliers among 100 measurements (6.00%)
     1 (1.00%) low mild
     4 (4.00%) high mild
     1 (1.00%) high severe
   
   Write UTF-8 SIMD size 1000
                           time:   [1.2469 µs 1.2498 µs 1.2533 µs]
   Found 7 outliers among 100 measurements (7.00%)
     1 (1.00%) low mild
     5 (5.00%) high mild
     1 (1.00%) high severe
   
   Write UTF-8 Standard size 1000
                           time:   [39.329 µs 39.369 µs 39.430 µs]
   Found 13 outliers among 100 measurements (13.00%)
     1 (1.00%) low mild
     5 (5.00%) high mild
     7 (7.00%) high severe
   
   Write UTF-8 SIMD size 10000
                           time:   [12.243 µs 12.254 µs 12.266 µs]
   Found 6 outliers among 100 measurements (6.00%)
     3 (3.00%) high mild
     3 (3.00%) high severe
   
   Write UTF-8 Standard size 10000
                           time:   [400.42 µs 401.68 µs 403.37 µs]
   Found 11 outliers among 100 measurements (11.00%)
     1 (1.00%) low mild
     3 (3.00%) high mild
     7 (7.00%) high severe
   
   Write UTF-8 SIMD size 100000
                           time:   [189.73 µs 190.37 µs 191.04 µs]
   Found 12 outliers among 100 measurements (12.00%)
     10 (10.00%) high mild
     2 (2.00%) high severe
   
   Write UTF-8 Standard size 100000
                           time:   [4.0438 ms 4.0524 ms 4.0617 ms]
   Found 2 outliers among 100 measurements (2.00%)
     1 (1.00%) high mild
     1 (1.00%) high severe
   
   Write UTF-16 SIMD size 100
                           time:   [1.6355 µs 1.6384 µs 1.6420 µs]
   Found 8 outliers among 100 measurements (8.00%)
     3 (3.00%) high mild
     5 (5.00%) high severe
   
   Write UTF-16 Standard size 100
                           time:   [4.7163 µs 4.7338 µs 4.7535 µs]
   Found 5 outliers among 100 measurements (5.00%)
     2 (2.00%) high mild
     3 (3.00%) high severe
   
   Write UTF-16 SIMD size 1000
                           time:   [14.996 µs 15.017 µs 15.039 µs]
   Found 4 outliers among 100 measurements (4.00%)
     3 (3.00%) high mild
     1 (1.00%) high severe
   
   Write UTF-16 Standard size 1000
                           time:   [41.669 µs 41.742 µs 41.827 µs]
   Found 5 outliers among 100 measurements (5.00%)
     5 (5.00%) high mild
   
   Write UTF-16 SIMD size 10000
                           time:   [145.72 µs 146.24 µs 146.81 µs]
   Found 2 outliers among 100 measurements (2.00%)
     1 (1.00%) high mild
     1 (1.00%) high severe
   
   Write UTF-16 Standard size 10000
                           time:   [437.97 µs 452.79 µs 471.40 µs]
   Found 13 outliers among 100 measurements (13.00%)
     4 (4.00%) high mild
     9 (9.00%) high severe
   
   Benchmarking Write UTF-16 SIMD size 100000: Warming up for 3.0000 s
   Warning: Unable to complete 100 samples in 5.0s. You may wish to increase 
target time to 9.3s, enable flat sampling, or reduce sample count to 50.
   Write UTF-16 SIMD size 100000
                           time:   [1.7727 ms 1.7795 ms 1.7878 ms]
   Found 6 outliers among 100 measurements (6.00%)
     6 (6.00%) high mild
   
   Write UTF-16 Standard size 100000
                           time:   [4.7168 ms 4.7426 ms 4.7709 ms]
   Found 4 outliers among 100 measurements (4.00%)
     2 (2.00%) low mild
     1 (1.00%) high mild
     1 (1.00%) high severe
   
   ```
   
   ```
   Read Latin-1 SIMD size 100
                           time:   [28.438 ns 28.466 ns 28.493 ns]
   Found 3 outliers among 100 measurements (3.00%)
     1 (1.00%) low mild
     1 (1.00%) high mild
     1 (1.00%) high severe
   
   Read Latin-1 Standard size 100
                           time:   [239.24 ns 239.80 ns 240.55 ns]
   Found 7 outliers among 100 measurements (7.00%)
     4 (4.00%) high mild
     3 (3.00%) high severe
   
   Read Latin-1 SIMD size 1000
                           time:   [66.150 ns 66.183 ns 66.222 ns]
   Found 4 outliers among 100 measurements (4.00%)
     2 (2.00%) high mild
     2 (2.00%) high severe
   
   Read Latin-1 Standard size 1000
                           time:   [2.2034 µs 2.2050 µs 2.2066 µs]
   Found 6 outliers among 100 measurements (6.00%)
     1 (1.00%) low mild
     4 (4.00%) high mild
     1 (1.00%) high severe
   
   Read Latin-1 SIMD size 10000
                           time:   [503.37 ns 506.51 ns 509.43 ns]
   Found 19 outliers among 100 measurements (19.00%)
     19 (19.00%) high mild
   
   Read Latin-1 Standard size 10000
                           time:   [21.271 µs 21.316 µs 21.370 µs]
   Found 2 outliers among 100 measurements (2.00%)
     2 (2.00%) high mild
   
   Read Latin-1 SIMD size 100000
                           time:   [5.5075 µs 5.5178 µs 5.5285 µs]
   Found 5 outliers among 100 measurements (5.00%)
     4 (4.00%) high mild
     1 (1.00%) high severe
   
   Read Latin-1 Standard size 100000
                           time:   [212.06 µs 212.32 µs 212.63 µs]
   Found 8 outliers among 100 measurements (8.00%)
     3 (3.00%) high mild
     5 (5.00%) high severe
   
   Read UTF-8 SIMD size 100
                           time:   [21.300 ns 21.314 ns 21.331 ns]
   Found 8 outliers among 100 measurements (8.00%)
     5 (5.00%) high mild
     3 (3.00%) high severe
   
   Read UTF-8 Standard size 100
                           time:   [76.610 ns 76.689 ns 76.779 ns]
   Found 5 outliers among 100 measurements (5.00%)
     3 (3.00%) high mild
     2 (2.00%) high severe
   
   Read UTF-8 SIMD size 1000
                           time:   [90.750 ns 91.046 ns 91.425 ns]
   Found 7 outliers among 100 measurements (7.00%)
     2 (2.00%) low mild
     3 (3.00%) high mild
     2 (2.00%) high severe
   
   Read UTF-8 Standard size 1000
                           time:   [530.43 ns 530.67 ns 530.95 ns]
   Found 10 outliers among 100 measurements (10.00%)
     8 (8.00%) high mild
     2 (2.00%) high severe
   
   Read UTF-8 SIMD size 10000
                           time:   [402.37 ns 403.34 ns 404.30 ns]
   Found 3 outliers among 100 measurements (3.00%)
     1 (1.00%) high mild
     2 (2.00%) high severe
   
   Read UTF-8 Standard size 10000
                           time:   [4.8775 µs 4.8913 µs 4.9069 µs]
   Found 6 outliers among 100 measurements (6.00%)
     6 (6.00%) high mild
   
   Read UTF-8 SIMD size 100000
                           time:   [8.2674 µs 8.2749 µs 8.2830 µs]
   Found 9 outliers among 100 measurements (9.00%)
     1 (1.00%) low severe
     3 (3.00%) low mild
     3 (3.00%) high mild
     2 (2.00%) high severe
   
   Read UTF-8 Standard size 100000
                           time:   [47.938 µs 47.991 µs 48.054 µs]
   Found 9 outliers among 100 measurements (9.00%)
     5 (5.00%) high mild
     4 (4.00%) high severe
   
   Read UTF-16 SIMD size 100
                           time:   [210.00 ns 210.46 ns 210.90 ns]
   Found 2 outliers among 100 measurements (2.00%)
     2 (2.00%) high mild
   
   Read UTF-16 Standard size 100
                           time:   [294.07 ns 299.92 ns 308.96 ns]
   Found 8 outliers among 100 measurements (8.00%)
     2 (2.00%) high mild
     6 (6.00%) high severe
   
   Read UTF-16 SIMD size 1000
                           time:   [1.4022 µs 1.4076 µs 1.4141 µs]
   Found 4 outliers among 100 measurements (4.00%)
     3 (3.00%) high mild
     1 (1.00%) high severe
   
   Read UTF-16 Standard size 1000
                           time:   [2.2546 µs 2.2960 µs 2.3543 µs]
   Found 9 outliers among 100 measurements (9.00%)
     4 (4.00%) high mild
     5 (5.00%) high severe
   
   Read UTF-16 SIMD size 10000
                           time:   [13.036 µs 13.291 µs 13.566 µs]
   Found 9 outliers among 100 measurements (9.00%)
     5 (5.00%) high mild
     4 (4.00%) high severe
   
   Read UTF-16 Standard size 10000
                           time:   [20.146 µs 20.273 µs 20.421 µs]
   Found 6 outliers among 100 measurements (6.00%)
     4 (4.00%) high mild
     2 (2.00%) high severe
   
   Read UTF-16 SIMD size 100000
                           time:   [131.25 µs 133.50 µs 136.36 µs]
   Found 8 outliers among 100 measurements (8.00%)
     2 (2.00%) high mild
     6 (6.00%) high severe
   
   Read UTF-16 Standard size 100000
                           time:   [214.45 µs 219.54 µs 225.14 µs]
   Found 12 outliers among 100 measurements (12.00%)
     5 (5.00%) high mild
     7 (7.00%) high severe
   ```
   


-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to