Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

gcd benchmarks pass number_rows: 0 for 100k-row inputs

オープン 初心者向け
#26,297 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@med9110 がすでに取り組んでいます。

2026年10月14日 から。

評価

難易度
1/5
見積もり時間
1時間未満
初心者へのやさしさ
92/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
rust
領域
performance

調査の方向性

datafusion/functions/benches/math_expressions/gcd.rs の56、77、98行目付近にある ScalarFunctionArgs の構築から始めてください。そこでは number_rows: 0 が設定されています。lcm.rs の55行目と比較してください。そこでは n_rows が渡されています。配列ベンチマークが n_rows を渡し、スカラー同士のベンチマークが 1 を渡し、expect のメッセージが "gcd should work on valid values" になり、cargo bench --bench math_expressions(または gcd ベンチのフィルタ)が引き続き実行できれば完了です。

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

説明

bug functions good first issue help wanted tech debt
Describe the bug

All three benchmarks in functions/benches/math_expressions/gcd.rs pass number_rows: 0 in ScalarFunctionArgs, including "gcd both array" and "gcd array and scalar", whose array inputs have 100,000 rows. The sibling lcm.rs benchmark passes number_rows: n_rows. A UDF that sizes its output or expands scalars from number_rows will not do the work the benchmark claims to measure.

Every gcd benchmark also uses the copy-pasted message .expect("date_bin should work on valid values").

To Reproduce

Read gcd.rs lines 56, 77 and 98 (number_rows: 0) and compare with lcm.rs line 55 (number_rows: n_rows).

Expected behavior
  • Pass number_rows: n_rows for the benchmarks with array inputs (and 1 for scalar-scalar).
  • Change the expect messages to "gcd should work on valid values".
Additional context

to_char.rs (L144-L341), gcd.rs and lcm.rs repeat the same bench_function + ScalarFunctionArgs boilerplate seven times, which is how this drift happened. A small shared helper that takes the UDF, args, number_rows and return type would prevent it. That part is optional.

This is a small, self-contained change and a good first issue. Line references are pinned to commit 0d79252f61bd.

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

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

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

apache/datafusion のほかの issue

apache/datafusion の issue をすべて見る

似ている issue

Rust の issue をもっと見る

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

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