Bicameral Engine — architecture map

ノードをクリックすると、その処理のソース(実装済み)か設計書・チケット(計画中)を GitHub で開きます。 リンクは版 bdf518d に固定。図の定義は docs/architecture/map.yaml。

動いている(クリックでコードへ) 計画(設計書・チケットへ) 研究(結果が読めない項目) 外部(OS・ドライバ)

起動して GPU の対応状況(SM 6.8 / DXR / Mesh / Work Graphs)を調べるところまで(T-0001)と、 シミュの整数の数学ライブラリ(T-0010。GPU と CPU が同じソースで計算する)と、 シミュに浮動小数点が入ったらビルドを落とす検査(T-0011)と、 GPU の小さな道具(デバイス・1 回投げて待つキュー・Work Graph)で自己テストと最小のグラフを GPU / WARP で走らせるテスト(T-0013)と、 シェーダーの printf / assert のリング・debug layer / GBV / DRED(T-0003)と、 Work Graphs のノードごとのカウンタと上限の検出(T-0008)と、 連鎖のトレース(選んだ刻み・場所だけ「誰が誰を起こしたか」を記録し、刻みごとの木にする)と CPU リファレンスとの食い違いの場所(T-0087)と、 窓とフレームのループ(T-0004): compute キューの仮の刻みと direct キューの描画をフェンスだけで並べ、 記録済みのリストを使い回し、GPU → CPU は待たない読み戻し、刻みの数はタイムスタンプで決める。 Agility SDK は exe が 2 つの値をエクスポートすることで、OS の d3d12.dll に読み込ませる。

flowchart TD
  subgraph exe["bicameral.exe"]
    main["wmain()<br/>コマンドラインの振り分け"]:::done
    caps["RunCapsProbe()<br/>アダプタを列挙して機能を問い合わせる"]:::done
    runtime["ReportRuntime()<br/>どの D3D12Core.dll が読まれたか"]:::done
    device["ReportDevice()<br/>SM / DXR / Mesh / Work Graphs の tier"]:::done
    sdkver["D3D12SDKVersion / D3D12SDKPath<br/>Agility SDK のエクスポート"]:::done
  end
  subgraph framelib["フレームのループ(T-0004)"]
    frameloop["RunFrameLoop()<br/>待ち → 読み戻し → 入力 → シミュ → 描画 → Present"]:::done
    window["Window<br/>Win32 の窓・入力(ボタン・ドラッグ・ホイール・キー)・DPI"]:::done
    viewcontroller["DebugViewController<br/>入力 → カメラ・表示の切り替え・つつくセル・T"]:::done
    debugcamera["OrbitCamera・PickSliceCell<br/>格子を回るカメラ・光線が断面に当たるセル"]:::done
    screenshot["ScreenshotCapture<br/>最後のフレームか刻み t の画面を BMP に(--screenshot)"]:::done
    imagecompare["image_compare.py<br/>基準の画像(tests/images)と許容差で比べる・差の画像"]:::done
    scheduler["SimScheduler<br/>1 フレームに投げる単位の数(予算・単位の GPU 時間)"]:::done
    editoroverlay["EditorOverlay<br/>ImGui のパネル(時間の操作・状態の表示。--editor)"]:::done
    timecontrol["TimeControl<br/>止める・1 刻み進める・速さ"]:::done
    graphpanel["BuildGraphPanel<br/>Work Graphs と性能(単位ごとの GPU 時間・ノードの数と上限)"]:::done
    labpanel["LabPanel<br/>実験室: 小さな箱に物と温度を置き GPU と CPU を刻みごとに比べる"]:::done
    probeview["ProbeView<br/>抽出の格子を光線で辿る(ボリューム・最大値・断面)"]:::done
    tracecapture["TraceCapture<br/>1 回ぶんのトレースを集めてファイルへ"]:::done
  end
  subgraph simlib["sim(仮の刻み。中身の本物は T-0005 以降)"]
    labsession["LabSession<br/>箱を GPU と CPU リファレンスで並べて刻み、最初に違った刻みとセル"]:::done
    savepoint["ProbeSim の保存点<br/>S(t) を VRAM に写す・戻す(巻き戻し)"]:::done
    probesim["ProbeSim<br/>1 刻み = 単位の列。フレームの枠ごとのリストに毎フレーム記録"]:::done
    probetick["probe_tick.hlsl<br/>EnqueueCommands / ApplyCommands / Busy / HashCells / FlushEvents / Extract"]:::done
    probeconduct["probe_conduct.hlsl(Work Graph)<br/>WakeBlocks → ConductBlock。熱が広がる所・反応が進む所だけ"]:::done
    commandqueue["GPU のコマンドキュー<br/>(targetTick, sequence) の順。適用の単位が先頭から取る"]:::done
    eventsort["刻みのイベントを並べる<br/>一時置き場 → bitonic sort → リング"]:::done
    probereference["ProbeReference<br/>CPU リファレンス(probe_sim.hlsli を共有)"]:::done
    probetrace["probe_trace<br/>刻みごとの木・CPU の予想・食い違いの場所"]:::done
    gasreference["StepGas<br/>気体の流れの CPU リファレンス G1(1 レベル)<br/>力 → 流れ → 風上の割合で移す"]:::done
    gasmoved["ComputeMovedAmounts<br/>気体 G2: 移す成分の物質量<br/>MUSCL(MC の制限)+ 乱数の丸め"]:::done
    gpuphysics["GpuPhysics::RecordStep<br/>広域 → 接触(Work Graph)→ 彩色 → 反復(Compute)→ 仕上げ"]:::done
    probephysics["ProbeSim::RecordPhysics<br/>物の 1 刻みを仮の世界の単位に(伝導の後ろ)"]:::done
    reactiontable["BakeReactionTable<br/>定義 → 整数の表(元素の釣り合いの検査)"]:::done
    multiresnest["MultiresNest<br/>多重解像度の木の CPU リファレンス(影・刻み・合計)"]:::done
    multirestree["ProcessRequests<br/>木の管理: 索引・空きのスタック・要求・帳簿"]:::done
    multiresactivity["StepActive<br/>木の上の活性: 種と面の隣だけ刻む"]:::done
    gpumultires["GpuMultires<br/>木の管理は Compute の段 + Work Graph、刻みは Compute"]:::done
    probepeek["ProbePeek<br/>覗き窓: 世界の写し → 影の鎖 k = 1〜9 → 抽出"]:::done
    multiresquiet["SubmitQuietCoarsenRequests<br/>静かな葉を粗くする要求(枠の順)"]:::done
    multirespages["ExpandWantedPages<br/>一様なブロックを頁に広げる(枠の順)"]:::done
    multiresfold["FoldQuietPages<br/>静かで一様(かほぼ同じ)になった頁を畳む(枠の順)"]:::done
    multiresconduction["ComputeConduction<br/>木の上の熱の伝導(違うレベルの面は細かい側が粗い側の端数へ送る)"]:::done
    multiressubcycle["StepConduction<br/>細かいレベルの熱の刻み(レベルごとの小刻み・粗い刻みの終わりに受け渡す)"]:::done
    gpuconduction["RecordConduction<br/>熱の伝導の GPU の段(印 → 頁 → 端数の枠 → 流れ → 足して反応)"]:::done
    gpusubcycle["RecordSubstepEnd<br/>細かいレベルの熱の刻みの GPU(小刻みの終わりに足して隣を起こす)"]:::done
    implicitcpu["StepImplicit<br/>細かいレベルの熱の陰解法の試作(V サイクル・誤差の見込みで止める・安全網)"]:::done
    implicittree["AddImplicitConduction<br/>細かいレベルの熱の陰解法を木の伝導に(案 a)"]:::done
    gpuimplicit["GpuImplicit::RecordStep<br/>陰解法の GPU の段(V サイクル × 上限・空で抜ける)"]:::done
    gpuimplicitbuild["GpuImplicitBuild::RecordBuild<br/>陰解法の系(未知数・境のセル・面)を GPU の木から作る"]:::done
    gpuimplicitlevels["GpuImplicitLevels::RecordBuild<br/>陰解法の多重格子の段・重みを GPU で作る"]:::done
    gpumultiresimplicit["GpuMultiresImplicit::Record<br/>GPU の伝導の段から陰解法を呼ぶ(系を作る → 段 → 解く → 変化を足す)"]:::done
  end
  subgraph gpulib["gpu(D3D12 の小さな道具)"]
    queue["Queue<br/>キュー + フェンス(Submit・GpuWait・待たずに見る)"]:::done
    swapchain["SwapChain<br/>フリップ・3 枚・待てる(先行 2〜3)"]:::done
    readbackring["ReadbackRing<br/>追記バッファを枠ごとの読み戻しへ(待たない)"]:::done
    gpudevice["Device::Create()<br/>ハードウェアの GPU か WARP・debug layer / GBV / DRED"]:::done
    dred["LogDeviceRemoved()<br/>デバイス喪失の理由・DRED のブレッドクラムとページフォールト"]:::done
    debugring["DebugRing<br/>シェーダーの printf / assert を読み戻してログへ"]:::done
    immediate["ImmediateQueue<br/>1 本記録して投げて待つ(direct / compute)"]:::done
    workgraph["WorkGraph<br/>状態オブジェクト・裏のメモリ・DispatchGraph"]:::done
    graphstats["WorkGraphStats<br/>ノードのカウンタを読み戻し、要約と上限の Warning"]:::done
    graphtrace["GraphTrace<br/>連鎖のトレースの範囲を書き、記録を読み戻す"]:::done
  end
  subgraph shared["shaders/common(HLSL と C++ で共通)"]
    probeworld["probe_world.hlsli<br/>1 セルの伝導 + 反応・つつき・ハッシュ"]:::done
    heatconduction["heat_conduction.hlsli<br/>温度の差の面の流れ(min の係数・1/8 の上限)"]:::done
    fixed["整数の数学ライブラリ(fixed.hlsli)<br/>128bit 積・割り算・平方根・log/exp・sin/cos・乱数"]:::done
    selftest["自己テスト(fixed_selftest)<br/>CPU と GPU が同じ列を計算"]:::done
    debugringhlsl["debug_ring.hlsli<br/>DEBUG_PRINT / DEBUG_ASSERT(ノードからも)"]:::done
    graphstatshlsl["work_graph_stats.hlsli<br/>ノードで数え、上限の手前で止める"]:::done
    graphtracehlsl["graph_trace.hlsli<br/>範囲の中だけ 16 バイトの記録を追記"]:::done
    physicscollide["physics_collision.hlsli<br/>直方体どうしの接触(分離軸・切り抜き・4 点)"]:::done
    physicssolverhlsl["physics_solver.hlsli<br/>拘束の行・物ごとの 6×6 の組み立て"]:::done
    physicssolve["PxSolveSymmetric6<br/>2 の冪の対称スケーリング + Q62 の Cholesky"]:::done
    physicsstep["physics_step.hlsli<br/>物・組・接触点ごとの手順と構造体(CPU と GPU で共通)"]:::done
    physicsgraph["physics_graph.hlsl(Work Graph)<br/>広域の選別 → 接触の幾何 / 色ごとの解(比べた方)"]:::done
    physicspush["physics_push.hlsli<br/>光線で物を押す(最初に入る物・力積)"]:::done
    reactionhlsl["reaction.hlsli<br/>1 セルの反応: 温度・進行度・取り合い・更新"]:::done
    reactionwait["待ちの丸め<br/>遅い反応が次に 1 単位進む刻み"]:::done
    multireshlsl["multires.hlsli<br/>細かくする・粗くする(端数)・影の引き戻し"]:::done
    multirestreehlsl["multires_tree.hlsli<br/>要求・索引の番地・帳簿の約束"]:::done
    multiresactivityhlsl["multires_activity.hlsli<br/>面の隣(粗い側は索引を上へ、細かい側は面を子へ)"]:::done
    multiresconductionhlsl["multires_conduction.hlsli<br/>面の隣・レベルの単位の係数・違うレベルの受け渡し"]:::done
    gpuconductionhlsl["multires_conduct.hlsli<br/>1 ブロックの印・流れ・足す(Compute と Work Graph で共有)"]:::done
    implicithlsl["implicit_conduction.hlsli<br/>陰解法の式(温度・面の流れ・誤差の判定・陽解法の係数)"]:::done
  end
  subgraph tests["テスト(ctest)"]
    firetest["gpu_probe_fire_test<br/>木箱に火をつけて 10 分"]:::done
    conductbench["gpu_conduct_bench<br/>伝播の規模ごとの伝導の時間"]:::done
    probesimtest["gpu_probe_sim_test<br/>分け方を変えても CPU とビット一致・記録 → 再生"]:::done
    fixedtest["fixed_test<br/>128bit 組み込み関数とのビット一致・誤差の測定"]:::done
    gpufixedtest["gpu_fixed_test<br/>自己テストを GPU で走らせ CPU と 1 値ずつ比べる"]:::done
    fixedbench["gpu_fixed_bench<br/>整数のルーチンの費用(タイムスタンプ)"]:::done
    wgtest["gpu_work_graph_test<br/>Root → Leaf の最小のグラフ"]:::done
    ringtest["gpu_debug_ring_test / gpu_debug_device_test<br/>リング・debug layer・DRED"]:::done
    statstest["gpu_work_graph_stats_test<br/>わざと上限に近づけ・越えさせる"]:::done
    gastest["gas_reference_test<br/>保存・静止大気・熱い泡・風で煙<br/>煙のにじみ・微量の成分"]:::done
    probephysicstest["gpu_probe_physics_test<br/>押して崩す積み木が CPU と毎刻みビット一致"]:::done
    gpuphysicstest["gpu_physics_test<br/>3 場面の全部の刻みを GPU と CPU で比べる"]:::done
    physicstest["physics_test<br/>平方根・6×6 と double / 場面の基準・決定性"]:::done
    reactionwaittest["reaction_wait_test<br/>待ちの分布・引き直し・眠らせる・何年分"]:::done
    reactiontest["reaction_test<br/>ベイクの検査・保存則・取り合い・並び・遅い反応"]:::done
    gpureactiontest["gpu_reaction_test<br/>セル 4096 × 400 刻みを GPU と CPU で比べる"]:::done
    peektest["gpu_probe_peek_test<br/>覗く・移る・やめるで CPU とビット一致・ハッシュ列が変わらない"]:::done
    multirestest["multires_test<br/>k = 0〜9 の往復・24 段と帳簿・影・たくさんの要求"]:::done
    gpumultirestest["gpu_multires_test<br/>本物の鎖・影の鎖・たくさんの要求を毎刻み GPU と CPU で比べる"]:::done
    activitytest["multires_activity_test<br/>刻んだ集合 = 総当たりの面の隣・全部刻むのとビット一致"]:::done
    gpuactivitytest["gpu_multires_activity_test<br/>活性の Work Graph を毎刻み CPU と比べる"]:::done
    quiettest["multires_quiet_test / gpu_multires_quiet_test<br/>変わったばかりは粗くしない・燃え尽きたら根まで畳む"]:::done
    uniformtest["multires_uniform_test / gpu_multires_uniform_test<br/>一様な根・鎖は頁を使わない・頁の不足・燃え尽きたら畳む"]:::done
    subcycletest["multires_subcycle_test<br/>物差し(レベルごとの実効の拡散率)・分けても保存量と活性 = 全部"]:::done
    conductiontest["multires_conduction_test<br/>面の隣の総当たり・保存量・活性 = 全部"]:::done
    gpuconductiontest["gpu_multires_conduction_test<br/>鎖・たくさんの要求の伝導を毎刻み GPU と CPU で比べる"]:::done
    implicittreetest["multires_implicit_tree_test<br/>木の物差し・熱い点・鎖・たくさんの要求(保存・活性 = 全部・2 回一致)"]:::done
    gpuimplicitbuildtest["gpu_multires_implicit_build_test<br/>GPU で作った系と解いた結果を CPU と比べる"]:::done
    gpuimplicitconductiontest["gpu_multires_implicit_conduction_test<br/>熱い点・鎖・たくさんの要求を陰解法つきで全部・活性に刻み毎刻み CPU と比べる"]:::done
    gpuimplicittest["gpu_multires_implicit_test<br/>物差しの山・熱い点を毎刻み GPU と CPU で比べる"]:::done
    gpuimplicittreetest["gpu_multires_implicit_tree_test<br/>木の本物の系(熱い点・鎖・たくさんの要求)を GPU で解いて CPU と比べる"]:::done
    tracetest["gpu_probe_trace_test<br/>2 回・分け方で同じ、CPU と一致、わざとずらす"]:::done
  end
  subgraph savelib["save(再生ファイル。CPU だけ)"]
    replayfile["再生ファイル<br/>形式の版・初期状態・コマンドの列・刻みごとのハッシュ"]:::done
    replaysession["ReplayRecorder / ReplayPlayer<br/>--record / --replay の帳簿"]:::done
  end
  subgraph corelib["core(どこからでも使う部品)"]
    log["Log() / Logger(シングルトン)<br/>サブシステム名・重大度つきのログ"]:::done
    checkhr["BICAMERAL_CHECK_HR<br/>HRESULT の失敗を式・場所つきで"]:::done
    sinks["出力先<br/>コンソール / VS 出力 / logs/*.log"]:::done
  end
  subgraph physicslib["physics(整数の AVBD の CPU の世界。T-0016。GPU のリファレンス)"]
    physicsworld["PhysicsWorld::Step<br/>接触 → 引き継ぎ → 彩色 → 反復 → 速度 → 位置"]:::done
    physicsscene["PhysicsScene<br/>原理の確認の場面(積み木・質量比・岩の山)"]:::done
  end
  subgraph labtools["試作の道具(tools/。浮動小数点可)"]
    physicslab["physics_lab<br/>double の試作と整数を同じ場面で比べる"]:::done
  end
  subgraph os["OS / ドライバ"]
    d3d12["d3d12.dll(OS)"]:::external
    core["D3D12Core.dll<br/>Agility SDK 1.619"]:::external
  end
  subgraph build["ビルドの中の検査(CMake + Python)"]
    addshader["bicameral_add_shader()<br/>DXC で sim / render を分けてコンパイル"]:::done
    dxilcheck["dxil_float_check<br/>シミュの DXIL に浮動小数点があれば落とす"]:::done
    srccheck["source_float_check<br/>共通のヘッダ・CPU リファレンスの float / double"]:::done
  end
  main -->|"--caps"| caps
  caps -->|"D3D12CreateDevice"| d3d12
  d3d12 -->|"起動時に読む"| sdkver
  d3d12 -->|"bin/D3D12 から読み込む"| core
  caps -->|"アダプタごと"| device
  caps -->|"デバイス作成後"| runtime
  main -->|"ログファイルを開く"| sinks
  caps -->|"失敗しうる API"| checkhr
  caps -->|"結果"| log
  checkhr -->|"Error"| log
  log --> sinks
  selftest --> fixed
  fixedtest -->|"CPU で要約を作る"| selftest
  fixedtest --> fixed
  addshader -->|"DXC(cs_6_8)"| selftest
  addshader -->|"sim は逆アセンブルを検査"| dxilcheck
  srccheck -->|"トークンを検査"| fixed
  gpufixedtest --> gpudevice
  gpufixedtest -->|"compute キュー"| immediate
  gpufixedtest -->|"GPU(.cso)と CPU で同じ列"| selftest
  fixedbench -->|"演算ごとの .cso(shaders/bench)"| fixed
  fixedbench -->|"タイムスタンプ"| immediate
  addshader -->|"DEFINES で変種"| fixedbench
  wgtest --> workgraph
  wgtest -->|"direct / compute"| immediate
  gpudevice --> d3d12
  gpudevice -->|"debug layer の報告"| log
  immediate -->|"デバイスが失われたら"| dred
  fixed -->|"FX_ASSERT"| debugringhlsl
  reactionhlsl --> fixed
  reactiontable -->|"ベイクも整数(R7)"| fixed
  reactiontable -->|"RxSpecies・RxRule・速度の表"| reactionhlsl
  reactiontest --> reactiontable
  reactionwait -->|"取り合いと更新は同じ関数"| reactionhlsl
  reactionwaittest --> reactionwait
  physicsworld -->|"PxCollideBoxes"| physicscollide
  physicsworld -->|"行・6×6"| physicssolverhlsl
  physicsworld --> physicsscene
  gastest --> gasreference
  gasreference --> gasmoved
  physicssolverhlsl --> physicssolve
  physicssolve --> fixed
  physicstest --> physicsworld
  physicslab -->|"同じ場面で比べる"| physicsworld
  physicsworld -->|"物・組ごとの手順"| physicsstep
  gpuphysics -->|"同じ関数(.cso)"| physicsstep
  gpuphysics -->|"DispatchGraph"| physicsgraph
  physicsgraph --> physicsstep
  physicsstep --> physicscollide
  physicsstep --> physicssolverhlsl
  gpuphysicstest --> gpuphysics
  gpuphysicstest -->|"ビット一致"| physicsworld
  probesim -->|"単位"| probephysics
  probephysics -->|"RecordStep"| gpuphysics
  probetick -->|"押すコマンド"| physicspush
  physicsworld -->|"Push"| physicspush
  probephysicstest --> probephysics
  probephysicstest -->|"ビット一致"| physicsworld
  gpureactiontest -->|"GPU(.cso)と CPU で同じ関数"| reactionhlsl
  multireshlsl -->|"葉のセルを RxStepCellWait で刻む"| reactionwait
  multiresnest --> multireshlsl
  multirestree --> multirestreehlsl
  multirestreehlsl --> multireshlsl
  gpumultires -->|"GPU の段と CPU で同じ関数"| multirestreehlsl
  gpumultires -->|"GPU(.cso)と CPU で同じ関数"| multireshlsl
  multirestest --> multiresnest
  multirestest --> multirestree
  gpumultirestest -->|"毎刻み比べる"| multirestree
  gpumultirestest --> gpumultires
  gpumultirestest -->|"毎刻み比べる"| multiresnest
  probepeek -->|"同じルート署名に u4・u5 を足して"| gpumultires
  multiresactivity --> multiresactivityhlsl
  multiresactivityhlsl -->|"索引で引く"| multirestreehlsl
  gpumultires -->|"ActivitySeedNode・WakeFaceNode(GPU と CPU で同じ関数)"| multiresactivityhlsl
  activitytest --> multiresactivity
  gpuactivitytest --> gpumultires
  gpuactivitytest -->|"毎刻み比べる"| multiresactivity
  multiresquiet -->|"MrWantsQuietCoarsen(GPU と CPU で同じ関数)"| multiresactivityhlsl
  multiresquiet -->|"要求の一覧の後ろに足す"| multirestree
  quiettest --> multiresquiet
  multiresconduction --> multiresconductionhlsl
  multiresconductionhlsl -->|"MrFindContaining で粗い側を引く"| multiresactivityhlsl
  multiresconductionhlsl -->|"端数(ADR-0015)で粗い側が受ける"| multireshlsl
  multiresactivity -->|"options.conduction"| multiresconduction
  conductiontest --> multiresconduction
  multiressubcycle -->|"小刻みごとに"| multiresconduction
  subcycletest --> multiressubcycle
  gpumultires -->|"options.conduction"| gpuconduction
  gpuconduction --> gpuconductionhlsl
  gpuconduction -->|"小刻み"| gpusubcycle
  gpusubcycle -->|"同じ結果"| multiressubcycle
  gpuconductionhlsl -->|"CPU と同じ式"| multiresconductionhlsl
  gpuconductiontest --> gpuconduction
  implicitcpu --> implicithlsl
  implicittree -->|"StepImplicit"| implicitcpu
  multiressubcycle -->|"最後の小刻みの後"| implicittree
  implicittreetest --> implicittree
  gpuimplicit --> implicithlsl
  gpuimplicit -->|"同じ結果"| implicitcpu
  gpuimplicittest --> gpuimplicit
  gpuimplicittreetest --> gpuimplicit
  gpuimplicittreetest --> implicittree
  gpuimplicitbuild -->|"セル・面を写す"| gpuimplicit
  gpuconduction -->|"options.implicitConduction"| gpumultiresimplicit
  gpumultiresimplicit --> gpuimplicitbuild
  gpumultiresimplicit --> gpuimplicitlevels
  gpumultiresimplicit --> gpuimplicit
  gpuimplicitconductiontest --> gpumultiresimplicit
  gpuimplicitbuild -->|"同じ番号"| implicittree
  gpuimplicitbuildtest --> gpuimplicitbuild
  gpuimplicitlevels -->|"系・セルの座標を読む"| gpuimplicitbuild
  gpuimplicitlevels -->|"節・隣・子の一覧を写す"| gpuimplicit
  gpuimplicitlevels -->|"BuildImplicitGrid と同じ番号"| implicitcpu
  gpuimplicitbuildtest --> gpuimplicitlevels
  quiettest -->|"毎刻み比べる"| gpumultires
  multiresactivity -->|"反応が進む一様なブロック"| multirespages
  multirespages -->|"頁の空きのスタック"| multirestree
  uniformtest --> multirespages
  multiresfold -->|"MrWantsFoldCheck(GPU と CPU で同じ関数)"| multiresactivityhlsl
  multiresfold -->|"頁の空きのスタックへ返す"| multirestree
  uniformtest --> multiresfold
  uniformtest -->|"毎刻み比べる"| gpumultires
  probesim -->|"抽出の後のフック"| probepeek
  viewcontroller -->|"P・PageDown → 覗く場所"| frameloop
  peektest --> probepeek
  gpureactiontest -->|"compute キュー"| immediate
  debugringhlsl -->|"読み戻し(フレームの終わり)"| debugring
  debugring -->|"Channel::Gpu / WorkGraph"| log
  ringtest --> debugring
  ringtest -->|"ノードから print"| workgraph
  graphstatshlsl -->|"読み戻し(フレームの終わり)"| graphstats
  graphstats -->|"要約(Trace)・上限(Warning)"| log
  graphstats --> readbackring
  statstest --> graphstats
  statstest -->|"出力の上限・再帰の深さ"| workgraph
  main -->|"引数なし"| frameloop
  frameloop -->|"入力"| window
  frameloop -->|"入力・描画の定数"| viewcontroller
  viewcontroller --> debugcamera
  frameloop -->|"--screenshot"| screenshot
  screenshot -->|"BMP(ctest)"| imagecompare
  frameloop -->|"単位の数"| scheduler
  frameloop -->|"状態 → パネル"| editoroverlay
  editoroverlay -->|"止める・1 刻み・速さ"| timecontrol
  timecontrol -->|"始めてよい刻み"| scheduler
  editoroverlay -->|"性能の表"| graphpanel
  editoroverlay -->|"実験室"| labpanel
  labpanel -->|"置く・刻む・再生"| labsession
  frameloop -->|"写す・戻す(巻き戻し)"| savepoint
  frameloop -->|"予算ぶんの単位(compute キュー)・トレースの範囲"| probesim
  probesim -->|"DispatchGraph(GPU の入力)"| probeconduct
  conductbench --> probesim
  frameloop -->|"記録済みのリスト(direct キュー)"| probeview
  frameloop -->|"Submit・GpuWait"| queue
  frameloop -->|"WaitForFrame・Present"| swapchain
  probesim -->|".cso"| probetick
  probesim -->|"イベント"| readbackring
  probesim -->|"枠ごとの読み戻し"| debugring
  probesim -->|"枠ごとの読み戻し"| graphstats
  probeconduct -->|"起動・出力の数"| graphstatshlsl
  probeconduct -->|"起こす・計算した"| graphtracehlsl
  probetick -->|"つつき"| graphtracehlsl
  graphtracehlsl -->|"読み戻し(フレームの終わり)"| graphtrace
  graphtrace --> readbackring
  probesim -->|"枠ごとの読み戻し"| graphtrace
  frameloop -->|"--trace・T"| tracecapture
  tracecapture -->|"木にして書く"| probetrace
  probetrace -->|"予想"| probereference
  tracetest --> probesim
  tracetest -->|"並べて比べる・食い違いの場所"| probetrace
  debugring --> readbackring
  probesimtest --> probesim
  probesimtest -->|"要約を比べる"| probereference
  firetest -->|"36,000 刻み"| probesim
  probeconduct -->|"1 セルの伝導 + 反応"| probeworld
  probereference -->|"同じ関数"| probeworld
  probeworld --> heatconduction
  probeworld -->|"RxStepCellWait"| reactionhlsl
  probesimtest -->|"記録 → 書く → 読む → 再生"| replaysession
  probetick --> commandqueue
  probetick --> eventsort
  eventsort -->|"刻みの順"| readbackring
  frameloop -->|"--record / --replay"| replaysession
  replaysession --> replayfile
  readbackring -.->|"数フレーム後に読む"| frameloop
  click main href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/main.cpp#L399-L404" _blank
  click frameloop href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/frame/frame_loop.cpp#L1705-L1722" _blank
  click window href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/platform/window.cpp#L32-L57" _blank
  click viewcontroller href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/render/debug_view_controller.cpp#L57-L70" _blank
  click debugcamera href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/render/debug_camera.cpp#L135-L167" _blank
  click screenshot href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/render/screenshot.cpp#L81-L101" _blank
  click imagecompare href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tools/image_compare/image_compare.py#L192-L420" _blank
  click scheduler href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/frame/sim_scheduler.cpp#L58-L93" _blank
  click editoroverlay href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/editor/editor_overlay.cpp#L215-L229" _blank
  click timecontrol href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/editor/time_control.cpp#L8-L30" _blank
  click graphpanel href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/editor/graph_panel.cpp#L115-L132" _blank
  click labpanel href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/editor/lab_panel.cpp#L90-L121" _blank
  click labsession href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/lab_session.cpp#L78-L118" _blank
  click savepoint href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/probe_save_point.cpp#L164-L194" _blank
  click probeview href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/render/probe_view.cpp#L57-L84" _blank
  click queue href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/queue.cpp#L28-L36" _blank
  click swapchain href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/swap_chain.cpp#L22-L71" _blank
  click readbackring href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/readback_ring.cpp#L42-L59" _blank
  click probesim href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/probe_sim.cpp#L524-L612" _blank
  click probetick href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/sim/probe_tick.hlsl#L132-L153" _blank
  click probeconduct href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/sim/probe_conduct.hlsl#L28-L39" _blank
  click probeworld href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/probe_world.hlsli#L81-L119" _blank
  click heatconduction href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/heat_conduction.hlsli#L84-L96" _blank
  click firetest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_probe_fire_test.cpp#L137-L207" _blank
  click conductbench href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_conduct_bench.cpp#L138-L176" _blank
  click commandqueue href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/sim/probe_tick.hlsl#L75-L110" _blank
  click eventsort href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/sim/probe_tick.hlsl#L159-L178" _blank
  click replayfile href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/save/replay_file.cpp#L105-L134" _blank
  click replaysession href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/save/replay_session.cpp#L58-L80" _blank
  click probereference href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/probe_sim.cpp#L1183-L1233" _blank
  click probesimtest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_probe_sim_test.cpp#L271-L272" _blank
  click caps href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/platform/caps.cpp#L175-L234" _blank
  click runtime href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/platform/caps.cpp#L41-L52" _blank
  click device href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/platform/caps.cpp#L80-L117" _blank
  click sdkver href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/platform/agility_sdk.cpp#L13" _blank
  click log href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/core/log.h#L140-L147" _blank
  click checkhr href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/core/hresult.cpp#L99-L110" _blank
  click sinks href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/core/log_sinks.cpp#L168-L196" _blank
  click fixed href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/fixed.hlsli#L115-L129" _blank
  click selftest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/fixed_selftest.hlsli#L29-L72" _blank
  click fixedtest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/fixed_test.cpp#L359-L370" _blank
  click gpudevice href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/device.cpp#L313-L333" _blank
  click dred href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/device.cpp#L379-L411" _blank
  click debugring href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/debug_ring.cpp#L188-L229" _blank
  click debugringhlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/debug_ring.hlsli#L60-L65" _blank
  click immediate href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/immediate_queue.cpp#L42-L66" _blank
  click workgraph href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/work_graph.cpp#L35-L67" _blank
  click gpufixedtest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_fixed_test.cpp#L128-L140" _blank
  click fixedbench href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_fixed_bench.cpp#L144-L182" _blank
  click wgtest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_work_graph_test.cpp#L36-L77" _blank
  click ringtest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_debug_ring_test.cpp#L269-L287" _blank
  click graphstats href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/work_graph_stats.cpp#L195-L212" _blank
  click graphstatshlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/work_graph_stats.hlsli#L100-L105" _blank
  click statstest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_work_graph_stats_test.cpp#L303-L332" _blank
  click graphtrace href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/gpu/graph_trace.cpp#L113-L136" _blank
  click graphtracehlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/graph_trace.hlsli#L100-L108" _blank
  click probetrace href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/probe_trace.cpp#L219-L250" _blank
  click physicsworld href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/physics_world.cpp#L50-L57" _blank
  click gasreference href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gas_reference.cpp#L748-L754" _blank
  click gasmoved href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gas_reference.cpp#L531-L545" _blank
  click gastest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gas_reference_test.cpp#L114-L135" _blank
  click physicsscene href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/physics_scene.cpp#L170-L187" _blank
  click physicscollide href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/physics_collision.hlsli#L380-L444" _blank
  click physicssolverhlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/physics_solver.hlsli#L112-L122" _blank
  click physicssolve href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/physics_math.hlsli#L418-L447" _blank
  click physicsstep href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/physics_step.hlsli#L360-L373" _blank
  click gpuphysics href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_physics.cpp#L347-L375" _blank
  click physicsgraph href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/sim/physics_bindings.hlsli#L210-L218" _blank
  click physicspush href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/physics_push.hlsli#L57-L83" _blank
  click probephysics href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/probe_sim.cpp#L809-L815" _blank
  click probephysicstest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_probe_physics_test.cpp#L182-L212" _blank
  click gpuphysicstest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_physics_test.cpp#L146-L204" _blank
  click physicstest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/physics_test.cpp#L288-L343" _blank
  click physicslab href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tools/physics_lab/avbd_solver.cpp#L87-L94" _blank
  click reactionhlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/reaction.hlsli#L716-L720" _blank
  click reactionwait href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/reaction.hlsli#L915-L947" _blank
  click reactionwaittest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/reaction_wait_test.cpp#L377-L420" _blank
  click reactiontable href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/reaction_table.cpp#L373-L406" _blank
  click reactiontest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/reaction_test.cpp#L160-L170" _blank
  click gpureactiontest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_reaction_test.cpp#L162-L193" _blank
  click multireshlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/multires.hlsli#L427-L481" _blank
  click multiresnest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_nest.cpp#L442-L449" _blank
  click multirestree href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_tree.cpp#L501-L523" _blank
  click multirestreehlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/multires_tree.hlsli#L119-L126" _blank
  click multiresactivity href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_activity.cpp#L199-L226" _blank
  click multiresactivityhlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/multires_activity.hlsli#L118-L151" _blank
  click gpumultires href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_multires.cpp#L706-L732" _blank
  click probepeek href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/probe_peek.cpp#L106-L145" _blank
  click peektest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_probe_peek_test.cpp#L201-L267" _blank
  click multirestest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/multires_test.cpp#L39-L65" _blank
  click gpumultirestest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_multires_test.cpp#L249-L289" _blank
  click activitytest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/multires_activity_test.cpp#L81-L132" _blank
  click gpuactivitytest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_multires_activity_test.cpp#L117-L162" _blank
  click multiresquiet href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_activity.cpp#L162-L181" _blank
  click quiettest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/multires_quiet_test.cpp#L148-L191" _blank
  click multirespages href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_nest.cpp#L355-L379" _blank
  click multiresfold href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_activity.cpp#L49-L55" _blank
  click uniformtest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/multires_uniform_test.cpp#L139-L174" _blank
  click multiresconduction href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_conduction.cpp#L290-L308" _blank
  click multiressubcycle href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_conduction.cpp#L310-L341" _blank
  click subcycletest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/multires_subcycle_test.cpp#L135-L160" _blank
  click multiresconductionhlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/multires_conduction.hlsli#L225-L264" _blank
  click conductiontest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/multires_conduction_test.cpp#L266-L298" _blank
  click gpuconduction href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_multires.cpp#L888-L907" _blank
  click gpusubcycle href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_multires.cpp#L937-L971" _blank
  click gpuconductionhlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/sim/multires_conduct.hlsli#L397-L440" _blank
  click gpuconductiontest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_multires_conduction_test.cpp#L268-L292" _blank
  click implicitcpu href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/implicit_conduction.cpp#L711-L747" _blank
  click implicittree href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/multires_implicit_conduction.cpp#L252-L288" _blank
  click implicittreetest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/multires_implicit_tree_test.cpp#L245-L288" _blank
  click implicithlsl href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/common/implicit_conduction.hlsli#L256-L269" _blank
  click gpuimplicit href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_implicit.cpp#L586-L646" _blank
  click gpuimplicitbuild href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_implicit_build.cpp#L203-L209" _blank
  click gpuimplicitlevels href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_implicit_levels.cpp#L245-L300" _blank
  click gpuimplicitbuildtest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_multires_implicit_build_test.cpp#L376-L441" _blank
  click gpumultiresimplicit href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/sim/gpu_multires_implicit.cpp#L64-L97" _blank
  click gpuimplicitconductiontest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_multires_implicit_conduction_test.cpp#L356-L412" _blank
  click gpuimplicittest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_multires_implicit_test.cpp#L114-L146" _blank
  click gpuimplicittreetest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_multires_implicit_tree_test.cpp#L295-L320" _blank
  click tracecapture href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/engine/src/frame/trace_capture.cpp#L31-L52" _blank
  click tracetest href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tests/gpu_probe_trace_test.cpp#L379-L413" _blank
  click d3d12 href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/docs/decisions/ADR-0004-agility-sdk-and-dxc.md" _blank
  click core href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/docs/decisions/ADR-0004-agility-sdk-and-dxc.md" _blank
  click addshader href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/shaders/CMakeLists.txt#L28-L40" _blank
  click dxilcheck href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tools/float_check/dxil_float_check.py#L32" _blank
  click srccheck href "https://github.com/Petaf000/BicameralEngine/blob/bdf518d5323e8bc015bc67d41cdae19ec8cc23c6/tools/float_check/source_float_check.py#L52" _blank
  classDef done fill:#dff3e4,stroke:#2f7d45,color:#12351d
  classDef planned fill:#f4f4f5,stroke:#8a8a93,color:#3f3f46,stroke-dasharray:5 4
  classDef research fill:#fdf1dc,stroke:#b7791f,color:#5b3a0a,stroke-dasharray:2 3
  classDef external fill:#e8eefc,stroke:#4a64a8,color:#1b2a52
ノード状態どこメモ
wmain() — コマンドラインの振り分け動いているengine/src/main.cpp:399
RunFrameLoop() — 待ち → 読み戻し → 入力 → シミュ → 描画 → Present動いているengine/src/frame/frame_loop.cpp:17051 フレームに予算ぶんの単位だけ投げ、後ろに描画(ADR-0011)。抽出は 3 組、描画は終わっている最新を読む
Window — Win32 の窓・入力(ボタン・ドラッグ・ホイール・キー)・DPI動いているengine/src/platform/window.cpp:32
DebugViewController — 入力 → カメラ・表示の切り替え・つつくセル・T動いているengine/src/render/debug_view_controller.cpp:57カメラと表示は View の状態で、世界には入らない(D-107)。つつきだけがコマンドになる
OrbitCamera・PickSliceCell — 格子を回るカメラ・光線が断面に当たるセル動いているengine/src/render/debug_camera.cpp:135描画(probe_view.hlsl)と同じ式で光線を作る。debug_camera_test で画素 → セルの往復を確かめる
ScreenshotCapture — 最後のフレームか刻み t の画面を BMP に(--screenshot)動いているengine/src/render/screenshot.cpp:81--screenshot-tick t: 刻み t の始めで止め、S(t) を描いたフレームを写す(T-0025。16 §5)
image_compare.py — 基準の画像(tests/images)と許容差で比べる・差の画像動いているtools/image_compare/image_compare.py:192色の差 > 8 の画素が 0.1 % を超えたら失敗。ctest image_*(gpu)・image_compare_selftest(CI)
SimScheduler — 1 フレームに投げる単位の数(予算・単位の GPU 時間)動いているengine/src/frame/sim_scheduler.cpp:58予算 = 1000 / 目標 fps − 描画 − 余裕。刻みはフレームをまたぐ。追いつけない分は捨てる(D-202)。sim_scheduler_test
EditorOverlay — ImGui のパネル(時間の操作・状態の表示。--editor)動いているengine/src/editor/editor_overlay.cpp:215描画の後・Present の前に重ねる。パネルの上の入力はカメラとつつきに渡さない。世界には触れない(D-107)
TimeControl — 止める・1 刻み進める・速さ動いているengine/src/editor/time_control.cpp:8始めてよい刻みの数だけを変える。世界のコマンドに入らず、再生のハッシュ列は変わらない。time_control_test
BuildGraphPanel — Work Graphs と性能(単位ごとの GPU 時間・ノードの数と上限)動いているengine/src/editor/graph_panel.cpp:115直近 1 秒の読み戻し(単位のタイムスタンプ・T-0008 のカウンタ)を表に。ノードごとの時間は測れない(DispatchGraph の前後だけ)
LabPanel — 実験室: 小さな箱に物と温度を置き GPU と CPU を刻みごとに比べる動いているengine/src/editor/lab_panel.cpp:90置く操作はコマンド(LAB_COMMAND_TYPE_*)。断面の温度・選んだセルの成分を CPU と GPU で並べる。記録の保存と再生。window_lab
LabSession — 箱を GPU と CPU リファレンスで並べて刻み、最初に違った刻みとセル動いているengine/src/sim/lab_session.cpp:78GpuLabBox(lab_box.hlsl でコマンドを当てる → GpuMultires::RecordStep)と StepLabBox(同じ関数 → StepNest)。gpu_lab_box・lab_box
ProbeSim の保存点 — S(t) を VRAM に写す・戻す(巻き戻し)動いているengine/src/sim/probe_save_point.cpp:164GPU → GPU のコピー(読み戻しなし)。戻すとコマンドキューを空にし、刻み t 以降のコマンドを足し直す。gpu_probe_rewind・window_replay_rewind
ProbeView — 抽出の格子を光線で辿る(ボリューム・最大値・断面)動いているengine/src/render/probe_view.cpp:57画面いっぱいの三角形 1 枚。重ね書き: 格子の枠・断面の枠・活性なブロック・色の凡例
Queue — キュー + フェンス(Submit・GpuWait・待たずに見る)動いているengine/src/gpu/queue.cpp:28
SwapChain — フリップ・3 枚・待てる(先行 2〜3)動いているengine/src/gpu/swap_chain.cpp:22
ReadbackRing — 追記バッファを枠ごとの読み戻しへ(待たない)動いているengine/src/gpu/readback_ring.cpp:42
ProbeSim — 1 刻み = 単位の列。フレームの枠ごとのリストに毎フレーム記録動いているengine/src/sim/probe_sim.cpp:524適用 → 伝導と反応(Work Graph。T-0005・T-0089)→ 重さ × k → 検査と出力。コマンドは GPU のキューで自分の刻みまで待つ(T-0086)。単位ごとのタイムスタンプ・刻みごとのハッシュ・エネルギーの合計とつつきの分・計算したブロックの数・イベントを読み戻す。初めの世界(空気の中の木箱)と反応の表は最初のフレームで写す
probe_tick.hlsl — EnqueueCommands / ApplyCommands / Busy / HashCells / FlushEvents / Extract動いているshaders/sim/probe_tick.hlsl:132
probe_conduct.hlsl(Work Graph) — WakeBlocks → ConductBlock。熱が広がる所・反応が進む所だけ動いているshaders/sim/probe_conduct.hlsl:28入力は GPU の活性の一覧(DispatchGraph の GPU の入力)。ConductBlock が伝導 → 反応(T-0089。待ちの丸めは T-0122)。変わったか、次の刻みに評価の要るブロックが次の刻みの一覧へ、ほかは起こす刻みを書いて眠り、適用の単位の WakeDueBlocks が起こす
probe_world.hlsli — 1 セルの伝導 + 反応・つつき・ハッシュ動いているshaders/common/probe_world.hlsli:81GPU(ConductBlock)と CPU リファレンスが同じ関数。熱のキャッシュ(温度・面の係数)はセルから決まる値
heat_conduction.hlsli — 温度の差の面の流れ(min の係数・1/8 の上限)動いているshaders/common/heat_conduction.hlsli:84両側が同じ大きさで逆向きを計算するのでエネルギーは構造的に保存。伝導率は物質の値(試験の表は大きくしてある)
gpu_probe_fire_test — 木箱に火をつけて 10 分動いているtests/gpu_probe_fire_test.cpp:137刻みごとのエネルギー・最後の元素・もう一度走らせて同じ・燃え広がる(1 秒ごとの経過)。ctest は 1 分、10 分は release で
gpu_conduct_bench — 伝播の規模ごとの伝導の時間動いているtests/gpu_conduct_bench.cpp:138ctest に入れない計測(docs/perf.md)。1 点のつつきが止まるまでと、熱の保存
GPU のコマンドキュー — (targetTick, sequence) の順。適用の単位が先頭から取る動いているshaders/sim/probe_tick.hlsl:75足すのは CPU だけ(末尾と空きを CPU が控える: ProbeSim::FreeCommandSlots)
刻みのイベントを並べる — 一時置き場 → bitonic sort → リング動いているshaders/sim/probe_tick.hlsl:159(刻み, 種類, 場所) の順。溢れたら落とした数を数える
再生ファイル — 形式の版・初期状態・コマンドの列・刻みごとのハッシュ動いているengine/src/save/replay_file.cpp:105replay_file_test(CPU)
ReplayRecorder / ReplayPlayer — --record / --replay の帳簿動いているengine/src/save/replay_session.cpp:58再生は数刻み先まで先にキューへ足し、読み戻したハッシュを突き合わせる
ProbeReference — CPU リファレンス(probe_sim.hlsli を共有)動いているengine/src/sim/probe_sim.cpp:1183
gpu_probe_sim_test — 分け方を変えても CPU とビット一致・記録 → 再生動いているtests/gpu_probe_sim_test.cpp:271単位の分け方 5 通りで(ハードウェアだけ。ADR-0013)、刻みごとのハッシュ列・最後の抽出・並んだイベントが CPU と一致。木箱の壁をつついて反応させる(T-0089)。イベントの溢れ。途中で届くコマンドを記録して別の分け方で再生(T-0086)。窓の記録 → 再生は ctest の window_replay_*
RunCapsProbe() — アダプタを列挙して機能を問い合わせる動いているengine/src/platform/caps.cpp:175
ReportRuntime() — どの D3D12Core.dll が読まれたか動いているengine/src/platform/caps.cpp:41
ReportDevice() — SM / DXR / Mesh / Work Graphs の tier動いているengine/src/platform/caps.cpp:80
D3D12SDKVersion / D3D12SDKPath — Agility SDK のエクスポート動いているengine/src/platform/agility_sdk.cpp:13ADR-0004。D3D12Core.dll は CMake が bin/D3D12 にコピーする
Log() / Logger(シングルトン) — サブシステム名・重大度つきのログ動いているengine/src/core/log.h:140
BICAMERAL_CHECK_HR — HRESULT の失敗を式・場所つきで動いているengine/src/core/hresult.cpp:99
出力先 — コンソール / VS 出力 / logs/*.log動いているengine/src/core/log_sinks.cpp:168ログは exe の横の logs/(ADR-0006)
整数の数学ライブラリ(fixed.hlsli) — 128bit 積・割り算・平方根・log/exp・sin/cos・乱数動いているshaders/common/fixed.hlsli:1151 つのソースを HLSL と C++ で使う(D-307)
自己テスト(fixed_selftest) — CPU と GPU が同じ列を計算動いているshaders/common/fixed_selftest.hlsli:29ビルドで DXC が通す。GPU で走らせて比べるのは T-0013
fixed_test — 128bit 組み込み関数とのビット一致・誤差の測定動いているtests/fixed_test.cpp:359
Device::Create() — ハードウェアの GPU か WARP・debug layer / GBV / DRED動いているengine/src/gpu/device.cpp:313debug プリセットで検証を有効化。debug layer の報告はログへ流して数える(テストは 0 件を確かめる)
LogDeviceRemoved() — デバイス喪失の理由・DRED のブレッドクラムとページフォールト動いているengine/src/gpu/device.cpp:379
DebugRing — シェーダーの printf / assert を読み戻してログへ動いているengine/src/gpu/debug_ring.cpp:188書式の番号 + 整数の引数だけを GPU が書き、文字列は CPU が持つ(debug_formats.hlsli)
debug_ring.hlsli — DEBUG_PRINT / DEBUG_ASSERT(ノードからも)動いているshaders/common/debug_ring.hlsli:60u0 space1。Debug のシミュのシェーダーだけ有効(FX_ASSERT もここへ)
ImmediateQueue — 1 本記録して投げて待つ(direct / compute)動いているengine/src/gpu/immediate_queue.cpp:42テストと準備用。フレームのループは待たない別の仕組み(T-0012)
WorkGraph — 状態オブジェクト・裏のメモリ・DispatchGraph動いているengine/src/gpu/work_graph.cpp:35
gpu_fixed_test — 自己テストを GPU で走らせ CPU と 1 値ずつ比べる動いているtests/gpu_fixed_test.cpp:128ハードウェアと WARP、debug(-Od)と release で一致
gpu_fixed_bench — 整数のルーチンの費用(タイムスタンプ)動いているtests/gpu_fixed_bench.cpp:144ctest に入れない計測。shaders/bench を演算ごとにコンパイル。DXIL の命令数は tools/fixed_bench/dxil_count.py
gpu_work_graph_test — Root → Leaf の最小のグラフ動いているtests/gpu_work_graph_test.cpp:36direct / compute キュー × ハードウェア / WARP。64bit atomic
gpu_debug_ring_test / gpu_debug_device_test — リング・debug layer・DRED動いているtests/gpu_debug_ring_test.cpp:269compute とノードからの print、溢れ、空に戻るか。わざと誤った呼び出しとデバイスの喪失
WorkGraphStats — ノードのカウンタを読み戻し、要約と上限の Warning動いているengine/src/gpu/work_graph_stats.cpp:195起動・入出力のレコードの数・再帰の深さ・容量の計器。同じ Warning は 600 回の報告に 1 回
work_graph_stats.hlsli — ノードで数え、上限の手前で止める動いているshaders/common/work_graph_stats.hlsli:100u1 space1。Release でも有効(越えると未定義の動作なので、止めて数える)
gpu_work_graph_stats_test — わざと上限に近づけ・越えさせる動いているtests/gpu_work_graph_stats_test.cpp:303カウンタが CPU の予想と一致・止めた数・Warning・ノードの printf の場所
GraphTrace — 連鎖のトレースの範囲を書き、記録を読み戻す動いているengine/src/gpu/graph_trace.cpp:113容量は作った時に固定。範囲(刻み・場所の箱)は SetFilter で実行中に変え、次の RecordBegin で GPU へ(T-0088)。無効のフレームは見出しだけ読み戻す
graph_trace.hlsli — 範囲の中だけ 16 バイトの記録を追記動いているshaders/common/graph_trace.hlsli:100u2 space1。順番に依存しない事実だけ書く(親は CPU が決まった規則で選ぶ)
probe_trace — 刻みごとの木・CPU の予想・食い違いの場所動いているengine/src/sim/probe_trace.cpp:219--trace でファイルへ。FirstDivergentTick → FindCellDivergence(16 §3 の最初の形)
PhysicsWorld::Step — 接触 → 引き継ぎ → 彩色 → 反復 → 速度 → 位置動いているengine/src/sim/physics_world.cpp:50研究 R-PHYS-1。刻みの初めで線形化した接触を拡張ラグランジュ法で。値の幅は PhysicsStepStats に記録
StepGas — 気体の流れの CPU リファレンス G1(1 レベル) — 力 → 流れ → 風上の割合で移す動いているengine/src/sim/gas_reference.cpp:748圧縮性の有限体積・音速を落とした c̃(Q11 は仮で C)・基準の静水圧との差・前進・後退の順。ADR-0043
ComputeMovedAmounts — 気体 G2: 移す成分の物質量 — MUSCL(MC の制限)+ 乱数の丸め動いているengine/src/sim/gas_reference.cpp:531煙のにじみを約 1/6 に(広がりの増え方)。端数は (シード, 小刻み, 面, 用途) の乱数で丸め、微量の成分も動く(R6・D-428)。ADR-0043 §6
gas_reference_test — 保存・静止大気・熱い泡・風で煙 — 煙のにじみ・微量の成分動いているtests/gas_reference_test.cpp:114
PhysicsScene — 原理の確認の場面(積み木・質量比・岩の山)動いているengine/src/sim/physics_scene.cpp:170
physics_collision.hlsli — 直方体どうしの接触(分離軸・切り抜き・4 点)動いているshaders/common/physics_collision.hlsli:380
physics_solver.hlsli — 拘束の行・物ごとの 6×6 の組み立て動いているshaders/common/physics_solver.hlsli:112
PxSolveSymmetric6 — 2 の冪の対称スケーリング + Q62 の Cholesky動いているshaders/common/physics_math.hlsli:418対角を [2^60, 2^62) に揃えると |L| ≤ 1 で溢れない。硬さの上限 = 軽い方の M/h² × 2^20 で条件数を抑える
physics_step.hlsli — 物・組・接触点ごとの手順と構造体(CPU と GPU で共通)動いているshaders/common/physics_step.hlsli:360順番に依存しない: 6×6 への足し込みは整数の和、β は最大値、彩色は前の回の色だけを読む
GpuPhysics::RecordStep — 広域 → 接触(Work Graph)→ 彩色 → 反復(Compute)→ 仕上げ動いているengine/src/sim/gpu_physics.cpp:347shaders/sim/physics_step.hlsl。色ごとの解は 1 グループ = 1 物(点ごとの寄与を整数の和で)。使わない色は述語で飛ばす(T-0094)。WG と Compute は測って選んだ(ADR-0002「計測」)
physics_graph.hlsl(Work Graph) — 広域の選別 → 接触の幾何 / 色ごとの解(比べた方)動いているshaders/sim/physics_bindings.hlsli:210組(3 KB)をノードの局所に持つと GPU が固まる(約 5〜6 KB 超)ので、組を作るのは Compute の BuildManifolds
physics_push.hlsli — 光線で物を押す(最初に入る物・力積)動いているshaders/common/physics_push.hlsli:57CPU は PhysicsWorld::Push、GPU は probe_tick.hlsl の ApplyPush。CPU は物の場所を知らない(D-107)
ProbeSim::RecordPhysics — 物の 1 刻みを仮の世界の単位に(伝導の後ろ)動いているengine/src/sim/probe_sim.cpp:809物のハッシュは刻みの最後の単位(StoreBodyHash)、姿勢は抽出の物の欄へ。窓は Shift + 左クリックで押す
gpu_probe_physics_test — 押して崩す積み木が CPU と毎刻みビット一致動いているtests/gpu_probe_physics_test.cpp:1822 回目は別のキューに雑音を流し、単位を 1 つずつ投げる(組を局所に持つと結果が変わった件の再発の検査)
gpu_physics_test — 3 場面の全部の刻みを GPU と CPU で比べる動いているtests/gpu_physics_test.cpp:146区間ごとに状態のハッシュと統計。GPU は 2 回走らせて一致も見る。GPU-based validation は切る(計装が終わらない)
physics_test — 平方根・6×6 と double / 場面の基準・決定性動いているtests/physics_test.cpp:288release では FX_ASSERT を有効にした checked 版でも全部の刻みを走らせる(桁あふれの確認)
physics_lab — double の試作と整数を同じ場面で比べる動いているtools/physics_lab/avbd_solver.cpp:87--integer で整数。--out で軌跡、plot_lab.py で画像
reaction.hlsli — 1 セルの反応: 温度・進行度・取り合い・更新動いているshaders/common/reaction.hlsli:716HLSL と C++ で共通。量は物質量(µmol。ADR-0012)。エネルギーの合計は変えない。端数は待ちで丸める(ADR-0018)
待ちの丸め — 遅い反応が次に 1 単位進む刻み動いているshaders/common/reaction.hlsli:915ブロックが最後に変わった刻みから幾何分布の待ち(ADR-0018)。眠らせても全部とビット一致。今までの丸めは T-0130 で消した
reaction_wait_test — 待ちの分布・引き直し・眠らせる・何年分動いているtests/reaction_wait_test.cpp:377
BakeReactionTable — 定義 → 整数の表(元素の釣り合いの検査)動いているengine/src/sim/reaction_table.cpp:373Arrhenius を温度 1 K ごとの表に(整数の ln・exp。R7)。試験の表は reaction_test_table(物質 7・規則 5)
reaction_test — ベイクの検査・保存則・取り合い・並び・遅い反応動いているtests/reaction_test.cpp:160
gpu_reaction_test — セル 4096 × 400 刻みを GPU と CPU で比べる動いているtests/gpu_reaction_test.cpp:162shaders/sim/reaction_cells.hlsl(1 スレッド = 1 セル)。WARP は GBV を切る(計装が終わらない)
multires.hlsli — 細かくする・粗くする(端数)・影の引き戻し動いているshaders/common/multires.hlsli:427比 2 のブロック(8³、子は親の 1/8)。単位はレベルごとに 1/8。粗くした余りは 64bit の端数(21 段の往復までビット一致)
MultiresNest — 多重解像度の木の CPU リファレンス(影・刻み・合計)動いているengine/src/sim/multires_nest.cpp:442ライブラリ bicameral_multires(GPU を知らない)。保存量の合計は 256bit で最も細かい単位 × 2^-64(世界 + 帳簿)
ProcessRequests — 木の管理: 索引・空きのスタック・要求・帳簿動いているengine/src/sim/multires_tree.cpp:501解決 → 確定 → 割り当て → 適用 → 解放 → 索引の作り直し。枠の番号は要求の順の累積和で決まる(CPU と GPU で配列のまま一致)
multires_tree.hlsli — 要求・索引の番地・帳簿の約束動いているshaders/common/multires_tree.hlsli:119
StepActive — 木の上の活性: 種と面の隣だけ刻む動いているengine/src/sim/multires_activity.cpp:199種 = 前の刻みに進める反応があった・木の変更でつつかれた。印(activeTick)を付けて刻む。全部を刻む StepNest とビット一致
multires_activity.hlsli — 面の隣(粗い側は索引を上へ、細かい側は面を子へ)動いているshaders/common/multires_activity.hlsli:118
GpuMultires — 木の管理は Compute の段 + Work Graph、刻みは Compute動いているengine/src/sim/gpu_multires.cpp:706shaders/sim/multires_tree.hlsl(段)・multires_graph.hlsl(細かくする鎖の再帰・粗くする要求・影)・multires_step.hlsl
ProbePeek — 覗き窓: 世界の写し → 影の鎖 k = 1〜9 → 抽出動いているengine/src/sim/probe_peek.cpp:106ProbeSim の抽出の後のフック。世界のバッファは読むだけ(D-403)。shaders/sim/multires_peek.hlsl(MirrorWorld・ExtractShadow)
gpu_probe_peek_test — 覗く・移る・やめるで CPU とビット一致・ハッシュ列が変わらない動いているtests/gpu_probe_peek_test.cpp:201
multires_test — k = 0〜9 の往復・24 段と帳簿・影・たくさんの要求動いているtests/multires_test.cpp:39
gpu_multires_test — 本物の鎖・影の鎖・たくさんの要求を毎刻み GPU と CPU で比べる動いているtests/gpu_multires_test.cpp:249状態の全部が配列のまま一致・GPU の索引で本物のブロックが全部引ける。WARP でも通る(T-0097 の WARP)
multires_activity_test — 刻んだ集合 = 総当たりの面の隣・全部刻むのとビット一致動いているtests/multires_activity_test.cpp:81
gpu_multires_activity_test — 活性の Work Graph を毎刻み CPU と比べる動いているtests/gpu_multires_activity_test.cpp:117状態の全部(活性の印も)と次の刻みの種の集合が一致。WARP でも通る
SubmitQuietCoarsenRequests — 静かな葉を粗くする要求(枠の順)動いているengine/src/sim/multires_activity.cpp:162N(MR_QUIET_TICKS)刻みを超えて変わっていない本物の葉で、子のセル 2×2×2 の組ごとの差が許容差の中のものだけ(D-430。静かになって初めての時に 1 回調べる CheckQuietLeaves)。兄弟は粗くできるものの八分の一の番号の小さい 1 つだけ。GPU は multires_tree.hlsl の TreeQuietCheck → TreeQuiet(1 グループの累積和)
multires_quiet_test / gpu_multires_quiet_test — 変わったばかりは粗くしない・燃え尽きたら根まで畳む動いているtests/multires_quiet_test.cpp:148保存量が毎刻み一致。GPU(HW・WARP)は状態の全部と次の刻みの種が毎刻み CPU と一致
ExpandWantedPages — 一様なブロックを頁に広げる(枠の順)動いているengine/src/sim/multires_nest.cpp:355見出しの枠とセルの頁は別のプール。一様(覆われていないセルが同じ値)は頁なしで値 1 つ。反応が進む時だけ刻んだ後に頁を配る。GPU は multires_tree.hlsl の TreeExpand → ExpandStepNode / StepExpandedWaitPass
FoldQuietPages — 静かで一様(かほぼ同じ)になった頁を畳む(枠の順)動いているengine/src/sim/multires_activity.cpp:49ちょうど静かになった刻み(MrWantsFoldCheck)に 1 回だけ一様か調べ、一様なら値 1 つに戻して頁を返す。GPU は multires_tree.hlsl の TreeFoldCheck(1 グループ = 1 枠)→ TreeFold(1 グループの累積和)。許容差つき(T-0104・GPU は T-0112)は計器で測れない差なら平均の切り捨てで畳み、余りと静かになった端数の枠の端数を帳簿へ(MrFoldStats・CPU は AddLedgerBits、GPU は繰り上げつきの atomic の AddLedgerCarrying)
multires_uniform_test / gpu_multires_uniform_test — 一様な根・鎖は頁を使わない・頁の不足・燃え尽きたら畳む動いているtests/multires_uniform_test.cpp:1391 つずつ刻む素直な答えと論理のセルが一致・保存量一致・燃え尽きた木箱が畳まれて頁が 0 に戻る(T-0103)。GPU(HW・WARP)は状態の全部と種が毎刻み CPU と一致
ComputeConduction — 木の上の熱の伝導(違うレベルの面は細かい側が粗い側の端数へ送る)動いているengine/src/sim/multires_conduction.cpp:290StepNest / StepActive の options.conduction(GPU は GpuMultires::RecordConduction。T-0107)。流れのある一様なブロックを頁に広げ、端数の枠を枠の順に配り、刻みの初めのセルから面の流れを足す(Jacobi 型)
StepConduction — 細かいレベルの熱の刻み(レベルごとの小刻み・粗い刻みの終わりに受け渡す)動いているengine/src/sim/multires_conduction.cpp:310options.maxSubcycleGap(既定 0 = 分けない)。レベル k を 1 刻みに 4^σ 回(σ ≤ 3)。粗い側の値は粗い小刻みの初めのまま、細かい側の流れの合計を終わりに 1 回で受ける(Berger–Colella の refluxing)。活性は小刻みで変わったブロックの隣を起こす。GPU は RecordSubstepEnd(T-0109)
multires_subcycle_test — 物差し(レベルごとの実効の拡散率)・分けても保存量と活性 = 全部動いているtests/multires_subcycle_test.cpp:135
multires_conduction.hlsli — 面の隣・レベルの単位の係数・違うレベルの受け渡し動いているshaders/common/multires_conduction.hlsli:225
multires_conduction_test — 面の隣の総当たり・保存量・活性 = 全部動いているtests/multires_conduction_test.cpp:266閉じた箱・6 段の鎖(端数の枠あり / なし)・たくさんの要求に伝導。面の係数が 1/8 で止まるレベルと、静かになった後に残る頁も測る
RecordConduction — 熱の伝導の GPU の段(印 → 頁 → 端数の枠 → 流れ → 足して反応)動いているengine/src/sim/gpu_multires.cpp:888Compute の段 shaders/sim/multires_conduct.hlsl(1 グループ = 1 ブロック)。活性の刻みは Work Graph が伝導の一覧に足し、段はその一覧だけ。変化は 64bit の atomic の足し算
RecordSubstepEnd — 細かいレベルの熱の刻みの GPU(小刻みの終わりに足して隣を起こす)動いているengine/src/sim/gpu_multires.cpp:937RecordConduction が小刻みを 4^maxSubcycleGap 回積む(印 → 頁 → 端数の枠 → 埋める → 流れ。始まるレベルが無ければ段は空)。小刻みの終わりは ConductEnd が終わるレベルに足し、活性なら変わったブロックの一覧で活性のグラフ(ActivitySeedNode)を投げて面の隣を起こす
multires_conduct.hlsli — 1 ブロックの印・流れ・足す(Compute と Work Graph で共有)動いているshaders/sim/multires_conduct.hlsli:397
gpu_multires_conduction_test — 鎖・たくさんの要求の伝導を毎刻み GPU と CPU で比べる動いているtests/gpu_multires_conduction_test.cpp:268全部 / 活性(伝導の段が Compute / Work Graph)。HW・WARP。release では Compute と Work Graph の時間も測る(D-302)。--subcycle で小刻み 64 回(T-0109)
StepImplicit — 細かいレベルの熱の陰解法の試作(V サイクル・誤差の見込みで止める・安全網)動いているengine/src/sim/implicit_conduction.cpp:711方式②の CPU リファレンス(セルの一覧・熱容量一定。木への組み込みは T-0119)。近似解の面の流れで足すので保存はビット単位
AddImplicitConduction — 細かいレベルの熱の陰解法を木の伝導に(案 a)動いているengine/src/sim/multires_implicit_conduction.cpp:252options.implicitConduction(既定 false)。流れを計算する側が基準より細かい(Δk 1〜8)面を陰解法の 1 刻みで解く。境の基準以下のセルは面で分ける。眠っている頁のブロックも入れて活性 = 全部。captureImplicitGrid で系を写せる(GPU と比べる。T-0127)。系を GPU で作るのは T-0129、GPU の伝導の段から呼ぶのは GpuMultiresImplicit(T-0132)。系の上限(options.implicitLimits)に入るブロックを流れの前に枠の順で選び、入らないブロックはその刻み陽解法(MarkImplicitBlocks・GPU は GpuImplicitBuild::RecordAdmit。T-0178・Q22 の案 A〔仮〕)
multires_implicit_tree_test — 木の物差し・熱い点・鎖・たくさんの要求(保存・活性 = 全部・2 回一致)動いているtests/multires_implicit_tree_test.cpp:245
implicit_conduction.hlsli — 陰解法の式(温度・面の流れ・誤差の判定・陽解法の係数)動いているshaders/common/implicit_conduction.hlsli:256
GpuImplicit::RecordStep — 陰解法の GPU の段(V サイクル × 上限・空で抜ける)動いているengine/src/sim/gpu_implicit.cpp:586Compute の段 shaders/sim/implicit_conduct.hlsl(1 スレッド = 1 節。隣が多い節は 1 グループで足し、小さい段から下は ImTail の 1 Dispatch〔T-0120〕)。止めるかは GPU の状態の語で決め、止めた後の段は述語で飛ばす。大きさは上限から、段の形・ImTail の境・Dispatch の大きさは刻みの初めに GPU が作る計画(ImPlanLevels・ImPlanArgs)から読み、ExecuteIndirect で積む〔T-0136〕
GpuImplicitBuild::RecordBuild — 陰解法の系(未知数・境のセル・面)を GPU の木から作る動いているengine/src/sim/gpu_implicit_build.cpp:203Compute の段 shaders/sim/implicit_build.hlsl(GpuMultires のルート署名 + 外のバッファ)。番号は CPU の MakeSystem と同じ(接頭和と atomic の最小)。多重格子の段・重みは GpuImplicitLevels(T-0134)
GpuImplicitLevels::RecordBuild — 陰解法の多重格子の段・重みを GPU で作る動いているengine/src/sim/gpu_implicit_levels.cpp:245Compute の段 shaders/sim/implicit_levels.hlsl。GpuImplicitBuild の系から CPU の BuildImplicitGrid と同じ番号で節・隣・子の一覧を作る(親は鍵の表の atomic の最小 + 接頭和、行の係数は 128bit の繰り上げつき atomic)。段の数は値で決まり、要らない回は述語で飛ばす。小さい段からの回を 1 グループで回す LvTail(T-0135。HW のみ・既定は使わない。WARP で直すのは T-0147)。段の表(見出し)は GpuImplicit の計画へそのまま写す(T-0136)
gpu_multires_implicit_build_test — GPU で作った系と解いた結果を CPU と比べる動いているtests/gpu_multires_implicit_build_test.cpp:376木は MultiresNest::captureImplicitNest の写し。多重格子の段・重みも比べる(T-0134)。HW・WARP。release の HW では系を作る段・多重格子の段の ms と段ごとの内訳を測る
GpuMultiresImplicit::Record — GPU の伝導の段から陰解法を呼ぶ(系を作る → 段 → 解く → 変化を足す)動いているengine/src/sim/gpu_multires_implicit.cpp:64GpuMultires::EnableImplicitConduction で作る。RecordConduction の流れの後・ConductApply の前。流れの段は基準より細かいブロックを飛ばす(stepFlags の MR_STEP_IMPLICIT)。解いた変化は BuildApply が伝導の表へ足し、活性なら伝導の一覧へ。記録の形は前の刻みの数から(ShapeFrom)
gpu_multires_implicit_conduction_test — 熱い点・鎖・たくさんの要求を陰解法つきで全部・活性に刻み毎刻み CPU と比べる動いているtests/gpu_multires_implicit_conduction_test.cpp:356HW・WARP。release の HW では 1 刻み全体の ms(陰解法あり・なし)を測る
gpu_multires_implicit_test — 物差しの山・熱い点を毎刻み GPU と CPU で比べる動いているtests/gpu_multires_implicit_test.cpp:114HW・WARP。release の HW では 1 刻み・V 1 回・空の段・鎖の場面の ms を測る
gpu_multires_implicit_tree_test — 木の本物の系(熱い点・鎖・たくさんの要求)を GPU で解いて CPU と比べる動いているtests/gpu_multires_implicit_tree_test.cpp:295系は CPU の木が作ったもの(MultiresNest::captureImplicitGrid)。HW・WARP。release の HW では刻みごとの ms・V の上限・ImTail の境を比べる
TraceCapture — 1 回ぶんのトレースを集めてファイルへ動いているengine/src/frame/trace_capture.cpp:31--trace(起動時の範囲)と窓の T(最後につついたセルの周り ±8 を 60 刻み。exe の横の traces/)。範囲の刻みを読み終えたら書く
gpu_probe_trace_test — 2 回・分け方で同じ、CPU と一致、わざとずらす動いているtests/gpu_probe_trace_test.cpp:379ずらしたつつきから、最初の刻み S(10)・ブロック・セルとトレースの刻み 9 が出る
d3d12.dll(OS)外部docs/decisions/ADR-0004-agility-sdk-and-dxc.md
D3D12Core.dll — Agility SDK 1.619外部docs/decisions/ADR-0004-agility-sdk-and-dxc.md
bicameral_add_shader() — DXC で sim / render を分けてコンパイル動いているshaders/CMakeLists.txt:28成果物は bin/shaders/sim|render/*.cso
dxil_float_check — シミュの DXIL に浮動小数点があれば落とす動いているtools/float_check/dxil_float_check.py:32型(float など)と命令(fadd・sitofp など)。asfloat の抜け道も捕まる
source_float_check — 共通のヘッダ・CPU リファレンスの float / double動いているtools/float_check/source_float_check.py:52型・小数のリテラル・<cmath> の関数。HLSL と C++ を同じ規則で