)]}'
{
  "commit": "4429b54cc831e436d27ba6f0e3c417543c22f486",
  "tree": "c4dce6b15076a3b00c3b8d73d0e932dc0d22bb0f",
  "parents": [
    "18e62b794632622c44684909edd447cf914eac44"
  ],
  "author": {
    "name": "Tom de Vries",
    "email": "tdevries@suse.de",
    "time": "Thu Jun 20 16:54:47 2024 +0200"
  },
  "committer": {
    "name": "Tom de Vries",
    "email": "tdevries@suse.de",
    "time": "Thu Jun 20 16:54:47 2024 +0200"
  },
  "message": "[gdb/testsuite] Fix gdb.python/py-format-address.exp on arm\n\nWhen running test-case gdb.python/py-format-address.exp on arm-linux, I get:\n...\n(gdb) python print(\"Got: \" + gdb.format_address(0x103dd))^M\nGot: 0x103dd \u003cmain at py-format-address.c:30\u003e^M\n(gdb) FAIL: $exp: symbol_filename\u003don: gdb.format_address, \\\nresult should have an offset\n...\n\nWhat is expected here is:\n...\nGot: 0x103dd \u003cmain+1 at py-format-address.c:30\u003e^M\n...\n\nMain starts at main_addr:\n...\n(gdb) print /x \u0026main^M\n$1 \u003d 0x103dc^M\n...\nand we obtained next_addr 0x103dd by adding 1 to it:\n...\nset next_addr [format 0x%x [expr $main_addr + 1]]\n...\n\nAdding 1 to $main_addr results in an address for a thumb function starting at\naddress 0x103dc, which is incorrect because main is an arm function (because\nI\u0027m running with target board unix/-marm).\n\nAt some point during the call to format_addr, arm_addr_bits_remove removes\nthe thumb bit, which causes the +1 offset to be dropped, causing the FAIL.\n\nFix this by using the address of the breakpoint on main, provided it\u0027s not at\nthe very start of main.\n\nTested on arm-linux.\n\nPR testsuite/31452\nBug: https://www.sourceware.org/bugzilla/show_bug.cgi?id\u003d31452\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "8e7cf47e03a007dd3c78ae3925abfef9b7f12fdf",
      "old_mode": 33188,
      "old_path": "gdb/testsuite/gdb.python/py-format-address.exp",
      "new_id": "ab8022c753b8264e194daca2149b2ae9163375d2",
      "new_mode": 33188,
      "new_path": "gdb/testsuite/gdb.python/py-format-address.exp"
    }
  ]
}
