Control or reject the blocking and scheduling members the surface classification lists as holes

オープン
#50 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

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

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
45/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
csharp

調査の方向性

Start with the surface classification and the existing controlled Task.Wait(), WaitAll(Task[]), WaitAny(Task[]), Task.Run, and ThreadPool.QueueUserWorkItem shims; inspect the classification test and docs/rule-inventory.md for the listed members. Then address the scheduling, blocking, and thread-state fidelity gaps, preserving virtual-time behavior or rejecting members where needed. Done when the members are controlled or rejected and no longer appear as unexplained holes in the generated inventory.

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

説明

enhancement

The surface classification added for the built-in rules (every public and protected member of a targeted type is controlled, rejected, or listed with a reason in UnrewrittenMembers, rendered in docs/rule-inventory.md under Members left as BCL calls) lists these members as documented holes. Under a simulation each runs real BCL scheduling or blocks the physical thread that runs the coordinator, so it can escape the deterministic schedule or stall the simulation. Each needs a controlled shim or a rejection rule.

Schedules: work runs through a BCL scheduler, the thread pool, or a new thread

  • Task.Start(), Task.Start(TaskScheduler), Task.RunSynchronously(), Task.RunSynchronously(TaskScheduler) (a task built with an unrewritten Task/Task<T> constructor)
  • Parallel.ForAsync (3 overloads) and Parallel.ForEachAsync (6 overloads)
  • Thread.UnsafeStart(), Thread.UnsafeStart(object): on a controlled thread this starts the real OS thread with the recorded body
  • ThreadPool.BindHandle(IntPtr), ThreadPool.BindHandle(SafeHandle)

Blocks: blocks the calling physical thread

  • Task.Wait(int), Wait(CancellationToken), Wait(TimeSpan), Wait(int, CancellationToken), Wait(TimeSpan, CancellationToken)
  • Task.WaitAll(IEnumerable<Task>, CancellationToken), WaitAll(ReadOnlySpan<Task>), WaitAll(Task[], int), WaitAll(Task[], int, CancellationToken), WaitAll(Task[], CancellationToken), WaitAll(Task[], TimeSpan)
  • Task.WaitAny(Task[], int), WaitAny(Task[], int, CancellationToken), WaitAny(Task[], CancellationToken), WaitAny(Task[], TimeSpan)
  • SynchronizationContext.WaitHelper(IntPtr[], bool, int) (protected static)
  • ValueTask<T>.Result (already documented)

Fidelity

  • Thread.IsAlive and Thread.ThreadState read the BCL Thread object a controlled thread keeps as its identity, which never runs, so a started controlled thread reports itself unstarted (IdentityHandle).

The controlled Task.Wait(), WaitAll(Task[]), and WaitAny(Task[]) shims already pump the coordinator, so the timed and cancellable overloads could follow them with virtual deadlines; the scheduling members could follow Task.Run and ThreadPool.QueueUserWorkItem, or be rejected where the scheduler cannot be preserved (as ContinueWith rejects foreign schedulers). Moving a member from the list to a rule makes the classification test flag the stale UnrewrittenMembers entry.

主要言語
C#
スター
0
フォーク
0
平均マージ
2時間 32分
マージ済み PR(30日)
23

環境構築

はじめの一歩

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

ReubenBond/Clockwork のほかの issue

ReubenBond/Clockwork の issue をすべて見る

似ている issue

C# の issue をもっと見る

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

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