)]}'
{
  "commit": "af20c826cd70950637e37b6aecb41bb1b413f9c7",
  "tree": "b37ee782b3a67f4daf2128438730684015c490e4",
  "parents": [
    "e991a05e359a25988f49bff3ab8af986e959b866"
  ],
  "author": {
    "name": "Sebastian Ullrich",
    "email": "sebasti@nullri.ch",
    "time": "Sat Aug 29 13:30:22 2026 +0000"
  },
  "committer": {
    "name": "Sebastian Ullrich",
    "email": "sebasti@nullri.ch",
    "time": "Sat Aug 29 13:39:18 2026 +0000"
  },
  "message": "perf: avoid `setTransparency` when the transparency is already in effect\n\nThis PR speeds up elaboration by not rebuilding the `MetaM` context when `withTransparency` or `withAtLeastTransparency` is asked for the transparency setting that is already in effect.\n\n`Context.setTransparency` rebuilds `Config`, `ConfigWithKey` and `Context`, so each such call allocated three objects and retraced the `Context`\u0027s pointer fields even when nothing changed. `withTransparency` did this unconditionally, and `withAtLeastTransparency` did it by construction on the branch where the ambient mode already suffices. Both are hot: `withInferTypeConfig` wraps every `inferType` in `withAtLeastTransparency .default`, as does `getFunInfoAux`, and `.default` is usually the ambient mode already.\n\nSkipping the rebuild is observationally equivalent: `ConfigWithKey.key` is maintained as `Config.toKey`, whose low three bits are exactly `transparency.toUInt64`, so re-applying the current mode reproduces an identical `Config` and an identical key.\n\nMeasured over 12 `elab_bench` files, 5 interleaved repetitions per variant against a same-machine baseline build: -0.33% instructions overall, with every file improving (-0.06% to -1.16%). The run-to-run noise floor for this metric is 0.10% per file and 0.00% overall.\n\nCo-Authored-By: Claude Opus 5 (1M context) \u003cnoreply@anthropic.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "e207f8f137bda69488be8424896fd82bad6cca8d",
      "old_mode": 33188,
      "old_path": "src/Lean/Meta/Basic.lean",
      "new_id": "1791b62f7fdeb9d2f2f83caec4cd281f38f4279b",
      "new_mode": 33188,
      "new_path": "src/Lean/Meta/Basic.lean"
    }
  ]
}
