)]}'
{
  "commit": "aab2ac34d7f78f0b7a42cef0187dc6e4d7ec4f02",
  "tree": "3fa71586b82374b5d2cb0a24ff5fd998ecbc1044",
  "parents": [
    "d519282866163864fff3fe0ab7227ff0339cad67"
  ],
  "author": {
    "name": "Tom Tromey",
    "email": "tom@tromey.com",
    "time": "Fri Feb 21 09:18:28 2025 -0700"
  },
  "committer": {
    "name": "Tom Tromey",
    "email": "tom@tromey.com",
    "time": "Fri Mar 07 17:15:20 2025 -0700"
  },
  "message": "Avoid excessive CU expansion on failed matches\n\nPR symtab/31010 points out that something like \"ptype INT\" will expand\nall CUs in a typical program.  The OP further points out that the\noriginal patch for PR symtab/30520:\n\n    https://sourceware.org/pipermail/gdb-patches/2024-January/205924.html\n\n... did solve the problem, but the patch changed after (my) review and\nreintroduced the bug.\n\nIn cooked_index_functions::expand_symtabs_matching, the final\ncomponent of a split name is compared with the entry\u0027s name using the\nusual method of calling get_symbol_name_matcher.\n\nThis code iterates over languages and tries to split the original name\naccording to each style.  But, the Ada splitter uses the decoded name\n-- \"int\".  This causes every C or C++ CU to be expanded.\n\nClearly this is wrong.  And, it seems to me that looping over\nlanguages and trying to guess the splitting style for the input text\nis probably bad.  However, fixing the problem is not so easy (again\ndue to Ada).  I\u0027ve filed a follow-up bug, PR symtab/32733, for this.\n\nMeanwhile, this patch changes the code to be closer to the\noriginally-submitted patch.  This works because the comparison is now\ndone between the full name and the \"lookup_name_without_params\"\nobject, which is a less adulterated variant of the original input.\n\nBug: https://sourceware.org/bugzilla/show_bug.cgi?id\u003d31010\nTested-By: Simon Marchi \u003csimon.marchi@efficios.com\u003e\n\n\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "202f05f7e9457f352336ad798d234fe582d10416",
      "old_mode": 33188,
      "old_path": "gdb/dwarf2/read.c",
      "new_id": "41532c8efecbf8b7c28c46612af862da4e25dc03",
      "new_mode": 33188,
      "new_path": "gdb/dwarf2/read.c"
    },
    {
      "type": "add",
      "old_id": "0000000000000000000000000000000000000000",
      "old_mode": 0,
      "old_path": "/dev/null",
      "new_id": "7359eeac5b7b50de8175f5c9003df3c18fe7fcfd",
      "new_mode": 33188,
      "new_path": "gdb/testsuite/gdb.dwarf2/no-expand-mixed-case.exp"
    }
  ]
}
