)]}'
{
  "commit": "3a2f6ea08f17f149908a17ff9ba6cba4791d7f96",
  "tree": "2ea49e4639ef1ab3a510c49436c3fb3a620b2ac2",
  "parents": [
    "1ec625b4c087921a06afd3befb807fea6f57c674"
  ],
  "author": {
    "name": "Jeremy Howard",
    "email": "j@howard.fm",
    "time": "Mon Aug 31 19:05:07 2026"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Mon Aug 31 19:05:07 2026"
  },
  "message": "bazel: load C++ rules from rules_cc (#6848)\n\nWe’re building [xmojo](https://github.com/AnswerDotAI/xmojo), an\nin-process ORC-based Mojo environment for terminal and Jupyter\nfrontends. It includes a WebGPU compiler backend that lowers Mojo\nkernels through LLVM’s SPIR-V target and uses SPIRV-Tools to produce\nWebGPU-compatible modules.\n\nFor example:\n\n```mojo\ndef kernel(\n    output: Pointer[\n        Int32, MutAnyOrigin, address_space\u003dAddressSpace(11)\n    ],\n):\n    output[unsafe_offset\u003d0] \u003d 42\n```\n\nis compiled to SPIR-V, loaded by Dawn, and executed on Metal.\n\nLLVM currently leaves resource-binding names as dead `i8` data in the\nemitted module. Dawn rejects the resulting `Int8` capability, so xmojo\nuses SPIRV-Tools for dead-code elimination and validation before passing\nthe module to WebGPU.\n\nxmojo builds against Modular’s Bazel 10 workspace and includes\nSPIRV-Tools as an external repository. Although SPIRV-Tools already\ndeclares `rules_cc`, its `BUILD.bazel` still relies on the removed\nnative C++ rules, so analysis stops at its first `cc_library`:\n\n```text\nThis rule has been removed from Bazel. Please add a `load()` statement for it.\n```\n\nThis PR loads `cc_binary`, `cc_library`, and `cc_test` from the existing\n`rules_cc` dependency. With that change, `spirv_tools_opt` builds\nsuccessfully and xmojo’s generated kernel executes through Dawn on\nMetal.",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "c05393b3647388bcc1581f43ff191c24877415ce",
      "old_mode": 33188,
      "old_path": "BUILD.bazel",
      "new_id": "0afce17af7ba754a252478009a28887e67421beb",
      "new_mode": 33188,
      "new_path": "BUILD.bazel"
    }
  ]
}
