)]}'
{
  "commit": "558802e4d1c5dcbd0df7d2c6ef62a6deac247a2f",
  "tree": "886bd294660f6280a4085267703135c754fe2770",
  "parents": [
    "b08c778be92ec638f4f8e6d8d7153c1456b460c8"
  ],
  "author": {
    "name": "Simon Marchi",
    "email": "simon.marchi@polymtl.ca",
    "time": "Thu Apr 07 08:55:16 2022 -0400"
  },
  "committer": {
    "name": "Simon Marchi",
    "email": "simon.marchi@efficios.com",
    "time": "Tue Apr 12 14:17:43 2022 -0400"
  },
  "message": "gdb: change subfile::line_vector to an std::vector\n\nChange this field to an std::vector to facilitate memory management.\nSince the linetable_entry array is copied into the symtab resulting from\nthe subfile, it is possible to change it without changing how symtab\nstores the linetable entries (which would be a much larger change).\n\nThere is a small change in buildsym_compunit::record_line to avoid\naccessing a now invalid linetable_entry.  Before this patch, we keep a\npointer to the last linetable entry, pop it from the vector, and then\nread last-\u003eline.  It works with the manually-maintained array, but since\nwe now use std::vector::pop_back, I am afraid that it could be flagged\nas an invalid access by the various static / dynamic analysis tools to\naccess the linetable_entry object after popping it from the vector.\nInstead, record just the line number in an optional and use it.\n\nThere are substantial changes in xcoffread.c that simplify the code, but\nI can\u0027t test them.  I was hesitant to do this change because of that,\nbut I decided to send it anyway.  I don\u0027t think that an almost dead\nplatform should hold back improving the code in the common parts of GDB.\n\nThe changes in xcoffread.c are:\n\n - Make arrange_linetable \"arrange\" the linetable passed as a parameter,\n   instead of returning possibly a new one, possibly the same one.\n - In the \"Process main file\u0027s line numbers.\", I\u0027m not too sure what\n   happens.  We get the lintable from \"main_subfile\", \"arrange\" it, but\n   then assign the result to the current subfile, obtained with\n   get_current_subfile.  I assume that the current subfile is also the\n   main one, so now I just call arrange_linetable on the main subfile\u0027s\n   line table.\n - Remove that weird \"Useless if!!!\" FIXME comment.  It\u0027s been there\n   forever, but the \"if\" is still there, so I guess the \"if\" can stay\n   there.\n\nChange-Id: I11799006fd85189e8cf5bd3a168f8f38c2c27a80\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "034db5987356e369392c66ff22f5aa4e883d6c32",
      "old_mode": 33188,
      "old_path": "gdb/buildsym.c",
      "new_id": "628903d674f4ad7b0551cd1f7d3761214b773ea4",
      "new_mode": 33188,
      "new_path": "gdb/buildsym.c"
    },
    {
      "type": "modify",
      "old_id": "6284aafc878fba838aee8115e1863be72ab132ca",
      "old_mode": 33188,
      "old_path": "gdb/buildsym.h",
      "new_id": "ee75e6fd95d355865bbbcb6e910d9057aa124c51",
      "new_mode": 33188,
      "new_path": "gdb/buildsym.h"
    },
    {
      "type": "modify",
      "old_id": "b89e98ae05f48936d3d85cf772b4dc2ec3301926",
      "old_mode": 33188,
      "old_path": "gdb/xcoffread.c",
      "new_id": "566c0824cd5a1a521718636557e4026fb42db45f",
      "new_mode": 33188,
      "new_path": "gdb/xcoffread.c"
    }
  ]
}
