Databases & Storage

Experimental pg_vexec project brings vectorized execution to PostgreSQL 19

Key Takeaway

The pg_vexec project aims to transform PostgreSQL into a high-performance analytical DBMS by integrating the ORCA query planner and vectorized execution.

Summary

Developer Igor Suhorukov has released updates on pg_vexec, an experimental project designed to port Greenplum's capabilities to a minimal PostgreSQL 19 fork. The project focuses on extracting the ORCA analytical query planner and implementing vectorized execution to compete with specialized OLAP databases.

Initial performance benchmarks against ClickHouse show significant gains in specific workloads. On Parquet-based queries, the project reportedly performs up to 18x faster by total query time, while also showing competitive results on MergeTree storage formats. The developer is currently working toward a GPU-accelerated version of the engine.

Technical architecture and performance benchmarks

  • Core Architecture: The project utilizes a minimal PostgreSQL 19 fork to isolate the specific patches required to run the ORCA analytical query planner.
  • Execution Model: It implements a vectorized execution engine to improve throughput for analytical workloads compared to standard row-based processing.
  • Parquet Performance: Benchmarks on ClickBench indicate a 13x improvement by geometric mean and an 18x improvement in total query time when compared to ClickHouse on Parquet files.
  • MergeTree Comparison: On MergeTree storage, the engine achieved 1.9x faster execution by geometric mean and 1.3x faster by total time relative to ClickHouse.
  • Hardware Roadmap: Development is moving toward a GPU-enabled version of the vectorized engine to further increase analytical processing speeds.

Why it matters

If successful, this project could bridge the gap between general-purpose PostgreSQL and high-performance analytical databases like ClickHouse. It offers software engineers a way to leverage the PostgreSQL ecosystem while achieving the vectorized performance required for modern big data and OLAP workloads.

Original reference: postgr.es →