google / google/codeworld

Check consistency of state in collaborations

オープン
#434 コメント 4 件 リアクション 0 件 担当者 0 名 GitHub で見る
enhancement
主要言語
Haskell
スター
1.3k
フォーク
201
PR マージ指標
30日以内にマージされた PR はありません

説明

There remains one source of indeterminacy in game computations that we haven't thought about: incomplete specification of floating point operations. Many transcendental functions in floating point are only specified to plus/minus one ulp of precision. Furthermore, optimizations often cause intermediate floating-point results to retain extra precision in some cases, and not others. It's not clear to what extent these things will cause problems in real-world games.

There are several stages to this problem:

1. Confirm that it's really a problem. That would mean collecting data across many platforms and browsers about whether floating point arithmetic (including complex nested expressions) gives different answers. We could, in theory, do this for visitors to code.world, and collect divergences from a reference value in files on the server.
2. If it is a problem, find solutions. We can replace many transcendental math functions with deterministic variants (e.g., those at https://deterministic.js.org/; but keep in mind that we don't want to completely load deterministic.js, since it kills access to the system clock, among other things.)

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

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

調査の方向性

ソースファイルもテストも指定されていません。code.world と、提案されているサーバー側での参照値の収集から始め、ネストされた式を含めて、プラットフォーム間およびブラウザー間で浮動小数点の結果を比較します。完了の条件は、発散が発生するかどうかを明らかにし、発生する場合は、ライブラリ全体を読み込まずに deterministic.js などの決定論的な数学のバリアントを評価することです。

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

評価

技術スタック
haskell, javascript
領域
game-dev, web-dev
issue の種類
バグ
難易度
5/5
見積もり時間
1週間以上
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
25/100

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

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