)]}'
{
  "commit": "93ec564f48e7b72b8adc8592df2dd863b699b4d6",
  "tree": "e2dcf2c2126ef375fb882f652be6cc85aeac6646",
  "parents": [
    "ada5991fff4234c43415690f5226011b40c8d2d3"
  ],
  "author": {
    "name": "Antonio Maiorano",
    "email": "amaiorano@google.com",
    "time": "Tue Jun 03 16:54:08 2025 -0700"
  },
  "committer": {
    "name": "Dawn LUCI CQ",
    "email": "dawn-scoped@luci-project-accounts.iam.gserviceaccount.com",
    "time": "Tue Jun 03 16:54:08 2025 -0700"
  },
  "message": "Enable BCSliced3D on D3D12\n\nThis re-enables the feature on D3D12 along with fixing the many bugs\nthat forced us to revert this the last time. With this, all BCSliced3D\nimage_copy CTS tests now pass\n(`\u0027webgpu:api,operation,command_buffer,image_copy:*\u0027`).\n\n- Fixed NeedBufferSizeWorkaroundForBufferTextureCopyOnD3D12 to support\n  compressed textures. This formerly only worked for uncompressed\n  textures, but is required also for compressed to avoid the same D3D12\n  validation errors about the footprint extending beyond the buffer.\n  - Note that I cannot unit test these fixes as RecordBufferTextureCopy\n    isn\u0027t tested. But CTS tests that were failing now pass (e.g.\n    `webgpu:api,operation,command_buffer,image_copy:mip_levels:initMethod\u003d\"WriteTexture\";checkMethod\u003d\"PartialCopyT2B\";format\u003d\"bc4-r-snorm\";dimension\u003d\"3d\"`,\n    subcase\n    `copySizeInBlocks\u003d{\"width\":5,\"height\":4,\"depthOrArrayLayers\":2};originInBlocks\u003d{\"x\":3,\"y\":2,\"z\":1};mipLevel\u003d2;textureSize\u003d[128,96,12]`).\n\n- Fixed multiple bugs in TextureCopySplitter:\n  - Fixed Recompute3DTextureCopyRegionWithEmptyFirstRowAndEvenCopyHeight\n    and Recompute3DTextureCopyRegionWithEmptyFirstRowAndOddCopyHeight,\n    both of which were micomputing alignment offsets because\n    copySize.height was assumed to be in texels rather than blocks.\n  - Fixed Compute3DTextureCopySplits, which was testing if\n    copySize.height was even or odd to call into the proper handlers,\n    but needed to be testing if `copySize.height / blockInfo.height` was\n    even or odd instead. Otherwise, we would end up calling the \"even\"\n    handler which assumed at least 2 rows would be copied, but this\n    would be incorrect for 2x2 or 4x4 blocks with a copy size of 1 row.\n  - Note that we considered making\n    GetOptimalBufferToTextureCopyOffsetAlignment return 512 rather than\n    the current 1 as this effectively worked around some of the\n    aforementioned offset-related bugs. But I decided to investigate and\n    fix them properly, so there\u0027s no need to force 512-byte alignment on\n    each WriteTeture ring buffer allocation.\n\n- Fixed bug in Texture::ClearTexture that was incorrectly passing in\n  rowsPerImage in texels rather than block rows.\n\n- CopySplitTest changes:\n  - Fixed GetBufferSize computing the wrong bufferSizeForFootprint\n  - Fixed ValidateOffset to correctly compute offset values (thanks\n    Corentin!)\n  - Improved ostream output for TextureSpec and BufferSpec\n  - Used designated initializers to improve readability of\n    kBaseTextureSpecs\n  - Added missing cases for 4x4 blocks with \u003e1 layer\n  - Added specific unit tests for CTS failure cases\n\n- Added and clarified comments here and there.\n\n- Enabled Feature::TextureCompressionBCSliced3D\n\nBug: 415303046\nChange-Id: Ib82d3a478ec04a504f6b0221ec2ba1715a303561\nReviewed-on: https://dawn-review.googlesource.com/c/dawn/+/244836\nReviewed-by: Kai Ninomiya \u003ckainino@chromium.org\u003e\nReviewed-by: Corentin Wallez \u003ccwallez@chromium.org\u003e\nCommit-Queue: Antonio Maiorano \u003camaiorano@google.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "197ce0f8cd6021717aaa93e2d2c7a8c2c6ae7755",
      "old_mode": 33188,
      "old_path": "src/dawn/native/CommandValidation.cpp",
      "new_id": "b1d0a70e0b5f554d644e6da3c41deb460e697042",
      "new_mode": 33188,
      "new_path": "src/dawn/native/CommandValidation.cpp"
    },
    {
      "type": "modify",
      "old_id": "1c04a4a2e30046d1a7860c95eea55f5e2c60209a",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp",
      "new_id": "6865585c1c2ee8a4e06f7cba17640ac3d35a9312",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "d5606b69e734e781f5df7f042da8ebd490a75142",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/TextureCopySplitter.cpp",
      "new_id": "3f895ea35e8fa6de082808d924ee520304bfaef8",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/TextureCopySplitter.cpp"
    },
    {
      "type": "modify",
      "old_id": "18e9f485aab525f2e6db49669d3d3794a9b94c52",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/TextureCopySplitter.h",
      "new_id": "605bc409d2d5948f8683a603f147c928de6f7581",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/TextureCopySplitter.h"
    },
    {
      "type": "modify",
      "old_id": "d815ecb943fcfe48e3e87f249c0b9c7b48711fcd",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/TextureD3D12.cpp",
      "new_id": "d4d7de8aa8450ac675f495e014bbe33d600d06fb",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/TextureD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "c5868c1898d7ee00d0a0e510cd0f5e19be77e6f2",
      "old_mode": 33188,
      "old_path": "src/dawn/native/d3d12/UtilsD3D12.cpp",
      "new_id": "0b86d61a2bd777fc0af50256a3c2eba593ebb2f8",
      "new_mode": 33188,
      "new_path": "src/dawn/native/d3d12/UtilsD3D12.cpp"
    },
    {
      "type": "modify",
      "old_id": "b2c62aae1f125713807d194d3482a62e6a46b468",
      "old_mode": 33188,
      "old_path": "src/dawn/tests/unittests/d3d12/CopySplitTests.cpp",
      "new_id": "637f6587c061f209d2efab1c170ebfe396fcfe19",
      "new_mode": 33188,
      "new_path": "src/dawn/tests/unittests/d3d12/CopySplitTests.cpp"
    }
  ]
}
