Skip to content

PartitionedOutputOperator RLE blocks support#11289

Merged
sopel39 merged 7 commits intotrinodb:masterfrom
starburstdata:ls/002-poo-rle
May 26, 2022
Merged

PartitionedOutputOperator RLE blocks support#11289
sopel39 merged 7 commits intotrinodb:masterfrom
starburstdata:ls/002-poo-rle

Conversation

@lukasz-stec
Copy link
Copy Markdown
Member

@lukasz-stec lukasz-stec commented Mar 3, 2022

Description

RLE support in the PartitionedOutputOperator.
The core of this c
orc-sf1K-part-rle-run3.pdf
hange is to refactor stateless and class isolated PositionsAppender to a stateful class that can build Block's. Possibly the name should change to something like 'BatchBlockBuilder'.
The reason the new implementation does not need isolation is twofold.

  1. Different io.trino.spi.type.Types are handled by dedicated PossitionAppenders
  2. DictionaryBlock and RunLengthEncodedBlock are handled by manual dispatch in BlockTypeDispatchingPositionsAppender

On top of this change, AdaptivePositionsAppender is added to support processing RLE blocks efficiently.

Latest benchmarks below
The JMH results seem to confirm it working as expected for RLE + improvements with using primitive arrays directly instead of BlockBuilders.
The tpch/.tpcds shows ~2% improvement, which is expected given partitioned exchange is on average ~4% of query cost.

image

orc-sf1K-part-rle-run3.pdf

| Benchmark                                  | channelCount | enableCompression | nullRate | partitionCount | positionCount | type                                                           | baseline  | no isolation + rle | no isolation + rle % |
| ------------------------------------------ | ------------ | ----------------- | -------- | -------------- | ------------- | -------------------------------------------------------------- | --------- | ------------------ | -------------------- |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT                                                         | 1377.988  | 1194.357           | -13.32602316         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT_SKEWED_HASH                                             | 1478.192  | 588.185            | -60.20916092         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | DICTIONARY_BIGINT                                              | 880.58    | 372.583            | -57.68890958         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | RLE_BIGINT                                                     | 891.652   | 247.568            | -72.23490779         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 855.909   | 472.901            | -44.74868239         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 863.687   | 404.686            | -53.14436827         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1204.258  | 434.008            | -63.96054666         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 929.678   | 447.363            | -51.87979064         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1489.952  | 440.623            | -70.42703389         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1558.682  | 454.968            | -70.81072342         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | RLE_PARTITION_BIGINT                                           | 1047.284  | 322.406            | -69.21503623         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 4.522     | 1.609              | -64.41839894         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | LONG_DECIMAL                                                   | 1857.105  | 643.624            | -65.3426166          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | INTEGER                                                        | 1303.061  | 484.015            | -62.85553785         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | SMALLINT                                                       | 1241.432  | 1050.261           | -15.3992325          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | BOOLEAN                                                        | 1527.221  | 1111.143           | -27.24412511         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | VARCHAR                                                        | 4295.36   | 2945.668           | -31.42209268         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | ARRAY_BIGINT                                                   | 1079.365  | 762.538            | -29.35309186         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | ARRAY_VARCHAR                                                  | 2587.769  | 2412.689           | -6.765673443         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | ARRAY_ARRAY_BIGINT                                             | 3777.661  | 3661.588           | -3.072615568         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | MAP_BIGINT_BIGINT                                              | 2157.84   | 2436.79            | 12.92727913          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 8439.16   | 7956.986           | -5.713530731         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | ROW_BIGINT_BIGINT                                              | 1011.156  | 914.291            | -9.579629652         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 2862.105  | 2689.306           | -6.037479408         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 2              | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 974.665   | 947.451            | -2.792138837         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT                                                         | 1531.461  | 635.676            | -58.49218491         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT_SKEWED_HASH                                             | 1445.4    | 625.853            | -56.70035976         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | DICTIONARY_BIGINT                                              | 950.5     | 451.38             | -52.51130984         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | RLE_BIGINT                                                     | 1019.647  | 658.623            | -35.40676332         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 871.119   | 526.682            | -39.53960366         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1332.829  | 433.859            | -67.44826231         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 674.881   | 451.3              | -33.12895162         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1605.395  | 716.257            | -55.38437581         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1015.204  | 465.206            | -54.17610648         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1016.257  | 464.759            | -54.26757208         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | RLE_PARTITION_BIGINT                                           | 1090.389  | 376.868            | -65.43728889         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 4.817     | 1.714              | -64.41768736         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | LONG_DECIMAL                                                   | 1789.638  | 739.024            | -58.70539182         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | INTEGER                                                        | 1417.015  | 1157.978           | -18.28046986         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | SMALLINT                                                       | 1252.093  | 1141.264           | -8.85149905          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | BOOLEAN                                                        | 1282.559  | 506.331            | -60.52181615         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | VARCHAR                                                        | 4473.089  | 2655.62            | -40.63118351         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | ARRAY_BIGINT                                                   | 1161.918  | 1053.978           | -9.28981219          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | ARRAY_VARCHAR                                                  | 3271.601  | 2627.539           | -19.68644709         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | ARRAY_ARRAY_BIGINT                                             | 3711.912  | 3781.893           | 1.885308703          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | MAP_BIGINT_BIGINT                                              | 2215.612  | 2009.711           | -9.293188519         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 8791.323  | 9468.428           | 7.701969317          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | ROW_BIGINT_BIGINT                                              | 864.239   | 1151.059           | 33.1875789           |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 2902.176  | 3113.187           | 7.270785783          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 16             | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 1271.502  | 1083.875           | -14.75632756         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT                                                         | 1821.222  | 1015.297           | -44.25188143         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT_SKEWED_HASH                                             | 1416.156  | 1310.207           | -7.481449784         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | DICTIONARY_BIGINT                                              | 1186.156  | 982.881            | -17.13729054         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | RLE_BIGINT                                                     | 984.876   | 642.725            | -34.74051556         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 877.169   | 422.889            | -51.78933592         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 751.474   | 466.31             | -37.9472876          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1075.353  | 475.17             | -55.81264943         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1414.557  | 497.04             | -64.86249759         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1258.328  | 505.125            | -59.85744575         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1485.438  | 510.652            | -65.62279947         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | RLE_PARTITION_BIGINT                                           | 1179.437  | 408.342            | -65.37822707         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 5.537     | 3.424              | -38.16145927         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | LONG_DECIMAL                                                   | 2437.78   | 1136.292           | -53.38824668         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | INTEGER                                                        | 1756.906  | 1086.541           | -38.15599696         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | SMALLINT                                                       | 1519.123  | 854.098            | -43.77690286         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | BOOLEAN                                                        | 1461.459  | 565.997            | -61.27178388         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | VARCHAR                                                        | 5280.259  | 3178.651           | -39.80122945         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | ARRAY_BIGINT                                                   | 1553.201  | 981.82             | -36.78731858         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | ARRAY_VARCHAR                                                  | 3420.646  | 3159.28            | -7.640837432         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | ARRAY_ARRAY_BIGINT                                             | 4602.567  | 4612.852           | 0.2234622549         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | MAP_BIGINT_BIGINT                                              | 3160.772  | 3068.688           | -2.913338893         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 11068.375 | 10248.298          | -7.409190599         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | ROW_BIGINT_BIGINT                                              | 1275.2    | 1501.235           | 17.72545483          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 3453.47   | 3574.603           | 3.507573542          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0        | 256            | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 1570.959  | 1295.839           | -17.51286953         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT                                                         | 1487.185  | 796.43             | -46.44714679         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT_SKEWED_HASH                                             | 1785.405  | 878.28             | -50.80779991         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | DICTIONARY_BIGINT                                              | 1283.707  | 506.794            | -60.52105348         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | RLE_BIGINT                                                     | 884.332   | 248.569            | -71.89189128         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 901.619   | 478.587            | -46.91915321         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1176.544  | 516.424            | -56.10669894         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 733.521   | 539.292            | -26.47899651         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 773.641   | 885.03             | 14.39802182          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1093.131  | 637.782            | -41.65548319         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 757.275   | 914.405            | 20.74939751          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | RLE_PARTITION_BIGINT                                           | 1073.874  | 558.295            | -48.01112607         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 5.162     | 2.635              | -48.95389384         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | LONG_DECIMAL                                                   | 1902.616  | 854.957            | -55.06413275         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | INTEGER                                                        | 1659.016  | 738.148            | -55.50687878         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | SMALLINT                                                       | 1578.704  | 666.223            | -57.79937214         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | BOOLEAN                                                        | 1754.117  | 723.107            | -58.77658104         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | VARCHAR                                                        | 4123.064  | 1939.886           | -52.95037865         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | ARRAY_BIGINT                                                   | 1163.802  | 1072.286           | -7.863536925         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | ARRAY_VARCHAR                                                  | 2009.727  | 1818.178           | -9.531095517         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | ARRAY_ARRAY_BIGINT                                             | 3045.492  | 3290.853           | 8.056530767          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | MAP_BIGINT_BIGINT                                              | 2308.81   | 1955.681           | -15.29484886         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 6727.883  | 6573.649           | -2.292459604         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | ROW_BIGINT_BIGINT                                              | 899.747   | 933.86             | 3.791399138          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 2285.481  | 2589.809           | 13.31570903          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 2              | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 1008.272  | 1073.563           | 6.47553438           |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT                                                         | 1456.212  | 702.925            | -51.7292125          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT_SKEWED_HASH                                             | 1870.212  | 942.098            | -49.62613864         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | DICTIONARY_BIGINT                                              | 969.743   | 513.209            | -47.07783402         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | RLE_BIGINT                                                     | 814.789   | 640.407            | -21.40210533         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 973.396   | 577.435            | -40.67830564         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 745.072   | 559.565            | -24.89786222         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 971.725   | 729.779            | -24.89860815         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1542.103  | 911.356            | -40.90174262         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1364.524  | 607.859            | -55.45267067         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 803.366   | 599.638            | -25.35930074         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | RLE_PARTITION_BIGINT                                           | 1370.722  | 646.677            | -52.82216233         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 4.695     | 2.598              | -44.66453674         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | LONG_DECIMAL                                                   | 1640.184  | 1454.72            | -11.30751184         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | INTEGER                                                        | 1332.152  | 648.781            | -51.29827527         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | SMALLINT                                                       | 1330.493  | 644.406            | -51.56637427         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | BOOLEAN                                                        | 1676.115  | 561.237            | -66.51560305         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | VARCHAR                                                        | 4176.501  | 2328.664           | -44.24366234         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | ARRAY_BIGINT                                                   | 869.231   | 815.148            | -6.221936401         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | ARRAY_VARCHAR                                                  | 2440.842  | 2524.851           | 3.441804099          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | ARRAY_ARRAY_BIGINT                                             | 3715.517  | 3133.791           | -15.65666366         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | MAP_BIGINT_BIGINT                                              | 2219.503  | 2412.3             | 8.686494229          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 7905.182  | 7451.738           | -5.73603492          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | ROW_BIGINT_BIGINT                                              | 983.02    | 1128.739           | 14.82360481          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 2591.924  | 2661.464           | 2.682949037          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 16             | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 937.949   | 916.133            | -2.325926036         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT                                                         | 1725.878  | 1089.528           | -36.87108822         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT_SKEWED_HASH                                             | 1676.634  | 1006.826           | -39.94956562         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | DICTIONARY_BIGINT                                              | 1191.739  | 764.539            | -35.84677517         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | RLE_BIGINT                                                     | 983.661   | 292.597            | -70.25428476         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 980.979   | 536.12             | -45.34847331         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 800.14    | 615.983            | -23.01559727         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1004.041  | 731.968            | -27.0977978          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1544.395  | 642.521            | -58.39658896         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1074.176  | 1058.461           | -1.462981858         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1515.508  | 648.563            | -57.20491083         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | RLE_PARTITION_BIGINT                                           | 1220.995  | 735.056            | -39.79860687         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 7.067     | 4.362              | -38.27649639         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | LONG_DECIMAL                                                   | 2048.711  | 1258.215           | -38.58504201         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | INTEGER                                                        | 1681.013  | 1047.26            | -37.70066026         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | SMALLINT                                                       | 1598.526  | 992.412            | -37.91705609         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | BOOLEAN                                                        | 1578.246  | 618.251            | -60.82670255         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | VARCHAR                                                        | 4494.003  | 2791.755           | -37.87821236         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | ARRAY_BIGINT                                                   | 1484.852  | 1459.632           | -1.698485775         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | ARRAY_VARCHAR                                                  | 2779.724  | 2406.36            | -13.43169322         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | ARRAY_ARRAY_BIGINT                                             | 3723.041  | 3873.765           | 4.048410963          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | MAP_BIGINT_BIGINT                                              | 3091.319  | 3036.642           | -1.7687272           |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 8490.43   | 8489.468           | -0.01133040376       |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | ROW_BIGINT_BIGINT                                              | 1480.015  | 1380.752           | -6.706891484         |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 3027.948  | 3168.945           | 4.656519861          |
| BenchmarkPartitionedOutputOperator.addPage | 1            | FALSE             | 0.2      | 256            | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 1235.024  | 1004.322           | -18.67996088         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT                                                         | 1565.991  | 604.042            | -61.42749224         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT_SKEWED_HASH                                             | 1586.653  | 631.677            | -60.18808145         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | DICTIONARY_BIGINT                                              | 1165.412  | 463.384            | -60.23861089         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | RLE_BIGINT                                                     | 1305.747  | 249.05             | -80.92662667         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 956.011   | 718.365            | -24.85808218         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1170.627  | 410.723            | -64.91427244         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1218.427  | 444.127            | -63.54914985         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1431.875  | 707.645            | -50.57913575         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1071.936  | 462.119            | -56.88931056         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1503.785  | 471.254            | -68.66214253         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | RLE_PARTITION_BIGINT                                           | 1073.326  | 526.597            | -50.93783249         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 5.997     | 2.451              | -59.12956478         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | LONG_DECIMAL                                                   | 2913.768  | 820.791            | -71.83059873         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | INTEGER                                                        | 1509.434  | 546.655            | -63.78410716         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | SMALLINT                                                       | 1551.3    | 553.214            | -64.33868368         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | BOOLEAN                                                        | 2014.684  | 505.431            | -74.91264139         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | VARCHAR                                                        | 6556.465  | 4107.887           | -37.34600886         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | ARRAY_BIGINT                                                   | 1924.249  | 1296.046           | -32.64665851         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | ARRAY_VARCHAR                                                  | 4617.898  | 5035.891           | 9.051585808          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | ARRAY_ARRAY_BIGINT                                             | 7129.627  | 6124.336           | -14.10019066         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | MAP_BIGINT_BIGINT                                              | 5137.283  | 5485.352           | 6.775351874          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 16117.295 | 13705.885          | -14.96162973         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | ROW_BIGINT_BIGINT                                              | 1708.188  | 2148.073           | 25.75155662          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 5151.144  | 4620.2             | -10.30730261         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 2              | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 1886.761  | 2229.173           | 18.14813853          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT                                                         | 1650.687  | 704.756            | -57.30529168         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT_SKEWED_HASH                                             | 1489.751  | 1243.568           | -16.52511057         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | DICTIONARY_BIGINT                                              | 1112.001  | 946.543            | -14.87930317         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | RLE_BIGINT                                                     | 1049.786  | 287.456            | -72.61765731         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 884.82    | 760.745            | -14.02262607         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1396.012  | 452.853            | -67.5609522          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1379.345  | 471.115            | -65.84502064         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 809.832   | 482.297            | -40.44480831         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1097.37   | 487.722            | -55.5553733          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1562.109  | 493.5              | -68.40809444         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | RLE_PARTITION_BIGINT                                           | 1105.83   | 541.072            | -51.07096027         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 5.843     | 2.736              | -53.174739           |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | LONG_DECIMAL                                                   | 2323.425  | 916.792            | -60.54135597         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | INTEGER                                                        | 1545.641  | 672.916            | -56.46362901         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | SMALLINT                                                       | 1558.249  | 647.521            | -58.44560144         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | BOOLEAN                                                        | 2024.976  | 565.468            | -72.07532336         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | VARCHAR                                                        | 9104.298  | 4847.453           | -46.75643306         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | ARRAY_BIGINT                                                   | 2103.593  | 1886.378           | -10.3259043          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | ARRAY_VARCHAR                                                  | 5602.723  | 5398.284           | -3.64892214          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | ARRAY_ARRAY_BIGINT                                             | 7648.848  | 7651.866           | 0.03945692214        |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | MAP_BIGINT_BIGINT                                              | 4365.258  | 4056.462           | -7.073946145         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 18945.791 | 18327.672          | -3.26256634          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | ROW_BIGINT_BIGINT                                              | 1949.656  | 1461.971           | -25.01389989         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 5730.163  | 5688.246           | -0.7315149674        |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 16             | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 1901.551  | 1627.874           | -14.39230397         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT                                                         | 2468.689  | 1429.152           | -42.10886831         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT_SKEWED_HASH                                             | 1733.471  | 750.841            | -56.68569016         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | DICTIONARY_BIGINT                                              | 2507.853  | 1486.14            | -40.7405458          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | RLE_BIGINT                                                     | 1112.528  | 302.208            | -72.83591964         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 1043.221  | 712.817            | -31.67152502         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1301.398  | 585.107            | -55.0401184          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1498.872  | 514.376            | -65.68245988         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1504.356  | 516.978            | -65.63459713         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1352.062  | 521.455            | -61.43261182         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1121.603  | 902.603            | -19.52562538         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | RLE_PARTITION_BIGINT                                           | 1169.667  | 622.426            | -46.78605107         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 6.232     | 4.526              | -27.37483954         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | LONG_DECIMAL                                                   | 3792.717  | 1836.15            | -51.58747674         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | INTEGER                                                        | 2722.116  | 1229.188           | -54.84439311         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | SMALLINT                                                       | 2061.356  | 1099.74            | -46.64968108         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | BOOLEAN                                                        | 1585.115  | 645.39             | -59.28434215         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | VARCHAR                                                        | 10141.49  | 6003.136           | -40.80617345         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | ARRAY_BIGINT                                                   | 2802.146  | 2407.243           | -14.09287739         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | ARRAY_VARCHAR                                                  | 6758.661  | 6496.838           | -3.87388863          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | ARRAY_ARRAY_BIGINT                                             | 8954.579  | 9654.247           | 7.813521998          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | MAP_BIGINT_BIGINT                                              | 6522.753  | 7607.369           | 16.62819365          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 23030.7   | 20835.556          | -9.531382025         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | ROW_BIGINT_BIGINT                                              | 2379.216  | 2142.979           | -9.929195163         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 7123.702  | 7345.167           | 3.108847057          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0        | 256            | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 2839.079  | 2798.05            | -1.445151755         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT                                                         | 2171.487  | 1337.212           | -38.41952542         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT_SKEWED_HASH                                             | 2203.488  | 1303.884           | -40.82636257         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | DICTIONARY_BIGINT                                              | 1321.459  | 778.778            | -41.0668057          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | RLE_BIGINT                                                     | 1026.341  | 255.923            | -75.06452534         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 1306.71   | 789.357            | -39.59202884         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1071.29   | 885.307            | -17.36065865         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1760.328  | 741.472            | -57.87875896         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1507.119  | 754.647            | -49.92784246         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1416.77   | 1259.083           | -11.13003522         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1805.955  | 771.392            | -57.28620038         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | RLE_PARTITION_BIGINT                                           | 1932.99   | 1147.766           | -40.62224843         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 8.217     | 5.773              | -29.74321529         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | LONG_DECIMAL                                                   | 3167.83   | 1377.827           | -56.50565213         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | INTEGER                                                        | 1929.54   | 1143.003           | -40.76292795         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | SMALLINT                                                       | 1954.398  | 1614.75            | -17.37865061         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | BOOLEAN                                                        | 2276.308  | 1144.591           | -49.71721753         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | VARCHAR                                                        | 6548.203  | 3775.443           | -42.34383082         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | ARRAY_BIGINT                                                   | 1823.59   | 1588.995           | -12.86445966         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | ARRAY_VARCHAR                                                  | 4155.769  | 3469.721           | -16.50832854         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | ARRAY_ARRAY_BIGINT                                             | 5978.912  | 6311.918           | 5.569675553          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | MAP_BIGINT_BIGINT                                              | 3666.914  | 4117.758           | 12.29491611          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 12720.477 | 12460.634          | -2.042714279         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | ROW_BIGINT_BIGINT                                              | 1587.113  | 1644.27            | 3.601318873          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 5144.823  | 5028.116           | -2.268435668         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 2              | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 1776.245  | 1789.509           | 0.7467438332         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT                                                         | 2043.238  | 1354.967           | -33.68530734         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT_SKEWED_HASH                                             | 2277.242  | 1188.533           | -47.80822592         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | DICTIONARY_BIGINT                                              | 1345.196  | 760.321            | -43.47879417         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | RLE_BIGINT                                                     | 1624.94   | 274.983            | -83.07734439         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 1386.056  | 843.047            | -39.17655564         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1096.313  | 942.495            | -14.03048217         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1650.884  | 918.833            | -44.34297019         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1779.528  | 1108.021           | -37.73511853         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1390.633  | 994.327            | -28.49824504         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 1122.907  | 876.675            | -21.92808487         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | RLE_PARTITION_BIGINT                                           | 2007.009  | 1192.23            | -40.59667894         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 9.115     | 4.568              | -49.88480527         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | LONG_DECIMAL                                                   | 3119.143  | 1358.373           | -56.45044168         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | INTEGER                                                        | 1832.532  | 1133.405           | -38.1508754          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | SMALLINT                                                       | 2154.529  | 1155.319           | -46.37718963         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | BOOLEAN                                                        | 2314.872  | 981.887            | -57.58352946         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | VARCHAR                                                        | 7692.571  | 4337.476           | -43.61474207         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | ARRAY_BIGINT                                                   | 2010.637  | 1697.004           | -15.59868838         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | ARRAY_VARCHAR                                                  | 4769.766  | 3787.13            | -20.60134606         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | ARRAY_ARRAY_BIGINT                                             | 7051.188  | 6913.119           | -1.958095572         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | MAP_BIGINT_BIGINT                                              | 4182.268  | 4606.757           | 10.14973215          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 15141.135 | 15742.405          | 3.971102563          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | ROW_BIGINT_BIGINT                                              | 1707.267  | 2110.319           | 23.60802382          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 5430.982  | 5306.303           | -2.29569901          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 16             | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 2033.261  | 1841.52            | -9.430220714         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT                                                         | 2811.82   | 1792.086           | -36.2659772          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT_SKEWED_HASH                                             | 2369.57   | 1457.996           | -38.47001777         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | DICTIONARY_BIGINT                                              | 1956.249  | 1258.746           | -35.65512366         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | RLE_BIGINT                                                     | 1223.56   | 296.625            | -75.75721665         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT_PARTITION_CHANNEL_20_PERCENT                            | 1411.154  | 907.854            | -35.66584512         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_20_PERCENT                 | 1310.566  | 1070.818           | -18.29347015         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_50_PERCENT                 | 1767.272  | 918.246            | -48.04161442         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_80_PERCENT                 | 1488.973  | 958.533            | -35.62455464         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT                | 1617.971  | 1270.319           | -21.48691169         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BIGINT_DICTIONARY_PARTITION_CHANNEL_100_PERCENT_MINUS\_1       | 2039.624  | 949.792            | -53.43298569         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | RLE_PARTITION_BIGINT                                           | 1938.644  | 1095.81            | -43.47543953         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | RLE_PARTITION_NULL_BIGINT                                      | 10.904    | 6.928              | -36.46368305         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | LONG_DECIMAL                                                   | 3535.014  | 2430.258           | -31.251814           |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | INTEGER                                                        | 2345.646  | 2313.037           | -1.390192723         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | SMALLINT                                                       | 2519.867  | 1625.114           | -35.50794546         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | BOOLEAN                                                        | 2367.953  | 873.041            | -63.13098275         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | VARCHAR                                                        | 8778.866  | 5443.803           | -37.98967885         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | ARRAY_BIGINT                                                   | 2352.735  | 2118.181           | -9.96941857          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | ARRAY_VARCHAR                                                  | 5170.807  | 4890.696           | -5.417162157         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | ARRAY_ARRAY_BIGINT                                             | 7323.928  | 7952.841           | 8.587099709          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | MAP_BIGINT_BIGINT                                              | 6074.763  | 5018.359           | -17.39004468         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | MAP_BIGINT_MAP_BIGINT_BIGINT                                   | 18034.814 | 18308.547          | 1.517803289          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | ROW_BIGINT_BIGINT                                              | 2374.269  | 2643.732           | 11.34930372          |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | ROW_ARRAY_BIGINT_ARRAY_BIGINT                                  | 6441.662  | 6222.575           | -3.401094314         |
| BenchmarkPartitionedOutputOperator.addPage | 2            | FALSE             | 0.2      | 256            | 8192          | ROW_RLE_BIGINT_BIGINT                                          | 2001.066  | 2556.196           | 27.74171367          |

Is this change a fix, improvement, new feature, refactoring, or other?

Is this a change to the core query engine, a connector, client library, or the SPI interfaces? (be specific)

How would you describe this change to a non-technical end user or system administrator?

Related issues, pull requests, and links

Documentation

( x) No documentation is needed.
( ) Sufficient documentation is included in this PR.
( ) Documentation PR is available with #prnumber.
( ) Documentation issue #issuenumber is filed, and can be handled later.

Release notes

(x ) No release notes entries required.
( ) Release notes entries required with the following suggested text:

Copy link
Copy Markdown
Member

@skrzypo987 skrzypo987 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skimmed, we'll talk offline

@lukasz-stec lukasz-stec requested a review from skrzypo987 March 3, 2022 10:08
@lukasz-stec
Copy link
Copy Markdown
Member Author

I re-run the tpcds and tpch benchmarks and the 2nd run shows no regressions nor improvements. This is what I expected initially and means the first run was flake/benchmark variability.

@sopel39
Copy link
Copy Markdown
Member

sopel39 commented Mar 7, 2022

please rebase

@lukasz-stec lukasz-stec force-pushed the ls/002-poo-rle branch 5 times, most recently from 6df3c97 to e66a1b4 Compare March 11, 2022 08:48
@lukasz-stec lukasz-stec force-pushed the ls/002-poo-rle branch 2 times, most recently from 408e205 to d2d92b5 Compare March 16, 2022 15:06
@lukasz-stec lukasz-stec removed the WIP label Mar 16, 2022
@lukasz-stec lukasz-stec requested a review from sopel39 March 16, 2022 15:22
@lukasz-stec lukasz-stec marked this pull request as ready for review March 16, 2022 15:23
@lukasz-stec
Copy link
Copy Markdown
Member Author

There are still unit tests coming for some of the changes but i think it's ready for the first round of the review.

@lukasz-stec
Copy link
Copy Markdown
Member Author

by row processing bug fixed

Copy link
Copy Markdown
Member Author

@lukasz-stec lukasz-stec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comments addressed.
JMH results are still pending. I ran them on the older hardware and got strange results. Need to re-run it.

@lukasz-stec lukasz-stec requested a review from skrzypo987 March 18, 2022 11:44
Copy link
Copy Markdown
Member Author

@lukasz-stec lukasz-stec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some quick comments

@lukasz-stec lukasz-stec requested a review from sopel39 May 18, 2022 19:53
Copy link
Copy Markdown
Member

@sopel39 sopel39 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm % comments

Copy link
Copy Markdown
Member Author

@lukasz-stec lukasz-stec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

another set of comments addressed

@lukasz-stec lukasz-stec force-pushed the ls/002-poo-rle branch 2 times, most recently from 3e357d1 to db5538b Compare May 23, 2022 12:26
Copy link
Copy Markdown
Member

@sopel39 sopel39 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

% comments

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the purpose of this test? Why all rows landed in partition number 0?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this tests that the output of the PagePartitioner contains exactly the input when all partitions are concatenated (so regardless of the partitioning).
Not all rows go to partition 0. See comment below.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this tests that the output of the PagePartitioner contains exactly the input when all partitions are concatenated (so regardless of the partitioning).

testProducesSameNumberOfRows?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sopel39 this tests the actual values in the output page matches input page/block so maybe testOutputEqualsInput?

@lukasz-stec lukasz-stec force-pushed the ls/002-poo-rle branch 3 times, most recently from 95d0148 to 5989ef6 Compare May 24, 2022 21:45
@lukasz-stec lukasz-stec requested a review from sopel39 May 25, 2022 07:57
Copy link
Copy Markdown
Member

@sopel39 sopel39 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this tests that the output of the PagePartitioner contains exactly the input when all partitions are concatenated (so regardless of the partitioning).

testProducesSameNumberOfRows?

To avoid block type pollution, use manual dispatch
over Block class instead of class isolation.
Before invoking dedicated PositionsAppender the
input Block is flattened so the dedicated appender
either gets flat Block or RLE Block with flat value.
Each dedicated, type-specific, PositionsAppender is
implemented without using BlockBuilder to increase
performance and to avoid jit inlining issues.

Microbenchmark results:
Benchmark                                   channelCount  enableCompression  nullRate  partitionCount  positionCount  type                                                     baseline  no        isolation      rle  no  isolation  rle  %
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         2               8192           BIGINT                                                   1301.217  485.526   -62.68677707
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT                                                   1324.132  541.814   -59.08157193
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_SKEWED                          1338.207  548.653   -59.00088701
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           DICTIONARY_BIGINT                                        1552.893  649.265   -58.18997188
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_20_PERCENT                      845.798   326.112   -61.44327605
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_20_PERCENT           656.293   437.755   -33.2988467
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_50_PERCENT           759.82    457.409   -39.80034745
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_80_PERCENT           850.399   472.21    -44.47194787
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_100_PERCENT          991.474   507.408   -48.82286374
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_100_PERCENT_MINUS_1  919.57    480.823   -47.71219157
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_RLE                             825.266   359.845   -56.39648307
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BIGINT_PARTITION_CHANNEL_RLE_NULL                        3.438     1.603     -53.37405468
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           LONG_DECIMAL                                             1560.603  633.44    -59.41056117
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           DICTIONARY_LONG_DECIMAL                                  1983.322  757.596   -61.80166408
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           INTEGER                                                  1362.036  508.811   -62.64335157
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           DICTIONARY_INTEGER                                       1548.895  585.053   -62.22771718
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           SMALLINT                                                 1290.688  482.476   -62.61869639
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           DICTIONARY_SMALLINT                                      1531.761  564.357   -63.15632791
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           BOOLEAN                                                  1371.602  493.602   -64.01273839
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           DICTIONARY_BOOLEAN                                       1451.336  595.603   -58.96174284
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           VARCHAR                                                  4027.003  3181.661  -20.99183934
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           DICTIONARY_VARCHAR                                       4226.032  3324.484  -21.33320335
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           ARRAY_BIGINT                                             738.844   505.346   -31.60315303
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           ARRAY_VARCHAR                                            2482.31   2247.198  -9.471500336
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           ARRAY_ARRAY_BIGINT                                       3804.695  3487.887  -8.326764695
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           MAP_BIGINT_BIGINT                                        2389.073  2509.251  5.030319291
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           MAP_BIGINT_MAP_BIGINT_BIGINT                             9909.356  9710.362  -2.008142608
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           ROW_BIGINT_BIGINT                                        993.453   646.287   -34.94538745
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           ROW_ARRAY_BIGINT_ARRAY_BIGINT                            2202.165  2205.541  0.1533036807
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         16              8192           ROW_RLE_BIGINT_BIGINT                                    878.079   788.256   -10.2294896
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0         256             8192           BIGINT                                                   1670.45   943.49    -43.5188123
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       2               8192           BIGINT                                                   1602.083  855.094   -46.62611113
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT                                                   1450.967  695.945   -52.03578028
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_SKEWED                          1749.628  992.395   -43.27965716
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           DICTIONARY_BIGINT                                        1768.296  794.583   -55.06504567
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_20_PERCENT                      1079.607  595.375   -44.85261767
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_20_PERCENT           909.682   708.798   -22.08288171
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_50_PERCENT           1007.795  715.258   -29.02743117
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_80_PERCENT           1108.153  742.894   -32.96106224
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_100_PERCENT          1235.82   776.522   -37.16544481
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_DICTIONARY_100_PERCENT_MINUS_1  1163.168  748.659   -35.63621076
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_RLE                             1251.835  778.291   -37.82798851
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BIGINT_PARTITION_CHANNEL_RLE_NULL                        5.362     3.367     -37.20626632
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           LONG_DECIMAL                                             1702.922  772.704   -54.62481546
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           DICTIONARY_LONG_DECIMAL                                  2086.265  889.509   -57.36356599
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           INTEGER                                                  1462.114  636.766   -56.44894995
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           DICTIONARY_INTEGER                                       1765.352  745.925   -57.74638712
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           SMALLINT                                                 1507.112  623.829   -58.60765491
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           DICTIONARY_SMALLINT                                      1718.672  723.018   -57.93158904
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           BOOLEAN                                                  1437.562  563.497   -60.80189933
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           DICTIONARY_BOOLEAN                                       1581.486  654.235   -58.63162873
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           VARCHAR                                                  3723.315  2907.568  -21.90915891
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           DICTIONARY_VARCHAR                                       3869.583  3013.539  -22.12238373
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           ARRAY_BIGINT                                             905.913   692.206   -23.59023438
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           ARRAY_VARCHAR                                            2218.627  1844.282  -16.8728227
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           ARRAY_ARRAY_BIGINT                                       3499.471  3289.49   -6.000364055
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           MAP_BIGINT_BIGINT                                        2331.617  2309.136  -0.9641806523
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           MAP_BIGINT_MAP_BIGINT_BIGINT                             7705.042  7388.883  -4.103274194
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           ROW_BIGINT_BIGINT                                        942.5     908.927   -3.562122016
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           ROW_ARRAY_BIGINT_ARRAY_BIGINT                            2341.541  2318.315  -0.9919108826
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       16              8192           ROW_RLE_BIGINT_BIGINT                                    827.48    813.803   -1.652849616
BenchmarkPartitionedOutputOperator.addPage  1             FALSE              0.2       256             8192           BIGINT                                                   1861.543  1042.849  -43.97932253
BenchmarkPartitionedOutputOperator.addPage  2             FALSE              0         2               8192           BIGINT                                                   1545.104  604.727   -60.8617284
Split one complicated loop inside partitionNotNullPositions
into two simple ones.
before
Benchmark                                   (channelCount)  (enableCompression)  (nullRate)  (partitionCount)  (positionCount)  (type)  Mode  Cnt    Score    Error  Units
BenchmarkPartitionedOutputOperator.addPage               1                false           0                16             8192  BIGINT  avgt   10  642.430 ± 24.573  ms/op

after
Benchmark                                   (channelCount)  (enableCompression)  (nullRate)  (partitionCount)  (positionCount)  (type)  Mode  Cnt    Score   Error  Units
BenchmarkPartitionedOutputOperator.addPage               1                false           0                16             8192  BIGINT  avgt   10  484.876 ± 4.875  ms/op
/**
* Copy {@code length} bytes from {@code block}, at position {@code position} to {@code count} consecutive positions in the {@link #bytes} array.
*/
private void duplicateBytes(Block block, int position, int count, int startOffset)
Copy link
Copy Markdown
Member

@sopel39 sopel39 Jun 13, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you need to pass startOffset since you also use currentOffset below?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, i noticed that too today. Its not needed (but it s equal to currentOffset )

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You could remove it altogether (I mean currentOffset). No need to track length twice (in offsets array and currentOffset)


/**
* Copy {@code length} bytes from {@code block}, at position {@code position} to {@code count} consecutive positions in the {@link #bytes} array.
*/
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would rename it to copyBytes too

private static final int INSTANCE_SIZE = ClassLayout.parseClass(SlicePositionsAppender.class).instanceSize();
private static final Block NULL_VALUE_BLOCK = new VariableWidthBlock(1, EMPTY_SLICE, new int[] {0, 0}, Optional.of(new boolean[] {true}));

private boolean initialized;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this field needed in appenders since ensureBytesCapacity works just fine without it?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ensurePositionCapacity uses it

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't have to. It can have same approach as ensureBytesCapacity, right?

if (rlePositionCount == 0) {
return;
}
int sourcePosition = 0;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove since it's always 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants