Improve performance by reducing string copies

オープン
#2,036 コメント 15 件 リアクション 2 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
25/100
issue の種類
リファクタリング
明瞭さ
説明が足りない
活発さ
停滞
技術スタック
rust
領域
compilers

調査の方向性

まずリンク先のDatabendブログ記事と関連するissue #1558を読み、その後lexerとtokenの所有権の経路を調べて、文字列がどこでコピーされているかを特定します。回避可能な文字列コピーを削減し、parserの動作を維持したうえで、プロジェクト既存のテストまたはベンチマークを使ってパフォーマンスへの影響を検証できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

@Omega359 mentioned in discord a blog post by the Databend folks about how they wrote a replacement of sqlparser-rs for their system

https://www.databend.com/blog/category-engineering/2025-09-10-query-parser/

Image

One thing they cite is the fact that sqlparser-rs often copies strings, even when this could be avoided

If anyone cares, we can probably avoid copying strings, someone just has to care enough to thread the lifetime information through all the tokens (or maybe use an Arc w/ an offset)

@AdamGS mentioned he might be interested in trying this

This could possibly be related to another ticket here:

主要言語
Rust
スター
3.5k
フォーク
774
平均マージ
3日 4時間
マージ済み PR(30日)
19

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

apache/datafusion-sqlparser-rs のほかの issue

apache/datafusion-sqlparser-rs の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。