[ 
https://issues.apache.org/jira/browse/IGNITE-24664?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17932171#comment-17932171
 ] 

Aleksey Plekhanov edited comment on IGNITE-24664 at 3/4/25 6:57 AM:
--------------------------------------------------------------------

Local performance test:

Before fix:
{noformat}
Benchmark                          (engine)   Mode  Cnt    Score    Error  Units
JmhSqlBenchmark.querySimpleUnique        H2  thrpt    3  192,254 ±  3,643  ops/s
JmhSqlBenchmark.querySimpleUnique   CALCITE  thrpt    3  147,601 ± 28,635  ops/s
{noformat}
After fix:
{noformat}
Benchmark                          (engine)   Mode  Cnt    Score    Error  Units
JmhSqlBenchmark.querySimpleUnique        H2  thrpt    3  193,708 ± 23,837  ops/s
JmhSqlBenchmark.querySimpleUnique   CALCITE  thrpt    3  160,935 ± 10,954  ops/s
{noformat}
 


was (Author: alex_pl):
Local performance test:

Before fix:

 
{noformat}
Benchmark                          (engine)   Mode  Cnt    Score    Error  Units
JmhSqlBenchmark.querySimpleUnique        H2  thrpt    3  192,254 ±  3,643  ops/s
JmhSqlBenchmark.querySimpleUnique   CALCITE  thrpt    3  147,601 ± 28,635  ops/s
{noformat}
After fix:
{noformat}
Benchmark                          (engine)   Mode  Cnt    Score    Error  Units
JmhSqlBenchmark.querySimpleUnique        H2  thrpt    3  193,708 ± 23,837  ops/s
JmhSqlBenchmark.querySimpleUnique   CALCITE  thrpt    3  160,935 ± 10,954  ops/s
{noformat}
 

> Calcite engine. Use _key_PK index scan instead of hash index scan if possible
> -----------------------------------------------------------------------------
>
>                 Key: IGNITE-24664
>                 URL: https://issues.apache.org/jira/browse/IGNITE-24664
>             Project: Ignite
>          Issue Type: Improvement
>            Reporter: Aleksey Plekhanov
>            Assignee: Aleksey Plekhanov
>            Priority: Major
>              Labels: calcite, ise
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> Looks like _key_PK index scan is more effective than hash index scan. Hash 
> index scan requires also entity type check, but _key_PK index scan only built 
> for required entity type, so type check can be skipped. 
> H2 engine uses PK index scan for table scans (see H2TableScanIndex.delegate() 
> method).
> Calcite engine should also use PK index scan when indexes are in correct 
> state.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to