)]}'
{
  "commit": "6ee5b8fed80589de02b551fbc2e52eb9dde91f89",
  "tree": "bc85793f9ffbf87cbf8bab6095117a9d2573af01",
  "parents": [
    "b2e93484bc0611525df54473e6771ad3e4500c6d"
  ],
  "author": {
    "name": "Antonio Maiorano",
    "email": "amaiorano@google.com",
    "time": "Tue Oct 28 17:47:17 2025 -0700"
  },
  "committer": {
    "name": "Dawn LUCI CQ",
    "email": "dawn-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "time": "Tue Oct 28 17:47:17 2025 -0700"
  },
  "message": "d3d12: optimize root signature slot usage for dynamic storage buffers\n\nRather than bind dynamic storage buffers to root descriptors as [base\noffset + dynamic offset, size], bind them instead to the root descriptor\ntable at [base offset, full size - base offset], and store the dynamic\noffset as a root constant. The dynamic offsets are fed to Tint via\nArrayOffsetFromUniform, and thus are applied at shader runtime by\nreading the offsets from a UBO and adding them to all reads/writes of\ndynamic storage buffers.\n\nBefore this change, each dynamic storage buffer binding would use 3 root\nsignature slots: 2 for the root descriptor binding, and 1 for the buffer\nlength. With this change, each binding now takes 2 root signature slots:\n1 for the buffer length (as before), and 1 for the buffer offset. This\nfrees up 8 slots (maxDynamicStorageBuffersPerPipelineLayout) in total.\n\nOther things to point out:\n\n- Added BindGroupTests.DynamicOffsetsWithAtomicOperations test to cover\n  the case of atomic operations on dynamic buffers. This is because\n  along with (RW)ByteAddressBuffer Load and Store functions, the\n  Interlocked* functions are the ones that take an offset, so we want to\n  make sure the dynamic offsets are properly applied.\n- Added some useful comments to DynamicBufferOffsetTests.\n- Added dawn::ityp::stack_vec::empty()\n- Added dawn::ityp::vector::resize(Index, const Value\u0026) overload\n\nBug: 449703736\nChange-Id: I394ae0a82352eda9b8d109fabf05597339fd4d47\nReviewed-on: https://dawn-review.googlesource.com/c/dawn/+/267454\nCommit-Queue: Antonio Maiorano \u003camaiorano@google.com\u003e\nReviewed-by: Loko Kung \u003clokokung@google.com\u003e\nReviewed-by: Jiawei Shao \u003cjiawei.shao@intel.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "875a813d55a3aad1e4461256f9f93b2cde473b65",
      "old_mode": 33188,
      "old_path": "src/dawn/common/ityp_stack_vec.h",
      "new_id": "cb4337e12f21bc09827019c23f2883dec8485f53",
      "new_mode": 33188,
      "new_path": "src/dawn/common/ityp_stack_vec.h"
    },
    {
      "type": "modify",
      "old_id": "9cb0c3991947b02f3d0c13f23d3eee496b338ca7",
      "old_mode": 33188,
      "old_path": "src/dawn/common/ityp_vector.h",
      "new_id": "5dd2ba22e35698562e3211c43aeab4394b108d6a",
      "new_mode": 33188,
      "new_path": "src/dawn/common/ityp_vector.h"
    },
    {
      "type": "modify",
      "old_id": "ac4427b41d42d7aca84552875596782f88029c38",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/BindGroupD3D12.cpp",
      "new_id": "34b1bab102b259fad36058dea51a1e521c393e42",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/BindGroupD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "a0a165ff3959b49591fb3eaa6b86f3f9d0b7349f",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/BindGroupLayoutD3D12.cpp",
      "new_id": "c80aa934c5e3bf70c9359a6dcc39f25403f1a4fb",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/BindGroupLayoutD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "48c11b36f3bdaccb1add58b071446c3a8b739801",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/CommandBufferD3D12.cpp",
      "new_id": "dab6c40145b2639fd50d877adaf528225173629f",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/CommandBufferD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "dcbae5a73859ac6eb54f73a45094a762f0c1c082",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp",
      "new_id": "be3cfeedcb450a8cdb6098e624c2bac8f1607a7e",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "d52b32aba05e113b08cd88307c4d01300bf418c2",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/PipelineLayoutD3D12.cpp",
      "new_id": "7705078731d58633cfd26a28ae3f12e6cd9fe785",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/PipelineLayoutD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "1e25ea88b15573e5b797733d7fafc06fcf2ec191",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/PipelineLayoutD3D12.h",
      "new_id": "c664886cd962c821e821813661ab35f8abb41782",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/PipelineLayoutD3D12.h"
    },
    {
      "type": "modify",
      "old_id": "8678be8a453d06b911fcdc446dccd0f4a8719fea",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/ShaderModuleD3D12.cpp",
      "new_id": "938babab91f4058a8fa5bd0d20f6df8be4d2cb5b",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/ShaderModuleD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "48fa1c9d65942fcd66930fee9ba453fea790e882",
      "old_mode": 33188,
      "old_path": "src/dawn/tests/end2end/BindGroupTests.cpp",
      "new_id": "3071348fb87e1d92efcc4585788f911d034afaf5",
      "new_mode": 33188,
      "new_path": "src/dawn/tests/end2end/BindGroupTests.cpp"
    },
    {
      "type": "modify",
      "old_id": "ffa0eaa656e60818961d2a8fa73bb9d2164184a6",
      "old_mode": 33188,
      "old_path": "src/dawn/tests/end2end/DynamicBufferOffsetTests.cpp",
      "new_id": "a3254d97579e844d48aeee5e38ec215c471e9357",
      "new_mode": 33188,
      "new_path": "src/dawn/tests/end2end/DynamicBufferOffsetTests.cpp"
    }
  ]
}
