)]}'
{
  "commit": "daf0182277831222101ee8e29f6fa3a1ac3b809d",
  "tree": "d2277f62a3102f57fbe95efbe23030c462b1e23a",
  "parents": [
    "11bbee9d9fbaa98978ed7704e799d6b56fb47295"
  ],
  "author": {
    "name": "Florian Hahn",
    "email": "flo@fhahn.com",
    "time": "Thu Oct 23 12:50:12 2025 +0100"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Thu Oct 23 12:50:12 2025 +0100"
  },
  "message": "[ConstraintElim] Apply add with neg constant first during decomp. (#164791)\n\nWe have dedicated decomposition logic for (add %x, -C), but if we have\n(add nsw %x, -C) we will first apply the generic logic for NSWAdd, which\ngives worse results for negative constants in practice.\n\nUpdate the code to first apply the pattern with negative constants.\n\nHelps to remove a number of runtime checks in practice:\nhttps://github.com/dtcxzyw/llvm-opt-benchmark/pull/2968\n\nAlive2 proofs for the test changes: https://alive2.llvm.org/ce/z/JfR2Ma\n\nPR: https://github.com/llvm/llvm-project/pull/164791",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "4acc3f2d846905623470ac1fae16a48d03d38fca",
      "old_mode": 33188,
      "old_path": "llvm/lib/Transforms/Scalar/ConstraintElimination.cpp",
      "new_id": "d347cedb42988ec0f08152fea3cbc5f8addf41b0",
      "new_mode": 33188,
      "new_path": "llvm/lib/Transforms/Scalar/ConstraintElimination.cpp"
    },
    {
      "type": "modify",
      "old_id": "5127e92a7c345b7d983dcb7cf7360cff2a22a683",
      "old_mode": 33188,
      "old_path": "llvm/test/Transforms/ConstraintElimination/add-nsw.ll",
      "new_id": "4b8ac09801ab2001c2c37ab3982a02817e93b34b",
      "new_mode": 33188,
      "new_path": "llvm/test/Transforms/ConstraintElimination/add-nsw.ll"
    },
    {
      "type": "modify",
      "old_id": "52adc78b4e159bfbfd0d222d234aa767ee3129ee",
      "old_mode": 33188,
      "old_path": "llvm/test/Transforms/ConstraintElimination/gep-arithmetic-add.ll",
      "new_id": "8dcac7832179a0d597cb560bda5b45cc437d6a79",
      "new_mode": 33188,
      "new_path": "llvm/test/Transforms/ConstraintElimination/gep-arithmetic-add.ll"
    }
  ]
}
