vlcn-io / cr-sqlite

Convergent, Replicated SQLite. Multi-writer and CRDT support for SQLite
https://vlcn.io
MIT License
2.61k stars 69 forks source link

Evaluate Profile-Guided Optimization (PGO) #345

Closed zamazan4ik closed 7 months ago

zamazan4ik commented 10 months ago

Hi.

There are a lot of examples of different software, where Profile-Guided Optimization (PGO) helps a lot with performance - you can check it here. E.g. in this list are a lot of databases like Redis, MongoDB, and PostgreSQL. For CR-SQLite the most interesting results I think the PGO results for SQLite.

We need to check the PGO effects on cr-sqlite, and if it works well - write a note in the cr-sqlite documentation about PGO (like it's already done for ClickHouse). I'd appreciate your providing an easy way to build cr-sqlite with PGO, and experienced users will be able to do it on their own for their own usage scenarios. Another option is to optimize the cr-sqlite builds with a generic-enough profile. Providing PGO-optimized binaries could be a trickier task (since it requires preparing a good-enough profile) but as an option would be great to see too.

For the Rust projects, I recommend starting with cargo-pgo.

tantaman commented 9 months ago

maybe one day... not quite a priority for me right now.

zamazan4ik commented 9 months ago

maybe one day... not quite a priority for me right now.

Maybe will be better to leave the issue open? In this case, maybe someone from the community will take the issue and perform all corresponding benchmarks and other PGO-related stuff.

tantaman commented 9 months ago

Sure, will do.