Slow compilation of large lexical scopes
メンテナーはふだん 1 日以内に返信
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 25/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- c, javascript
- 領域
- compilers, performance
調査の方向性
Reproduce the compile time first with the commands in the report: npm pack [email protected], extract package/dist/umd/lucide-react.js, then time ./build/qjsc -o /tmp/lucide-react.c /tmp/lucide-react.js over 11 runs. Then read find_var_in_child_scope() and find_lexical_decl(), which the report flags as scanning existing bindings during declaration checks, plus the local name-resolution walk over the binding chain. Done means a large flat const scope compiles without the per-declaration scan blowing up, verified by the same timing loop.
索引モデルが issue の本文から書いたものです。
説明
The published [email protected] UMD bundle has 3,287 const bindings in one function. On QuickJS-NG d06a85c, it took 140 ms to compile. I saw the same slowdown with the CommonJS entry from @tabler/[email protected]: 972 ms with the standard Node wrapper.
Both timings are compile-only medians over 11 runs on Linux x86-64, GCC 14.2, -O2.
npm pack [email protected] --silent
tar -xOf lucide-react-0.548.0.tgz package/dist/umd/lucide-react.js > /tmp/lucide-react.js
./build/qjsc -o /tmp/lucide-react.c /tmp/lucide-react.js
find_var_in_child_scope() and find_lexical_decl() scan existing bindings during declaration checks. Local name resolution also walks the binding chain.
- 主要言語
- C
- スター
- 3.9k
- フォーク
- 389
- 平均マージ
- 2日 2時間
- マージ済み PR(30日)
- 19
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
quickjs-ng/quickjs のほかの issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
quickjs-ng/quickjs#1959 ·
メンテナーはふだん 1 日以内に返信
-
JS_SetPropertyInternal2 loses the value when a lazy property on the prototype runs out of memory対応中かも @TheNetherWatcher が 6 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
quickjs-ng/quickjs#1852 ·
メンテナーはふだん 1 日以内に返信
-
Object.prototype.propertyIsEnumerable converts `this` before the property key対応中かも @SomSamantray が 48 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
quickjs-ng/quickjs#1772 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 58/100
quickjs-ng/quickjs#1957 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
JS_ToCStringLen2 contract is documented wrong対応中かも @bnoordhuis が 3 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 45/100
quickjs-ng/quickjs#1950 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
quickjs-ng/quickjs の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
メンテナーはふだん 2 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
libsndfile/libsndfile#1238 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
DaveGamble/cJSON#1143 ·
-
Claude:Bug GPT:Bug triage
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
open5gs/open5gs#5161 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 2 日以内に返信