)]}'
{
  "commit": "ef1c830f003acaf149bb9ee230be0d0067e1855c",
  "tree": "7a9a5efeff511a38f4c593158424c2d5a756ad58",
  "parents": [
    "6197c6f3a6f9e8b8102ba56f5f1a4cb06e1acef3"
  ],
  "author": {
    "name": "Alan Modra",
    "email": "amodra@gmail.com",
    "time": "Mon Apr 22 09:29:28 2024 +0930"
  },
  "committer": {
    "name": "Alan Modra",
    "email": "amodra@gmail.com",
    "time": "Tue Apr 23 22:07:00 2024 +0930"
  },
  "message": "ignore some symbols in elf.c:swap_out_syms\n\nThe reason behind this patch was noticing that generic ELF targets\nfail to remove \"bar\" in the recently committed ld-elf/undefweak-1\ntest.  (Despite that, those targets pass the test due to it being too\nstrict when matching symbols.  \"bar\" gets turned into a local weak\ndefined absolute symbol.)\n\nswap_out_syms currently drops local section syms that are defined in\ndiscarded sections.  Extend that to also drop other symbols in\ndiscarded sections too, even global symbols.  The linker goes to quite\na lot of effort to ensure globals in discarded section take a\ndefinition from the kept linkonce or comdat group section.  So the\nglobal sym change should only affect cases where something is quite\nwrong about the set of linkonce or comdat group sections.  However\nthat change to elf_map_symbols meant we dropped _DYNAMIC_LINK /\n_DYNAMIC_LINKING for mips, a global absolute symbol given STT_SECTION\ntype for some reason.  That problem is fixed by reverting the pr14493\nchange which is no longer needed due to a) BSF_SECTION_SYM_USED on\nx86, and b) fixing objcopy to use copy_private_symbol_data.\n\nbfd/\n\tPR 14493\n\t* elf.c (ignore_sym): Rename from ignore_section_sym.  Return\n\ttrue for any symbol without a section or in a discarded section.\n\tRevert pr14493 change.\n\t(elf_map_symbols): Tidy.  Use ignore_sym on all symbols.\n\t(swap_out_syms): Tidy.\nld/\n\t* testsuite/ld-elf/undefweak-1.rd: Match any \"bar\".\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "41ec649ebabfd0dd669eb3cb63310fc2c2268020",
      "old_mode": 33188,
      "old_path": "bfd/elf.c",
      "new_id": "0f4907adc32acbbf74ab86415c72c221adfd8218",
      "new_mode": 33188,
      "new_path": "bfd/elf.c"
    },
    {
      "type": "modify",
      "old_id": "5b48c13c892a86f5f9697def70de20f95b3869ba",
      "old_mode": 33188,
      "old_path": "ld/testsuite/ld-elf/undefweak-1.rd",
      "new_id": "6bf3da0ce608169aa0dc5cbaef6079d6aac5b68a",
      "new_mode": 33188,
      "new_path": "ld/testsuite/ld-elf/undefweak-1.rd"
    }
  ]
}
