)]}'
{
  "commit": "c96f019fa3bc02bbc60343de606235c6e2cef4bd",
  "tree": "f860a4a155fed8cca943247b3643e0dddae716f9",
  "parents": [
    "af497d9a658ebca437aff79cd9532cd93b7a58a0"
  ],
  "author": {
    "name": "Nikita Popov",
    "email": "npopov@redhat.com",
    "time": "Wed Apr 30 09:07:55 2025 +0200"
  },
  "committer": {
    "name": "GitHub",
    "email": "noreply@github.com",
    "time": "Wed Apr 30 09:07:55 2025 +0200"
  },
  "message": "[BasicBlockUtils] Remove broken support for eh pads in SplitEdge() (#137816)\n\nd81d9e8b8604c85709de0a22bb8dd672a28f0401 changed SplitEdge() to make use\nof ehAwareSplitEdge() for critical edges where the target is an eh pad.\nHowever, the implementation is incorrect at least for landing pads. What\nis currently produced for the code in the modified unit test is\nsomething like this:\n\n    continue:\n      invoke void @sink()\n              to label %normal unwind label %new_bb\n\n    new_bb:\n      %cp \u003d cleanuppad within %exception []\n      cleanupret from %cp unwind label %exception\n\n    exception:\n      %cleanup \u003d landingpad i8 cleanup\n      br label %trivial-eh-handler\n\nThis mixes different exception handling mechanisms in a nonsensical way,\nand is not well-formed IR. To actually \"split\" the landingpad edge (for\na rather loose definition of \"split\"), I think we\u0027d have to generate\nsomething along these lines:\n\n      exception.split:\n        %cleanup.split \u003d landingpad i8 cleanup\n        br label %exception.cont\n\n      exception:\n        %cleanup.orig \u003d landingpad i8 cleanup\n        br label %exception.cont\n      \n      exception.cont:\n%cleanup \u003d phi i8 [ %cleanup.split, %exception_split ], [ %cleanup.orig,\n%exception ]\n\nI didn\u0027t bother actually implementing that, seeing as how nobody noticed\nthe existing codegen being broken in the last four years, so clearly\nnobody actually needs this function to work with EH edges. Just return\nnullptr instead.",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "429037ab9da47427079e58591d5933acb0827722",
      "old_mode": 33188,
      "old_path": "llvm/lib/Transforms/Utils/BasicBlockUtils.cpp",
      "new_id": "dce10c0ecd56cb547aa3408f2f63da8630c81bdb",
      "new_mode": 33188,
      "new_path": "llvm/lib/Transforms/Utils/BasicBlockUtils.cpp"
    },
    {
      "type": "modify",
      "old_id": "c9a6a32851775a73a5c1f42a87e7a796dbd76f10",
      "old_mode": 33188,
      "old_path": "llvm/unittests/Transforms/Utils/BasicBlockUtilsTest.cpp",
      "new_id": "e58daed8878550e9619111c39281d41af9e3dc2b",
      "new_mode": 33188,
      "new_path": "llvm/unittests/Transforms/Utils/BasicBlockUtilsTest.cpp"
    }
  ]
}
