)]}'
{
  "commit": "17467c103073ae0ec7bc43ffa35cb488cd2a97ed",
  "tree": "149dd042d0351d083b6ed20dc2445ce4db9c01f6",
  "parents": [
    "d246d904adf3e338c731c123219a8246281002e2"
  ],
  "author": {
    "name": "Simon Marchi",
    "email": "simon.marchi@efficios.com",
    "time": "Tue Nov 22 13:18:43 2022 -0500"
  },
  "committer": {
    "name": "Simon Marchi",
    "email": "simon.marchi@polymtl.ca",
    "time": "Thu Feb 02 10:02:34 2023 -0500"
  },
  "message": "gdb/solib-svr4: don\u0027t disable probes interface if probe not found\n\nIn ROCm-GDB, we install an solib provider for the GPU code objects on\ntop of the svr4 provider for the host, in order to add solibs\nrepresenting the GPU code objects to the solib list containing the host\nprocess\u0027 shared libraries.  We override the target_so_ops::handle_event\nfunction pointer with our own, in which we call svr4_so_ops.handle_event\n(which contains svr4_handle_solib_event) manually.  When the host\n(un)loads a library, the ROCm part of handle_event is a no-op.  When the\nGPU (un)loads a code object, we want the host side (svr4) to be a no-op.\n\nThe problem is that when handle_event is called because of a GPU event,\nsvr4_handle_solib_event gets called while not stopped at an svr4\nprobe.  It then assumes this means there\u0027s a problem with the probes\ninterface and disables it through the following sequence of events:\n\n  - solib_event_probe_at return nullptr\n  - svr4_handle_solib_event returns early\n  - the make_scope_exit callback calls disable_probes_interface\n\nWe could fix that by making the ROCm handle_event callback check if an\nsvr4 probe is that the stop address, and only call\nsvr4_so_ops.handle_event if so.  However, it doesn\u0027t feel right to\ninclude some svr4 implementation detail in the ROCm event handler.\n\nInstead, this patch changes svr4_handle_solib_event to not assume it is\nan error if called while not at an svr4 probe location, and therefore\nnot disable the probes interface.  That just means moving the\nmake_scope_exit call below where we lookup the probe by pc.\n\nChange-Id: Ie8ddf5beffa2e92b8ebfdd016454546252519244\nCo-Authored-By: Lancelot SIX \u003clancelot.six@amd.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "fe009a1581d837f602ce38878d1244ececeb0229",
      "old_mode": 33188,
      "old_path": "gdb/solib-svr4.c",
      "new_id": "33577b7ddd2b1f82712ed895c1124918d2521ac1",
      "new_mode": 33188,
      "new_path": "gdb/solib-svr4.c"
    }
  ]
}
