heterodb / pg-strom

PG-Strom - Master development repository
http://heterodb.github.io/pg-strom/
Other
1.27k stars 163 forks source link

Pg2Arrow並列モードの改良 #755

Closed kaigai closed 2 months ago

kaigai commented 2 months ago

以下で評価したように、同じ個所を複数回スキャンするような方式だと性能がサチる。 -tならテーブル名は自明なので、relation sizeと並列数から、適切な範囲を ctid スキャンできるようにすれば ほぼ理想的な並列化になるハズ。 -cの場合、テーブルを指定すれば$(CTID_RANGE_COND)を置き換えてくれるみたいな感じにするか。 https://kaigai.hatenablog.com/entry/2024/04/01/001141

kaigai commented 2 months ago

4451af00c363298a8f258742917513a09f9d50f8 にて改良。 普通のテーブル(パーティションなし、非ForeignTable)を-tで指定すると、pg_relation_size()の結果を元にスキャン範囲を分割してくれる。 パーティションありの場合、ちょっと範囲指定が難しいができなくはない。 image (1)