)]}'
{
  "commit": "bcd0612c5890fd948d278090c164d211617b6c3f",
  "tree": "50d08f79302c3b3ff9b59f988e01edb8c8b9dea4",
  "parents": [
    "aedc636a1ed20dea04fbb25b84833ba717db5df7"
  ],
  "author": {
    "name": "Googler",
    "email": "noreply@google.com",
    "time": "Thu Jul 23 17:26:24 2026 -0700"
  },
  "committer": {
    "name": "Copybara-Service",
    "email": "copybara-worker@google.com",
    "time": "Thu Jul 23 17:26:49 2026 -0700"
  },
  "message": "[bzl-optimizer] Eliminate redundant Starlark list allocations in C++ build variables.\n\nOptimize Starlark memory usage during C++ build variable evaluation by replacing empty mutable lists with empty tuples `()`:\n1. `link_build_variables.bzl`: Replaces empty `user_link_flags` with `()` via `user_link_flags if (is_using_linker and user_link_flags) else ()`. Guards dynamic library flag processing with `and user_link_flags` to skip `_remove_pie` when empty, and updates `_remove_pie` to return a tuple.\n2. `compile_build_variables.bzl`: Replaces `[]` with `()` for `MODULE_FILES` when `use_header_modules` feature is enabled.\n\nMemory Evidence (statistics from the analysis phase of a mars-lro build):\n- Confirmed zero allocations remaining at line 261 of `link_build_variables.bzl` in post-optimization benchmark run.\n- Eliminates 135,226 empty list allocations from `link_build_variables.bzl`.\n- Eliminates 89,276 empty list allocations from `compile_build_variables.bzl`.\n- Net live Starlark list instance reduction: 224,502 instances.\n\nStartblock:\n  * // Put other blockers before this line to avoid churning.\n  * has lgtm\n  * is approved\n  * and then\n  * all comments are resolved\n  * and then\n  *[] allows unknown commit\nPiperOrigin-RevId: 953043322\nChange-Id: I6801c009e719939af7eb4f0c73ec2e22d9e44275\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "ed76c6e100d565bac8a8be26d0e4dd160b69ed53",
      "old_mode": 33188,
      "old_path": "cc/private/compile/compile_build_variables.bzl",
      "new_id": "f5be61387520db2ed7f6b0d67e75887c0d5c18c7",
      "new_mode": 33188,
      "new_path": "cc/private/compile/compile_build_variables.bzl"
    },
    {
      "type": "modify",
      "old_id": "256fb3d42b55e506488c7eac8c16f0b48146909b",
      "old_mode": 33188,
      "old_path": "cc/private/link/link_build_variables.bzl",
      "new_id": "57433541d5163f3a82e8fed0271e09ca9e7c5297",
      "new_mode": 33188,
      "new_path": "cc/private/link/link_build_variables.bzl"
    }
  ]
}
