Make exception throwing a bit more efficient
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-04-08 Tom Tromey <tom@tromey.com>
2
3 * gdbreplay.c: Update.
4 * linux-low.c: Update.
5 * server.c: Update.
6
7 2019-04-08 Tom Tromey <tom@tromey.com>
8
9 * server.c: Use C++ exception handling.
10 * linux-low.c: Use C++ exception handling.
11 * gdbreplay.c: Use C++ exception handling.
12
13 2019-04-08 Tom Tromey <tom@tromey.com>
14
15 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
16 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
17 (captured_main, main): Update.
18 * gdbreplay.c (main): Update.
19
20 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
21
22 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
23 value in argument pointer, return 1 if the entry is found and 0
24 otherwise. Move comment.
25 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
26 * linux-low.h (linux_get_auxv): Declare.
27 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
28
29 2019-04-05 Tom Tromey <tromey@adacore.com>
30
31 * server.c (gdbserver_usage): Use upper-case for metasyntactic
32 variables.
33
34 2019-03-28 Alan Hayward <alan.hayward@arm.com>
35
36 * linux-low.c (AT_HWCAP2): Add define if not already included.
37
38 2019-03-26 Alan Hayward <alan.hayward@arm.com>
39
40 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
41 (aarch64_arch_setup): Call linux_get_hwcap.
42 * linux-arm-low.c (arm_get_hwcap): Remove function.
43 (arm_read_description): Call linux_get_hwcap.
44 * linux-low.c (linux_get_auxv): New function.
45 (linux_get_hwcap): Likewise.
46 (linux_get_hwcap2): Likewise.
47 * linux-low.h (linux_get_hwcap): New declaration.
48 (linux_get_hwcap2): Likewise.
49 * linux-ppc-low.c (ppc_get_auxv): Remove function.
50 (ppc_arch_setup): Call linux_get_hwcap.
51 * linux-s390-low.c (s390_get_hwcap): Remove function.
52 (s390_arch_setup): Call linux_get_hwcap.
53
54 2019-03-22 Alan Hayward <alan.hayward@arm.com>
55 Jiong Wang <jiong.wang@arm.com>
56
57 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
58 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
59 to fail.
60 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
61
62 2019-03-22 Alan Hayward <alan.hayward@arm.com>
63 Jiong Wang <jiong.wang@arm.com>
64
65 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
66 (aarch64_get_hwcap): New function.
67 (aarch64_arch_setup): Read APIA hwcap.
68
69 2019-03-22 Alan Hayward <alan.hayward@arm.com>
70 Jiong Wang <jiong.wang@arm.com>
71
72 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
73 (initialize_low_tracepoint): Likewise.
74 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
75 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
76 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
77 (aarch64_linux_read_description): Likewise.
78 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
79
80 2019-03-12 John Baldwin <jhb@FreeBSD.org>
81
82 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
83 i386_create_target_description for 'segments' parameter.
84 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
85 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
86 * win32-i386-low.c (i386_arch_setup): Likewise.
87
88 2019-03-12 Tom Tromey <tromey@adacore.com>
89
90 * linux-low.c (iterate_over_lwps): Update.
91
92 2019-03-06 Tom Tromey <tom@tromey.com>
93
94 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
95 (captured_main): Use SCOPE_EXIT.
96
97 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
98
99 * configure.srv: Use '$enable_unittest' instead of '$development'
100 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
101 case.
102
103 2019-02-27 Tom Tromey <tromey@adacore.com>
104
105 * gdbreplay.c (logchar): Handle \r\n.
106
107 2019-02-07 Alan Hayward <alan.hayward@arm.com>
108
109 * linux-low.c (linux_attach): Add process before lwp.
110 * server.c (attach_inferior): Check if already attached.
111
112 2019-02-07 Tom Tromey <tom@tromey.com>
113
114 * x86-tdesc.h: Rename include guard.
115 * x86-low.h: Add include guard.
116 * wincecompat.h: Rename include guard.
117 * win32-low.h: Add include guard.
118 * utils.h: Rename include guard.
119 * tracepoint.h: Rename include guard.
120 * tdesc.h: Rename include guard.
121 * target.h: Rename include guard.
122 * server.h: Rename include guard.
123 * remote-utils.h: Rename include guard.
124 * regcache.h: Rename include guard.
125 * nto-low.h: Rename include guard.
126 * notif.h: Add include guard.
127 * mem-break.h: Rename include guard.
128 * lynx-low.h: Add include guard.
129 * linux-x86-tdesc.h: Add include guard.
130 * linux-s390-tdesc.h: Add include guard.
131 * linux-ppc-tdesc-init.h: Add include guard.
132 * linux-low.h: Add include guard.
133 * linux-aarch64-tdesc.h: Add include guard.
134 * linux-aarch32-low.h: Add include guard.
135 * inferiors.h: Rename include guard.
136 * i387-fp.h: Rename include guard.
137 * hostio.h: Rename include guard.
138 * gdbthread.h: Rename include guard.
139 * gdb_proc_service.h: Rename include guard.
140 * event-loop.h: Rename include guard.
141 * dll.h: Rename include guard.
142 * debug.h: Rename include guard.
143 * ax.h: Rename include guard.
144
145 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
146
147 PR gdb/23985
148 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
149 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
150
151 2019-01-25 Tom Tromey <tom@tromey.com>
152
153 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
154
155 2019-01-25 Tom Tromey <tom@tromey.com>
156
157 * win32-low.c: Fix common/ includes.
158 * win32-i386-low.c: Fix common/ includes.
159 * tracepoint.c: Fix common/ includes.
160 * thread-db.c: Fix common/ includes.
161 * target.h: Fix common/ includes.
162 * symbol.c: Fix common/ includes.
163 * spu-low.c: Fix common/ includes.
164 * server.h: Fix common/ includes.
165 * server.c: Fix common/ includes.
166 * remote-utils.c: Fix common/ includes.
167 * regcache.h: Fix common/ includes.
168 * regcache.c: Fix common/ includes.
169 * nto-x86-low.c: Fix common/ includes.
170 * notif.h: Fix common/ includes.
171 * mem-break.h: Fix common/ includes.
172 * lynx-low.c: Fix common/ includes.
173 * lynx-i386-low.c: Fix common/ includes.
174 * linux-x86-tdesc-selftest.c: Fix common/ includes.
175 * linux-x86-low.c: Fix common/ includes.
176 * linux-low.c: Fix common/ includes.
177 * inferiors.h: Fix common/ includes.
178 * i387-fp.c: Fix common/ includes.
179 * hostio.c: Fix common/ includes.
180 * hostio-errno.c: Fix common/ includes.
181 * gdbthread.h: Fix common/ includes.
182 * gdbreplay.c: Fix common/ includes.
183 * fork-child.c: Fix common/ includes.
184 * event-loop.c: Fix common/ includes.
185 * ax.c:
186 (enum gdb_agent_op): Fix common/ includes.
187
188 2019-01-21 Tom Tromey <tom@tromey.com>
189
190 * tracepoint.c: Fix includes.
191 * remote-utils.c: Fix includes.
192 * linux-x86-low.c: Fix includes.
193
194 2019-01-01 Joel Brobecker <brobecker@adacore.com>
195
196 * gdbreplay.c (gdbreplay_version): Update copyright year in
197 version message.
198 * server.c (gdbserver_version): Likewise.
199
200 2018-12-05 Alan Hayward <alan.hayward@arm.com>
201
202 * linux-low.c (add_lwp): Switch ordering.
203
204 2018-11-29 Tom Tromey <tom@tromey.com>
205
206 * win32-low.c (win32_join): Take pid, not process.
207 * target.h (struct target_ops) <join>: Change argument type.
208 (join_inferior): Change argument name.
209 * spu-low.c (spu_join): Take pid, not process.
210 * server.c (handle_detach): Preserve pid before destroying
211 process.
212 * lynx-low.c (lynx_join): Take pid, not process.
213 * linux-low.c (linux_join): Take pid, not process.
214
215 2018-11-23 Alan Hayward <alan.hayward@arm.com>
216
217 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
218 (aarch64_cannot_fetch_register): Likewise.
219 (struct linux_target_ops): Update references.
220
221 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
222
223 * linux-ppc-low.c: Include nat/linux-ptrace.h.
224
225 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
226
227 * configure.srv (ipa_ppc_linux_regobj): Add
228 powerpc-isa207-htm-vsx32l-ipa.o and
229 powerpc-isa207-htm-vsx64l-ipa.o.
230 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
231 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
232 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
233 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
234 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
235 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
236 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
237 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
238 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
239 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
240 (init_registers_powerpc_isa207_htm_vsx32l)
241 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
242 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
243 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
244 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
245 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
246 (ppc_store_tm_ctarregset): New functions.
247 (ppc_regsets): Add entries for HTM regsets.
248 (ppc_arch_setup): Set htm in features struct when needed. Set
249 sizes for the HTM regsets.
250 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
251 (initialize_low_arch): Call
252 init_registers_powerpc_isa207_htm_vsx32l and
253 init_registers_powerpc_isa207_htm_vsx64l.
254 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
255 PPC_TDESC_ISA207_HTM_VSX.
256 (initialize_low_tracepoint): Call
257 init_registers_powerpc_isa207_htm_vsx32l and
258 init_registers_powerpc_isa207_htm_vsx64l.
259
260 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
261
262 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
263 rs6000/power-linux-pmu.xml to srv_xmlfiles.
264 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
265 (ppc_store_pmuregset): New functions.
266 (ppc_regsets): Add entries for ebb and pmu regsets.
267 (ppc_arch_setup): Set isa207 in features struct if the ebb and
268 pmu regsets are available. Set sizes for these regsets.
269
270 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
271
272 * configure.srv (ipa_ppc_linux_regobj): Add
273 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
274 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
275 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
276 rs6000/powerpc-isa207-vsx32l.xml, and
277 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
278 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
279 <PPC_TDESC_ISA207_VSX>: New enum value.
280 (init_registers_powerpc_isa207_vsx32l): Declare.
281 (init_registers_powerpc_isa207_vsx64l): Declare.
282 * linux-ppc-low.c (ppc_fill_tarregset): New function.
283 (ppc_store_tarregset): New function.
284 (ppc_regsets): Add entry for the TAR regset.
285 (ppc_arch_setup): Set isa207 in features struct when needed. Set
286 size for the TAR regsets.
287 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
288 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
289 and init_registers_powerpc_isa207_vsx64l.
290 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
291 (initialize_low_tracepoint): Call
292 init_registers_powerpc_isa207_vsx32l and
293 init_registers_powerpc_isa207_vsx64l.
294
295 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
296 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
297
298 * configure.srv (ipa_ppc_linux_regobj): Add
299 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
300 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
301 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
302 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
303 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
304 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
305 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
306 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
307 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
308 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
309 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
310 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
311 (ppc_hwcap): Add comment.
312 (ppc_hwcap2): New global.
313 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
314 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
315 (ppc_regsets): Add entries for the DSCR and PPR regsets.
316 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
317 when needed. Set sizes for the the DSCR and PPR regsets.
318 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
319 (initialize_low_arch): Call
320 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
321 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
322 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
323 PPC_TDESC_ISA205_PPR_DSCR_VSX.
324 (initialize_low_tracepoint): Call
325 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
326 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
327
328 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
329
330 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
331
332 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
333 Simon Marchi <simark@simark.ca>
334
335 * acinclude.m4: Include "../selftest.m4".
336 * configure: Regenerate.
337 * configure.ac: Use "GDB_AC_SELFTEST".
338 * configure.srv: Use "$enable_unittests" instead of
339 "$development" when checking whether unit tests have been
340 enabled.
341 * server.c (captured_main): Update message informing that
342 selftests have been disabled.
343
344 2018-10-04 Tom Tromey <tom@tromey.com>
345
346 * configure: Rebuild.
347
348 2018-10-04 Tom Tromey <tom@tromey.com>
349
350 * server.c (handle_status): Rename inner "thread".
351 (process_serial_event): Declare "res" in 'm' case.
352 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
353 (iterate_over_lwps): Rename inner "thread".
354 (linux_qxfer_libraries_svr4): Rename inner "len".
355 * gdbthread.h (find_thread_in_random): Rename inner "thread".
356
357 2018-10-01 Gary Benson <gbenson@redhat.com>
358
359 * gdb_proc_service.h: Moved common code to
360 common/gdb_proc_service.h.
361
362 2018-10-01 Gary Benson <gbenson@redhat.com>
363
364 * gdb_proc_service.h: Synchronize comments and whitespace with
365 GDB's version of this file.
366
367 2018-09-25 Tom Tromey <tom@tromey.com>
368
369 * configure: Rebuild.
370 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
371
372 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
373
374 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
375 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
376 ($(IPA_LIB)): Sort IPA_OBJS.
377
378 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
379
380 * Makefile.in: Remove references to $(ADD_DEPS).
381
382 2018-09-16 Tom Tromey <tom@tromey.com>
383
384 * remote-utils.c (remote_open): Use GNU style for metasyntactic
385 variables.
386 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
387 variables.
388
389 2018-09-05 Tom Tromey <tom@tromey.com>
390
391 * configure: Rebuild.
392
393 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
394
395 PR build/23399
396 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
397
398 2018-08-27 Tom Tromey <tom@tromey.com>
399
400 PR build/23087:
401 * configure: Rebuild.
402
403 2018-08-27 Tom Tromey <tom@tromey.com>
404
405 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
406 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
407 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
408 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
409 (s390x_emit_stack_adjust): Add casts to unsigned char.
410
411 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
412
413 PR gdb/23374
414 PR gdb/23375
415 * server.h (struct client_state) <disable_randomization>:
416 Initialize to 1.
417
418 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
419
420 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
421 variable.
422 (mips_supply_ptrace_register): Likewise.
423
424 2018-07-22 Tom Tromey <tom@tromey.com>
425
426 * configure: Rebuild.
427
428 2018-07-22 Tom Tromey <tom@tromey.com>
429
430 * win32-low.c (win32_create_inferior): Remove unused variables.
431 * gdbreplay.c (remote_open): Remove unused variable.
432 * remote-utils.c (remote_prepare): Remove unused variable.
433 * x86-tdesc.h (X86_TDESC_H): Define.
434 (amd64_expedite_regs): Define conditionally.
435 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
436 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
437 * remote-utils.c (readchar): Remove unused variable.
438
439 2018-07-13 Pedro Alves <palves@redhat.com>
440
441 * linux-low.c (linux_kill): Change parameter to process_info
442 pointer instead of pid. Adjust.
443 * lynx-low.c (lynx_kill): Likewise.
444 * nto-low.c (nto_kill): Likewise.
445 * spu-low.c (spu_kill): Likewise.
446 * win32-low.c (win32_kill): Likewise.
447 * server.c (handle_v_kill, kill_inferior_callback)
448 (detach_or_kill_for_exit): Adjust.
449 * target.c (kill_inferior): Change parameter to process_info
450 pointer instead of pid. Adjust.
451 * target.h (struct target_ops) <kill>: Change parameter to
452 process_info pointer instead of pid. Adjust all implementations
453 and callers.
454 (kill_inferior): Likewise.
455
456 2018-07-13 Pedro Alves <palves@redhat.com>
457
458 * linux-low.c (linux_detach, linux_join): Change parameter to
459 process_info pointer instead of pid. Adjust.
460 * lynx-low.c (lynx_detach, lynx_join): Likewise.
461 * nto-low.c (nto_detach): Likewise.
462 * spu-low.c (spu_detach, spu_join): Likewise.
463 * win32-low.c (win32_detach, win32_join): Likewise.
464 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
465 * target.h (struct target_ops) <detach, join>: Change parameter to
466 process_info pointer instead of pid. Adjust all implementations
467 and callers.
468 (detach_inferior, join_inferior): Rename 'pid' parameter to
469 'proc'.
470
471 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
472 Jan Kratochvil <jan.kratochvil@redhat.com>
473 Paul Fertser <fercerpav@gmail.com>
474 Tsutomu Seki <sekiriki@gmail.com>
475
476 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
477 (OBS): Add 'common/netstuff.o'.
478 (GDBREPLAY_OBS): Likewise.
479 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
480 (remote_open): Implement support for IPv6
481 connections.
482 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
483 and 'wspiapi.h'.
484 (handle_accept_event): Accept connections from IPv6 sources.
485 (remote_prepare): Handle IPv6-style hostnames; implement
486 support for IPv6 connections.
487 (remote_open): Implement support for printing connections from
488 IPv6 sources.
489
490 2018-07-11 Pedro Alves <palves@redhat.com>
491
492 PR gdb/23377
493 * mem-break.c (any_persistent_commands): Add process_info
494 parameter and use it instead of relying on the current process.
495 Change return type to bool.
496 * mem-break.h (any_persistent_commands): Add process_info
497 parameter and change return type to bool.
498 * server.c (handle_detach): Remove require_running_or_return call.
499 Look up the process_info for the process we're about to detach.
500 If not found, return back error to GDB. Adjust
501 any_persistent_commands call to pass down a process pointer.
502
503 2018-07-11 Pedro Alves <palves@redhat.com>
504
505 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
506 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
507 instead of collect_register_by_name.
508 * regcache.c (regcache_raw_get_unsigned_by_name): New.
509 * regcache.h (regcache_raw_get_unsigned_by_name): New.
510
511 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
512 Pedro Alves <palves@redhat.com>
513
514 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
515
516 2018-07-03 Tom Tromey <tom@tromey.com>
517
518 * linux-low.c: Update.
519 * lynx-low.c: Update.
520 * mem-break.c: Update.
521 * nto-low.c: Update.
522 * remote-utils.c: Update.
523 * server.c: Update.
524 * spu-low.c: Update.
525 * target.c: Update.
526 * win32-low.c: Update.
527
528 2018-07-03 Tom Tromey <tom@tromey.com>
529
530 * server.c: Update.
531
532 2018-07-03 Tom Tromey <tom@tromey.com>
533
534 * linux-low.c: Update.
535
536 2018-07-03 Tom Tromey <tom@tromey.com>
537
538 * target.c: Update.
539
540 2018-07-03 Tom Tromey <tom@tromey.com>
541
542 * linux-low.c: Update.
543 * linux-mips-low.c: Update.
544 * lynx-low.c: Update.
545 * nto-low.c: Update.
546 * remote-utils.c: Update.
547 * server.c: Update.
548 * spu-low.c: Update.
549 * target.c: Update.
550 * thread-db.c: Update.
551
552 2018-07-03 Tom Tromey <tom@tromey.com>
553
554 * linux-low.c: Update.
555 * linux-mips-low.c: Update.
556 * lynx-low.c: Update.
557 * mem-break.c: Update.
558 * nto-low.c: Update.
559 * remote-utils.c: Update.
560 * server.c: Update.
561 * spu-low.c: Update.
562 * target.c: Update.
563 * tracepoint.c: Update.
564
565 2018-07-03 Tom Tromey <tom@tromey.com>
566
567 * linux-low.c: Update.
568 * linux-ppc-low.c: Update.
569 * linux-x86-low.c: Update.
570 * proc-service.c: Update.
571 * server.c: Update.
572 * spu-low.c: Update.
573 * thread-db.c: Update.
574 * win32-low.c: Update.
575
576 2018-07-03 Tom Tromey <tom@tromey.com>
577
578 * linux-low.c: Update.
579 * lynx-low.c: Update.
580 * nto-low.c: Update.
581 * remote-utils.c: Update.
582 * spu-low.c: Update.
583 * thread-db.c: Update.
584 * win32-low.c: Update.
585
586 2018-06-29 Joel Brobecker <brobecker@adacore.com>
587
588 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
589 parameter in call to 'amd64_create_target_description'.
590
591 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
592
593 * x86-tdesc.h: Remove executable permission flag.
594
595 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
596
597 * configure.ac: Remove AC_PREREQ, add missing quoting.
598 * configure: Re-generate.
599 * config.in: Re-generate.
600 * aclocal.m4: Re-generate.
601
602 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
603
604 * tracepoint.h (current_traceframe): Remove declaration.
605
606 2018-06-18 Alan Hayward <alan.hayward@arm.com>
607
608 * linux-aarch64-low.c (is_sve_tdesc): New function.
609 (aarch64_sve_regs_copy_to_regcache): Likewise.
610 (aarch64_sve_regs_copy_from_regcache): Likewise.
611 (aarch64_regs_info): Add SVE checks.
612 (initialize_low_arch): Initialize SVE.
613
614 2018-06-18 Alan Hayward <alan.hayward@arm.com>
615
616 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
617
618 2018-06-11 Alan Hayward <alan.hayward@arm.com>
619
620 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
621 (initialize_low_tracepoint): Likewise
622 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
623 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
624 param.
625 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
626 checks.
627 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
628
629 2018-06-11 Alan Hayward <alan.hayward@arm.com>
630
631 * server.h (PBUFSIZ): Increase size
632
633 2018-06-11 Alan Hayward <alan.hayward@arm.com>
634
635 * regcache.c (regcache::raw_compare): New function.
636 * regcache.h (regcache::raw_compare): New declaration.
637
638 2018-06-11 Alan Hayward <alan.hayward@arm.com>
639
640 * regcache.c (new_register_cache): Use new.
641 (free_register_cache): Use delete.
642 (register_data): Use const.
643 (supply_register): Move body inside regcache.
644 (regcache::raw_supply): New override function.
645 (collect_register): Move body inside regcache.
646 (regcache::raw_collect): New override function.
647 (regcache::get_register_status): New override function.
648 * regcache.h (struct regcache): Inherit from reg_buffer_common.
649
650 2018-06-09 Tom Tromey <tom@tromey.com>
651
652 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
653 declare queue.
654 (event_queue): Use std::queue.
655 (gdb_event_xfree): Remove.
656 (initialize_event_loop, process_event, wait_for_event): Update.
657
658 2018-06-08 Stan Cox <scox@redhat.com>
659
660 * win32-low.c (win32_create_inferior): last_ptid and last_status
661 moved to client_state.
662
663 2018-06-08 Pedro Alves <palves@redhat.com>
664
665 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
666 common/common-exceptions.o, common/common-utils.o,
667 common/errors.o, common/print-utils.o and utils.o.
668 * gdbreplay.c: Include "common-defs.h" instead of the two
669 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
670 string.h or alloca.h.
671 (perror_with_name): Delete.
672 (remote_open): Use xstrdup instead of strdup.
673 (main): Rename to ...
674 (captured_main): ... this.
675 (main): New.
676
677 2018-06-08 Tom Tromey <tom@tromey.com>
678
679 * linux-low.c (linux_low_read_btrace): Update.
680
681 2018-06-04 Stan Cox <scox@redhat.com>
682
683 * server.h (struct client_state): New.
684 * server.c (cont_thread, general_thread, multi_process)
685 (report_fork_events, report_vfork_events, report_exec_events)
686 (report_thread_events, swbreak_feature, hwbreak_feature)
687 (vCont_supported, disable_randomization, pass_signals)
688 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
689 Moved to client_state.
690 * remote-utils.c (remote_debug, noack_mode)
691 (transport_is_reliable): Moved to client_state.
692 * tracepoint.c (current_traceframe): Moved to client_state.
693
694 Update all callers.
695 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
696 linux-low.c, remote-utils.h, target.c: Use client_state.
697
698 2018-05-31 Alan Hayward <alan.hayward@arm.com>
699
700 * configure.srv: Add new c/h file.
701
702 2018-05-31 Alan Hayward <alan.hayward@arm.com>
703
704 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
705 null VQ.
706
707 2018-05-25 Maciej W. Rozycki <macro@mips.com>
708
709 * gdb.arch/mips-fpregset-core.exp: New test.
710 * gdb.arch/mips-fpregset-core.c: New test source.
711
712 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
713
714 PR server/23198
715 * hostio.c (require_int): Do not report overflow for integers
716 between 0xfffffff and 0x7fffffff.
717
718 2018-05-22 Maciej W. Rozycki <macro@mips.com>
719
720 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
721 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
722 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
723 functions.
724 (the_low_target): Wire them.
725
726 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
727
728 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
729 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
730 mode. Call collect_register_by_name with vscr using
731 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
732 (ppc_store_vrregset): Add and set vscr_offset variable as in
733 ppc_fill_vrregset. Call supply_register_by_name with vscr using
734 vscr_offset.
735
736 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
737
738 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
739 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
740 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
741
742 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
743
744 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
745 (ppc_store_vsxregset): Likewise.
746 (ppc_fill_vrregset): Likewise.
747 (ppc_store_vrregset): Likewise.
748 (ppc_fill_evrregset): Likewise.
749 (ppc_store_evrregset): Likewise.
750 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
751 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
752 needed.
753
754 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
755
756 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
757 wordsize of the inferior. Call ppc_linux_target_wordsize.
758
759 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
760
761 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
762 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
763 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
764 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
765 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
766 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
767 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
768 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
769 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
770 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
771 (tdesc_powerpc_e500l): Remove.
772 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
773 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
774 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
775 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
776 linux-ppc-tdesc.h.
777 (ppc_arch_setup): Remove target description matching code. Fill a
778 ppc_linux_features struct and call ppc_linux_match_description
779 with it.
780
781 2018-05-22 Maciej W. Rozycki <macro@mips.com>
782
783 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
784 width of the requested register exceeds the width of the
785 `ptrace' data type.
786 (mips_cannot_store_register): Likewise.
787
788 2018-05-21 Maciej W. Rozycki <macro@mips.com>
789
790 * linux-mips-low.c (mips_fetch_register): New function. Update
791 preceding comment.
792 (mips_store_gregset): Supply 0 rather than $restart for $zero.
793 (the_low_target): Wire `mips_fetch_register'.
794
795 2018-05-10 Joel Brobecker <brobecker@adacore.com>
796
797 * lynx-i386-low.c (LYNXOS_178): New macro.
798 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
799 the layout on LynxOS-178.
800 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
801 handle floating point registers that are not supported by
802 LynxOS-178.
803
804 2018-05-10 Tom Tromey <tom@tromey.com>
805
806 * configure: Rebuild.
807
808 2018-05-10 Joel Brobecker <brobecker@adacore.com>
809
810 PR server/23158:
811 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
812 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
813 Use it to set the expedite_regs field in the given tdesc.
814 * x86-tdesc.h: New file.
815 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
816 Adjust following the addition of the new expedite_regs parameter
817 to init_target_desc.
818 * linux-tic6x-low.c (tic6x_read_description): Likewise.
819 * linux-x86-tdesc.c: #include "x86-tdesc.h".
820 (i386_linux_read_description, amd64_linux_read_description):
821 Adjust following the addition of the new expedite_regs parameter
822 to init_target_desc.
823 * lynx-i386-low.c: #include "x86-tdesc.h".
824 (lynx_i386_arch_setup): Adjust following the addition of the new
825 expedite_regs parameter to init_target_desc.
826 * nto-x86-low.c: #include "x86-tdesc.h".
827 (nto_x86_arch_setup): Adjust following the addition of the new
828 expedite_regs parameter to init_target_desc.
829 * win32-i386-low.c: #include "x86-tdesc.h".
830 (i386_arch_setup): Adjust following the addition of the new
831 expedite_regs parameter to init_target_desc.
832
833 2018-05-10 Joel Brobecker <brobecker@adacore.com>
834
835 PR server/23158:
836 * win32-low.c (win32_create_inferior): Add call to my_wait
837 setting last_status global.
838
839 2018-05-10 Joel Brobecker <brobecker@adacore.com>
840
841 PR server/23158:
842 * win32-low.c (create_process): Only call gdb_tilde_expand if
843 inferior_cwd is not NULL.
844
845 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
846
847 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
848 registers to the cache if their values have changed.
849 (i387_xsave_to_cache): Provide default values for x87 control
850 registers when these features are available, but disabled.
851 * regcache.c (supply_register_by_name_zeroed): New function.
852 * regcache.h (supply_register_by_name_zeroed): Declare new
853 function.
854
855 2018-05-07 Tom Tromey <tom@tromey.com>
856
857 * configure: Rebuild.
858
859 2018-05-04 Tom Tromey <tom@tromey.com>
860
861 * configure: Rebuild.
862
863 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
864 Pedro Alves <palves@redhat.com>
865
866 * linux-aarch64-low.c (aarch64_stopped_data_address):
867 Likewise.
868
869 2018-04-27 Tom Tromey <tom@tromey.com>
870
871 * configure: Rebuild.
872
873 2018-04-23 Tom Tromey <tom@tromey.com>
874
875 * configure: Rebuild.
876
877 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
878
879 * Makefile.in (depcomp): Add "..".
880 (all_deps_files): New and use it.
881
882 2018-04-18 Alan Hayward <alan.hayward@arm.com>
883
884 * configure.srv (aarch64*-*-linux*): Don't include xml.
885 (i[34567]86-*-cygwin*): Likewise.
886 (i[34567]86-*-linux*): Likewise.
887 (i[34567]86-*-lynxos*): Likewise.
888 (i[34567]86-*-mingw32ce*): Likewise.
889 (i[34567]86-*-mingw*): Likewise.
890 (i[34567]86-*-nto*): Likewise.
891 (tic6x-*-uclinux): Likewise.
892 (x86_64-*-linux*): Likewise.
893 (x86_64-*-mingw*): Likewise.
894 (x86_64-*-cygwin*): Likewise.
895
896 2018-04-18 Alan Hayward <alan.hayward@arm.com>
897
898 * tdesc.c: Remove xml parameter.
899
900 2018-04-18 Alan Hayward <alan.hayward@arm.com>
901
902 * server.c (get_features_xml): Remove cast.
903 * tdesc.c (void target_desc::accept): Fill in function.
904 (tdesc_get_features_xml): Remove old xml creation.
905 (print_xml_feature::visit_pre): Add xml vistor.
906 * tdesc.h (struct target_desc): Make xmltarget mutable.
907 (tdesc_get_features_xml): Remove declaration.
908
909 2018-04-18 Alan Hayward <alan.hayward@arm.com>
910
911 * tdesc.c (tdesc_architecture_name): Add new function.
912 (tdesc_osabi_name): Likewise.
913 (tdesc_get_features_xml): Use new functions.
914
915 2018-04-18 Alan Hayward <alan.hayward@arm.com>
916
917 * tdesc.c (tdesc_create_flags): Remove.
918 (tdesc_add_flag): Likewise.
919 (tdesc_named_type): Likewise.
920 (tdesc_create_union): Likewise.
921 (tdesc_create_struct): Likewise.
922 (tdesc_create_vector): Likewise.
923 (tdesc_add_bitfield): Likewise.
924 (tdesc_add_field): Likewise.
925 (tdesc_set_struct_size): Likewise.
926
927 2018-04-18 Alan Hayward <alan.hayward@arm.com>
928
929 * tdesc.c (~target_desc): Remove implictly deleted items.
930 (init_target_desc): Iterate all features.
931 (tdesc_get_features_xml): Use vector.
932 (tdesc_create_feature): Create feature.
933 * tdesc.h (tdesc_feature) Remove
934 (target_desc): Add features.
935
936 2018-04-18 Alan Hayward <alan.hayward@arm.com>
937
938 * Makefile.in: Add common/tdesc.c
939 * tdesc.c (init_target_desc): init all reg_defs from register
940 vector.
941 (tdesc_create_reg): Create tdesc_reg.
942 * tdesc.h (tdesc_feature): Add register vector.
943
944 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
945
946 * tdesc.h (struct target_desc) <features>: Change type to
947 std::vector<std::string>.
948 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
949 changes.
950 (tdesc_get_features_xml): Likewise.
951 (tdesc_create_feature): Likewise.
952
953 2018-03-26 Alan Hayward <alan.hayward@arm.com>
954
955 * regcache.c (find_register_by_number): Return a ref.
956 (find_regno): Use references.
957 (register_size): Likewise.
958 (register_data): Likewise.
959 * tdesc.c (target_desc::~target_desc): Remove free calls.
960 (target_desc::operator==): Use std::vector compare.
961 (init_target_desc): Use reference.
962 (tdesc_create_reg): Use reg constructors.
963 * tdesc.h (struct target_desc): Replace pointer with object.
964
965 2018-03-23 Alan Hayward <alan.hayward@arm.com>
966
967 * regcache.c (find_register_by_number): Make static.
968 (find_regno): Use find_register_by_number
969 * regcache.h (struct reg): Remove declaration.
970
971 2018-03-23 Alan Hayward <alan.hayward@arm.com>
972
973 * tdesc.c (target_desc::~target_desc): Move to here.
974 (target_desc::operator==): Likewise.
975 * tdesc.h (target_desc::~target_desc): Move from here.
976 (target_desc::operator==): Likewise.
977
978 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
979
980 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
981
982 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
983
984 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
985 S390_TDESC_GS.
986 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
987 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
988 and init_registers_s390_gs_linux64.
989
990 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
991
992 * linux-s390-low.c (s390_fill_gs): Remove function.
993 (s390_fill_gsbc): Remove function.
994 (s390_regsets): Set fill functions for the guarded storage regsets
995 to NULL.
996
997 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
998
999 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1000 the word size. Add comment.
1001 (s390_get_wordsize): New function.
1002 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1003 pswm with it. Instead, use s390_get_wordsize to determine the
1004 word size first and derive the correct tdesc from that directly.
1005
1006 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1007
1008 * Makefile.in: Include silent-rules.mk.
1009 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1010 (COMPILE): Add ECHO_CXX.
1011 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1012 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1013 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1014 (version-generated.c): Add ECHO_GEN.
1015 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1016 (IPAGENT_COMPILE): Add ECHO_CXX.
1017 (%-generated.c): Add ECHO_REGDAT.
1018
1019 2018-03-14 Tom Tromey <tom@tromey.com>
1020
1021 PR cli/14977:
1022 * ax.c (ax_printf): Special case for NULL.
1023
1024 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1025
1026 * linux-low.c (linux_qxfer_libraries_svr4): Use
1027 xml_escape_text_append.
1028
1029 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1030
1031 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1032
1033 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1034
1035 * server.c (handle_general_set): Remove unnecessary xstrdup.
1036
1037 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1038
1039 * server.c (parse_debug_format_options): Adjust to
1040 delim_string_to_char_ptr_vec changes.
1041 * thread-db.c (thread_db_load_search): Adjust to
1042 dirnames_to_char_ptr_vec changes.
1043
1044 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1045
1046 * target.h (target_enable_btrace, target_disable_btrace)
1047 (target_read_btrace, target_read_btrace_conf): Turn macro into
1048 inline function. Throw error if target method is not defined.
1049 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1050 check for btrace target method. Be prepared to handle exceptions
1051 from btrace target methods.
1052
1053 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1054
1055 * server.c (captured_main): Change order of error message printed
1056 when the current working directory cannot be found.
1057
1058 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1059
1060 * server.c: Include "filenames.h" and "pathstuff.h".
1061 (program_name): Delete variable.
1062 (program_path): New anonymous class.
1063 (get_exec_wrapper): Use "program_path" instead of
1064 "program_name".
1065 (handle_v_run): Likewise.
1066 (captured_main): Likewise.
1067 (process_serial_event): Likewise.
1068
1069 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1070
1071 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1072 (OBJS): Add "pathstuff.o".
1073 * server.c (current_directory): New global variable.
1074 (captured_main): Initialize "current_directory".
1075
1076 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1077
1078 * tdesc.c: Use common/tdesc.h.
1079 * tdesc.h: Likewise.
1080
1081 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1082 Simon Marchi <simon.marchi@ericsson.com>
1083
1084 * Makefile.in: Switch order of make rules.
1085
1086 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1087
1088 * Makefile.in: Add common directory in build.
1089 * configure.ac: Add common reference.
1090 * configure: Regenerate.
1091
1092 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1093
1094 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1095 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1096 * spu-low.c (spu_target_ops): Likewise.
1097 * win32-low.c (win32_target_ops): Likewise.
1098 * server.c (supported_btrace_packets): Report packets unconditionally.
1099 * target.h (target_ops) <supports_btrace>: Remove.
1100 (target_supports_btrace): Remove.
1101
1102 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1103
1104 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1105 (handle_btrace_disable): Change return type to void. Use exceptions
1106 to report errors.
1107 (handle_btrace_general_set): Catch exception and copy message to
1108 return message.
1109
1110 2018-02-08 Tom Tromey <tom@tromey.com>
1111
1112 * linux-low.c (install_software_single_step_breakpoints): Use
1113 make_scoped_restore.
1114 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1115 (do_restore_current_thread_cleanup): Remove.
1116 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1117 declare.
1118
1119 2018-02-08 Tom Tromey <tom@tromey.com>
1120
1121 * mem-break.c (set_raw_breakpoint_at): Use
1122 gdb::unique_xmalloc_ptr.
1123
1124 2018-01-30 Pedro Alves <palves@redhat.com>
1125
1126 PR gdb/13211
1127 * target.c (target_terminal::terminal_state): Rename to ...
1128 (target_terminal::m_terminal_state): ... this.
1129
1130 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1131
1132 * linux-low.c (handle_extended_wait): Surround call to
1133 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1134
1135 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1136
1137 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1138 linux_ptrace_attach_fail_reason_string now returning an
1139 std::string.
1140 (linux_attach): Likewise.
1141 * thread-db.c (attach_thread): Likewise.
1142
1143 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1144
1145 PR gdb/21559
1146 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1147 checking for fs_base/gs_base fields in struct user_regs_struct.
1148 * configure: Regenerate.
1149
1150 2018-01-16 Yao Qi <yao.qi@linaro.org>
1151
1152 PR gdb/18749
1153 * linux-low.c (fetch_register): Call supply_register instead of
1154 error.
1155
1156 2018-01-08 Yao Qi <yao.qi@linaro.org>
1157 Simon Marchi <simon.marchi@ericsson.com>
1158
1159 * Makefile.in (OBS): Remove selftest.o.
1160 * configure.ac: Set srv_selftest_objs if $development is true.
1161 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1162 * configure: Re-generated.
1163 * server.c (captured_main): Wrap variable selftest_filter with
1164 GDB_SELF_TEST.
1165
1166 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1167
1168 * server.c (parse_debug_format_options): Return std::string.
1169 (handle_monitor_command, captured_main): Adjust.
1170
1171 2018-01-05 Pedro Alves <palves@redhat.com>
1172
1173 PR gdb/18653
1174 * server.c (captured_main): Pass quiet=false to
1175 save_original_signals_state.
1176
1177 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1178
1179 * gdbreplay.c (gdbreplay_version): Update copyright year in
1180 version message.
1181 * server.c (gdbserver_version): Likewise.
1182
1183 2017-12-08 Tom Tromey <tom@tromey.com>
1184
1185 * ax.c (ax_printf): Update.
1186
1187 2017-12-07 Yao Qi <yao.qi@linaro.org>
1188
1189 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1190 aarch64_linux_read_description.
1191 * linux-amd64-ipa.c (idx2mask): New array.
1192 (get_ipa_tdesc): Move idx2mask out.
1193 (initialize_low_tracepoint): Initialize target descriptions.
1194 * linux-i386-ipa.c (idx2mask): New array.
1195 (get_ipa_tdesc): Move idx2mask out.
1196 (initialize_low_tracepoint): Initialize target descriptions.
1197
1198 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1199
1200 * tdesc.c (struct tdesc_type): Change return type.
1201 (tdesc_add_flag): Change parameter type.
1202 (tdesc_add_bitfield): Likewise.
1203 (tdesc_add_field): Likewise.
1204 (tdesc_set_struct_size): Likewise.
1205
1206 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1207
1208 * regcache.c (registers_to_string): Remove unused variable.
1209
1210 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1211
1212 * inferiors.c (for_each_inferior_with_data): Remove.
1213 * inferiors.h (for_each_inferior_with_data): Remove.
1214 * server.c (handle_qxfer_threads_worker): Change parameter type.
1215 (handle_qxfer_threads_proper): Use for_each_thread.
1216
1217 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1218
1219 * inferiors.c (for_each_inferior): Remove.
1220 (clear_inferiors): Use for_each_thread.
1221 * inferiors.h (for_each_inferior): Remove.
1222 * linux-low.c (linux_wait_for_event_filtered): Use
1223 for_each_thread.
1224 (linux_stabilize_threads): Likewise.
1225 * regcache.c (regcache_release): Likewise.
1226 * server.c (gdb_wants_all_threads_stopped): Likewise.
1227 (clear_pending_status_callback): Remove.
1228 (handle_status): Use for_each_thread.
1229 (captured_main): Likewise.
1230 * win32-low.c (child_init_thread_list): Likewise.
1231 (win32_clear_inferiors): Likewise.
1232 (fake_breakpoint_event): Likewise.
1233
1234 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1235
1236 * inferiors.h (find_inferior): Remove.
1237 * inferiors.c (find_inferior): Remove.
1238
1239 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1240
1241 * linux-low.c (resume_status_pending_p): Update comment.
1242 (need_step_over_p): Update comment.
1243
1244 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1245
1246 * linux-low.c (proceed_one_lwp): Return void, change parameter
1247 type.
1248 (unsuspend_and_proceed_one_lwp): Likewise.
1249 (proceed_all_lwps): Use for_each_thread.
1250 (unstop_all_lwps): Likewise.
1251
1252 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1253
1254 * linux-low.c (linux_resume_one_thread): Return void, take
1255 parameter directly.
1256 (linux_resume): Use for_each_thread.
1257
1258 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1259
1260 * linux-low.c (send_sigstop_callback): Return void, change
1261 parameter type. Rename to...
1262 (send_sigstop): ... this.
1263 (suspend_and_send_sigstop_callback): Return void, change parameter
1264 type. Rename to...
1265 (suspend_and_send_sigstop): ... this.
1266 (stop_all_lwps): Use for_each_thread.
1267
1268 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1269
1270 * linux-low.c (lwp_running): Return bool, remove unused
1271 argument.
1272 (linux_stabilize_threads): Use find_thread.
1273
1274 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1275
1276 * linux-low.c (select_singlestep_lwp_callback): Remove.
1277 (count_events_callback): Remove.
1278 (select_event_lwp_callback): Remove.
1279 (select_event_lwp): Use find_thread/for_each_thread.
1280
1281 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1282
1283 * linux-low.c (not_stopped_callback): Return bool, take filter
1284 argument directly.
1285 (linux_wait_for_event_filtered): Use find_thread.
1286 (linux_wait_1): Likewise.
1287
1288 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1289
1290 * linux-low.c (same_lwp): Remove.
1291 (find_lwp_pid): Use find_thread.
1292
1293 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1294
1295 * linux-low.c (delete_lwp_callback): Remove.
1296 (linux_mourn): Use for_each_thread.
1297
1298 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1299
1300 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1301 args parameter, don't check for pid.
1302 (linux_detach): Use for_each_thread.
1303
1304 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1305
1306 * linux-low.c (struct counter): Remove.
1307 (second_thread_of_pid_p): Remove.
1308 (last_thread_of_process_p): Use find_thread.
1309
1310 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1311
1312 * inferiors.c (find_inferior_in_random): Remove.
1313 * inferiors.h (find_inferior_in_random): Remove.
1314 * linux-low.c (status_pending_p_callback): Return bool, accept
1315 parameter ptid directly.
1316 (linux_wait_for_event_filtered): Use find_thread_in_random.
1317 (linux_wait_1): Likewise.
1318
1319 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1320
1321 * inferiors.c (find_inferior_id): Remove.
1322 (find_thread_ptid): Move implemention from find_inferior_id to
1323 here.
1324 * inferiors.h (find_inferior_id): Remove.
1325 * server.c (handle_status): Use find_thread_ptid.
1326 (process_serial_event): Likewise.
1327 * thread-db.c (find_one_thread): Likewise.
1328 (thread_db_thread_handle): Likewise.
1329 * win32-low.c (thread_rec): Likewise.
1330 (child_delete_thread): Likewise.
1331 (win32_thread_alive): Likewise.
1332 (get_child_debug_event): Likewise.
1333
1334 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1335
1336 * linux-mips-low.c (update_watch_registers_callback): Return
1337 void, remove pid_p parameter, don't check for pid.
1338 (mips_insert_point, mips_remove_point): Use for_each_thread.
1339
1340 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1341
1342 * lynx.low (lynx_delete_thread_callback): Remove.
1343 (lynx_mourn): Use for_each_thread.
1344
1345 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1346
1347 * regcache.c (regcache_invalidate_one): Remove.
1348 (regcache_invalidate_pid): use for_each_thread.
1349
1350 2017-11-26 Tom Tromey <tom@tromey.com>
1351
1352 * linux-low.c (linux_create_inferior): Update.
1353
1354 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1355
1356 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1357
1358 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1359
1360 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1361 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1362 * linux-aarch64-tdesc-selftest.c: New file.
1363 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1364
1365 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1366
1367 * configure.srv: Add new file.
1368 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1369 * linux-aarch64-tdesc-selftest.c: New file.
1370 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1371
1372 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1373
1374 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1375 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1376 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1377
1378 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1379
1380 * configure.srv: Add new files.
1381 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1382 aarch64_linux_read_description.
1383 * linux-aarch64-low.c (aarch64_linux_read_description):
1384 Merge with aarch64_arch_setup.
1385 (aarch64_arch_setup): Call aarch64_linux_read_description.
1386 * linux-aarch64-tdesc.c: New file.
1387 * linux-aarch64-tdesc.h: New file.
1388
1389 2017-11-24 Yao Qi <yao.qi@linaro.org>
1390
1391 * configure.srv: Set $srv_regobj for tic6x-linux.
1392 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1393 (tic6x_read_description): Move some code to tic6x_arch_setup.
1394 (tic6x_tdesc_test): New function.
1395 (initialize_low_arch): Call selftests::register_test.
1396
1397 2017-11-22 Yao Qi <yao.qi@linaro.org>
1398
1399 * remote-utils.c (prepare_resume_reply): Use memcpy.
1400
1401 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1402
1403 * linux-low.c (kill_one_lwp_callback): Return void, take
1404 argument directly, don't filter on pid.
1405 (linux_kill): Use for_each_thread.
1406
1407 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1408
1409 * linux-low.c (need_step_over_p): Return bool, remove dummy
1410 argument.
1411 (linux_resume, proceed_all_lwps): Use find_thread.
1412
1413 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1414
1415 * linux-low.c (resume_status_pending_p): Return bool, remove
1416 flag_p argument.
1417 (linux_resume): Use find_thread.
1418
1419 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1420
1421 * linux-low.c (struct thread_resume_array): Remove.
1422 (linux_set_resume_request): Return void, take arguments
1423 directly.
1424 (linux_resume): Use for_each_thread.
1425
1426 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1427
1428 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1429 return bool, remove data argument.
1430 (linux_stabilize_threads): Use find_thread.
1431
1432 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1433
1434 * linux-low.c (unsuspend_one_lwp): Remove.
1435 (unsuspend_all_lwps): Use for_each_thread, inline code from
1436 unsuspend_one_lwp.
1437
1438 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1439
1440 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1441 * linux-low.c (struct iterate_over_lwps_args): Remove.
1442 (iterate_over_lwps_filter): Remove.
1443 (iterate_over_lwps): Use find_thread.
1444
1445 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1446
1447 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1448 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1449 code from reset_lwp_ptrace_options_callback.
1450
1451 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1452
1453 * linux-arm-low.c (struct update_registers_data): Remove.
1454 (update_registers_callback): Return void, take arguments
1455 directly, don't check thread's pid.
1456 (arm_insert_point, arm_remove_point): Use for_each_thread.
1457
1458 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1459
1460 * win32-low.c (continue_one_thread): Return void, take argument
1461 directly.
1462 (child_continue): Use for_each_thread.
1463
1464 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1465
1466 * win32-i386-low.c (update_debug_registers_callback): Rename
1467 to ...
1468 (update_debug_registers): ... this, return void, remove pid_p arg.
1469 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1470
1471 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1472
1473 * inferiors.h (struct process_info): Add constructor, initialize
1474 fields..
1475 <syscalls_to_catch>: Change type to std::vector<int>.
1476 * inferiors.c (add_process): Allocate process_info with new.
1477 (remove_process): Free process_info with delete.
1478 * linux-low.c (handle_extended_wait): Adjust.
1479 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1480 * server.c (handle_general_set): Adjust.
1481
1482 2017-11-16 Pedro Alves <palves@redhat.com>
1483
1484 * remote-utils.c (remote_close): Block SIGIO signals instead of
1485 uninstalling the SIGIO handler.
1486
1487 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1488
1489 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1490
1491 2017-11-16 Yao Qi <yao.qi@linaro.org>
1492
1493 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1494 (tic6x_store_gregset): Likewise.
1495 (tic6x_usrregs_info): Move it up.
1496
1497 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1498
1499 * Makefile.in: Update arch rules.
1500 * configure.srv: Explicitly mark arch/ files.
1501
1502 2017-11-13 Andreas Schwab <schwab@suse.de>
1503
1504 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1505 function.
1506 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1507
1508 2017-11-06 Pedro Alves <palves@redhat.com>
1509
1510 * config.in, configure: Regenerate.
1511
1512 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1513
1514 * target.c (struct thread_search): Remove.
1515 (thread_search_callback): Remove.
1516 (prepare_to_access_memory): Use for_each_thread instead of
1517 find_inferior. Inline code from thread_search_callback.
1518
1519 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1520
1521 * server.c (struct visit_actioned_threads_data): Remove.
1522 (visit_actioned_threads): Change prototype to take arguments
1523 directly.
1524 (resume): Use find_thread instead of find_inferior.
1525
1526 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1527
1528 * server.c (queue_stop_reply_callback): Change prototype, return
1529 void.
1530 (find_status_pending_thread_callback): Remove.
1531 (handle_status): Replace find_inferior with find_thread and
1532 for_each_thread.
1533
1534 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1535
1536 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1537 with REGNO.
1538 (aarch64_store_gregset): Likewise.
1539 (aarch64_fill_fpregset): Likewise.
1540 (aarch64_store_fpregset): Likewise.
1541
1542 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1543
1544 * gdbthread.h (find_thread, for_each_thread): New functions.
1545 * inferiors.c (thread_of_pid): Remove.
1546 (find_any_thread_of_pid): Use find_thread.
1547 * linux-low.c (num_lwps): Use for_each_thread.
1548
1549 2017-10-17 Yao Qi <yao.qi@linaro.org>
1550
1551 * Makefile.in: Remove one rule.
1552 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1553
1554 2017-10-17 Yao Qi <yao.qi@linaro.org>
1555
1556 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1557 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1558
1559 2017-10-17 Yao Qi <yao.qi@linaro.org>
1560
1561 * configure.srv: Rename arm.o with arch/arm.o.
1562
1563 2017-10-17 Yao Qi <yao.qi@linaro.org>
1564
1565 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1566 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1567 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1568 (arch-i386.o, arch-amd64.o): Remove rules.
1569 (arch/%.o): New rule.
1570 Update POSTCOMPILE and COMPILE.pre.
1571 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1572 * configure: Re-generated.
1573 * configure.srv: Replace arch-i386.o with arch/i386.o.
1574 Replace arch-amd64.o with arch/amd64.o.
1575
1576 2017-10-16 Yao Qi <yao.qi@linaro.org>
1577
1578 * configure: Regenerated.
1579
1580 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1581
1582 * inferiors.h: (struct inferior_list): Remove.
1583 (struct inferior_list_entry); Remove.
1584 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
1585 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
1586 get_first_inferior): Remove.
1587 (for_each_inferior, for_each_inferior_with_data, find_inferior,
1588 find_inferior_id, find_inferior_in_random): Change signature.
1589 * inferiors.c (all_threads): Change type to
1590 std::list<thread_info *>.
1591 (get_thread): Remove macro.
1592 (find_inferior, find_inferior_id): Change signature, implement
1593 using find_thread.
1594 (find_inferior_in_random): Change signature, implement using
1595 find_thread_in_random.
1596 (for_each_inferior, for_each_inferior_with_data): Change
1597 signature, implement using for_each_thread.
1598 (add_inferior_to_list, remove_inferior): Remove.
1599 (add_thread, get_first_thread, thread_of_pid,
1600 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
1601 (get_first_inferior, one_inferior_p, clear_inferior_list):
1602 Remove.
1603 (clear_inferiors, get_thread_process): Update.
1604 * gdbthread.h: Include <list>.
1605 (struct thread_info) <entry>: Remove field.
1606 <id>: New field.
1607 (all_threads): Change type to std::list<thread_info *>.
1608 (get_first_inferior): Add doc.
1609 (find_thread, for_each_thread, find_thread_in_random): New
1610 functions.
1611 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
1612 * linux-arm-low.c (update_registers_callback): Update.
1613 * linux-low.c (second_thread_of_pid_p): Update.
1614 (kill_one_lwp_callback, linux_detach_lwp_callback,
1615 delete_lwp_callback, status_pending_p_callback, same_lwp,
1616 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
1617 iterate_over_lwps, not_stopped_callback,
1618 resume_stopped_resumed_lwps, count_events_callback,
1619 select_singlestep_lwp_callback, select_event_lwp_callback,
1620 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
1621 suspend_and_send_sigstop_callback, wait_for_sigstop,
1622 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
1623 lwp_running, linux_set_resume_request, resume_status_pending_p,
1624 need_step_over_p, start_step_over, linux_resume_one_thread,
1625 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
1626 reset_lwp_ptrace_options_callback): Update.
1627 * linux-mips-low.c (update_watch_registers_callback): Update.
1628 * regcache.c (regcache_invalidate_one, regcache_invalidate):
1629 Update.
1630 (free_register_cache_thread_one): Remove.
1631 (regcache_release): Update.
1632 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
1633 handle_qxfer_threads_worker): Update.
1634 (handle_query): Update, use list iterator.
1635 (visit_actioned_threads, handle_pending_status,
1636 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
1637 clear_pending_status_callback, set_pending_status_callback,
1638 find_status_pending_thread_callback, handle_status,
1639 process_serial_event): Update.
1640 * target.c (thread_search_callback): Update.
1641 * thread-db.c (thread_db_get_tls_address): Update.
1642 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
1643 Update.
1644 * win32-i386-low.c (update_debug_registers_callback): Update.
1645 * win32-low.c (delete_thread_info, child_delete_thread,
1646 continue_one_thread, suspend_one_thread,
1647 get_child_debug_event): Adjust.
1648
1649 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1650
1651 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
1652 * inferiors.h: Include <list>.
1653 (struct process_info) <entry>: Remove field.
1654 <pid>: New field.
1655 (pid_of): Change macro to function.
1656 (ptid_of, lwpid_of): Remove macro.
1657 (all_processes): Change type to std::list<process_info *>.
1658 (ALL_PROCESSES): Remove macro.
1659 (for_each_process, find_process): New function.
1660 * inferiors.c (all_processes): Change type to
1661 std::list<process_info *>.
1662 (find_thread_process): Adjust.
1663 (add_process): Likewise.
1664 (remove_process): Likewise.
1665 (find_process_pid): Likewise.
1666 (get_first_process): Likewise.
1667 (started_inferior_callback): Remove.
1668 (have_started_inferiors_p): Adjust.
1669 (attached_inferior_callback): Remove.
1670 (have_attached_inferiors_p): Adjust.
1671 * linux-low.c (check_zombie_leaders): Likewise.
1672 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
1673 (x86_linux_update_xmltarget): Adjust.
1674 * server.c (handle_query): Likewise.
1675 (gdb_reattached_process): Remove.
1676 (handle_status): Adjust.
1677 (kill_inferior_callback): Likewise.
1678 (detach_or_kill_inferior): Remove.
1679 (print_started_pid): Likewise.
1680 (print_attached_pid): Likewise.
1681 (detach_or_kill_for_exit): Update.
1682 (process_serial_event): Likewise.
1683 * linux-arm-low.c (arm_new_fork): Likewise.
1684
1685 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1686
1687 * dll.h: Include <list>.
1688 (struct dll_info): Add constructor.
1689 <entry>: Remove field.
1690 (all_dlls): Change type to std::list<dll_info>.
1691 * dll.c: Include <algorithm>.
1692 (get_dll): Remove macro.
1693 (all_dlls): Change type to std::list<dll_info *>.
1694 (free_one_dll): Remove.
1695 (match_dll): Likewise.
1696 (loaded_dll): Adjust.
1697 (unloaded_dll): Adjust to all_dlls type change, use
1698 std::find_if. Inline code from match_dll.
1699 (clear_dlls): Adjust to all_dlls type change.
1700 * server.c (emit_dll_description): Remove.
1701 (handle_qxfer_libraries): Adjust to all_dlls type change,
1702 integrate emit_dll_description's functionality.
1703
1704 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1705
1706 * linux-low.h (struct linux_target_ops) <delete_process>: New
1707 field.
1708 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
1709 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
1710 (struct linux_target_ops): Add delete_process callback.
1711 * linux-arm-low.c (arm_delete_process): New.
1712 (struct linux_target_ops): Add delete_process callback.
1713 * linux-bfin-low.c (struct linux_target_ops): Likewise.
1714 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
1715 * linux-m32r-low.c (struct linux_target_ops): Likewise.
1716 * linux-mips-low.c (mips_linux_delete_process): New.
1717 (struct linux_target_ops): Add delete_process callback.
1718 * linux-ppc-low.c (struct linux_target_ops): Likewise.
1719 * linux-s390-low.c (struct linux_target_ops): Likewise.
1720 * linux-sh-low.c (struct linux_target_ops): Likewise.
1721 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
1722 * linux-tile-low.c (struct linux_target_ops): Likewise.
1723 * linux-x86-low.c (x86_linux_delete_process): New.
1724 (struct linux_target_ops): Add delete_process callback.
1725 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
1726
1727 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1728
1729 * linux-aarch64-low.c (the_low_target): Add thread delete
1730 callback.
1731 * linux-arm-low.c (arm_delete_thread): New function.
1732 (the_low_target): Add thread delete callback.
1733 * linux-bfin-low.c (the_low_target): Likewise.
1734 * linux-crisv32-low.c (the_low_target): Likewise.
1735 * linux-low.c (delete_lwp): Invoke delete_thread callback if
1736 set.
1737 * linux-low.h (struct linux_target_ops) <delete_thread>: New
1738 field.
1739 * linux-m32r-low.c (the_low_target): Add thread delete callback.
1740 * linux-mips-low.c (mips_linux_delete_thread): New function.
1741 (the_low_target): Add thread delete callback.
1742 * linux-ppc-low.c (the_low_target): Likewise.
1743 * linux-s390-low.c (the_low_target): Likewise.
1744 * linux-sh-low.c (the_low_target): Likewise.
1745 * linux-tic6x-low.c (the_low_target): Likewise.
1746 * linux-tile-low.c (the_low_target): Likewise.
1747 * linux-x86-low.c (the_low_target): Likewise.
1748 * linux-xtensa-low.c (the_low_target): Likewise.
1749
1750 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
1751
1752 * win32-low.c: Include "common-inferior.h".
1753
1754 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1755
1756 * inferiors.c (set_inferior_cwd): New function.
1757 * server.c (handle_general_set): Handle QSetWorkingDir packet.
1758 (handle_query): Inform that QSetWorkingDir is supported.
1759 * win32-low.c (create_process): Pass the inferior's cwd to
1760 CreateProcess.
1761
1762 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1763
1764 * inferiors.c (current_inferior_cwd): New global variable.
1765 (get_inferior_cwd): New function.
1766 * inferiors.h (struct process_info) <cwd>: New field.
1767
1768 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1769
1770 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
1771 (OBS): Add gdb_tilde_expand.o.
1772
1773 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
1774
1775 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
1776 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
1777
1778 2017-09-29 Pedro Alves <palves@redhat.com>
1779
1780 * ax.c (gdb_parse_agent_expr): Constify.
1781 * ax.h (gdb_parse_agent_expr): Constify.
1782 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
1783 Constify.
1784 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
1785 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
1786 * remote-utils.h (read_ptid): Constify.
1787 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
1788 (process_point_options, process_serial_event): Constify.
1789 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
1790 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
1791 (cmd_qtbuffer): Constify.
1792
1793 2017-09-29 Pedro Alves <palves@redhat.com>
1794
1795 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
1796 fails.
1797
1798 2017-09-29 Pedro Alves <palves@redhat.com>
1799
1800 * linux-low.c (handle_extended_wait): Pass parent thread instead
1801 of process to thread_db_notice_clone.
1802 * linux-low.h (thread_db_notice_clone): Replace parent process
1803 parameter with parent thread parameter.
1804 * thread-db.c (find_one_thread): Add comment.
1805 (thread_db_notice_clone): Replace parent process parameter with
1806 parent thread parameter. Temporarily switch to the parent thread.
1807
1808 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
1809
1810 * gdbthread.h: Include "common-gdbthread.h".
1811 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
1812 "if" when validating the ptid.
1813 * remote-utils.c: Include "gdbthread.h".
1814 (prepare_resume_reply): Use "switch_to_thread".
1815 * target.c (done_accessing_memory): Likewise.
1816
1817 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1818
1819 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
1820 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
1821 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
1822 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
1823 s390x-gs-linux64-ipa.o to ipa_obj.
1824 * linux-s390-low.c (HWCAP_S390_GS): New define.
1825 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
1826 New functions.
1827 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
1828 (s390_arch_setup): Check for guarded-storage support and choose
1829 appropriate tdesc.
1830 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
1831 init_registers_s390x_gs_linux64.
1832 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
1833 enum value.
1834 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
1835 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
1836
1837 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
1838
1839 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
1840
1841 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1842
1843 * linux-low.h (struct lwp_info): Add new field, thread_handle.
1844 (thread_db_thread_handle): Declare.
1845 * linux-low.c (linux_target_ops): Initialize thread_handle.
1846 * server.c (handle_qxfer_threads_worker): Add support for
1847 "handle" attribute.
1848 * target.h (struct target_ops): Add new function pointer,
1849 thread_handle.
1850 (target_thread_handle): Define.
1851 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
1852 field in lwp.
1853 (thread_db_thread_handle): New function.
1854
1855 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1856
1857 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
1858 * linux-low.h (thread_db_notice_clone): Declare.
1859 * thread-db.c (thread_db_notice_clone): New function.
1860
1861 2017-09-21 Pedro Alves <palves@redhat.com>
1862
1863 * server.c (gdb_read_memory, handle_status, process_serial_event)
1864 (handle_serial_event, handle_target_event): Adjust to
1865 set_desired_thread prototype change.
1866 * target.c (set_desired_thread): Remove 'use_general' parameter
1867 and adjust.
1868 * target.h (set_desired_thread): Remove 'use_general' parameter.
1869
1870 2017-09-20 Tom Tromey <tom@tromey.com>
1871
1872 * target.c (target_terminal::terminal_state): Define.
1873 (target_terminal::init): Rename from target_terminal_init.
1874 (target_terminal::inferior): Rename from
1875 target_terminal_inferior.
1876 (target_terminal::ours): Rename from target_terminal_ours.
1877 (target_terminal::ours_for_output, target_terminal::info): New.
1878
1879 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1880
1881 * server.c (accumulate_file_name_length): Remove.
1882 (emit_dll_description): Adjust to std::string change.
1883 (handle_qxfer_libraries): Use std::string to hold document.
1884
1885 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1886
1887 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
1888 return type of xml_escape_text.
1889 * server.c (emit_dll_description): Likewise.
1890
1891 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1892
1893 * server.c (captured_main): Accept argument for --selftest.
1894 Update run_tests call.
1895 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
1896 when registering selftests.
1897
1898 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
1899
1900 * regcache.c (get_thread_regcache): Update code to use "std::vector"
1901 instead of "VEC" for "target_desc.reg_defs".
1902 (regcache_cpy): Likewise.
1903 (registers_to_string): Likewise.
1904 (registers_from_string): Likewise.
1905 (find_regno): Likewise.
1906 (supply_regblock): Likewise.
1907 (regcache_raw_read_unsigned): Likewise.
1908 * tdesc.c (init_target_desc): Likewise.
1909 (tdesc_create_reg): Likewise.
1910 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
1911 (struct target_desc) <reg_defs>: Convert to "std::vector".
1912 (target_desc): Do not initialize "reg_defs".
1913 (~target_desc): Update code to use "std::vector" instead of "VEC"
1914 for "target_desc.reg_defs".
1915 (operator==): Likewise.
1916
1917 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1918
1919 * inferiors.h (thread_to_gdb_id): Remove.
1920 * inferiors.c (thread_to_gdb_id): Remove.
1921 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
1922 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
1923 lynx_store_registers, lynx_read_memory, lynx_write_memory):
1924 Likewise.
1925 * nto-low.c (nto_fetch_registers, nto_store_registers,
1926 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
1927
1928 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1929
1930 * inferiors.h (gdb_id_to_thread_id): Remove.
1931 * inferiors.c (gdb_id_to_thread_id): Remove.
1932 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
1933 removal. Move pid declaration closer to where it's used.
1934
1935 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1936
1937 * server.c (handle_detach): New function.
1938 (process_serial_event): Move code out, call handle_detach.
1939
1940 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1941
1942 * server.c (require_running): Rename to ...
1943 (require_running_or_return): ... this ...
1944 (require_running_or_break): ... and this.
1945 (handle_query, process_serial_event): Adjust.
1946
1947 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1948
1949 * linux-low.c (linux_set_resume_request): Remove unused
1950 variables.
1951
1952 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1953
1954 * server.c (first_thread_of): Remove.
1955 (process_serial_event): Replace usage of first_thread_of with
1956 find_any_thread_of_pid.
1957 * tracepoint.c (same_process_p): Remove.
1958 (gdb_agent_about_to_close): Replace usage of same_process_p with
1959 find_any_thread_of_pid.
1960 * linux-x86-low.c (same_process_callback): Remove.
1961 (x86_arch_setup_process_callback): Replace usage of
1962 same_process_callback with find_any_thread_of_pid.
1963 * thread-db.c (any_thread_of): Remove.
1964 (switch_to_process): Replace usage of any_thread_of with
1965 find_any_thread_of_pid.
1966 * inferiors.c (thread_pid_matches_callback): Remove.
1967 (find_thread_process): Adjust to use find_any_thread_of_pid.
1968
1969 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1970
1971 * regcache.c (get_thread_regcache): Guard calls to "memset"
1972 with "!VEC_empty".
1973
1974 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1975
1976 * linux-low.c (handle_extended_wait): Use
1977 "allocate_target_description" instead of "XNEW".
1978 * linux-x86-low.c (initialize_low_arch): Likewise.
1979
1980 2017-09-05 Yao Qi <yao.qi@linaro.org>
1981
1982 * configure.srv (srv_i386_regobj): Remove.
1983 (srv_amd64_regobj): Remove.
1984 (srv_regobj): Set it to "" for x86 non-linux targets.
1985 * linux-x86-tdesc.c (i386_linux_read_description):
1986 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
1987 (init_registers_i386): Remove the declaration.
1988 (tdesc_i386): Remove the declaration.
1989 (lynx_i386_arch_setup): Call i386_create_target_description.
1990 * nto-x86-low.c: Likewise.
1991 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
1992 [!__x86_64__]: include arch/i386.h.
1993 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
1994
1995 2017-09-05 Yao Qi <yao.qi@linaro.org>
1996
1997 * configure.srv (srv_amd64_linux_xmlfiles): Remove
1998 i386/amd64-XXX-linux from it.
1999
2000 2017-09-05 Yao Qi <yao.qi@linaro.org>
2001
2002 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2003 false.
2004 (ipa_amd64_linux_regobj): Remove.
2005 (ipa_x32_linux_regobj): Remove.
2006
2007 2017-09-05 Yao Qi <yao.qi@linaro.org>
2008
2009 * Makefile.in (arch-amd64.o): New rule.
2010 * configure.srv: Append arch-amd64.o.
2011 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2012 (get_ipa_tdesc): Call amd64_linux_read_description.
2013 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2014 and init_registers_amd64_XXX.
2015 * linux-x86-low.c (x86_linux_read_description): Call
2016 amd64_linux_read_description.
2017 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2018 (initialize_low_arch): Don't call init_registers_x32_XXX and
2019 init_registers_amd64_XXX.
2020 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2021 and tdesc_amd64_XXX.
2022 [__x86_64__] (amd64_tdesc_test): New function.
2023 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2024 and init_registers_amd64_XXX.
2025 * linux-x86-tdesc.c: Include arch/amd64.h.
2026 (xcr0_to_tdesc_idx): New function.
2027 (i386_linux_read_description): New function.
2028 (amd64_get_ipa_tdesc_idx): New function.
2029 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2030 (amd64_get_ipa_tdesc): Declare.
2031
2032 2017-09-05 Yao Qi <yao.qi@linaro.org>
2033
2034 * configure.srv (srv_i386_linux_xmlfiles): Remove
2035 i386/i386-XXX-linux.xml from it.
2036
2037 2017-09-05 Yao Qi <yao.qi@linaro.org>
2038
2039 * configure.srv: Set srv_i386_linux_regobj empty if $development
2040 is false.
2041 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2042 initialize_low_tdesc.
2043 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2044 with #if initialize_low_tdesc.
2045 * linux-x86-tdesc-selftest.c: New file.
2046 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2047
2048 2017-09-05 Yao Qi <yao.qi@linaro.org>
2049
2050 * Makefile.in (arch-i386.o): New rule.
2051 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2052 (x86_64-*-linux*): Likewise.
2053 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2054 include arch/i386.h.
2055 (i386_linux_read_description): Remove code and call
2056 i386_create_target_description.
2057 * tdesc.c (allocate_target_description): New function.
2058 * tdesc.h (set_tdesc_architecture): Remove declaration.
2059 (set_tdesc_osabi): Likewise.
2060
2061 2017-09-05 Yao Qi <yao.qi@linaro.org>
2062
2063 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2064 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2065 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2066 .xmltarget.
2067 * server.c (get_features_xml): Call tdesc_get_features_xml.
2068 * tdesc.c (set_tdesc_architecture): New function.
2069 (set_tdesc_osabi): New function.
2070 (tdesc_get_features_xml): New function.
2071 (tdesc_create_feature): Add an argument.
2072 * tdesc.h (struct target_desc) <features>: New field.
2073 <arch, osabi>: New field.
2074 (~target_desc): xfree features, arch, and osabi.
2075 (target_desc::oerator==): Don't compare .xmltarget.
2076 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2077 (set_tdesc_osabi): Likewise.
2078 (tdesc_get_features_xml): Likewise.
2079
2080 2017-09-05 Yao Qi <yao.qi@linaro.org>
2081
2082 * linux-x86-tdesc.c: Include selftest.h.
2083 (i386_tdesc_test): New function.
2084 (initialize_low_tdesc): Call selftests::register_test.
2085 * tdesc.h: Include regdef.h.
2086 (target_desc): Override operator == and !=.
2087
2088 2017-09-05 Yao Qi <yao.qi@linaro.org>
2089
2090 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2091 (ipa_obj): Likewise.
2092 * linux-i386-ipa.c: Include common/x86-xstate.h
2093 (get_ipa_tdesc): Call i386_linux_read_description.
2094 (initialize_low_tracepoint): Don't call init_registers_XXX
2095 functions, call initialize_low_tdesc instead.
2096 * linux-x86-low.c (x86_linux_read_description): Call
2097 i386_linux_read_description.
2098 (initialize_low_arch): Don't call init_registers_i386_XXX
2099 functions, call initialize_low_tdesc.
2100 * linux-x86-tdesc.c: New file.
2101 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2102 (i386_get_ipa_tdesc_idx): Declare.
2103 (i386_get_ipa_tdesc): Declare.
2104 (initialize_low_tdesc): Declare.
2105
2106 2017-09-05 Yao Qi <yao.qi@linaro.org>
2107
2108 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2109 instead of 0.
2110
2111 2017-09-05 Yao Qi <yao.qi@linaro.org>
2112
2113 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2114 * regcache.c (get_thread_regcache): Use VEC_length.
2115 (init_register_cache): Likewise.
2116 (regcache_cpy): Likewise.
2117 (registers_to_string): Iterate reg_defs via VEC_iterate.
2118 (find_regno): Likewise.
2119 (find_register_by_number): Use VEC_index.
2120 (register_size): Call find_register_by_number.
2121 (register_data): Call find_register_by_number.
2122 (supply_regblock): Use VEC_length.
2123 (regcache_raw_read_unsigned): Likewise.
2124 * tdesc.c (init_target_desc): Iterate reg_defs via
2125 VEC_iterate.
2126 (default_description): Update initializer.
2127 (copy_target_description): Don't update field num_registers.
2128 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2129 <num_registers>: Remove.
2130
2131 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2132
2133 * Makefile.in (.SECONDARY): Define target.
2134
2135 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2136
2137 * linux-low.c (linux_wait_1): Adjust.
2138 * server.c (queue_stop_reply_callback): Adjust.
2139
2140 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2141
2142 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2143 QEnvironmentUnset and QEnvironmentReset packets.
2144 (handle_query): Inform remote that QEnvironmentHexEncoded,
2145 QEnvironmentUnset and QEnvironmentReset are supported.
2146
2147 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2148
2149 * inferiors.h (inferior_target_data): Rename to ...
2150 (thread_target_data): ... this.
2151 (inferior_regcache_data): Rename to ...
2152 (thread_regcache_data): ... this.
2153 (set_inferior_regcache_data): Rename to ...
2154 (set_thread_regcache_data): ... this.
2155 * inferiors.c (inferior_target_data): Rename to ...
2156 (thread_target_data): ... this.
2157 (inferior_regcache_data): Rename to ...
2158 (thread_regcache_data): ... this.
2159 (set_inferior_regcache_data): Rename to ...
2160 (set_thread_regcache_data): ... this.
2161 (free_one_thread): Update.
2162 * linux-low.h (get_thread_lwp): Update.
2163 * regcache.c (get_thread_regcache): Update.
2164 (regcache_invalidate_thread): Update.
2165 (free_register_cache_thread): Update.
2166 * win32-i386-low.c (update_debug_registers_callback): Update.
2167 (win32_get_current_dr): Update.
2168 * win32-low.c (thread_rec): Update.
2169 (delete_thread_info): Update.
2170 (continue_one_thread): Update.
2171 (suspend_one_thread): Update.
2172
2173 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2174
2175 * inferiors.c (set_inferior_target_data): Remove.
2176 * inferiors.h (set_inferior_target_data): Remove.
2177
2178 2017-08-18 Yao Qi <yao.qi@linaro.org>
2179
2180 * Makefile.in (OBS): Add selftest.o.
2181 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2182 * configure, config.in: Re-generated.
2183 * server.c: Include common/sefltest.h.
2184 (captured_main): Handle option --selftest.
2185
2186 2017-08-09 Yao Qi <yao.qi@linaro.org>
2187
2188 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2189 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2190 i386-avx-mpx.o and i386-mmx.o.
2191 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2192 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2193 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2194 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2195 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2196 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2197 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2198 i386/amd64-avx-mpx.xml.
2199
2200 2017-08-09 Yao Qi <yao.qi@linaro.org>
2201
2202 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2203 and x32-avx-avx512.o.
2204 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2205 i386/x32-avx-avx512.xml.
2206
2207 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2208
2209 * tracepoint.h (enum class fast_tpoint_collect_result): New
2210 enumeration.
2211 (fast_tracepoint_collecting): Change return type to
2212 fast_tpoint_collect_result.
2213 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2214 * linux-low.h: Include tracepoint.h.
2215 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2216 fast_tpoint_collect_result.
2217 * linux-low.c (handle_tracepoints): Adjust.
2218 (linux_fast_tracepoint_collecting): Change return type to
2219 fast_tpoint_collect_result.
2220 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2221 linux_wait_1, stuck_in_jump_pad_callback,
2222 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2223 proceed_one_lwp): Adjust to type change.
2224
2225 2017-07-10 Yao Qi <yao.qi@linaro.org>
2226
2227 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2228
2229 2017-06-29 Yao Qi <yao.qi@linaro.org>
2230
2231 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2232 Remove.
2233 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2234
2235 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2236
2237 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2238
2239 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2240
2241 * linux-low.c (linux_create_inferior): Adjust code to access the
2242 environment information via 'gdb_environ' class.
2243 * lynx-low.c (lynx_create_inferior): Likewise.
2244 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2245 (get_environ): Return a pointer to 'our_environ'.
2246 (captured_main): Initialize 'our_environ'.
2247 * server.h (get_environ): Adjust prototype.
2248 * spu-low.c (spu_create_inferior): Adjust code to access the
2249 environment information via 'gdb_environ' class.
2250
2251 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2252
2253 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2254 usage of "register" keyword.
2255
2256 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2257
2258 * configure: Re-generate.
2259
2260 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2261
2262 * configure: Re-generate.
2263
2264 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2265
2266 * Makefile.in (COMPILE.pre): Add "-x c++".
2267
2268 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2269
2270 * fork-child.c: Conditionally include <signal.h>.
2271
2272 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2273
2274 * server.c (handle_general_set): Handle new packet
2275 "QStartupWithShell".
2276 (handle_query): Add "QStartupWithShell" to the list of supported
2277 packets.
2278 (gdbserver_usage): Add help text explaining the
2279 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2280 options.
2281 (captured_main): Recognize and act upon the presence of the new
2282 CLI options.
2283
2284 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2285 Pedro Alves <palves@redhat.com>
2286
2287 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2288 * configure: Regenerate.
2289 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2290 "fork-inferior.o".
2291 (i[34567]86-*-lynxos*): Likewise.
2292 (spu*-*-*): Likewise.
2293 * fork-child.c: New file.
2294 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2295 and "environ.h".
2296 (linux_ptrace_fun): New function.
2297 (linux_create_inferior): Adjust function prototype to reflect
2298 change on "target.h". Adjust function code to use
2299 "fork_inferior".
2300 (linux_request_interrupt): Delete "signal_pid".
2301 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2302 (lynx_ptrace_fun): New function.
2303 (lynx_create_inferior): Adjust function prototype to reflect
2304 change on "target.h". Adjust function code to use
2305 "fork_inferior".
2306 * nto-low.c (nto_create_inferior): Adjust function prototype and
2307 code to reflect change on "target.h". Update comments.
2308 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2309 "common-terminal.h" and "environ.h".
2310 (terminal_fd): Moved to fork-child.c.
2311 (old_foreground_pgrp): Likewise.
2312 (restore_old_foreground_pgrp): Likewise.
2313 (last_status): Make it global.
2314 (last_ptid): Likewise.
2315 (our_environ): New variable.
2316 (startup_with_shell): Likewise.
2317 (program_name): Likewise.
2318 (program_argv): Rename to...
2319 (program_args): ...this.
2320 (wrapper_argv): New variable.
2321 (start_inferior): Delete function.
2322 (get_exec_wrapper): New function.
2323 (get_exec_file): Likewise.
2324 (get_environ): Likewise.
2325 (prefork_hook): Likewise.
2326 (post_fork_inferior): Likewise.
2327 (postfork_hook): Likewise.
2328 (postfork_child_hook): Likewise.
2329 (handle_v_run): Update code to deal with arguments coming from the
2330 remote host. Update calls from "start_inferior" to
2331 "create_inferior".
2332 (captured_main): Likewise. Initialize environment variable. Call
2333 "have_job_control".
2334 * server.h (post_fork_inferior): New prototype.
2335 (get_environ): Likewise.
2336 (last_status): Declare.
2337 (last_ptid): Likewise.
2338 (signal_pid): Likewise.
2339 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2340 (spu_ptrace_fun): New function.
2341 (spu_create_inferior): Adjust function prototype to reflect change
2342 on "target.h". Adjust function code to use "fork_inferior".
2343 * target.c (target_terminal_init): New function.
2344 (target_terminal_inferior): Likewise.
2345 (target_terminal_ours): Likewise.
2346 * target.h: Include <vector>.
2347 (struct target_ops) <create_inferior>: Update prototype.
2348 (create_inferior): Update macro.
2349 * utils.c (gdb_flush_out_err): New function.
2350 * win32-low.c (win32_create_inferior): Adjust function prototype
2351 and code to reflect change on "target.h".
2352
2353 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2354
2355 * inferiors.c (switch_to_thread): New function.
2356
2357 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2358
2359 * Makefile.in (SFILE): Add "common/job-control.c".
2360 (OBS): Add "job-control.o".
2361
2362 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2363
2364 * Makefile: Remove "@host_makefile_frag@".
2365
2366 2017-05-05 Pedro Alves <palves@redhat.com>
2367
2368 * configure: Regenerate.
2369
2370 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2371
2372 * configure: Regenerate.
2373
2374 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2375
2376 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2377 software_single_step change of return type to
2378 std::vector<CORE_ADDR>.
2379 * linux-low.c (install_software_single_step_breakpoints):
2380 Likewise.
2381 * linux-low.h (install_software_single_step_breakpoints):
2382 Likewise.
2383
2384 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2385
2386 * remote-utils.c: Include "gdb_termios.h" instead of
2387 "terminal.h".
2388 * terminal.h: Delete file.
2389
2390 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2391
2392 * server.c: Include <vector>.
2393 <program_argv, wrapper_argv>: Convert to std::vector.
2394 (start_inferior): Rewrite function to use C++.
2395 (handle_v_run): Likewise. Update code that calculates the argv
2396 based on the vRun packet; use C++.
2397 (captured_main): Likewise.
2398
2399 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2400
2401 * server.c (handle_v_cont): Initialize thread_resume::thread
2402 with null_ptid.
2403
2404 2017-04-05 Pedro Alves <palves@redhat.com>
2405
2406 * configure: Regenerate.
2407
2408 2017-04-05 Pedro Alves <palves@redhat.com>
2409
2410 * gdbreplay.c (sync_error): Constify.
2411 * linux-x86-low.c (push_opcode): Constify.
2412
2413 2017-04-05 Pedro Alves <palves@redhat.com>
2414
2415 * win32-low.c (get_child_debug_event)
2416 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2417 Report TARGET_WAITKIND_SPURIOUS instead.
2418
2419 2017-04-05 Pedro Alves <palves@redhat.com>
2420
2421 * remote-utils.c (remote_prepare, remote_open): Constify.
2422 * remote-utils.h (remote_prepare, remote_open): Constify.
2423 * server.c (captured_main): Constify 'port' handling.
2424
2425 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2426
2427 * Makefile.in (clean): Clear .deps.
2428
2429 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2430
2431 * .gitignore: Remove generated files, replace with wildcard.
2432 * (clean): Replace removal of generated files with wildcard.
2433 (version.c): Replace with...
2434 (version-generated.c): ...this.
2435 (xml-builtin.c): Replace with...
2436 (xml-builtin-generated.c): ...this.
2437 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2438 (%.c: *regformats*): Replace with...
2439 (%-generated.c: *regformats*): ...this.
2440
2441 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2442
2443 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2444 (xtensa_fill_gregset): Call collect_register_by_name for
2445 threadptr register.
2446 (xtensa_store_gregset): Call supply_register_by_name for
2447 threadptr register.
2448
2449 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2450
2451 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2452 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2453 (xtensa_store_gregset): Call supply_register for all registers in
2454 a0_regnum..a0_regnum + C0_NREGS range.
2455
2456 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2457
2458 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2459 (ax-ipa.o: ax.c): Remove.
2460 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2461 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2462 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2463 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2464 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2465
2466 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2467
2468 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2469 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2470 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2471 (errors-ipa.o: ../common/errors.c): Remove.
2472 (format-ipa.o: ../common/format.c): Remove.
2473 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2474
2475 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2476
2477 * Makefile.in (%-ipa.o: %.c): New rule.
2478 (tracepoint-ipa.o: tracepoint.c): Remove.
2479 (utils-ipa.o: utils.c): Remove.
2480 (remote-utils-ipa.o: remote-utils.c): Remove.
2481 (regcache-ipa.o: regcache.c): Remove.
2482 (i386-linux-ipa.o: i386-linux.c): Remove.
2483 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2484 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2485 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2486 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2487 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2488 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2489 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2490 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2491 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2492 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2493 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2494 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2495 (aarch64-ipa.o: aarch64.c): Remove.
2496 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2497 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2498 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2499 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2500 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2501 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2502 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2503 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2504 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2505 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2506 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2507 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2508 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2509 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2510 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2511 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2512 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2513 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2514 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2515 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2516 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2517 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2518 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2519 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2520 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2521 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2522 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2523 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2524 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2525 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2526 (tdesc-ipa.o: tdesc.c): Remove.
2527 (x32-linux-ipa.o: x32-linux.c): Remove.
2528 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2529 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2530
2531 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2532
2533 * Makefile.in (%.o: ../arch/%.c): New rule.
2534 (arm.o: ../arch/arm.c): Remove.
2535 (arm-linux.o: ../arch/arm-linux.c): Remove.
2536 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2537 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2538
2539 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2540
2541 * Makefile.in (%.o: ../nat/%.c): New rule.
2542 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2543 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2544 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2545 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2546 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2547 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2548 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2549 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2550 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2551 (linux-personality.o: ../nat/linux-personality.c): Remove.
2552 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2553 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2554 (x86-linux.o: ../nat/x86-linux.c): Remove.
2555 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2556 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2557
2558 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2559
2560 * Makefile.in (%.o: ../common/%.c): New rule.
2561 (signals.o: ../common/signals.c): Remove.
2562 (print-utils.o: ../common/print-utils.c): Remove.
2563 (rsp-low.o: ../common/rsp-low.c): Remove.
2564 (common-utils.o: ../common/common-utils.c): Remove.
2565 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2566 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2567 (vec.o: ../common/vec.c): Remove.
2568 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2569 (xml-utils.o: ../common/xml-utils.c): Remove.
2570 (ptid.o: ../common/ptid.c): Remove.
2571 (buffer.o: ../common/buffer.c): Remove.
2572 (format.o: ../common/format.c): Remove.
2573 (filestuff.o: ../common/filestuff.c): Remove.
2574 (agent.o: ../common/agent.c): Remove.
2575 (errors.o: ../common/errors.c): Remove.
2576 (environ.o: ../common/environ.c): Remove.
2577 (common-debug.o: ../common/common-debug.c): Remove.
2578 (cleanups.o: ../common/cleanups.c): Remove.
2579 (common-exceptions.o: ../common/common-exceptions.c): Remove.
2580 (fileio.o: ../common/fileio.c): Remove.
2581 (common-regcache.o: ../common/common-regcache.c): Remove.
2582 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
2583 (new-op.o: ../common/new-op.c): Remove.
2584 (btrace-common.o: ../common/btrace-common.c): Remove.
2585
2586 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2587
2588 * Makefile.in (%.o: ../target/%.c): New rule.
2589 (waitstatus.o: ../target/waitstatus.c): Remove.
2590
2591 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2592
2593 * Makefile.in
2594 (%.c: ../regformats/%.dat,
2595 (%.c: ../regformats/arm/%.dat,
2596 (%.c: ../regformats/i386/%.dat,
2597 (%.c: ../regformats/rs6000/%.dat): New rules.
2598 (aarch64.c): Remove.
2599 (reg-arm.c): Remove.
2600 (arm-with-iwmmxt.c): Remove.
2601 (arm-with-vfpv2.c): Remove.
2602 (arm-with-vfpv3.c): Remove.
2603 (arm-with-neon.c): Remove.
2604 (reg-bfin.c): Remove.
2605 (reg-cris.c): Remove.
2606 (reg-crisv32.c): Remove.
2607 (i386.c): Remove.
2608 (i386-linux.c): Remove.
2609 (i386-avx.c): Remove.
2610 (i386-avx-linux.c): Remove.
2611 (i386-avx-avx512.c): Remove.
2612 (i386-avx-avx512-linux.c): Remove.
2613 (i386-mpx.c): Remove.
2614 (i386-mpx-linux.c): Remove.
2615 (i386-avx-mpx-avx512-pku.c): Remove.
2616 (i386-avx-mpx-avx512-pku-linux.c): Remove.
2617 (i386-avx-mpx.c): Remove.
2618 (i386-avx-mpx-linux.c): Remove.
2619 (i386-mmx.c): Remove.
2620 (i386-mmx-linux.c): Remove.
2621 (reg-ia64.c): Remove.
2622 (reg-m32r.c): Remove.
2623 (reg-m68k.c): Remove.
2624 (reg-cf.c): Remove.
2625 (mips-linux.c): Remove.
2626 (mips-dsp-linux.c): Remove.
2627 (mips64-linux.c): Remove.
2628 (mips64-dsp-linux.c): Remove.
2629 (nios2-linux.c): Remove.
2630 (powerpc-32.c): Remove.
2631 (powerpc-32l.c): Remove.
2632 (powerpc-altivec32l.c): Remove.
2633 (powerpc-cell32l.c): Remove.
2634 (powerpc-vsx32l.c): Remove.
2635 (powerpc-isa205-32l.c): Remove.
2636 (powerpc-isa205-altivec32l.c): Remove.
2637 (powerpc-isa205-vsx32l.c): Remove.
2638 (powerpc-e500l.c): Remove.
2639 (powerpc-64l.c): Remove.
2640 (powerpc-altivec64l.c): Remove.
2641 (powerpc-cell64l.c): Remove.
2642 (powerpc-vsx64l.c): Remove.
2643 (powerpc-isa205-64l.c): Remove.
2644 (powerpc-isa205-altivec64l.c): Remove.
2645 (powerpc-isa205-vsx64l.c): Remove.
2646 (s390-linux32.c): Remove.
2647 (s390-linux32v1.c): Remove.
2648 (s390-linux32v2.c): Remove.
2649 (s390-linux64.c): Remove.
2650 (s390-linux64v1.c): Remove.
2651 (s390-linux64v2.c): Remove.
2652 (s390-te-linux64.c): Remove.
2653 (s390-vx-linux64.c): Remove.
2654 (s390-tevx-linux64.c): Remove.
2655 (s390x-linux64.c): Remove.
2656 (s390x-linux64v1.c): Remove.
2657 (s390x-linux64v2.c): Remove.
2658 (s390x-te-linux64.c): Remove.
2659 (s390x-vx-linux64.c): Remove.
2660 (s390x-tevx-linux64.c): Remove.
2661 (tic6x-c64xp-linux.c): Remove.
2662 (tic6x-c64x-linux.c): Remove.
2663 (tic6x-c62x-linux.c): Remove.
2664 (reg-sh.c): Remove.
2665 (reg-sparc64.c): Remove.
2666 (reg-spu.c): Remove.
2667 (amd64.c): Remove.
2668 (amd64-linux.c): Remove.
2669 (amd64-avx.c): Remove.
2670 (amd64-avx-linux.c): Remove.
2671 (amd64-avx-avx512.c): Remove.
2672 (amd64-avx-avx512-linux.c): Remove.
2673 (amd64-mpx.c): Remove.
2674 (amd64-mpx-linux.c): Remove.
2675 (amd64-avx-mpx-avx512-pku.c): Remove.
2676 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
2677 (amd64-avx-mpx.c): Remove.
2678 (amd64-avx-mpx-linux.c): Remove.
2679 (x32.c): Remove.
2680 (x32-linux.c): Remove.
2681 (x32-avx.c): Remove.
2682 (x32-avx-linux.c): Remove.
2683 (x32-avx-avx512.c): Remove.
2684 (x32-avx-avx512-linux.c): Remove.
2685 (reg-xtensa.c): Remove.
2686 (reg-tilegx.c): Remove.
2687 (reg-tilegx32.c): Remove.
2688
2689 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
2690
2691 * Makefile.in (SFILES): Add "common/environ.c".
2692 (OBJS): Add "common/environ.h".
2693
2694 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
2695
2696 * configure.ac: Check if the fs_base and gs_base members of
2697 `struct user_regs_struct' exist.
2698 * config.in: Regenerated.
2699 * configure: Likewise.
2700
2701 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
2702
2703 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
2704 target_read_memory.
2705 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
2706 (get_next_pcs_syscall_next_pc): Likewise.
2707
2708 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
2709
2710 * win32-i386-low.c: Fix incorrect reference to a couple source files.
2711 * nto-x86-low.c: Likewise.
2712
2713 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
2714
2715 * Makefile.in: Include disable-implicit-rules.mk.
2716
2717 2016-11-23 Pedro Alves <palves@redhat.com>
2718
2719 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
2720 (debug_vprintf): Use std::chrono::steady_clock instead of
2721 gettimeofday. Use '.' instead of ':'.
2722 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
2723 (get_timestamp): Use std::chrono::steady_clock instead of
2724 gettimeofday.
2725
2726 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2727
2728 * Makefile.in: Fix whitespace formatting.
2729
2730 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2731
2732 * Makefile.in (SFILES, OBS): Flatten list and order
2733 alphabetically.
2734
2735 2016-11-23 Pedro Alves <palves@redhat.com>
2736
2737 * event-loop.c (handle_file_event): Use warning.
2738 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
2739 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2740 Use warning.
2741
2742 2016-11-23 Pedro Alves <palves@redhat.com>
2743
2744 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
2745 output.
2746 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
2747 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
2748 debug_printf and debug_flush for debug output.
2749 * server.c (handle_general_set): Likewise.
2750 * thread-db.c (try_thread_db_load): Use debug_printf for debug
2751 output.
2752
2753 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2754
2755 * Makefile.in (.c.o): Replace rule with ...
2756 (%.o: %.c): ... this one.
2757
2758 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2759
2760 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
2761 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
2762 make.
2763 * configure.ac: Remove checks for the make program.
2764 * configure: Re-generate.
2765
2766 2016-10-28 Pedro Alves <palves@redhat.com>
2767
2768 * Makefile.in (CXX_DIALECT): Get from configure.
2769 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
2770 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
2771 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
2772 * config.in: Regenerate.
2773 * configure: Regenerate.
2774
2775 2016-10-27 Yao Qi <yao.qi@linaro.org>
2776
2777 * linux-low.c (linux_supports_range_stepping): Return true if
2778 can_software_single_step return true.
2779
2780 2016-10-27 Yao Qi <yao.qi@linaro.org>
2781
2782 * inferiors.c (find_inferior_in_random): New function.
2783 * inferiors.h (find_inferior_in_random): Declare.
2784 * linux-low.c (linux_wait_for_event_filtered): Call
2785 find_inferior_in_random instead of find_inferior.
2786
2787 2016-10-27 Yao Qi <yao.qi@linaro.org>
2788
2789 * linux-low.c (linux_wait_1): If single-step breakpoints are
2790 inserted, remove them.
2791
2792 2016-10-26 Pedro Alves <palves@redhat.com>
2793
2794 * linux-low.c (handle_extended_wait): Link parent/child fork
2795 threads.
2796 (linux_wait_1): Unlink them.
2797 (linux_set_resume_request): Ignore resume requests for
2798 already-resumed and unhandled fork child threads.
2799 * linux-low.h (struct lwp_info) <fork_relative>: New field.
2800 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
2801 New functions.
2802 (handle_v_requests) <vCont>: Don't call require_running.
2803 * server.h (in_queued_stop_replies): New declaration.
2804
2805 2016-10-24 Yao Qi <yao.qi@linaro.org>
2806
2807 PR server/20733
2808 * linux-aarch64-low.c (append_insns): Cast the return value to
2809 'uint32_t *'.
2810
2811 2016-10-10 Yao Qi <yao.qi@linaro.org>
2812
2813 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
2814
2815 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
2816
2817 * target.c (target_supports_multi_process): New function, moved
2818 from...
2819 * target.h (target_supports_multi_process): ... here. Remove
2820 macro.
2821
2822 2016-10-05 Tom Tromey <tom@tromey.com>
2823
2824 PR remote/20655:
2825 * tracepoint.c (handle_tracepoint_bkpts): Check
2826 ipa_error_tracepoint, not ipa_stopping_tracepoint.
2827
2828 2016-10-05 Yao Qi <yao.qi@linaro.org>
2829
2830 * configure.srv: Update the path of arm-*.xml files.
2831
2832 2016-10-05 Terry Guo <terry.guo@arm.com>
2833 Yao Qi <yao.qi@linaro.org>
2834
2835 * Makefile.in: Adjust the path of rules.
2836 * configure.srv: Update the path of xml files.
2837 * regformats/arm-with-iwmmxt.dat: Regenerated.
2838 * regformats/arm-with-neon.dat: Likewise.
2839 * regformats/arm-with-vfpv2.dat: Likewise.
2840 * regformats/arm-with-vfpv3.dat Likewise.
2841
2842 2016-09-30 Yao Qi <yao.qi@linaro.org>
2843
2844 PR gdbserver/20627
2845 * target.c (target_stop_and_wait): Don't call
2846 target_continue_no_signal, use resume_stop instead.
2847
2848 2016-09-26 Yao Qi <yao.qi@linaro.org>
2849
2850 * linux-low.c (linux_wait_1): Call debug_exit.
2851
2852 2016-09-23 Pedro Alves <palves@redhat.com>
2853
2854 * Makefile.in (SFILES): Add common/new-op.c.
2855 (OBS): Add common/new-op.o.
2856 (new-op.o): New rule.
2857
2858 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
2859
2860 * .gitinore: Ignore more files.
2861
2862 2016-09-21 Yao Qi <yao.qi@linaro.org>
2863
2864 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
2865 23.
2866
2867 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
2868
2869 * server.c (start_inferior): Call target_mourn_inferior instead of
2870 mourn_inferior; pass ptid_t argument to it.
2871 (resume): Likewise.
2872 (handle_target_event): Likewise.
2873 * target.c (target_mourn_inferior): New function.
2874 * target.h (mourn_inferior): Delete macro.
2875
2876 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
2877
2878 * linux-low.c (lwp_is_stepping): New function.
2879
2880 2016-09-06 Carl Love <cel@us.ibm.com>
2881
2882 * server.c (start_inferior): Fixed comment, requested comment change
2883 didn't get updated correctly. Removed reference to ptrace () call as
2884 it is only true on Linux systems.
2885
2886 2016-09-06 Carl Love <cel@us.ibm.com>
2887
2888 * server.c (start_inferior): Do not call
2889 function target_post_create_inferior () if the
2890 inferior process has already exited.
2891
2892 2016-09-05 Pedro Alves <palves@redhat.com>
2893
2894 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
2895 (COMPILE.pre, CC_LD): Use CXX directly.
2896 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
2897 * acinclude.m4: Don't include build-with-cxx.m4.
2898 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
2899 * configure: Regenerate.
2900
2901 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
2902
2903 PR gdb/19495
2904 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
2905 call writing data to own_buf.
2906
2907 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2908
2909 * target.c (mywait): Call target_wait instead of
2910 the_target->wait.
2911 (target_wait): New function.
2912
2913 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2914
2915 * server.c (start_inferior): New variable 'ptid'. Replace calls
2916 to the_target->resume by target_continue{,_no_signal}, depending
2917 on the case.
2918 * target.c (target_stop_and_wait): Call target_continue_no_signal
2919 instead of the_target->resume.
2920 (target_continue): New function.
2921
2922 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
2923
2924 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
2925
2926 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
2927
2928 PR server/20491
2929 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
2930 ps_prochandle.
2931 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
2932 * linux-arm-low.c (ps_get_thread_area): Likewise.
2933 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
2934 * linux-m68k-low.c (ps_get_thread_area): Likewise.
2935 * linux-mips-low.c (ps_get_thread_area): Likewise.
2936 * linux-nios2-low.c (ps_get_thread_area): Likewise.
2937 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
2938 * linux-x86-low.c (ps_get_thread_area): Likewise.
2939 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
2940
2941 2016-08-19 Pedro Alves <palves@redhat.com>
2942
2943 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
2944
2945 2016-08-19 Pedro Alves <palves@redhat.com>
2946
2947 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
2948 comment. Use memcpy instead of casting through unsigned long.
2949
2950 2016-08-19 Pedro Alves <palves@redhat.com>
2951
2952 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
2953 allocating around 0x80000000.
2954
2955 2016-08-19 Pedro Alves <palves@redhat.com>
2956
2957 PR gdb/20415
2958 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
2959 (x32-avx512-linux-ipa.o): New rules.
2960 * configure.ac (x86_64-*-linux*): New x32 check.
2961 * configure.srv (ipa_x32_linux_regobj): New.
2962 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
2963 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
2964 descriptions.
2965 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
2966 descriptions.
2967 * configure: Regenerate.
2968
2969 2016-08-09 Pedro Alves <palves@redhat.com>
2970
2971 PR gdb/18653
2972 * Makefile.in (OBS): Add signals-state-save-restore.o.
2973 (signals-state-save-restore.o): New rule.
2974 * config.in: Regenerate.
2975 * configure: Regenerate.
2976 * linux-low.c: Include "signals-state-save-restore.h".
2977 (linux_create_inferior): Call
2978 restore_original_signals_state.
2979 * server.c: Include "dispositions-save-restore.h".
2980 (captured_main): Call save_original_signals_state.
2981
2982 2016-08-05 Pedro Alves <palves@redhat.com>
2983
2984 * configure: Regenerate.
2985
2986 2016-08-04 Yao Qi <yao.qi@linaro.org>
2987
2988 * linux-low.c (regsets_fetch_inferior_registers): Check
2989 errno is ESRCH or not.
2990
2991 2016-08-02 Yao Qi <yao.qi@linaro.org>
2992
2993 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
2994 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
2995 (thread_db_load_search): Update.
2996 (try_thread_db_load_1): Don't look for td_ta_event_addr,
2997 td_ta_set_event and td_ta_event_getmsg.
2998
2999 2016-07-26 Pedro Alves <palves@redhat.com>
3000
3001 PR server/20414
3002 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3003 of unsigned long for 64-bit registers and use uint32_t instead of
3004 unsigned int for 32-bit registers.
3005
3006 2016-07-26 Pedro Alves <palves@redhat.com>
3007
3008 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3009 to 'ptrace'.
3010
3011 2016-07-21 Tom Tromey <tom@tromey.com>
3012
3013 * configure: Rebuild.
3014
3015 2016-07-21 Yao Qi <yao.qi@linaro.org>
3016
3017 * mem-break.c (find_gdb_breakpoint): Cast bp to
3018 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3019
3020 2016-07-21 Yao Qi <yao.qi@linaro.org>
3021
3022 * server.c (handle_v_requests): Support s and S actions
3023 if target_supports_software_single_step return true.
3024
3025 2016-07-21 Yao Qi <yao.qi@linaro.org>
3026
3027 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3028 is resume_step, call maybe_hw_step.
3029 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3030 and unstop them.
3031 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3032 breakpoints or not.
3033 (proceed_one_lwp): If resume request is resume_step, install
3034 reinsert breakpoints and call maybe_hw_step.
3035
3036 2016-07-21 Yao Qi <yao.qi@linaro.org>
3037
3038 * linux-low.c (proceed_one_lwp): Declare.
3039 (linux_resume_one_thread): Remove local variable 'step'.
3040 Lift code enqueue signal. Call proceed_one_lwp instead of
3041 linux_resume_one_lwp.
3042
3043 2016-07-21 Yao Qi <yao.qi@linaro.org>
3044
3045 * linux-low.c (linux_resume_one_thread): Call
3046 enqueue_pending_signal.
3047
3048 2016-07-21 Yao Qi <yao.qi@linaro.org>
3049
3050 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3051 * inferiors.c (do_restore_current_thread_cleanup): New function.
3052 (make_cleanup_restore_current_thread): Likewise.
3053 * linux-low.c (install_software_single_step_breakpoints): Call
3054 make_cleanup_restore_current_thread. Switch current_thread to
3055 thread.
3056
3057 2016-07-21 Yao Qi <yao.qi@linaro.org>
3058
3059 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3060 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3061 (clone_one_breakpoint): Likewise.
3062 (delete_reinsert_breakpoints): Change parameter to thread.
3063 Callers updated.
3064 (has_reinsert_breakpoints): Likewise.
3065 (uninsert_reinsert_breakpoints): Likewise.
3066 (reinsert_reinsert_breakpoints): Likewise.
3067 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3068 (delete_reinsert_breakpoints): Likewise.
3069 (reinsert_reinsert_breakpoints): Likewise.
3070 (uninsert_reinsert_breakpoints): Likewise.
3071 (has_reinsert_breakpoints): Likewise.
3072
3073 2016-07-21 Yao Qi <yao.qi@linaro.org>
3074
3075 * inferiors.c (get_thread_process): Make parameter const.
3076 * inferiors.h (get_thread_process): Update declaration.
3077 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3078 Add new parameters child_thread and parent_thread. Callers
3079 updated.
3080 * mem-break.h (clone_all_breakpoints): Update declaration.
3081
3082 2016-07-21 Yao Qi <yao.qi@linaro.org>
3083
3084 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3085 <command_list, handler>: Remove.
3086 (struct gdb_breakpoint): New.
3087 (struct other_breakpoint): New.
3088 (struct reinsert_breakpoint): New.
3089 (is_gdb_breakpoint): New function.
3090 (any_persistent_commands): Update command_list if
3091 is_gdb_breakpoint returns true.
3092 (set_breakpoint): Create breakpoints according to their types.
3093 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3094 (set_gdb_breakpoint_1): Likewise.
3095 (set_gdb_breakpoint): Likewise.
3096 (clear_breakpoint_conditions): Change parameter type to
3097 'struct gdb_breakpoint *'.
3098 (clear_breakpoint_commands): Likewise.
3099 (clear_breakpoint_conditions_and_commands): Likewise.
3100 (add_condition_to_breakpoint): Likewise.
3101 (add_breakpoint_condition): Likewise.
3102 (add_commands_to_breakpoint): Likewise.
3103 (check_breakpoints): Check other_breakpoint.
3104 (clone_one_breakpoint): Clone breakpopint according to its type.
3105 * mem-break.h (struct gdb_breakpoint): Declare.
3106 (set_gdb_breakpoint): Update declaration.
3107 (clear_breakpoint_conditions_and_commands): Likewise.
3108 (add_breakpoint_condition): Likewise.
3109 (add_breakpoint_commands): Likewise.
3110 * server.c (process_point_options): Change parameter type to
3111 'struct gdb_breakpoint *'.
3112
3113 2016-07-21 Yao Qi <yao.qi@linaro.org>
3114
3115 * mem-break.c (set_breakpoint_at): Rename it to ...
3116 (set_breakpoint_type_at): ... it.
3117 (set_breakpoint_at): Call set_breakpoint_type_at.
3118 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3119 * mem-break.h (set_breakpoint_at): Update comments.
3120
3121 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3122
3123 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3124 to buf parameter.
3125 (nios2_store_gregset): Likewise.
3126
3127 2016-07-01 Pedro Alves <palves@redhat.com>
3128 Antoine Tremblay <antoine.tremblay@ericsson.com>
3129
3130 * linux-low.c: Change interface to take the target lwp_info
3131 pointer directly and return void. Handle detaching from a zombie
3132 thread.
3133 (linux_detach_lwp_callback): New function.
3134 (linux_detach): Detach from the leader thread after detaching from
3135 the clone threads.
3136
3137 2016-06-28 Yao Qi <yao.qi@linaro.org>
3138
3139 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3140 for variable new_offset.
3141 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3142 (aarch64_ftrace_insn_reloc_cb): Likewise.
3143 (aarch64_ftrace_insn_reloc_tb): Likewise.
3144 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3145 PRIx64 instead of PRIx32.
3146
3147 2016-06-28 Yao Qi <yao.qi@linaro.org>
3148
3149 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3150 (the_low_target): Install arm_get_syscall_trapinfo.
3151
3152 2016-06-28 Yao Qi <yao.qi@linaro.org>
3153
3154 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3155 function.
3156 (the_low_target): Install aarch64_get_syscall_trapinfo.
3157
3158 2016-06-28 Yao Qi <yao.qi@linaro.org>
3159
3160 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3161 Callers updated.
3162 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3163 Remove parameter sysno.
3164 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3165 sysret.
3166
3167 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3168
3169 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3170 (s390_emit_ne_goto): Likewise.
3171 (s390_emit_lt_goto): Likewise.
3172 (s390_emit_le_goto): Likewise.
3173 (s390_emit_gt_goto): Likewise.
3174 (s390_emit_ge_goto): Likewise.
3175 (s390x_emit_eq_goto): Likewise.
3176 (s390x_emit_ne_goto): Likewise.
3177 (s390x_emit_lt_goto): Likewise.
3178 (s390x_emit_le_goto): Likewise.
3179 (s390x_emit_gt_goto): Likewise.
3180 (s390x_emit_ge_goto): Likewise.
3181 (s390_emit_ops_impl): Mark variable static.
3182 (s390x_emit_ops): Likewise.
3183
3184 2016-06-17 Yao Qi <yao.qi@linaro.org>
3185
3186 * linux-low.c (handle_extended_wait): Call
3187 uninsert_reinsert_breakpoints for the parent process. Remove
3188 reinsert breakpoints from the child process. Reinsert them to
3189 the parent process when vfork is done.
3190 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3191 (reinsert_reinsert_breakpoints): New function.
3192 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3193 (reinsert_reinsert_breakpoints): Declare.
3194
3195 2016-06-17 Yao Qi <yao.qi@linaro.org>
3196
3197 * linux-low.c (handle_extended_wait): If the parent is doing
3198 step-over, remove the reinsert breakpoints from the forked child.
3199
3200 2016-06-17 Yao Qi <yao.qi@linaro.org>
3201
3202 * linux-low.c (unsuspend_all_lwps): Declare.
3203 (linux_low_filter_event): If thread exited, call finish_step_over.
3204 If step-over is finished, unsuspend other threads.
3205
3206 2016-06-17 Yao Qi <yao.qi@linaro.org>
3207
3208 * linux-low.c (linux_resume_one_lwp_throw): Assert
3209 has_reinsert_breakpoints returns false.
3210 * mem-break.c (delete_disabled_breakpoints): Assert
3211 bp type isn't reinsert_breakpoint.
3212
3213 2016-06-17 Yao Qi <yao.qi@linaro.org>
3214
3215 * linux-low.c (maybe_hw_step): New function.
3216 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3217 (finish_step_over): Switch current_thread to lwp temporarily,
3218 and assert has_reinsert_breakpoints returns true.
3219 (proceed_one_lwp): Call maybe_hw_step.
3220 * mem-break.c (has_reinsert_breakpoints): New function.
3221 * mem-break.h (has_reinsert_breakpoints): Declare.
3222
3223 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3224
3225 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3226
3227 2016-05-17 Yao Qi <yao.qi@linaro.org>
3228
3229 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3230 instead of find_inferior.
3231
3232 2016-05-05 Yao Qi <yao.qi@linaro.org>
3233
3234 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3235 Initialize res to zero.
3236
3237 2016-05-05 Yao Qi <yao.qi@linaro.org>
3238
3239 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3240 to uint32_t.
3241
3242 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3243
3244 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3245 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3246 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3247
3248 2016-04-28 Par Olsson <par.olsson@windriver.com>
3249 Simon Marchi <simon.marchi@ericsson.com>
3250
3251 * tracepoint.c (write_inferior_int8): New function.
3252 (cmd_qtenable_disable): Write enable flag using
3253 write_inferior_int8.
3254
3255 2016-04-25 Yao Qi <yao.qi@linaro.org>
3256
3257 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3258 (need_step_over_p): Return zero if the LWP has pending signals
3259 can be delivered on software single step target.
3260
3261 2016-04-25 Yao Qi <yao.qi@linaro.org>
3262
3263 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3264 return instead of error.
3265
3266 2016-04-22 Yao Qi <yao.qi@linaro.org>
3267
3268 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3269 to 23.
3270
3271 2016-04-22 Yao Qi <yao.qi@linaro.org>
3272
3273 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3274 signal when stepping over breakpoint with software single
3275 step.
3276
3277 2016-04-21 Pedro Alves <palves@redhat.com>
3278
3279 * linux-s390-low.c (s390_collect_ptrace_register)
3280 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3281 add casts.
3282 (s390_check_regset): Use void * instead of gdb_byte *.
3283
3284 2016-04-20 Pedro Alves <palves@redhat.com>
3285
3286 * configure: Renegerate.
3287
3288 2016-04-20 Yao Qi <yao.qi@linaro.org>
3289
3290 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3291 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3292 number 16.
3293 (arm_store_gregset): Likewise.
3294
3295 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3296
3297 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3298 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3299 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3300 (amd64-avx-mpx-linux.c): New rules.
3301 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3302 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3303 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3304 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3305 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3306 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3307 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3308 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3309 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3310 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3311 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3312 * linux-x86-low.c (x86_linux_read_description): Add case for
3313 X86_XSTATE_AVX_MPX_MASK.
3314 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3315 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3316 init_registers_i386_avx_mpx_linux.
3317 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3318 (initialize_low_tracepoint): Call
3319 init_registers_i386_avx_mpx_linux.
3320 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3321 (initialize_low_tracepoint): Call
3322 init_registers_amd64_avx_mpx_linux.
3323 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3324 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3325 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3326 declarations.
3327
3328 2016-04-18 Pedro Alves <palves@redhat.com>
3329
3330 * configure: Regenerate.
3331
3332 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3333
3334 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3335 (aarch64_emit_sub): Likewise.
3336
3337 2016-04-12 Pedro Alves <palves@redhat.com>
3338
3339 * utils.c (prepare_to_throw_exception): Delete.
3340
3341 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3342
3343 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3344
3345 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3346
3347 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3348
3349 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3350
3351 * linux-aarch64-ipa.c: Add <elf.h> include.
3352 * linux-ppc-ipa.c: Add <elf.h> include.
3353 * linux-s390-ipa.c: Add <elf.h> include.
3354
3355 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3356
3357 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3358 (get_raw_reg_ptr): Likewise.
3359 (get_trace_state_variable_value_ptr): Likewise.
3360 (set_trace_state_variable_value_ptr): Likewise.
3361 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3362 char *.
3363
3364 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3365 Marcin Kościelnicki <koriakin@0x04.net>
3366
3367 PR/17221
3368 * linux-ppc-low.c (emit_insns): New function.
3369 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3370 (ppc_emit_prologue): New function.
3371 (ppc_emit_epilogue): New function.
3372 (ppc_emit_add): New function.
3373 (ppc_emit_sub): New function.
3374 (ppc_emit_mul): New function.
3375 (ppc_emit_lsh): New function.
3376 (ppc_emit_rsh_signed): New function.
3377 (ppc_emit_rsh_unsigned): New function.
3378 (ppc_emit_ext): New function.
3379 (ppc_emit_zero_ext): New function.
3380 (ppc_emit_log_not): New function.
3381 (ppc_emit_bit_and): New function.
3382 (ppc_emit_bit_or): New function.
3383 (ppc_emit_bit_xor): New function.
3384 (ppc_emit_bit_not): New function.
3385 (ppc_emit_equal): New function.
3386 (ppc_emit_less_signed): New function.
3387 (ppc_emit_less_unsigned): New function.
3388 (ppc_emit_ref): New function.
3389 (ppc_emit_const): New function.
3390 (ppc_emit_reg): New function.
3391 (ppc_emit_pop): New function.
3392 (ppc_emit_stack_flush): New function.
3393 (ppc_emit_swap): New function.
3394 (ppc_emit_stack_adjust): New function.
3395 (ppc_emit_call): New function.
3396 (ppc_emit_int_call_1): New function.
3397 (ppc_emit_void_call_2): New function.
3398 (ppc_emit_if_goto): New function.
3399 (ppc_emit_goto): New function.
3400 (ppc_emit_eq_goto): New function.
3401 (ppc_emit_ne_goto): New function.
3402 (ppc_emit_lt_goto): New function.
3403 (ppc_emit_le_goto): New function.
3404 (ppc_emit_gt_goto): New function.
3405 (ppc_emit_ge_goto): New function.
3406 (ppc_write_goto_address): New function.
3407 (ppc_emit_ops_impl): New static variable.
3408 (ppc64v1_emit_prologue): New function.
3409 (ppc64v2_emit_prologue): New function.
3410 (ppc64_emit_epilogue): New function.
3411 (ppc64_emit_add): New function.
3412 (ppc64_emit_sub): New function.
3413 (ppc64_emit_mul): New function.
3414 (ppc64_emit_lsh): New function.
3415 (ppc64_emit_rsh_signed): New function.
3416 (ppc64_emit_rsh_unsigned): New function.
3417 (ppc64_emit_ext): New function.
3418 (ppc64_emit_zero_ext): New function.
3419 (ppc64_emit_log_not): New function.
3420 (ppc64_emit_bit_and): New function.
3421 (ppc64_emit_bit_or): New function.
3422 (ppc64_emit_bit_xor): New function.
3423 (ppc64_emit_bit_not): New function.
3424 (ppc64_emit_equal): New function.
3425 (ppc64_emit_less_signed): New function.
3426 (ppc64_emit_less_unsigned): New function.
3427 (ppc64_emit_ref): New function.
3428 (ppc64_emit_const): New function.
3429 (ppc64v1_emit_reg): New function.
3430 (ppc64v2_emit_reg): New function.
3431 (ppc64_emit_pop): New function.
3432 (ppc64_emit_stack_flush): New function.
3433 (ppc64_emit_swap): New function.
3434 (ppc64v1_emit_call): New function.
3435 (ppc64v2_emit_call): New function.
3436 (ppc64v1_emit_int_call_1): New function.
3437 (ppc64v2_emit_int_call_1): New function.
3438 (ppc64v1_emit_void_call_2): New function.
3439 (ppc64v2_emit_void_call_2): New function.
3440 (ppc64_emit_if_goto): New function.
3441 (ppc64_emit_eq_goto): New function.
3442 (ppc64_emit_ne_goto): New function.
3443 (ppc64_emit_lt_goto): New function.
3444 (ppc64_emit_le_goto): New function.
3445 (ppc64_emit_gt_goto): New function.
3446 (ppc64_emit_ge_goto): New function.
3447 (ppc64v1_emit_ops_impl): New static variable.
3448 (ppc64v2_emit_ops_impl): New static variable.
3449 (ppc_emit_ops): New function.
3450 (linux_low_target): Wire in ppc_emit_ops.
3451
3452 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3453 Marcin Kościelnicki <koriakin@0x04.net>
3454
3455 PR/17221
3456 * Makefile.in: Add powerpc-*-ipa.o
3457 * configure.srv: Add ipa_obj for powerpc*-linux.
3458 * linux-ppc-ipa.c: New file.
3459 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3460 includes.
3461 (PPC_FIELD): New macro.
3462 (PPC_SEXT): New macro.
3463 (PPC_OP6): New macro.
3464 (PPC_BO): New macro.
3465 (PPC_LI): New macro.
3466 (PPC_BD): New macro.
3467 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3468 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3469 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3470 (ppc_get_thread_area): New function.
3471 (is_elfv2_inferior): New function.
3472 (gen_ds_form): New function.
3473 (GEN_STD): New macro.
3474 (GEN_STDU): New macro.
3475 (GEN_LD): New macro.
3476 (GEN_LDU): New macro.
3477 (gen_d_form): New function.
3478 (GEN_ADDI): New macro.
3479 (GEN_ADDIS): New macro.
3480 (GEN_LI): New macro.
3481 (GEN_LIS): New macro.
3482 (GEN_ORI): New macro.
3483 (GEN_ORIS): New macro.
3484 (GEN_LWZ): New macro.
3485 (GEN_STW): New macro.
3486 (GEN_STWU): New macro.
3487 (gen_xfx_form): New function.
3488 (GEN_MFSPR): New macro.
3489 (GEN_MTSPR): New macro.
3490 (GEN_MFCR): New macro.
3491 (GEN_MTCR): New macro.
3492 (GEN_SYNC): New macro.
3493 (GEN_LWSYNC): New macro.
3494 (gen_x_form): New function.
3495 (GEN_OR): New macro.
3496 (GEN_MR): New macro.
3497 (GEN_LWARX): New macro.
3498 (GEN_STWCX): New macro.
3499 (GEN_CMPW): New macro.
3500 (gen_md_form): New function.
3501 (GEN_RLDICL): New macro.
3502 (GEN_RLDICR): New macro.
3503 (gen_i_form): New function.
3504 (GEN_B): New macro.
3505 (GEN_BL): New macro.
3506 (gen_b_form): New function.
3507 (GEN_BNE): New macro.
3508 (GEN_LOAD): New macro.
3509 (GEN_STORE): New macro.
3510 (gen_limm): New function.
3511 (gen_atomic_xchg): New function.
3512 (gen_call): New function.
3513 (ppc_relocate_instruction): New function.
3514 (ppc_install_fast_tracepoint_jump_pad): New function.
3515 (ppc_get_min_fast_tracepoint_insn_len): New function.
3516 (ppc_get_ipa_tdesc_idx): New function.
3517 (the_low_target): Wire in the new functions.
3518 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3519 tdescs.
3520 * linux-ppc-tdesc.h: New file.
3521
3522 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3523
3524 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3525 (alloc_jump_pad_buffer): New function.
3526 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3527 (alloc_jump_pad_buffer): New function.
3528 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3529 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3530 (alloc_jump_pad_buffer): New function.
3531 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3532 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3533 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3534 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3535
3536 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3537
3538 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3539 * linux-amd64-ipa.c: Likewise.
3540 * linux-i386-ipa.c: Likewise.
3541 * linux-s390-ipa.c: Likewise.
3542 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3543 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3544 set_trace_state_variable_value_ptr.
3545 (struct ipa_sym_addresses): Likewise.
3546 (symbol_list): Likewise.
3547 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3548 accessing gdb_collect directly.
3549 (gdb_collect_ptr_type): New typedef.
3550 (get_raw_reg_ptr_type): New typedef.
3551 (get_trace_state_variable_value_ptr_type): New typedef.
3552 (set_trace_state_variable_value_ptr_type): New typedef.
3553 (gdb_collect_ptr): New global.
3554 (get_raw_reg_ptr): New global.
3555 (get_trace_state_variable_value_ptr): New global.
3556 (set_trace_state_variable_value_ptr): New global.
3557 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3558 accessing get_raw_reg directly.
3559 (get_get_tsv_func_addr): Likewise for
3560 get_trace_state_variable_value_ptr.
3561 (get_set_tsv_func_addr): Likewise for
3562 set_trace_state_variable_value_ptr.
3563 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3564
3565 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3566
3567 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3568
3569 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3570
3571 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3572 packets.
3573 (relocate_instruction): Remove own_buf.
3574 * server.c (own_buf): Make global.
3575 (handle_v_requests): Make global.
3576 * server.h (own_buf): New declaration.
3577 (handle_v_requests): New prototype.
3578
3579 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3580
3581 PR 18377
3582 * linux-s390-low.c (add_insns): New function.
3583 (s390_emit_prologue): New function.
3584 (s390_emit_epilogue): New function.
3585 (s390_emit_add): New function.
3586 (s390_emit_sub): New function.
3587 (s390_emit_mul): New function.
3588 (s390_emit_lsh): New function.
3589 (s390_emit_rsh_signed): New function.
3590 (s390_emit_rsh_unsigned): New function.
3591 (s390_emit_ext): New function.
3592 (s390_emit_log_not): New function.
3593 (s390_emit_bit_and): New function.
3594 (s390_emit_bit_or): New function.
3595 (s390_emit_bit_xor): New function.
3596 (s390_emit_bit_not): New function.
3597 (s390_emit_equal): New function.
3598 (s390_emit_less_signed): New function.
3599 (s390_emit_less_unsigned): New function.
3600 (s390_emit_ref): New function.
3601 (s390_emit_if_goto): New function.
3602 (s390_emit_goto): New function.
3603 (s390_write_goto_address): New function.
3604 (s390_emit_litpool): New function.
3605 (s390_emit_const): New function.
3606 (s390_emit_call): New function.
3607 (s390_emit_reg): New function.
3608 (s390_emit_pop): New function.
3609 (s390_emit_stack_flush): New function.
3610 (s390_emit_zero_ext): New function.
3611 (s390_emit_swap): New function.
3612 (s390_emit_stack_adjust): New function.
3613 (s390_emit_set_r2): New function.
3614 (s390_emit_int_call_1): New function.
3615 (s390_emit_void_call_2): New function.
3616 (s390_emit_eq_goto): New function.
3617 (s390_emit_ne_goto): New function.
3618 (s390_emit_lt_goto): New function.
3619 (s390_emit_le_goto): New function.
3620 (s390_emit_gt_goto): New function.
3621 (s390_emit_ge_goto): New function.
3622 (s390x_emit_prologue): New function.
3623 (s390x_emit_epilogue): New function.
3624 (s390x_emit_add): New function.
3625 (s390x_emit_sub): New function.
3626 (s390x_emit_mul): New function.
3627 (s390x_emit_lsh): New function.
3628 (s390x_emit_rsh_signed): New function.
3629 (s390x_emit_rsh_unsigned): New function.
3630 (s390x_emit_ext): New function.
3631 (s390x_emit_log_not): New function.
3632 (s390x_emit_bit_and): New function.
3633 (s390x_emit_bit_or): New function.
3634 (s390x_emit_bit_xor): New function.
3635 (s390x_emit_bit_not): New function.
3636 (s390x_emit_equal): New function.
3637 (s390x_emit_less_signed): New function.
3638 (s390x_emit_less_unsigned): New function.
3639 (s390x_emit_ref): New function.
3640 (s390x_emit_if_goto): New function.
3641 (s390x_emit_const): New function.
3642 (s390x_emit_call): New function.
3643 (s390x_emit_reg): New function.
3644 (s390x_emit_pop): New function.
3645 (s390x_emit_stack_flush): New function.
3646 (s390x_emit_zero_ext): New function.
3647 (s390x_emit_swap): New function.
3648 (s390x_emit_stack_adjust): New function.
3649 (s390x_emit_int_call_1): New function.
3650 (s390x_emit_void_call_2): New function.
3651 (s390x_emit_eq_goto): New function.
3652 (s390x_emit_ne_goto): New function.
3653 (s390x_emit_lt_goto): New function.
3654 (s390x_emit_le_goto): New function.
3655 (s390x_emit_gt_goto): New function.
3656 (s390x_emit_ge_goto): New function.
3657 (s390_emit_ops): New function.
3658 (struct linux_target_ops): Fill in emit_ops hook.
3659
3660 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3661
3662 PR 18377
3663 * Makefile.in: Add s390 IPA files.
3664 * configure.srv: Build IPA for s390.
3665 * linux-s390-ipa.c: New file.
3666 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
3667 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
3668 (tdesc_s390_linux32): Likewise.
3669 (init_registers_s390_linux32v1): Likewise.
3670 (tdesc_s390_linux32v1): Likewise.
3671 (init_registers_s390_linux32v2): Likewise.
3672 (tdesc_s390_linux32v2): Likewise.
3673 (init_registers_s390_linux64): Likewise.
3674 (tdesc_s390_linux64): Likewise.
3675 (init_registers_s390_linux64v1): Likewise.
3676 (tdesc_s390_linux64v1): Likewise.
3677 (init_registers_s390_linux64v2): Likewise.
3678 (tdesc_s390_linux64v2): Likewise.
3679 (init_registers_s390_te_linux64): Likewise.
3680 (tdesc_s390_te_linux64): Likewise.
3681 (init_registers_s390_vx_linux64): Likewise.
3682 (tdesc_s390_vx_linux64): Likewise.
3683 (init_registers_s390_tevx_linux64): Likewise.
3684 (tdesc_s390_tevx_linux64): Likewise.
3685 (init_registers_s390x_linux64): Likewise.
3686 (tdesc_s390x_linux64): Likewise.
3687 (init_registers_s390x_linux64v1): Likewise.
3688 (tdesc_s390x_linux64v1): Likewise.
3689 (init_registers_s390x_linux64v2): Likewise.
3690 (tdesc_s390x_linux64v2): Likewise.
3691 (init_registers_s390x_te_linux64): Likewise.
3692 (tdesc_s390x_te_linux64): Likewise.
3693 (init_registers_s390x_vx_linux64): Likewise.
3694 (tdesc_s390x_vx_linux64): Likewise.
3695 (init_registers_s390x_tevx_linux64): Likewise.
3696 (tdesc_s390x_tevx_linux64): Likewise.
3697 (have_hwcap_s390_vx): New static variable.
3698 (s390_arch_setup): Fill have_hwcap_s390_vx.
3699 (s390_get_thread_area): New function.
3700 (s390_ft_entry_gpr_esa): New const.
3701 (s390_ft_entry_gpr_zarch): New const.
3702 (s390_ft_entry_misc): New const.
3703 (s390_ft_entry_fr): New const.
3704 (s390_ft_entry_vr): New const.
3705 (s390_ft_main_31): New const.
3706 (s390_ft_main_64): New const.
3707 (s390_ft_exit_fr): New const.
3708 (s390_ft_exit_vr): New const.
3709 (s390_ft_exit_misc): New const.
3710 (s390_ft_exit_gpr_esa): New const.
3711 (s390_ft_exit_gpr_zarch): New const.
3712 (append_insns): New function.
3713 (s390_relocate_instruction): New function.
3714 (s390_install_fast_tracepoint_jump_pad): New function.
3715 (s390_get_min_fast_tracepoint_insn_len): New function.
3716 (s390_get_ipa_tdesc_idx): New function.
3717 (struct linux_target_ops): Wire in the above functions.
3718 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
3719 * linux-s390-tdesc.h: New file.
3720
3721 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3722
3723 * linux-s390-low.c (s390_supports_tracepoints): New function.
3724 (struct linux_target_ops): Fill supports_tracepoints hook.
3725
3726 2016-03-18 Yao Qi <yao.qi@linaro.org>
3727
3728 * linux-low.c (lwp_signal_can_be_delivered): New function.
3729 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
3730
3731 2016-03-18 Yao Qi <yao.qi@linaro.org>
3732
3733 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
3734 0 if signal is enqueued. Remove 'signal' from one debugging
3735 message. Move one debugging message to some lines below.
3736 Remove code setting 'signal' to 0.
3737
3738 2016-03-18 Yao Qi <yao.qi@linaro.org>
3739
3740 * linux-low.c (linux_low_filter_event): Remove redundant
3741 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
3742
3743 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
3744
3745 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
3746 (struct linux_target_ops): Wire in the above.
3747
3748 2016-03-03 Yao Qi <yao.qi@linaro.org>
3749
3750 * linux-low.c: Update comments to start_step_over.
3751
3752 2016-03-03 Yao Qi <yao.qi@linaro.org>
3753
3754 PR server/19736
3755 * linux-low.c (handle_extended_wait): Set child suspended
3756 if event_lwp->bp_reinsert isn't zero.
3757
3758 2016-03-02 Yao Qi <yao.qi@linaro.org>
3759
3760 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
3761 enqueue_pending_signal.
3762
3763 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
3764
3765 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
3766 is actually loaded.
3767
3768 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3769
3770 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
3771 (s390_regmap_3264) [!__s390x__]: New global.
3772 (s390_collect_ptrace_register): Skip map entries containing -1.
3773 (s390_supply_ptrace_register): Ditto.
3774 (s390_fill_gprs_high): New function.
3775 (s390_store_gprs_high): New function.
3776 (s390_regsets): Add NT_S390_HIGH_GPRS.
3777 (s390_get_hwcap): Enable on 31-bit.
3778 (have_hwcap_s390_high_gprs): Enable on 31-bit.
3779 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
3780 Detect NT_S390_HIGH_GPRS.
3781 (s390_usrregs_info_3264): Enable on 31-bit.
3782 (s390_regs_info): Enable regs_info_3264 on 31-bit.
3783 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
3784
3785 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3786
3787 PR gdb/13808
3788 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
3789 * configure.srv: Ditto.
3790 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
3791 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
3792 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
3793 (init_registers_amd64_linux): Remove prototype.
3794 (tdesc_amd64_linux): Remove declaration.
3795 (get_ipa_tdesc): New function.
3796 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3797 initialize remaining tdescs.
3798 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
3799 (init_registers_i386_linux): Remove prototype.
3800 (tdesc_i386_linux): Remove declaration.
3801 (get_ipa_tdesc): New function.
3802 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3803 initialize remaining tdescs.
3804 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
3805 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
3806 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
3807 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
3808 (x86_get_ipa_tdesc_idx): New function.
3809 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
3810 * linux-x86-tdesc.h: New file.
3811 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
3812 (target_get_ipa_tdesc_idx): New macro.
3813 * tracepoint.c (ipa_tdesc_idx): New macro.
3814 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
3815 (symbol_list): Add ipa_tdesc_idx.
3816 (cmd_qtstart): Write ipa_tdesc_idx in the target.
3817 (ipa_tdesc): Remove.
3818 (ipa_tdesc_idx): New variable.
3819 (get_context_regcache): Use get_ipa_tdesc.
3820 (gdb_collect): Ditto.
3821 (gdb_probe): Ditto.
3822 * tracepoint.h (get_ipa_tdesc): New prototype.
3823 (ipa_tdesc): Remove.
3824
3825 2016-02-24 Pedro Alves <palves@redhat.com>
3826
3827 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
3828 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
3829 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
3830 Factor out common code between the USE_SIGTRAP_SIGINFO and
3831 !USE_SIGTRAP_SIGINFO blocks.
3832 (linux_low_filter_event): Call save_stop_reason instead of
3833 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
3834 Update comments.
3835 (linux_wait_1): Update comments.
3836
3837 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
3838
3839 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
3840 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
3841 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
3842 ppc_insert_point, ppc_remove_point.
3843
3844 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
3845
3846 * linux-s390-low.c (s390_supports_z_point_type): New function.
3847 (struct linux_target_ops): Wire s390_supports_z_point_type in.
3848
3849 2016-02-16 Yao Qi <yao.qi@linaro.org>
3850
3851 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
3852 PC. Get pc from regcache_read_pc.
3853
3854 2016-02-12 Yao Qi <yao.qi@linaro.org>
3855
3856 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
3857 or linux_get_pc_32bit.
3858 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
3859
3860 2016-02-12 Yao Qi <yao.qi@linaro.org>
3861
3862 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
3863 arm_linux_get_next_pcs_fixup.
3864
3865 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
3866
3867 * tracepoint.c (x_tracepoint_action_download): Change
3868 write_inferior_data_ptr to write_inferior_data_pointer.
3869 (cmd_qtstart): Likewise.
3870 (write_inferior_data_ptr): Remove.
3871 (download_agent_expr): Change write_inferior_data_ptr to
3872 write_inferior_data_pointer.
3873 (download_tracepoint_1): Likewise.
3874 (download_tracepoint): Likewise.
3875 (download_trace_state_variables): Likewise.
3876
3877 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
3878 Marcin Kościelnicki <koriakin@0x04.net>
3879
3880 * tracepoint.c (struct tracepoint_action_ops): Remove.
3881 (struct tracepoint_action): Remove ops.
3882 (m_tracepoint_action_download, r_tracepoint_action_download)
3883 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
3884 size and offset accordingly.
3885 (m_tracepoint_action_ops, r_tracepoint_action_ops)
3886 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
3887 (tracepoint_action_send, tracepoint_action_download): New functions.
3888 Helpers for trace action handlers.
3889 (add_tracepoint_action): Remove setup actions ops.
3890 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
3891
3892 2016-02-10 Yao Qi <yao.qi@linaro.org>
3893
3894 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
3895
3896 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3897
3898 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
3899 to AC_OUTPUT.
3900 * configure: Regenerate.
3901
3902 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3903
3904 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
3905 void * to gdb_byte *.
3906 * linux-low.c (siginfo_fixup): Likewise.
3907 (linux_xfer_siginfo): Likewise.
3908 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
3909 Likewise.
3910 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
3911
3912 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
3913
3914 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
3915 to srv_tgtobj.
3916 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
3917 to srv_tgtobj.
3918 * linux-x86-low.c [__x86_64__]: Include
3919 "nat/amd64-linux-siginfo.h".
3920 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
3921 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
3922 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
3923 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
3924 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
3925 (cpt_si_fd, si_timerid, si_overrun): Move from
3926 nat/amd64-linux-siginfo.c.
3927 * Makefile.in (amd64-linux-siginfo.o:): New rule.
3928
3929 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
3930
3931 * server.c (skip_to_semicolon): Remove.
3932 (process_point_options): Use strchrnul instead of
3933 skip_to_semicolon.
3934
3935 2016-01-26 Yao Qi <yao.qi@linaro.org>
3936
3937 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
3938 * linux-low.c (install_software_single_step_breakpoints): Don't
3939 call regcache_read_pc.
3940 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
3941 argument pc.
3942
3943 2016-01-26 Yao Qi <yao.qi@linaro.org>
3944
3945 * linux-low.c (install_software_single_step_breakpoints): Call
3946 regcache_read_pc instead of get_pc.
3947
3948 2016-01-26 Yao Qi <yao.qi@linaro.org>
3949
3950 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
3951 (unblock_async_io): Rename to ...
3952 (block_unblock_async_io): ... it. New function.
3953 (enable_async_io): Don't install SIGIO handler. Unblock it
3954 instead.
3955 (disable_async_io): Don't ignore SIGIO. Block it instead.
3956 (initialize_async_io): Install SIGIO handler. Don't call
3957 unblock_async_io.
3958
3959 2016-01-26 Yao Qi <yao.qi@linaro.org>
3960
3961 * remote-utils.c (getpkt): If the buffer isn't empty, and the
3962 first character is '\003', call *the_target->request_interrupt.
3963
3964 2016-01-25 Yao Qi <yao.qi@linaro.org>
3965
3966 * remote-utils.c (new_thread_notify): Remove.
3967 (dead_thread_notify): Likewise.
3968 * remote-utils.h (new_thread_notify): Remove declaration.
3969 (dead_thread_notify): Likewise.
3970
3971 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
3972
3973 * gdb.trace/pending.exp: Fix expected message on continue.
3974
3975 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
3976
3977 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
3978 it works properly on big-endian machines where sizeof (CORE_ADDR)
3979 != sizeof (void *).
3980
3981 2016-01-21 Pedro Alves <palves@redhat.com>
3982
3983 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
3984 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
3985 * configure: Regenerate.
3986
3987 2016-01-21 Yao Qi <yao.qi@linaro.org>
3988
3989 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
3990 is_thumb and set it according to CPSR saved on the stack.
3991 (get_next_pcs_syscall_next_pc): Pass is_thumb to
3992 arm_sigreturn_next_pc.
3993
3994 2016-01-18 Yao Qi <yao.qi@linaro.org>
3995
3996 * linux-low.c (linux_set_pc_64bit): New function.
3997 (linux_get_pc_64bit): New function.
3998 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
3999 Declare.
4000 * linux-sparc-low.c (debug_threads): Remove declaration.
4001 (sparc_get_pc): Remove.
4002 (the_low_target): Use linux_get_pc_64bit instead of
4003 sparc_get_pc.
4004 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4005 (the_low_target): Use linux_get_pc_64bit and
4006 linux_set_pc_64bit.
4007
4008 2016-01-18 Yao Qi <yao.qi@linaro.org>
4009
4010 * linux-arm-low.c (debug_threads): Remove declaration.
4011 (arm_get_pc, arm_set_pc): Remove.
4012 (the_low_target): Use linux_get_pc_32bit and
4013 linux_set_pc_32bit.
4014 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4015 (the_low_target): Use linux_get_pc_32bit and
4016 linux_set_pc_32bit.
4017 * linux-cris-low.c (debug_threads): Remove declaration.
4018 (cris_get_pc, cris_set_pc,): Remove.
4019 (the_low_target): Use linux_get_pc_32bit and
4020 linux_set_pc_32bit.
4021 * linux-crisv32-low.c (debug_threads): Remove declaration.
4022 (cris_get_pc, cris_set_pc): Remove.
4023 (the_low_target): Use linux_get_pc_32bit and
4024 linux_set_pc_32bit.
4025 * linux-low.c: Include inttypes.h.
4026 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4027 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4028 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4029 (the_low_target): Use linux_get_pc_32bit and
4030 linux_set_pc_32bit.
4031 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4032 (the_low_target): Use linux_get_pc_32bit and
4033 linux_set_pc_32bit.
4034 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4035 (the_low_target): Use linux_get_pc_32bit and
4036 linux_set_pc_32bit.
4037 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4038 (the_low_target): Use linux_get_pc_32bit and
4039 linux_set_pc_32bit.
4040 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4041 (the_low_target): Use linux_get_pc_32bit and
4042 linux_set_pc_32bit.
4043
4044 2016-01-18 Gary Benson <gbenson@redhat.com>
4045
4046 * configure.ac (AC_FUNC_FORK): New check.
4047 * config.in: Regenerate.
4048 * configure: Likewise.
4049
4050 2016-01-14 Yao Qi <yao.qi@linaro.org>
4051
4052 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4053 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4054 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4055 arm_get_next_pcs_ctor.
4056
4057 2016-01-12 Josh Stone <jistone@redhat.com>
4058 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4059
4060 * inferiors.h: Include "gdb_vecs.h".
4061 (struct process_info): Add syscalls_to_catch.
4062 * inferiors.c (remove_process): Free syscalls_to_catch.
4063 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4064 syscall_return stops.
4065 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4066 * server.c (handle_general_set): Handle QCatchSyscalls.
4067 (handle_query): Report support for QCatchSyscalls.
4068 * target.h (struct target_ops): Add supports_catch_syscall.
4069 (target_supports_catch_syscall): New macro.
4070 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4071 (struct lwp_info): Add syscall_state.
4072 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4073 Maintain syscall_state and syscalls_to_catch across exec.
4074 (get_syscall_trapinfo): New function, proxy to the_low_target.
4075 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4076 (linux_low_filter_event): Toggle syscall_state entry/return for
4077 syscall traps, and set it ignored for all others.
4078 (gdb_catching_syscalls_p): New function.
4079 (gdb_catch_this_syscall_p): New function.
4080 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4081 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4082 (linux_supports_catch_syscall): New function.
4083 (linux_target_ops): Install it.
4084 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4085 (the_low_target): Install it.
4086
4087 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4088
4089 * acinclude.m4: Include new ../warning.m4 file.
4090 * configure: Regenerated.
4091 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4092
4093 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4094
4095 * ax.c (is_goto_target): Mark static.
4096 * linux-low.c (register_addr): Likewise.
4097 (linux_fetch_registers, linux_store_registers): Likewise.
4098 * mem-break.c (any_persistent_commands): Fix old prototype.
4099 (add_commands_to_breakpoint): Mark static.
4100 * regcache.c (find_register_by_name): Delete unused func.
4101 * remote-utils.c (hex_or_minus_one): Mark static.
4102 * server.c (monitor_show_help): Mark static.
4103 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4104 handle_v_requests): Likewise.
4105
4106 2016-01-12 Pedro Alves <palves@redhat.com>
4107
4108 Remove use of the registered trademark symbol throughout.
4109
4110 2016-01-08 Yao Qi <yao.qi@linaro.org>
4111
4112 * remote-utils.c (getpkt): If c is '\003', call target hook
4113 request_interrupt.
4114
4115 2016-01-06 Yao Qi <yao.qi@linaro.org>
4116
4117 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4118 linux-aarch32-low.c.
4119 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4120 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4121 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4122 (thumb2_breakpoint): Declare.
4123 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4124 linux-aarch32-low.h.
4125 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4126 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4127 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4128
4129 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4130
4131 * gdbreplay.c (gdbreplay_version): Change copyright year in
4132 version message.
4133 * server.c (gdbserver_version): Likewise.
4134
4135 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4136
4137 * server.c (crc32_table): Delete.
4138 (crc32): Use libiberty's xcrc32 function.
4139
4140 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4141
4142 * lynx-low.c (lynx_delete_thread_callback): New function.
4143 (lynx_mourn): Properly delete our process and all of its
4144 threads. Remove call to clear_inferiors.
4145
4146 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4147
4148 * target.c (thread_search_callback): Add check that
4149 the thread_stopped target callback is not NULL before
4150 calling it.
4151
4152 2015-12-21 Yao Qi <yao.qi@linaro.org>
4153
4154 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4155 arm breakpoint.
4156
4157 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4158
4159 * server.c (handle_query): Call target_supports_software_single_step.
4160
4161 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4162
4163 * linux-low.c (single_step): New function.
4164 (linux_resume_one_lwp_throw): Call single_step.
4165 (start_step_over): Likewise.
4166
4167 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4168
4169 * Makefile.in (SFILES): Append arch/arm-linux.c,
4170 arch/arm-get-next-pcs.c.
4171 (arm-linux.o): New rule.
4172 (arm-get-next-pcs.o): New rule.
4173 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4174 arm-linux.o.
4175 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4176 to linux-aarch32-low.c.
4177 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4178 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4179 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4180 (thumb2_breakpoint_len): Likewise.
4181 (arm_is_thumb_mode): Make non-static.
4182 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4183 from linux-aarch32-low.c.
4184 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4185 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4186 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4187 (thumb2_breakpoint_len): Likewise.
4188 (arm_is_thumb_mode): New declaration.
4189 * linux-arm-low.c: Include arch/arm-linux.h
4190 aarch/arm-get-next-pcs.h, sys/syscall.h.
4191 (get_next_pcs_ops): New struct.
4192 (get_next_pcs_addr_bits_remove): New function.
4193 (get_next_pcs_is_thumb): New function.
4194 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4195 (arm_sigreturn_next_pc): Likewise.
4196 (get_next_pcs_syscall_next_pc): Likewise.
4197 (arm_gdbserver_get_next_pcs): Likewise.
4198 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4199 Initialize.
4200 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4201 * server.h: Include gdb_vecs.h.
4202
4203 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4204
4205 * Makefile.in (SFILES): Append common/common-regcache.c.
4206 (OBS): Append common-regcache.o.
4207 (common-regcache.o): New rule.
4208 * regcache.c (init_register_cache): Initialize cache to
4209 REG_UNAVAILABLE.
4210 (regcache_raw_read_unsigned): New function.
4211 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4212 register_status enum.
4213
4214 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4215
4216 * linux-aarch64-low.c (the_low_targets): Rename
4217 breakpoint_reinsert_addr to get_next_pcs.
4218 * linux-arm-low.c (the_low_targets): Likewise.
4219 * linux-bfin-low.c (the_low_targets): Likewise.
4220 * linux-cris-low.c (the_low_targets): Likewise.
4221 * linux-crisv32-low.c (the_low_targets): Likewise.
4222 * linux-low.c (can_software_single_step): Likewise.
4223 (install_software_single_step_breakpoints): New function.
4224 (start_step_over): Use install_software_single_step_breakpoints.
4225 * linux-low.h: New CORE_ADDR vector.
4226 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4227 get_next_pcs.
4228 * linux-mips-low.c (the_low_targets): Likewise.
4229 * linux-nios2-low.c (the_low_targets): Likewise.
4230 * linux-sparc-low.c (the_low_targets): Likewise.
4231
4232 2015-12-17 Pedro Alves <palves@redhat.com>
4233
4234 * linux-low.c (linux_kill_one_lwp): Remove references to
4235 LinuxThreads.
4236 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4237 to 'kill'.
4238 (linux_init_signals): Delete.
4239 (initialize_low): Adjust.
4240 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4241
4242 2015-12-16 Pedro Alves <palves@redhat.com>
4243
4244 * configure.ac (compiler warning flags): When testing a
4245 -Wno-foo option, check whether -Wfoo works instead.
4246 * configure: Regenerate.
4247
4248 2015-12-11 Don Breazeal <donb@codesourcery.com>
4249
4250 * server.c (process_serial_event): Don't exit from gdbserver
4251 in remote mode if there are still active inferiors.
4252
4253 2015-12-11 Yao Qi <yao.qi@linaro.org>
4254
4255 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4256 arm_breakpoint_at if the process is 32-bit.
4257
4258 2015-12-11 Yao Qi <yao.qi@linaro.org>
4259
4260 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4261 arm breakpoint.
4262
4263 2015-12-07 Yao Qi <yao.qi@linaro.org>
4264
4265 * configure.srv: Append arm.o to srv_tgtobj for
4266 aarch64*-*-linux* target.
4267 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4268 from linux-arm-low.c.
4269 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4270 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4271 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4272 (thumb2_breakpoint_len): Likewise.
4273 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4274 (arm_breakpoint_kinds): Likewise.
4275 (arm_breakpoint_kind_from_pc): Likewise.
4276 (arm_sw_breakpoint_from_kind): Likewise.
4277 (arm_breakpoint_kind_from_current_state): Likewise.
4278 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4279 (arm_sw_breakpoint_from_kind): Declare.
4280 (arm_breakpoint_kind_from_current_state): Declare.
4281 (arm_breakpoint_at): Declare.
4282 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4283 arm_sw_breakpoint_from_kind if process is 32-bit.
4284 (aarch64_breakpoint_kind_from_pc): New function.
4285 (aarch64_breakpoint_kind_from_current_state): New function.
4286 (the_low_target): Initialize fields breakpoint_kind_from_pc
4287 and breakpoint_kind_from_current_state.
4288 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4289 linux-aarch32-low.c.
4290 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4291 (arm_breakpoint, arm_breakpoint_len): Likewise.
4292 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4293 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4294 (arm_is_thumb_mode): Likewise.
4295 (arm_breakpoint_at): Likewise.
4296 (arm_breakpoint_kind_from_pc): Likewise.
4297 (arm_sw_breakpoint_from_kind): Likewise.
4298 (arm_breakpoint_kind_from_current_state): Likewise.
4299
4300 Revert:
4301 2015-08-04 Yao Qi <yao.qi@linaro.org>
4302
4303 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4304 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4305 * server.c (extended_protocol): Remove "static".
4306 * server.h (extended_protocol): Declare it.
4307
4308 2015-12-04 Josh Stone <jistone@redhat.com>
4309
4310 * target.h (struct target_ops) <arch_setup>: Rename to ...
4311 (struct target_ops) <post_create_inferior>: ... this.
4312 (target_arch_setup): Rename to ...
4313 (target_post_create_inferior): ... this, calling post_create_inferior.
4314 * server.c (start_inferior): Update target_arch_setup calls to
4315 target_post_create_inferior.
4316 * linux-low.c (linux_low_ptrace_options): Forward declare.
4317 (linux_arch_setup): Update its comment for general use.
4318 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4319 (struct linux_target_ops): Use linux_post_create_inferior.
4320 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4321 to post_create_inferior.
4322 * nto-low.c (struct nto_target_ops): Likewise.
4323 * spu-low.c (struct spu_target_ops): Likewise.
4324 * win32-low.c (struct win32_target_ops): Likewise.
4325
4326 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4327
4328 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4329
4330 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4331
4332 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4333 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4334 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4335 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4336 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4337 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4338 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4339 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4340 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4341 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4342 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4343 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4344
4345 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4346
4347 * linux-low.c (linux_look_up_symbols): Don't call
4348 linux_supports_traceclone.
4349 * linux-low.h (thread_db_init): Remove use_events argument.
4350 * thread-db.c (thread_db_use_event): Remove global variable.
4351 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4352 (struct thread_db) <td_create_bp>: Remove field.
4353 (thread_db_create_event): Remove function.
4354 (thread_db_enable_reporting): Likewise.
4355 (find_one_thread): Don't check for thread_db_use_events.
4356 (attach_thread): Likewise.
4357 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4358 (try_thread_db_load_1): Don't check for thread_db_use_events.
4359 (thread_db_init): Remove use_events argument and thread events
4360 handling.
4361 (remove_thread_event_breakpoints): Remove function.
4362 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4363
4364 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4365
4366 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4367 New function.
4368 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4369 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4370 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4371 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4372 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4373 Initialize.
4374 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4375 New function.
4376 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4377 * linux-low.c (can_hardware_single_step): Use
4378 supports_hardware_single_step.
4379 (can_software_single_step): New function.
4380 (start_step_over): Call can_software_single_step.
4381 (linux_supports_hardware_single_step): New function.
4382 (struct target_ops) <supports_software_single_step>: Initialize.
4383 * linux-low.h (struct linux_target_ops)
4384 <supports_hardware_single_step>: Initialize.
4385 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4386 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4387 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4388 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4389 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4390 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4391 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4392 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4393 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4394 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4395 Initialize.
4396 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4397 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4398 Initialize.
4399 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4400 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4401 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4402 New function.
4403 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4404 * target.h (struct target_ops): <supports_software_single_step>:
4405 New field.
4406 (target_supports_software_single_step): New macro.
4407
4408 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4409
4410 * linux-low.c (linux_wait_1): Fix pc advance condition.
4411 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4412 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4413
4414 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4415
4416 * linux-arm-low.c (arm_is_thumb_mode): New function.
4417 (arm_breakpoint_at): Use arm_is_thumb_mode.
4418 (arm_breakpoint_kind_from_current_state): New function.
4419 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4420 Initialize.
4421 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4422 (linux_breakpoint_kind_from_current_state): New function.
4423 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4424 * linux-low.h (struct linux_target_ops)
4425 <breakpoint_kind_from_current_state>: New field.
4426 * target.h (struct target_ops): Likewise.
4427 (target_breakpoint_kind_from_current_state): New macro.
4428
4429 2015-11-30 Pedro Alves <palves@redhat.com>
4430
4431 * linux-low.c (linux_resume): Wake up the event loop before
4432 returning.
4433
4434 2015-11-30 Pedro Alves <palves@redhat.com>
4435
4436 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4437 check.
4438 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4439 to -1.
4440 * target.c (struct thread_search): New structure.
4441 (thread_search_callback): New function.
4442 (prev_general_thread): New global.
4443 (prepare_to_access_memory, done_accessing_memory): New functions.
4444 * target.h (prepare_to_access_memory, done_accessing_memory):
4445 Replace macros with function declarations.
4446
4447 2015-11-30 Pedro Alves <palves@redhat.com>
4448
4449 PR 14618
4450 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4451 report TARGET_WAITKIND_NO_RESUMED.
4452 * remote-utils.c (prepare_resume_reply): Handle
4453 TARGET_WAITKIND_NO_RESUMED.
4454 * server.c (report_no_resumed): New global.
4455 (handle_query) <qSupported>: Handle "no-resumed+". Report
4456 "no-resumed+" support.
4457 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4458 return error if the client doesn't support no-resumed events.
4459 (push_stop_notification): New function.
4460 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4461 events if the client supports them.
4462
4463 2015-11-30 Pedro Alves <palves@redhat.com>
4464
4465 * linux-low.c (thread_still_has_status_pending_p): Don't check
4466 vCont;t here.
4467 (lwp_resumed): New function.
4468 (status_pending_p_callback): Return early if the LWP is not
4469 supposed to be resumed.
4470
4471 2015-11-30 Pedro Alves <palves@redhat.com>
4472
4473 * linux-low.c (handle_extended_wait): Assert that the LWP's
4474 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4475 thread create events, leave the new child's status pending.
4476 (linux_low_filter_event): If GDB wants to hear about thread exit
4477 events, leave the LWP marked dead and don't delete it.
4478 (linux_wait_for_event_filtered): Don't check for thread exit.
4479 (filter_exit_event): New function.
4480 (linux_wait_1): Use it, when returning an exit event.
4481 (linux_resume_one_lwp_throw): Assert that the LWP's
4482 waitstatus is TARGET_WAITKIND_IGNORE.
4483 * remote-utils.c (prepare_resume_reply): Handle
4484 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4485 * server.c (report_thread_events): New global.
4486 (handle_general_set): Handle QThreadEvents.
4487 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4488 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4489 TARGET_WAITKIND_THREAD_EXITED.
4490 * server.h (report_thread_events): Declare.
4491
4492 2015-11-30 Pedro Alves <palves@redhat.com>
4493
4494 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4495 the thread's last_resume_kind was resume_stop.
4496
4497 2015-11-30 Pedro Alves <palves@redhat.com>
4498
4499 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4500 before returning.
4501
4502 2015-11-30 Pedro Alves <palves@redhat.com>
4503
4504 * server.c (handle_v_requests): Handle vCtrlC.
4505
4506 2015-11-30 Pedro Alves <palves@redhat.com>
4507
4508 * gdbthread.h (find_any_thread_of_pid): Declare.
4509 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4510 functions.
4511 * server.c (handle_query): If current_thread is NULL, look for
4512 another thread of the selected process.
4513
4514 2015-11-26 Daniel Colascione <dancol@dancol.org>
4515 Simon Marchi <simon.marchi@ericsson.com>
4516
4517 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4518 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4519 name in reply.
4520 * target.h (struct target_ops) <thread_name>: New field.
4521 (target_thread_name): New macro.
4522
4523 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4524
4525 * regcache.h (regcache_invalidate_pid): Add declaration.
4526 * regcache.c (regcache_invalidate_pid): New function, extracted
4527 from regcache_invalidate.
4528 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4529 Add trivial documentation comment.
4530 * lynx-low.c: Use regcache_invalidate_pid instead of
4531 regcache_invalidate.
4532
4533 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4534
4535 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4536 and Elf64_auxv_t if the target is Android.
4537
4538 2015-11-22 Doug Evans <xdje42@gmail.com>
4539
4540 * target.h: #include <sys/types.h>.
4541
4542 2015-11-19 Pedro Alves <palves@redhat.com>
4543
4544 * linux-low.c (linux_process_qsupported): Change prototype.
4545 Adjust.
4546 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4547 Change prototype.
4548 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4549 and adjust to loop over all features.
4550 * server.c (handle_query) <qSupported>: Adjust to call
4551 target_process_qsupported once, passing it a vector of unprocessed
4552 features.
4553 * target.h (struct target_ops) <process_qsupported>: Change
4554 prototype.
4555 (target_process_qsupported): Adjust.
4556
4557 2015-11-19 Pedro Alves <palves@redhat.com>
4558
4559 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4560 mode.
4561 * configure: Regenerate.
4562
4563 2015-11-19 Pedro Alves <palves@redhat.com>
4564
4565 * configure: Regenerate.
4566
4567 2015-11-19 Yao Qi <yao.qi@linaro.org>
4568
4569 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4570 type to uint32_t.
4571
4572 2015-11-19 Yao Qi <yao.qi@linaro.org>
4573
4574 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4575 (struct aarch64_operand): Move enum out.
4576
4577 2015-11-19 Yao Qi <yao.qi@linaro.org>
4578
4579 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
4580 struct user_fpsimd_state *.
4581 (aarch64_store_fpregset): Likewise.
4582
4583 2015-11-19 Yao Qi <yao.qi@linaro.org>
4584
4585 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
4586 struct user_pt_regs *.
4587 (aarch64_store_gregset): Likewise.
4588
4589 2015-11-18 Pedro Alves <palves@redhat.com>
4590
4591 * Makefile.in (all_object_files): Add $IPA_OBJS.
4592
4593 2015-11-17 Pedro Alves <palves@redhat.com>
4594
4595 * win32-low.c (win32_resume): Use gdb_signal_from_host,
4596 GDB_SIGNAL_0 and gdb_signal_to_string.
4597
4598 2015-11-17 Pedro Alves <palves@redhat.com>
4599
4600 * win32-low.c (handle_output_debug_string): Remove parameter.
4601 (win32_kill): Remove our_status local and adjust call to
4602 handle_output_debug_string.
4603 (get_child_debug_event): Adjust call to
4604 handle_output_debug_string.
4605
4606 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4607
4608 * linux-mips-low.c (mips_fill_gregset): Add cast.
4609 (mips_store_gregset): Likewise.
4610 (mips_fill_fpregset): Likewise.
4611 (mips_store_fpregset): Likewise.
4612
4613 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4614
4615 * linux-mips-low.c (mips_add_watchpoint): Rename private to
4616 priv.
4617
4618 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4619
4620 * linux-mips-low.c (mips_linux_new_thread): Change type of
4621 watch_type to enum target_hw_bp_type.
4622
4623 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4624
4625 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
4626 Change return type to arm_hwbp_type.
4627
4628 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4629
4630 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
4631 (arm_store_gregset): Likewise.
4632 * linux-arm-low.c (arm_get_hwcap): Likewise.
4633 (arm_read_description): Likewise.
4634
4635 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4636
4637 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
4638
4639 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4640
4641 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
4642 (ppc_fill_vsxregset): Likewise.
4643 (ppc_store_vsxregset): Likewise.
4644 (ppc_fill_vrregset): Likewise.
4645 (ppc_store_vrregset): Likewise.
4646 (ppc_fill_evrregset): Likewise.
4647 (ppc_store_evrregset): Likewise.
4648
4649 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4650
4651 * linux-ppc-low.c (ppc_usrregs_info): Remove
4652 forward-declaration.
4653 (ppc_arch_setup): Move lower in file.
4654
4655 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
4656
4657 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
4658 (ps_pdwrite): Likewise.
4659
4660 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
4661
4662 * linux-arm-low.c (arm_new_thread): Move pointer dereference
4663 to after assert checks.
4664
4665 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
4666
4667 * proc-service.c (ps_pdread): Add/adjust casts.
4668 (ps_pdwrite): Add/adjust casts.
4669
4670 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4671
4672 * server.c (handle_search_memory_1): Cast return value of
4673 memmem.
4674
4675 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4676
4677 * server.c (write_qxfer_response): Change type of data to
4678 gdb_byte *.
4679
4680 2015-10-29 Pedro Alves <palves@redhat.com>
4681
4682 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
4683
4684 2015-10-29 Pedro Alves <palves@redhat.com>
4685
4686 * tracepoint.c (clear_installed_tracepoints): Add casts.
4687
4688 2015-10-29 Pedro Alves <palves@redhat.com>
4689
4690 * server.c (handle_v_cont, process_serial_event): Add enum
4691 gdb_signal casts to signal parsing code.
4692
4693 2015-10-29 Pedro Alves <palves@redhat.com>
4694
4695 * linux-low.h (NULL_REGSET): Define.
4696 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4697 * linux-arm-low.c (arm_regsets): Likewise.
4698 * linux-crisv32-low.c (cris_regsets): Likewise.
4699 * linux-m68k-low.c (m68k_regsets): Likewise.
4700 * linux-mips-low.c (mips_regsets): Likewise.
4701 * linux-nios2-low.c (nios2_regsets): Likewise.
4702 * linux-ppc-low.c (ppc_regsets): Likewise.
4703 * linux-s390-low.c (s390_regsets): Likewise.
4704 * linux-sh-low.c (sh_regsets): Likewise.
4705 * linux-sparc-low.c (sparc_regsets): Likewise.
4706 * linux-tic6x-low.c (tic6x_regsets): Likewise.
4707 * linux-tile-low.c (tile_regsets): Likewise.
4708 * linux-x86-low.c (x86_regsets): Likewise.
4709 * linux-xtensa-low.c (xtensa_regsets): Likewise.
4710
4711 2015-10-29 Pedro Alves <palves@redhat.com>
4712
4713 * linux-low.h (NULL_REGSET): Define.
4714 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4715 * linux-arm-low.c (arm_regsets): Likewise.
4716 * linux-crisv32-low.c (cris_regsets): Likewise.
4717 * linux-m68k-low.c (m68k_regsets): Likewise.
4718 * linux-mips-low.c (mips_regsets): Likewise.
4719 * linux-nios2-low.c (nios2_regsets): Likewise.
4720 * linux-ppc-low.c (ppc_regsets): Likewise.
4721 * linux-s390-low.c (s390_regsets): Likewise.
4722 * linux-sh-low.c (sh_regsets): Likewise.
4723 * linux-sparc-low.c (sparc_regsets): Likewise.
4724 * linux-tic6x-low.c (tic6x_regsets): Likewise.
4725 * linux-tile-low.c (tile_regsets): Likewise.
4726 * linux-x86-low.c (x86_regsets): Likewise.
4727 * linux-xtensa-low.c (xtensa_regsets): Likewise.
4728
4729 2015-10-26 Doug Evans <dje@google.com>
4730
4731 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
4732
4733 2015-10-26 Doug Evans <dje@google.com>
4734
4735 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
4736
4737 2015-10-26 Doug Evans <dje@google.com>
4738
4739 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
4740 for debug_printf.
4741 (attach_thread, find_new_threads_callback): Ditto.
4742
4743 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4744
4745 * mem-break.h (set_breakpoint_data): Remove.
4746
4747 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4748
4749 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
4750 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4751 (initialize_low): Remove set_breakpoint_data call.
4752 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
4753 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
4754 (initialize_low): Remove set_breakpoint_data call.
4755 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
4756 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4757 (initialize_low): Remove set_breakpoint_data call.
4758
4759 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4760
4761 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
4762 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
4763 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
4764 * target.h (target_breakpoint_kind_from_pc): New macro.
4765
4766 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
4767
4768 * linux-low.c (default_breakpoint_kind_from_pc): New function.
4769 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
4770 the default breakpoint kind.
4771
4772 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4773
4774 * linux-arm-low.c (arm_supports_z_point_type): Add software
4775 breakpoint support.
4776
4777 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4778
4779 * linux-arm-low.c: Refactor breakpoint definitions.
4780 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
4781 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
4782
4783 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4784
4785 * Makefile.in: Add arm.c/o.
4786 * configure.srv: Likewise.
4787 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
4788 (arm_breakpoint_kind_from_pc): New function.
4789 (arm_sw_breakpoint_from_kind): Return proper kind.
4790 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
4791
4792 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4793
4794 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
4795 removal.
4796 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
4797 (struct raw_breakpoint) <size>: Remove.
4798 (struct raw_breakpoint) <kind>: Add.
4799 (bp_size): New function.
4800 (bp_opcode): Likewise.
4801 (find_raw_breakpoint_at): Adjust for kind.
4802 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
4803 (remove_memory_breakpoint): Adjust for kind call bp_size.
4804 (set_raw_breakpoint_at): Adjust for kind.
4805 (set_breakpoint): Likewise.
4806 (set_breakpoint_at): Call breakpoint_kind_from_pc.
4807 (delete_raw_breakpoint): Adjust for kind.
4808 (delete_breakpoint): Likewise.
4809 (find_gdb_breakpoint): Likewise.
4810 (set_gdb_breakpoint_1): Likewise.
4811 (set_gdb_breakpoint): Likewise.
4812 (delete_gdb_breakpoint_1): Likewise.
4813 (delete_gdb_breakpoint): Likewise.
4814 (uninsert_raw_breakpoint): Likewise.
4815 (reinsert_raw_breakpoint): Likewise.
4816 (set_breakpoint_data): Remove.
4817 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
4818 (check_mem_read): Adjust for kind call bp_size.
4819 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
4820 (clone_one_breakpoint): Adjust for kind.
4821 * mem-break.h (set_gdb_breakpoint): Likewise.
4822 (delete_gdb_breakpoint): Likewise.
4823 * server.c (process_serial_event): Likewise.
4824
4825 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4826
4827 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
4828 (struct linux_target_ops) <breakpoint>: Remove.
4829 (struct linux_target_ops) <breakpoint_len>: Remove.
4830 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4831 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4832 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
4833 (arm_sw_breakpoint_from_kind): New function.
4834 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
4835 (struct linux_target_ops) <breakpoint>: Remove.
4836 (struct linux_target_ops) <breakpoint_len>: Remove.
4837 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4838 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4839 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
4840 (struct linux_target_ops) <breakpoint>: Remove.
4841 (struct linux_target_ops) <breakpoint_len>: Remove.
4842 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4843 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4844 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
4845 (struct linux_target_ops) <breakpoint>: Remove.
4846 (struct linux_target_ops) <breakpoint_len>: Remove.
4847 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4848 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4849 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
4850 and sw_breakpoint_from_kind to increment the pc.
4851 (linux_breakpoint_kind_from_pc): New function.
4852 (linux_sw_breakpoint_from_kind): New function.
4853 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
4854 (initialize_low): Call breakpoint_kind_from_pc and
4855 sw_breakpoint_from_kind to replace breakpoint_data/len.
4856 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
4857 New field.
4858 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
4859 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
4860 (struct linux_target_ops) <breakpoint>: Remove.
4861 (struct linux_target_ops) <breakpoint_len>: Remove.
4862 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4863 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4864 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
4865 (struct linux_target_ops) <breakpoint>: Remove.
4866 (struct linux_target_ops) <breakpoint_len>: Remove.
4867 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4868 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4869 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
4870 (struct linux_target_ops) <breakpoint>: Remove.
4871 (struct linux_target_ops) <breakpoint_len>: Remove.
4872 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4873 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4874 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
4875 (struct linux_target_ops) <breakpoint>: Remove.
4876 (struct linux_target_ops) <breakpoint_len>: Remove.
4877 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4878 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4879 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
4880 (struct linux_target_ops) <breakpoint>: Remove.
4881 (struct linux_target_ops) <breakpoint_len>: Remove.
4882 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4883 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4884 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
4885 (struct linux_target_ops) <breakpoint>: Remove.
4886 (struct linux_target_ops) <breakpoint_len>: Remove.
4887 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4888 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4889 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
4890 (struct linux_target_ops) <breakpoint>: Remove.
4891 (struct linux_target_ops) <breakpoint_len>: Remove.
4892 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4893 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4894 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
4895 (struct linux_target_ops) <breakpoint>: Remove.
4896 (struct linux_target_ops) <breakpoint_len>: Remove.
4897 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4898 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4899 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
4900 (struct linux_target_ops) <breakpoint>: Remove.
4901 (struct linux_target_ops) <breakpoint_len>: Remove.
4902 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4903 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4904 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
4905 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
4906 (struct linux_target_ops) <breakpoint>: Remove.
4907 (struct linux_target_ops) <breakpoint_len>: Remove.
4908 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4909 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4910 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
4911 (struct linux_target_ops) <breakpoint>: Remove.
4912 (struct linux_target_ops) <breakpoint_len>: Remove.
4913 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4914 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4915
4916 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4917
4918 * linux-cris-low.c (cris_get_pc): Remove void arg.
4919
4920 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4921
4922 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
4923 variable name.
4924
4925 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4926
4927 * inferiors.c (thread_pid_matches_callback): New function.
4928 (find_thread_process): New function.
4929 (remove_thread): Reset current_thread.
4930 (remove_process): Assert threads have been removed first.
4931
4932 2015-10-15 Yao Qi <yao.qi@linaro.org>
4933
4934 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
4935 if it is 3.
4936 (aarch64_remove_point): Likewise.
4937 * regcache.c (regcache_register_size): New function.
4938
4939 2015-10-12 Yao Qi <yao.qi@linaro.org>
4940
4941 * linux-aarch64-low.c: Update all callers as emit_load_store
4942 is renamed to aarch64_emit_load_store.
4943
4944 2015-10-12 Yao Qi <yao.qi@linaro.org>
4945
4946 * linux-aarch64-low.c: Update all callers of function renaming
4947 from emit_insn to aarch64_emit_insn.
4948
4949 2015-10-12 Yao Qi <yao.qi@linaro.org>
4950
4951 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
4952 arch/aarch64-insn.h.
4953 (struct aarch64_memory_operand): Likewise.
4954 (ENCODE): Likewise.
4955 (emit_insn): Move to arch/aarch64-insn.c.
4956 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
4957 (emit_load_store): Move to arch/aarch64-insn.c.
4958 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
4959 (can_encode_int32): Remove.
4960
4961 2015-10-12 Yao Qi <yao.qi@linaro.org>
4962
4963 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
4964 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
4965 (aarch64_relocate_instruction): Likewise.
4966 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
4967 (struct aarch64_insn_visitor): Likewise.
4968
4969 2015-10-12 Yao Qi <yao.qi@linaro.org>
4970
4971 * linux-aarch64-low.c (struct aarch64_insn_data): New.
4972 (struct aarch64_insn_visitor): New.
4973 (struct aarch64_insn_relocation_data): New.
4974 (aarch64_ftrace_insn_reloc_b): New function.
4975 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
4976 (aarch64_ftrace_insn_reloc_cb): Likewise.
4977 (aarch64_ftrace_insn_reloc_tb): Likewise.
4978 (aarch64_ftrace_insn_reloc_adr): Likewise.
4979 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
4980 (aarch64_ftrace_insn_reloc_others): Likewise.
4981 (visitor): New.
4982 (aarch64_relocate_instruction): Use visitor.
4983
4984 2015-10-12 Yao Qi <yao.qi@linaro.org>
4985
4986 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
4987 int. Add argument buf.
4988 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
4989 aarch64_relocate_instruction.
4990
4991 2015-10-12 Yao Qi <yao.qi@linaro.org>
4992
4993 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
4994 argument insn. Remove local variable insn. Don't call
4995 target_read_uint32.
4996 (aarch64_install_fast_tracepoint_jump_pad): Call
4997 target_read_uint32.
4998
4999 2015-09-30 Yao Qi <yao.qi@linaro.org>
5000
5001 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5002 (emit_load_store_pair): Likewise.
5003
5004 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5005
5006 * dll.c (match_dll): Add cast(s).
5007 (unloaded_dll): Likewise.
5008 * linux-low.c (second_thread_of_pid_p): Likewise.
5009 (delete_lwp_callback): Likewise.
5010 (count_events_callback): Likewise.
5011 (select_event_lwp_callback): Likewise.
5012 (linux_set_resume_request): Likewise.
5013 * server.c (accumulate_file_name_length): Likewise.
5014 (emit_dll_description): Likewise.
5015 (handle_qxfer_threads_worker): Likewise.
5016 (visit_actioned_threads): Likewise.
5017 * thread-db.c (any_thread_of): Likewise.
5018 * tracepoint.c (same_process_p): Likewise.
5019 (match_blocktype): Likewise.
5020 (build_traceframe_info_xml): Likewise.
5021
5022 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5023
5024 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5025 assignment.
5026 (gdb_unparse_agent_expr): Likewise.
5027 * hostio.c (require_data): Likewise.
5028 (handle_pread): Likewise.
5029 * linux-low.c (disable_regset): Likewise.
5030 (fetch_register): Likewise.
5031 (store_register): Likewise.
5032 (get_dynamic): Likewise.
5033 (linux_qxfer_libraries_svr4): Likewise.
5034 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5035 (set_fast_tracepoint_jump): Likewise.
5036 (uninsert_fast_tracepoint_jumps_at): Likewise.
5037 (reinsert_fast_tracepoint_jumps_at): Likewise.
5038 (validate_inserted_breakpoint): Likewise.
5039 (clone_agent_expr): Likewise.
5040 * regcache.c (init_register_cache): Likewise.
5041 * remote-utils.c (putpkt_binary_1): Likewise.
5042 (decode_M_packet): Likewise.
5043 (decode_X_packet): Likewise.
5044 (look_up_one_symbol): Likewise.
5045 (relocate_instruction): Likewise.
5046 (monitor_output): Likewise.
5047 * server.c (handle_search_memory): Likewise.
5048 (handle_qxfer_exec_file): Likewise.
5049 (handle_qxfer_libraries): Likewise.
5050 (handle_qxfer): Likewise.
5051 (handle_query): Likewise.
5052 (handle_v_cont): Likewise.
5053 (handle_v_run): Likewise.
5054 (captured_main): Likewise.
5055 * target.c (write_inferior_memory): Likewise.
5056 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5057 * tracepoint.c (init_trace_buffer): Likewise.
5058 (add_tracepoint_action): Likewise.
5059 (add_traceframe): Likewise.
5060 (add_traceframe_block): Likewise.
5061 (cmd_qtdpsrc): Likewise.
5062 (cmd_qtdv): Likewise.
5063 (cmd_qtstatus): Likewise.
5064 (response_source): Likewise.
5065 (response_tsv): Likewise.
5066 (cmd_qtnotes): Likewise.
5067 (gdb_collect): Likewise.
5068 (initialize_tracepoint): Likewise.
5069
5070 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5071
5072 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5073 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5074 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5075 <NOP>: New.
5076 (enum aarch64_condition_codes): New enum.
5077 (w0): New static global.
5078 (fp): Likewise.
5079 (lr): Likewise.
5080 (struct aarch64_memory_operand) <type>: New
5081 MEMORY_OPERAND_POSTINDEX type.
5082 (postindex_memory_operand): New helper function.
5083 (emit_ret): New function.
5084 (emit_load_store_pair): New function, factored out of emit_stp
5085 with support for MEMORY_OPERAND_POSTINDEX.
5086 (emit_stp): Rewrite using emit_load_store_pair.
5087 (emit_ldp): New function.
5088 (emit_load_store): Likewise.
5089 (emit_ldr): Mention post-index instruction in comment.
5090 (emit_ldrh): New function.
5091 (emit_ldrb): New function.
5092 (emit_ldrsw): Mention post-index instruction in comment.
5093 (emit_str): Likewise.
5094 (emit_subs): New function.
5095 (emit_cmp): Likewise.
5096 (emit_and): Likewise.
5097 (emit_orr): Likewise.
5098 (emit_orn): Likewise.
5099 (emit_eor): Likewise.
5100 (emit_mvn): Likewise.
5101 (emit_lslv): Likewise.
5102 (emit_lsrv): Likewise.
5103 (emit_asrv): Likewise.
5104 (emit_mul): Likewise.
5105 (emit_sbfm): Likewise.
5106 (emit_sbfx): Likewise.
5107 (emit_ubfm): Likewise.
5108 (emit_ubfx): Likewise.
5109 (emit_csinc): Likewise.
5110 (emit_cset): Likewise.
5111 (emit_nop): Likewise.
5112 (emit_ops_insns): New helper function.
5113 (emit_pop): Likewise.
5114 (emit_push): Likewise.
5115 (aarch64_emit_prologue): New function.
5116 (aarch64_emit_epilogue): Likewise.
5117 (aarch64_emit_add): Likewise.
5118 (aarch64_emit_sub): Likewise.
5119 (aarch64_emit_mul): Likewise.
5120 (aarch64_emit_lsh): Likewise.
5121 (aarch64_emit_rsh_signed): Likewise.
5122 (aarch64_emit_rsh_unsigned): Likewise.
5123 (aarch64_emit_ext): Likewise.
5124 (aarch64_emit_log_not): Likewise.
5125 (aarch64_emit_bit_and): Likewise.
5126 (aarch64_emit_bit_or): Likewise.
5127 (aarch64_emit_bit_xor): Likewise.
5128 (aarch64_emit_bit_not): Likewise.
5129 (aarch64_emit_equal): Likewise.
5130 (aarch64_emit_less_signed): Likewise.
5131 (aarch64_emit_less_unsigned): Likewise.
5132 (aarch64_emit_ref): Likewise.
5133 (aarch64_emit_if_goto): Likewise.
5134 (aarch64_emit_goto): Likewise.
5135 (aarch64_write_goto_address): Likewise.
5136 (aarch64_emit_const): Likewise.
5137 (aarch64_emit_call): Likewise.
5138 (aarch64_emit_reg): Likewise.
5139 (aarch64_emit_pop): Likewise.
5140 (aarch64_emit_stack_flush): Likewise.
5141 (aarch64_emit_zero_ext): Likewise.
5142 (aarch64_emit_swap): Likewise.
5143 (aarch64_emit_stack_adjust): Likewise.
5144 (aarch64_emit_int_call_1): Likewise.
5145 (aarch64_emit_void_call_2): Likewise.
5146 (aarch64_emit_eq_goto): Likewise.
5147 (aarch64_emit_ne_goto): Likewise.
5148 (aarch64_emit_lt_goto): Likewise.
5149 (aarch64_emit_le_goto): Likewise.
5150 (aarch64_emit_gt_goto): Likewise.
5151 (aarch64_emit_ge_got): Likewise.
5152 (aarch64_emit_ops_impl): New static global variable.
5153 (aarch64_emit_ops): New target function, return
5154 &aarch64_emit_ops_impl.
5155 (struct linux_target_ops): Install it.
5156
5157 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5158
5159 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5160 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5161 aarch64-ipa.o.
5162 * linux-aarch64-ipa.c: New file.
5163 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5164 and endian.h.
5165 (aarch64_get_thread_area): New target method.
5166 (extract_signed_bitfield): New helper function.
5167 (aarch64_decode_ldr_literal): New function.
5168 (enum aarch64_opcodes): New enum.
5169 (struct aarch64_register): New struct.
5170 (struct aarch64_operand): New struct.
5171 (x0): New static global.
5172 (x1): Likewise.
5173 (x2): Likewise.
5174 (x3): Likewise.
5175 (x4): Likewise.
5176 (w2): Likewise.
5177 (ip0): Likewise.
5178 (sp): Likewise.
5179 (xzr): Likewise.
5180 (aarch64_register): New helper function.
5181 (register_operand): Likewise.
5182 (immediate_operand): Likewise.
5183 (struct aarch64_memory_operand): New struct.
5184 (offset_memory_operand): New helper function.
5185 (preindex_memory_operand): Likewise.
5186 (enum aarch64_system_control_registers): New enum.
5187 (ENCODE): New macro.
5188 (emit_insn): New helper function.
5189 (emit_b): New function.
5190 (emit_bcond): Likewise.
5191 (emit_cb): Likewise.
5192 (emit_tb): Likewise.
5193 (emit_blr): Likewise.
5194 (emit_stp): Likewise.
5195 (emit_ldp_q_offset): Likewise.
5196 (emit_stp_q_offset): Likewise.
5197 (emit_load_store): Likewise.
5198 (emit_ldr): Likewise.
5199 (emit_ldrsw): Likewise.
5200 (emit_str): Likewise.
5201 (emit_ldaxr): Likewise.
5202 (emit_stxr): Likewise.
5203 (emit_stlr): Likewise.
5204 (emit_data_processing_reg): Likewise.
5205 (emit_data_processing): Likewise.
5206 (emit_add): Likewise.
5207 (emit_sub): Likewise.
5208 (emit_mov): Likewise.
5209 (emit_movk): Likewise.
5210 (emit_mov_addr): Likewise.
5211 (emit_mrs): Likewise.
5212 (emit_msr): Likewise.
5213 (emit_sevl): Likewise.
5214 (emit_wfe): Likewise.
5215 (append_insns): Likewise.
5216 (can_encode_int32_in): New helper function.
5217 (aarch64_relocate_instruction): New function.
5218 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5219 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5220 (struct linux_target_ops): Install aarch64_get_thread_area,
5221 aarch64_install_fast_tracepoint_jump_pad and
5222 aarch64_get_min_fast_tracepoint_insn_len.
5223
5224 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5225
5226 * Makefile.in (aarch64-insn.o): New rule.
5227 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5228
5229 2015-09-21 Yao Qi <yao.qi@linaro.org>
5230
5231 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5232
5233 2015-09-21 Yao Qi <yao.qi@linaro.org>
5234
5235 * tracepoint.c (max_jump_pad_size): Remove.
5236
5237 2015-09-18 Yao Qi <yao.qi@linaro.org>
5238
5239 * linux-aarch64-low.c: Don't include sys/uio.h.
5240 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5241
5242 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5243
5244 * tracepoint.c (eval_result_type): Change prototype.
5245 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5246
5247 2015-09-15 Pedro Alves <palves@redhat.com>
5248
5249 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5250 Check whether to report exec events instead of checking whether
5251 multiprocess is enabled.
5252
5253 2015-09-15 Pedro Alves <palves@redhat.com>
5254
5255 PR remote/18965
5256 * remote-utils.c (prepare_resume_reply): Merge
5257 TARGET_WAITKIND_VFORK_DONE switch case with the
5258 TARGET_WAITKIND_FORKED case.
5259
5260 2015-09-15 Yao Qi <yao.qi@linaro.org>
5261
5262 * server.c (handle_query): Check string comparison using
5263 "else if" instead of "if".
5264
5265 2015-09-15 Yao Qi <yao.qi@linaro.org>
5266
5267 * server.c (vCont_supported): New global variable.
5268 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5269 matches. Append ";vContSupported+" to own_buf.
5270 (handle_v_requests): Append ";s;S" to own_buf if target supports
5271 hardware single step or vCont_supported is false.
5272 (capture_main): Set vCont_supported to zero.
5273
5274 2015-09-15 Yao Qi <yao.qi@linaro.org>
5275
5276 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5277 it to ...
5278 (linux_supports_hardware_single_step): ... New function.
5279 (linux_target_ops): Update.
5280 * lynx-low.c (lynx_target_ops): Set field
5281 supports_hardware_single_step to target_can_do_hardware_single_step.
5282 * nto-low.c (nto_target_ops): Likewise.
5283 * spu-low.c (spu_target_ops): Likewise.
5284 * win32-low.c (win32_target_ops): Likewise.
5285 * target.c (target_can_do_hardware_single_step): New function.
5286 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5287 Remove. <supports_hardware_single_step>: New field.
5288 (target_supports_conditional_breakpoints): Remove.
5289 (target_supports_hardware_single_step): New macro.
5290 (target_can_do_hardware_single_step): Declare.
5291 * server.c (handle_query): Use target_supports_hardware_single_step
5292 instead of target_supports_conditional_breakpoints.
5293
5294 2015-09-15 Yao Qi <yao.qi@linaro.org>
5295
5296 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5297 function.
5298 (struct linux_target_ops the_low_target): Install
5299 aarch64_linux_siginfo_fixup.
5300
5301 2015-09-11 Don Breazeal <donb@codesourcery.com>
5302 Luis Machado <lgustavo@codesourcery.com>
5303
5304 * linux-low.c (linux_mourn): Static declaration.
5305 (linux_arch_setup): Move in front of
5306 handle_extended_wait.
5307 (linux_arch_setup_thread): New function.
5308 (handle_extended_wait): Handle exec events. Call
5309 linux_arch_setup_thread. Make event_lwp argument a
5310 pointer-to-a-pointer.
5311 (check_zombie_leaders): Do not check stopped threads.
5312 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5313 (linux_low_filter_event): Add lwp and thread for exec'ing
5314 non-leader thread if leader thread has been deleted.
5315 Refactor code into linux_arch_setup_thread and call it.
5316 Pass child lwp pointer by reference to handle_extended_wait.
5317 (linux_wait_for_event_filtered): Update comment.
5318 (linux_wait_1): Prevent clobbering exec event status.
5319 (linux_supports_exec_events): New function.
5320 (linux_target_ops) <supports_exec_events>: Initialize new member.
5321 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5322 new member.
5323 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5324 * server.c (report_exec_events): New global variable.
5325 (handle_query): Handle qSupported query for exec-events feature.
5326 (captured_main): Initialize report_exec_events.
5327 * server.h (report_exec_events): Declare new global variable.
5328 * target.h (struct target_ops) <supports_exec_events>: New
5329 member.
5330 (target_supports_exec_events): New macro.
5331 * win32-low.c (win32_target_ops) <supports_exec_events>:
5332 Initialize new member.
5333
5334 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5335
5336 * linux-low.c (linux_low_enable_btrace): Remove.
5337 (linux_target_ops): Replace linux_low_enable_btrace with
5338 linux_enable_btrace.
5339
5340 2015-09-03 Yao Qi <yao.qi@linaro.org>
5341
5342 * linux-aarch64-low.c (aarch64_insert_point): Call
5343 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5344 returns true.
5345
5346 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5347
5348 * linux-low.c (check_stopped_by_breakpoint): Use
5349 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5350
5351 2015-08-27 Pedro Alves <palves@redhat.com>
5352
5353 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5354
5355 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5356
5357 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5358 the XNEW-family equivalent.
5359 (compile_bytecodes): Likewise.
5360 * dll.c (loaded_dll): Likewise.
5361 * event-loop.c (append_callback_event): Likewise.
5362 (create_file_handler): Likewise.
5363 (create_file_event): Likewise.
5364 * hostio.c (handle_open): Likewise.
5365 * inferiors.c (add_thread): Likewise.
5366 (add_process): Likewise.
5367 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5368 * linux-arm-low.c (arm_new_process): Likewise.
5369 (arm_new_thread): Likewise.
5370 * linux-low.c (add_to_pid_list): Likewise.
5371 (linux_add_process): Likewise.
5372 (handle_extended_wait): Likewise.
5373 (add_lwp): Likewise.
5374 (enqueue_one_deferred_signal): Likewise.
5375 (enqueue_pending_signal): Likewise.
5376 (linux_resume_one_lwp_throw): Likewise.
5377 (linux_resume_one_thread): Likewise.
5378 (linux_read_memory): Likewise.
5379 (linux_write_memory): Likewise.
5380 * linux-mips-low.c (mips_linux_new_process): Likewise.
5381 (mips_linux_new_thread): Likewise.
5382 (mips_add_watchpoint): Likewise.
5383 * linux-x86-low.c (initialize_low_arch): Likewise.
5384 * lynx-low.c (lynx_add_process): Likewise.
5385 * mem-break.c (set_raw_breakpoint_at): Likewise.
5386 (set_breakpoint): Likewise.
5387 (add_condition_to_breakpoint): Likewise.
5388 (add_commands_to_breakpoint): Likewise.
5389 (clone_agent_expr): Likewise.
5390 (clone_one_breakpoint): Likewise.
5391 * regcache.c (new_register_cache): Likewise.
5392 * remote-utils.c (look_up_one_symbol): Likewise.
5393 * server.c (queue_stop_reply): Likewise.
5394 (start_inferior): Likewise.
5395 (queue_stop_reply_callback): Likewise.
5396 (handle_target_event): Likewise.
5397 * spu-low.c (fetch_ppc_memory): Likewise.
5398 (store_ppc_memory): Likewise.
5399 * target.c (set_target_ops): Likewise.
5400 * thread-db.c (thread_db_load_search): Likewise.
5401 (try_thread_db_load_1): Likewise.
5402 * tracepoint.c (add_tracepoint): Likewise.
5403 (add_tracepoint_action): Likewise.
5404 (create_trace_state_variable): Likewise.
5405 (cmd_qtdpsrc): Likewise.
5406 (cmd_qtro): Likewise.
5407 (add_while_stepping_state): Likewise.
5408 * win32-low.c (child_add_thread): Likewise.
5409 (get_image_name): Likewise.
5410
5411 2015-08-25 Yao Qi <yao.qi@linaro.org>
5412
5413 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5414
5415 2015-08-25 Yao Qi <yao.qi@linaro.org>
5416
5417 * Makefile.in (aarch64-linux.o): New rule.
5418 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5419 srv_tgtobj.
5420 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5421 (aarch64_init_debug_reg_state): Make it extern.
5422 (aarch64_linux_prepare_to_resume): Remove.
5423
5424 2015-08-25 Yao Qi <yao.qi@linaro.org>
5425
5426 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5427 lwp_arch_private_info and ptid_of_lwp.
5428
5429 2015-08-25 Yao Qi <yao.qi@linaro.org>
5430
5431 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5432 Find proc_info by find_process_pid. All callers updated.
5433
5434 2015-08-25 Yao Qi <yao.qi@linaro.org>
5435
5436 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5437 Remove.
5438 (debug_reg_change_callback): Remove.
5439 (aarch64_notify_debug_reg_change): Remove.
5440
5441 2015-08-25 Yao Qi <yao.qi@linaro.org>
5442
5443 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5444 Call current_lwp_ptid.
5445
5446 2015-08-25 Yao Qi <yao.qi@linaro.org>
5447
5448 * linux-aarch64-low.c (debug_reg_change_callback): Use
5449 debug_printf.
5450
5451 2015-08-25 Yao Qi <yao.qi@linaro.org>
5452
5453 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5454
5455 2015-08-25 Yao Qi <yao.qi@linaro.org>
5456
5457 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5458
5459 2015-08-25 Yao Qi <yao.qi@linaro.org>
5460
5461 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5462 the code.
5463
5464 2015-08-25 Yao Qi <yao.qi@linaro.org>
5465
5466 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5467 Remove.
5468 (debug_reg_change_callback): Remove argument entry and add argument
5469 lwp. Remove local variable thread. Don't print thread id in the
5470 debugging output. Don't check whether pid of thread equals to pid.
5471 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5472 iterate_over_lwps instead find_inferior.
5473
5474 2015-08-24 Pedro Alves <palves@redhat.com>
5475
5476 * inferiors.c (get_first_process): New function.
5477 * inferiors.h (get_first_process): New declaration.
5478 * remote-utils.c (read_ptid): Default to the first process in the
5479 list, instead of to the current thread's process.
5480
5481 2015-08-24 Pedro Alves <palves@redhat.com>
5482
5483 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5484 * event-loop.c: Likewise.
5485 * remote-utils.c: Likewise.
5486 * tracepoint.c: Likewise.
5487
5488 2015-08-24 Pedro Alves <palves@redhat.com>
5489
5490 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5491 ptid_get_lwp.
5492
5493 2015-08-21 Pedro Alves <palves@redhat.com>
5494
5495 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5496 instead of literal 1.
5497
5498 2015-08-21 Pedro Alves <palves@redhat.com>
5499
5500 * tdesc.c (default_description): Explicitly zero-initialize.
5501
5502 2015-08-21 Pedro Alves <palves@redhat.com>
5503
5504 PR gdb/18749
5505 * inferiors.c (remove_thread): Discard any pending stop reply for
5506 this thread.
5507 * server.c (remove_all_on_match_pid): Rename to ...
5508 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5509 instead of a pid.
5510 (discard_queued_stop_replies): Change parameter to a ptid. Now
5511 extern.
5512 (handle_v_kill, kill_inferior_callback, captured_main)
5513 (process_serial_event): Adjust.
5514 * server.h (discard_queued_stop_replies): Declare.
5515
5516 2015-08-21 Pedro Alves <palves@redhat.com>
5517
5518 * linux-low.c (wait_for_sigstop): Always switch to no thread
5519 selected if the previously current thread dies.
5520 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5521 process instead of the current thread's.
5522 * remote-utils.c (input_interrupt): Don't check if there's no
5523 current thread.
5524 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5525 current thread to the general thread fails, error out.
5526 (handle_qxfer_auxv, handle_qxfer_libraries)
5527 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5528 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5529 (handle_query): Check if there's a thread selected instead of
5530 checking whether there's any thread in the thread list.
5531 (handle_qxfer_threads, handle_qxfer_btrace)
5532 (handle_qxfer_btrace_conf): Don't error out early if there's no
5533 thread in the thread list.
5534 (handle_v_cont, myresume): Don't set the current thread to the
5535 continue thread.
5536 (process_serial_event) <Hg handling>: Also set thread_id if the
5537 previous general thread is still alive.
5538 (process_serial_event) <g/G handling>: If setting the current
5539 thread to the general thread fails, error out.
5540 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5541 thread's lwp instead of the current thread's.
5542 * target.c (set_desired_thread): If the desired thread was not
5543 found, leave the current thread pointing to NULL. Return an int
5544 (boolean) indicating success.
5545 * target.h (set_desired_thread): Change return type to int.
5546
5547 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5548
5549 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5550 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5551 #includes.
5552 (ps_get_thread_area): New function.
5553
5554 2015-08-19 Gary Benson <gbenson@redhat.com>
5555
5556 * hostio.c (handle_pread): Do not attempt to read more data
5557 than hostio_reply_with_data can fit in a packet.
5558
5559 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5560
5561 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5562
5563 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5564
5565 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5566
5567 2015-08-06 Pedro Alves <palves@redhat.com>
5568
5569 * tracepoint.c (expr_eval_result): Now an int.
5570
5571 2015-08-06 Pedro Alves <palves@redhat.com>
5572
5573 * gdbthread.h (struct regcache): Forward declare.
5574 (struct thread_info) <regcache_data>: Now a struct regcache
5575 pointer.
5576 * inferiors.c (inferior_regcache_data)
5577 (set_inferior_regcache_data): Now work with struct regcache
5578 pointers.
5579 * inferiors.h (struct regcache): Forward declare.
5580 (inferior_regcache_data, set_inferior_regcache_data): Now work
5581 with struct regcache pointers.
5582 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
5583 (free_register_cache_thread): Remove struct regcache pointer
5584 casts.
5585
5586 2015-08-06 Pedro Alves <palves@redhat.com>
5587
5588 * server.c (captured_main): On error, print the exception message
5589 to stderr, and if run_once is set, throw a quit.
5590
5591 2015-08-06 Pedro Alves <palves@redhat.com>
5592
5593 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
5594 the current thread.
5595
5596 2015-08-06 Pedro Alves <palves@redhat.com>
5597
5598 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
5599 reading beyond the passed in buffer length.
5600
5601 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
5602
5603 * tracepoint.c (symbol_list) <required>: Remove.
5604
5605 2015-08-06 Pedro Alves <palves@redhat.com>
5606
5607 * linux-low.c (handle_extended_wait): Set the fork child's suspend
5608 count if stopping and suspending threads.
5609 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
5610 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
5611 (linux_detach): Complete an ongoing step-over.
5612 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
5613 throughout.
5614 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
5615 (linux_wait_1): If passing a signal to the inferior after
5616 finishing a step-over, unsuspend and re-resume all lwps. If we
5617 see a single-step event but the thread should be continuing, don't
5618 pass the trap to gdb.
5619 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
5620 internal_error instead of gdb_assert.
5621 (enqueue_pending_signal): New function.
5622 (check_ptrace_stopped_lwp_gone): Add debug output.
5623 (start_step_over): Use internal_error instead of gdb_assert.
5624 (complete_ongoing_step_over): New function.
5625 (linux_resume_one_thread): Don't resume a suspended thread.
5626 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
5627 it stepping.
5628
5629 2015-08-06 Pedro Alves <palves@redhat.com>
5630
5631 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
5632 (linux_thread_alive): Use lwp_is_marked_dead.
5633 (extended_event_reported): Delete.
5634 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
5635 instead of extended_event_reported.
5636 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
5637 as well.
5638 (lwp_is_marked_dead): New function.
5639 (lwp_running): Use lwp_is_marked_dead.
5640 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
5641 comment.
5642
5643 2015-08-06 Pedro Alves <palves@redhat.com>
5644
5645 * linux-low.c (linux_wait_1): Move fork event output out of the
5646 !report_to_gdb check. Pass event_child->waitstatus to
5647 target_waitstatus_to_string instead of ourstatus.
5648
5649 2015-08-04 Yao Qi <yao.qi@linaro.org>
5650
5651 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
5652 if current_thread is 32 bit.
5653
5654 2015-08-04 Yao Qi <yao.qi@linaro.org>
5655
5656 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5657 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5658 * server.c (extended_protocol): Remove "static".
5659 * server.h (extended_protocol): Declare it.
5660
5661 2015-08-04 Yao Qi <yao.qi@linaro.org>
5662
5663 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
5664 both aarch64 and aarch32.
5665 (aarch64_set_pc): Likewise.
5666
5667 2015-08-04 Yao Qi <yao.qi@linaro.org>
5668
5669 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
5670 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
5671 arm-with-neon.xml to srv_xmlfiles.
5672 * linux-aarch64-low.c: Include linux-aarch32-low.h.
5673 (is_64bit_tdesc): New function.
5674 (aarch64_linux_read_description): New function.
5675 (aarch64_arch_setup): Call aarch64_linux_read_description.
5676 (regs_info): Rename to regs_info_aarch64.
5677 (aarch64_regs_info): Return right regs_info.
5678 (initialize_low_arch): Call initialize_low_arch_aarch32.
5679
5680 2015-08-04 Yao Qi <yao.qi@linaro.org>
5681
5682 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
5683 * linux-aarch32-low.c: New file.
5684 * linux-aarch32-low.h: New file.
5685 * linux-arm-low.c (arm_fill_gregset): Move it to
5686 linux-aarch32-low.c.
5687 (arm_store_gregset): Likewise.
5688 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
5689 (arm_store_vfpregset): Call arm_store_vfpregset_num.
5690 (arm_arch_setup): Check if PTRACE_GETREGSET works.
5691 (regs_info): Rename to regs_info_arm.
5692 (arm_regs_info): Return regs_info_aarch32 if
5693 have_ptrace_getregset is 1 and target description is
5694 arm_with_neon or arm_with_vfpv3.
5695 (initialize_low_arch): Don't call init_registers_arm_with_neon.
5696 Call initialize_low_arch_aarch32 instead.
5697
5698 2015-08-04 Yao Qi <yao.qi@linaro.org>
5699
5700 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
5701 * linux-low.c: ... here.
5702 * linux-low.h (have_ptrace_getregset): Declare it.
5703
5704 2015-08-04 Pedro Alves <palves@redhat.com>
5705
5706 * thread-db.c (struct thread_db): Use new typedefs.
5707 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
5708 CHK calls.
5709 (disable_thread_event_reporting): Cast result of dlsym to
5710 destination function pointer type.
5711 (thread_db_mourn): Use td_ta_delete_ftype.
5712
5713 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
5714
5715 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
5716 arch variant.
5717 (CDX_BREAKPOINT): Define for R2.
5718 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
5719 (the_low_target): Add comments.
5720
5721 2015-07-30 Yao Qi <yao.qi@linaro.org>
5722
5723 * linux-arm-low.c (arm_hwcap): Remove it.
5724 (arm_read_description): New local variable arm_hwcap. Don't
5725 set arm_hwcap to zero.
5726
5727 2015-07-30 Yao Qi <yao.qi@linaro.org>
5728
5729 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
5730 Use regcache->tdesc instead.
5731 (arm_store_wmmxregset): Likewise.
5732 (arm_fill_vfpregset): Likewise.
5733 (arm_store_vfpregset): Likewise.
5734
5735 2015-07-30 Yao Qi <yao.qi@linaro.org>
5736
5737 * linux-arm-low.c: Include arch/arm.h.
5738 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
5739 (arm_store_gregset): Likewise.
5740
5741 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
5742
5743 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
5744 ptrace's 4th parameter.
5745
5746 2015-07-27 Yao Qi <yao.qi@linaro.org>
5747
5748 * configure.srv (case aarch64*-*-linux*): Don't set
5749 srv_linux_usrregs.
5750
5751 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
5752
5753 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
5754 sys/ptrace.h.
5755 * linux-arm-low.c: Likewise.
5756 * linux-cris-low.c: Likewise.
5757 * linux-crisv32-low.c: Likewise.
5758 * linux-low.c: Likewise.
5759 * linux-m68k-low.c: Likewise.
5760 * linux-mips-low.c: Likewise.
5761 * linux-nios2-low.c: Likewise.
5762 * linux-s390-low.c: Likewise.
5763 * linux-sparc-low.c: Likewise.
5764 * linux-tic6x-low.c: Likewise.
5765 * linux-tile-low.c: Likewise.
5766 * linux-x86-low.c: Likewise.
5767
5768 2015-07-24 Pedro Alves <palves@redhat.com>
5769
5770 * config.in: Regenerate.
5771 * configure: Regenerate.
5772
5773 2015-07-24 Pedro Alves <palves@redhat.com>
5774
5775 * acinclude.m4: Include ../ptrace.m4.
5776 * configure.ac: Call GDB_AC_PTRACE.
5777 * config.in, configure: Regenerate.
5778
5779 2015-07-24 Yao Qi <yao.qi@linaro.org>
5780
5781 * linux-low.c (linux_create_inferior): Remove setting to
5782 proc->priv->new_inferior.
5783 (linux_attach): Likewise.
5784 (linux_low_filter_event): Likewise.
5785 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
5786
5787 2015-07-24 Yao Qi <yao.qi@linaro.org>
5788
5789 * linux-low.c (linux_arch_setup): New function.
5790 (linux_low_filter_event): If proc->tdesc is NULL and
5791 proc->attached is true, call the_low_target.arch_setup.
5792 Otherwise, keep status pending, and return.
5793 (linux_resume_one_lwp_throw): Don't call get_pc if
5794 thread->while_stepping isn't NULL. Don't call
5795 get_thread_regcache if proc->tdesc is NULL.
5796 (need_step_over_p): Return 0 if proc->tdesc is NULL.
5797 (linux_target_ops): Install arch_setup.
5798 * server.c (start_inferior): Call the_target->arch_setup.
5799 * target.h (struct target_ops) <arch_setup>: New field.
5800 (target_arch_setup): New marco.
5801 * lynx-low.c (lynx_target_ops): Update.
5802 * nto-low.c (nto_target_ops): Update.
5803 * spu-low.c (spu_target_ops): Update.
5804 * win32-low.c (win32_target_ops): Update.
5805
5806 2015-07-24 Yao Qi <yao.qi@linaro.org>
5807
5808 * linux-low.c (linux_add_process): Don't set
5809 proc->priv->new_inferior.
5810 (linux_create_inferior): Set proc->priv->new_inferior to 1.
5811 (linux_attach): Likewise.
5812
5813 2015-07-24 Yao Qi <yao.qi@linaro.org>
5814
5815 * server.c (start_inferior): Code refactor.
5816
5817 2015-07-24 Yao Qi <yao.qi@linaro.org>
5818
5819 * server.c (process_serial_event): Set general_thread.
5820
5821 2015-07-21 Yao Qi <yao.qi@linaro.org>
5822
5823 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
5824 aarch64_linux_get_debug_reg_capacity.
5825
5826 2015-07-17 Yao Qi <yao.qi@linaro.org>
5827
5828 * Makefile.in (aarch64-linux-hw-point.o): New rule.
5829 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
5830 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
5831 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
5832 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
5833 (AARCH64_HWP_ALIGNMENT): Likewise.
5834 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
5835 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
5836 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
5837 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
5838 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
5839 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
5840 (struct aarch64_debug_reg_state): Likewise.
5841 (struct arch_lwp_info): Likewise.
5842 (aarch64_align_watchpoint): Likewise.
5843 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
5844 (aarch64_watchpoint_length): Likewise.
5845 (aarch64_point_encode_ctrl_reg): Likewise
5846 (aarch64_point_is_aligned): Likewise.
5847 (aarch64_align_watchpoint): Likewise.
5848 (aarch64_linux_set_debug_regs):
5849 (aarch64_dr_state_insert_one_point): Likewise.
5850 (aarch64_dr_state_remove_one_point): Likewise.
5851 (aarch64_handle_breakpoint): Likewise.
5852 (aarch64_handle_aligned_watchpoint): Likewise.
5853 (aarch64_handle_unaligned_watchpoint): Likewise.
5854 (aarch64_handle_watchpoint): Likewise.
5855
5856 2015-07-17 Yao Qi <yao.qi@linaro.org>
5857
5858 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
5859 and don't aarch64_get_debug_reg_state. All callers update.
5860 (aarch64_handle_aligned_watchpoint): Likewise.
5861 (aarch64_handle_unaligned_watchpoint): Likewise.
5862 (aarch64_handle_watchpoint): Likewise.
5863 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
5864 (aarch64_remove_point): Likewise.
5865
5866 2015-07-17 Yao Qi <yao.qi@linaro.org>
5867
5868 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
5869 debug_printf.
5870 (aarch64_handle_unaligned_watchpoint): Likewise.
5871
5872 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5873
5874 Revert the previous 3 commits:
5875 Move gdb_regex* to common/
5876 Move linux_find_memory_regions_full & co.
5877 gdbserver build-id attribute generator
5878
5879 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5880 Jan Kratochvil <jan.kratochvil@redhat.com>
5881
5882 gdbserver build-id attribute generator.
5883 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
5884 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
5885 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
5886 (find_phdr): New.
5887 (get_dynamic): Use find_pdhr to traverse program headers.
5888 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
5889 (compare_mapping_entry_range, struct find_memory_region_callback_data)
5890 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
5891 (get_hex_build_id): New.
5892 (linux_qxfer_libraries_svr4): Add optional build-id attribute
5893 to reply XML document.
5894
5895 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5896 Jan Kratochvil <jan.kratochvil@redhat.com>
5897
5898 * target.c: Include target/target-utils.h and fcntl.h.
5899 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
5900 (target_fileio_read_stralloc): New functions.
5901
5902 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5903
5904 * Makefile.in (OBS): Add gdb_regex.o.
5905 (gdb_regex.o): New.
5906 * config.in: Rebuilt.
5907 * configure: Rebuilt.
5908
5909 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5910 Jan Kratochvil <jan.kratochvil@redhat.com>
5911
5912 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
5913 * Makefile.in (OBS): Add target-utils.o.
5914 (linux-maps.o, target-utils.o): New.
5915 * configure.srv (srv_linux_obj): Add linux-maps.o.
5916
5917 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
5918
5919 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
5920 function, return 1.
5921 (the_low_target): Install it.
5922
5923 2015-07-14 Pedro Alves <palves@redhat.com>
5924
5925 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
5926 Instead, ignore ECHILD, and throw an error for other errnos.
5927
5928 2015-07-10 Pedro Alves <palves@redhat.com>
5929
5930 * event-loop.c (struct callback_event) <data>: Change type to
5931 gdb_client_data instance instead of gdb_client_data pointer.
5932 (append_callback_event): Adjust.
5933
5934 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
5935
5936 * linux-aarch64-low.c: Add comments for each linux_target_ops
5937 method. Remove comments already covered in target_ops and
5938 linux_target_ops definitions.
5939 (the_low_target): Add comments for each unimplemented method.
5940
5941 2015-07-09 Yao Qi <yao.qi@linaro.org>
5942
5943 * linux-aarch64-low.c (aarch64_regmap): Remove.
5944 (aarch64_usrregs_info): Remove.
5945 (regs_info): Set field usrregs to NULL.
5946
5947 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
5948
5949 * linux-low.c: Include "rsp-low.h"
5950 (linux_low_encode_pt_config, linux_low_encode_raw): New.
5951 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
5952 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
5953 (handle_btrace_enable_pt): New.
5954 (handle_btrace_general_set): Support "pt".
5955 (handle_btrace_conf_general_set): Support "pt:size".
5956
5957 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5958
5959 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
5960 Z_PACKET_SW_BP.
5961
5962 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5963
5964 * linux-aarch64-low.c: Remove comment about endianness.
5965 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
5966 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
5967 memcmp.
5968
5969 2015-06-24 Gary Benson <gbenson@redhat.com>
5970
5971 * linux-i386-ipa.c (stdint.h): Do not include.
5972 * lynx-i386-low.c (stdint.h): Likewise.
5973 * lynx-ppc-low.c (stdint.h): Likewise.
5974 * mem-break.c (stdint.h): Likewise.
5975 * thread-db.c (stdint.h): Likewise.
5976 * tracepoint.c (stdint.h): Likewise.
5977 * win32-low.c (stdint.h): Likewise.
5978
5979 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
5980
5981 * server.c (write_qxfer_response): Update call to
5982 remote_escape_output.
5983
5984 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
5985 Jan Kratochvil <jan.kratochvil@redhat.com>
5986
5987 Merge multiple hex conversions.
5988 * gdbreplay.c (tohex): Rename to 'fromhex'.
5989 (logchar): Use fromhex.
5990
5991 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
5992
5993 * server.c (handle_qxfer_libraries): Set `version' attribute for
5994 <library-list>.
5995
5996 2015-06-10 Gary Benson <gbenson@redhat.com>
5997
5998 * target.h (struct target_ops) <multifs_open>: New field.
5999 <multifs_unlink>: Likewise.
6000 <multifs_readlink>: Likewise.
6001 * linux-low.c (nat/linux-namespaces.h): New include.
6002 (linux_target_ops): Initialize the_target->multifs_open,
6003 the_target->multifs_unlink and the_target->multifs_readlink.
6004 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6005 * hostio.c (hostio_fs_pid): New static variable.
6006 (hostio_handle_new_gdb_connection): New function.
6007 (handle_setfs): Likewise.
6008 (handle_open): Use the_target->multifs_open as appropriate.
6009 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6010 (handle_readlink): Use the_target->multifs_readlink as
6011 appropriate.
6012 (handle_vFile): Handle vFile:setfs packets.
6013 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6014 after target_handle_new_gdb_connection.
6015
6016 2015-06-10 Gary Benson <gbenson@redhat.com>
6017
6018 * configure.ac (AC_CHECK_FUNCS): Add setns.
6019 * config.in: Regenerate.
6020 * configure: Likewise.
6021 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6022 (linux-namespaces.o): New rule.
6023 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6024
6025 2015-06-09 Gary Benson <gbenson@redhat.com>
6026
6027 * hostio.c (handle_open): Process mode argument with
6028 fileio_to_host_mode.
6029
6030 2015-06-01 Yao Qi <yao.qi@linaro.org>
6031
6032 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6033 * linux-x86-low.c: Likewise.
6034
6035 2015-05-28 Don Breazeal <donb@codesourcery.com>
6036
6037 * linux-low.c (handle_extended_wait): Initialize
6038 thread_info.last_resume_kind for new fork children.
6039
6040 2015-05-15 Pedro Alves <palves@redhat.com>
6041
6042 * target.h (target_handle_new_gdb_connection): Rewrite using if
6043 wrapped in do/while.
6044
6045 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6046
6047 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6048 * configure, config.in: Regenerate.
6049 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6050 Declare typedef.
6051
6052 2015-05-12 Don Breazeal <donb@codesourcery.com>
6053
6054 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6055 PTRACE_EVENT_VFORK_DONE.
6056 (linux_low_ptrace_options, extended_event_reported): Add vfork
6057 events.
6058 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6059 and "vforkdone" for RSP 'T' Stop Reply Packet.
6060 * server.h (report_vfork_events): Declare
6061 global variable.
6062
6063 2015-05-12 Don Breazeal <donb@codesourcery.com>
6064
6065 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6066 (the_low_target) <new_fork>: Initialize new member.
6067 * linux-arm-low.c (arm_new_fork): New function.
6068 (the_low_target) <new_fork>: Initialize new member.
6069 * linux-low.c (handle_extended_wait): Call new target function
6070 new_fork.
6071 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6072 * linux-mips-low.c (mips_add_watchpoint): New function
6073 extracted from mips_insert_point.
6074 (the_low_target) <new_fork>: Initialize new member.
6075 (mips_linux_new_fork): New function.
6076 (mips_insert_point): Call mips_add_watchpoint.
6077 * linux-x86-low.c (x86_linux_new_fork): New function.
6078 (the_low_target) <new_fork>: Initialize new member.
6079
6080 2015-05-12 Don Breazeal <donb@codesourcery.com>
6081
6082 * linux-low.c (handle_extended_wait): Implement return value,
6083 rename argument 'event_child' to 'event_lwp', handle
6084 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6085 (linux_low_ptrace_options): New function.
6086 (linux_low_filter_event): Call linux_low_ptrace_options,
6087 use different argument fo linux_enable_event_reporting,
6088 use return value from handle_extended_wait.
6089 (extended_event_reported): New function.
6090 (linux_wait_1): Call extended_event_reported and set
6091 status to report fork events.
6092 (linux_write_memory): Add pid to debug message.
6093 (reset_lwp_ptrace_options_callback): New function.
6094 (linux_handle_new_gdb_connection): New function.
6095 (linux_target_ops): Initialize new structure member.
6096 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6097 * lynx-low.c: Initialize new structure member.
6098 * remote-utils.c (prepare_resume_reply): Implement stop reason
6099 "fork" for "T" stop message.
6100 * server.c (handle_query): Call handle_new_gdb_connection.
6101 * server.h (report_fork_events): Declare global flag.
6102 * target.h (struct target_ops) <handle_new_gdb_connection>:
6103 New member.
6104 (target_handle_new_gdb_connection): New macro.
6105 * win32-low.c: Initialize new structure member.
6106
6107 2015-05-12 Don Breazeal <donb@codesourcery.com>
6108
6109 * mem-break.c (APPEND_TO_LIST): Define macro.
6110 (clone_agent_expr): New function.
6111 (clone_one_breakpoint): New function.
6112 (clone_all_breakpoints): New function.
6113 * mem-break.h: Declare new functions.
6114
6115 2015-05-12 Don Breazeal <donb@codesourcery.com>
6116
6117 * linux-low.c (linux_supports_fork_events): New function.
6118 (linux_supports_vfork_events): New function.
6119 (linux_target_ops): Initialize new structure members.
6120 (initialize_low): Call linux_check_ptrace_features.
6121 * lynx-low.c (lynx_target_ops): Initialize new structure
6122 members.
6123 * server.c (report_fork_events, report_vfork_events):
6124 New global flags.
6125 (handle_query): Add new features to qSupported packet and
6126 response.
6127 (captured_main): Initialize new global variables.
6128 * target.h (struct target_ops) <supports_fork_events>:
6129 New member.
6130 <supports_vfork_events>: New member.
6131 (target_supports_fork_events): New macro.
6132 (target_supports_vfork_events): New macro.
6133 * win32-low.c (win32_target_ops): Initialize new structure
6134 members.
6135
6136 2015-05-12 Gary Benson <gbenson@redhat.com>
6137
6138 * server.c (handle_qxfer_exec_file): Use current process
6139 if annex is empty.
6140
6141 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6142
6143 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6144 Remove HAVE_PTRACE_GETREGS conditionals.
6145 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6146 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6147
6148 2015-05-08 Yao Qi <yao.qi@linaro.org>
6149
6150 * linux-low.c (linux_supports_conditional_breakpoints): New
6151 function.
6152 (linux_target_ops): Install new target method.
6153 * lynx-low.c (lynx_target_ops): Install NULL hook for
6154 supports_conditional_breakpoints.
6155 * nto-low.c (nto_target_ops): Likewise.
6156 * spu-low.c (spu_target_ops): Likewise.
6157 * win32-low.c (win32_target_ops): Likewise.
6158 * server.c (handle_query): Check
6159 target_supports_conditional_breakpoints.
6160 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6161 New field.
6162 (target_supports_conditional_breakpoints): New macro.
6163
6164 2015-05-06 Pedro Alves <palves@redhat.com>
6165
6166 PR server/18081
6167 * server.c (start_inferior): If the process exits, mourn it.
6168
6169 2015-04-21 Gary Benson <gbenson@redhat.com>
6170
6171 * hostio.c (fileio_open_flags_to_host): Factored out to
6172 fileio_to_host_openflags in common/fileio.c. Single use
6173 updated.
6174
6175 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6176
6177 * linux-xtensa-low.c (xtensa_fill_gregset)
6178 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6179 XCHAL_HAVE_LOOP.
6180
6181 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6182
6183 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6184 (regs_info): Replace usrregs pointer with NULL.
6185
6186 2015-04-17 Gary Benson <gbenson@redhat.com>
6187
6188 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6189 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6190 * server.c (handle_qxfer_exec_file): New function.
6191 (qxfer_packets): Add exec-file entry.
6192 (handle_query): Report qXfer:exec-file:read as supported packet.
6193
6194 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6195
6196 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6197
6198 2015-04-09 Gary Benson <gbenson@redhat.com>
6199
6200 * hostio-errno.c (errno_to_fileio_error): Remove function.
6201 Update caller to use remote_fileio_to_fio_error.
6202
6203 2015-04-09 Yao Qi <yao.qi@linaro.org>
6204
6205 * linux-low.c (linux_insert_point): Call
6206 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6207 (linux_remove_point): Call remove_memory_breakpoint if type is
6208 raw_bkpt_type_sw.
6209 * linux-x86-low.c (x86_insert_point): Don't call
6210 insert_memory_breakpoint.
6211 (x86_remove_point): Don't call remove_memory_breakpoint.
6212
6213 2015-04-01 Pedro Alves <palves@redhat.com>
6214 Cleber Rosa <crosa@redhat.com>
6215
6216 * server.c (gdbserver_usage): Reorganize and extend the usage
6217 message.
6218
6219 2015-03-24 Pedro Alves <palves@redhat.com>
6220
6221 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6222 output. Also dump TRAP_TRACE.
6223 (linux_low_filter_event): In debug output, distinguish a
6224 resume_stop SIGSTOP from a delayed SIGSTOP.
6225
6226 2015-03-24 Gary Benson <gbenson@redhat.com>
6227
6228 * linux-x86-low.c (x86_linux_new_thread): Moved to
6229 nat/x86-linux.c.
6230 (x86_linux_prepare_to_resume): Likewise.
6231
6232 2015-03-24 Gary Benson <gbenson@redhat.com>
6233
6234 * Makefile.in (x86-linux-dregs.o): New rule.
6235 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6236 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6237 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6238 (x86_linux_dr_get): Likewise.
6239 (x86_linux_dr_set): Likewise.
6240 (update_debug_registers_callback): Likewise.
6241 (x86_linux_dr_set_addr): Likewise.
6242 (x86_linux_dr_get_addr): Likewise.
6243 (x86_linux_dr_set_control): Likewise.
6244 (x86_linux_dr_get_control): Likewise.
6245 (x86_linux_dr_get_status): Likewise.
6246 (x86_linux_update_debug_registers): Likewise.
6247
6248 2015-03-24 Gary Benson <gbenson@redhat.com>
6249
6250 * linux-x86-low.c (x86_linux_update_debug_registers):
6251 New function, factored out from...
6252 (x86_linux_prepare_to_resume): ...this.
6253
6254 2015-03-24 Gary Benson <gbenson@redhat.com>
6255
6256 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6257 (x86_linux_dr_set): Likewise.
6258 (update_debug_registers_callback): Likewise.
6259 (x86_linux_dr_set_addr): Likewise.
6260 (x86_linux_dr_get_addr): Likewise.
6261 (x86_linux_dr_set_control): Likewise.
6262 (x86_linux_dr_get_control): Likewise.
6263 (x86_linux_dr_get_status): Likewise.
6264 (x86_linux_prepare_to_resume): Likewise.
6265
6266 2015-03-24 Gary Benson <gbenson@redhat.com>
6267
6268 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6269 Use perror_with_name. Pass string through gettext.
6270 (x86_linux_dr_set): Likewise.
6271
6272 2015-03-24 Gary Benson <gbenson@redhat.com>
6273
6274 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6275 (x86_linux_dr_set_addr): ...this.
6276 (x86_dr_low_get_addr): Rename to...
6277 (x86_linux_dr_get_addr): ...this.
6278 (x86_dr_low_set_control): Rename to...
6279 (x86_linux_dr_set_control): ...this.
6280 (x86_dr_low_get_control): Rename to...
6281 (x86_linux_dr_get_control): ...this.
6282 (x86_dr_low_get_status): Rename to...
6283 (x86_linux_dr_get_status): ...this.
6284 (x86_dr_low): Update with new function names.
6285
6286 2015-03-24 Gary Benson <gbenson@redhat.com>
6287
6288 * Makefile.in (x86-linux.o): New rule.
6289 * configure.srv: Add x86-linux.o to relevant targets.
6290 * linux-low.c (lwp_set_arch_private_info): New function.
6291 (lwp_arch_private_info): Likewise.
6292 * linux-x86-low.c: Include nat/x86-linux.h.
6293 (arch_lwp_info): Removed structure.
6294 (update_debug_registers_callback):
6295 Use lwp_set_debug_registers_changed.
6296 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6297 and lwp_set_debug_registers_changed.
6298 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6299
6300 2015-03-24 Gary Benson <gbenson@redhat.com>
6301
6302 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6303 * linux-arm-low.c (arm_new_thread): Likewise.
6304 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6305 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6306 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6307 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6308
6309 2015-03-24 Gary Benson <gbenson@redhat.com>
6310
6311 * linux-low.c (ptid_of_lwp): New function.
6312 (lwp_is_stopped): Likewise.
6313 (lwp_stop_reason): Likewise.
6314 * linux-x86-low.c (update_debug_registers_callback):
6315 Use lwp_is_stopped.
6316 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6317 lwp_stop_reason.
6318
6319 2015-03-24 Gary Benson <gbenson@redhat.com>
6320
6321 * linux-low.h (linux_stop_lwp): Remove declaration.
6322
6323 2015-03-24 Gary Benson <gbenson@redhat.com>
6324
6325 * linux-low.h: Include nat/linux-nat.h.
6326 * linux-low.c (iterate_over_lwps_args): New structure.
6327 (iterate_over_lwps_filter): New function.
6328 (iterate_over_lwps): Likewise.
6329 * linux-x86-low.c (update_debug_registers_callback):
6330 Update signature to what iterate_over_lwps expects.
6331 Remove PID check that iterate_over_lwps now performs.
6332 (x86_dr_low_set_addr): Use iterate_over_lwps.
6333 (x86_dr_low_set_control): Likewise.
6334
6335 2015-03-24 Gary Benson <gbenson@redhat.com>
6336
6337 * linux-x86-low.c (x86_debug_reg_state): New function.
6338 (x86_linux_prepare_to_resume): Use the above.
6339
6340 2015-03-24 Gary Benson <gbenson@redhat.com>
6341
6342 * linux-low.c (current_lwp_ptid): New function.
6343 * linux-x86-low.c: Include nat/linux-nat.h.
6344 (x86_dr_low_get_addr): Use current_lwp_ptid.
6345 (x86_dr_low_get_control): Likewise.
6346 (x86_dr_low_get_status): Likewise.
6347
6348 2015-03-20 Pedro Alves <palves@redhat.com>
6349
6350 * tracepoint.c (cmd_qtstatus): Make "str" const.
6351
6352 2015-03-20 Pedro Alves <palves@redhat.com>
6353
6354 * server.c (handle_general_set): Make "req_str" const.
6355
6356 2015-03-19 Pedro Alves <palves@redhat.com>
6357
6358 * linux-low.c (linux_resume_one_lwp): Rename to ...
6359 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6360 instead call perror_with_name.
6361 (check_ptrace_stopped_lwp_gone): New function.
6362 (linux_resume_one_lwp): Reimplement as wrapper around
6363 linux_resume_one_lwp_throw that swallows errors if the LWP is
6364 gone.
6365
6366 2015-03-19 Pedro Alves <palves@redhat.com>
6367
6368 * linux-low.c (count_events_callback, select_event_lwp_callback):
6369 No longer check whether the thread has resume_stop as last resume
6370 kind.
6371
6372 2015-03-19 Pedro Alves <palves@redhat.com>
6373
6374 * linux-low.c (count_events_callback, select_event_lwp_callback):
6375 Use the lwp's status_pending_p field, not the thread's.
6376
6377 2015-03-19 Pedro Alves <palves@redhat.com>
6378
6379 * linux-low.c (select_event_lwp_callback): Update comments to
6380 no longer mention SIGTRAP.
6381
6382 2015-03-18 Gary Benson <gbenson@redhat.com>
6383
6384 * server.c (handle_query): Do not report vFile:fstat as supported.
6385
6386 2015-03-11 Gary Benson <gbenson@redhat.com>
6387
6388 * hostio.c (sys/types.h): New include.
6389 (sys/stat.h): Likewise.
6390 (common-remote-fileio.h): Likewise.
6391 (handle_fstat): New function.
6392 (handle_vFile): Handle vFile:fstat packets.
6393
6394 2015-03-11 Gary Benson <gbenson@redhat.com>
6395
6396 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6397 struct stat.st_blocks and struct stat.st_blksize.
6398 * configure: Regenerate.
6399 * config.in: Likewise.
6400 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6401 (OBS): Add common-remote-fileio.o.
6402 (common-remote-fileio.o): New rule.
6403
6404 2015-03-09 Pedro Alves <palves@redhat.com>
6405
6406 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6407 'struct sockaddr' pointer in 'accept' call.
6408
6409 2015-03-09 Pedro Alves <palves@redhat.com>
6410
6411 Revert:
6412 2015-03-07 Pedro Alves <palves@redhat.com>
6413 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6414 or <winsock2.h> here. Instead include "gdb_socket.h".
6415 (remote_open): Use union gdb_sockaddr_u.
6416 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6417 or <winsock2.h> here. Instead include "gdb_socket.h".
6418 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6419 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6420 or <sys/un.h>.
6421 (init_named_socket, gdb_agent_helper_thread): Use union
6422 gdb_sockaddr_u.
6423
6424 2015-03-07 Pedro Alves <palves@redhat.com>
6425
6426 * configure.ac (build_warnings): Move
6427 -Wdeclaration-after-statement to the C-specific set.
6428 * configure: Regenerate.
6429
6430 2015-03-07 Pedro Alves <palves@redhat.com>
6431
6432 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6433 or <winsock2.h> here. Instead include "gdb_socket.h".
6434 (remote_open): Use union gdb_sockaddr_u.
6435 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6436 or <winsock2.h> here. Instead include "gdb_socket.h".
6437 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6438 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6439 or <sys/un.h>.
6440 (init_named_socket, gdb_agent_helper_thread): Use union
6441 gdb_sockaddr_u.
6442
6443 2015-03-07 Pedro Alves <palves@redhat.com>
6444
6445 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6446 instead.
6447
6448 2015-03-06 Yao Qi <yao.qi@linaro.org>
6449
6450 * linux-aarch64-low.c (aarch64_insert_point): Use
6451 show_debug_regs as a boolean.
6452 (aarch64_remove_point): Likewise.
6453
6454 2015-03-05 Pedro Alves <palves@redhat.com>
6455
6456 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6457 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6458 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6459 * nto-low.c (nto_target_ops): Likewise.
6460 * spu-low.c (spu_target_ops): Likewise.
6461 * win32-low.c (win32_target_ops): Likewise.
6462
6463 2015-03-04 Pedro Alves <palves@redhat.com>
6464
6465 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6466 Decide whether a breakpoint triggered based on the SIGTRAP's
6467 siginfo.si_code.
6468 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6469 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6470 (linux_low_filter_event): Check for breakpoints before checking
6471 watchpoints.
6472 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6473 siginfo.si_code.
6474 (linux_stopped_by_sw_breakpoint)
6475 (linux_supports_stopped_by_sw_breakpoint)
6476 (linux_stopped_by_hw_breakpoint)
6477 (linux_supports_stopped_by_hw_breakpoint): New functions.
6478 (linux_target_ops): Install new target methods.
6479
6480 2015-03-04 Pedro Alves <palves@redhat.com>
6481
6482 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6483 * server.c (swbreak_feature, hwbreak_feature): New globals.
6484 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6485 (captured_main): Clear swbreak_feature and hwbreak_feature.
6486 * server.h (swbreak_feature, hwbreak_feature): Declare.
6487 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6488 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6489 supports_stopped_by_hw_breakpoint>: New fields.
6490 (target_supports_stopped_by_sw_breakpoint)
6491 (target_stopped_by_sw_breakpoint)
6492 (target_supports_stopped_by_hw_breakpoint)
6493 (target_stopped_by_hw_breakpoint): Declare.
6494
6495 2015-03-04 Pedro Alves <palves@redhat.com>
6496
6497 enum lwp_stop_reason -> enum target_stop_reason
6498 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6499 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6500 (linux_wait_1, stuck_in_jump_pad_callback)
6501 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6502 (linux_stopped_by_watchpoint):
6503 * linux-low.h (enum lwp_stop_reason): Delete.
6504 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6505 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6506
6507 2015-03-04 Yao Qi <yao.qi@linaro.org>
6508
6509 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6510
6511 2015-03-03 Gary Benson <gbenson@redhat.com>
6512
6513 * hostio.c (handle_vFile): Fix prefix lengths.
6514
6515 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6516
6517 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6518 ptr_bits.
6519
6520 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6521
6522 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6523 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6524 (clean): Add "rm -f" for above C files.
6525 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6526 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6527 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6528 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6529 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6530 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6531 (init_registers_s390x_vx_linux64)
6532 (init_registers_s390x_tevx_linux64)
6533 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6534 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6535 declarations.
6536 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6537 (s390_store_vxrs_high): New functions.
6538 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6539 NT_S390_VXRS_HIGH.
6540 (s390_arch_setup): Add logic for selecting one of the new target
6541 descriptions. Activate the new vector regsets if applicable.
6542 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6543 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6544 and init_registers_s390x_tevx_linux64.
6545
6546 2015-03-01 Pedro Alves <palves@redhat.com>
6547
6548 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6549 parameter.
6550
6551 2015-02-27 Pedro Alves <palves@redhat.com>
6552
6553 * linux-x86-low.c (u_debugreg_offset): New function.
6554 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6555
6556 2015-02-27 Pedro Alves <palves@redhat.com>
6557
6558 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6559 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6560 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6561 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6562 (ps_lsetfpregs, ps_getpid)
6563 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6564 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6565 (ps_lsetxregs, ps_plog): Declare.
6566
6567 2015-02-27 Pedro Alves <palves@redhat.com>
6568
6569 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6570 IP_AGENT_EXPORT_FUNC.
6571 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6572 IP_AGENT_EXPORT_FUNC.
6573 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6574 (IP_AGENT_EXPORT): Delete.
6575 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6576 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6577 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6578 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
6579 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
6580 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
6581 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
6582 (traceframe_read_count, traceframe_write_count)
6583 (traceframes_created, trace_state_variables, get_raw_reg)
6584 (get_trace_state_variable_value, set_trace_state_variable_value)
6585 (ust_loaded, helper_thread_id, cmd_buf): Use
6586 IPA_SYM_EXPORTED_NAME.
6587 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
6588 (tracepoints) Use IP_AGENT_EXPORT_VAR.
6589 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
6590 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6591 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
6592 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
6593 EXTERN_C_PUSH/EXTERN_C_POP.
6594 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
6595 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
6596 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6597 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
6598 (traceframe_write_count, traceframe_read_count)
6599 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
6600 (about_to_request_buffer_space, get_trace_state_variable_value)
6601 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
6602 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
6603 EXTERN_C_PUSH/EXTERN_C_POP.
6604 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
6605 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
6606 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
6607 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6608 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6609 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6610 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
6611 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
6612 Define.
6613 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
6614 (IP_AGENT_EXPORT_VAR_DECL): Define.
6615 (tracing): Declare.
6616 (gdb_agent_get_raw_reg): Declare.
6617
6618 2015-02-27 Tom Tromey <tromey@redhat.com>
6619 Pedro Alves <palves@redhat.com>
6620
6621 Rename symbols whose names are reserved C++ keywords throughout.
6622
6623 2015-02-27 Pedro Alves <palves@redhat.com>
6624
6625 * Makefile.in (COMPILER): New, get it from autoconf.
6626 (CXX): Get from autoconf instead.
6627 (COMPILE.pre): Use COMPILER.
6628 (CC-LD): Rename to ...
6629 (CC_LD): ... this. Use COMPILER.
6630 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
6631 (CXX_FOR_TARGET): Default to g++ instead of gcc.
6632 * acinclude.m4: Include build-with-cxx.m4.
6633 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
6634 Disable -Werror by default if building in C++ mode.
6635 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
6636 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
6637 the C++ compiler. Save/restore CXXFLAGS too.
6638 * configure: Regenerate.
6639
6640 2015-02-27 Pedro Alves <palves@redhat.com>
6641
6642 * acinclude.m4: Include libiberty.m4.
6643 * configure.ac: Call libiberty_INIT.
6644 * config.in, configure: Regenerate.
6645
6646 2015-02-26 Pedro Alves <palves@redhat.com>
6647
6648 * linux-low.c (linux_wait_1): When incrementing the PC past a
6649 program breakpoint always use the_low_target.breakpoint_len as
6650 increment, rather than the maximum between that and
6651 the_low_target.decr_pc_after_break.
6652
6653 2015-02-23 Pedro Alves <palves@redhat.com>
6654
6655 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
6656 thread was doing a step-over; always adjust the PC if
6657 we stepped over a permanent breakpoint.
6658 (linux_wait_1): If we stepped over breakpoint that was on top of a
6659 permanent breakpoint, manually advance the PC past it.
6660
6661 2015-02-23 Pedro Alves <palves@redhat.com>
6662
6663 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
6664 modes.
6665 (x86_fill_gregset, x86_store_gregset): Use it when handling
6666 $orig_eax.
6667
6668 2015-02-20 Pedro Alves <palves@redhat.com>
6669
6670 * thread-db.c: Include "nat/linux-procfs.h".
6671 (thread_db_init): Skip listing new threads if the kernel supports
6672 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
6673
6674 2015-02-20 Pedro Alves <palves@redhat.com>
6675
6676 * linux-low.c (status_pending_p_callback): Use ptid_match.
6677
6678 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
6679
6680 PR breakpoints/16812
6681 * linux-low.c (wstatus_maybe_breakpoint): Remove.
6682 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
6683 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
6684
6685 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
6686
6687 PR breakpoints/15956
6688 * tracepoint.c (cmd_qtinit): Add check for current_thread.
6689
6690 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6691
6692 * linux-low.c (linux_low_btrace_conf): Print size.
6693 * server.c (handle_btrace_conf_general_set): New.
6694 (hanle_general_set): Call handle_btrace_conf_general_set.
6695 (handle_query): Report Qbtrace-conf:bts:size as supported.
6696
6697 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6698
6699 * linux-low.c (linux_low_enable_btrace): Update parameters.
6700 (linux_low_btrace_conf): New.
6701 (linux_target_ops)<to_btrace_conf>: Initialize.
6702 * server.c (current_btrace_conf): New.
6703 (handle_btrace_enable): Rename to ...
6704 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
6705 to target_enable_btrace. Update comment. Update users.
6706 (handle_qxfer_btrace_conf): New.
6707 (qxfer_packets): Add btrace-conf entry.
6708 (handle_query): Report qXfer:btrace-conf:read as supported packet.
6709 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
6710 (target_ops)<read_btrace_conf>: New.
6711 (target_enable_btrace): Update parameters.
6712 (target_read_btrace_conf): New.
6713
6714 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6715
6716 * server.c (handle_btrace_general_set): Remove call to
6717 target_supports_btrace.
6718 (supported_btrace_packets): New.
6719 (handle_query): Call supported_btrace_packets.
6720 * target.h: include btrace-common.h.
6721 (btrace_target_info): Removed.
6722 (supports_btrace, target_supports_btrace): Update parameters.
6723
6724 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6725
6726 * Makefile.in (SFILES): Add common/btrace-common.c.
6727 (OBS): Add common/btrace-common.o.
6728 (btrace-common.o): Add build rules.
6729 * linux-low: Include btrace-common.h.
6730 (linux_low_read_btrace): Use struct btrace_data. Call
6731 btrace_data_init and btrace_data_fini.
6732
6733 2015-02-06 Pedro Alves <palves@redhat.com>
6734
6735 * thread-db.c (find_new_threads_callback): Add debug output.
6736
6737 2015-02-04 Pedro Alves <palves@redhat.com>
6738
6739 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
6740 (resume_stopped_resumed_lwps): New function.
6741 (linux_wait_for_event_filtered): Use it.
6742
6743 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6744
6745 * Makefile.in (SFILES): Add linux-personality.c.
6746 (linux-personality.o): New rule.
6747 * configure.srv (srv_linux_obj): Add linux-personality.o to the
6748 list of objects to be built.
6749 * linux-low.c: Include nat/linux-personality.h.
6750 (linux_create_inferior): Remove code to disable address space
6751 randomization (moved to ../nat/linux-personality.c). Create
6752 cleanup to disable address space randomization.
6753
6754 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6755
6756 * Makefile.in (posix-strerror.o): New rule.
6757 (mingw-strerror.o): Likewise.
6758 * configure: Regenerated.
6759 * configure.ac: Source file ../common/common.host. Initialize new
6760 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
6761
6762 2015-01-14 Yao Qi <yao@codesourcery.com>
6763
6764 * Makefile.in (SFILES): Add nat/ppc-linux.c.
6765 (ppc-linux.o): New rule.
6766 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
6767 * configure.ac: AC_CHECK_FUNCS(getauxval).
6768 * config.in: Re-generated.
6769 * configure: Re-generated.
6770 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
6771 ppc64_64bit_inferior_p
6772
6773 2015-01-14 Yao Qi <yao@codesourcery.com>
6774
6775 * linux-ppc-low.c: Include "nat/ppc-linux.h".
6776 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
6777 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
6778 (PT_ORIG_R3, PT_TRAP): Likewise.
6779 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
6780 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
6781 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
6782
6783 2015-01-10 Joel Brobecker <brobecker@adacore.com>
6784
6785 * i387-fp.c (i387_cache_to_xsave): In look over
6786 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
6787 zmmh_low_space field by use of zmmh_high_space.
6788
6789 2015-01-09 Pedro Alves <palves@redhat.com>
6790
6791 * linux-low.c (step_over_bkpt): Move higher up in the file.
6792 (handle_extended_wait): Don't store the stop_pc here.
6793 (get_stop_pc): Adjust comments and rename to ...
6794 (check_stopped_by_breakpoint): ... this. Record whether the LWP
6795 stopped for a software breakpoint or hardware breakpoint.
6796 (thread_still_has_status_pending_p): New function.
6797 (status_pending_p_callback): Use
6798 thread_still_has_status_pending_p. If the event is no longer
6799 interesting, resume the LWP.
6800 (handle_tracepoints): Add assert.
6801 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
6802 (wstatus_maybe_breakpoint): New function.
6803 (cancel_breakpoint): Delete function.
6804 (check_stopped_by_watchpoint): New function, factored out from
6805 linux_low_filter_event.
6806 (lp_status_maybe_breakpoint): Delete function.
6807 (linux_low_filter_event): Remove filter_ptid argument.
6808 Leave thread group exits pending here. Store the LWP's stop PC.
6809 Always leave events pending.
6810 (linux_wait_for_event_filtered): Pull all events out of the
6811 kernel, and leave them all pending.
6812 (count_events_callback, select_event_lwp_callback): Consider all
6813 events.
6814 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
6815 (select_event_lwp): Only give preference to the stepping LWP in
6816 all-stop mode. Adjust comments.
6817 (ignore_event): New function.
6818 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
6819 references to cancel_breakpoints. Adjust to renames. Also give
6820 equal priority to all LWPs that have had events in non-stop mode.
6821 If reporting a software breakpoint event, unadjust the LWP's PC.
6822 (linux_wait): If linux_wait_1 returned an ignored event, retry.
6823 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
6824 Adjust.
6825 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
6826 (resume_status_pending_p): Use thread_still_has_status_pending_p.
6827 (linux_stopped_by_watchpoint): Adjust.
6828 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
6829 * linux-low.h (enum lwp_stop_reason): New.
6830 (struct lwp_info) <stop_pc>: Adjust comment.
6831 <stopped_by_watchpoint>: Delete field.
6832 <stop_reason>: New field.
6833 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6834 * mem-break.c (software_breakpoint_inserted_here)
6835 (hardware_breakpoint_inserted_here): New function.
6836 * mem-break.h (software_breakpoint_inserted_here)
6837 (hardware_breakpoint_inserted_here): Declare.
6838 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
6839 (cancel_breakpoints): Delete.
6840 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
6841 (upload_fast_traceframes): Remove references to
6842 cancel_breakpoints.
6843
6844 2015-01-09 Pedro Alves <palves@redhat.com>
6845
6846 * thread-db.c (find_new_threads_callback): Ignore thread if the
6847 kernel thread ID is -1.
6848
6849 2015-01-09 Pedro Alves <palves@redhat.com>
6850
6851 * linux-low.c (linux_attach_fail_reason_string): Move to
6852 nat/linux-ptrace.c, and rename.
6853 (linux_attach_lwp): Update comment.
6854 (attach_proc_task_lwp_callback): New function.
6855 (linux_attach): Adjust to rename and use
6856 linux_proc_attach_tgid_threads.
6857 (linux_attach_fail_reason_string): Delete declaration.
6858
6859 2015-01-01 Joel Brobecker <brobecker@adacore.com>
6860
6861 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
6862 * server.c (gdbserver_version): Likewise.
6863
6864 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
6865
6866 * remote-utils.c: Include ctype.h.
6867 (input_interrupt): Explicitly handle the case when the char
6868 received is the NUL byte. Improve the printing of non-ASCII
6869 characters.
6870
6871 2014-12-16 Joel Brobecker <brobecker@adacore.com>
6872
6873 * linux-low.c (linux_low_filter_event): Update call to
6874 linux_enable_event_reporting following the addition of
6875 a new parameter to that function.
6876
6877 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
6878
6879 PR server/17457
6880 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
6881 (AARCH64_FPCR_REGNO): Likewise.
6882 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
6883 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
6884 (aarch64_store_fpregset): Likewise.
6885
6886 2014-12-15 Joel Brobecker <brobecker@adacore.com>
6887
6888 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
6889 Remove FIXME comment about assumption about N.
6890
6891 2014-12-13 Joel Brobecker <brobecker@adacore.com>
6892
6893 * configure.ac: If large-file support is disabled in GDBserver,
6894 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
6895 * configure: Regenerate.
6896
6897 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6898
6899 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
6900 warning upon ENODATA from ptrace.
6901 * linux-s390-low.c (s390_store_tdb): New.
6902 (s390_regsets): Add regset for NT_S390_TDB.
6903
6904 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6905
6906 * linux-low.c (regsets_store_inferior_registers): Skip regsets
6907 without a fill_function.
6908 * linux-s390-low.c (s390_fill_last_break): Remove.
6909 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
6910 (s390_arch_setup): Use regset's size instead of fill_function for
6911 loop end condition.
6912
6913 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6914
6915 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
6916 the regset's store function when ptrace returned an error.
6917 * regcache.c (get_thread_regcache): Invalidate register cache
6918 before fetching inferior's registers.
6919
6920 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6921
6922 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
6923 while-loop as for-loop.
6924 (regsets_store_inferior_registers): Likewise.
6925
6926 2014-11-28 Yao Qi <yao@codesourcery.com>
6927
6928 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
6929 * config.in, configure: Re-generate.
6930 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
6931 is defined.
6932
6933 2014-11-21 Yao Qi <yao@codesourcery.com>
6934
6935 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
6936 (AC_CHECK_HEADERS): Remove malloc.h.
6937 * configure: Re-generated.
6938 * config.in: Re-generated.
6939 * server.h: Don't include alloca.h and malloc.h.
6940 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
6941 Don't include malloc.h.
6942
6943 2014-11-17 Joel Brobecker <brobecker@adacore.com>
6944
6945 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
6946 corresponding ERRNO check in same block.
6947
6948 2014-11-12 Pedro Alves <palves@redhat.com>
6949
6950 * server.c (cont_thread): Update comment.
6951 (start_inferior, attach_inferior): No longer clear cont_thread.
6952 (handle_v_cont): No longer set cont_thread.
6953 (captured_main): Clear cont_thread each time a GDB connects.
6954
6955 2014-11-12 Pedro Alves <palves@redhat.com>
6956
6957 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
6958 thread, and don't resume all threads if the Hc thread has exited.
6959
6960 2014-11-12 Pedro Alves <palves@redhat.com>
6961
6962 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
6963 the process group instead of to a specific LWP.
6964
6965 2014-10-15 Pedro Alves <palves@redhat.com>
6966
6967 PR server/17487
6968 * win32-arm-low.c (arm_set_thread_context): Remove current_event
6969 parameter.
6970 (arm_set_thread_context): Delete.
6971 (the_low_target): Adjust.
6972 * win32-i386-low.c (debug_registers_changed)
6973 (debug_registers_used): Delete.
6974 (update_debug_registers_callback): New function.
6975 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
6976 needing to update their debug registers.
6977 (win32_get_current_dr): New function.
6978 (x86_dr_low_get_addr, x86_dr_low_get_control)
6979 (x86_dr_low_get_status): Fetch the debug register from the thread
6980 record's context.
6981 (i386_initial_stuff): Adjust.
6982 (i386_get_thread_context): Remove current_event parameter. Don't
6983 clear debug_registers_changed nor copy DR values to
6984 debug_reg_state.
6985 (i386_set_thread_context): Delete.
6986 (i386_prepare_to_resume): New function.
6987 (i386_thread_added): Mark the thread as needing to update irs
6988 debug registers.
6989 (the_low_target): Remove i386_set_thread_context and install
6990 i386_prepare_to_resume.
6991 * win32-low.c (win32_get_thread_context): Adjust.
6992 (win32_set_thread_context): Use SetThreadContext
6993 directly.
6994 (win32_prepare_to_resume): New function.
6995 (win32_require_context): New function, factored out from ...
6996 (thread_rec): ... this.
6997 (continue_one_thread): Call win32_prepare_to_resume on each thread
6998 we're about to continue.
6999 (win32_resume): Call win32_prepare_to_resume on the event thread.
7000 * win32-low.h (struct win32_thread_info)
7001 <debug_registers_changed>: New field.
7002 (struct win32_target_ops): Change prototype of set_thread_context,
7003 delete set_thread_context and add prepare_to_resume.
7004 (win32_require_context): New declaration.
7005
7006 2014-10-08 Gary Benson <gbenson@redhat.com>
7007
7008 * server.h: Do not include common-exceptions.h.
7009
7010 2014-10-08 Gary Benson <gbenson@redhat.com>
7011
7012 * server.h: Do not include cleanups.h.
7013
7014 2014-09-30 James Hogan <james.hogan@imgtec.com>
7015
7016 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7017 mips64-dsp-linux.c.
7018
7019 2014-09-23 Yao Qi <yao@codesourcery.com>
7020
7021 * linux-low.c (lp_status_maybe_breakpoint): New function.
7022 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7023 (count_events_callback): Likewise.
7024 (select_event_lwp_callback): Likewise.
7025 (cancel_breakpoints_callback): Likewise.
7026
7027 2014-09-19 Don Breazeal <donb@codesourcery.com>
7028
7029 * linux-low.c (handle_extended_wait): Call
7030 linux_ptrace_get_extended_event.
7031 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7032 linux_is_extended_waitstatus.
7033
7034 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7035
7036 * Makefile.in (CPPFLAGS): Define.
7037 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7038 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7039
7040 2014-09-16 Gary Benson <gbenson@redhat.com>
7041
7042 * inferiors.h (current_inferior): Renamed as...
7043 (current_thread): New variable. All uses updated.
7044 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7045 (maybe_move_out_of_jump_pad): Likewise.
7046 (cancel_breakpoint): Likewise.
7047 (linux_low_filter_event): Likewise.
7048 (wait_for_sigstop): Likewise.
7049 (linux_resume_one_lwp): Likewise.
7050 (need_step_over_p): Likewise.
7051 (start_step_over): Likewise.
7052 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7053 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7054 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7055 and save_inferior as saved_thread.
7056 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7057 saved_thread.
7058 (regcache_invalidate_thread): Likewise.
7059 * remote-utils.c (prepare_resume_reply): Likewise.
7060 * thread-db.c (thread_db_get_tls_address): Likewise.
7061 (disable_thread_event_reporting): Likewise.
7062 (remove_thread_event_breakpoints): Likewise.
7063 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7064 as saved_thread.
7065 * target.h (set_desired_inferior): Renamed as...
7066 (set_desired_thread): New declaration. All uses updated.
7067 * server.c (myresume): Updated comment to reference thread instead
7068 of inferior.
7069 (handle_serial_event): Likewise.
7070 (handle_target_event): Likewise.
7071
7072 2014-09-12 Tom Tromey <tromey@redhat.com>
7073 Gary Benson <gbenson@redhat.com>
7074
7075 * regcache.h: Include common-regcache.h.
7076 (regcache_read_pc): Don't declare.
7077 * regcache.c (get_thread_regcache_for_ptid): New function.
7078
7079 2014-09-11 Tom Tromey <tromey@redhat.com>
7080 Gary Benson <gbenson@redhat.com>
7081
7082 * symbol.c: New file.
7083 * Makefile.in (SFILES): Add symbol.c.
7084 (OBS): Add symbol.o.
7085
7086 2014-09-11 Gary Benson <gbenson@redhat.com>
7087
7088 * target.c (target_stop_ptid, target_continue_ptid): New
7089 functions.
7090
7091 2014-09-11 Tom Tromey <tromey@redhat.com>
7092 Gary Benson <gbenson@redhat.com>
7093
7094 * target.h: Include target/target.h.
7095 * target.c (target_read_memory, target_read_uint32)
7096 (target_write_memory): New functions.
7097
7098 2014-09-11 Gary Benson <gbenson@redhat.com>
7099
7100 * server.h (debug_hw_points): Don't declare.
7101 * server.c (debug_hw_points): Don't define. Replace all uses
7102 with show_debug_regs.
7103 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7104 all uses with show_debug_regs.
7105
7106 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7107
7108 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7109 endianness into account.
7110 (ppc_supply_ptrace_register): Likewise.
7111
7112 2014-09-03 James Hogan <james.hogan@imgtec.com>
7113
7114 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7115 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7116
7117 2014-09-03 Gary Benson <gbenson@redhat.com>
7118
7119 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7120 ALL_DEBUG_ADDRESS_REGISTERS.
7121
7122 2014-09-02 Gary Benson <gbenson@redhat.com>
7123
7124 * i386-low.h: Renamed as...
7125 * x86-low.h: New file. All type, function and variable name
7126 prefixes changed from "i386_" to "x86_". All references updated.
7127 * i386-low.c: Renamed as...
7128 * x86-low.c: New file. All type, function and variable name
7129 prefixes changed from "i386_" to "x86_". All references updated.
7130
7131 2014-09-02 Gary Benson <gbenson@redhat.com>
7132
7133 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7134 (x86_linux_new_thread): Likewise.
7135
7136 2014-08-29 Gary Benson <gbenson@redhat.com>
7137
7138 * server.h (setjmp.h): Do not include.
7139 (toplevel): Do not declare.
7140 (common-exceptions.h): Include.
7141 (cleanups.h): Likewise.
7142 * server.c (toplevel): Do not define.
7143 (exit_code): New static global.
7144 (detach_or_kill_for_exit_cleanup): New function.
7145 (main): New function. Original main renamed to...
7146 (captured_main): New function.
7147 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7148
7149 2014-08-29 Gary Benson <gbenson@redhat.com>
7150
7151 * Makefile.in (SFILES): Add common/common-exceptions.c.
7152 (OBS): Add common-exceptions.o.
7153 (common-exceptions.o): New rule.
7154 * utils.c (prepare_to_throw_exception): New function.
7155
7156 2014-08-29 Gary Benson <gbenson@redhat.com>
7157
7158 * config.in: Regenerate.
7159 * configure: Likewise.
7160
7161 2014-08-29 Gary Benson <gbenson@redhat.com>
7162
7163 * Makefile.in (SFILES): Add common/cleanups.c.
7164 (OBS): cleanups.o.
7165 (cleanups.o): New rule.
7166
7167 2014-08-29 Gary Benson <gbenson@redhat.com>
7168
7169 * utils.c (internal_vwarning): New function.
7170
7171 2014-08-28 Gary Benson <gbenson@redhat.com>
7172
7173 * utils.h (fatal): Remove declaration.
7174 * utils.c (fatal): Remove function.
7175
7176 2014-08-28 Gary Benson <gbenson@redhat.com>
7177
7178 * tracepoint.c (gdb_agent_init): Replace fatal with
7179 perror_with_name.
7180 (initialize_tracepoint): Likewise.
7181
7182 2014-08-28 Gary Benson <gbenson@redhat.com>
7183
7184 * remote-utils.c (remote_prepare): Replace fatal with error.
7185
7186 2014-08-28 Gary Benson <gbenson@redhat.com>
7187
7188 * linux-low.c (linux_async): Replace fatal with warning.
7189 Tidy up and return.
7190 (linux_start_non_stop): Return -1 if linux_async failed.
7191
7192 2014-08-28 Gary Benson <gbenson@redhat.com>
7193
7194 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7195 gdb_assert.
7196 (i386_dr_low_get_addr): Remove vague comment.
7197 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7198 gdb_assert.
7199
7200 2014-08-28 Gary Benson <gbenson@redhat.com>
7201
7202 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7203 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7204 internal_error.
7205 (linux_resume_one_lwp): Likewise.
7206 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7207 gdb_assert.
7208 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7209 with internal_error.
7210 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7211 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7212 (find_register_by_name): Replace fatal with internal_error.
7213 (find_regno): Likewise.
7214 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7215 * thread-db.c (thread_db_create_event): Likewise.
7216 (thread_db_load_search): Likewise.
7217 (try_thread_db_load_1): Likewise.
7218 * tracepoint.c (get_jump_space_head): Replace fatal with
7219 internal_error.
7220 (claim_trampoline_space): Likewise.
7221 (have_fast_tracepoint_trampoline_buffer): Likewise.
7222 (cmd_qtstart): Likewise.
7223 (stop_tracing): Likewise.
7224 (fast_tracepoint_collecting): Likewise.
7225 (target_malloc): Likewise.
7226 (download_tracepoint): Likewise.
7227 (download_trace_state_variables): Replace check with gdb_assert.
7228 (upload_fast_traceframes): Replace fatal with internal_error.
7229
7230 2014-08-19 Tom Tromey <tromey@redhat.com>
7231 Gary Benson <gbenson@redhat.com>
7232
7233 * Makefile.in (SFILES): Add common/common-debug.c.
7234 (OBS): Add common-debug.o.
7235 (common-debug.o): New rule.
7236 * debug.h (debug_printf): Don't declare.
7237 * debug.c (debug_printf): Renamed and rewritten as...
7238 (debug_vprintf): New function.
7239
7240 2014-08-19 Gary Benson <gbenson@redhat.com>
7241
7242 * utils.h: Do not include print-utils.h.
7243
7244 2014-08-19 Tom Tromey <tromey@redhat.com>
7245 Gary Benson <gbenson@redhat.com>
7246
7247 * server.h: Add static assertion.
7248 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7249
7250 2014-08-19 Tom Tromey <tromey@redhat.com>
7251 Gary Benson <gbenson@redhat.com>
7252
7253 * Makefile.in (SFILES): Add common/errors.c.
7254 (OBS): Add errors.o.
7255 (IPA_OBS): Add errors-ipa.o.
7256 (errors.o): New rule.
7257 (errors-ipa.o): Likewise.
7258 * utils.h (perror_with_name, error, warning): Don't declare.
7259 * utils.c (warning): Renamed and rewritten as...
7260 (vwarning): New function.
7261 (error): Renamed and rewritten as...
7262 (verror): New function.
7263 (internal_error): Renamed and rewritten as...
7264 (internal_verror): New function.
7265
7266 2014-08-07 Gary Benson <gbenson@redhat.com>
7267
7268 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7269 * configure: Regenerate.
7270 * config.in: Likewise.
7271 * server.h: Do not include errno.h.
7272 * event-loop.c: Likewise.
7273 * hostio-errno.c: Likewise.
7274 * linux-low.c: Likewise.
7275 * remote-utils.c: Likewise.
7276 * spu-low.c: Likewise.
7277 * utils.c: Likewise.
7278 * gdbreplay.c: Unconditionally include errno.h.
7279
7280 2014-08-07 Gary Benson <gbenson@redhat.com>
7281
7282 * server.h: Do not include string.h.
7283 * event-loop.c: Likewise.
7284 * linux-low.c: Likewise.
7285 * regcache.c: Likewise.
7286 * remote-utils.c: Likewise.
7287 * spu-low.c: Likewise.
7288 * utils.c: Likewise.
7289
7290 2014-08-07 Gary Benson <gbenson@redhat.com>
7291
7292 * server.h: Do not include gdb_assert.h.
7293
7294 2014-08-07 Gary Benson <gbenson@redhat.com>
7295
7296 * server.h: Do not include common-utils.h.
7297
7298 2014-08-07 Gary Benson <gbenson@redhat.com>
7299
7300 * server.h: Do not include ptid.h.
7301 * notif.h: Likewise.
7302
7303 2014-08-07 Gary Benson <gbenson@redhat.com>
7304
7305 * server.h: Do not include gdb_locale.h.
7306
7307 2014-08-07 Gary Benson <gbenson@redhat.com>
7308
7309 * server.h: Do not include gdb/signals.h.
7310 * win32-low.c: Likewise.
7311
7312 2014-08-07 Gary Benson <gbenson@redhat.com>
7313
7314 * server.h: Do not include pathmax.h.
7315
7316 2014-08-07 Gary Benson <gbenson@redhat.com>
7317
7318 * server.h: Do not include libiberty.h.
7319 * linux-bfin-low.c: Likewise.
7320
7321 2014-08-07 Gary Benson <gbenson@redhat.com>
7322
7323 * server.h: Do not include ansidecl.h.
7324
7325 2014-08-07 Gary Benson <gbenson@redhat.com>
7326
7327 * linux-x86-low.c: Do not include stddef.h.
7328 * lynx-ppc-low.c: Likewise.
7329 * tracepoint.c: Likewise.
7330
7331 2014-08-07 Gary Benson <gbenson@redhat.com>
7332
7333 * server.h: Do not include stdarg.h.
7334 * nto-low.c: Likewise.
7335
7336 2014-08-07 Gary Benson <gbenson@redhat.com>
7337
7338 * server.h: Do not include stdlib.h.
7339 * inferiors.c: Likewise.
7340 * linux-low.c: Likewise.
7341 * regcache.c: Likewise.
7342 * spu-low.c: Likewise.
7343 * tracepoint.c: Likewise.
7344 * utils.c: Likewise.
7345
7346 2014-08-07 Gary Benson <gbenson@redhat.com>
7347
7348 * server.h: Do not include stdio.h.
7349 * linux-low.c: Likewise.
7350 * remote-utils.c: Likewise.
7351 * spu-low.c: Likewise.
7352 * utils.c: Likewise.
7353 * wincecompat.c: Likewise.
7354
7355 2014-08-06 Gary Benson <gbenson@redhat.com>
7356
7357 * regcache.c (init_register_cache): Move conditionals inside if.
7358
7359 2014-08-06 Gary Benson <gbenson@redhat.com>
7360
7361 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7362
7363 2014-07-31 Gary Benson <gbenson@redhat.com>
7364
7365 * ax.h: Do not include server.h.
7366 * gdbthread.h: Likewise.
7367 * lynx-low.h: Likewise.
7368 * notif.h: Likewise.
7369
7370 2014-07-30 Gary Benson <gbenson@redhat.com>
7371
7372 * server.h: Include common-defs.h.
7373 Do not include config.h or build-gnulib-gdbserver/config.h.
7374
7375 2014-07-30 Gary Benson <gbenson@redhat.com>
7376
7377 * hostio-errno.c: Move server.h to top of includes list.
7378 * inferiors.c: Likewise.
7379 * linux-x86-low.c: Likewise.
7380 * notif.c: Include server.h.
7381
7382 2014-07-24 Tom Tromey <tromey@redhat.com>
7383 Gary Benson <gbenson@redhat.com>
7384
7385 * server.h (CORE_ADDR): Now unsigned.
7386
7387 2014-07-16 Pedro Alves <palves@redhat.com>
7388
7389 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7390
7391 2014-07-15 Pedro Alves <palves@redhat.com>
7392
7393 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7394 copy.
7395
7396 2014-07-11 Pedro Alves <palves@redhat.com>
7397
7398 * linux-low.c (kill_wait_lwp): New function, based on
7399 kill_one_lwp_callback, but use my_waitpid directly.
7400 (kill_one_lwp_callback, linux_kill): Use it.
7401
7402 2014-06-23 Pedro Alves <palves@redhat.com>
7403
7404 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7405 before setting DR0..DR3.
7406
7407 2014-06-20 Gary Benson <gbenson@redhat.com>
7408
7409 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7410 * configure: Regenerated.
7411 * config.in: Likewise.
7412
7413 2014-06-20 Gary Benson <gbenson@redhat.com>
7414
7415 * Makefile.in (SFILES): Update locations for files moved
7416 from common to nat.
7417 (object file files): Reordered.
7418
7419 2014-06-20 Gary Benson <gbenson@redhat.com>
7420
7421 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7422 (i386_dr_low_set_addr): Likewise.
7423 (i386_dr_low_get_addr): Likewise.
7424 (i386_dr_low_can_set_control): Likewise.
7425 (i386_dr_low_set_control): Likewise.
7426 (i386_dr_low_get_control): Likewise.
7427 (i386_dr_low_get_status): Likewise.
7428 (i386_get_debug_register_length): Likewise.
7429 * linux-x86-low.c (i386_dr_low_set_addr):
7430 Changed signature. Made static.
7431 (i386_dr_low_get_addr): Likewise.
7432 (i386_dr_low_set_control): Likewise.
7433 (i386_dr_low_get_control): Likewise.
7434 (i386_dr_low_get_status): Likewise.
7435 (i386_dr_low): New global variable.
7436 * win32-i386-low.c (i386_dr_low_set_addr):
7437 Changed signature. Made static.
7438 (i386_dr_low_get_addr): Likewise.
7439 (i386_dr_low_set_control): Likewise.
7440 (i386_dr_low_get_control): Likewise.
7441 (i386_dr_low_get_status): Likewise.
7442 (i386_dr_low): New global variable.
7443
7444 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7445
7446 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7447 * Makefile.in (AR, AR_FLAGS): Define.
7448 * configure: Regenerate.
7449
7450 2014-06-19 Gary Benson <gbenson@redhat.com>
7451
7452 * Makefile.in (i386-dregs.o): New rule.
7453 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7454 * i386-low.c (target.h): Remove include.
7455 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7456 (DR_CONTROL_SHIFT): Likewise.
7457 (DR_CONTROL_SIZE): Likewise.
7458 (DR_RW_EXECUTE): Likewise.
7459 (DR_RW_WRITE): Likewise.
7460 (DR_RW_READ): Likewise.
7461 (DR_RW_IORW): Likewise.
7462 (DR_LEN_1): Likewise.
7463 (DR_LEN_2): Likewise.
7464 (DR_LEN_4): Likewise.
7465 (DR_LEN_8): Likewise.
7466 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7467 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7468 (DR_ENABLE_SIZE): Likewise.
7469 (DR_LOCAL_SLOWDOWN): Likewise.
7470 (DR_GLOBAL_SLOWDOWN): Likewise.
7471 (DR_CONTROL_RESERVED): Likewise.
7472 (I386_DR_CONTROL_MASK): Likewise.
7473 (I386_DR_VACANT): Likewise.
7474 (I386_DR_LOCAL_ENABLE): Likewise.
7475 (I386_DR_GLOBAL_ENABLE): Likewise.
7476 (I386_DR_DISABLE): Likewise.
7477 (I386_DR_SET_RW_LEN): Likewise.
7478 (I386_DR_GET_RW_LEN): Likewise.
7479 (I386_DR_WATCH_HIT): Likewise.
7480 (i386_wp_op_t): Likewise.
7481 (i386_show_dr): Likewise.
7482 (i386_length_and_rw_bits): Likewise.
7483 (i386_insert_aligned_watchpoint): Likewise.
7484 (i386_remove_aligned_watchpoint): Likewise.
7485 (i386_handle_nonaligned_watchpoint): Likewise.
7486 i386_update_inferior_debug_regs(): Likewise.
7487 (i386_dr_insert_watchpoint): Likewise.
7488 (i386_dr_remove_watchpoint): Likewise.
7489 (i386_dr_region_ok_for_watchpoint): Likewise.
7490 (i386_dr_stopped_data_address): Likewise.
7491 (i386_dr_stopped_by_watchpoint): Likewise.
7492
7493 2014-06-19 Gary Benson <gbenson@redhat.com>
7494
7495 * i386-low.c (i386_dr_show): Renamed to
7496 i386_show_dr and made static. All uses updated.
7497 (i386_dr_length_and_rw_bits): Renamed to
7498 i386_length_and_rw_bits and made static.
7499 All uses updated.
7500 (i386_dr_insert_aligned_watchpoint): Renamed to
7501 i386_insert_aligned_watchpoint and made static.
7502 All uses updated.
7503 (i386_dr_remove_aligned_watchpoint): Renamed to
7504 i386_remove_aligned_watchpoint and made static.
7505 All uses updated.
7506 (i386_dr_update_inferior_debug_regs): Renamed to
7507 i386_update_inferior_debug_regs and made static.
7508 All uses updated.
7509
7510 2014-06-18 Gary Benson <gbenson@redhat.com>
7511
7512 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7513 (i386_dr_low_can_set_control): Likewise.
7514 (i386_get_debug_register_length): Likewise.
7515 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7516 (i386_dr_low_can_set_control): Likewise.
7517 (i386_get_debug_register_length): Likewise.
7518
7519 2014-06-17 Gary Benson <gbenson@redhat.com>
7520
7521 * i386-low.h (i386-dregs.h): New include.
7522 (DR_FIRSTADDR): Now in i386-dregs.h.
7523 (DR_LASTADDR): Likewise.
7524 (DR_NADDR): Likewise.
7525 (DR_STATUS): Likewise.
7526 (DR_CONTROL): Likewise.
7527 (i386_debug_reg_state): Likewise.
7528 (i386_dr_insert_watchpoint): Likewise.
7529 (i386_dr_remove_watchpoint): Likewise.
7530 (i386_dr_region_ok_for_watchpoint): Likewise.
7531 (i386_dr_stopped_data_address): Likewise.
7532 (i386_dr_stopped_by_watchpoint): Likewise.
7533 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7534
7535 2014-06-18 Gary Benson <gbenson@redhat.com>
7536
7537 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7538 i386_dr_insert_watchpoint.
7539 (i386_low_remove_watchpoint): Renamed to
7540 i386_dr_remove_watchpoint.
7541 (i386_low_region_ok_for_watchpoint): Renamed to
7542 i386_dr_region_ok_for_watchpoint.
7543 (i386_low_stopped_data_address): Renamed to
7544 i386_dr_stopped_data_address.
7545 (i386_low_stopped_by_watchpoint): Renamed to
7546 i386_dr_stopped_by_watchpoint.
7547 * i386-low.c (i386_show_dr): Renamed to
7548 i386_dr_show and made nonstatic. All uses updated.
7549 (i386_length_and_rw_bits): Renamed to
7550 i386_dr_length_and_rw_bits and made nonstatic.
7551 All uses updated.
7552 (i386_insert_aligned_watchpoint): Renamed to
7553 i386_dr_insert_aligned_watchpoint and made nonstatic.
7554 All uses updated.
7555 (i386_remove_aligned_watchpoint): Renamed to
7556 i386_dr_remove_aligned_watchpoint and made nonstatic.
7557 All uses updated.
7558 (i386_update_inferior_debug_regs): Renamed to
7559 i386_dr_update_inferior_debug_regs and made nonstatic.
7560 All uses updated.
7561 (i386_low_insert_watchpoint): Renamed to
7562 i386_dr_insert_watchpoint. All uses updated.
7563 (i386_low_remove_watchpoint): Renamed to
7564 i386_dr_remove_watchpoint. All uses updated.
7565 (i386_low_region_ok_for_watchpoint): Renamed to
7566 i386_dr_region_ok_for_watchpoint. All uses updated.
7567 (i386_low_stopped_data_address): Renamed to
7568 i386_dr_stopped_data_address. All uses updated.
7569 (i386_low_stopped_by_watchpoint): Renamed to
7570 i386_dr_stopped_by_watchpoint. All uses updated.
7571
7572 2014-06-18 Gary Benson <gbenson@redhat.com>
7573
7574 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7575 (i386_dr_low_can_set_control): Likewise.
7576 (i386_insert_aligned_watchpoint): New check.
7577
7578 2014-06-18 Gary Benson <gbenson@redhat.com>
7579
7580 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
7581 Renamed to state.
7582
7583 2014-06-18 Gary Benson <gbenson@redhat.com>
7584
7585 * i386-low.c (i386_length_and_rw_bits): Use internal_error
7586 instead of fatal and error.
7587 (i386_handle_nonaligned_watchpoint): Likewise.
7588
7589 2014-06-18 Gary Benson <gbenson@redhat.com>
7590
7591 * i386-low.c (i386_get_debug_register_length): New macro.
7592 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
7593 (i386_show_dr): Use debug_printf instead of fprintf. Use
7594 phex to format values.
7595
7596 2014-06-18 Gary Benson <gbenson@redhat.com>
7597
7598 * i386-low.h: Comment changes.
7599 * i386-low.c: Likewise.
7600
7601 2014-06-18 Gary Benson <gbenson@redhat.com>
7602
7603 * i386-low.c: Whitespace changes.
7604
7605 2014-06-12 Tom Tromey <tromey@redhat.com>
7606
7607 * utils.c (freeargv): Remove.
7608
7609 2014-06-12 Tom Tromey <tromey@redhat.com>
7610
7611 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
7612 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
7613 (parse_debug_format_options): Likewise.
7614 (gdbserver_usage): Likewise.
7615 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
7616 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
7617 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
7618 against libiberty.
7619 ($(LIBGNU)): Depend on libiberty.
7620 (all-lib): Recurse into all subdirs.
7621 (install-only): Invoke "install" target in subdirs.
7622 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
7623 targets.
7624 * configure: Rebuild.
7625 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
7626 for vasprintf, vsnprintf, or gettimeofday.
7627 * configure.srv: Don't add safe-ctype.o or lbasename.o to
7628 srv_tgtobj.
7629
7630 2014-06-05 Joel Brobecker <brobecker@adacore.com>
7631
7632 * development.sh: Delete.
7633 * Makefile.in (config.status): Adjust dependency on development.sh.
7634 * configure.ac: Adjust development.sh source call.
7635 * configure: Regenerate.
7636
7637 2014-06-02 Pedro Alves <palves@redhat.com>
7638
7639 * ax.c (gdb_free_agent_expr): New function.
7640 * ax.h (gdb_free_agent_expr): New declaration.
7641 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
7642 list.
7643 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
7644 static.
7645 (clear_breakpoint_conditions_and_commands): New function.
7646 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
7647 (clear_breakpoint_conditions_and_commands): New declaration.
7648
7649 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
7650
7651 * linux-aarch64-low.c (asm/ptrace.h): Include.
7652
7653 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7654
7655 Fix TLS access for -static -pthread.
7656 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
7657 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
7658 (thread_db_load_search, try_thread_db_load_1): Initialize it.
7659
7660 2014-05-20 Pedro Alves <palves@redhat.com>
7661
7662 * linux-aarch64-low.c (aarch64_insert_point)
7663 (aarch64_remove_point): No longer check whether the type is
7664 supported here. Adjust to new interface.
7665 (the_low_target): Install aarch64_supports_z_point_type as
7666 supports_z_point_type method.
7667 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
7668 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
7669 instead of a Z packet char. Adjust.
7670 (arm_supports_z_point_type): New function.
7671 (arm_insert_point, arm_remove_point): Adjust to new interface.
7672 (the_low_target): Install arm_supports_z_point_type.
7673 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
7674 (cris_insert_point, cris_remove_point): Adjust to new interface.
7675 Don't check whether the type is supported here.
7676 (the_low_target): Install cris_supports_z_point_type.
7677 * linux-low.c (linux_supports_z_point_type): New function.
7678 (linux_insert_point, linux_remove_point): Adjust to new interface.
7679 * linux-low.h (struct linux_target_ops) <insert_point,
7680 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
7681 raw_breakpoint pointer parameter.
7682 <supports_z_point_type>: New method.
7683 * linux-mips-low.c (mips_supports_z_point_type): New function.
7684 (mips_insert_point, mips_remove_point): Adjust to new interface.
7685 Use mips_supports_z_point_type.
7686 (the_low_target): Install mips_supports_z_point_type.
7687 * linux-ppc-low.c (the_low_target): Install NULL as
7688 supports_z_point_type method.
7689 * linux-s390-low.c (the_low_target): Install NULL as
7690 supports_z_point_type method.
7691 * linux-sparc-low.c (the_low_target): Install NULL as
7692 supports_z_point_type method.
7693 * linux-x86-low.c (x86_supports_z_point_type): New function.
7694 (x86_insert_point): Adjust to new insert_point interface. Use
7695 insert_memory_breakpoint. Adjust to new
7696 i386_low_insert_watchpoint interface.
7697 (x86_remove_point): Adjust to remove_point interface. Use
7698 remove_memory_breakpoint. Adjust to new
7699 i386_low_remove_watchpoint interface.
7700 (the_low_target): Install x86_supports_z_point_type.
7701 * lynx-low.c (lynx_target_ops): Install NULL as
7702 supports_z_point_type callback.
7703 * nto-low.c (nto_supports_z_point_type): New.
7704 (nto_insert_point, nto_remove_point): Adjust to new interface.
7705 (nto_target_ops): Install nto_supports_z_point_type.
7706 * mem-break.c: Adjust intro comment.
7707 (struct raw_breakpoint) <raw_type, size>: New fields.
7708 <inserted>: Update comment.
7709 <shlib_disabled>: Delete field.
7710 (enum bkpt_type) <gdb_breakpoint>: Delete value.
7711 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
7712 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
7713 (raw_bkpt_type_to_target_hw_bp_type): New function.
7714 (find_enabled_raw_code_breakpoint_at): New function.
7715 (find_raw_breakpoint_at): New type and size parameters. Use them.
7716 (insert_memory_breakpoint): New function, based off
7717 set_raw_breakpoint_at.
7718 (remove_memory_breakpoint): New function.
7719 (set_raw_breakpoint_at): Reimplement.
7720 (set_breakpoint): New, based on set_breakpoint_at.
7721 (set_breakpoint_at): Reimplement.
7722 (delete_raw_breakpoint): Go through the_target->remove_point
7723 instead of assuming memory breakpoints.
7724 (find_gdb_breakpoint_at): Delete.
7725 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
7726 (find_gdb_breakpoint): New function.
7727 (set_gdb_breakpoint_at): Delete.
7728 (z_type_supported): New function.
7729 (set_gdb_breakpoint_1): New function, loosely based off
7730 set_gdb_breakpoint_at.
7731 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
7732 (delete_gdb_breakpoint_at): Delete.
7733 (delete_gdb_breakpoint_1): New function, loosely based off
7734 delete_gdb_breakpoint_at.
7735 (delete_gdb_breakpoint): New function.
7736 (clear_gdb_breakpoint_conditions): Rename to ...
7737 (clear_breakpoint_conditions): ... this. Don't handle a NULL
7738 breakpoint.
7739 (add_condition_to_breakpoint): Make static.
7740 (add_breakpoint_condition): Take a struct breakpoint pointer
7741 instead of an address. Adjust.
7742 (gdb_condition_true_at_breakpoint): Rename to ...
7743 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
7744 z_type parameter.
7745 (gdb_condition_true_at_breakpoint): Reimplement.
7746 (add_breakpoint_commands): Take a struct breakpoint pointer
7747 instead of an address. Adjust.
7748 (gdb_no_commands_at_breakpoint): Rename to ...
7749 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
7750 parameter. Return true if no breakpoint was found. Change debug
7751 output.
7752 (gdb_no_commands_at_breakpoint): Reimplement.
7753 (run_breakpoint_commands): Rename to ...
7754 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
7755 and change return type to boolean.
7756 (run_breakpoint_commands): New function.
7757 (gdb_breakpoint_here): Also check for Z1 breakpoints.
7758 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
7759 breakpoint. Go through the_target->remove_point instead of
7760 assuming memory breakpoint.
7761 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
7762 software and hardware breakpoints.
7763 (reinsert_raw_breakpoint): Go through the_target->insert_point
7764 instead of assuming memory breakpoint.
7765 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
7766 software and hardware breakpoints.
7767 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
7768 Check both software and hardware breakpoints.
7769 (validate_inserted_breakpoint): Assert the breakpoint is a
7770 software breakpoint. Set the inserted flag to -1 instead of
7771 setting shlib_disabled.
7772 (delete_disabled_breakpoints): Adjust.
7773 (validate_breakpoints): Only validate software breakpoints.
7774 Adjust to inserted flag change.
7775 (check_mem_read, check_mem_write): Skip breakpoint types other
7776 than software breakpoints. Adjust to inserted flag change.
7777 * mem-break.h (enum raw_bkpt_type): New enum.
7778 (raw_breakpoint, struct process_info): Forward declare.
7779 (Z_packet_to_target_hw_bp_type): Delete declaration.
7780 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
7781 (set_gdb_breakpoint, delete_gdb_breakpoint)
7782 (clear_breakpoint_conditions): New declarations.
7783 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
7784 (breakpoint_inserted_here): Update comment.
7785 (add_breakpoint_condition, add_breakpoint_commands): Replace
7786 address parameter with a breakpoint pointer parameter.
7787 (gdb_breakpoint_here): Update comment.
7788 (delete_gdb_breakpoint_at): Delete.
7789 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
7790 * server.c (process_point_options): Take a struct breakpoint
7791 pointer instead of an address. Adjust.
7792 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
7793 delete_gdb_breakpoint.
7794 * spu-low.c (spu_target_ops): Install NULL as
7795 supports_z_point_type method.
7796 * target.h: Include mem-break.h.
7797 (struct target_ops) <prepare_to_access_memory>: Update comment.
7798 <supports_z_point_type>: New field.
7799 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7800 instead of a char. Also take a raw breakpoint pointer.
7801 * win32-arm-low.c (the_low_target): Install NULL as
7802 supports_z_point_type.
7803 * win32-i386-low.c (i386_supports_z_point_type): New function.
7804 (i386_insert_point, i386_remove_point): Adjust to new interface.
7805 (the_low_target): Install i386_supports_z_point_type.
7806 * win32-low.c (win32_supports_z_point_type): New function.
7807 (win32_insert_point, win32_remove_point): Adjust to new interface.
7808 (win32_target_ops): Install win32_supports_z_point_type.
7809 * win32-low.h (struct win32_target_ops):
7810 <supports_z_point_type>: New method.
7811 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7812 instead of a char. Also take a raw breakpoint pointer.
7813
7814 2014-05-20 Pedro Alves <palves@redhat.com>
7815
7816 * mem-break.h: Include break-common.h.
7817 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7818 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
7819 (Z_packet_to_target_hw_bp_type): New declaration.
7820 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
7821 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
7822 (Z_PACKET_ACCESS_WP): Delete macros.
7823 (Z_packet_to_hw_type): Delete function.
7824 * i386-low.h: Don't include break-common.h here.
7825 (Z_packet_to_hw_type): Delete declaration.
7826 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
7827 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7828 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
7829 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7830 * linux-aarch64-low.c: Don't include break-common.h here.
7831 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7832 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
7833 (Z_packet_to_target_hw_bp_type): Delete function.
7834 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
7835 function.
7836 (mips_insert_point, mips_remove_point): Use
7837 Z_packet_to_target_hw_bp_type.
7838
7839 2014-05-20 Pedro Alves <palves@redhat.com>
7840
7841 * linux-aarch64-low.c: Include break-common.h.
7842 (enum target_point_type): Delete.
7843 (Z_packet_to_point_type): Rename to ...
7844 (Z_packet_to_target_hw_bp_type): ... this, and return a
7845 target_hw_bp_type instead.
7846 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
7847 instead of an enum target_point_type.
7848 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
7849 breakpoint type.
7850 (aarch64_dr_state_insert_one_point)
7851 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
7852 (aarch64_handle_aligned_watchpoint)
7853 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
7854 Take an enum target_hw_bp_type instead of an enum
7855 target_point_type.
7856 (aarch64_supports_z_point_type): New function.
7857 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
7858 use Z_packet_to_target_hw_bp_type.
7859
7860 2014-05-20 Joel Brobecker <brobecker@adacore.com>
7861
7862 * configure.ac: Only use -Werror by default when DEVELOPMENT
7863 is true.
7864 * configure: Regenerate.
7865
7866 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
7867
7868 Fix gdbserver qGetTLSAddr for x86_64 -m32.
7869 * linux-x86-low.c (X86_64_USER_REGS): New.
7870 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
7871
7872 2014-04-28 Yao Qi <yao@codesourcery.com>
7873
7874 * Makefile.in (i386-avx512.c): Fix the typo of generated file
7875 name.
7876
7877 2014-04-25 Pedro Alves <palves@redhat.com>
7878
7879 PR server/16255
7880 * linux-low.c (linux_attach_fail_reason_string): New function.
7881 (linux_attach_lwp): Delete.
7882 (linux_attach_lwp_1): Rename to ...
7883 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
7884 argument. Remove "initial" parameter. Return int instead of
7885 void. Don't error or warn here.
7886 (linux_attach): Adjust to call linux_attach_lwp. Call error on
7887 failure to attach to the tgid. Call warning when failing to
7888 attach to an lwp.
7889 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
7890 argument. Remove "initial" parameter. Return int instead of
7891 void. Don't error or warn here.
7892 (linux_attach_fail_reason_string): New declaration.
7893 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
7894 interface change. Use linux_attach_fail_reason_string.
7895
7896 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
7897 Walfred Tedeschi <walfred.tedeschi@intel.com>
7898
7899 * Makefile.in: Added rules to handle new files
7900 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
7901 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
7902 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
7903 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
7904 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
7905 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
7906 x32-avx512-linux.o.
7907 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
7908 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
7909 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
7910 i386/x32-avx512.xml.
7911 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
7912 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
7913 i386/x32-avx512-linux.xml.
7914 * i387-fp.c (num_avx512_k_registers): New constant for number
7915 of K registers.
7916 (num_avx512_zmmh_low_registers): New constant for number of
7917 lower ZMM registers (0-15).
7918 (num_avx512_zmmh_high_registers): New constant for number of
7919 higher ZMM registers (16-31).
7920 (num_avx512_ymmh_registers): New contant for number of higher
7921 YMM registers (ymm16-31 added by avx521 on x86_64).
7922 (num_avx512_xmm_registers): New constant for number of higher
7923 XMM registers (xmm16-31 added by AVX512 on x86_64).
7924 (struct i387_xsave): Add space for AVX512 registers.
7925 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
7926 Add code to handle AVX512 registers.
7927 (i387_xsave_to_cache): Add code to handle AVX512 registers.
7928 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
7929 prototypei from generated file.
7930 (tdesc_amd64_avx512_linux): Likewise.
7931 (init_registers_x32_avx512_linux): Likewise.
7932 (tdesc_x32_avx512_linux): Likewise.
7933 (init_registers_i386_avx512_linux): Likewise.
7934 (tdesc_i386_avx512_linux): Likewise.
7935 (x86_64_regmap): Add AVX512 registers.
7936 (x86_linux_read_description): Add code to handle AVX512 XSTATE
7937 mask.
7938 (initialize_low_arch): Add code to initialize AVX512 registers.
7939
7940 2014-04-23 Pedro Alves <palves@redhat.com>
7941
7942 * mem-break.c (find_gdb_breakpoint_at): Make static.
7943 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
7944
7945 2014-04-23 Pedro Alves <palves@redhat.com>
7946
7947 * i386-low.c: Don't include break-common.h here.
7948 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7949 prototype to take target_hw_bp_type as argument instead of a Z
7950 packet char.
7951 * i386-low.h: Include break-common.h here.
7952 (Z_packet_to_hw_type): Declare.
7953 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7954 prototypes.
7955 * linux-x86-low.c (x86_insert_point): Convert the packet number to
7956 a target_hw_bp_type before calling i386_low_insert_watchpoint.
7957 (x86_remove_point): Convert the packet number to a
7958 target_hw_bp_type before calling i386_low_remove_watchpoint.
7959 * win32-i386-low.c (i386_insert_point): Convert the packet number
7960 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
7961 (i386_remove_point): Convert the packet number to a
7962 target_hw_bp_type before calling i386_low_remove_watchpoint.
7963
7964 2014-04-23 Pedro Alves <palves@redhat.com>
7965
7966 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
7967
7968 2014-04-10 Pedro Alves <palves@redhat.com>
7969
7970 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7971 Check if the condition or command is NULL before checking if the
7972 breakpoint is known. On success, return true.
7973 * mem-break.h (add_breakpoint_condition): Document return.
7974 (add_breakpoint_commands): Add describing comment.
7975 * server.c (skip_to_semicolon): New function.
7976 (process_point_options): Use it.
7977
7978 2014-04-09 Pedro Alves <palves@redhat.com>
7979
7980 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
7981 to lwpid_of.
7982
7983 2014-02-27 Pedro Alves <palves@redhat.com>
7984
7985 PR 12702
7986 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
7987 macros.
7988 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
7989 output.
7990 (last_thread_of_process_p): Take a PID argument instead of a
7991 thread pointer.
7992 (linux_wait_for_lwp): Delete.
7993 (num_lwps, check_zombie_leaders, not_stopped_callback): New
7994 functions.
7995 (linux_low_filter_event): New function, party factored out from
7996 linux_wait_for_event.
7997 (linux_wait_for_event): Rename to ...
7998 (linux_wait_for_event_filtered): ... this. Add new filter ptid
7999 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8000 sigsuspend. Check for zombie leaders.
8001 (linux_wait_for_event): Reimplement as wrapper around
8002 linux_wait_for_event_filtered.
8003 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8004 a normal or signal exit is seen, it's the whole process exiting.
8005 (wait_for_sigstop): No longer a for_each_inferior callback.
8006 Rewrite on top of linux_wait_for_event_filtered.
8007 (stop_all_lwps): Call wait_for_sigstop directly.
8008 * server.c (resume, handle_target_event): Handle
8009 TARGET_WAITKIND_NO_RESUMED.
8010
8011 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8012
8013 * win32-low.c (psapi_get_dll_name,
8014 * win32_CreateToolhelp32Snapshot): Delete.
8015 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8016 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8017 Delete.
8018 (handle_load_dll): Add function description.
8019 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8020
8021 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8022
8023 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8024 Add comment.
8025 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8026 base address when calling win32_add_one_solib.
8027 (handle_load_dll): Delete local variable load_addr.
8028 Remove 0x1000 offset applied to DLL base address when calling
8029 win32_add_one_solib.
8030 (handle_unload_dll): Add comment.
8031
8032 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8033
8034 * win32-low.c (win32_add_all_dlls): Renames
8035 win32_ensure_ntdll_loaded. Rewrite function documentation.
8036 Adjust implementation to always load all DLLs.
8037 Add 0x1000 offset to DLL base address when calling
8038 win32_add_one_solib.
8039 (child_initialization_done): New static global.
8040 (do_initial_child_stuff): Set child_initialization_done to
8041 zero during child initialization, and 1 after. Replace call
8042 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8043 Add comment.
8044 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8045 (handle_unload_dll): Add function documentation.
8046 (get_child_debug_event): Ignore load and unload DLL events
8047 during child initialization.
8048
8049 2014-02-20 Doug Evans <dje@google.com>
8050
8051 Remove global all_lwps.
8052 * inferiors.h (ptid_of): Move here from linux-low.h.
8053 (pid_of, lwpid_of): Ditto.
8054 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8055 parameter is a struct thread_info * now.
8056 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8057 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8058 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8059 directly.
8060 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8061 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8062 * linux-arm-low.c (update_registers_callback): Update, "entry"
8063 parameter is a struct thread_info * now.
8064 Fetch lwpid from current_inferior directly.
8065 (arm_insert_point): Pass &all_threads to find_inferior instead of
8066 &all_lwps.
8067 (arm_remove_point): Ditto.
8068 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8069 (arm_prepare_to_resume): Fetch pid from thread.
8070 (arm_read_description): Fetch lwpid from current_inferior directly.
8071 * linux-low.c (all_lwps): Delete.
8072 (delete_lwp): Delete call to remove_inferior.
8073 (handle_extended_wait): Fetch lwpid from thread.
8074 (add_lwp): Don't set lwp->entry.id. Remove call to
8075 add_inferior_to_list.
8076 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8077 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8078 (kill_one_lwp_callback): Ditto.
8079 (linux_kill): Don't dereference NULL pointer.
8080 Fetch ptid,lwpid from thread.
8081 (get_detach_signal): Fetch ptid from thread.
8082 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8083 Simplify call to regcache_invalidate_thread.
8084 (delete_lwp_callback): Update, "entry" parameter is a
8085 struct thread_info * now. Fetch pid from thread.
8086 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8087 (status_pending_p_callback): Update, "entry" parameter is a
8088 struct thread_info * now. Fetch ptid from thread.
8089 (find_lwp_pid): Update, "entry" parameter is a
8090 struct thread_info * now.
8091 (linux_wait_for_lwp): Fetch pid from thread.
8092 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8093 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8094 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8095 (dequeue_one_deferred_signal): Ditto.
8096 (cancel_breakpoint): Fetch ptid from current_inferior.
8097 (linux_wait_for_event): Pass &all_threads to find_inferior,
8098 not &all_lwps. Fetch ptid, lwpid from thread.
8099 (count_events_callback): Update, "entry" parameter is a
8100 struct thread_info * now.
8101 (select_singlestep_lwp_callback): Ditto.
8102 (select_event_lwp_callback): Ditto.
8103 (cancel_breakpoints_callback): Ditto.
8104 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8105 not &all_lwps.
8106 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8107 (unsuspend_one_lwp): Update, "entry" parameter is a
8108 struct thread_info * now.
8109 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8110 not &all_lwps.
8111 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8112 Fetch lwpid from thread, not lwp.
8113 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8114 Pass &all_threads to find_inferior, not &all_lwps.
8115 (send_sigstop): Fetch lwpid from thread, not lwp.
8116 (send_sigstop_callback): Update, "entry" parameter is a
8117 struct thread_info * now.
8118 (suspend_and_send_sigstop_callback): Ditto.
8119 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8120 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8121 struct thread_info * now.
8122 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8123 from thread, lwp.
8124 (lwp_running): Update, "entry" parameter is a
8125 struct thread_info * now.
8126 (stop_all_lwps): Fetch ptid from thread.
8127 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8128 (linux_resume_one_lwp): Fetch lwpid from thread.
8129 (linux_set_resume_request): Update, "entry" parameter is a
8130 struct thread_info * now. Fetch pid, lwpid from thread.
8131 (resume_status_pending_p): Update, "entry" parameter is a
8132 struct thread_info * now.
8133 (need_step_over_p): Ditto. Fetch lwpid from thread.
8134 (start_step_over): Fetch lwpid from thread.
8135 (linux_resume_one_thread): Update, "entry" parameter is a
8136 struct thread_info * now. Fetch lwpid from thread.
8137 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8138 (proceed_one_lwp): Update, "entry" parameter is a
8139 struct thread_info * now. Fetch lwpid from thread.
8140 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8141 struct thread_info * now.
8142 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8143 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8144 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8145 directly.
8146 (regsets_store_inferior_registers): Ditto.
8147 (fetch_register, store_register): Ditto.
8148 (linux_read_memory, linux_write_memory): Ditto.
8149 (linux_request_interrupt): Ditto.
8150 (linux_read_auxv): Ditto.
8151 (linux_xfer_siginfo): Ditto.
8152 (linux_qxfer_spu): Ditto.
8153 (linux_qxfer_libraries_svr4): Ditto.
8154 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8155 moved to inferiors.h.
8156 (get_lwp): Delete.
8157 (get_thread_lwp): Update.
8158 (struct lwp_info): Delete member "entry". Simplify comment for
8159 member "thread".
8160 (all_lwps): Delete.
8161 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8162 current_inferior directly.
8163 (update_watch_registers_callback): Update, "entry" parameter is a
8164 struct thread_info * now. Fetch pid from thread.
8165 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8166 (mips_insert_point): Fetch lwpid from current_inferior.
8167 Pass &all_threads to find_inferior, not &all_lwps.
8168 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8169 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8170 directly.
8171 (mips_stopped_data_address): Ditto.
8172 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8173 directly.
8174 * linux-tile-low.c (tile_arch_setup): Ditto.
8175 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8176 (update_debug_registers_callback): Update, "entry" parameter is a
8177 struct thread_info * now. Fetch pid from thread.
8178 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8179 Pass &all_threads to find_inferior, not &all_lwps.
8180 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8181 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8182 Pass &all_threads to find_inferior, not &all_lwps.
8183 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8184 (i386_dr_low_get_status): Ditto.
8185 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8186 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8187 (x86_linux_read_description): Ditto.
8188 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8189
8190 2014-02-20 Doug Evans <dje@google.com>
8191
8192 * inferiors.c (get_first_inferior): Fix buglet.
8193
8194 2014-02-19 Doug Evans <dje@google.com>
8195
8196 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8197 * inferiors.c (add_thread): Change result type to struct thread_info *.
8198 All callers updated.
8199 (add_lwp): Call add_thread here instead of in callers.
8200 All callers updated.
8201 * linux-low.h (get_lwp_thread): Rewrite.
8202 (struct lwp_info): New member "thread".
8203
8204 2014-02-19 Doug Evans <dje@google.com>
8205
8206 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8207 All callers updated.
8208
8209 2014-02-19 Doug Evans <dje@google.com>
8210
8211 * inferiors.c (add_thread): Fix whitespace.
8212
8213 2014-02-19 Doug Evans <dje@google.com>
8214
8215 * dll.c (clear_dlls): Replace accessing list implemention details
8216 with API function.
8217 * gdbthread.h (get_first_thread): Declare.
8218 * inferiors.c (for_each_inferior_with_data): New function.
8219 (get_first_thread): New function.
8220 (find_thread_ptid): Simplify.
8221 (get_first_inferior): New function.
8222 (clear_list): Delete.
8223 (one_inferior_p): New function.
8224 (clear_inferior_list): New function.
8225 (clear_inferiors): Update.
8226 * inferiors.h (for_each_inferior_with_data): Declare.
8227 (clear_inferior_list): Declare.
8228 (one_inferior_p): Declare.
8229 (get_first_inferior): Declare.
8230 * linux-low.c (linux_wait_for_event): Replace accessing list
8231 implemention details with API function.
8232 * server.c (target_running): Ditto.
8233 (accumulate_file_name_length): New function.
8234 (emit_dll_description): New function.
8235 (handle_qxfer_libraries): Replace accessing list implemention
8236 details with API function.
8237 (handle_qxfer_threads_worker): New function.
8238 (handle_qxfer_threads_proper): Replace accessing list implemention
8239 details with API function.
8240 (handle_query): Ditto.
8241 (visit_actioned_threads_callback_ftype): New typedef.
8242 (visit_actioned_threads_data): New struct.
8243 (visit_actioned_threads): Rewrite to be find_inferior callback.
8244 (resume): Call find_inferior.
8245 (handle_status): Replace accessing list implemention
8246 details with API function.
8247 (process_serial_event): Replace accessing list implemention details
8248 with API function.
8249 * target.c (set_desired_inferior): Replace accessing list implemention
8250 details with API function.
8251 * tracepoint.c (same_process_p): New function.
8252 (gdb_agent_about_to_close): Replace accessing list implemention
8253 details with API function.
8254 * win32-low.c (child_delete_thread): Replace accessing list
8255 implemention details with API function.
8256 (match_dll_by_basename): New function.
8257 (dll_is_loaded_by_basename): New function.
8258 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8259 details call to dll_is_loaded_by_basename.
8260
8261 2014-02-19 Doug Evans <dje@google.com>
8262
8263 * dll.h (struct dll_info): Add comment.
8264 * gdbthread.h (struct thread_info): Add comment.
8265 (current_ptid): Simplify.
8266 * inferiors.c (add_process): Update.
8267 (remove_process): Update.
8268 * inferiors.h (struct process_info): Rename member "head" to "entry".
8269 * linux-low.c (delete_lwp): Update.
8270 (add_lwp): Update.
8271 (last_thread_of_process_p): Update.
8272 (kill_one_lwp_callback, linux_kill): Update.
8273 (status_pending_p_callback): Update.
8274 (wait_for_sigstop): Update. Simplify read of ptid.
8275 (start_step_over): Update.
8276 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8277 (get_lwp_thread): Update.
8278 (struct lwp_info): Rename member "head" to "entry".
8279 * regcache.h (inferior_list_entry): Delete.
8280 * server.c (kill_inferior_callback): Update.
8281 (detach_or_kill_inferior_callback): Update.
8282 (print_started_pid): Update.
8283 (print_attached_pid): Update.
8284 (process_serial_event): Simplify read of ptid.
8285 * thread-db.c (thread_db_create_event): Update.
8286 (thread_db_get_tls_address): Update.
8287 * win32-low.c (current_inferior_ptid): Simplify.
8288
8289 2014-02-19 Tom Tromey <tromey@redhat.com>
8290
8291 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8292 argument.
8293 (target_supports_btrace): Update.
8294
8295 2014-02-14 Yao Qi <yao@codesourcery.com>
8296
8297 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8298 (rsp-low-ipa.o): New target.
8299
8300 2014-02-12 Tom Tromey <tromey@redhat.com>
8301
8302 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8303 convert_ascii_to_int.
8304 * regcache.c (registers_to_string): Likewise.
8305 * remote-utils.c (decode_M_packet): Likewise.
8306 * server.c (process_serial_event): Likewise.
8307
8308 2014-02-12 Tom Tromey <tromey@redhat.com>
8309
8310 * server.c (handle_query, handle_v_run): Use hex2bin, not
8311 unhexify.
8312 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8313
8314 2014-02-12 Tom Tromey <tromey@redhat.com>
8315
8316 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8317 convert_int_to_ascii.
8318 * regcache.c (registers_to_string, collect_register_as_string):
8319 Likewise.
8320 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8321 Likewise.
8322 * server.c (process_serial_event): Likewise.
8323 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8324 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8325
8326 2014-02-12 Tom Tromey <tromey@redhat.com>
8327
8328 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8329 bin2hex, not hexify.
8330 * tracepoint.c (cmd_qtstatus): Likewise.
8331
8332 2014-02-12 Tom Tromey <tromey@redhat.com>
8333
8334 * remote-utils.c (monitor_output): Pass explicit length to
8335 hexify.
8336
8337 2014-02-12 Tom Tromey <tromey@redhat.com>
8338
8339 * tracepoint.c: Include rsp-low.h.
8340 * server.c: Include rsp-low.h.
8341 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8342 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8343 declare.
8344 * remote-utils.c: Include rsp-low.h.
8345 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8346 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8347 (convert_int_to_ascii, convert_ascii_to_int): Move to
8348 common/rsp-low.c.
8349 * regcache.c: Include rsp-low.h.
8350 * ax.c: Include rsp-low.h.
8351 * Makefile.in (SFILES): Add common/rsp-low.c.
8352 (OBS): Add rsp-low.o.
8353 (rsp-low.o): New target.
8354
8355 2014-02-12 Tom Tromey <tromey@redhat.com>
8356
8357 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8358 Include print-utils.h.
8359 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8360 (plongest, thirty_two, phex_nz): Remove.
8361 * Makefile.in (SFILES): Add common/print-utils.c.
8362 (OBS): Add print-utils.o.
8363 (print-utils-ipa.o): New target.
8364 (print-utils.o): New target.
8365 (IPA_OBJS): Add print-utils-ipa.o.
8366
8367 2014-02-06 Tom Tromey <tromey@redhat.com>
8368
8369 * Makefile.in (SFILES): Fix indentation.
8370
8371 2014-02-05 Doug Evans <dje@google.com>
8372
8373 * linux-low.c (linux_wait_for_event): Improve comment.
8374 (linux_wait_1): Keep current_inferior in sync with event_child.
8375
8376 2014-01-22 Doug Evans <dje@google.com>
8377
8378 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8379
8380 2014-01-22 Doug Evans <dje@google.com>
8381
8382 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8383 * configure: Regenerate.
8384 * config.in: Regenerate.
8385 * Makefile.in (SFILES): Add debug.c.
8386 (OBS): Add debug.o.
8387 * debug.c: New file.
8388 * debug.h: New file.
8389 * linux-aarch64-low.c (*): Update all debugging printfs to use
8390 debug_printf instead of fprintf.
8391 * linux-arm-low.c (*): Ditto.
8392 * linux-cris-low.c (*): Ditto.
8393 * linux-crisv32-low.c (*): Ditto.
8394 * linux-m32r-low.c (*): Ditto.
8395 * linux-sparc-low.c (*): Ditto.
8396 * linux-x86.c (*): Ditto.
8397 * linux-low.c (*): Ditto.
8398 (linux_wait_1): Add calls to debug_enter, debug_exit.
8399 (linux_wait): Remove redundant debugging printf.
8400 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8401 (linux_resume, unstop_all_lwps): Ditto.
8402 * mem-break.c (*): Update all debugging printfs to use
8403 debug_printf instead of fprintf.
8404 * remote-utils.c (*): Ditto.
8405 * thread-db.c (*): Ditto.
8406 * server.c #include <ctype.h>, "gdb_vecs.h".
8407 (debug_threads): Moved to debug.c.
8408 (*): Update all debugging printfs to use debug_printf instead of
8409 fprintf.
8410 (start_inferior): Replace call to fflush with call to debug_flush.
8411 (monitor_show_help): Mention set debug-format.
8412 (parse_debug_format_options): New function.
8413 (handle_monitor_command): Handle "monitor set debug-format".
8414 (gdbserver_usage): Mention --debug-format.
8415 (main): Parse --debug-format.
8416 * server.h (debug_threads): Declaration moved to debug.h.
8417 #include "debug.h".
8418 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8419 trace_debug_1 that uses debug_printf.
8420 (tracepoint_look_up_symbols): Update all debugging printfs to use
8421 debug_printf instead of fprintf.
8422
8423 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8424
8425 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8426 sys/ptrace.h.
8427
8428 2014-01-17 Pedro Alves <palves@redhat.com>
8429
8430 PR build/16445
8431 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8432 defined after including gdb_proc_service.h.
8433
8434 2014-01-16 Doug Evans <dje@google.com>
8435
8436 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8437 (match_dll): Use it.
8438
8439 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8440
8441 * target.h (target_ops) <read_btrace>: Change parameters and
8442 return type to allow error reporting.
8443 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8444 trace reading errors on.
8445 * linux-low.c (linux_low_read_btrace): Pass trace reading
8446 errors on.
8447 (linux_low_disable_btrace): New.
8448
8449 2014-01-15 Doug Evans <dje@google.com>
8450
8451 * inferiors.c (thread_id_to_gdb_id): Delete.
8452 * inferiors.h (thread_id_to_gdb_id): Delete.
8453
8454 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8455
8456 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8457 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8458 versions.
8459
8460 2014-01-08 Pedro Alves <palves@redhat.com>
8461
8462 * server.c (handle_status): Don't discard previous queued stop
8463 replies or thread's pending status here.
8464 (main) <disconnection>: Do it here instead.
8465
8466 2014-01-08 Pedro Alves <palves@redhat.com>
8467
8468 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8469 * server.c (visit_actioned_threads, handle_pending_status): New
8470 function.
8471 (handle_v_cont): Factor out parts to ...
8472 (resume): ... this new function. If in all-stop, and a thread
8473 being resumed has a pending status, report it without actually
8474 resuming.
8475 (myresume): Adjust to use the new 'resume' function.
8476 (clear_pending_status_callback, set_pending_status_callback)
8477 (find_status_pending_thread_callback): New functions.
8478 (handle_status): Handle the case of multiple threads having
8479 interesting statuses to report. Report threads' real last signal
8480 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8481 with an interesting thread to report the status for, instead of
8482 always reporting the status of the first thread.
8483
8484 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8485
8486 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8487 * gdbreplay.c (gdbreplay_version): Likewise.
8488
8489 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8490
8491 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8492 iov.iov_len with the real length in use.
8493
8494 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8495
8496 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8497 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8498 for all targets that use win32-low.c.
8499 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8500 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8501
8502 2013-12-13 Pedro Alves <palves@redhat.com>
8503
8504 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8505 if equal to TARGET_WAITKIND_LOADED.
8506 * win32-low.c (cached_status): New static global.
8507 (win32_wait): Add declaration.
8508 (do_initial_child_stuff): Flush all initial pending debug events
8509 up to the initial breakpoint.
8510 (win32_wait): If CACHED_STATUS was set, return that instead
8511 of doing a real wait. Remove the code resuming the execution
8512 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8513 during the initial phase. Also remove the code changing
8514 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8515 TARGET_WAITKIND_STOPPED.
8516
8517 2013-12-11 Yao Qi <yao@codesourcery.com>
8518
8519 * notif.c (handle_notif_ack): Return 0 if no notification
8520 matches.
8521
8522 2013-11-20 Doug Evans <dje@google.com>
8523
8524 * linux-low.c (linux_set_resume_request): Fix comment.
8525
8526 2013-11-20 Doug Evans <dje@google.com>
8527
8528 * linux-low.c (resume_status_pending_p): Tweak comment.
8529
8530 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8531
8532 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8533 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8534 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8535 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8536 (srv_amd64_regobj): Add amd64-mpx.o.
8537 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8538 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8539 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8540 * i387-fp.c (num_pl_bnd_register) Added constant.
8541 (num_pl_bnd_cfg_registers) Added constant.
8542 (struct i387_xsave) Added reserved area and MPX fields.
8543 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8544 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8545 function.
8546 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8547 (init_registers_amd64_mpx_linux): Declare new function.
8548 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8549 (x86_64_regmap): Add MPX registers.
8550 (x86_linux_read_description): Add MPX case.
8551 (initialize_low_arch): Initialize MPX targets.
8552
8553 2013-11-18 Tom Tromey <tromey@redhat.com>
8554
8555 * configure: Rebuild.
8556 * configure.ac: Don't check for stdlib.h.
8557 * gdbreplay.c: Unconditionally include stdlib.h.
8558
8559 2013-11-18 Tom Tromey <tromey@redhat.com>
8560
8561 * config.in: Rebuild.
8562 * configure: Rebuild.
8563 * configure.ac: Don't use AC_HEADER_DIRENT.
8564
8565 2013-11-18 Tom Tromey <tromey@redhat.com>
8566
8567 * server.h: Don't check HAVE_STRING_H.
8568 * gdbreplay.c: Don't check HAVE_STRING_H.
8569 * configure: Rebuild.
8570
8571 2013-11-18 Tom Tromey <tromey@redhat.com>
8572
8573 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8574 LIBGNU.
8575
8576 2013-11-08 Tom Tromey <tromey@redhat.com>
8577
8578 * configure, config.in: Rebuild.
8579 * configure.ac: Remove unused configury.
8580
8581 2013-11-08 Tom Tromey <tromey@redhat.com>
8582
8583 * acinclude.m4: Include common.m4, codeset.m4.
8584 * configure, config.in: Rebuild.
8585 * configure.ac: Use GDB_AC_COMMON.
8586
8587 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
8588
8589 * linux-s390-low.c (HWCAP_S390_TE): New define.
8590 (s390_arch_setup): Consider the TE field in the HWCAP for
8591 determining 'have_regset_tdb'.
8592
8593 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
8594
8595 PR gdb/16014
8596 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
8597 call to sizeof.
8598
8599 2013-10-02 Pedro Alves <palves@redhat.com>
8600
8601 * server.c (process_serial_event): Don't output "GDBserver
8602 exiting" if GDB is connected through stdio.
8603 * target.c (mywait): Likewise, be silent if GDB is connected
8604 through stdio.
8605
8606 2013-10-01 Joel Brobecker <brobecker@adacore.com>
8607
8608 * lynx-low.c (lynx_add_threads_after_attach): New function.
8609 (lynx_attach): Remove call to add_thread. Add call to
8610 lynx_add_threads_after_attach instead.
8611
8612 2013-09-28 Mike Frysinger <vapier@gentoo.org>
8613
8614 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
8615 * config.in, configure: Regenerated.
8616
8617 2013-09-18 Yao Qi <yao@codesourcery.com>
8618
8619 PR server/15959
8620 * server.c (start_inferior): Clear 'resume_info'.
8621
8622 2013-09-16 Jiong Wang <jiwang@tilera.com>
8623
8624 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
8625 for each register.
8626
8627 2013-09-16 Jiong Wang <jiwang@tilera.com>
8628
8629 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
8630 linux-tile-low.o to srv_tgtobj.
8631
8632 2013-09-16 Will Newton <will.newton@linaro.org>
8633
8634 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
8635 out regs.
8636
8637 2013-09-06 Pedro Alves <palves@redhat.com>
8638
8639 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
8640 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
8641 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
8642 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
8643 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
8644 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
8645
8646 2013-09-06 Pedro Alves <palves@redhat.com>
8647
8648 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
8649 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
8650
8651 2013-09-06 Pedro Alves <palves@redhat.com>
8652
8653 * linux-amd64-ipa.c: Include tracepoint.h.
8654 * linux-i386-ipa.c: Include tracepoint.h.
8655
8656 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8657
8658 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
8659 (ps_get_thread_area): New function.
8660
8661 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8662
8663 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
8664 (initialize_low_arch): Call init_registers_crisv32 rather than
8665 init_register_crisv32.
8666
8667 2013-09-05 Pedro Alves <palves@redhat.com>
8668
8669 * server.h (handle_vFile, hostio_last_error_from_errno): Move
8670 to ...
8671 * hostio.h: ... this new file.
8672 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
8673 win32-low.c: Include hostio.h.
8674
8675 2013-09-05 Pedro Alves <palves@redhat.com>
8676
8677 * server.h (gdb_client_data, handler_func, callback_handler_func)
8678 (delete_file_handler, add_file_handler, append_callback_event)
8679 (delete_callback_event, start_event_loop, initialize_event_loop):
8680 Move to event-loop.h and include it.
8681 * event-loop.h: New file.
8682
8683 2013-09-05 Pedro Alves <palves@redhat.com>
8684
8685 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
8686 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
8687 (loaded_dll, unloaded_dll): Move to ...
8688 * dll.h: ... this new file.
8689 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
8690
8691 2013-09-05 Pedro Alves <palves@redhat.com>
8692
8693 * server.h (current_process, get_thread_process, all_processes)
8694 (add_inferior_to_list, for_each_inferior, current_inferior)
8695 (remove_inferior, add_process, remove_process, find_process_pid)
8696 (have_started_inferiors_p, have_attached_inferiors_p)
8697 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
8698 (clear_inferiors, find_inferior, find_inferior_id)
8699 (inferior_target_data, set_inferior_target_data)
8700 (inferior_regcache_data, set_inferior_regcache_data): Move to
8701 inferiors.h, and include it.
8702 * inferiors.h: New file.
8703
8704 2013-09-05 Pedro Alves <palves@redhat.com>
8705
8706 * server.h (struct emit_ops, current_insn_ptr, emit_error):
8707 Move ...
8708 * ax.h: ... here.
8709
8710 2013-09-05 Pedro Alves <palves@redhat.com>
8711
8712 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
8713 tracepoint.h.
8714 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
8715 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
8716 (handle_tracepoint_general_set, handle_tracepoint_query)
8717 (tracepoint_finished_step, tracepoint_was_hit)
8718 (release_while_stepping_state_list, current_traceframe)
8719 (in_readonly_region, traceframe_read_mem)
8720 (fetch_traceframe_registers, traceframe_read_sdata)
8721 (traceframe_read_info, struct fast_tpoint_collect_status)
8722 (fast_tracepoint_collecting, force_unlock_trace_buffer)
8723 (handle_tracepoit_bkpts, initialize_low_tracepoint)
8724 (supply_fast_tracepoint_registers)
8725 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
8726 (ipa_tdesc, claim_trampoline_space)
8727 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
8728 (agent_mem_read, agent_get_trace_state_variable_value)
8729 (agent_set_trace_state_variable_value, agent_tsv_read)
8730 (agent_mem_read_string, get_raw_reg_func_addr)
8731 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
8732 * tracepoint.h: ... this new file.
8733
8734 2013-09-05 Pedro Alves <palves@redhat.com>
8735
8736 * server.h (perror_with_name, error, fatal, warning, paddress)
8737 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
8738 include it.
8739 * utils.h: New file.
8740
8741 2013-09-05 Pedro Alves <palves@redhat.com>
8742
8743 * server.h (remote_debug, noack_mode, transport_is_reliable)
8744 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
8745 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
8746 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
8747 (write_enn, initialize_async_io, enable_async_io)
8748 (disable_async_io, check_remote_input_interrupt_request)
8749 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
8750 (dead_thread_notify, prepare_resume_reply)
8751 (decode_address_to_semicolon, decode_address, decode_m_packet)
8752 (decode_M_packet, decode_X_packet, decode_xfer_write)
8753 (decode_search_memory_packet, unhexify, hexify)
8754 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
8755 (look_up_one_symbol, relocate_instruction)
8756 (monitor_output): Move to remote-utils.h, and include it.
8757 * remote-utils.h: New file.
8758
8759 2013-09-05 Pedro Alves <palves@redhat.com>
8760
8761 * server.h (_): Delete.
8762
8763 2013-09-02 Pedro Alves <palves@redhat.com>
8764
8765 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
8766 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
8767 allocated.
8768 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
8769
8770 2013-09-02 Pierre Muller <muller@sourceware.org>
8771
8772 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
8773 or WriteProcessMemory complete successfully and handle
8774 ERROR_PARTIAL_COPY error.
8775
8776 2013-09-02 Pedro Alves <palves@redhat.com>
8777
8778 * server.c (gdb_read_memory): Return -1 on traceframe memory read
8779 error instead of EIO.
8780
8781 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
8782
8783 PR server/15604
8784 * linux-low.c: Include filestuff.h.
8785 (linux_create_inferior) <pid == 0>: Call close_most_fds.
8786 * lynx-low.c: Include filestuff.h.
8787 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
8788 * server.c: Include filestuff.h.
8789 (main): Call notice_open_fds.
8790 * spu-low.c: Include filestuff.h.
8791 (spu_create_inferior) <pid == 0>: Call close_most_fds.
8792
8793 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
8794
8795 * Makefile.in: Explain why ../target and ../nat are not
8796 listed as include file search paths.
8797 (linux-waitpid.o): New object file rule.
8798 * configure.srv (srv_native_linux_obj): New variable.
8799 Replace all occurrences of linux native object files with
8800 $srv_native_linux_obj.
8801 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
8802 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
8803 (linux_enable_event_reporting): Remove declaration.
8804 (my_waitpid): Moved to common/linux-waitpid.c.
8805 (linux_wait_for_event): Pass ptid when calling
8806 linux_enable_event_reporting.
8807 (linux_supports_tracefork_flag): Remove.
8808 (linux_enable_event_reporting): Likewise.
8809 (linux_tracefork_grandchild): Remove.
8810 (STACK_SIZE): Moved to common/linux-ptrace.c.
8811 (linux_tracefork_child): Remove.
8812 (linux_test_for_tracefork): Remove.
8813 (linux_look_up_symbols): Call linux_supports_traceclone.
8814 (initialize_low): Remove call to linux_test_for_tracefork.
8815 * linux-low.h (PTRACE_TYPE_ARG3): Move to
8816 common/linux-ptrace.h.
8817 (PTRACE_TYPE_ARG4): Likewise.
8818 Include linux-ptrace.h.
8819
8820 2013-08-21 Pedro Alves <palves@redhat.com>
8821
8822 * config.in: Renegerate.
8823
8824 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
8825
8826 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
8827 (SFILES): Remove $(srcdir)/common/target-common.c and
8828 add $(srcdir)/target/waitstatus.c.
8829 (OBS): Remove target-common.o and add waitstatus.o.
8830 (server_h): Remove $(srcdir)/../common/target-common.h and
8831 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
8832 and $(srcdir)/../target/waitstatus.h.
8833 (target-common.o): Remove.
8834 (waitstatus.o): New target object file.
8835 * target.h: Do not include target-common.h and
8836 include target/resume.h, target/wait.h and
8837 target/waitstatus.h.
8838
8839 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
8840
8841 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8842 to PTRACE_TYPE_ARG3.
8843 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8844 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
8845 PTRACE_TYPE_ARG4.
8846 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
8847 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
8848
8849 2013-07-27 Jie Zhang <jie@codesourcery.com>
8850 Daniel Jacobowitz <dan@codesourcery.com>
8851 Yao Qi <yao@codesourcery.com>
8852
8853 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
8854 (mips-linux-watch.o): New rule.
8855 (mips_linux_watch_h): New variable.
8856 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
8857 srv_tgtobj.
8858 * linux-mips-low.c: Include mips-linux-watch.h.
8859 (struct arch_process_info, struct arch_lwp_info): New.
8860 (update_watch_registers_callback): New function.
8861 (mips_linux_new_process, mips_linux_new_thread) New functions.
8862 (mips_linux_prepare_to_resume, mips_insert_point): New
8863 functions.
8864 (mips_remove_point, mips_stopped_by_watchpoint): New
8865 functions.
8866 (rsp_bp_type_to_target_hw_bp_type): New function.
8867 (mips_stopped_data_address): New function.
8868 (the_low_target): Add watchpoint support functions.
8869
8870 2013-07-27 Yao Qi <yao@codesourcery.com>
8871
8872 * i386-low.c: Include break-common.h.
8873 (enum target_hw_bp_type): Remove.
8874
8875 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
8876
8877 * Makefile.in (SFILES): /common/target-common.c.
8878 (OBS): Add target-common.o.
8879 (server_h): Add $(srcdir)/../common/target-common.h.
8880 (target-common.o): New target.
8881 * server.c (queue_stop_reply_callback): Free
8882 status string after use.
8883 * target.c (target_waitstatus_to_string): Remove.
8884 * target.h: Include target-common.h.
8885 (resume_kind): Likewise.
8886 (target_waitkind): Likewise.
8887 (target_waitstatus): Likewise.
8888 (TARGET_WNOHANG): Likewise.
8889
8890 2013-07-04 Yao Qi <yao@codesourcery.com>
8891
8892 * Makefile.in (host_alias): Use @host_noncanonical@.
8893 (target_alias): Use @target_noncanonical@.
8894 * configure.ac: Use ACX_NONCANONICAL_TARGET and
8895 ACX_NONCANONICAL_HOST.
8896 * configure: Regenerated.
8897
8898 Revert:
8899 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8900
8901 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8902 * configure: Rebuild.
8903 * Makefile.in (version_host, version_target): Get from configure.
8904 (version.c): Use $(version_host) and $(version_target).
8905
8906 2013-07-03 Pedro Alves <palves@redhat.com>
8907
8908 * Makefile.in (config.status): Depend on development.sh.
8909 * acinclude.m4: Include libmcheck.m4.
8910 * configure: Regenerate.
8911
8912 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8913
8914 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
8915 attribute inside the parentheses.
8916 (winapi_DebugSetProcessKillOnExit): Ditto.
8917 (winapi_DebugBreakProcess): Ditto.
8918 (winapi_GenerateConsoleCtrlEvent): Ditto.
8919
8920 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8921
8922 * notif.h (notif_event): Add a dummy member to avoid compiler
8923 errors.
8924
8925 2013-07-01 Pedro Alves <palves@redhat.com>
8926
8927 * hostio.c (HOSTIO_PATH_MAX): Define.
8928 (require_filename, handle_open, handle_unlink, handle_readlink):
8929 Use it.
8930
8931 2013-07-01 Pedro Alves <palves@redhat.com>
8932
8933 * server.h: Include "pathmax.h".
8934 * linux-low.c: Don't include sys/param.h.
8935 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
8936 MAXPATHLEN.
8937 * win32-low.c: Don't include sys/param.h.
8938 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
8939
8940 2013-07-01 Pedro Alves <palves@redhat.com>
8941
8942 * event-loop.c: Don't check HAVE_UNISTD_H before including
8943 <unistd.h>.
8944 * gdbreplay.c: Likewise.
8945 * remote-utils.c: Likewise.
8946 * server.c: Likewise.
8947 * configure.ac: Don't check for unistd.h.
8948 * configure: Regenerate.
8949
8950 2013-06-28 Tom Tromey <tromey@redhat.com>
8951
8952 * Makefile.in (version.c): Use version.in, not
8953 common/version.in.
8954
8955 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8956
8957 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8958 * configure: Rebuild.
8959 * Makefile.in (version_host, version_target): Get from configure.
8960 (version.c): Use $(version_host) and $(version_target).
8961
8962 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8963
8964 Fix trace-status to output user name without trailing colon.
8965 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
8966
8967 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8968
8969 Fix trace-status to output proper start-time and stop-time.
8970 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
8971 output start time and stop time in hex as gdb expects.
8972
8973 2013-06-26 Pedro Alves <pedro@codesourcery.com>
8974
8975 * tracepoint.c (build_traceframe_info_xml): Output trace state
8976 variables present in the trace buffer.
8977
8978 2013-06-24 Tom Tromey <tromey@redhat.com>
8979
8980 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
8981 create-version.sh.
8982 (version.o): Remove.
8983 * gdbreplay.c: Include version.h.
8984 (version, host_name): Don't declare.
8985 * server.h: Include version.h.
8986 (version, host_name): Don't declare.
8987
8988 2013-06-12 Pedro Alves <palves@redhat.com>
8989
8990 * linux-x86-low.c (linux_is_elf64): Delete global.
8991 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
8992 with local linux_pid_exe_is_elf_64_file use.
8993
8994 2013-06-11 Pedro Alves <palves@redhat.com>
8995
8996 * linux-low.c (regset_disabled, disable_regset): New functions.
8997 (regsets_fetch_inferior_registers)
8998 (regsets_store_inferior_registers): Use them.
8999 (initialize_regsets_info); Don't allocate the disabled_regsets
9000 array here.
9001 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9002 comment.
9003
9004 2013-06-11 Pedro Alves <palves@redhat.com>
9005
9006 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9007 xmalloc.
9008
9009 2013-06-11 Pedro Alves <palves@redhat.com>
9010
9011 * linux-x86-low.c (initialize_low_arch): Call
9012 init_registers_x32_avx_linux.
9013
9014 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9015
9016 Fix compatibility with Android Bionic.
9017 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9018 it is not empty.
9019
9020 2013-06-07 Pedro Alves <palves@redhat.com>
9021
9022 PR server/14823
9023 * Makefile.in (OBS): Add tdesc.o.
9024 (IPA_OBJS): Add tdesc-ipa.o.
9025 (tdesc-ipa.o): New rule.
9026 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9027 interface.
9028 * linux-low.c (new_inferior): Delete.
9029 (disabled_regsets, num_regsets): Delete.
9030 (linux_add_process): Adjust to set the new per-process
9031 new_inferior flag.
9032 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9033 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9034 was a stop. When calling arch_setup, switch the current inferior
9035 to the thread that got an event.
9036 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9037 (regsets_fetch_inferior_registers)
9038 (regsets_store_inferior_registers): New regsets_info parameter.
9039 Adjust to use it.
9040 (linux_register_in_regsets): New regs_info parameter. Adjust to
9041 use it.
9042 (register_addr, fetch_register, store_register): New usrregs_info
9043 parameter. Adjust to use it.
9044 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9045 parameter regs_info. Adjust to use it.
9046 (linux_fetch_registers): Get the current inferior's regs_info, and
9047 adjust to use it.
9048 (linux_store_registers): Ditto.
9049 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9050 (initialize_low): Don't initialize the target_regsets here. Call
9051 initialize_low_arch.
9052 * linux-low.h (target_regsets): Delete declaration.
9053 (struct regsets_info): New.
9054 (struct usrregs_info): New.
9055 (struct regs_info): New.
9056 (struct process_info_private) <new_inferior>: New field.
9057 (struct linux_target_ops): Delete the num_regs, regmap, and
9058 regset_bitmap fields. New field regs_info.
9059 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9060 * i387-fp.c (num_xmm_registers): Delete.
9061 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9062 calls to new interface.
9063 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9064 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9065 Infer the number of xmm registers from the regcache's target
9066 description.
9067 * i387-fp.h (num_xmm_registers): Delete.
9068 * inferiors.c (add_thread): Don't install the thread's regcache
9069 here.
9070 * proc-service.c (gregset_info): Fetch the current inferior's
9071 regs_info. Adjust to use it.
9072 * regcache.c: Include tdesc.h.
9073 (register_bytes, reg_defs, num_registers)
9074 (gdbserver_expedite_regs): Delete.
9075 (get_thread_regcache): If the thread doesn't have a regcache yet,
9076 create one, instead of aborting gdbserver.
9077 (regcache_invalidate_one): Rename to ...
9078 (regcache_invalidate_thread): ... this.
9079 (regcache_invalidate_one): New.
9080 (regcache_invalidate): Only invalidate registers of the current
9081 process.
9082 (init_register_cache): Add target_desc parameter, and use it.
9083 (new_register_cache): Ditto. Assert the target description has a
9084 non zero registers_size.
9085 (regcache_cpy): Add assertions. Adjust.
9086 (realloc_register_cache, set_register_cache): Delete.
9087 (registers_to_string, registers_from_string): Adjust.
9088 (find_register_by_name, find_regno, find_register_by_number)
9089 (register_cache_size): Add target_desc parameter, and use it.
9090 (free_register_cache_thread, free_register_cache_thread_one)
9091 (regcache_release, register_cache_size): New.
9092 (register_size): Add target_desc parameter, and use it.
9093 (register_data, supply_register, supply_register_zeroed)
9094 (supply_regblock, supply_register_by_name, collect_register)
9095 (collect_register_as_string, collect_register_by_name): Adjust.
9096 * regcache.h (struct target_desc): Forward declare.
9097 (struct regcache) <tdesc>: New field.
9098 (init_register_cache, new_register_cache): Add target_desc
9099 parameter.
9100 (regcache_invalidate_thread): Declare.
9101 (regcache_invalidate_one): Delete declaration.
9102 (regcache_release): Declare.
9103 (find_register_by_number, register_cache_size, register_size)
9104 (find_regno): Add target_desc parameter.
9105 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9106 declarations.
9107 * remote-utils.c: Include tdesc.h.
9108 (outreg, prepare_resume_reply): Adjust.
9109 * server.c: Include tdesc.h.
9110 (gdbserver_xmltarget): Delete declaration.
9111 (get_features_xml, process_serial_event): Adjust.
9112 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9113 declare.
9114 (struct process_info) <tdesc>: New field.
9115 (ipa_tdesc): Declare.
9116 * tdesc.c: New file.
9117 * tdesc.h: New file.
9118 * tracepoint.c: Include tdesc.h.
9119 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9120 (get_context_regcache): Adjust to pass ipa_tdesc down.
9121 (do_action_at_tracepoint): Adjust to get the register cache size
9122 from the context regcache's description.
9123 (traceframe_walk_blocks): Adjust to get the register cache size
9124 from the current trace frame's description.
9125 (traceframe_get_pc): Adjust to get current trace frame's
9126 description and pass it down.
9127 (gdb_collect): Adjust to get the register cache size from the
9128 IPA's description.
9129 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9130 (gdbserver_xmltarget): Delete.
9131 (initialize_low_tracepoint): Set the ipa's target description.
9132 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9133 (initialize_low_tracepoint): Set the ipa's target description.
9134 * linux-x86-low.c: Include tdesc.h.
9135 [__x86_64__] (is_64bit_tdesc): New.
9136 (ps_get_thread_area, x86_get_thread_area): Use it.
9137 (i386_cannot_store_register): Rename to ...
9138 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9139 (i386_cannot_fetch_register): Rename to ...
9140 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9141 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9142 to new interface.
9143 (target_regsets): Rename to ...
9144 (x86_regsets): ... this.
9145 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9146 interface.
9147 (x86_siginfo_fixup): Use is_64bit_tdesc.
9148 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9149 (tdesc_x32_avx_linux, tdesc_x32_linux)
9150 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9151 Declare.
9152 (x86_linux_update_xmltarget): Delete.
9153 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9154 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9155 (AMD64_LINUX_USER64_CS): New.
9156 (x86_linux_read_description): New, based on
9157 x86_linux_update_xmltarget.
9158 (same_process_callback): New.
9159 (x86_arch_setup_process_callback): New.
9160 (x86_linux_update_xmltarget): New.
9161 (x86_regsets_info): New.
9162 (amd64_linux_regs_info): New.
9163 (i386_linux_usrregs_info): New.
9164 (i386_linux_regs_info): New.
9165 (x86_linux_regs_info): New.
9166 (x86_arch_setup): Reimplement.
9167 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9168 (x86_emit_ops): Ditto.
9169 (the_low_target): Adjust. Install x86_linux_regs_info,
9170 x86_cannot_fetch_register, and x86_cannot_store_register.
9171 (initialize_low_arch): New.
9172 * linux-ia64-low.c (tdesc_ia64): Declare.
9173 (ia64_fetch_register): Adjust.
9174 (ia64_usrregs_info, regs_info): New globals.
9175 (ia64_regs_info): New function.
9176 (the_low_target): Adjust.
9177 (initialize_low_arch): New function.
9178 * linux-sparc-low.c (tdesc_sparc64): Declare.
9179 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9180 Adjust.
9181 (sparc_arch_setup): New function.
9182 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9183 (the_low_target): Adjust.
9184 (initialize_low_arch): New function.
9185 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9186 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9187 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9188 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9189 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9190 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9191 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9192 (tdesc_powerpc_isa205_vsx64l): Declare.
9193 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9194 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9195 (ppc_set_pc, ppc_get_hwcap): Adjust.
9196 (ppc_usrregs_info): Forward declare.
9197 (!__powerpc64__) ppc_regmap_adjusted: New global.
9198 (ppc_arch_setup): Adjust to the current process'es target
9199 description.
9200 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9201 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9202 (ppc_store_evrregset): Adjust.
9203 (target_regsets): Rename to ...
9204 (ppc_regsets): ... this, and make static.
9205 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9206 (ppc_regs_info): New function.
9207 (the_low_target): Adjust.
9208 (initialize_low_arch): New function.
9209 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9210 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9211 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9212 (tdesc_s390x_linux64v2): Declare.
9213 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9214 (s390_fill_gregset, s390_store_last_break): Adjust.
9215 (target_regsets): Rename to ...
9216 (s390_regsets): ... this, and make static.
9217 (s390_get_pc, s390_set_pc): Adjust.
9218 (s390_get_hwcap): New target_desc parameter, and use it.
9219 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9220 (s390_arch_setup): Adjust to set the current process'es target
9221 description. Don't adjust the regmap.
9222 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9223 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9224 (regs_info_3264): New globals.
9225 (s390_regs_info): New function.
9226 (the_low_target): Adjust.
9227 (initialize_low_arch): New function.
9228 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9229 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9230 [__mips64] (init_registers_mips_linux)
9231 (init_registers_mips_dsp_linux): Delete defines.
9232 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9233 (have_dsp): New global.
9234 (mips_read_description): New, based on mips_arch_setup.
9235 (mips_arch_setup): Reimplement.
9236 (get_usrregs_info): New function.
9237 (mips_cannot_fetch_register, mips_cannot_store_register)
9238 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9239 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9240 (target_regsets): Rename to ...
9241 (mips_regsets): ... this, and make static.
9242 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9243 (dsp_regs_info, regs_info): New globals.
9244 (mips_regs_info): New function.
9245 (the_low_target): Adjust.
9246 (initialize_low_arch): New function.
9247 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9248 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9249 Declare.
9250 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9251 (arm_read_description): New, with bits factored from
9252 arm_arch_setup.
9253 (arm_arch_setup): Reimplement.
9254 (target_regsets): Rename to ...
9255 (arm_regsets): ... this, and make static.
9256 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9257 (arm_regs_info): New function.
9258 (the_low_target): Adjust.
9259 (initialize_low_arch): New function.
9260 * linux-m68k-low.c (tdesc_m68k): Declare.
9261 (target_regsets): Rename to ...
9262 (m68k_regsets): ... this, and make static.
9263 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9264 (m68k_regs_info): New function.
9265 (m68k_arch_setup): New function.
9266 (the_low_target): Adjust.
9267 (initialize_low_arch): New function.
9268 * linux-sh-low.c (tdesc_sharch): Declare.
9269 (target_regsets): Rename to ...
9270 (sh_regsets): ... this, and make static.
9271 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9272 (sh_regs_info, sh_arch_setup): New functions.
9273 (the_low_target): Adjust.
9274 (initialize_low_arch): New function.
9275 * linux-bfin-low.c (tdesc_bfin): Declare.
9276 (bfin_arch_setup): New function.
9277 (bfin_usrregs_info, regs_info): New globals.
9278 (bfin_regs_info): New function.
9279 (the_low_target): Adjust.
9280 (initialize_low_arch): New function.
9281 * linux-cris-low.c (tdesc_cris): Declare.
9282 (cris_arch_setup): New function.
9283 (cris_usrregs_info, regs_info): New globals.
9284 (cris_regs_info): New function.
9285 (the_low_target): Adjust.
9286 (initialize_low_arch): New function.
9287 * linux-cris-low.c (tdesc_crisv32): Declare.
9288 (cris_arch_setup): New function.
9289 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9290 (cris_regs_info): New function.
9291 (the_low_target): Adjust.
9292 (initialize_low_arch): New function.
9293 * linux-m32r-low.c (tdesc_m32r): Declare.
9294 (m32r_arch_setup): New function.
9295 (m32r_usrregs_info, regs_info): New globals.
9296 (m32r_regs_info): Adjust.
9297 (initialize_low_arch): New function.
9298 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9299 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9300 (tic6x_usrregs_info): Forward declare.
9301 (tic6x_read_description): New function, based on ...
9302 (tic6x_arch_setup): ... this. Reimplement.
9303 (target_regsets): Rename to ...
9304 (tic6x_regsets): ... this, and make static.
9305 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9306 (tic6x_regs_info): New function.
9307 (the_low_target): Adjust.
9308 (initialize_low_arch): New function.
9309 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9310 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9311 (target_regsets): Rename to ...
9312 (xtensa_regsets): ... this, and make static.
9313 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9314 globals.
9315 (xtensa_arch_setup, xtensa_regs_info): New functions.
9316 (the_low_target): Adjust.
9317 (initialize_low_arch): New function.
9318 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9319 (nios2_arch_setup): Set the current process'es tdesc.
9320 (target_regsets): Rename to ...
9321 (nios2_regsets): ... this.
9322 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9323 (nios2_regs_info): New function.
9324 (the_low_target): Adjust.
9325 (initialize_low_arch): New function.
9326 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9327 (aarch64_arch_setup): Set the current process'es tdesc.
9328 (target_regsets): Rename to ...
9329 (aarch64_regsets): ... this.
9330 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9331 (aarch64_regs_info): New function.
9332 (the_low_target): Adjust.
9333 (initialize_low_arch): New function.
9334 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9335 globals.
9336 (target_regsets): Rename to ...
9337 (tile_regsets): ... this.
9338 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9339 (tile_regs_info): New function.
9340 (tile_arch_setup): Set the current process'es tdesc.
9341 (the_low_target): Adjust.
9342 (initialize_low_arch): New function.
9343 * spu-low.c (tdesc_spu): Declare.
9344 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9345 * win32-arm-low.c (tdesc_arm): Declare.
9346 (arm_arch_setup): New function.
9347 (the_low_target): Install arm_arch_setup instead of
9348 init_registers_arm.
9349 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9350 (init_windows_x86): Rename to ...
9351 (i386_arch_setup): ... this. Set `win32_tdesc'.
9352 (the_low_target): Adjust.
9353 * win32-low.c (win32_tdesc): New global.
9354 (child_add_thread): Don't create the thread cache here.
9355 (do_initial_child_stuff): Set the new process'es tdesc.
9356 * win32-low.h (struct target_desc): Forward declare.
9357 (win32_tdesc): Declare.
9358 * lynx-i386-low.c (tdesc_i386): Declare global.
9359 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9360 * lynx-low.c (lynx_tdesc): New global.
9361 (lynx_add_process): Set the new process'es tdesc.
9362 * lynx-low.h (struct target_desc): Forward declare.
9363 (lynx_tdesc): Declare global.
9364 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9365 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9366 * nto-low.c (nto_tdesc): New global.
9367 (do_attach): Set the new process'es tdesc.
9368 * nto-low.h (struct target_desc): Forward declare.
9369 (nto_tdesc): Declare.
9370 * nto-x86-low.c (tdesc_i386): Declare.
9371 (nto_x86_arch_setup): Set `nto_tdesc'.
9372
9373 2013-06-04 Gary Benson <gbenson@redhat.com>
9374
9375 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9376 to qSupported response when appropriate.
9377 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9378 with nonzero-length annex.
9379 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9380 arguments supplied in annex.
9381
9382 2013-05-31 Doug Evans <dje@google.com>
9383
9384 PR server/15594
9385 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9386 64 bits in 64-cross-32 environment.
9387
9388 2013-05-28 Pedro Alves <palves@redhat.com>
9389
9390 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9391 (aarch64-without-fpu.c): Delete rule.
9392 * configure.srv (aarch64*-*-linux*): Remove references to
9393 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9394 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9395 declaration.
9396
9397 2013-05-24 Pedro Alves <palves@redhat.com>
9398
9399 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9400 instead of strchr/decode_address. Error if the range isn't split
9401 with a ','. Don't assume there's be a ':' in the action.
9402
9403 2013-05-23 Yao Qi <yao@codesourcery.com>
9404 Pedro Alves <palves@redhat.com>
9405
9406 * linux-low.c (lwp_in_step_range): New function.
9407 (linux_wait_1): If the thread was range stepping and stopped
9408 outside the stepping range, report the stop to GDB. Otherwise,
9409 continue stepping. Add range stepping debug output.
9410 (linux_set_resume_request): Copy the step range from the resume
9411 request to the lwp.
9412 (linux_supports_range_stepping): New.
9413 (linux_target_ops) <supports_range_stepping>: Set to
9414 linux_supports_range_stepping.
9415 * linux-low.h (struct linux_target_ops)
9416 <supports_range_stepping>: New field.
9417 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9418 * linux-x86-low.c (x86_supports_range_stepping): New.
9419 (the_low_target) <supports_range_stepping>: Set to
9420 x86_supports_range_stepping.
9421 * server.c (handle_v_cont): Handle 'r' action.
9422 (handle_v_requests): Append ";r" if the target supports range
9423 stepping.
9424 * target.h (struct thread_resume) <step_range_start,
9425 step_range_end>: New fields.
9426 (struct target_ops) <supports_range_stepping>:
9427 New field.
9428 (target_supports_range_stepping): New macro.
9429
9430 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9431
9432 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9433 confusion in comment.
9434
9435 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9436
9437 * lynx-low.c (struct process_info_private): New type.
9438 (lynx_add_process): New function.
9439 (lynx_create_inferior, lynx_attach): Replace calls to
9440 add_process by calls to lynx_add_process.
9441 (lynx_resume): If PTID is null, then try using
9442 current_process()->private->last_wait_event_ptid.
9443 Add comments.
9444 (lynx_clear_inferiors): Delete. The contents of that function
9445 has been inlined in lynx_mourn;
9446 (lynx_wait_1): Save the ptid in the process's private data.
9447 (lynx_mourn): Free the process' private data. Replace call
9448 to lynx_clear_inferiors by call to clear_inferiors.
9449
9450 2013-05-17 Yao Qi <yao@codesourcery.com>
9451
9452 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9453 the right place.
9454
9455 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9456
9457 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9458 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9459 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9460 PT_TEXT_END_ADDR guards. Update comments.
9461 (linux_target_op) <read_offsets>: Conditionally define to
9462 linux_read_offsets if the target is UCLIBC and if it defines
9463 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9464
9465 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9466 Andrew Jenner <andrew@codesourcery.com>
9467
9468 * Makefile.in (SFILES): Add linux-nios2-low.c.
9469 (clean): Add action to delete nios2-linux.c.
9470 (nios2-linux.c): New rule.
9471 * configure.srv: Add nios2*-*-linux*.
9472 * linux-nios2-low.c: New.
9473
9474 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9475
9476 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9477
9478 2013-04-25 Hui Zhu <hui@codesourcery.com>
9479
9480 PR gdb/15186
9481 * ax.c (ax_printf): Add fflush.
9482
9483 2013-04-22 Tom Tromey <tromey@redhat.com>
9484
9485 * Makefile.in (SFILES): Add filestuff.c.
9486 (OBS): Add filestuff.o.
9487 (filestuff.o): New target.
9488 * config.in, configure: Rebuild.
9489 * configure.ac: Check for fdwalk, pipe2.
9490
9491 2013-04-17 Pedro Alves <palves@redhat.com>
9492
9493 * configure.ac (USE_THREAD_DB): Delete variable.
9494 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9495 Don't AC_SUBST USE_THREAD_DB.
9496 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9497 * config.in, configure: Regenerate.
9498
9499 2013-04-16 Pedro Alves <palves@redhat.com>
9500
9501 * linux-low.h (struct lwp_info) <thread_known>: Move under
9502 the USE_THREAD_DB #ifdef.
9503
9504 2013-04-16 Pedro Alves <palves@redhat.com>
9505
9506 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9507 (linux-low.o): Delete rule.
9508 * linux-low.h: Always include "gdb_thread_db.h" instead of
9509 conditionally including thread_db.h.
9510 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9511 HAVE_THREAD_DB_H.
9512
9513 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9514
9515 * Makefile.in (install-only): Fix make install regression.
9516
9517 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9518
9519 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9520 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9521 installation.
9522 * gdbserver.1: Remove.
9523
9524 2013-03-22 Pedro Alves <palves@redhat.com>
9525
9526 * linux-low.c (handle_extended_wait): Don't call
9527 linux_enable_event_reporting.
9528
9529 2013-03-15 Tony Theodore <tonyt@logyst.com>
9530
9531 PR build/9098:
9532 * Makefile.in (SHELL): Use @SHELL@.
9533
9534 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9535
9536 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9537 compiler warning.
9538
9539 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9540
9541 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9542 Remove extraneous NULL element.
9543
9544 2013-03-13 Yao Qi <yao@codesourcery.com>
9545
9546 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9547 'V' block in trace frame.
9548
9549 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9550
9551 * target.h (struct target_ops): Add btrace ops.
9552 (target_supports_btrace): New macro.
9553 (target_enable_btrace): New macro.
9554 (target_disable_btrace): New macro.
9555 (target_read_btrace): New macro.
9556 * gdbthread.h (struct thread_info): Add btrace field.
9557 * server.c: Include btrace-common.h.
9558 (handle_btrace_general_set): New function.
9559 (handle_btrace_enable): New function.
9560 (handle_btrace_disable): New function.
9561 (handle_general_set): Call handle_btrace_general_set.
9562 (handle_qxfer_btrace): New function.
9563 (struct qxfer qxfer_packets[]): Add btrace entry.
9564 * inferiors.c (remove_thread): Disable btrace.
9565 * linux-low: Include linux-btrace.h.
9566 (linux_low_enable_btrace): New function.
9567 (linux_low_read_btrace): New function.
9568 (linux_target_ops): Add btrace ops.
9569 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9570 Add srv_linux_btrace=yes.
9571 (x86_64-*-linux*): Add linux-btrace.o.
9572 Add srv_linux_btrace=yes.
9573 * configure.ac: Define HAVE_LINUX_BTRACE.
9574 * config.in: Regenerated.
9575 * configure: Regenerated.
9576
9577 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9578
9579 * server.c (handle_qxfer): Preserve error message if -3 is
9580 returned.
9581 (qxfer): Document the -3 return value.
9582
9583 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9584
9585 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
9586 (linux_btrace_h): New variable.
9587 (linux-btrace.o): New rule.
9588
9589 2013-03-08 Stan Shebs <stan@codesourcery.com>
9590 Hafiz Abid Qadeer <abidh@codesourcery.com>
9591
9592 * tracepoint.c (trace_buffer_size): New global.
9593 (DEFAULT_TRACE_BUFFER_SIZE): New define.
9594 (init_trace_buffer): Change to one-argument function. Allocate
9595 trace buffer memory.
9596 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
9597 handle QTBuffer:size packet.
9598 (cmd_bigqtbuffer_size): New function.
9599 (initialize_tracepoint): Call init_trace_buffer with
9600 DEFAULT_TRACE_BUFFER_SIZE.
9601 * server.c (handle_query): Add QTBuffer:size in the
9602 supported packets.
9603
9604 2013-03-07 Yao Qi <yao@codesourcery.com>
9605
9606 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
9607 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
9608 of -1.
9609 (cmd_qtsp): Adjust condition. Do post increment.
9610 Set cur_action and cur_step_action back to 0.
9611
9612 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
9613
9614 PR server/15236
9615 * linux-low.c (linux_write_memory): Return early success if LEN is
9616 zero.
9617
9618 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
9619
9620 * configure.srv: Add x86_64-*-cygwin* as target.
9621
9622 2013-02-28 Tom Tromey <tromey@redhat.com>
9623
9624 * configure.ac: Invoke AC_SYS_LARGEFILE.
9625 * configure, config.in: Rebuild.
9626
9627 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
9628
9629 * win32-low.c: Throughout, fix format strings and casts of
9630 printf-like functions to avoid type related warnings on all
9631 platforms.
9632 (get_child_debug_event): Print dwDebugEventCode as hex since
9633 that's how it's usually documented.
9634
9635 2013-02-28 Yao Qi <yao@codesourcery.com>
9636
9637 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
9638 pulongest.
9639
9640 2013-02-27 Jiong Wang <jiwang@tilera.com>
9641
9642 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
9643 (reg-tilegx32.c): New rule.
9644 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
9645 * linux-tile-low.c (tile_arch_setup): New function. Invoke
9646 different register info initializer according to elf class.
9647 (init_registers_tilgx32): New function. The tilegx32 register info
9648 initializer.
9649 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
9650 (tile_store_gregset): Likewise.
9651
9652 2013-02-27 Yao Qi <yao@codesourcery.com>
9653
9654 * server.c (process_point_options): Print debug message when
9655 debug_threads is true.
9656
9657 2013-02-26 Yao Qi <yao@codesourcery.com>
9658
9659 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
9660
9661 2013-02-19 Pedro Alves <palves@redhat.com>
9662 Kai Tietz <ktietz@redhat.com>
9663
9664 PR gdb/15161
9665
9666 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
9667 instead of strtoul to extract address from packet.
9668 (process_serial_event) <'z'>: Likewise.
9669
9670 2013-02-18 Yao Qi <yao@codesourcery.com>
9671
9672 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
9673
9674 2013-02-14 Pedro Alves <palves@redhat.com>
9675
9676 Plug memory leak.
9677
9678 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
9679 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
9680
9681 2013-02-14 Pedro Alves <palves@redhat.com>
9682
9683 * tracepoint.c (cmd_qtdpsrc): Use savestring.
9684
9685 2013-02-14 Pedro Alves <palves@redhat.com>
9686
9687 * tracepoint.c (save_string): Delete.
9688 (add_tracepoint_action): Use savestring instead of save_string.
9689
9690 2013-02-12 Pedro Alves <palves@redhat.com>
9691
9692 * linux-xtensa-low.c: Ditto.
9693 * xtensa-xtregs.c: Ditto.
9694
9695 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
9696
9697 * thread-db.c (thread_db_get_tls_address): NULL pointer check
9698 thread_db.
9699
9700 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
9701
9702 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
9703 aarch64_num_wp_regs and aarch64_num_bp_regs to
9704 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
9705
9706 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
9707
9708 * linux-aarch64-low.c (ps_get_thread_area): Replace
9709 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
9710
9711 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
9712 Marcus Shawcroft <marcus.shawcroft@arm.com>
9713 Nigel Stephens <nigel.stephens@arm.com>
9714 Yufeng Zhang <yufeng.zhang@arm.com>
9715
9716 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
9717 (aarch64.c, aarch64-without-fpu.c): New targets.
9718 * configure.srv (aarch64*-*-linux*): New.
9719 * linux-aarch64-low.c: New file.
9720
9721 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
9722
9723 * linux-low.c (handle_extended_wait, linux_create_inferior)
9724 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
9725 (dequeue_one_deferred_signal, linux_resume_one_thread)
9726 (fetch_register, linux_write_memory, linux_enable_event_reporting)
9727 (linux_tracefork_grandchild, linux_test_for_tracefork)
9728 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
9729 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
9730 where the argument is 0.
9731
9732 2013-01-25 Yao Qi <yao@codesourcery.com>
9733
9734 * event-loop.c: Include "queue.h".
9735 (gdb_event_p): New typedef.
9736 (struct gdb_event) <next_event>: Remove.
9737 (event_queue): Change to QUEUE(gdb_event_p).
9738 (async_queue_event): Remove.
9739 (gdb_event_xfree): New.
9740 (initialize_event_loop): New.
9741 (process_event): Use API from QUEUE.
9742 (wait_for_event): Likewise.
9743 * server.c (main): Call initialize_event_loop.
9744 * server.h (initialize_event_loop): Declare.
9745
9746 2013-01-18 Yao Qi <yao@codesourcery.com>
9747
9748 * ax.h (struct eval_agent_expr_context): New.
9749 (gdb_eval_agent_expr): Update declaration.
9750 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
9751 TFRAME. Add new argument CTX.
9752 * server.h (struct eval_agent_expr_context): Declare.
9753 (agent_mem_read, agent_tsv_read): Update declaration.
9754 (agent_mem_read_string): Likewise.
9755 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
9756 (add_traceframe_block): Add new argument TPOINT.
9757 Increase TPOINT->traceframe_usage.
9758 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
9759 eval_tracepoint_agent_expr.
9760 (condition_true_at_tracepoint): Likewise.
9761 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
9762 (agent_mem_read_string, agent_tsv_read): Likewise.
9763
9764 2013-01-16 Yao Qi <yao@codesourcery.com>
9765
9766 * linux-low.c (linux_resume_one_lwp): Don't check
9767 'lwp->bp_reinsert != 0'.
9768
9769 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9770 Pedro Alves <palves@redhat.com>
9771
9772 * lynx-low.c (ptrace_request_to_str): Define a temporary
9773 macro and use it to simplify this function's implementation.
9774
9775 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9776
9777 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
9778 sets errno.
9779
9780 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9781
9782 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
9783
9784 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9785
9786 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
9787
9788 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9789
9790 * lynx-low.c (lynx_resume): Use the resume_info parameter
9791 to determine the ptid for the lynx_ptrace call, unless
9792 it is equal to minus_one_ptid, in which case we use the
9793 ptid of the current_inferior.
9794 (lynx_wait_1): After having received a thread create/exit
9795 event, resume the inferior's execution using the signaling
9796 thread's ptid, rather than the old ptid.
9797
9798 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9799
9800 * lynx-low.c (lynx_resume): Delete variable ret.
9801
9802 2013-01-01 Joel Brobecker <brobecker@adacore.com>
9803
9804 * gdbreplay.c (gdbreplay_version): Update copyright year.
9805 * server.c (gdbserver_version): Likewise.
9806
9807 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9808
9809 * lynx-low.c (lynx_wait_1): Add debug trace before adding
9810 new thread.
9811
9812 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9813
9814 * lynx-low.c (ptrace_request_to_str): Add handling for
9815 PTRACE_GETTRACESIG.
9816
9817 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9818
9819 * lynx-low.c (lynx_attach): Delete variable new_process.
9820
9821 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9822
9823 * lynx-low.c (lynx_create_inferior): Delete variable
9824 new_process.
9825
9826 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9827
9828 * lynx-low.c (ptrace_request_to_str): Do not handle
9829 PTRACE_GETTHREADLIST if this macro does not exist.
9830
9831 2012-12-15 Yao Qi <yao@codesourcery.com>
9832
9833 * Makefile.in (OBS): Add notif.o.
9834 * notif.c, notif.h: New.
9835 * server.c: Include "notif.h".
9836 (struct vstop_notif) <next>: Remove.
9837 <base>: New field.
9838 (queue_stop_reply): Update.
9839 (push_event, send_next_stop_reply): Remove.
9840 (discard_queued_stop_replies): Update.
9841 (notif_stop): New variable.
9842 (handle_v_stopped): Remove.
9843 (handle_v_requests): Don't call handle_v_stopped. Call
9844 handle_ack_notif instead.
9845 (queue_stop_reply_callback): Call notif_event_enque instead
9846 of queue_stop_reply.
9847 (handle_status): Don't call send_next_stop_reply, call
9848 notif_write_event instead.
9849 (kill_inferior_callback): Likewise.
9850 (detach_or_kill_inferior_callback): Likewise.
9851 (main): Call initialize_notif.
9852 (process_serial_event): Call QUEUE_is_empty.
9853 (handle_target_event): Call notif_push instead of push event.
9854 * server.h (push_event): Remove declaration.
9855
9856 2012-12-10 Tom Tromey <tromey@redhat.com>
9857
9858 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
9859 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
9860 macros.
9861 (.c.o): Rewrite.
9862 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
9863 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
9864 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
9865 (amd64-linux-ipa.o, ax.o): Rewrite.
9866 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
9867 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
9868 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
9869 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
9870 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
9871 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
9872 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
9873 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
9874 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
9875 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
9876 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
9877 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
9878 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
9879 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
9880 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
9881 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
9882 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
9883 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
9884 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
9885 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
9886 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
9887 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
9888 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
9889 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
9890 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
9891 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
9892 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
9893 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
9894 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
9895 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
9896 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
9897 (reg-tilegx.o): Remove.
9898 (all_object_files): New macro.
9899 Include .deps files.
9900 * aclocal.m4, configure: Rebuild.
9901 * acinclude.m4: Include depstand.m4, lead-dot.m4.
9902 * configure.ac: Invoke ZW_CREATE_DEPDIR,
9903 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
9904
9905 2012-12-05 Tom Tromey <tromey@redhat.com>
9906
9907 PR gdb/14917:
9908 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
9909
9910 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
9911
9912 * configure.ac: Check for linux/perf_event.h.
9913 * config.in: Regenerated.
9914 * configure: Regenerated.
9915
9916 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
9917
9918 * hostio.c (handle_readlink): Decrease buffer size
9919 parameter passed to readlink by one byte.
9920
9921 2012-11-26 Yao Qi <yao@codesourcery.com>
9922
9923 * configure.ac (build_warnings): Append '-Wempty-body'.
9924 * configure: Regenerated.
9925 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
9926 body.
9927
9928 2012-11-15 Pierre Muller <muller@sourceware.org>
9929
9930 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
9931 * config.in: Regenerate.
9932 * configure: Regenerate.
9933 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
9934 Use "gdb_wait.h" header instead of <sys/wait.h> header.
9935 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9936 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
9937 header.
9938 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
9939 instead of <sys/wait.h> header.
9940 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9941
9942 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
9943
9944 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
9945 (various make rules): Remove -DGDBSERVER
9946
9947 2012-11-09 Yao Qi <yao@codesourcery.com>
9948
9949 * spu-low.c (current_ptid): Move it to ..
9950 * gdbthread.h: ... here. New.
9951 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
9952 * server.c (myresume, process_serial_event): Likewise.
9953 * thread-db.c (thread_db_find_new_threads): Likewise.
9954 * tracepoint.c (run_inferior_command): Likewise.
9955
9956 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
9957
9958 * server.c (handle_search_memory_1): Include access length in
9959 warning message.
9960
9961 2012-09-05 Michael Brandt <michael.brandt@axis.com>
9962
9963 * linux-crisv32-low.c: Fix compile errors.
9964
9965 2012-09-04 Yao Qi <yao@codesourcery.com>
9966
9967 * tracepoint.c (cmd_qtsv): Adjust debug message.
9968 Don't check CUR_TPOINT.
9969
9970 2012-08-28 Yao Qi <yao@codesourcery.com>
9971
9972 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
9973 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
9974 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
9975 Remove declarations of xmalloc, xreallloc, xstrdup and
9976 freeargv.
9977 * Makefile.in (libiberty_h): New.
9978 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
9979 (linux-bfin-low.o): Append dependency 'libiberty.h'.
9980
9981 2012-08-23 Yao Qi <yao@codesourcery.com>
9982
9983 * server.h: Remove declaration of 'xsnprintf'.
9984
9985 2012-08-22 Keith Seitz <keiths@redhat.com>
9986
9987 * server.h: Include build-gnulib-gbserver/config.h.
9988 * gdbreplay.c: Likewise.
9989
9990 2012-08-08 Doug Evans <dje@google.com>
9991
9992 * Makefile.in (SFILES): Add gdb_vecs.c.
9993 (OBS): Add gdb_vecs.o.
9994 (gdb_vecs_h, host_defs_h): New variables.
9995 (thread-db.o): Add $(gdb_vecs_h) dependency.
9996 (gdb_vecs.o): New rule.
9997 * thread-db.c: #include "gdb_vecs.h".
9998 (thread_db_load_search): Use a vector to iterate over path elements.
9999 Handle text appearing after "$pdir".
10000
10001 * configure.ac: Add check for strstr.
10002 * config.in: Regenerate.
10003 * configure: Regenerate.
10004
10005 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10006
10007 * hostio.c (handle_pread): If pread fails, fall back to attempting
10008 lseek/read.
10009 (handle_pwrite): Likewise for pwrite.
10010
10011 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10012
10013 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10014 between unsupported TYPE and unimplementable ADDR/LEN combination.
10015 (arm_insert_point): Act on new return value.
10016
10017 2012-07-31 Pedro Alves <palves@redhat.com>
10018
10019 * server.c (process_point_options): Only skip tokens if we find
10020 one that is unrecognized. Don't treat 'X' specially while
10021 skipping unrecognized tokens.
10022
10023 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10024
10025 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10026 to 4-byte-align HW breakpoint addresses for Thumb.
10027
10028 2012-07-27 Yao Qi <yao@codesourcery.com>
10029
10030 PR remote/14161.
10031
10032 * server.h: Declare gdb_agent_about_to_close.
10033 * target.c (kill_inferior): Include "agent.h".
10034 New. Send command 'kill'.
10035 * target.h (kill_inferior): Removed macro.
10036 * tracepoint.c (gdb_agent_about_to_close): New.
10037 (gdb_agent_helper_thread): Handle command 'close'.
10038 Wait endlessly until the inferior stops.
10039 Install gdb_agent_remove_socket to atexit hook.
10040 (agent_socket_name): New static variable.
10041 (gdb_agent_socket_init): Replace local variable 'name' with
10042 'agent_socket_name'.
10043 (gdb_agent_remove_socket): New.
10044
10045 2012-07-27 Yao Qi <yao@codesourcery.com>
10046
10047 * server.c (process_point_options): Stop at 'X' when parsing.
10048
10049 2012-07-19 Michael Eager <eager@eagercon.com>
10050
10051 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10052 to hw_execute.
10053 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10054 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10055 hardware breakpoint.
10056
10057 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10058
10059 * gdbserver/linux-low.c (initialize_low): Call
10060 linux_ptrace_init_warnings.
10061
10062 2012-07-02 Doug Evans <dje@google.com>
10063
10064 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10065 pointer to int.
10066
10067 2012-07-02 Stan Shebs <stan@codesourcery.com>
10068
10069 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10070 (ax.o): Add it to build rule.
10071 (ax-ipa.o): Ditto.
10072 (OBS): Add format.o.
10073 (IPA_OBS): Add format.o.
10074 * server.c (handle_query): Claim support for breakpoint commands.
10075 (process_point_options): Add command case.
10076 (process_serial_event): Leave running if there are printfs in
10077 effect.
10078 * mem-break.h (any_persistent_commands): Declare.
10079 (add_breakpoint_commands): Declare.
10080 (gdb_no_commands_at_breakpoint): Declare.
10081 (run_breakpoint_commands): Declare.
10082 * mem-break.c (struct point_command_list): New struct.
10083 (struct breakpoint): New field command_list.
10084 (any_persistent_commands): New function.
10085 (add_commands_to_breakpoint): New function.
10086 (add_breakpoint_commands): New function.
10087 (gdb_no_commands_at_breakpoint): New function.
10088 (run_breakpoint_commands): New function.
10089 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10090 locally.
10091 * ax.c: Include format.h.
10092 (ax_printf): New function.
10093 (gdb_eval_agent_expr): Add printf opcode.
10094
10095 2012-06-13 Yao Qi <yao@codesourcery.com>
10096
10097 * server.c (start_inferior): Remove duplicated writes to fields
10098 'last_resume_kind' and 'last_status' of 'current_inferior'.
10099
10100 2012-06-12 Yao Qi <yao@codesourcery.com>
10101 Pedro Alves <palves@redhat.com>
10102
10103 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10104 comment.
10105 * server.c (handle_v_cont): Extend comment.
10106
10107 2012-06-11 Yao Qi <yao@codesourcery.com>
10108
10109 * linux-low.c (linux_attach): Add 'static'.
10110
10111 2012-06-06 Yao Qi <yao@codesourcery.com>
10112
10113 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10114
10115 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10116
10117 Fix gcc -flto compilation warning.
10118 * server.c (main): Make variable multi_mode and attach volatile.
10119
10120 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10121
10122 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10123 if the platform doesn't know about it.
10124
10125 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10126
10127 * Makefile.in (SFILES): Add linux-tile-low.c.
10128 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10129 * configure.srv: Handle tilegx-*-linux*.
10130 * linux-tile-low.c: New file.
10131
10132 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10133
10134 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10135
10136 2012-05-24 Pedro Alves <palves@redhat.com>
10137
10138 PR gdb/7205
10139
10140 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10141
10142 2012-05-24 Pedro Alves <palves@redhat.com>
10143
10144 PR gdb/7205
10145
10146 Replace target_signal with gdb_signal throughout.
10147
10148 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10149
10150 * linux-low.c (linux_store_registers): Avoid the copying sequence
10151 when no data has been retrieved by ptrace.
10152
10153 2012-05-22 Will Deacon <will.deacon@arm.com>
10154
10155 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10156 Include asm/ptrace.h.
10157 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10158 already defined.
10159
10160 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10161
10162 * linux-low.c (linux_store_registers): Don't re-retrieve data
10163 with ptrace that has already been obtained from /proc. Always
10164 copy any data retrieved with ptrace to the buffer supplied.
10165
10166 2012-05-11 Yao Qi <yao@codesourcery.com>
10167 Pedro Alves <palves@redhat.com>
10168
10169 * linux-low.c (enum stopping_threads_kind): New.
10170 (stopping_threads): Change type to `enum stopping_threads_kind'.
10171 (handle_extended_wait): If stopping and suspending threads, leave
10172 the new_lwp suspended too.
10173 (linux_wait_for_event): Adjust.
10174 (stop_all_lwps): Set `stopping_threads' to
10175 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10176 whether we're suspending threads or just stopping them. Assert no
10177 recursion happens.
10178
10179 2012-04-29 Yao Qi <yao@codesourcery.com>
10180
10181 * server.h: Move some code to ...
10182 * gdbthread.h: ... here. New.
10183 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10184 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10185 (nto-low.o, win32-low.o): Likewise.
10186 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10187 * regcache.c, remote-utils.c, server.c: Likewise.
10188 * target.c, tracepoint.c, win32-low.c: Likewise.
10189
10190 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10191
10192 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10193 (PTRACE_ARG4_TYPE): Likewise.
10194 (PTRACE_XFER_TYPE): Likewise.
10195 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10196 ptrace to PTRACE_ARG3_TYPE.
10197 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10198 (PTRACE_ARG4_TYPE): Likewise.
10199 (PTRACE_XFER_TYPE): Likewise.
10200 (linux_detach_one_lwp): Cast fourth argument of
10201 ptrace to long then PTRACE_ARG4_TYPE.
10202 (regsets_fetch_inferior_registers): Cast third argument of
10203 ptrace to long then PTRACE_ARG3_TYPE.
10204 (regsets_store_inferior_registers): Likewise.
10205
10206 2012-04-20 Pedro Alves <palves@redhat.com>
10207
10208 * configure: Regenerate.
10209
10210 2012-04-19 Pedro Alves <palves@redhat.com>
10211
10212 * Makefile.in (GNULIB_BUILDDIR): New.
10213 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10214 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10215 (all, install-only, uninstall, clean-info, all-lib, clean): No
10216 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10217 (maintainer-clean realclean distclean): Use subdir_do.
10218 (subdir_do): New.
10219 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10220 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10221 * acinclude.m4: Include acx_configure_dir.m4.
10222 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10223 calls. Call AC_PROG_RANLIB. Configure gnulib using
10224 ACX_CONFIGURE_DIR.
10225 (GNULIB): New.
10226 (GNULIB_STDINT_H): Adjust.
10227 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10228 * gdbreplay.c: Include build-gnulib/config.h.
10229 * server.h: Likewise.
10230 * aclocal.m4: Regenerate.
10231 * config.in: Regenerate.
10232 * configure: Regenerate.
10233
10234 2012-04-19 Pedro Alves <palves@redhat.com>
10235
10236 * Makefile.in (LIBGNU, INCGNU): Adjust.
10237 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10238 (all, install-only, uninstall, clean-info, all-lib, clean)
10239 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10240 * configure.ac: Adjust AC_OUTPUT output.
10241 * aclocal.m4: Regenerate.
10242 * configure: Regenerate.
10243
10244 2012-04-19 Pedro Alves <palves@redhat.com>
10245
10246 * Makefile.in (generated_files): New.
10247 (server_h): Remove the explicit dependency on config.h, and depend
10248 on $generated_files.
10249
10250 2012-04-19 Pedro Alves <palves@redhat.com>
10251
10252 * Makefile.in (INCGNU): Add -Ignulib.
10253
10254 2012-04-19 Pedro Alves <palves@redhat.com>
10255
10256 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10257 (INCGNU): ... this, and spell out -I here.
10258 (GNULIB_LIB): Rename to ...
10259 (LIBGNU): ... this.
10260 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10261
10262 2012-04-19 Pedro Alves <palves@redhat.com>
10263
10264 * config.in: Regenerate.
10265
10266 2012-04-19 Pedro Alves <palves@redhat.com>
10267
10268 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10269 * server.h (memmem): Remove declaration.
10270 * config.in: Regenerate.
10271 * configure: Regenerate.
10272
10273 2012-04-19 Yao Qi <yao@codesourcery.com>
10274
10275 * Makefile.in (SFILES): Add common/vec.c.
10276 (OBS): Add vec.o.
10277 (vec.o): New rule.
10278
10279 2012-04-19 Yao Qi <yao@codesourcery.com>
10280
10281 * remote-utils.c (prepare_resume_reply): Replace with macro
10282 target_core_of_thread.
10283 * server.c (handle_qxfer_threads_proper): Likewise.
10284 * target.h (traget_core_of_thread): New macro.
10285
10286 2012-04-18 Pedro Alves <palves@redhat.com>
10287
10288 * aclocal.m4: Regenerate.
10289 * configure: Regenerate.
10290
10291 2012-04-16 Yao Qi <yao@codesourcery.com>
10292
10293 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10294 duplicated on address.
10295
10296 2012-04-16 Yao Qi <yao@codesourcery.com>
10297
10298 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10299 (struct tracepoint_action_ops) <send>: New field.
10300 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10301 (agent_expr_send, x_tracepoint_action_send): New.
10302 (l_tracepoint_action_send): New.
10303 (cmd_qtdp): Download and install tracepoint
10304 according to `use_agent'.
10305 (run_inferior_command): Add one more parameter `len'.
10306 Update callers.
10307 (tracepoint_send_agent): New.
10308 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10309
10310 2012-04-16 Yao Qi <yao@codesourcery.com>
10311
10312 * tracepoint.c (download_tracepoints): Moved to ...
10313 (cmd_qtstart): ... here.
10314
10315 2012-04-14 Yao Qi <yao@codesourcery.com>
10316
10317 * tracepoint.c: Include inttypes.h.
10318 (struct collect_memory_action): Use sized types.
10319 (struct tracepoint): Likewise.
10320 (cmd_qtdp, stop_tracing): Update print specifiers.
10321 (cmd_qtp, response_tracepoint): Likewise.
10322 (collect_data_at_tracepoint): Likewise.
10323 (collect_data_at_step): Likewise.
10324
10325 2012-04-14 Yao Qi <yao@codesourcery.com>
10326
10327 Import gnulib module inttypes.
10328 * aclocal.m4, config.in, configure: Regenerated.
10329
10330 2012-04-14 Yao Qi <yao@codesourcery.com>
10331
10332 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10333 Makefile and config.status at last.
10334
10335 2012-04-13 Yao Qi <yao@codesourcery.com>
10336
10337 * tracepoint.c: Include stdint.h unconditionally.
10338
10339 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10340
10341 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10342 on BFD_HAVE_SYS_PROCFS_TYPE.
10343 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10344 * configure: Regenerate.
10345 * config.in: Likewise.
10346
10347 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10348
10349 * Makefile.in (clean): Also remove x32.c x32-linux.c
10350 x32-avx.c x32-avx-linux.c.
10351 (x32.o): New target.
10352 (x32.c): Likewise.
10353 (x32-linux.o): Likewise.
10354 (x32-linux.c): Likewise.
10355 (x32-avx.o): Likewise.
10356 (x32-avx.c): Likewise.
10357 (x32-avx-linux.o): Likewise.
10358 (x32-avx-linux.c): Likewise.
10359
10360 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10361 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10362 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10363 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10364 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10365 i386/x32-avx-linux.xml.
10366
10367 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10368 (init_registers_x32_avx_linux): Likwise.
10369 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10370 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10371
10372 2012-04-13 Pedro Alves <palves@redhat.com>
10373
10374 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10375 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10376 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10377 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10378 the sub-make.
10379
10380 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10381
10382 * linux-x86-low.c (compat_x32_clock_t): New.
10383 (compat_x32_siginfo_t): Likewise.
10384 (compat_x32_siginfo_from_siginfo): Likewise.
10385 (siginfo_from_compat_x32_siginfo): Likewise.
10386 (linux_is_elf64): Likewise.
10387 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10388 and siginfo_from_compat_x32_siginfo for x32.
10389 (x86_arch_setup): Set linux_is_elf64.
10390
10391 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10392
10393 PR gdb/13969
10394 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10395 e_machine field.
10396 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10397 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10398 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10399 compatible with process.
10400
10401 2012-04-12 Yao Qi <yao@codesourcery.com>
10402
10403 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10404 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10405 (install-only, install-info, clean): Handle sub dir gnulib.
10406 (all-lib, am--refresh): New targets.
10407 (memmem.o): Remove target.
10408 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10409 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10410 (AC_REPLACE_FUNCS): Remove memmem.
10411 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10412 (AC_OUTPUT): Generate Makefile in gnulib/.
10413 * aclocal.m4, config.in, configure: Regenerated.
10414
10415 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10416
10417 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10418
10419 2012-04-05 Pedro Alves <palves@redhat.com>
10420
10421 -Werror=strict-aliasing
10422
10423 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10424 pointer.
10425
10426 2012-04-04 Pedro Alves <palves@redhat.com>
10427
10428 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10429 (sparc_store_gregset_from_stack, sparc_store_gregset)
10430 (sparc_breakpoint_at): Fix formatting.
10431
10432 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10433
10434 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10435 are available.
10436 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10437 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10438 * config.in: Regenerate.
10439 * configure: Likewise.
10440
10441 2012-03-29 Pedro Alves <palves@redhat.com>
10442
10443 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10444 Correct ptrace arguments.
10445
10446 2012-03-28 Pedro Alves <palves@redhat.com>
10447
10448 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10449 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10450 (IA64_FR1_REGNUM): New defines.
10451 (ia64_fetch_register): New.
10452 (the_low_target): Install it.
10453 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10454 field.
10455 * linux-low.c (linux_fetch_registers): Try the
10456 the_low_target.fetch_register hook first.
10457
10458 * linux-arm-low.c (the_low_target): Adjust.
10459 * linux-bfin-low.c (the_low_target): Adjust.
10460 * linux-cris-low.c (the_low_target): Adjust.
10461 * linux-crisv32-low.c (the_low_target): Adjust.
10462 * linux-m32r-low.c (the_low_target): Adjust.
10463 * linux-m68k-low.c (the_low_target): Adjust.
10464 * linux-mips-low.c (the_low_target): Adjust.
10465 * linux-ppc-low.c (the_low_target): Adjust.
10466 * linux-s390-low.c (the_low_target): Adjust.
10467 * linux-sh-low.c (the_low_target): Adjust.
10468 * linux-sparc-low.c (the_low_target): Adjust.
10469 * linux-tic6x-low.c (the_low_target): Adjust.
10470 * linux-x86-low.c (the_low_target): Adjust.
10471 * linux-xtensa-low.c (the_low_target): Adjust.
10472
10473 2012-03-26 Pedro Alves <palves@redhat.com>
10474
10475 * server.c (handle_qxfer_libraries): Don't bail early if
10476 the_target->qxfer_libraries_svr4 is not NULL.
10477
10478 2012-03-26 Pedro Alves <palves@redhat.com>
10479
10480 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10481
10482 2012-03-23 Pedro Alves <palves@redhat.com>
10483
10484 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10485 "library-list-svr4" element's start tag when the the DSO list is
10486 empty.
10487
10488 2012-03-23 Pedro Alves <palves@redhat.com>
10489
10490 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10491 a variable whose type size is the same as the inferior's pointer
10492 size.
10493
10494 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10495
10496 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10497 struct siginfo.
10498 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10499 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10500 * linux-low.h: Include <signal.h>.
10501 (struct siginfo): Remove forward declaration.
10502 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10503 struct siginfo.
10504
10505 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10506
10507 * .gitignore: Ignore more files.
10508
10509 2012-03-19 Pedro Alves <palves@redhat.com>
10510 Jan Kratochvil <jan.kratochvil@redhat.com>
10511
10512 * server.c (cont_thread, general_thread): Add describing comments.
10513 (start_inferior): Clear `cont_thread'.
10514 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10515 of a process.
10516
10517 2012-03-15 Yao Qi <yao@codesourcery.com>
10518
10519 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10520 handling to ...
10521 (cmd_qtdp): ... here.
10522
10523 2012-03-15 Yao Qi <yao@codesourcery.com>
10524
10525 * tracepoint.c (struct tracepoint_action_ops): New.
10526 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10527 (m_tracepoint_action_download): New.
10528 (r_tracepoint_action_download): New.
10529 (x_tracepoint_action_download): New.
10530 (l_tracepoint_action_download): New.
10531 (add_tracepoint_action): Install `action->ops' according type.
10532 (download_tracepoint_1): Move code `download' function pointer
10533 of various tracepoint_action_ops.
10534
10535 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10536
10537 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10538 linux_ptrace_attach_warnings.
10539
10540 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10541
10542 * Makefile.in (linux-ptrace.o): New.
10543 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10544 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10545 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10546 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10547 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10548 of these targets.
10549 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10550
10551 2012-03-08 Yao Qi <yao@codesourcery.com>
10552 Pedro Alves <palves@redhat.com>
10553
10554 Fix PR server/13392.
10555 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10556 offset of JMP insn.
10557 * tracepoint.c (remove_tracepoint): New.
10558 (cmd_qtdp): Call remove_tracepoint when failed to install.
10559
10560 2012-03-07 Pedro Alves <palves@redhat.com>
10561
10562 * linux-low.c (get_detach_signal): New.
10563 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10564 Pass on pending signals to PTRACE_DETACH. Check the result of the
10565 ptrace call.
10566 * server.c (program_signals, program_signals_p): New.
10567 (handle_general_set): Handle QProgramSignals.
10568 * server.h (program_signals, program_signals_p): Declare.
10569
10570 2012-03-05 Pedro Alves <palves@redhat.com>
10571 Jan Kratochvil <jan.kratochvil@redhat.com>
10572
10573 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10574 New comment why.
10575
10576 2012-03-03 Yao Qi <yao@codesourcery.com>
10577
10578 * tracepoint.c (tracepoint_look_up_symbols): Update call to
10579 agent_look_up_symbols.
10580
10581 2012-03-03 Yao Qi <yao@codesourcery.com>
10582
10583 * Makefile.in (linux-low.o): Keep dependence on agent.h.
10584 (linux-x86-low.o): Likewise.
10585 * server.h: Remove in_process_agent_loaded.
10586 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
10587 common/agent.c.
10588 Update callers.
10589
10590 2012-03-03 Yao Qi <yao@codesourcery.com>
10591
10592 * tracepoint.c (gdb_agent_capability): New global.
10593 (in_process_agent_loaded_ust): Renamed to
10594 `in_process_agent_supports_ust'.
10595 Update callers.
10596 (in_process_agent_supports_ust): Call agent_capability_check.
10597 (clear_installed_tracepoints): Assert that agent supports
10598 agent.
10599
10600 2012-03-03 Yao Qi <yao@codesourcery.com>
10601
10602 * linux-low.c (linux_supports_agent): New.
10603 (linux_target_ops): Initialize field `supports_agent' with
10604 linux_supports_agent.
10605 * target.h (struct target_ops) <supports_agent>: New.
10606 (target_supports_agent): New macro.
10607 * server.c (handle_general_set): Handle packet 'QAgent'.
10608 (handle_query): Send `QAgent+'.
10609 * Makefile.in (server.o): Depends on agent.h.
10610
10611 2012-03-03 Yao Qi <yao@codesourcery.com>
10612
10613 * Makefile.in (OBS): Add agent.o.
10614 Add new rule for agent.o.
10615 Track dependence of tracepoint.c on agent.h.
10616 * tracepoint.c (run_inferior_command_1):
10617 (run_inferior_command): Call agent_run_command.
10618 (gdb_ust_connect_sync_socket): Deleted. Move it to
10619 common/agent.c.
10620 (resume_thread, stop_thread): Likewise.
10621 (gdb_ust_socket_init): Renamed to ...
10622 (gdb_agent_socket_init): ... New.
10623 (gdb_ust_thread): Renamed to ...
10624 (gdb_agent_helper_thread): ... New.
10625 (gdb_ust_init): Move some code to ...
10626 (gdb_agent_init): ... here. New.
10627 [HAVE_UST]: Call gdb_ust_init.
10628 (initialize_tracepoint_ftlib): Call gdb_agent_init.
10629 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
10630 * config.in, configure: Regenerated.
10631
10632 2012-03-02 Pedro Alves <palves@redhat.com>
10633
10634 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
10635 * linux-low.c (struct simple_pid_list): New.
10636 (stopped_pids): New a struct simple_pid_list pointer.
10637 (add_to_pid_list, pull_pid_from_list): New.
10638 (handle_extended_wait): Don't assume the first signal new children
10639 report is SIGSTOP. Adjust call to pull_pid_from_list.
10640 (linux_wait_for_lwp): Adjust.
10641
10642 2012-03-02 Yao Qi <yao@codesourcery.com>
10643
10644 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
10645 debug log.
10646
10647 2012-03-02 Yao Qi <yao@codesourcery.com>
10648
10649 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
10650 `stop_pc' and `tpoint'. Update caller.
10651
10652 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
10653
10654 * linux-low.h (linux_target_ops): Add regset_bitmap member.
10655 * linux-low.c (use_linux_regsets): New macro.
10656 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
10657 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
10658 (linux_register_in_regsets): New function.
10659 (usr_fetch_inferior_registers): Skip registers covered by
10660 regsets.
10661 (usr_store_inferior_registers): Likewise.
10662 (usr_fetch_inferior_registers): New macro.
10663 (usr_store_inferior_registers): Likewise.
10664 (linux_fetch_registers): Handle mixed regset/non-regset targets.
10665 (linux_store_registers): Likewise.
10666 * linux-mips-low.c (init_registers_mips_dsp_linux): New
10667 prototype.
10668 (init_registers_mips64_dsp_linux): Likewise.
10669 (init_registers_mips_linux): New macro.
10670 (init_registers_mips_dsp_linux): Likewise.
10671 (mips_dsp_num_regs): Likewise.
10672 (DSP_BASE, DSP_CONTROL): New fallback macros.
10673 (mips_base_regs): New macro.
10674 (mips_regmap): Use it. Fix the size.
10675 (mips_dsp_regmap): New variable.
10676 (mips_dsp_regset_bitmap): Likewise.
10677 (mips_arch_setup): New function.
10678 (mips_cannot_fetch_register): Use the_low_target.regmap rather
10679 than mips_regmap.
10680 (mips_cannot_store_register): Likewise.
10681 (the_low_target): Update .arch_setup, .num_regs and .regmap
10682 initializers. Add .regset_bitmap initializer.
10683 * linux-arm-low.c (the_low_target): Add .regset_bitmap
10684 initializer.
10685 * linux-bfin-low.c (the_low_target): Likewise.
10686 * linux-cris-low.c (the_low_target): Likewise.
10687 * linux-crisv32-low.c (the_low_target): Likewise.
10688 * linux-ia64-low.c (the_low_target): Likewise.
10689 * linux-m32r-low.c (the_low_target): Likewise.
10690 * linux-m68k-low.c (the_low_target): Likewise.
10691 * linux-ppc-low.c (the_low_target): Likewise.
10692 * linux-s390-low.c (the_low_target): Likewise.
10693 * linux-sh-low.c (the_low_target): Likewise.
10694 * linux-sparc-low.c (the_low_target): Likewise.
10695 * linux-tic6x-low.c (the_low_target): Likewise.
10696 * linux-x86-low.c (the_low_target): Likewise.
10697 * linux-xtensa-low.c (the_low_target): Likewise.
10698 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
10699 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
10700 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
10701 srv_xmlfiles.
10702 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
10703 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
10704
10705 2012-02-29 Yao Qi <yao@codesourcery.com>
10706 Pedro Alves <palves@redhat.com>
10707
10708 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
10709 `step_over_finished' is true.
10710
10711 2012-02-27 Pedro Alves <palves@redhat.com>
10712
10713 * linux-low.c (pid_is_stopped): Delete, moved to common/.
10714 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
10715
10716 2012-02-27 Pedro Alves <palves@redhat.com>
10717
10718 PR server/9684
10719 * linux-low.c (pid_is_stopped): New.
10720 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
10721
10722 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
10723
10724 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
10725 of conditions.
10726
10727 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
10728
10729 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
10730
10731 2012-02-24 Luis Machado <lgustavo@codesourcery>
10732
10733 * server.c (handle_query): Advertise support for target-side
10734 breakpoint condition evaluation.
10735 (process_point_options): New function.
10736 (process_serial_event): When inserting a breakpoint, check for
10737 a target-side condition that should be evaluated.
10738
10739 * mem-break.c: Include regcache.h and ax.h.
10740 (point_cond_list_t): New data structure.
10741 (breakpoint) <cond_list>: New field.
10742 (find_gdb_breakpoint_at): Make non-static.
10743 (delete_gdb_breakpoint_at): Clear any target-side
10744 conditions.
10745 (clear_gdb_breakpoint_conditions): New function.
10746 (add_condition_to_breakpoint): Likewise.
10747 (add_breakpoint_condition): Likewise.
10748 (gdb_condition_true_at_breakpoint): Likewise.
10749 (gdb_breakpoint_here): Return result directly instead
10750 of going through a local variable.
10751
10752 * mem-break.h (find_gdb_breakpoint_at): New prototype.
10753 (clear_gdb_breakpoint_conditions): Likewise.
10754 (add_breakpoint_condition): Likewise.
10755 (gdb_condition_true_at_breakpoint): Likewise.
10756
10757 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
10758 (need_step_over_p): Take target-side breakpoint condition into
10759 consideration.
10760
10761 2012-02-24 Luis Machado <lgustavo@codesourcery>
10762
10763 * server.h: Include tracepoint.h.
10764 (agent_mem_read, agent_get_trace_state_variable_value,
10765 agent_set_trace_state_variable_value,
10766 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
10767 get_set_tsv_func_addr): New prototypes.
10768
10769 * ax.h: New include file.
10770 * ax.c: New source file.
10771
10772 * tracepoint.c: Include ax.h.
10773 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
10774 agent_expr, eval_result_type): Move to ax.h.
10775 (parse_agent_expr): Rename to ...
10776 (gdb_parse_agent_expr): ... this, make it non-static and move
10777 to ax.h.
10778 (unparse_agent_expr) Rename to ...
10779 (gdb_unparse_agent_expr): ... this, make it non-static and move
10780 to ax.h.
10781 (eval_agent_expr): Rename to ...
10782 (eval_tracepoint_agent_expr): ... this.
10783 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
10784 forward declarations.
10785 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
10786 (agent_get_trace_state_variable_value): New function.
10787 (agent_set_trace_state_variable_value): New function.
10788 (cmd_qtdp): Call gdb_parse_agent_expr (...).
10789 (response_tracepoint): Call gdb_unparse_agent_expr (...).
10790 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
10791 (condition_true_at_tracepoint): Likewise.
10792 (parse_agent_expr): Rename to ...
10793 (gdb_parse_agent_expr): ... this and move to ax.c.
10794 (unparse_agent_expr): Rename to ...
10795 (gdb_unparse_agent_expr): ... this and move to ax.c.
10796 (gdb_agent_op_name): Move to ax.c.
10797 (eval_agent_expr): Rename to ...
10798 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
10799 and move to ax.c.
10800 (eval_tracepoint_agent_expr): New function.
10801 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
10802 non-static.
10803 (current_insn_ptr, emit_error, struct bytecode_address): Move to
10804 ax.c.
10805 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
10806 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
10807 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
10808 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
10809 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
10810 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
10811 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
10812 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
10813 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
10814 (compile_bytecodes): Remove forward declaration.
10815 (is_goto_target): Move to ax.c.
10816 (compile_bytecodes): Move to ax.c and call
10817 agent_get_trace_state_variable_value (...) and
10818 agent_set_trace_state_variable_value (...).
10819
10820 * Makefile.in: Update ax.c and IPA dependencies.
10821
10822 2012-02-24 Pedro Alves <palves@redhat.com>
10823
10824 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
10825 (cmd_bigqtbuffer_circular): ... this. Only handle
10826 'QTBuffer:circular:'.
10827 (handle_tracepoint_general_set): Adjust.
10828
10829 2012-02-16 Yao Qi <yao@codesourcery.com>
10830
10831 * inferiors.c: Move code to ...
10832 * dll.c: .... here. New.
10833 * server.h: Declare clear_dlls.
10834 * Makefile.in (SFILES): Add dll.c.
10835 (OBS): Add dll.o
10836 (dll.o): New rule.
10837
10838 2012-02-11 Yao Qi <yao@codesourcery.com>
10839
10840 * server.c: (handle_monitor_command): Add a new parameter
10841 `own_buf'.
10842 (handle_query): Update caller.
10843
10844 2012-02-09 Joel Brobecker <brobecker@adacore.com>
10845
10846 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
10847 * configure, config.in: Regenerate.
10848 * hostio.c: Provide an alternate implementation if HAVE_READLINK
10849 is not defined.
10850
10851 2012-02-02 Pedro Alves <palves@redhat.com>
10852
10853 Try SIGKILL first, then PTRACE_KILL.
10854 * linux-low.c (linux_kill_one_lwp): New.
10855 (linux_kill_one_lwp): Rename to ...
10856 (kill_one_lwp_callback): ... this. Use the new
10857 linux_kill_one_lwp.
10858
10859 2012-02-02 Pedro Alves <palves@redhat.com>
10860
10861 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
10862 inferior.
10863
10864 2012-01-27 Pedro Alves <palves@redhat.com>
10865
10866 * linux-low.c (linux_child_pid_to_exec_file): Delete.
10867 (elf_64_file_p): Make static.
10868 (linux_pid_exe_is_elf_64_file): New.
10869 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
10870 Delete declarations.
10871 (linux_pid_exe_is_elf_64_file): Declare.
10872 * linux-x86-low.c (x86_arch_setup): Use
10873 linux_pid_exe_is_elf_64_file.
10874
10875 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
10876
10877 * linux-low.c (linux_wait_for_event_1): Rename to ...
10878 (linux_wait_for_event): ... here and merge it with former
10879 linux_wait_for_event - new variable wait_ptid, use it.
10880 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
10881
10882 2012-01-23 Pedro Alves <palves@redhat.com>
10883
10884 * server.c (main): Avoid yet another case of infinite loop while
10885 detaching/killing after a longjmp.
10886
10887 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10888
10889 Code cleanup.
10890 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
10891
10892 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
10893
10894 * hostio.c (handle_readlink): New function.
10895 (handle_vFile): Call it to handle "vFile:readlink" packets.
10896
10897 2012-01-20 Pedro Alves <palves@redhat.com>
10898 Ulrich Weigand <ulrich.weigand@linaro.org>
10899
10900 * server.c (handle_v_requests): Only support vAttach and vRun to
10901 start multiple processes when in extended protocol mode.
10902
10903 2012-01-17 Pedro Alves <palves@redhat.com>
10904
10905 * tracepoint.c (initialize_tracepoint): Use mmap instead of
10906 memalign plus mprotect to allocate the scratch buffer.
10907
10908 2012-01-13 Pedro Alves <palves@redhat.com>
10909
10910 * server.c (attach_inferior): Clear `cont_thread'.
10911
10912 2012-01-13 Pedro Alves <palves@redhat.com>
10913
10914 * server.c (main): Avoid infinite loop while detaching/killing
10915 after a longjmp.
10916
10917 2012-01-09 Doug Evans <dje@google.com>
10918
10919 * server.c (start_inferior): Set last_ptid in --wrapper case.
10920
10921 2012-01-06 Yao Qi <yao@codesourcery.com>
10922
10923 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
10924 defined.
10925 [IN_PROCESS_AGENT] (debug_agent): New global variable.
10926
10927 2012-01-04 Yao Qi <yao@codesourcery.com>
10928
10929 * tracepoint.c (cmd_qtdp): Print debug message
10930 for static tracepoint.
10931
10932 2012-01-04 Yao Qi <yao@codesourcery.com>
10933
10934 * tracepoint.c (trace_vdebug): Differentiate debug message
10935 between gdbserver and IPA.
10936
10937 2012-01-03 Yao Qi <yao@codesourcery.com>
10938
10939 * tracepoint.c (tracepoint_was_hit): Don't collect for
10940 static tracepoint.
10941
10942 2012-01-02 Joel Brobecker <brobecker@adacore.com>
10943
10944 * terminal.h: Reformat copyright header.
10945
10946 2012-01-02 Joel Brobecker <brobecker@adacore.com>
10947
10948 * server.c (gdbserver_version): Update copyright year.
10949 * gdbreplay.c (gdbreplay_version): Likewise.
10950
10951 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
10952
10953 * linux-low.c (linux_create_inferior): Put empty if clause for write.
10954
10955 Revert:
10956 2011-12-18 Hui Zhu <teawater@gmail.com>
10957 * linux-low.c (linux_create_inferior): Save return value to ret.
10958
10959 2011-12-18 Hui Zhu <teawater@gmail.com>
10960
10961 * linux-low.c (linux_create_inferior): Save return value to ret.
10962
10963 2011-12-16 Doug Evans <dje@google.com>
10964
10965 * linux-low.c (linux_create_inferior): If stdio connection,
10966 redirect stdin from /dev/null, stdout to stderr.
10967 * remote-utils.c (remote_is_stdio): New static global.
10968 (remote_connection_is_stdio): New function.
10969 (remote_prepare): Handle stdio connection.
10970 (remote_open): Ditto.
10971 (remote_close): Don't close stdin for stdio connections.
10972 (read_prim,write_prim): New functions. Replace all calls to
10973 read/write to these.
10974 * server.c (main): Watch for "-" argument. Move call to
10975 remote_prepare before start_inferior.
10976 * server.h (STDIO_CONNECTION_NAME): New macro.
10977 (remote_connection_is_stdio): Declare.
10978
10979 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
10980 in debugging output.
10981
10982 2011-12-15 Yao Qi <yao@codesourcery.com>
10983
10984 * tracepoint.c: Include sys/syscall.h.
10985 (gdb_ust_thread): Remove preprocessor conditional.
10986
10987 2011-12-14 Pedro Alves <pedro@codesourcery.com>
10988
10989 * linux-low.c (linux_detach_one_lwp): Call
10990 the_low_target.prepare_to_resume before detaching.
10991
10992 2011-12-14 Yao Qi <yao@codesourcery.com>
10993
10994 * tracepoint.c (gdb_ust_thread): Don't ignore return value
10995 of write.
10996
10997 2011-12-14 Yao Qi <yao@codesourcery.com>
10998
10999 * i386-low.c (i386_low_stopped_data_address): Initialize local
11000 variable `control'.
11001
11002 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11003
11004 PR remote/13492
11005
11006 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11007 DR_CONTROL unless necessary. Extend comments.
11008 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11009 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11010
11011 2011-12-13 Yao Qi <yao@codesourcery.com>
11012
11013 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11014 macros.
11015 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11016
11017 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11018
11019 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11020 Print new debug message for such case.
11021
11022 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11023
11024 Fix overlapping memcpy.
11025 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11026 the read_inferior_memory transfer.
11027 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11028 write_inferior_memory transfer.
11029 (set_fast_tracepoint_jump): New variable buf. Use it for the
11030 read_inferior_memory and write_inferior_memory transfers.
11031 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11032 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11033 Use it for the write_inferior_memory transfer.
11034 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11035 buffers.
11036
11037 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11038
11039 * linux-low.c (fetch_register, store_register): Make code
11040 consistent, fix formatting.
11041
11042 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11043
11044 * linux-low.c (usr_store_inferior_registers): Factor out code
11045 to handle individual registers into...
11046 (store_register): ... this new function.
11047
11048 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11049
11050 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11051 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11052 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11053 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11054 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11055 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11056 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11057 (srv_xmlfiles): Add new XML files.
11058
11059 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11060 and <sys/uio.h>.
11061 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11062 (init_registers_s390_linux32v1): Add prototype.
11063 (init_registers_s390_linux32v2): Likewise.
11064 (init_registers_s390_linux64v1): Likewise.
11065 (init_registers_s390_linux64v2): Likewise.
11066 (init_registers_s390x_linux64v1): Likewise.
11067 (init_registers_s390x_linux64v2): Likewise.
11068 (s390_num_regs): Increment to 52.
11069 (s390_regmap): Add orig_r2 register.
11070 (s390_num_regs_3264): Increment to 68.
11071 (s390_regmap_3264): Add orig_r2 register.
11072 (s390_collect_ptrace_register): Handle orig_r2 register.
11073 (s390_supply_ptrace_register): Likewise.
11074 (s390_fill_last_break): New function.
11075 (s390_store_last_break): Likewise.
11076 (s390_fill_system_call): New function.
11077 (s390_store_system_call): Likewise.
11078 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11079 register sets.
11080 (s390_check_regset): New function.
11081 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11082 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11083 Update target_regsets for available register sets.
11084
11085 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11086 Jan Kratochvil <jan.kratochvil@redhat.com>
11087
11088 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11089 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11090 New.
11091 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11092 * linux-low.h (struct process_info_private): New member r_debug.
11093 * server.c (handle_qxfer_libraries): Call
11094 the_target->qxfer_libraries_svr4.
11095 (handle_qxfer_libraries_svr4): New function.
11096 (qxfer_packets): New entry "libraries-svr4".
11097 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11098 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11099 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11100 PACKET_qXfer_libraries_svr4.
11101
11102 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11103
11104 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11105 PSW address/mask between 8-byte and 16-byte formats.
11106 (s390_supply_ptrace_register): Likewise.
11107 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11108 basic addressing mode bit.
11109
11110 2011-11-24 Stan Shebs <stan@codesourcery.com>
11111
11112 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11113
11114 2011-11-17 Stan Shebs <stan@codesourcery.com>
11115
11116 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11117 (tracing_start_time): New global.
11118 (tracing_stop_time): New global.
11119 (tracing_user_name): New global.
11120 (tracing_notes): New global.
11121 (tracing_stop_note): New global.
11122 (cmd_qtstart): Set traceframe_usage, start_time.
11123 (stop_tracing): Set stop_time.
11124 (cmd_qtstatus): Report additional status.
11125 (cmd_qtp): New function.
11126 (handle_tracepoint_query): Call it.
11127 (cmd_qtnotes): New function.
11128 (handle_tracepoint_general_set): Call it.
11129 (get_timestamp): Rename from tsv_get_timestamp.
11130
11131 2011-11-14 Stan Shebs <stan@codesourcery.com>
11132 Kwok Cheung Yeung <kcy@codesourcery.com>
11133
11134 * linux-x86-low.c (small_jump_insn): New.
11135 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11136 trampoline and error message, build a trampoline and issue a small
11137 jump instruction to it.
11138 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11139 trampoline and error message.
11140 (x86_get_min_fast_tracepoint_insn_len): New.
11141 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11142 * linux-low.h (struct linux_target_ops): Add arguments to
11143 install_fast_tracepoint_jump_pad operation, add new operation.
11144 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11145 arguments.
11146 (linux_get_min_fast_tracepoint_insn_len): New function.
11147 (linux_target_op): Add new operation.
11148 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11149 (gdb_trampoline_buffer_end): Ditto.
11150 (gdb_trampoline_buffer_error): Ditto.
11151 (struct ipa_sym_addresses): Add fields for new IPA variables.
11152 (symbol_list): Add entries for new IPA variables.
11153 (struct tracepoint): Add fields to hold the address range of the
11154 trampoline used by the tracepoint.
11155 (trampoline_buffer_head): New static variable.
11156 (trampoline_buffer_tail): Ditto.
11157 (claim_trampoline_space): New function.
11158 (have_fast_tracepoint_trampoline_buffer): New function.
11159 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11160 structure.
11161 (install_fast_tracepoint): Ditto, also add error buffer argument.
11162 (cmd_qtminftpilen): New function.
11163 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11164 (fast_tracepoint_from_trampoline_address): New function.
11165 (fast_tracepoint_collecting): Handle trampoline as part of jump
11166 pad space.
11167 (set_trampoline_buffer_space): New function.
11168 (initialize_tracepoint): Initialize new IPA variables.
11169 * target.h (struct target_ops): Add arguments to
11170 install_fast_tracepoint_jump_pad operation, add new
11171 get_min_fast_tracepoint_insn_len operation.
11172 (target_get_min_fast_tracepoint_insn_len): New.
11173 (install_fast_tracepoint_jump_pad): Add arguments.
11174 * server.h (IPA_BUFSIZ): Define.
11175 * linux-i386-ipa.c: Include extra header files.
11176 (initialize_fast_tracepoint_trampoline_buffer): New function.
11177 (initialize_low_tracepoint): Call it.
11178 * server.h (set_trampoline_buffer_space): Declare.
11179 (claim_trampoline_space): Ditto.
11180 (have_fast_tracepoint_trampoline_buffer): Ditto.
11181
11182 2011-11-14 Yao Qi <yao@codesourcery.com>
11183
11184 * server.c (handle_query): Handle InstallInTrace for qSupported.
11185 * tracepoint.c (add_tracepoint): Sort list.
11186 (install_tracepoint, download_tracepoint): New.
11187 (cmd_qtdp): Call them to install and download tracepoints.
11188 (sort_tracepoints): Removed.
11189 (cmd_qtstart): Update.
11190
11191 2011-11-14 Yao Qi <yao@codesourcery.com>
11192
11193 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11194 * mem-break.h: Declare.
11195 * tracepoint.c (cmd_qtstart): Move some code to ...
11196 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11197 New.
11198 (download_tracepoints): Move some code to ...
11199 (download_tracepoint_1): ... here. New.
11200
11201 2011-11-08 Yao Qi <yao@codesourcery.com>
11202
11203 * remote-utils.c (relocate_instruction): A comment fix.
11204
11205 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11206
11207 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11208 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11209 dr_status_mirror and dr_control_mirror from debug_reg_state.
11210 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11211 (i386_initial_stuff): Remove use of deleted globals.
11212 (i386_get_thread_context, i386_set_thread_context,
11213 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11214 from debug_reg_state.
11215
11216 2011-11-05 Yao Qi <yao@codesourcery.com>
11217
11218 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11219 address as TPOINT's.
11220
11221 2011-11-02 Stan Shebs <stan@codesourcery.com>
11222
11223 * tracepoint.c (agent_mem_read_string): New function.
11224 (eval_agent_expr): Call it for tracenz.
11225 * server.c (handle_query): Report support for tracenz.
11226
11227 2011-11-02 Yao Qi <yao@codesourcery.com>
11228
11229 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11230
11231 2011-11-02 Yao Qi <yao@codesourcery.com>
11232
11233 * target.h: Fix a typo in comment.
11234
11235 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11236
11237 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11238 clobber the breakpoints' shadows with fast tracepoint jumps.
11239 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11240 * target.c (write_inferior_memory): Also pass MYADDR down to
11241 check_mem_write.
11242
11243 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11244
11245 * configure.ac: Check support for personality routine.
11246 * configure: Regenerate.
11247 * config.in: Likewise.
11248 * linux-low.c: Include <sys/personality.h>.
11249 Define ADDR_NO_RANDOMIZE if necessary.
11250 (linux_create_inferior): Disable address space randomization when
11251 forking inferior, if requested.
11252 (linux_supports_disable_randomization): New function.
11253 (linux_target_ops): Install it.
11254 * server.h (disable_randomization): Declare.
11255 * server.c (disable_randomization): New global variable.
11256 (handle_general_set): Handle QDisableRandomization.
11257 (handle_query): Likewise for qSupported.
11258 (main): Support --disable-randomization and --no-disable-randomization
11259 command line arguments.
11260 * target.h (struct target_ops): Add supports_disable_randomization.
11261 (target_supports_disable_randomization): New macro.
11262
11263 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11264
11265 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11266 ifdef check.
11267 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11268 [!PT_GETDSBT] (target_loadmap): New definition.
11269 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11270 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11271 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11272 and PT_GETDSBT to LINUX_LOADMAP.
11273 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11274 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11275
11276 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11277
11278 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11279 (arm_linux_hwbp_cap): New static variable.
11280 (arm_linux_get_hwbp_cap): Replace by ...
11281 (arm_linux_init_hwbp_cap): ... this new function.
11282 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11283 (arm_linux_get_hw_watchpoint_count): Likewise.
11284 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11285 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11286 (arm_prepare_to_resume): Use perror_with_name instead of error.
11287
11288 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11289
11290 * linux-arm-low.c: Include <signal.h>.
11291 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11292 (struct arm_linux_hwbp_cap): New data type.
11293 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11294 (struct arm_linux_hw_breakpoint): New data type.
11295 (MAX_BPTS, MAX_WPTS): Define.
11296 (struct arch_process_info, struct arch_lwp_info): New data types.
11297 (arm_linux_get_hwbp_cap): New function.
11298 (arm_linux_get_hw_breakpoint_count): Likewise.
11299 (arm_linux_get_hw_watchpoint_count): Likewise.
11300 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11301 (arm_hwbp_control_initialize): Likewise.
11302 (arm_hwbp_control_is_enabled): Likewise.
11303 (arm_hwbp_control_is_initialized): Likewise.
11304 (arm_hwbp_control_disable): Likewise.
11305 (arm_linux_hw_breakpoint_equal): Likewise.
11306 (arm_linux_hw_point_initialize): Likewise.
11307 (struct update_registers_data): New data structure.
11308 (update_registers_callback: New function.
11309 (arm_insert_point): Likewise.
11310 (arm_remove_point): Likewise.
11311 (arm_stopped_by_watchpoint): Likewise.
11312 (arm_stopped_data_address): Likewise.
11313 (arm_new_process): Likewise.
11314 (arm_new_thread): Likewise.
11315 (arm_prepare_to_resume): Likewise.
11316 (the_low_target): Register arm_insert_point, arm_remove_point,
11317 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11318 arm_new_thread, and arm_prepare_to_resume.
11319
11320 2011-09-15 Stan Shebs <stan@codesourcery.com>
11321
11322 * server.h (struct emit_ops): Add compare-goto fields.
11323 * tracepoint.c (gdb_agent_op_sizes): New table.
11324 (emit_eq_goto): New function.
11325 (emit_ne_goto): New function.
11326 (emit_lt_goto): New function.
11327 (emit_le_goto): New function.
11328 (emit_gt_goto): New function.
11329 (emit_ge_goto): New function.
11330 (is_goto_target): New function.
11331 (compile_bytecodes): Recognize special cases of compare-goto
11332 combinations and call specialized emitters for them.
11333 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11334 (amd64_emit_ne_goto): New function.
11335 (amd64_emit_lt_goto): New function.
11336 (amd64_emit_le_goto): New function.
11337 (amd64_emit_gt_goto): New function.
11338 (amd64_emit_ge_goto): New function.
11339 (amd64_emit_ops): Add the new functions.
11340 (i386_emit_eq_goto): New function.
11341 (i386_emit_ne_goto): New function.
11342 (i386_emit_lt_goto): New function.
11343 (i386_emit_le_goto): New function.
11344 (i386_emit_gt_goto): New function.
11345 (i386_emit_ge_goto): New function.
11346 (i386_emit_ops): Add the new functions.
11347
11348 2011-09-08 Stan Shebs <stan@codesourcery.com>
11349
11350 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11351 (i386_emit_epilogue): Restore %ebx.
11352
11353 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11354
11355 * server.c (step_thread): Remove definition.
11356 (process_serial_event): Don't handle Hs.
11357 * server.h (step_thread): Remove declaration.
11358 * target.c (set_desired_inferior): Remove use of step_thread.
11359
11360 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11361
11362 * linux-low.c: Include linux-procfs.h.
11363 (linux_attach_lwp_1): Update comments.
11364 (linux_attach): Scan for existing threads when attaching to a
11365 process that is the tgid.
11366 * Makefile.in: Update dependencies.
11367
11368 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11369
11370 * configure.srv: Add linux-procfs.o dependencies.
11371
11372 2011-08-14 Yao Qi <yao@codesourcery.com>
11373
11374 * target.h (struct target_ops): Fix indent.
11375 * win32-low.c (win32_target_ops): Fix comment.
11376
11377 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11378 Yao Qi <yao@codesourcery.com>
11379
11380 * Makefile.in (clean): Remove tic6x-*.c files.
11381 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11382 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11383 (tic6x-c64xp-linux.c): Likewise.
11384 * configure.srv: Add support for tic6x-*-uclinux.
11385 * linux-tic6x-low.c: New.
11386 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11387
11388 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11389 Yao Qi <yao@codesourcery.com>
11390
11391 * target.h (struct target_ops): Add read_loadmap.
11392 * linux-low.c (struct target_loadseg): New type.
11393 (struct target_loadmap): New type.
11394 (linux_read_loadmap): New function.
11395 (linux_target_ops): Add linux_read_loadmap.
11396 * server.c (handle_query): Support qXfer:fdpic:read packet.
11397 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11398 to NULL.
11399
11400 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11401
11402 * win32-low.c: Include <stdint.h>.
11403
11404 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11405
11406 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11407 to the inferior here.
11408 (i386_remove_aligned_watchpoint): Ditto.
11409 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11410 fit part of the watchpoint in the debug registers.
11411 (i386_update_inferior_debug_regs): New.
11412 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11413 registers, and only update the inferior on success.
11414 (i386_low_remove_watchpoint): Ditto.
11415
11416 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11417
11418 * linux-low.c (compare_ints, unique, list_threads, show_process,
11419 linux_core_of_thread): Delete.
11420 (linux_target_ops): Change linux_core_of_thread to
11421 linux_common_core_of_thread.
11422 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11423 * utils.c (malloc_failure): Change type of argument.
11424 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11425 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11426 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11427 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11428 (IPA_OBJS): Add common-utils-ipa.o.
11429 (ptid_h, linux_osdata_h): New macros.
11430 (server_h): Add common/common-utils.h, common/xml-utils.h,
11431 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11432 common/ptid.h.
11433 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11434 ptid.o, buffer.o): New rules.
11435 (linux-low.o): Add common/linux-osdata.h as a dependency.
11436 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11437 * configure.ac: Add AC_HEADER_DIRENT check.
11438 * config.in: Regenerate.
11439 * configure: Regenerate.
11440 * remote-utils.c (xml_escape_text): Delete.
11441 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11442 buffer_xml_printf): Move to common/buffer.c.
11443 * server.c (main): Remove call to initialize_inferiors.
11444 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11445 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11446 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11447 internal_error, gdb_assert, gdb_assert_fail): Delete.
11448 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11449 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11450 common/buffer.h.
11451 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11452 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11453 initialize_inferiors): Delete.
11454
11455 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11456
11457 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11458 symbol error.
11459
11460 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11461
11462 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11463 assertion.
11464 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11465
11466 2011-05-26 Yao Qi <yao@codesourcery.com>
11467
11468 * Makefile.in (thread-db.o): Track dependence to
11469 common/gdb_thread_db.h.
11470 * thread-db.c: include gdb_thread_db.h from right place.
11471
11472 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11473
11474 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11475 __FILE__ and __LINE__ to internal_error.
11476
11477 2011-05-13 Doug Evans <dje@google.com>
11478
11479 * thread-db.c (try_thread_db_load_from_sdir): New function.
11480 (try_thread_db_load_from_dir): New function.
11481 (thread_db_load_search): Handle $sdir, ignore $pdir.
11482 Remove trying of system directories if search of
11483 libthread-db-search-path fails, that is now done via $sdir.
11484
11485 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11486
11487 * server.c (handle_query): Add EnableDisableTracepoints to the list
11488 of supported features.
11489 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11490 tracepoints.
11491 (cmd_qtenable_disable): New.
11492 (cmd_qtstart): Install tracepoints even if disabled.
11493 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11494 receiving a QTEnable or QTDisable packet.
11495 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11496 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11497 tracepoints.
11498 (gdb_probe): Skip data collection if static tracepoint is disabled.
11499
11500 2011-05-10 Doug Evans <dje@google.com>
11501
11502 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11503
11504 2011-05-04 Doug Evans <dje@google.com>
11505
11506 * linux-low.c (linux_join): Skip process lookup.
11507 * spu-low.c (spu_join): Ditto.
11508 * server.c (join_inferiors_callback): Delete.
11509 (process_serial_event): For 'D' packet (detach) call join_inferior
11510 directly.
11511
11512 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11513
11514 * README: Don't mention xscale*-*-linux*.
11515 * configure.srv (xscale*-*-linux*): Don't handle target.
11516
11517 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11518
11519 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11520 casting pointers.
11521 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11522 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11523 (i386_emit_void_call_2): Likewise.
11524
11525 2011-04-26 Yao Qi <yao@codesourcery.com>
11526
11527 * linux-low.c: Move common macros to linux-ptrace.h.
11528 Include linux-ptrace.h.
11529 * Makefile.in (linux_ptrace_h): New.
11530 (linux-low.o): Depends on linux-ptrace.h.
11531
11532 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11533
11534 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11535 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11536 (remote_prepare): New function with most of the TCP code from ...
11537 (remote_open): ... here. Detect PORT here unconditionally. Move also
11538 setting transport_is_reliable.
11539 * server.c (run_once): New variable.
11540 (gdbserver_usage): Document it.
11541 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11542 the first run if RUN_ONCE.
11543 * server.h (run_once, remote_prepare): New declarations.
11544
11545 2011-04-19 Tom Tromey <tromey@redhat.com>
11546
11547 * win32-low.c (handle_load_dll): Remove duplicate "the".
11548
11549 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11550
11551 Remove support for old Cygwin 1.5 versions.
11552 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11553 function to avoid warning.
11554 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11555 warning.
11556
11557 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11558
11559 * gdbserver/server.h (Macro _): Define it if not available.
11560
11561 2011-03-14 Michael Snyder <msnyder@vmware.com>
11562
11563 * hostio.c (handle_close): Remove unnecessary null test.
11564
11565 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11566
11567 * Makefile.in (maintainer-clean realclean distclean): Remove
11568 "make ... subdir_do" command.
11569
11570 2011-03-10 Michael Snyder <msnyder@vmware.com>
11571
11572 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11573
11574 * server.c (handle_v_run): Free alloced buffer on early return.
11575
11576 2011-03-09 Yao Qi <yao@codesourcery.com>
11577
11578 Revert:
11579 2011-03-04 Yao Qi <yao@codesourcery.com>
11580
11581 * Makefile.in: Remove GNU make feature --directory.
11582
11583 2011-03-05 Yao Qi <yao@codesourcery.com>
11584
11585 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11586 (subdir_do): New make target. Copied from gdb/Makefile.
11587 (maintainer-clean, realclean, distclean, clean): Call corresponding
11588 make targets in common/Makefile.
11589
11590 2011-02-11 Yao Qi <yao@codesourcery.com>
11591
11592 * configure.ac: Call AC_PROG_RANLIB.
11593 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11594 * configure: Regenerate.
11595
11596 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11597
11598 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
11599
11600 2011-03-06 Yao Qi <yao@codesourcery.com>
11601
11602 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
11603
11604 2011-03-05 Yao Qi <yao@codesourcery.com>
11605
11606 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11607 (subdir_do): New make target. Copied from gdb/Makefile.
11608 (maintainer-clean, realclean, distclean, clean): Call corresponding
11609 make targets in common/Makefile.
11610
11611 2011-03-04 Yao Qi <yao@codesourcery.com>
11612
11613 * Makefile.in: Remove GNU make feature --directory.
11614
11615 2011-03-04 Michael Snyder <msnyder@vmware.com>
11616
11617 * server.c (queue_stop_reply): Call xmalloc not malloc.
11618
11619 2011-03-02 Michael Snyder <msnyder@vmware.com>
11620
11621 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
11622
11623 2011-02-28 Michael Snyder <msnyder@vmware.com>
11624
11625 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
11626 (cmd_qtframe): Ditto.
11627 (cmd_qtbuffer): Ditto.
11628 (cmd_bigqtbuffer): Ditto.
11629
11630 * utils.c (decimal2str): Initialize 'width' to nine, then
11631 don't mess with it.
11632
11633 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11634
11635 * hostio.c (require_data): Free *data, not data.
11636
11637 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11638
11639 * hostio.c (require_data): Use free, not xfree.
11640
11641 2011-02-27 Michael Snyder <msnyder@vmware.com>
11642
11643 * server.c (handle_query): Discard unused value.
11644
11645 * hostio.c (require_data): Free malloc memory before returning
11646 error.
11647
11648 2011-02-26 Michael Snyder <msnyder@vmware.com>
11649
11650 * linux-low.c (list_threads): Call closedir for dirent.
11651
11652 2011-02-27 Michael Snyder <msnyder@vmware.com>
11653
11654 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
11655 a case statement falls through.
11656
11657 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
11658
11659 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
11660 in comparison.
11661
11662 2011-02-26 Michael Snyder <msnyder@vmware.com>
11663
11664 * utils.c (decimal2str): Eliminate dead code and dead param.
11665 (pulongest): Drop dead param from call to decimal2str.
11666 (plongest): Ditto.
11667
11668 2011-02-24 Joel Brobecker <brobecker@adacore.com>
11669
11670 Revert the following patch (not approved yet):
11671 2011-02-21 Hui Zhu <teawater@gmail.com>
11672 * tracepoint.c (tp_printf): New function.
11673 (eval_agent_expr): Handle gdb_agent_op_printf.
11674
11675 2011-02-21 Hui Zhu <teawater@gmail.com>
11676
11677 * tracepoint.c (tp_printf): New function.
11678 (eval_agent_expr): Handle gdb_agent_op_printf.
11679
11680 2011-02-18 Tom Tromey <tromey@redhat.com>
11681
11682 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
11683 (tracepoint.o): Likewise.
11684 * tracepoint.c (enum gdb_agent_op): Use ax.def.
11685 (gdb_agent_op_names): Likewise.
11686
11687 2011-02-18 Tom Tromey <tromey@redhat.com>
11688
11689 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
11690 gdb_agent_op_rot>: New constants.
11691 (gdb_agent_op_names): Add pick and roll.
11692 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
11693 cases.
11694
11695 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
11696
11697 * aclocal.m4: Regenerated with aclocal-1.11.1.
11698
11699 2011-02-14 Pedro Alves <pedro@codesourcery.com>
11700
11701 * server.c (handle_qxfer_traceframe_info): New.
11702 (qxfer_packets): Register "traceframe-info".
11703 (handle_query): Report support for qXfer:traceframe-info:read+.
11704 * tracepoint.c (match_blocktype): New.
11705 (traceframe_find_block_type): Rename to ...
11706 (traceframe_walk_blocks): ... this. Add callback filter argument,
11707 and use it.
11708 (traceframe_find_block_type): New, reimplemented on top of
11709 traceframe_walk_blocks.
11710 (build_traceframe_info_xml): New.
11711 (traceframe_read_info): New.
11712 * server.h (traceframe_read_info): Declare.
11713
11714 2011-02-11 Yao Qi <yao@codesourcery.com>
11715
11716 * configure.ac: Call AC_PROG_RANLIB.
11717 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11718 * configure: Regenerate.
11719
11720 2011-02-07 Pedro Alves <pedro@codesourcery.com>
11721
11722 * server.c (gdb_read_memory): Change return semantics to allow
11723 partial transfers.
11724 (handle_search_memory_1): Adjust.
11725 (process_serial_event) <'m' packet>: Handle partial transfers.
11726 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
11727
11728 2011-01-28 Pedro Alves <pedro@codesourcery.com>
11729
11730 * regcache.c (init_register_cache): Initialize
11731 regcache->register_status.
11732 (free_register_cache): Release regcache->register_status.
11733 (regcache_cpy): Copy register_status.
11734 (registers_to_string): Print 'x's for unavailable registers.
11735 (supply_register): Mark the register's status valid or
11736 unavailable, depending on whether a buffer was passed in or not.
11737 (supply_register_zeroed): New.
11738 (supply_regblock): Mark the registers' status valid or
11739 unavailable, depending on whether a buffer was passed in or not.
11740 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
11741 (struct regcache): New `register_status' field.
11742 (supply_register_zeroed): Declare.
11743 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
11744 supply_register_zeroed, rather than passing a NULL buffer to
11745 supply_register.
11746 * tracepoint.c (fetch_traceframe_registers): Update comment.
11747
11748 2011-01-28 Pedro Alves <pedro@codesourcery.com>
11749
11750 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
11751 buffer explicit.
11752
11753 2011-01-25 Pedro Alves <pedro@codesourcery.com>
11754
11755 * server.h (decode_xfer_write): Change prototype.
11756 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
11757 and don't extract the annex here.
11758 * server.c (decode_xfer_read): Remove `annex' parameter,
11759 and don't extract the annex here.
11760 (decode_xfer): New.
11761 (struct qxfer): New.
11762 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
11763 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
11764 (handle_qxfer_statictrace): New functions, abstracted out from
11765 handle_query, and made to use the struct qxfer interface.
11766 (handle_threads_qxfer_proper): Rename to ...
11767 (handle_qxfer_threads_proper): ... this.
11768 (handle_threads_qxfer): Rename to ...
11769 (handle_qxfer_threads): ... this. Adjust.
11770 (qxfer_packets): New array.
11771 (handle_qxfer): New function.
11772 (handle_query): Use handle_qxfer.
11773
11774 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
11775
11776 * gdbreplay.c: Shorten lines of >= 80 columns.
11777 * linux-low.c: Ditto.
11778 * linux-ppc-low.c: Ditto.
11779 * linux-s390-low.c: Ditto.
11780 * linux-sparc-low.c: Ditto.
11781 * linux-x86-low.c: Ditto.
11782 * linux-xtensa-low.c: Ditto.
11783 * mem-break.c: Ditto.
11784 * nto-low.c: Ditto.
11785 * regcache.h: Ditto.
11786 * remote-utils.c: Ditto.
11787 * server.c: Ditto.
11788 * server.h: Ditto.
11789 * thread-db.c: Ditto.
11790 * tracepoint.c: Ditto.
11791 * utils.c: Ditto.
11792 * win32-low.h: Ditto.
11793
11794 2011-01-05 Joel Brobecker <brobecker@adacore.com>
11795
11796 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
11797 update.
11798
11799 2011-01-01 Joel Brobecker <brobecker@adacore.com>
11800
11801 * server.c (gdbserver_version): Update copyright year in version
11802 output.
11803 * gdbreplay.c (gdbreplay_version): Ditto.
11804
11805 2010-12-29 Jie Zhang <jie.zhang@analog.com>
11806
11807 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
11808 * linux-bfin-low.c: New file.
11809 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
11810 PT_DATA_ADDR for BFIN targets.
11811 * Makefile.in (SFILES): Add linux-bfin-low.c.
11812 (clean): Remove reg-bfin.c.
11813 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
11814 * README: Mention supported Blackfin targets.
11815
11816 2010-12-23 Mike Frysinger <vapier@gentoo.org>
11817
11818 * .gitignore: New file.
11819
11820 2010-11-16 Mike Frysinger <vapier@gentoo.org>
11821
11822 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
11823
11824 2010-10-22 Jie Zhang <jie@codesourcery.com>
11825
11826 * Makefile.in: Add FLAGS_TO_PASS variable.
11827 (install): Remove dependency of install-only and recursively
11828 invoke make for install-only.
11829
11830 2010-10-04 Doug Evans <dje@google.com>
11831
11832 * Makefile.in (uninstall): Use $(DESTDIR).
11833
11834 2010-09-24 Pedro Alves <pedro@codesourcery.com>
11835
11836 PR gdb/11842
11837
11838 * linux-x86-low.c (compat_siginfo_from_siginfo)
11839 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
11840 si_code is < 0. Check for si_code == SI_TIMER before checking for
11841 si_code < 0.
11842
11843 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11844
11845 * lynx-i386-low.c: New file.
11846 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
11847
11848 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11849
11850 * lynx-low.c (ptrace_request_to_str): Remove handling for
11851 request values that have been removed in LynxOS 5.x.
11852
11853 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11854
11855 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
11856 <ptrace.h>
11857
11858 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
11859
11860 * configure.ac: Add --enable-inprocess-agent option.
11861 * configure: Rebuilt.
11862
11863 2010-09-06 Yao Qi <yao@codesourcery.com>
11864
11865 * linux-low.c (linux_kill): Remove unused variable.
11866 (linux_stabilize_threads): Likewise.
11867 * server.c (start_inferior): Likewise.
11868 (queue_stop_reply_callback): Likewise.
11869 * tracepoint.c (do_action_at_tracepoint): Likewise.
11870
11871 2010-09-06 Yao Qi <yao@codesourcery.com>
11872
11873 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
11874 on return.
11875
11876 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11877
11878 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
11879
11880 2010-09-06 Pedro Alves <pedro@codesourcery.com>
11881
11882 * Makefile.in (install-only): Replace $IPA_DEPFILES with
11883 "$(IPA_DEPFILES)".
11884
11885 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11886
11887 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
11888 gdbserver/lynx-ppc-low.c: New files.
11889 * Makefile.in (lynx_low_h): New variable.
11890 (lynx-low.o, lynx-ppc-low.o): New rules.
11891 * configure.ac: On LynxOS, link with -lnetinet.
11892 * configure.srv: Add handling of powerpc-*-lynxos* targets.
11893 * configure: regenerate.
11894
11895 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11896
11897 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
11898 * configure.ac: Add check for vasprintf and vsnprintf.
11899 * configure, config.in: Regenerate.
11900 * server.h (vasprintf, vsnprintf): Add conditional declarations.
11901
11902 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11903
11904 * gdbreplay.c: Move include of alloca.h up, next to include of
11905 malloc.h.
11906 * server.h: Add include of malloc.h.
11907 * mem-break.c: Remove include of malloc.h.
11908 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
11909
11910 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11911
11912 * Makefile.in (memmem.o): Build with -Wno-error.
11913
11914 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11915
11916 * utils.c (xsnprintf): Make non-static.
11917 * server.h: Add xsnprintf declaration.
11918 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
11919 replace calls to snprintf by calls to xsnprintf throughout.
11920
11921 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11922
11923 * configure.ac: Add configure check for alloca.
11924 * configure, config.in: Regenerate.
11925 * server.h: Include alloca.h if it exists.
11926 * gdbreplay.c: Include alloca.h if it exists.
11927
11928 2010-08-28 Pedro Alves <pedro@codesourcery.com>
11929
11930 * linux-low.c (__SIGRTMIN): Define if not already defined.
11931 (linux_create_inferior): Check for __ANDROID__ rather than
11932 __SIGRTMIN.
11933 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
11934 are already deferred.
11935 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
11936 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
11937 stopped and already has a pending signal to report.
11938 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
11939 a pending signal to report or is moving out of a jump pad.
11940 (linux_init_signals): Check for __ANDROID__ rather than
11941 __SIGRTMIN.
11942
11943 2010-08-28 Pedro Alves <pedro@codesourcery.com>
11944
11945 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
11946 debug_threads check. Avoid a linear search when not doing debug
11947 output.
11948
11949 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11950
11951 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
11952 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
11953 (struct file_handler) <fd>: Change type to gdb_fildes_t.
11954 (process_event): Change local fd's type to gdb_fildes_t.
11955 (create_file_handler): Adjust prototype.
11956 (delete_file_handler): Adjust prototype.
11957 (handle_file_event): Adjust prototype. Use pfildes.
11958 (create_file_event): Adjsut prototype.
11959 * remote-utils.c (remote_desc, listen_desc): Change type to
11960 gdb_fildes_t.
11961 * server.h: New gdb_fildes_t typedef.
11962 [USE_WIN32API]: Include winsock2.h.
11963 (delete_file_handler, add_file_handler): Adjust prototypes.
11964 (pfildes): Declare.
11965 * utils.c (pfildes): New.
11966
11967 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11968
11969 * configure.ac (build_warnings): Add -Wno-char-subscripts.
11970 * configure: Regenerate.
11971
11972 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11973
11974 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
11975 (linux_done_accessing_memory): ... this.
11976 (linux_target_ops): Adjust.
11977 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
11978 * nto-low.c (nto_target_ops): Adjust comment.
11979 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
11980 * spu-low.c (spu_target_ops): Adjust comment.
11981 * target.h (target_ops): Rename unprepare_to_access_memory field
11982 to done_accessing_memory.
11983 (unprepare_to_access_memory): Rename to ...
11984 (done_accessing_memory): ... this.
11985
11986 2010-08-26 Pedro Alves <pedro@codesourcery.com>
11987
11988 * linux-low.c (linux_prepare_to_access_memory): New.
11989 (linux_unprepare_to_access_memory): New.
11990 (linux_target_ops): Install them.
11991 * server.c (read_memory): Rename to ...
11992 (gdb_read_memory): ... this. Use
11993 prepare_to_access_memory/prepare_to_access_memory.
11994 (write_memory): Rename to ...
11995 (gdb_write_memory): ... this. Use
11996 prepare_to_access_memory/prepare_to_access_memory.
11997 (handle_search_memory_1): Adjust.
11998 (process_serial_event): Adjust.
11999 * target.h (struct target_ops): New fields
12000 prepare_to_access_memory and unprepare_to_access_memory.
12001 (prepare_to_access_memory, unprepare_to_access_memory): New.
12002 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12003 prepare_to_access_memory/prepare_to_access_memory.
12004 * nto-low.c (nto_target_ops): Adjust.
12005 * spu-low.c (spu_target_ops): Adjust.
12006 * win32-low.c (win32_target_ops): Adjust.
12007
12008 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12009
12010 * Makefile.in (WARN_CFLAGS): Get it from configure.
12011 (WERROR_CFLAGS): New.
12012 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12013 * configure.ac: Introduce --enable-werror, which adds -Werror to
12014 the compiler command line. Enabled by default. Disable with
12015 --disable-werror. Add -Wdeclaration-after-statement
12016 Wpointer-arith and -Wformat-nonliteral to warning flags.
12017 * configure: Regenerate.
12018
12019 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12020
12021 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12022
12023 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12024
12025 * gdbreplay.c (remote_error): New.
12026 (gdbchar): New.
12027 (expect): Use gdbchar. Check for error reading from GDB.
12028 Clarify sync error output.
12029 (play): Check for errors writing to GDB.
12030 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12031 * remote-utils.c (getpkt): Check for errors writing to the remote
12032 descriptor.
12033
12034 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12035
12036 * linux-low.c (linux_wait_1): Move non-debugging code out of
12037 `debug_threads' control.
12038
12039 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12040
12041 * linux-low.c (linux_wait_1): Don't set last_status here.
12042 * server.c (push_event, queue_stop_reply_callback): Assert we're
12043 not pushing a TARGET_WAITKIND_IGNORE event.
12044 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12045 (myresume, handle_target_event): Set the thread's last_resume_kind
12046 and last_status from the target returned status.
12047
12048 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12049
12050 PR threads/10729
12051
12052 * linux-x86-low.c (update_debug_registers_callback): New.
12053 (i386_dr_low_set_addr): Use it.
12054 (i386_dr_low_get_addr): New.
12055 (i386_dr_low_set_control): Use update_debug_registers_callback.
12056 (i386_dr_low_get_control): New.
12057 (i386_dr_low_get_status): Adjust.
12058 * linux-low.c (linux_stop_lwp): New.
12059 * linux-low.h (linux_stop_lwp): Declare.
12060
12061 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12062 argument instead of a i386_debug_reg_state.
12063 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12064 a i386_debug_reg_state.
12065 (i386_insert_aligned_watchpoint): Adjust.
12066 (i386_remove_aligned_watchpoint): Adjust.
12067 (i386_low_stopped_data_address): Read the debug registers from the
12068 inferior instead of from the mirrors.
12069 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12070 (i386_dr_low_get_addr): Declare.
12071 (i386_dr_low_get_control): Declare.
12072 (i386_dr_low_get_status): Change prototype.
12073
12074 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12075 (i386_dr_low_get_addr): New.
12076 (i386_dr_low_get_control): New.
12077 (i386_dr_low_get_status): Adjust prototype. Return
12078 dr_status_mirror.
12079 (i386_initial_stuff): Clear dr_status_mirror and
12080 dr_control_mirror.
12081 (i386_get_thread_context): Adjust.
12082 (i386_set_thread_context): Adjust.
12083 (i386_thread_added): Adjust.
12084
12085 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12086
12087 * linux-low.h (linux_thread_area): Delete declaration.
12088
12089 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12090
12091 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12092 after its termination.
12093
12094 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12095
12096 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12097 (gdb_wants_all_stopped): Delete.
12098 (linux_wait_1): Don't call them.
12099 * server.c (handle_v_cont): Tag all threads as want-stopped.
12100 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12101 stopped as "client-wants-stopped".
12102
12103 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12104
12105 * Makefile.in (signals_h): New.
12106 (server_h): Depend on it.
12107 (server.o): Don't depend on $(signals_def).
12108 (signals.o): Depend on $(signals_def).
12109
12110 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12111
12112 * Makefile.in (signals_def): New.
12113 (server_h): Append include/gdb/signals.h and signals_def.
12114 (server.o): Append signals_def.
12115
12116 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12117
12118 * server.c (handle_target_event): Use target_signal_to_host for
12119 resume_info.sig initialization.
12120 * target.h (struct thread_resume) <sig>: New comment.
12121
12122 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12123
12124 * server.c (handle_query): strcpy() the returned string from paddress()
12125 instead of sprintf().
12126 * utils.c (paddress): Return phex_nz().
12127
12128 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12129
12130 * server.c (handle_v_cont): Call mourn_inferior if process
12131 just exited.
12132 (myresume): Likewise.
12133
12134 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12135
12136 Static tracepoints, and integration with UST.
12137
12138 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12139 * mem-break.c (uninsert_all_breakpoints)
12140 (reinsert_all_breakpoints): New.
12141 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12142 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12143 (gdb_agent_ust_loaded, helper_thread_id)
12144 (gdb_agent_helper_thread_id): New macros.
12145 (struct ipa_sym_addresses): Add addr_ust_loaded,
12146 addr_helper_thread_id, addr_cmd_buf.
12147 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12148 (in_process_agent_loaded_ust): New.
12149 (write_e_ust_not_loaded): New.
12150 (maybe_write_ipa_ust_not_loaded): New.
12151 (struct collect_static_trace_data_action): New.
12152 (enum tracepoint_type) <static_tracepoint>: New.
12153 (struct tracepoint) <handle>: Mention static tracepoints.
12154 (struct static_tracepoint_ctx): New.
12155 (CMD_BUF_SIZE): New.
12156 (add_tracepoint_action): Handle static tracepoint actions.
12157 (unprobe_marker_at): New.
12158 (clear_installed_tracepoints): Handle static tracepoints.
12159 (cmd_qtdp): Handle static tracepoints.
12160 (probe_marker_at): New.
12161 (cmd_qtstart): Handle static tracepoints.
12162 (response_tracepoint): Handle static tracepoints.
12163 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12164 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12165 (get_context_regcache): Handle static tracepoints.
12166 (do_action_at_tracepoint): Handle static tracepoint actions.
12167 (traceframe_find_block_type): Handle static trace data blocks.
12168 (traceframe_read_sdata): New.
12169 (download_tracepoints): Download static tracepoint actions.
12170 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12171 (GDB_PROBE_NAME): New.
12172 (ust_ops): New.
12173 (GET_UST_SYM): New.
12174 (USTF): New.
12175 (dlsym_ust): New.
12176 (ust_marker_to_static_tracepoint): New.
12177 (gdb_probe): New.
12178 (collect_ust_data_at_tracepoint): New.
12179 (gdb_ust_probe): New.
12180 (UNIX_PATH_MAX, SOCK_DIR): New.
12181 (gdb_ust_connect_sync_socket): New.
12182 (resume_thread, stop_thread): New.
12183 (run_inferior_command): New.
12184 (init_named_socket): New.
12185 (gdb_ust_socket_init): New.
12186 (cstr_to_hexstr): New.
12187 (next_st): New.
12188 (first_marker, next_marker): New.
12189 (response_ust_marker): New.
12190 (cmd_qtfstm, cmd_qtsstm): New.
12191 (unprobe_marker_at, probe_marker_at): New.
12192 (cmd_qtstmat, gdb_ust_thread): New.
12193 (gdb_ust_init): New.
12194 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12195 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12196 (ST_REGENTRY): New.
12197 (x86_64_st_collect_regmap): New.
12198 (X86_64_NUM_ST_COLLECT_GREGS): New.
12199 (AMD64_RIP_REGNUM): New.
12200 (supply_static_tracepoint_registers): New.
12201 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12202 (ST_REGENTRY): New.
12203 (i386_st_collect_regmap): New.
12204 (i386_NUM_ST_COLLECT_GREGS): New.
12205 (supply_static_tracepoint_registers): New.
12206 * server.c (handle_query): Handle qXfer:statictrace:read.
12207 <qSupported>: Report support for StaticTracepoints, and
12208 qXfer:statictrace:read features.
12209 * server.h (traceframe_read_sdata)
12210 (supply_static_tracepoint_registers): Declare.
12211 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12212 (unpack_varlen_hex): Include in IPA build.
12213 * Makefile.in (ustlibs, ustinc): New.
12214 (IPA_OBJS): Add remote-utils-ipa.o.
12215 ($(IPA_LIB)): Link -ldl and -lpthread.
12216 (UST_CFLAGS): New.
12217 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12218 * config.in, configure: Regenerate.
12219
12220 2010-06-20 Ian Lance Taylor <iant@google.com>
12221 Pedro Alves <pedro@codesourcery.com>
12222
12223 * linux-x86-low.c (always_true): Delete.
12224 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12225 trying to fool the compiler with always_true.
12226
12227 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12228
12229 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12230 conditions in gdbserver.
12231
12232 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12233
12234 * spu-low.c (spu_read_memory): Wrap around local store limit.
12235 (spu_write_memory): Likewise.
12236
12237 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12238
12239 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12240 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12241 LONGEST uses.
12242 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12243 uses.
12244 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12245 uses with LONGEST uses.
12246
12247 2010-06-14 Stan Shebs <stan@codesourcery.com>
12248 Pedro Alves <pedro@codesourcery.com>
12249
12250 Bytecode compiler.
12251
12252 * linux-x86-low.c: Include limits.h.
12253 (add_insns): New.
12254 (always_true): New.
12255 (EMIT_ASM): New.
12256 (EMIT_ASM32): New.
12257 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12258 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12259 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12260 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12261 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12262 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12263 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12264 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12265 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12266 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12267 (amd64_emit_void_call_2): New.
12268 (amd64_emit_ops): New.
12269 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12270 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12271 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12272 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12273 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12274 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12275 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12276 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12277 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12278 (i386_emit_stack_adjust, i386_emit_int_call_1)
12279 (i386_emit_void_call_2): New.
12280 (i386_emit_ops): New.
12281 (x86_emit_ops): New.
12282 (the_low_target): Install x86_emit_ops.
12283 * server.h (struct emit_ops): New.
12284 (get_raw_reg_func_addr): Declare.
12285 (current_insn_ptr, emit_error): Declare.
12286 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12287 (set_trace_state_variable_value): New defines.
12288 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12289 addr_get_trace_state_variable_value and
12290 addr_set_trace_state_variable_value.
12291 (symbol_list): New fields for get_raw_reg,
12292 get_trace_state_variable_value and set_trace_state_variable_value.
12293 (condfn): New typedef.
12294 (struct tracepoint): New field `compiled_cond'.
12295 (do_action_at_tracepoint): Clear compiled_cond.
12296 (get_trace_state_variable_value, set_trace_state_variable_value):
12297 Export in the IPA.
12298 (condition_true_at_tracepoint): If there's a compiled condition,
12299 run that.
12300 (current_insn_ptr, emit_error): New globals.
12301 (struct bytecode_address): New.
12302 (get_raw_reg_func_addr): New.
12303 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12304 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12305 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12306 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12307 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12308 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12309 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12310 (compile_tracepoint_condition, compile_bytecodes): New.
12311 * target.h (emit_ops): Forward declare.
12312 (struct target_ops): New field emit_ops.
12313 (target_emit_ops): New.
12314 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12315 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12316 * linux-low.c (linux_emit_ops): New.
12317 (linux_target_ops): Install it.
12318 * linux-low.h (struct linux_target_ops): New field emit_ops.
12319
12320 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12321
12322 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12323 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12324
12325 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12326 Stan Shebs <stan@codesourcery.com>
12327
12328 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12329 (all): Depend on $(extra_libraries).
12330 (install-only): Install the IPA.
12331 (IPA_OBJS, IPA_LIB): New.
12332 (clean): Remove the IPA lib.
12333 (IPAGENT_CFLAGS): New.
12334 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12335 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12336 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12337 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12338 * configure.ac: Check for atomic builtins support in the compiler.
12339 (IPA_DEPFILES, extra_libraries): Define.
12340 * configure.srv (ipa_obj): Add description.
12341 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12342 (i[34567]86-*-linux*): Set ipa_obj.
12343 (x86_64-*-linux*): Set ipa_obj.
12344 * linux-low.c (stabilizing_threads): New.
12345 (supports_fast_tracepoints): New.
12346 (linux_detach): Stabilize threads before detaching.
12347 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12348 the lwp is either not stabilizing, or is moving out of a jump pad.
12349 (linux_fast_tracepoint_collecting): New.
12350 (maybe_move_out_of_jump_pad): New.
12351 (enqueue_one_deferred_signal): New.
12352 (dequeue_one_deferred_signal): New.
12353 (linux_wait_for_event_1): If moving out of a jump pad, defer
12354 pending signals to later.
12355 (linux_stabilize_threads): New.
12356 (linux_wait_1): Check if threads need moving out of jump pads, and
12357 do it if so.
12358 (stuck_in_jump_pad_callback): New.
12359 (move_out_of_jump_pad_callback): New.
12360 (lwp_running): New.
12361 (linux_resume_one_lwp): Handle moving out of jump pads.
12362 (linux_set_resume_request): Dequeue deferred signals.
12363 (need_step_over_p): Also step over fast tracepoint jumps.
12364 (start_step_over): Also uninsert fast tracepoint jumps.
12365 (finish_step_over): Also reinsert fast tracepoint jumps.
12366 (linux_install_fast_tracepoint_jump): New.
12367 (linux_target_ops): Install linux_stabilize_threads and
12368 linux_install_fast_tracepoint_jump_pad.
12369 * linux-low.h (linux_target_ops) <get_thread_area,
12370 install_fast_tracepoint_jump_pad>: New fields.
12371 (struct lwp_info) <collecting_fast_tracepoint,
12372 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12373 (linux_get_thread_area): Declare.
12374 * linux-x86-low.c (jump_insn): New.
12375 (x86_get_thread_area): New.
12376 (append_insns): New.
12377 (push_opcode): New.
12378 (amd64_install_fast_tracepoint_jump_pad): New.
12379 (i386_install_fast_tracepoint_jump_pad): New.
12380 (x86_install_fast_tracepoint_jump_pad): New.
12381 (the_low_target): Install x86_get_thread_area and
12382 x86_install_fast_tracepoint_jump_pad.
12383 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12384 (struct fast_tracepoint_jump): New.
12385 (fast_tracepoint_jump_insn): New.
12386 (fast_tracepoint_jump_shadow): New.
12387 (find_fast_tracepoint_jump_at): New.
12388 (fast_tracepoint_jump_here): New.
12389 (delete_fast_tracepoint_jump): New.
12390 (set_fast_tracepoint_jump): New.
12391 (uninsert_fast_tracepoint_jumps_at): New.
12392 (reinsert_fast_tracepoint_jumps_at): New.
12393 (set_breakpoint_at): Use write_inferior_memory.
12394 (uninsert_raw_breakpoint): Use write_inferior_memory.
12395 (check_mem_read): Mask out fast tracepoint jumps.
12396 (check_mem_write): Mask out fast tracepoint jumps.
12397 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12398 (set_fast_tracepoint_jump): Declare.
12399 (delete_fast_tracepoint_jump)
12400 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12401 (reinsert_fast_tracepoint_jumps_at): Declare.
12402 * regcache.c: Don't compile many functions when building the
12403 in-process agent library.
12404 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12405 the register buffer in the heap.
12406 (free_register_cache): If the register buffer isn't owned by the
12407 regcache, don't free it.
12408 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12409 pre-existing register caches.
12410 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12411 type.
12412 (convert_ascii_to_int): : Constify `from' parameter type.
12413 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12414 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12415 the needed buffer in-place.
12416 (relocate_instruction): New.
12417 * server.c (handle_query) <qSymbols>: If the target supports
12418 tracepoints, give it a chance of looking up symbols. Report
12419 support for fast tracepoints.
12420 (handle_status): Stabilize threads.
12421 (process_serial_event): Adjust.
12422 * server.h (struct fast_tracepoint_jump): Forward declare.
12423 (struct process_info) <fast_tracepoint_jumps>: New field.
12424 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12425 (decode_X_packet, decode_M_packet): Adjust.
12426 (relocate_instruction): Declare.
12427 (in_process_agent_loaded): Declare.
12428 (tracepoint_look_up_symbols): Declare.
12429 (struct fast_tpoint_collect_status): Declare.
12430 (fast_tracepoint_collecting): Declare.
12431 (force_unlock_trace_buffer): Declare.
12432 (handle_tracepoint_bkpts): Declare.
12433 (initialize_low_tracepoint)
12434 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12435 * target.h (struct target_ops) <stabilize_threads,
12436 install_fast_tracepoint_jump_pad>: New fields.
12437 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12438 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12439 [HAVE_STDINT_H]: Include stdint.h.
12440 (trace_debug_1): Rename to ...
12441 (trace_vdebug): ... this.
12442 (trace_debug): Rename to ...
12443 (trace_debug_1): ... this. Add `level' parameter.
12444 (trace_debug): New.
12445 (ATTR_USED, ATTR_NOINLINE): New.
12446 (IP_AGENT_EXPORT): New.
12447 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12448 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12449 (about_to_request_buffer_space, trace_buffer_is_full)
12450 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12451 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12452 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12453 (traceframe_write_count, traceframes_created)
12454 (trace_state_variables)
12455 New renaming defines.
12456 (struct ipa_sym_addresses): New.
12457 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12458 (symbol_list): New.
12459 (ipa_sym_addrs): New.
12460 (all_tracepoint_symbols_looked_up): New.
12461 (in_process_agent_loaded): New.
12462 (write_e_ipa_not_loaded): New.
12463 (maybe_write_ipa_not_loaded): New.
12464 (tracepoint_look_up_symbols): New.
12465 (debug_threads) [IN_PROCESS_AGENT]: New.
12466 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12467 (UNKNOWN_SIDE_EFFECTS): New.
12468 (stop_tracing): New.
12469 (flush_trace_buffer): New.
12470 (stop_tracing_bkpt): New.
12471 (flush_trace_buffer_bkpt): New.
12472 (read_inferior_integer): New.
12473 (read_inferior_uinteger): New.
12474 (read_inferior_data_pointer): New.
12475 (write_inferior_data_pointer): New.
12476 (write_inferior_integer): New.
12477 (write_inferior_uinteger): New.
12478 (struct collect_static_trace_data_action): Delete.
12479 (enum tracepoint_type): New.
12480 (struct tracepoint) <type>: New field `type'.
12481 <actions_str, step_actions, step_actions_str>: Only include in
12482 GDBserver.
12483 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12484 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12485 (tracepoints): Use IP_AGENT_EXPORT.
12486 (last_tracepoint): Don't include in the IPA.
12487 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12488 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12489 (alloced_trace_state_variables): New.
12490 (trace_state_variables): Use IP_AGENT_EXPORT.
12491 (traceframe_t): Delete unused variable.
12492 (circular_trace_buffer): Don't include in the IPA.
12493 (trace_buffer_start): Delete.
12494 (struct trace_buffer_control): New.
12495 (trace_buffer_free): Delete.
12496 (struct ipa_trace_buffer_control): New.
12497 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12498 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12499 New.
12500 (trace_buffer_ctrl): New.
12501 (TRACE_BUFFER_CTRL_CURR): New.
12502 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12503 Reimplement as macros.
12504 (trace_buffer_wrap): Delete.
12505 (traceframe_write_count, traceframe_read_count)
12506 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12507 (struct tracepoint_hit_ctx) <type>: New field.
12508 (struct fast_tracepoint_ctx): New.
12509 (memory_barrier): New.
12510 (cmpxchg): New.
12511 (record_tracepoint_error): Update atomically in the IPA.
12512 (clear_inferior_trace_buffer): New.
12513 (about_to_request_buffer_space): New.
12514 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12515 updating the same buffer.
12516 (add_tracepoint): Default the tracepoint's type to trap
12517 tracepoint, and orig_size to -1.
12518 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12519 internal variables.
12520 (create_trace_state_variable): New parameter `gdb'. Handle it.
12521 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12522 (cmd_qtdp): Handle fast tracepoints.
12523 (cmd_qtdv): Adjust.
12524 (max_jump_pad_size): New.
12525 (gdb_jump_pad_head): New.
12526 (get_jump_space_head): New.
12527 (claim_jump_space): New.
12528 (sort_tracepoints): New.
12529 (MAX_JUMP_SIZE): New.
12530 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12531 IPA.
12532 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12533 support. Upload fast traceframes, and delete internal IPA
12534 breakpoints.
12535 (stop_tracing_handler): New.
12536 (flush_trace_buffer_handler): New.
12537 (cmd_qtstop): Upload fast tracepoints.
12538 (response_tracepoint): Handle fast tracepoints.
12539 (tracepoint_finished_step): Upload fast traceframes. Set the
12540 tracepoint hit context's tracepoint type.
12541 (handle_tracepoint_bkpts): New.
12542 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12543 type. Add comment about fast tracepoints.
12544 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12545 non-existing action_str field.
12546 (get_context_regcache): Handle fast tracepoints.
12547 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12548 to the regcache.
12549 (fast_tracepoint_from_jump_pad_address): New.
12550 (fast_tracepoint_from_ipa_tpoint_address): New.
12551 (collecting_t): New.
12552 (force_unlock_trace_buffer): New.
12553 (fast_tracepoint_collecting): New.
12554 (collecting): New.
12555 (gdb_collect): New.
12556 (write_inferior_data_ptr): New.
12557 (target_tp_heap): New.
12558 (target_malloc): New.
12559 (download_agent_expr): New.
12560 (UALIGN): New.
12561 (download_tracepoints): New.
12562 (download_trace_state_variables): New.
12563 (upload_fast_traceframes): New.
12564 (IPA_FIRST_TRACEFRAME): New.
12565 (IPA_NEXT_TRACEFRAME_1): New.
12566 (IPA_NEXT_TRACEFRAME): New.
12567 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12568 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12569 (gdb_jump_pad_buffer_end): New.
12570 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12571 (initialize_tracepoint): Adjust.
12572 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12573 buffer. Initialize the low module.
12574 * utils.c (PREFIX, TOOLNAME): New.
12575 (malloc_failure): Use PREFIX.
12576 (error): In the IPA, an error causes an exit.
12577 (fatal, warning): Use PREFIX.
12578 (internal_error): Use TOOLNAME.
12579 (NUMCELLS): Increase to 10.
12580 * configure, config.in: Regenerate.
12581
12582 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12583
12584 * server.c (handle_query) <qSupported>: Do two passes over the
12585 qSupported string to avoid nesting strtok.
12586
12587 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12588
12589 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
12590 (CDEPS): New.
12591 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
12592 -Wl,--dynamic-list.
12593 * configure: Regenerate.
12594 * proc-service.list: New.
12595
12596 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12597
12598 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
12599 New comment.
12600
12601 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
12602
12603 * gdbreplay.c (remote_open): Check error return from socket() call by
12604 its equality to -1 not by it being negative.
12605 * remote-utils.c (remote_open): Likewise.
12606
12607 2010-05-23 Pedro Alves <pedro@codesourcery.com>
12608
12609 * config.h: Regenerate.
12610
12611 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12612
12613 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
12614 doesn't provide PTRACE_GET_THREAD_AREA.
12615
12616 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12617
12618 * linux-m68k-low.c: Include <asm/ptrace.h>
12619 (ps_get_thread_area): Implement.
12620
12621 2010-05-03 Doug Evans <dje@google.com>
12622
12623 * event-loop.c (struct callback_event): New struct.
12624 (callback_list): New global.
12625 (append_callback_event, delete_callback_event): New functions.
12626 (process_callback): New function.
12627 (start_event_loop): Call it.
12628 * remote-utils.c (NOT_SCHEDULED): Define.
12629 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
12630 moved out of readchar.
12631 (readchar): Rewrite. Call reschedule before returning.
12632 (reset_readchar): New function.
12633 (remote_close): Call it.
12634 (process_remaining, reschedule): New functions.
12635 * server.h (callback_handler_func): New typedef.
12636 (append_callback_event, delete_callback_event): Declare.
12637
12638 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12639
12640 * proc-service.c (ps_pglobal_lookup): Use
12641 thread_db_look_up_one_symbol.
12642 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
12643 parameter. Use it instead of all_symbols_looked_up.
12644 * server.h (struct process_info) <all_symbols_looked_up>: Delete
12645 field.
12646 (all_symbols_looked_up): Don't declare.
12647 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
12648 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
12649 field.
12650 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
12651 Set all_symbols_looked_up here.
12652 (thread_db_look_up_one_symbol): New.
12653 (thread_db_get_tls_address): Adjust.
12654 (thread_db_load_search, try_thread_db_load_1): Always allocate the
12655 thread_db object on the heap, and tentatively set it in the
12656 process structure.
12657 (thread_db_init): Don't set all_symbols_looked_up here.
12658 * linux-low.h (thread_db_look_up_one_symbol): Declare.
12659
12660 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12661
12662 * linux-low.c (linux_kill, linux_detach): Adjust.
12663 (status_pending_p_callback): Remove redundant statement. Check
12664 for !TARGET_WAITIKIND_IGNORE, instead of
12665 TARGET_WAITKIND_STOPPED.
12666 (handle_tracepoints): Make sure LWP is locked. Adjust.
12667 (linux_wait_for_event_1): Adjust.
12668 (linux_cancel_breakpoints): New.
12669 (unsuspend_one_lwp): New.
12670 (unsuspend_all_lwps): New.
12671 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
12672 (send_sigstop_callback): Change return type to int, add new
12673 `except' parameter and handle it.
12674 (suspend_and_send_sigstop_callback): New.
12675 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
12676 pass them down. If SUSPEND, also increment the lwp's suspend
12677 count.
12678 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
12679 (need_step_over_p): Don't consider suspended LWPs.
12680 (start_step_over): Adjust.
12681 (proceed_one_lwp): Change return type to int, add new `except'
12682 parameter and handle it.
12683 (unsuspend_and_proceed_one_lwp): New.
12684 (proceed_all_lwps): Use find_inferior instead of
12685 for_each_inferior.
12686 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
12687 also decrement the suspend count of LWPs. Pass `except' down,
12688 instead of hacking its suspend count.
12689 (linux_pause_all): Add `freeze' parameter. Adjust.
12690 (linux_unpause_all): New.
12691 (linux_target_ops): Install linux_unpause_all.
12692 * server.c (handle_status): Adjust.
12693 * target.h (struct target_ops): New fields `unpause_all' and
12694 `cancel_breakpoints'. Add new parameter to `pause_all'.
12695 (pause_all): Add new `freeze' parameter.
12696 (unpause_all): New.
12697 (cancel_breakpoints): New.
12698 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
12699 cancel breakpoints.
12700 (cmd_qtstart): Pause threads.
12701 (stop_tracing): Pause threads, and cancel breakpoints.
12702 * win32-low.c (win32_target_ops): Adjust.
12703
12704 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12705
12706 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
12707 the inferior right away from here...
12708 (linux_wait_1): ... to here, and adjust to check the thread's
12709 last_resume_kind instead of the lwp's step or stop_expected flags.
12710
12711 2010-05-02 Pedro Alves <pedro@codesourcery.com>
12712
12713 * README: Use consistent `GDB' and `GDBserver' spellings.
12714
12715 2010-05-02 Pedro Alves <pedro@codesourcery.com>
12716
12717 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
12718 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
12719 (linux_detach_one_lwp): Assume the lwp is stopped.
12720 (any_thread_of): Delete.
12721 (linux_detach): Stop all lwps here. Don't blindly delete all
12722 breakpoints.
12723 (delete_lwp_callback): New.
12724 (linux_mourn): Delete all lwps of the process that is gone.
12725 (linux_wait_1): Don't delete the last lwp of the process here.
12726 * mem-break.h (mark_breakpoints_out): Declare.
12727 * mem-break.c (mark_breakpoints_out): New.
12728 (free_all_breakpoints): Use it.
12729 * server.c (handle_target_event): If the process is gone, mark
12730 breakpoints out.
12731 * thread-db.c (struct thread_db) <create_bp>: New field.
12732 (thread_db_enable_reporting): Fix prototype. Store a thread event
12733 breakpoint reference in the thread_db struct.
12734 (thread_db_load_search): Clear the thread_db object.
12735 (try_thread_db_load_1): Ditto.
12736 (switch_to_process): New.
12737 (disable_thread_event_reporting): Use it.
12738 (remove_thread_event_breakpoints): New.
12739 (thread_db_detach, thread_db_mourn): Use it.
12740
12741 2010-05-01 Pedro Alves <pedro@codesourcery.com>
12742
12743 * linux-low.c (linux_enable_event_reporting): New.
12744 (linux_wait_for_event_1, handle_extended_wait): Use it.
12745
12746 2010-04-30 Pedro Alves <pedro@codesourcery.com>
12747
12748 * linux-low.c (linux_kill_one_lwp, linux_kill)
12749 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
12750 (send_sigstop): Take an lwp_info as parameter instead. Queue a
12751 SIGSTOP even if the LWP is stopped.
12752 (send_sigstop_callback): New.
12753 (stop_all_lwps): Use send_sigstop_callback instead.
12754 (linux_resume_one_thread): Adjust.
12755 (proceed_one_lwp): Still proceed an LWP that the client has
12756 requested to stop, if we haven't reported it as stopped yet. Make
12757 sure that LWPs the client want stopped, have a pending SIGSTOP.
12758
12759 2010-04-26 Doug Evans <dje@google.com>
12760
12761 * server.c (handle_general_set): Make static.
12762
12763 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
12764 Print received char after testing for error/eof instead of before.
12765 (input_interrupt): Tweak comment.
12766
12767 2010-04-23 Doug Evans <dje@google.com>
12768
12769 * server.c (start_inferior): Print inferior argv if --debug.
12770
12771 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
12772
12773 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
12774 * nto-x86-low.c: Include server.h
12775
12776 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
12777
12778 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
12779 be consistent with other sources of this directory.
12780 (init_registers_amd64): Correct name of source file of this function
12781 in the comment.
12782
12783 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12784
12785 * configure.srv (x86_64-*-mingw*): New configuration for Windows
12786 64-bit executables.
12787
12788 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12789
12790 * win32-i386-low.c: Add 64-bit support.
12791 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
12792 (init_registers_amd64): Declare.
12793 (mappings): Add 64-bit version of array.
12794 (init_windows_x86): New function.
12795 (the_low_target): Change init_arch field to init_windows_x86.
12796
12797 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12798
12799 * win32-low.c: Adapt to support also 64-bit architecture.
12800 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
12801 (get_image_name): Use SIZE_T type for local variable `done'.
12802 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
12803 (toolhelp_get_dll_name): Idem.
12804 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
12805 Use uintptr_t typecast to avoid warning.
12806 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
12807 (handle_exception): Use phex_nz to avoid warning.
12808 (win32_wait): Remove unused local variable `process'.
12809
12810 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12811
12812 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
12813 `amd64-avx.o'.
12814
12815 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
12816
12817 * configure.ac: Use `ws2_32' library for srv_mingw.
12818 * configure: Regenerate.
12819 * gdbreplay.c: Include winsock2.h instead of winsock.h.
12820 * remote-utils.c: Likewise.
12821
12822 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
12823
12824 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
12825 if __x86_64__ is defined.
12826
12827 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12828
12829 * configure: Regenerate.
12830
12831 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12832
12833 * server.c (handle_query): Handle 'qGetTIBAddr' query.
12834 * target.h (target_ops): New get_tib_address field.
12835 * win32-low.h (win32_thread_info): Add thread_local_base field.
12836 * win32-low.c (child_add_thread): Add tlb argument.
12837 Set thread_local_base field to TLB.
12838 (get_child_debug_event): Adapt to child_add_thread change.
12839 (win32_get_tib_address): New function.
12840 (win32_target_ops): Set get_tib_address field to
12841 win32_get_tib_address.
12842 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
12843
12844 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12845
12846 * linux-low.c (linux_mourn): Also remove the process.
12847 * server.c (handle_target_event): Don't remove the process here.
12848 * nto-low.c (nto_mourn): New.
12849 (nto_target_ops): Install it.
12850 * spu-low.c (spu_mourn): New.
12851 (spu_target_ops): Install it.
12852 * win32-low.c (win32_mourn): New.
12853 (win32_target_ops): Install it.
12854
12855 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12856
12857 * server.h (buffer_xml_printf): Remove redundant `;'.
12858
12859 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12860
12861 * regcache.c (set_register_cache): Invalidate regcaches before
12862 changing the register cache layout.
12863 (regcache_invalidate_one): Allow a NULL regcache.
12864 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
12865 regcaches before changing the register cache layout or the target
12866 regsets.
12867
12868 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
12869
12870 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
12871 variable warning on Linux/x86-64.
12872
12873 2010-04-11 Pedro Alves <pedro@codesourcery.com>
12874
12875 GDBserver disconnected tracing support.
12876
12877 * linux-low.c (linux_remove_process): Delete.
12878 (add_lwp): Don't set last_resume_kind here.
12879 (linux_kill): Use `mourn'.
12880 (linux_detach): Use `thread_db_detach', and `mourn'.
12881 (linux_mourn): New.
12882 (linux_attach_lwp_1): Adjust comment.
12883 (linux_attach): last_resume_kind moved the thread_info; adjust.
12884 (status_pending_p_callback): Adjust.
12885 (linux_wait_for_event_1): Adjust.
12886 (count_events_callback, select_singlestep_lwp_callback)
12887 (select_event_lwp_callback, cancel_breakpoints_callback)
12888 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
12889 (proceed_one_lwp): Adjust.
12890 (linux_async): Add debug output.
12891 (linux_thread_stopped): New.
12892 (linux_pause_all): New.
12893 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
12894 linux_pause_all.
12895 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
12896 (thread_db_free): Delete declaration.
12897 (thread_db_detach, thread_db_mourn): Declare.
12898 * thread-db.c (thread_db_init): Use thread_db_mourn.
12899 (thread_db_free): Delete, split in two.
12900 (disable_thread_event_reporting): New.
12901 (thread_db_detach): New.
12902 (thread_db_mourn): New.
12903
12904 * server.h (struct thread_info) <last_resume_kind>: New field.
12905 <attached>: Add comment.
12906 <gdb_detached>: New field.
12907 (handler_func): Change return type to int.
12908 (handle_serial_event, handle_target_event): Ditto.
12909 (gdb_connected): Declare.
12910 (tracing): Delete.
12911 (disconnected_tracing): Declare.
12912 (stop_tracing): Declare.
12913
12914 * server.c (handle_query) <qSupported>: Report support for
12915 disconnected tracing.
12916 (queue_stop_reply_callback): Account for running threads.
12917 (gdb_wants_thread_stopped): New.
12918 (gdb_wants_all_threads_stopped): New.
12919 (gdb_reattached_process): New.
12920 (handle_status): Clear the `gdb_detached' flag of all processes.
12921 In all-stop, stop all threads.
12922 (main): Be sure to leave tfind mode. Handle disconnected tracing.
12923 (process_serial_event): If the remote connection breaks, or if an
12924 exit was forced with "monitor exit", force an event loop exit.
12925 Handle disconnected tracing on detach.
12926 (handle_serial_event): Adjust.
12927 (handle_target_event): If GDB isn't connected, forward events back
12928 to the inferior, unless the last process exited, in which case,
12929 exit gdbserver. Adjust interface.
12930
12931 * remote-utils.c (remote_open): Don't block in accept. Instead
12932 register an event loop source on the listen socket file
12933 descriptor. Refactor bits into ...
12934 (listen_desc): ... this new global.
12935 (gdb_connected): ... this new function.
12936 (enable_async_notification): ... this new function.
12937 (handle_accept_event): ... this new function.
12938 (remote_close): Clear remote_desc.
12939
12940 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
12941
12942 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
12943 New fields.
12944 (mourn_inferior): Define.
12945 (target_process_qsupported): Avoid the dangling else problem.
12946 (thread_stopped): Define.
12947 (pause_all): Define.
12948 (target_waitstatus_to_string): Declare.
12949 * target.c (target_waitstatus_to_string): New.
12950
12951 * tracepoint.c (tracing): Make extern.
12952 (disconnected_tracing): New.
12953 (stop_tracing): Make extern. Handle tracing stops due to GDB
12954 disconnecting.
12955 (cmd_qtdisconnected): New.
12956 (cmd_qtstatus): Report disconnected tracing status in trace reply.
12957 (handle_tracepoint_general_set): Handle QTDisconnected.
12958
12959 * event-loop.c (event_handler_func): Change return type to int.
12960 (process_event): Bail out if the event handler wants the event
12961 loop to stop.
12962 (handle_file_event): Ditto.
12963 (start_event_loop): Bail out if the event handler wants the event
12964 loop to stop.
12965
12966 * nto-low.c (nto_target_ops): Adjust.
12967 * spu-low.c (spu_wait): Don't remove the process here.
12968 (spu_target_ops): Adjust.
12969 * win32-low.c (win32_wait): Don't remove the process here.
12970 (win32_target_ops): Adjust.
12971
12972 2010-04-11 Pedro Alves <pedro@codesourcery.com>
12973
12974 * regcache.c (realloc_register_cache): Invalidate inferior's
12975 regcache before recreating it.
12976
12977 2010-04-09 Pedro Alves <pedro@codesourcery.com>
12978
12979 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
12980
12981 2010-04-09 Stan Shebs <stan@codesourcery.com>
12982 Pedro Alves <pedro@codesourcery.com>
12983
12984 * server.h (LONGEST): New.
12985 (struct thread_info) <while_stepping>: New field.
12986 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
12987 Declare.
12988 (initialize_tracepoint, handle_tracepoint_general_set)
12989 (handle_tracepoint_query, tracepoint_finished_step)
12990 (tracepoint_was_hit, release_while_stepping_state_list):
12991 (current_traceframe): Declare.
12992 * server.c (handle_general_set): Handle tracepoint packets.
12993 (read_memory): New.
12994 (write_memory): New.
12995 (handle_search_memory_1): Use read_memory.
12996 (handle_query): Report support for conditional tracepoints, trace
12997 state variables, and tracepoint sources. Handle tracepoint
12998 queries.
12999 (main): Initialize the tracepoints module.
13000 (process_serial_event): Handle traceframe reads/writes.
13001
13002 * linux-low.c (handle_tracepoints): New.
13003 (linux_wait_1): Call it.
13004 (linux_resume_one_lwp): Handle while-stepping.
13005 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13006 (linux_target_ops): Install them.
13007 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13008 New field.
13009 * linux-x86-low.c (x86_supports_tracepoints): New.
13010 (the_low_target). Install it.
13011
13012 * mem-break.h (delete_breakpoint): Declare.
13013 * mem-break.c (delete_breakpoint): Make external.
13014
13015 * target.h (struct target_ops): Add `supports_tracepoints',
13016 `read_pc', and `write_pc' fields.
13017 (target_supports_tracepoints): Define.
13018 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13019 (phex_nz): New.
13020
13021 * regcache.h (struct regcache) <registers_owned>: New field.
13022 (init_register_cache, regcache_cpy): Declare.
13023 (regcache_read_pc, regcache_write_pc): Declare.
13024 (register_cache_size): Declare.
13025 (supply_regblock): Declare.
13026 * regcache.c (init_register_cache): New.
13027 (new_register_cache): Use it.
13028 (regcache_cpy): New.
13029 (register_cache_size): New.
13030 (supply_regblock): New.
13031 (regcache_read_pc, regcache_write_pc): New.
13032
13033 * tracepoint.c: New.
13034
13035 * Makefile.in (OBS): Add tracepoint.o.
13036 (tracepoint.o): New rule.
13037
13038 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13039
13040 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13041 (i386-mmx.o): New.
13042 (i386-mmx.c): Likewise.
13043 (i386-mmx-linux.o): Likewise.
13044 (i386-mmx-linux.c): Likewise.
13045
13046 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13047 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13048 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13049 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13050
13051 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13052 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13053 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13054
13055 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13056
13057 * Makefile.in (clean): Updated.
13058 (i386-avx.o): New.
13059 (i386-avx.c): Likewise.
13060 (i386-avx-linux.o): Likewise.
13061 (i386-avx-linux.c): Likewise.
13062 (amd64-avx.o): Likewise.
13063 (amd64-avx.c): Likewise.
13064 (amd64-avx-linux.o): Likewise.
13065 (amd64-avx-linux.c): Likewise.
13066
13067 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13068 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13069 (srv_amd64_regobj): Add amd64-avx.o.
13070 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13071 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13072 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13073 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13074 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13075 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13076 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13077
13078 * i387-fp.c: Include "i386-xstate.h".
13079 (i387_xsave): New.
13080 (i387_cache_to_xsave): Likewise.
13081 (i387_xsave_to_cache): Likewise.
13082 (x86_xcr0): Likewise.
13083
13084 * i387-fp.h (i387_cache_to_xsave): Likewise.
13085 (i387_xsave_to_cache): Likewise.
13086 (x86_xcr0): Likewise.
13087
13088 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13089 * linux-crisv32-low.c (target_regsets): Likewise.
13090 * linux-m68k-low.c (target_regsets): Likewise.
13091 * linux-mips-low.c (target_regsets): Likewise.
13092 * linux-ppc-low.c (target_regsets): Likewise.
13093 * linux-s390-low.c (target_regsets): Likewise.
13094 * linux-sh-low.c (target_regsets): Likewise.
13095 * linux-sparc-low.c (target_regsets): Likewise.
13096 * linux-xtensa-low.c (target_regsets): Likewise.
13097
13098 * linux-low.c: Include <sys/uio.h>.
13099 (regsets_fetch_inferior_registers): Support nt_type.
13100 (regsets_store_inferior_registers): Likewise.
13101 (linux_process_qsupported): New.
13102 (linux_target_ops): Add linux_process_qsupported.
13103
13104 * linux-low.h (regset_info): Add nt_type.
13105 (linux_target_ops): Add process_qsupported.
13106
13107 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13108 and <sys/uio.h>.
13109 (init_registers_i386_avx_linux): New.
13110 (init_registers_amd64_avx_linux): Likewise.
13111 (xmltarget_i386_linux_no_xml): Likewise.
13112 (xmltarget_amd64_linux_no_xml): Likewise.
13113 (PTRACE_GETREGSET): Likewise.
13114 (PTRACE_SETREGSET): Likewise.
13115 (x86_fill_xstateregset): Likewise.
13116 (x86_store_xstateregset): Likewise.
13117 (use_xml): Likewise.
13118 (x86_linux_update_xmltarget): Likewise.
13119 (x86_linux_process_qsupported): Likewise.
13120 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13121 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13122 init_registers_i386_linux here. Call
13123 x86_linux_update_xmltarget.
13124 (the_low_target): Add x86_linux_process_qsupported.
13125
13126 * server.c (handle_query): Call target_process_qsupported.
13127
13128 * target.h (target_ops): Add process_qsupported.
13129 (target_process_qsupported): New.
13130
13131 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13132
13133 * inferiors.c (add_thread): Set last_status kind to
13134 TARGET_WAITKIND_IGNORE.
13135 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13136 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13137 (linux_wait_1): Move `thread' local definition to block that uses
13138 it. Don't NULL initialize `event_child'.
13139 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13140 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13141 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13142
13143 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13144
13145 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13146 an extended waitstatus, or by a watchpoint.
13147 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13148 thread was stepping or has been stopped by a watchpoint.
13149
13150 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13151
13152 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13153 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13154 of another, then delete the previous, and validate all
13155 breakpoints.
13156 (validate_inserted_breakpoint): New.
13157 (delete_disabled_breakpoints): New.
13158 (validate_breakpoints): New.
13159 (check_mem_read): Validate breakpoints before trusting their
13160 shadow. Delete disabled breakpoints.
13161 (check_mem_write): Validate breakpoints before trusting they
13162 should be inserted. Delete disabled breakpoints.
13163 * mem-break.h (validate_breakpoints):
13164 * server.c (handle_query): Validate breakpoints when we see a
13165 qSymbol query.
13166
13167 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13168
13169 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13170 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13171 if we could tell there's a GDB breakpoint at stop_pc.
13172 (need_step_over_p): Don't do a step over if we find a GDB
13173 breakpoint at the resume PC.
13174
13175 * mem-break.c (struct raw_breakpoint): New.
13176 (enum bkpt_type): New type `gdb_breakpoint'.
13177 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13178 fields. New field `raw'.
13179 (find_raw_breakpoint_at): New.
13180 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13181 breakpoint instead.
13182 (set_breakpoint_at): Adjust.
13183 (delete_raw_breakpoint): New.
13184 (release_breakpoint): New.
13185 (delete_breakpoint): Rename to...
13186 (delete_breakpoint_1): ... this. Add proc parameter. Use
13187 release_breakpoint. Return ENOENT.
13188 (delete_breakpoint): Reimplement.
13189 (find_breakpoint_at): Delete.
13190 (find_gdb_breakpoint_at): New.
13191 (delete_breakpoint_at): Delete.
13192 (set_gdb_breakpoint_at): New.
13193 (delete_gdb_breakpoint_at): New.
13194 (gdb_breakpoint_here): New.
13195 (set_reinsert_breakpoint): Use release_breakpoint.
13196 (uninsert_breakpoint): Rename to ...
13197 (uninsert_raw_breakpoint): ... this.
13198 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13199 (reinsert_raw_breakpoint): Change parameter type to
13200 raw_breakpoint.
13201 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13202 instead.
13203 (check_breakpoints): Adjust. Use release_breakpoint.
13204 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13205 (breakpoint_inserted_here): Ditto.
13206 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13207 Don't trust the breakpoint's shadow if it is not inserted.
13208 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13209 (delete_all_breakpoints): Adjust.
13210 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13211 use delete_breakpoint_1.
13212
13213 * mem-break.h (breakpoints_supported): Delete declaration.
13214 (set_gdb_breakpoint_at): Declare.
13215 (gdb_breakpoint_here): Declare.
13216 (delete_breakpoint_at): Delete.
13217 (delete_gdb_breakpoint_at): Declare.
13218
13219 * server.h (struct raw_breakpoint): Forward declare.
13220 (struct process_info): New field `raw_breakpoints'.
13221
13222 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13223 breakpoints.
13224
13225 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13226
13227 * linux-low.c (status_pending_p_callback): Fix comment.
13228 (linux_wait_for_event_1): Move most of the internal breakpoint
13229 handling from here...
13230 (linux_wait_1): ... to here.
13231 (count_events_callback): New.
13232 (select_singlestep_lwp_callback): New.
13233 (select_event_lwp_callback): New.
13234 (cancel_breakpoints_callback): New.
13235 (select_event_lwp): New.
13236 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13237 priority to all LWPs that have had events that should be reported
13238 to the client. Cancel breakpoints when about to reporting the
13239 event to the client, not while stopping lwps. No longer cancel
13240 finished single-steps here.
13241 (cancel_finished_single_step): Delete.
13242 (cancel_finished_single_steps): Delete.
13243
13244 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13245
13246 * mem-break.c (enum bkpt_type): New.
13247 (struct breakpoint): New field `type'.
13248 (set_breakpoint_at): Change return type to struct breakpoint
13249 pointer. Set type to `other_breakpoint' by default.
13250 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13251 in the breakpoint list.
13252 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13253 (reinsert_breakpoint): Rename to ...
13254 (reinsert_raw_breakpoint): ... this.
13255 (reinsert_breakpoints_at): Adjust.
13256 * mem-break.h (struct breakpoint): Declare.
13257 (set_breakpoint_at): Change return type to struct breakpoint
13258 pointer.
13259
13260 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13261
13262 * server.c (handle_query): Assign, not compare.
13263
13264 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13265
13266 Teach linux gdbserver to step-over-breakpoints.
13267
13268 * linux-low.c (can_hardware_single_step): New.
13269 (supports_breakpoints): New.
13270 (handle_extended_wait): If stopping threads, read the stop pc of
13271 the new cloned LWP.
13272 (get_pc): New.
13273 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13274 low target doesn't support retrieving the PC.
13275 (add_lwp): Set last_resume_kind to resume_continue.
13276 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13277 (linux_attach): Don't clear stop_expected. Set the lwp's
13278 last_resume_kind to resume_stop.
13279 (linux_detach_one_lwp): Don't check for removed breakpoints.
13280 (check_removed_breakpoint): Delete.
13281 (status_pending_p): Rename to ...
13282 (status_pending_p_callback): ... this. Don't check for removed
13283 breakpoints. Don't consider threads that are stopped from GDB's
13284 perspective.
13285 (linux_wait_for_lwp): Always read the stop_pc here.
13286 (cancel_breakpoint): New.
13287 (step_over_bkpt): New global.
13288 (linux_wait_for_event_1): Implement stepping over breakpoints.
13289 (gdb_wants_lwp_stopped): New.
13290 (gdb_wants_all_stopped): New.
13291 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13292 single-step traps here. Store the thread's last reported target
13293 wait status.
13294 (send_sigstop): Don't clear stop_expected. Always set it,
13295 instead.
13296 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13297 (cancel_finished_single_step): New.
13298 (cancel_finished_single_steps): New.
13299 (wait_for_sigstop): Don't cancel finished single-step traps here.
13300 (linux_resume_one_lwp): Don't check for removed breakpoints.
13301 Don't set `step' on non-hardware step archs.
13302 (linux_set_resume_request): Ignore resume_stop requests if already
13303 stopping or stopped. Set the lwp's last_resume_kind.
13304 (resume_status_pending_p): Don't check for removed breakpoints.
13305 (need_step_over_p): New.
13306 (start_step_over): New.
13307 (finish_step_over): New.
13308 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13309 requests. Clear the thread's last reported target waitstatus.
13310 Don't use the `suspended' flag. Don't consider pending breakpoints.
13311 (linux_resume): Start a step-over if necessary.
13312 (proceed_one_lwp): New.
13313 (proceed_all_lwps): New.
13314 (unstop_all_lwps): New.
13315 * linux-low.h (struct lwp_info): Rewrite comment for the
13316 `suspended' flag. Add the `stop_pc' field. Delete the
13317 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13318 Add `'last_resume_kind' and `need_step_over' fields.
13319 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13320 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13321 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13322 (set_raw_breakpoint_at): New.
13323 (set_breakpoint_at): Rewrite to use it.
13324 (reinsert_breakpoint_handler): Delete.
13325 (set_reinsert_breakpoint): New.
13326 (reinsert_breakpoint_by_bp): Delete.
13327 (delete_reinsert_breakpoints): New.
13328 (uninsert_breakpoint): Rewrite.
13329 (uninsert_breakpoints_at): New.
13330 (reinsert_breakpoint): Rewrite.
13331 (reinsert_breakpoints_at): New.
13332 (check_breakpoints): Rewrite.
13333 (breakpoint_here): New.
13334 (breakpoint_inserted_here): New.
13335 (check_mem_read): Adjust.
13336 * mem-break.h (breakpoints_supported, breakpoint_here)
13337 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13338 (reinsert_breakpoint_by_bp): Delete declaration.
13339 (delete_reinsert_breakpoints): Declare.
13340 (reinsert_breakpoint): Delete declaration.
13341 (reinsert_breakpoints_at): Declare.
13342 (uninsert_breakpoint): Delete declaration.
13343 (uninsert_breakpoints_at): Declare.
13344 (check_breakpoints): Adjust prototype.
13345 * server.h: Adjust include order.
13346 (struct thread_info): Declare here. Add a `last_status' field.
13347
13348 2010-03-23 Michael Snyder <msnyder@vmware.com>
13349
13350 * server.c (crc32): New function.
13351 (handle_query): Add handling for 'qCRC:' request.
13352
13353 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13354
13355 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13356 lwp had been stopped by a watchpoint.
13357
13358 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13359
13360 * server.h (internal_error): Declare.
13361 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13362 * utils.c (internal_error): New function.
13363
13364 2010-03-15 Andreas Schwab <schwab@redhat.com>
13365
13366 * configure.srv: Fix typo setting srv_regobj.
13367
13368 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13369
13370 * linux-low.c (fetch_register): Avoid passing a non string literal
13371 format to `error'.
13372 (usr_store_inferior_registers): Ditto.
13373
13374 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13375
13376 * linux-low.c (linux_write_memory): Bail out early if peeking
13377 memory failed.
13378
13379 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13380
13381 * linux-low.h (struct lwp_info): New fields
13382 `stopped_by_watchpoint' and `stopped_data_address'.
13383 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13384 here, and cache them in the lwp object.
13385 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13386 directly.
13387 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13388 field.
13389 (linux_stopped_by_watchpoint): Rewrite.
13390 (linux_stopped_data_address): Rewrite.
13391
13392 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13393
13394 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13395 switching the current inferior, not before.
13396
13397 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13398
13399 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13400 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13401 i386-linux.c and amd64-linux.c.
13402 (reg-i386.o): Removed.
13403 (reg-i386.c): Likewise.
13404 (reg-i386-linux.o): Likewise.
13405 (reg-i386-linux.c): Likewise.
13406 (reg-x86-64.o): Likewise.
13407 (reg-x86-64.c): Likewise.
13408 (reg-x86-64-linux.o): Likewise.
13409 (reg-x86-64-linux.c): Likewise.
13410 (i386.o): New.
13411 (i386.c): Likewise.
13412 (i386-linux.o): Likewise.
13413 (i386-linux.c): Likewise.
13414 (amd64.o): Likewise.
13415 (amd64.c): Likewise.
13416 (amd64-linux.o): Likewise.
13417 (amd64-linux.c): Likewise.
13418
13419 * configure.srv (srv_i386_regobj): New.
13420 (srv_i386_linux_regobj): Likewise.
13421 (srv_amd64_regobj): Likewise.
13422 (srv_amd64_linux_regobj): Likewise.
13423 (srv_i386_32bit_xmlfiles): Likewise.
13424 (srv_i386_64bit_xmlfiles): Likewise.
13425 (srv_i386_xmlfiles): Likewise.
13426 (srv_amd64_xmlfiles): Likewise.
13427 (srv_i386_linux_xmlfiles): Likewise.
13428 (srv_amd64_linux_xmlfiles): Likewise.
13429 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13430 srv_xmlfiles to $srv_i386_xmlfiles.
13431 (i[34567]86-*-mingw32ce*): Likewise.
13432 (i[34567]86-*-mingw*): Likewise.
13433 (i[34567]86-*-nto*): Likewise.
13434 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13435 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13436 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13437 (x86_64-*-linux*): Likewise.
13438
13439 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13440 (init_registers_amd64_linux): New.
13441 (x86_arch_setup): Replace init_registers_x86_64_linux with
13442 init_registers_amd64_linux.
13443
13444 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13445
13446 * configure.ac: Check for libdl. If it is not available link against
13447 static libthread_db.
13448 * configure: Regenerate.
13449
13450 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13451
13452 PR9605
13453
13454 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13455 handing a read watchpoint.
13456 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13457
13458 2010-02-12 Doug Evans <dje@google.com>
13459
13460 * linux-low.c (linux_supports_tracefork_flag): Document.
13461 (linux_look_up_symbols): Add comment.
13462
13463 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13464
13465 * regcache.c (supply_register): Clear regcache if buf is NULL.
13466
13467 2010-02-02 Nicolas Roche <roche@sourceware.org>
13468 Joel Brobecker <brobecker@adacore.com>
13469
13470 * inferiors.c (find_inferior): Add function documentation.
13471 (unloaded_dll): Handle the case where the unloaded dll has not
13472 been previously registered in the dll list.
13473
13474 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13475
13476 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13477 (thumb2_breakpoint): New.
13478 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13479
13480 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13481
13482 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13483 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13484 breakpoints.
13485
13486 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13487
13488 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13489
13490 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13491
13492 * linux-s390-low.c (s390_collect_ptrace_register)
13493 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13494
13495 2010-01-21 Doug Evans <dje@google.com>
13496
13497 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13498 (PTRACE_ARG4_TYPE): New macro.
13499 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13500 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13501 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13502 (usr_store_inferior_registers): Ditto.
13503 (linux_read_memory, linux_write_memory): Ditto.
13504 (linux_test_for_tracefork): Ditto.
13505
13506 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13507 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13508
13509 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13510
13511 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13512 target.
13513
13514 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13515
13516 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13517 prototype to take a regcache. Adjust.
13518
13519 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13520
13521 * regcache.h (struct thread_info): Forward declare.
13522 (struct regcache): New.
13523 (new_register_cache): Adjust prototype.
13524 (get_thread_regcache): Declare.
13525 (free_register_cache): Adjust prototype.
13526 (registers_to_string, registers_from_string): Ditto.
13527 (supply_register, supply_register_by_name, collect_register)
13528 (collect_register_as_string, collect_register_by_name): Ditto.
13529 * regcache.c (struct inferior_regcache_data): Delete.
13530 (get_regcache): Rename to ...
13531 (get_thread_regcache): ... this. Adjust. Switch inferior before
13532 fetching registers.
13533 (regcache_invalidate_one): Adjust.
13534 (regcache_invalidate): Fix prototype.
13535 (new_register_cache): Return the new register cache.
13536 (free_register_cache): Change prototype.
13537 (realloc_register_cache): Adjust.
13538 (registers_to_string): Change prototype to take a regcache. Adjust.
13539 (registers_from_string): Ditto.
13540 (register_data): Ditto.
13541 (supply_register): Ditto.
13542 (supply_register_by_name): Ditto.
13543 (collect_register): Ditto.
13544 (collect_register_as_string): Ditto.
13545 (collect_register_by_name): Ditto.
13546 * server.c (process_serial_event): Adjust.
13547 * linux-low.h (regset_fill_func, regset_store_func): Change
13548 prototype.
13549 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13550 Change prototype.
13551 * linux-low.c (get_stop_pc): Adjust.
13552 (check_removed_breakpoint): Adjust.
13553 (linux_wait_for_event): Adjust.
13554 (linux_resume_one_lwp): Adjust.
13555 (fetch_register): Add regcache parameter. Adjust.
13556 (usr_store_inferior_registers): Ditto.
13557 (regsets_fetch_inferior_registers): Ditto.
13558 (regsets_store_inferior_registers): Ditto.
13559 (linux_fetch_registers, linux_store_registers): Ditto.
13560 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13561 regcache. Adjust.
13562 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13563 Ditto.
13564 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13565 prototype to take a regcache.
13566 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13567 * remote-utils.c (convert_ascii_to_int, outreg)
13568 (prepare_resume_reply): Change prototype to take a regcache.
13569 Adjust.
13570 * target.h (struct target_ops) <fetch_registers, store_registers>:
13571 Change prototype to take a regcache.
13572 (fetch_inferior_registers, store_inferior_registers): Change
13573 prototype to take a regcache. Adjust.
13574 * proc-service.c (ps_lgetregs): Adjust.
13575 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13576 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13577 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13578 take a regcache. Adjust.
13579 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
13580 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
13581 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
13582 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
13583 * linux-cris-low.c (cris_get_pc, cris_set_pc)
13584 (cris_cannot_fetch_register):
13585 (cris_breakpoint_at): Change prototype to take a regcache.
13586 Adjust.
13587 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
13588 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
13589 to take a regcache. Adjust.
13590 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
13591 Adjust.
13592 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
13593 take a regcache. Adjust.
13594 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
13595 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
13596 (m68k_set_pc): Change prototype to take a regcache. Adjust.
13597 * linux-mips-low.c (mips_get_pc):
13598 (mips_set_pc): Change prototype to take a regcache. Adjust.
13599 (mips_reinsert_addr): Adjust.
13600 (mips_collect_register): Change prototype to take a regcache.
13601 Adjust.
13602 (mips_supply_register):
13603 (mips_collect_register_32bit, mips_supply_register_32bit)
13604 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
13605 (mips_store_fpregset): Ditto.
13606 * linux-ppc-low.c (ppc_supply_ptrace_register)
13607 (ppc_supply_ptrace_register): Ditto.
13608 (parse_spufs_run): Adjust.
13609 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
13610 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
13611 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
13612 take a regcache. Adjust.
13613 * linux-s390-low.c (s390_collect_ptrace_register)
13614 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
13615 (s390_set_pc): Change prototype to take a regcache. Adjust.
13616 (s390_arch_setup): Adjust.
13617 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
13618 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
13619 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13620 (sparc_fill_gregset, sparc_store_gregset_from_stack)
13621 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
13622 regcache. Adjust.
13623 (sparc_breakpoint_at): Adjust.
13624 * linux-xtensa-low.c (xtensa_fill_gregset):
13625 (xtensa_store_gregset):
13626 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
13627 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
13628 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
13629 prototype to take a regcache. Adjust.
13630 * win32-arm-low.c (arm_fetch_inferior_register)
13631 (arm_store_inferior_register): Change prototype to take a
13632 regcache. Adjust.
13633 * win32-i386-low.c (i386_fetch_inferior_register)
13634 (i386_store_inferior_register): Change prototype to take a
13635 regcache. Adjust.
13636 * win32-low.c (child_fetch_inferior_registers)
13637 (child_store_inferior_registers): Change prototype to take a
13638 regcache. Adjust.
13639 (win32_wait): Adjust.
13640 (win32_fetch_inferior_registers): Change prototype to take a
13641 regcache. Adjust.
13642 (win32_store_inferior_registers): Adjust.
13643 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
13644 store_inferior_register>: Change prototype to take a regcache.
13645
13646 2010-01-20 Doug Evans <dje@google.com>
13647
13648 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
13649 #ifdef.
13650 (linux_wait_for_event1, linux_init_signals): Ditto.
13651 (W_STOPCODE): Provide definition if missing.
13652
13653 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
13654
13655 * linux-low.c (linux_core_of_thread): New.
13656 (compare_ints, show_process, list_threads): New.
13657 (linux_qxfer_osdata): Report threads and cores.
13658 (linux_target_op): Register linux_core_of_thread.
13659 * remote-utils.c (prepare_resume_reply): Report the core.
13660 (buffer_xml_printf): Support %d specifier.
13661 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
13662 New.
13663 (handle_query): Handle qXfer:threads. Announce availability
13664 thereof.
13665 * target.h (struct target_ops): New field core_of_thread.
13666
13667 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
13668
13669 * Makefile.in (clean): Remove new generated files.
13670 (reg-s390.o, reg-s390.c): Remove rules.
13671 (reg-s390x.o, reg-s390x.c): Likewise.
13672 (s390-linux32.o, s390-linux32.c): Add rules.
13673 (s390-linux64.o, s390-linux64.c): Likewise.
13674 (s390x-linux64.o, s390x-linux64.c): Likewise.
13675 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
13676 * linux-s390-low.c: Include <elf.h>.
13677 (HWCAP_S390_HIGH_GPRS): Define if undefined.
13678 (init_registers_s390): Remove prototype.
13679 (init_registers_s390x): Likewise.
13680 (init_registers_s390_linux32): Add prototype.
13681 (init_registers_s390_linux64): Likewise.
13682 (init_registers_s390x_linux64): Likewise.
13683 (s390_num_regs_3264): New define.
13684 (s390_regmap_3264): New global variable.
13685 (s390_cannot_fetch_register): Remove obsolete check.
13686 (s390_cannot_store_register): Likewise.
13687 (s390_collect_ptrace_register): Handle upper/lower register halves.
13688 (s390_supply_ptrace_register): Likewise.
13689 (s390_fill_gregset): Update to register number changes.
13690 (s390_get_hwcap): New routine.
13691 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
13692 Install appropriate regmap and register set.
13693
13694 2010-01-01 Joel Brobecker <brobecker@adacore.com>
13695
13696 * server.c (gdbserver_version): Update copyright year to 2010.
13697 * gdbreplay.c (gdbreplay_version): Likewise.
13698
13699 2009-12-28 Doug Evans <dje@google.com>
13700
13701 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
13702 elf/external.h. Include <elf.h> instead but only if necessary.
13703
13704 2009-12-28 Pedro Alves <pedro@codesourcery.com>
13705
13706 * linux-low.c (linux_remove_process): Remove `detaching'
13707 parameter. Don't release/detach from thread_db here.
13708 (linux_kill): Release/detach from thread_db here, ...
13709 (linux_detach): ... and here, before actually detaching.
13710 (linux_wait_1): ... and here, when a process exits.
13711 * thread-db.c (any_thread_of): New.
13712 (thread_db_free): Switch the current inferior to a thread of the
13713 passed in process.
13714
13715 2009-12-21 Doug Evans <dje@google.com>
13716
13717 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
13718
13719 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
13720 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
13721 warning ifndef __NR_tkill. Move setting of errno there too.
13722 Delete unnecessary resetting of errno after syscall.
13723 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
13724
13725 * configure.ac: Check for dladdr.
13726 * config.in: Regenerate.
13727 * configure: Regenerate.
13728 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
13729 (try_thread_db_load): Update.
13730
13731 * linux-low.c (my_waitpid): Delete unnecessary prototype.
13732
13733 2009-12-18 Doug Evans <dje@google.com>
13734
13735 * event-loop.c: Include unistd.h if it exists.
13736
13737 * linux-low.c (my_waitpid): Move definition away from being in
13738 between linux_tracefork_child/linux_test_for_tracefork.
13739
13740 * gdb_proc_service.h (psaddr_t): Fix type.
13741 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
13742 signature to match glibc.
13743
13744 2009-12-16 Doug Evans <dje@google.com>
13745
13746 * linux-low.c (linux_read_memory): Fix argument to read.
13747
13748 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13749
13750 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
13751 events, don't leave current_inferior pointing at null.
13752
13753 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13754
13755 * win32-low.c (LOG): Delete.
13756 (OUTMSG): Output to stderr.
13757 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
13758 on compile time LOG macro.
13759 (win32_wait): Fix debug output.
13760
13761 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13762
13763 * win32-low.c (win32_add_one_solib): If the dll name is
13764 "ntdll.dll", prepend the system directory to the dll path.
13765
13766 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
13767
13768 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
13769
13770 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
13771 Vladimir Prus <vladimir@codesourcery.com>
13772
13773 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
13774 * configure.ac: Check for __mcoldfire__ and set
13775 gdb_cv_m68k_is_coldfire.
13776 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
13777 reg-cf.o and reg-m68k.o.
13778 * configure: Regenerated.
13779
13780 2009-11-16 Pedro Alves <pedro@codesourcery.com>
13781
13782 * linux-low.c (linux_remove_process): Add `detaching' parameter.
13783 Pass it to thread_db_free.
13784 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
13785 proper `detaching' argument to linux_remove_process.
13786 * linux-low.h (thread_db_free): Add `detaching' parameter.
13787 * thread-db.c (thread_db_init): Pass false as `detaching' argument
13788 to thread_db_free.
13789 (thread_db_free): Add `detaching' parameter. Only
13790 call td_ta_clear_event if detaching from process.
13791
13792 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
13793
13794 * thread-db.c (thread_db_free): Fix typo.
13795
13796 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
13797
13798 PR gdb/10838
13799 * thread-db.c (thread_db_free): Call td_ta_clear_event.
13800
13801 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
13802
13803 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
13804 with an i686 compiler.
13805 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
13806 needed.
13807 * configure: Rebuilt.
13808
13809 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
13810
13811 PR gdb/10783
13812
13813 * server.c (handle_search_memory_1): Correct read_addr initialization
13814 in loop for searching subsequent chunks.
13815
13816 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
13817
13818 * configure.ac: New --with-libthread-db option.
13819 * thread-db.c: Allow direct dependence on libthread_db.
13820 (thread_db_free): Adjust.
13821 * config.in: Regenerate.
13822 * configure: Likewise.
13823
13824 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
13825
13826 PR gdb/10757
13827 * thread-db.c (attach_thread): New function.
13828 (maybe_attach_thread): Return success/failure.
13829 (find_new_threads_callback): Adjust.
13830 (thread_db_find_new_threads): Loop until no new threads.
13831
13832 2009-10-13 Pedro Alves <pedro@codesourcery.com>
13833
13834 * proc-service.c (ps_lgetregs): Formatting.
13835
13836 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
13837
13838 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
13839 * configure.ac: Adjust.
13840 * linux-low.h (struct process_info_private): Move members to struct
13841 thread_db.
13842 (thread_db_free, thread_db_handle_monitor_command): New prototype.
13843 * linux-low.c (linux_remove_process): Adjust.
13844 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
13845 * server.c (handle_query): Move code ...
13846 (handle_monitor_command): ... here. New function.
13847 * target.h (struct target_ops): New member.
13848 * thread-db.c (struct thread_db): New.
13849 (libthread_db_search_path): New variable.
13850 (thread_db_create_event, thread_db_enable_reporting)
13851 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
13852 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
13853 (try_thread_db_load_1, dladdr_to_soname): New functions.
13854 (try_thread_db_load, thread_db_load_search): New functions.
13855 (thread_db_init): Search for libthread_db.
13856 (thread_db_free): New function.
13857 (thread_db_handle_monitor_command): Likewise.
13858 * config.in: Regenerate.
13859 * configure: Regenerate.
13860
13861 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
13862
13863 * spu-low.c (spu_kill): Wait for inferior to terminate.
13864 Call clear_inferiors.
13865 (spu_detach): Call clear_inferiors.
13866
13867 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13868
13869 * aclocal.m4: Regenerate.
13870 * config.in: Likewise.
13871 * configure: Likewise.
13872
13873 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13874
13875 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
13876 (parse_spufs_run): New function.
13877 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
13878 (ppc_breakpoint_at): Handle SPU breakpoints.
13879
13880 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13881
13882 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
13883 (SPUFS_MAGIC): Define.
13884 (spu_enumerate_spu_ids): New function.
13885 (linux_qxfer_spu): New function.
13886 (linux_target_ops): Install linux_qxfer_spu.
13887
13888 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13889
13890 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
13891 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
13892 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
13893 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
13894 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
13895 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
13896 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
13897 (init_registers_powerpc_cell32l): Add prototype.
13898 (init_registers_powerpc_cell64l): Likewise.
13899 (ppc_arch_setup): Detect Cell/B.E. architecture.
13900
13901 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13902
13903 * Makefile.in (datarootdir): New variable.
13904
13905 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13906
13907 * linux-low.c (linux_write_memory): Update debugging output.
13908 * Makefile.in (clean): Add new descriptions.
13909 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
13910 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
13911 * configure.srv: Add new files for arm*-*-linux*.
13912 * linux-arm-low.c: Add new declarations.
13913 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
13914 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
13915 (HWCAP_VFPv3D16): New.
13916 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
13917 instead of __IWMMXT__.
13918 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
13919 (arm_arch_setup): New.
13920 (target_regsets): Remove #ifdef. Add VFP regset.
13921 (the_low_target): Use arm_arch_setup.
13922
13923 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13924
13925 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
13926 the main thread again.
13927
13928 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
13929
13930 Adding Neutrino gdbserver.
13931 * configure: Regenerated.
13932 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
13933 * configure.srv (i[34567]86-*-nto*): New target.
13934 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
13935 * remote-utils.c [__QNX__]: Include sys/iomgr.h
13936 (nto_comctrl) [__QNX__]: New function.
13937 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
13938
13939 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
13940
13941 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
13942 srv_tgtobj.
13943
13944 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
13945 Pedro Alves <pedro@codesourcery.com>
13946
13947 * win32-i386-low.c (i386_get_thread_context): Handle systems that
13948 don't support CONTEXT_EXTENDED_REGISTERS.
13949 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
13950 (the_low_target): Install them.
13951 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
13952 failing with ERROR_PIPE_NOT_CONNECTED.
13953
13954 2009-06-30 Doug Evans <dje@google.com>
13955 Pierre Muller <muller@ics.u-strasbg.fr>
13956
13957 Add h/w watchpoint support to x86-linux, win32-i386.
13958 * Makefile.in (SFILES): Add i386-low.c
13959 (i386_low_h): Define.
13960 (i386-low.o): Add dependencies.
13961 (linux-x86-low.o): Add i386-low.h dependency.
13962 (win32-i386-low.o): Ditto.
13963 * i386-low.c: New file.
13964 * i386-low.h: New file.
13965 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
13966 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
13967 * linux-low.c (linux_add_process): Initialize arch_private.
13968 (linux_remove_process): Free arch_private.
13969 (add_lwp): Initialize arch_private.
13970 (delete_lwp): Free arch_private.
13971 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
13972 provided.
13973 * linux-low.h (process_info_private): New member arch_private.
13974 (lwp_info): New member arch_private.
13975 (linux_target_ops): New members new_process, new_thread,
13976 prepare_to_resume.
13977 (ptid_of): New macro.
13978 * linux-x86-low.c: Include stddef.h, i386-low.h.
13979 (arch_process_info): New struct.
13980 (arch_lwp_info): New struct.
13981 (x86_linux_dr_get, x86_linux_dr_set): New functions.
13982 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
13983 (i386_dr_low_get_status): New function.
13984 (x86_insert_point, x86_remove_point): New functions.
13985 (x86_stopped_by_watchpoint): New function.
13986 (x86_stopped_data_address): New function.
13987 (x86_linux_new_process, x86_linux_new_thread): New functions.
13988 (x86_linux_prepare_to_resume): New function.
13989 (the_low_target): Add entries for insert_point, remove_point,
13990 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
13991 prepare_to_resume.
13992 * server.c (debug_hw_points): New global.
13993 (monitor_show_help): Document set debug-hw-points.
13994 (handle_query): Process "set debug-hw-points".
13995 * server.h (debug_hw_points): Declare.
13996 (paddress): Declare.
13997 * utils.c (NUMCELLS, CELLSIZE): New macros.
13998 (get_sell, xsnprintf, paddress): New functions.
13999 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14000 remove_point, stopped_by_watchpoint, stopped_data_address.
14001 * win32-i386-low.c: Include i386-low.h.
14002 (debug_reg_state): Replaces dr.
14003 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14004 (i386_dr_low_get_status): New function.
14005 (i386_insert_point, i386_remove_point): New functions.
14006 (i386_stopped_by_watchpoint): New function.
14007 (i386_stopped_data_address): New function.
14008 (i386_initial_stuff): Update.
14009 (get_thread_context,set_thread_context,i386_thread_added): Update.
14010 (the_low_target): Add entries for insert_point,
14011 remove_point, stopped_by_watchpoint, stopped_data_address.
14012 * win32-low.c (win32_insert_watchpoint): New function.
14013 (win32_remove_watchpoint): New function.
14014 (win32_stopped_by_watchpoint): New function.
14015 (win32_stopped_data_address): New function.
14016 (win32_target_ops): Add entries for insert_watchpoint,
14017 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14018 * win32-low.h (win32_target_ops): New members insert_point,
14019 remove_point, stopped_by_watchpoint, stopped_data_address.
14020
14021 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14022
14023 * server.c (process_serial_event): Re-return unsupported, not
14024 error, if the type isn't recognized. Re-allow supporting only
14025 insert or remove packets. Also call require_running for
14026 breakpoints. Add missing break statement to default case. Tidy.
14027 * target.h (struct target_ops): Rename insert_watchpoint to
14028 insert_point, and remove_watchpoint to remove_point.
14029
14030 * linux-low.h (struct linux_target_ops): Likewise.
14031 * linux-low.c (linux_insert_watchpoint): Rename to ...
14032 (linux_insert_point): ... this. Adjust.
14033 (linux_remove_watchpoint): Rename to ...
14034 (linux_remove_point): ... this. Adjust.
14035 (linux_target_ops): Adjust.
14036 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14037 (cris_insert_point): ... this.
14038 (cris_remove_watchpoint): Rename to ...
14039 (cris_remove_point): ... this.
14040 (the_low_target): Adjust.
14041
14042 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14043
14044 * server.c (handle_v_kill): Pass signal_pid to
14045 kill_inferior if multi_process is zero.
14046
14047 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14048
14049 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14050 * target.h (target_ops): Comment for *_watchpoint to make it clear
14051 the functions can get types '0' and '1'.
14052
14053 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14054
14055 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14056 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14057 * regcache.c (get_regcache): Likewise.
14058 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14059 * win32-low.c (child_fetch_inferior_registers): Remove check for
14060 regno 0.
14061
14062 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14063 Pedro Alves <pedro@codesourcery.com>
14064
14065 * target.h (struct target_ops) <supports_multi_process>: New
14066 callback.
14067 (target_supports_multi_process): New.
14068 * server.c (handle_query): Even if GDB reports support, only
14069 enable multi-process if the target also supports it. Report
14070 multi-process support only if the target backend supports it.
14071 * linux-low.c (linux_supports_multi_process): New function.
14072 (linux_target_ops): Install it as target_supports_multi_process
14073 callback.
14074
14075 2009-05-24 Doug Evans <dje@google.com>
14076
14077 Global renaming of find_thread_pid to find_thread_ptid.
14078 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14079 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14080 All callers updated.
14081
14082 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14083 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14084 directly.
14085
14086 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14087 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14088 (linux_resume_one_lwp): Ditto.
14089
14090 2009-05-23 Doug Evans <dje@google.com>
14091
14092 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14093 from struct inferior_list_entry * to struct lwp_info *.
14094 All callers updated.
14095
14096 2009-05-13 Doug Evans <dje@google.com>
14097
14098 * linux-x86-low.c: Don't include assert.h.
14099 (x86_siginfo_fixup): Use fatal, not assert.
14100 (x86_arch_setup): Fix comment.
14101
14102 2009-05-12 Doug Evans <dje@google.com>
14103
14104 Biarch support for i386/amd64 gdbserver.
14105 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14106 Add linux-x86-low.c.
14107 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14108 (linux-x86-low.o): Add.
14109 * linux-x86-64-low.c: Delete.
14110 * linux-i386-low.c: Delete.
14111 * linux-x86-low.c: New file.
14112 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14113 linux-x86-low.o.
14114 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14115 linux-x86-low.o.
14116 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14117 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14118 (linux_child_pid_to_exec_file): New function.
14119 (elf_64_header_p, elf_64_file_p): New functions.
14120 (siginfo_fixup): New function.
14121 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14122 give target a chance to convert layout.
14123 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14124 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14125
14126 2009-05-07 Doug Evans <dje@google.com>
14127
14128 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14129 (regsets_store_inferior_registers): Ditto.
14130
14131 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14132
14133 PR server/10048
14134
14135 * linux-low.c (must_set_ptrace_flags): Delete.
14136 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14137 of the global.
14138 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14139 `lwp->must_set_ptrace_flags' instead.
14140 (linux_wait_for_event_1): Set ptrace options here.
14141 (linux_wait_1): ... not here.
14142
14143 2009-04-30 Doug Evans <dje@google.com>
14144
14145 * inferiors.c (started_inferior_callback): New function.
14146 (attached_inferior_callback): New function.
14147 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14148 * server.c (print_started_pid, print_attached_pid): New functions.
14149 (detach_or_kill_for_exit): New function.
14150 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14151 * server.h (have_started_inferiors_p): Declare.
14152 (have_attached_inferiors_p): Declare.
14153
14154 * inferiors.c (remove_process): Fix memory leak, free process.
14155 * linux-low.c (linux_remove_process): New function.
14156 (linux_kill): Call it instead of remove_process.
14157 (linux_detach, linux_wait_1): Ditto.
14158
14159 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14160
14161 * configure.srv: Add x86 Windows CE target.
14162
14163 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14164
14165 * inferiors.c (get_thread_process): Make global.
14166 * server.h (get_thread_process): Add prototype.
14167 * thread-db.c (find_one_thread): Use get_thread_process
14168 instead of current_process.
14169 (thread_db_get_tls_address): Do not crash if called when
14170 thread layer is not yet initialized.
14171
14172 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14173
14174 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14175 * spu-low.c (current_tid): Rename to ...
14176 (current_ptid): ... this.
14177 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14178 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14179 ptid_get_lwp (current_ptid) instead of current_tid.
14180 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14181 instead of current_tid. Use find_process_pid to verify pid
14182 argument is valid. Pass proper argument to remove_process.
14183 (spu_thread_alive): Compare current_ptid instead of current_tid.
14184 (spu_resume): Likewise.
14185
14186 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14187
14188 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14189 variable.
14190
14191 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14192
14193 Implement the multiprocess extensions, and add linux multiprocess
14194 support.
14195
14196 * server.h (ULONGEST): Declare.
14197 (struct ptid, ptid_t): New.
14198 (minus_one_ptid, null_ptid): Declare.
14199 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14200 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14201 (struct inferior_list_entry): Change `id' type from unsigned from
14202 to ptid_t.
14203 (struct sym_cache, struct breakpoint, struct
14204 process_info_private): Forward declare.
14205 (struct process_info): Declare.
14206 (current_process): Declare.
14207 (all_processes): Declare.
14208 (initialize_inferiors): Declare.
14209 (add_thread): Adjust to use ptid_t.
14210 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14211 (add_process, remove_process, find_thread_pid): Declare.
14212 (find_inferior_id): Adjust to use ptid_t.
14213 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14214 (multi_process): Declare.
14215 (push_event): Adjust to use ptid_t.
14216 (read_ptid, write_ptid): Declare.
14217 (prepare_resume_reply): Adjust to use ptid_t.
14218 (clear_symbol_cache): Declare.
14219 * inferiors.c (all_processes): New.
14220 (null_ptid, minus_one_ptid): New.
14221 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14222 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14223 (add_thread): Change unsigned long to ptid. Remove gdb_id
14224 parameter. Adjust.
14225 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14226 (gdb_id_to_thread): Rename to ...
14227 (find_thread_pid): ... this. Change unsigned long to ptid.
14228 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14229 (loaded_dll, pull_pid_from_list): Adjust.
14230 (add_process, remove_process, find_process_pid)
14231 (get_thread_process, current_process, initialize_inferiors): New.
14232 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14233 (struct target_waitstatus) <related_pid>: Ditto.
14234 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14235 return type to int.
14236 (struct target_ops) <join>: Add `pid' argument.
14237 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14238 (struct target_ops) <wait>: Add `ptid' field. Change return type
14239 to ptid.
14240 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14241 (mywait): Add `ptid' argument. Change return type to ptid_t.
14242 (target_pid_to_str): Declare.
14243 * target.c (set_desired_inferior): Adjust to use ptids.
14244 (mywait): Add new `ptid' argument. Adjust.
14245 (target_pid_to_str): New.
14246 * mem-break.h (free_all_breakpoints): Declare.
14247 * mem-break.c (breakpoints): Delelete.
14248 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14249 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14250 to use per-process breakpoint list.
14251 (free_all_breakpoints): New.
14252 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14253 (symbol_cache, all_symbols_looked_up): Delete.
14254 (hexchars): New.
14255 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14256 read_ptid): New.
14257 (prepare_resume_reply): Change ptid argument's type from unsigned
14258 long to ptid_t. Adjust. Implement W;process and X;process.
14259 (free_sym_cache, clear_symbol_cache): New.
14260 (look_up_one_symbol): Adjust to per-process symbol cache. *
14261 * server.c (cont_thread, general_thread, step_thread): Change type
14262 to ptid_t.
14263 (attached): Delete.
14264 (multi_process): New.
14265 (last_ptid): Change type to ptid_t.
14266 (struct vstop_notif) <ptid>: Change type to ptid_t.
14267 (queue_stop_reply, push_event): Change `ptid' argument's type to
14268 ptid_t.
14269 (discard_queued_stop_replies): Add `pid' argument.
14270 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14271 changes. Don't reference the `attached' global.
14272 (attach_inferior): Adjust to mywait interface changes.
14273 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14274 features. Handle and report "multiprocess+". Handle
14275 "qAttached:PID".
14276 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14277 changes.
14278 (handle_v_kill): New.
14279 (handle_v_stopped): Adjust to use target_pid_to_str.
14280 (handle_v_requests): Allow multiple attaches and runs when
14281 multiprocess extensions are in effect. Handle "vKill".
14282 (myresume): Adjust to use ptids.
14283 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14284 (handle_status): Adjust to discard_queued_stop_replies interface
14285 change.
14286 (first_thread_of, kill_inferior_callback)
14287 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14288 (main): Call initialize_inferiors. Adjust to use ptids, killing
14289 and detaching from all inferiors. Handle multiprocess packet
14290 variants.
14291 * linux-low.h: Include gdb_proc_service.h.
14292 (struct process_info_private): New.
14293 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14294 <lwpid_of>: Use ptid_get_lwp.
14295 (get_lwp_thread): Adjust.
14296 (struct lwp_info): Add `dead' member.
14297 (find_lwp_pid): Declare.
14298 * linux-low.c (thread_db_active): Delete.
14299 (new_inferior): Adjust comment.
14300 (inferior_pid): Delete.
14301 (linux_add_process): New.
14302 (handle_extended_wait): Adjust.
14303 (add_lwp): Change unsigned long to ptid.
14304 (linux_create_inferior): Add process to processes table. Adjust
14305 to use ptids. Don't set new_inferior here.
14306 (linux_attach_lwp): Rename to ...
14307 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14308 it. Adjust to use ptids.
14309 (linux_attach_lwp): New.
14310 (linux_attach): Add process to processes table. Don't set
14311 new_inferior here.
14312 (struct counter): New.
14313 (second_thread_of_pid_p, last_thread_of_process_p): New.
14314 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14315 multiple processes.
14316 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14317 processes. Remove process from process table.
14318 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14319 to multiple processes.
14320 (any_thread_of): New.
14321 (linux_detach): Add `pid' argument, and handle it. Remove process
14322 from processes table.
14323 (linux_join): Add `pid' argument. Handle it.
14324 (linux_thread_alive): Change unsighed long argument to ptid_t.
14325 Consider dead lwps as not being alive.
14326 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14327 threads we're not interested in.
14328 (same_lwp, find_lwp_pid): New.
14329 (linux_wait_for_lwp): Change `pid' argument's type from int to
14330 ptid_t. Adjust.
14331 (linux_wait_for_event): Rename to ...
14332 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14333 from int to ptid_t. Adjust.
14334 (linux_wait_for_event): New.
14335 (linux_wait_1): Add `ptid' argument. Change return type to
14336 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14337 that exit from the process table.
14338 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14339 Adjust.
14340 (mark_lwp_dead): New.
14341 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14342 stopping all threads, mark its main lwp as dead.
14343 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14344 ptids.
14345 (fetch_register, usr_store_inferior_registers)
14346 (regsets_fetch_inferior_registers)
14347 (regsets_store_inferior_registers, linux_read_memory)
14348 (linux_write_memory): Inline `inferior_pid'.
14349 (linux_look_up_symbols): Adjust to use per-process
14350 `thread_db_active'.
14351 (linux_request_interrupt): Adjust to use ptids.
14352 (linux_read_auxv): Inline `inferior_pid'.
14353 (initialize_low): Don't reference thread_db_active.
14354 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14355 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14356 (ps_getpid): Return the pid of the current inferior.
14357 * thread-db.c (proc_handle, thread_agent): Delete.
14358 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14359 per-process data.
14360 (find_one_thread): Change argument type to ptid_t. Adjust to
14361 per-process data.
14362 (maybe_attach_thread): Adjust to per-process data and ptids.
14363 (thread_db_find_new_threads): Ditto.
14364 (thread_db_init): Ditto.
14365 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14366 processes table. Adjust to use ptids.
14367 (spu_kill, spu_detach): Adjust interface. Remove process from
14368 processes table.
14369 (spu_join, spu_thread_alive): Adjust interface.
14370 (spu_wait): Adjust interface. Remove process from processes
14371 table. Adjust to use ptids.
14372 * win32-low.c (current_inferior_tid): Delete.
14373 (current_inferior_ptid): New.
14374 (debug_event_ptid): New.
14375 (thread_rec): Take a ptid. Adjust.
14376 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14377 (child_delete_thread): Ditto.
14378 (do_initial_child_stuff): Add `attached' argument. Add process to
14379 processes table.
14380 (child_fetch_inferior_registers, child_store_inferior_registers):
14381 Adjust.
14382 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14383 (win32_attach): Pass 1 to do_initial_child_stuff.
14384 (win32_kill): Adjust interface. Remove process from processes
14385 table.
14386 (win32_detach): Ditto.
14387 (win32_join): Adjust interface.
14388 (win32_thread_alive): Take a ptid.
14389 (win32_resume): Adjust to use ptids.
14390 (get_child_debug_event): Ditto.
14391 (win32_wait): Adjust interface. Remove exiting process from
14392 processes table.
14393
14394 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14395
14396 Non-stop mode support.
14397
14398 * server.h (non_stop): Declare.
14399 (gdb_client_data, handler_func): Declare.
14400 (delete_file_handler, add_file_handler, start_event_loop):
14401 Declare.
14402 (handle_serial_event, handle_target_event, push_event)
14403 (putpkt_notif): Declare.
14404 * target.h (enum resume_kind): New.
14405 (struct thread_resume): Replace `step' field by `kind' field.
14406 (TARGET_WNOHANG): Define.
14407 (struct target_ops) <wait>: Add `options' argument.
14408 <supports_non_stop, async, start_non_stop>: New fields.
14409 (target_supports_non_stop, target_async): New.
14410 (start_non_stop): Declare.
14411 (mywait): Add `options' argument.
14412 * target.c (mywait): Add `options' argument. Print child exit
14413 notifications here.
14414 (start_non_stop): New.
14415 * server.c (non_stop, own_buf, mem_buf): New globals.
14416 (struct vstop_notif): New.
14417 (notif_queue): New global.
14418 (queue_stop_reply, push_event, discard_queued_stop_replies)
14419 (send_next_stop_reply): New.
14420 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14421 interface changes.
14422 (attach_inferior): In non-stop mode, don't wait for the target
14423 here.
14424 (handle_general_set): Handle QNonStop.
14425 (handle_query): When handling qC, return the current general
14426 thread, instead of the first thread of the list.
14427 (handle_query): If the backend supports non-stop mode, include
14428 QNonStop+ in the qSupported query response.
14429 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14430 and non-stop mode.
14431 (handle_v_attach, handle_v_run): Handle non-stop mode.
14432 (handle_v_stopped): New.
14433 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14434 (myresume): Adjust to use resume_kind. Handle non-stop.
14435 (queue_stop_reply_callback): New.
14436 (handle_status): Handle non-stop mode.
14437 (main): Clear non_stop flag on reconnection. Use the event-loop.
14438 Refactor serial protocol handling from here ...
14439 (process_serial_event): ... to this new function. When GDB
14440 selects any thread, select one here. In non-stop mode, wait until
14441 GDB acks all pending events before exiting.
14442 (handle_serial_event, handle_target_event): New.
14443 * remote-utils.c (remote_open): Install remote_desc in the event
14444 loop.
14445 (remote_close): Remove remote_desc from the event loop.
14446 (putpkt_binary): Rename to...
14447 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14448 (putpkt_binary): New as wrapper around putpkt_binary_1.
14449 (putpkt_notif): New.
14450 (prepare_resume_reply): In non-stop mode, don't change the
14451 general_thread.
14452 * event-loop.c: New.
14453 * Makefile.in (OBJ): Add event-loop.o.
14454 (event-loop.o): New rule.
14455
14456 * linux-low.h (pid_of): Moved here.
14457 (lwpid_of): New.
14458 (get_lwp_thread): Use lwpid_of.
14459 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14460 * linux-low.c (pid_of): Delete.
14461 (inferior_pid): Use lwpid_of.
14462 (linux_event_pipe): New.
14463 (target_is_async_p): New.
14464 (delete_lwp): New.
14465 (handle_extended_wait): Use lwpid_of.
14466 (add_lwp): Don't set lwpid field.
14467 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14468 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14469 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14470 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14471 first. Adjust to linux_wait_for_event interface changes. Use
14472 lwpid_of.
14473 (linux_detach): Don't delete the main lwp here.
14474 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14475 (status_pending_p): Don't consider explicitly suspended lwps.
14476 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14477 pointer. Add OPTIONS argument. Change return type to int. Use
14478 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14479 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14480 pointer. Add status pointer argument. Return a pid instead of a
14481 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14482 changes. In non-stop mode, don't switch to a random thread.
14483 (linux_wait): Rename to...
14484 (linux_wait_1): ... this. Add target_options argument, and handle
14485 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14486 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14487 clean exit and signal exit code. Don't stop all threads in
14488 non-stop mode. In all-stop mode, only stop all threads when
14489 reporting a stop to GDB. Handle explicit thread stop requests.
14490 (async_file_flush, async_file_mark): New.
14491 (linux_wait): New.
14492 (send_sigstop): Use lwpid_of.
14493 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14494 interface changes. In non-stop mode, don't switch to a random
14495 thread.
14496 (linux_resume_one_lwp): Use lwpid_of.
14497 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14498 (linux_resume_one_thread): ... this. Handle resume_stop. In
14499 non-stop mode, don't look for pending flag in all threads.
14500 (resume_status_pending_p): Don't consider explicitly suspended
14501 threads.
14502 (my_waitpid): Reimplement. Emulate __WALL.
14503 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14504 Use lwpid_of.
14505 (sigchld_handler, linux_supports_non_stop, linux_async)
14506 (linux_start_non_stop): New.
14507 (linux_target_ops): Register linux_supports_non_stop, linux_async
14508 and linux_start_non_stop.
14509 (initialize_low): Install SIGCHLD handler.
14510 * thread-db.c (thread_db_create_event, find_one_thread)
14511 (thread_db_get_tls_address): Use lwpid_of.
14512 * win32-low.c (win32_detach): Adjust to use resume_kind.
14513 (win32_wait): Add `options' argument.
14514 * spu-low.c (spu_resume): Adjust to use resume_kind.
14515 (spu_wait): Add `options' argument.
14516
14517 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14518
14519 Decouple target code from remote protocol.
14520
14521 * target.h (enum target_waitkind): New.
14522 (struct target_waitstatus): New.
14523 (struct target_ops) <wait>: Return an unsigned long. Take a
14524 target_waitstatus pointer instead of a char pointer.
14525 (mywait): Likewise.
14526 * target.c (mywait): Change prototype to return an unsigned long.
14527 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14528 * server.h (thread_from_wait, old_thread_from_wait): Delete
14529 declarations.
14530 (prepare_resume_reply): Change prototype to take a
14531 target_waitstatus.
14532 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14533 (last_status, last_ptid): New.
14534 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14535 pid instead of a signal.
14536 (attach_inferior): Remove "status" and "signal" parameters.
14537 Adjust.
14538 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14539 not as an address.
14540 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14541 (handle_v_requests, myresume): Remove "status" and "signal"
14542 parameters. Adjust.
14543 (handle_status): New.
14544 (main): Delete local `status'. Adjust.
14545 * remote-utils.c: Include target.h.
14546 (prepare_resume_reply): Change prototype to take a
14547 target_waitstatus. Adjust.
14548
14549 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14550 interface.
14551 * spu-low.c (spu_wait): Adjust.
14552 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14553 Delete.
14554 (win32_wait): Adjust.
14555
14556 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14557
14558 * target.h (struct thread_resume): Delete leave_stopped member.
14559 (struct target_ops): Add a `n' argument to the `resume' callback.
14560 * server.c (start_inferior): Adjust.
14561 (handle_v_cont, myresume): Adjust.
14562 * linux-low.c (check_removed_breakpoint): Adjust to resume
14563 interface change, and to removed leave_stopped field.
14564 (resume_ptr): Delete.
14565 (struct thread_resume_array): New.
14566 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14567 resume interface change.
14568 (linux_continue_one_thread, linux_queue_one_thread)
14569 (resume_status_pending_p): Check if the resume field is NULL
14570 instead of checking the leave_stopped member.
14571 (linux_resume): Adjust to the target resume interface change.
14572 * spu-low.c (spu_resume): Adjust to the target resume interface
14573 change.
14574 * win32-low.c (win32_detach, win32_resume): Ditto.
14575
14576 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14577
14578 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
14579 flag.
14580 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
14581 pending.
14582 (linux_continue_one_thread): Only preserve the stepping flag if
14583 there's a pending breakpoint.
14584
14585 2009-03-31 Pedro Alves <pedro@codesourcery.com>
14586
14587 * server.c (main): After the inferior having exited, call
14588 remote_close before exiting gdbserver.
14589
14590 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
14591
14592 Fix size of FPSCR in Power 7 processors.
14593 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
14594 (PPC_FEATURE_HAS_DFP): New #define.
14595 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
14596 size of the FPSCR.
14597
14598 2009-03-23 Pedro Alves <pedro@codesourcery.com>
14599
14600 * server.c (handle_query) Whitespace and formatting.
14601
14602 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14603
14604 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
14605 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
14606 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
14607 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
14608 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
14609 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
14610 Makefile.in, configure.ac: Fix whitespace throughout.
14611 * configure: Regenerate.
14612
14613 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14614
14615 * inferiors.c (find_inferior): Make it safe for the callback
14616 function to delete the currently iterated inferior.
14617
14618 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14619
14620 * Makefile.in (linuw_low_h): Move higher.
14621 (thread-db.o): Depend on $(linux_low_h).
14622
14623 2009-03-17 Pedro Alves <pedro@codesourcery.com>
14624
14625 Rename "process" to "lwp" throughout.
14626
14627 * linux-low.c (all_processes): Rename to...
14628 (all_lwps): ... this.
14629 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
14630 (add_process): Rename to ...
14631 (add_lwp): ... this. Adjust.
14632 (linux_create_inferior): Adjust.
14633 (linux_attach_lwp): Adjust.
14634 (linux_attach): Adjust.
14635 (linux_kill_one_process): Rename to ...
14636 (linux_kill_one_lwp): ... this. Adjust.
14637 (linux_kill): Adjust.
14638 (linux_detach_one_process): Rename to ...
14639 (linux_detach_one_lwp): ... this. Adjust.
14640 (linux_detach): Adjust.
14641 (check_removed_breakpoint): Adjust.
14642 (status_pending_p): Adjust.
14643 (linux_wait_for_process): Rename to ...
14644 (linux_wait_for_lwp): ... this. Adjust.
14645 (linux_wait_for_event): Adjust.
14646 (send_sigstop): Adjust.
14647 (wait_for_sigstop): Adjust.
14648 (stop_all_processes): Rename to ...
14649 (stop_all_lwps): ... this.
14650 (linux_resume_one_process): Rename to ...
14651 (linux_resume_one_lwp): ... this. Adjust.
14652 (linux_set_resume_request, linux_continue_one_thread)
14653 (linux_queue_one_thread, resume_status_pending_p)
14654 (usr_store_inferior_registers, regsets_store_inferior_registers)
14655 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14656 Adjust.
14657 * linux-low.h (get_process): Rename to ...
14658 (get_lwp): ... this. Adjust.
14659 (get_thread_process): Rename to ...
14660 (get_thread_lwp): ... this. Adjust.
14661 (get_process_thread): Rename to ...
14662 (get_lwp_thread): ... this. Adjust.
14663 (struct process_info): Rename to ...
14664 (struct lwp_info): ... this.
14665 (all_processes): Rename to ...
14666 (all_lwps): ... this.
14667 * proc-service.c (ps_lgetregs): Adjust.
14668 * thread-db.c (thread_db_create_event, find_one_thread)
14669 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
14670
14671 2009-03-14 Pedro Alves <pedro@codesourcery.com>
14672
14673 * server.c (handle_query): Handle "qAttached".
14674
14675 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
14676
14677 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
14678 GPLv3, update license URL.
14679
14680 2009-03-01 Doug Evans <dje@google.com>
14681
14682 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
14683 (server_h): Add gdb_signals.h.
14684 (signals.o): Update.
14685 * server.h (target_signal_from_host,target_signal_to_host_p)
14686 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
14687
14688 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
14689
14690 * remote-utils.c (getpkt): Also generate remote-debug
14691 information if noack_mode is set.
14692
14693 2009-02-06 Pedro Alves <pedro@codesourcery.com>
14694
14695 * server.c (handle_query): Report qXfer:siginfo:read and
14696 qXfer:siginfo:write as supported and handle them.
14697 * target.h (struct target_ops) <qxfer_siginfo>: New field.
14698 * linux-low.c (linux_xfer_siginfo): New.
14699 (linux_target_ops): Set it.
14700
14701 2009-01-26 Pedro Alves <pedro@codesourcery.com>
14702
14703 * server.c (gdbserver_usage): Mention --remote-debug.
14704 (main): Accept '--remote-debug' switch.
14705
14706 2009-01-18 Doug Evans <dje@google.com>
14707
14708 * regcache.c (new_register_cache): No need to check result of xcalloc.
14709 * server.c (handle_search_memory): Back out calls to xmalloc,
14710 result is checked and error is returned to user upon failure.
14711 (handle_query): Ditto. Add more checks for result of malloc.
14712 (handle_v_cont): Check result of malloc, report error back to
14713 user upon failure.
14714 (handle_v_run): Ditto. Call freeargv.
14715 * server.h (freeargv): Declare.
14716 * utils.c (freeargv): New fn.
14717
14718 2009-01-15 Doug Evans <dje@google.com>
14719
14720 * gdbreplay.c (perror_with_name): Make arg const char *.
14721 * server.h (target_signal_to_name): Make return type const char *.
14722 * thread-db.c (thread_db_err_str): Make return type const char *.
14723 * utils.c (perror_with_name): Make arg const char *.
14724
14725 2009-01-14 Pedro Alves <pedro@codesourcery.com>
14726
14727 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
14728 when handling a EXIT_PROCESS_DEBUG_EVENT.
14729
14730 2009-01-06 Joel Brobecker <brobecker@adacore.com>
14731
14732 * gdbreplay.c (gdbreplay_version): Update copyright year.
14733 * server.c (gdbserver_version): Likewise.
14734
14735 2009-01-05 Doug Evans <dje@google.com>
14736
14737 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
14738 (handle_extended_wait): Improve comment.
14739
14740 2008-12-13 Doug Evans <dje@google.com>
14741
14742 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
14743 * server.h (ATTR_MALLOC): New macro.
14744 (xmalloc,xcalloc,xstrdup): Declare.
14745 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
14746 * inferiors.c: Ditto.
14747 * linux-low.c: Ditto.
14748 * mem-break.c: Ditto.
14749 * regcache.c: Ditto.
14750 * remote-utils.c: Ditto.
14751 * server.c: Ditto.
14752 * target.c: Ditto.
14753 * win32-low.c: Ditto.
14754
14755 2008-12-12 Doug Evans <dje@google.com>
14756
14757 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
14758 in debugging printf.
14759
14760 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
14761
14762 2008-12-09 Doug Evans <dje@google.com>
14763
14764 * linux-low.h (struct process_info): Delete member tid, unused.
14765 * thread-db.c (find_one_thread): Update.
14766 (maybe_attach_thread): Update.
14767
14768 2008-12-02 Pedro Alves <pedro@codesourcery.com>
14769
14770 * target.h (struct target_ops): Add qxfer_osdata member.
14771 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
14772 and dirent.h.
14773 (linux_qxfer_osdata): New functions.
14774 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
14775 callback.
14776 * server.c (handle_query): Handle "qXfer:osdata:read:".
14777 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
14778 (buffer_xml_printf): New functions.
14779 * server.h (struct buffer): New.
14780 (buffer_grow_str, buffer_grow_str0): New macros.
14781 (buffer_grow, buffer_free, buffer_init, buffer_finish)
14782 (buffer_xml_printf): Declare.
14783
14784 2008-11-24 Doug Evans <dje@google.com>
14785
14786 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
14787
14788 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
14789
14790 * server.c (handle_v_run): Always use the supplied argument list.
14791
14792 2008-11-19 Bob Wilson <bob.wilson@acm.org>
14793
14794 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
14795 (xtensa_regmap_table): Add entry for scompare1.
14796
14797 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
14798
14799 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
14800 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
14801 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
14802 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
14803 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
14804 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
14805 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
14806 XML target descriptions.
14807 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
14808 when inferior is running on an ISA 2.05 or later processor. Add
14809 special case to return offset for full 64-bit slot of FPSCR when
14810 in 32-bits.
14811
14812 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
14813
14814 * Makefile.in (SFILES, clean): Added sparc64 files.
14815 (reg-sparc64.o, reg-sparc64.c): New.
14816 * configure.srv (sparc*-*-linux*): New configuration.
14817 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
14818 syscall arguments for SPARC.
14819 (regsets_store_inferior_registers): Likewise.
14820 * linux-sparc-low.c: New file.
14821
14822 2008-10-21 Doug Evans <dje@google.com>
14823
14824 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
14825 (READLINE_DIR,READLINE_DEP): Delete.
14826 (INTERNAL_CFLAGS): Update.
14827 (LINTFLAGS): Update.
14828
14829 2008-10-10 Pedro Alves <pedro@codesourcery.com>
14830
14831 * server.c (handle_v_run): If GDB didn't specify an argv, use the
14832 whole argv from the last run, not just argv[0].
14833
14834 2008-09-08 Pedro Alves <pedro@codesourcery.com>
14835
14836 * regcache.c (new_register_cache): Return NULL if the register
14837 cache size isn't known yet.
14838 (free_register_cache): Avoid dereferencing a NULL regcache.
14839
14840 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
14841
14842 * configure.srv: Merge MIPS and MIPS64.
14843
14844 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
14845
14846 * Makefile.in (uninstall): Apply $(EXEEXT) too.
14847
14848 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
14849
14850 * Makefile.in: Add required vsx dependencies.
14851
14852 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
14853 Declare init_registers_powerpc_vsx32l.
14854 Declare init_registers_powerpc_vsx64l.
14855 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
14856 (ppc_arch_setup): Check for VSX in hwcap.
14857 (ppc_fill_vsxregset): New function.
14858 (ppc_store_vsxregset): New function.
14859 Add new VSX entry in regset_info target_regsets.
14860
14861 * configure.srv: Add new VSX dependencies.
14862
14863 2008-08-12 Pedro Alves <pedro@codesourcery.com>
14864
14865 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
14866 (remote_open): Set or clear transport_is_reliable.
14867 (putpkt_binary): Don't expect acks in noack mode.
14868 (getpkt): Don't send ack/nac in noack mode.
14869 * server.c (handle_general_set): Handle QStartNoAckMode.
14870 (handle_query): If connected by tcp pass QStartNoAckMode+ in
14871 qSupported.
14872 (main): Reset noack_mode on every connection.
14873 * server.h (noack_mode): Declare.
14874
14875 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14876
14877 * Makefile.in (GDBREPLAY_OBS): New variable.
14878 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
14879
14880 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
14881 Daniel Jacobowitz <dan@codesourcery.com>
14882
14883 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
14884 (usr_store_inferior_registers): Likewise.
14885 (regsets_store_inferior_registers): Likewise.
14886
14887 2008-07-31 Rolf Jansen <rj@surtec.com>
14888 Pedro Alves <pedro@codesourcery.com>
14889
14890 * configure.ac: Check for memmem declaration.
14891 * server.c [HAVE_MALLOC_H]: Include malloc.h.
14892 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
14893 (disable_packet_qfThreadInfo): Unconditionally compile.
14894 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
14895 * configure, config.in: Regenerate.
14896
14897 2008-07-28 Doug Kwan <dougkwan@google.com>
14898
14899 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
14900 (linux_write_memory): Remove declaration of errno.
14901
14902 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
14903
14904 * linux-low.c (handle_extended_wait): Do not use "status"
14905 variable uninitialized.
14906
14907 2008-07-07 Pedro Alves <pedro@codesourcery.com>
14908
14909 * server.c (handle_v_attach): Inhibit reporting dll changes.
14910
14911 2008-06-27 Pedro Alves <pedro@codesourcery.com>
14912
14913 * remote-utils.c (prepare_resume_reply): If requested, don't
14914 output "thread:TID" in the T stop reply.
14915
14916 * server.c (disable_packet_vCont, disable_packet_Tthread)
14917 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
14918 (handle_query): If requested, disable support for qC, qfThreadInfo
14919 and qsThreadInfo.
14920 (handle_v_requests): If requested, disable support for vCont.
14921 (gdbserver_show_disableable): New.
14922 (main): Handle --disable-packet and --disable-packet=LIST.
14923
14924 * server.h (disable_packet_vCont, disable_packet_Tthread)
14925 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
14926
14927 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
14928
14929 * server.c (gdbserver_usage): Mention --version.
14930
14931 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
14932
14933 * Makefile.in (gdbreplay.o): New rule.
14934
14935 2008-06-06 Joseph Myers <joseph@codesourcery.com>
14936
14937 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
14938 message, not gdbserver.
14939
14940 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
14941 Nathan Sidwell <nathan@codesourcery.com>
14942 Joseph Myers <joseph@codesourcery.com>
14943
14944 * acinclude.m4: Include ../../config/acx.m4.
14945 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
14946 * configure, config.in: Regenerate.
14947 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
14948 * server.c (gdbserver_version): Print PKGVERSION.
14949 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
14950 (main): Adjust gdbserver_usage calls.
14951 * gdbreplay.c (version, host_name): Add declarations.
14952 (gdbreplay_version, gdbreplay_usage): New.
14953 (main): Accept --version and --help options.
14954
14955 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
14956
14957 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
14958 (arm_breakpoint_at): Handle Thumb.
14959 (the_low_target): Add comment.
14960
14961 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
14962
14963 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
14964
14965 2008-05-09 Doug Evans <dje@google.com>
14966
14967 * server.h (decode_search_memory_packet): Declare.
14968 * remote-utils.c (decode_search_memory_packet): New fn.
14969 * server.c (handle_search_memory_1): New fn.
14970 (handle_search_memory): New fn.
14971 (handle_query): Process qSearch:memory packets.
14972
14973 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
14974
14975 * regcache.c (registers_length): Remove.
14976 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
14977 full register packet.
14978 * regcache.h (registers_length): Remove prototype.
14979 * server.h (PBUFSIZ): Define to 16384.
14980
14981 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
14982
14983 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
14984 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
14985 powerpc-64l.o, and powerpc-altivec64l.o.
14986 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
14987 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
14988 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
14989 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
14990 rs6000/power-linux.xml, and rs6000/power64-linux.xml
14991 to srv_xmlfiles.
14992
14993 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
14994 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
14995 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
14996 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
14997 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
14998 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
14999 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15000 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15001 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15002 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15003 (clean): Update.
15004
15005 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15006 (init_registers_powerpc_32l): ... this new prototype.
15007 (init_registers_powerpc_32): Remove, replace by ...
15008 (init_registers_powerpc_altivec32l): ... this new prototype.
15009 (init_registers_powerpc_e500): Remove, replace by ...
15010 (init_registers_powerpc_e500l): ... this new prototype.
15011 (init_registers_ppc64): Remove, replace by ...
15012 (init_registers_powerpc_64l): ... this new prototype.
15013 (init_registers_powerpc_64): Remove, replace by ...
15014 (init_registers_powerpc_altivec64l): ... this new prototype.
15015 (ppc_num_regs): Set to 73.
15016 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15017 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15018 (ppc_cannot_store_register): Handle orig_r3 and trap.
15019 (ppc_arch_setup): Update init_registers_... calls.
15020 (ppc_fill_gregset): Handle orig_r3 and trap.
15021
15022 * inferiors.c (clear_inferiors): Reset current_inferior.
15023
15024 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15025
15026 * acinclude.m4: Add override.m4.
15027 * configure: Regenerate.
15028
15029 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15030
15031 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15032 initial call to init_register_ppc64.
15033
15034 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15035
15036 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15037 single powerpc*-*-linux* case.
15038 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15039
15040 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15041
15042 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15043 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15044 from reg_xmlfiles.
15045 * linux-ppc-low.c: Include <elf.h>.
15046 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15047 (ppc_hwcap): New global variable.
15048 (ppc_regmap): Remove __SPE__ #ifdef sections.
15049 (ppc_regmap_e500): New global variable.
15050 (ppc_cannot_store_register): Update __SPE__ special case.
15051 (ppc_get_hwcap): New function.
15052 (ppc_arch_setup): Use it to determine whether inferior supports
15053 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15054 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15055 Do not access registers if target does not support AltiVec.
15056 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15057 Do not access registers if target does not support SPE.
15058 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15059
15060 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15061
15062 * linux-low.c (disabled_regsets, num_regsets): New.
15063 (use_regsets_p): Delete.
15064 (linux_wait_for_process): Clear disabled_regsets.
15065 (regsets_fetch_inferior_registers): Check and set it.
15066 (regsets_store_inferior_registers): Likewise.
15067 (linux_fetch_registers, linux_store_registers): Do not use
15068 use_regsets_p.
15069 (initialize_low): Allocate disabled_regsets.
15070
15071 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15072
15073 * Makefile.in (LIBOBJS): New.
15074 (OBS): Use LIBOBJS.
15075 (memmem.o): New rule.
15076 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15077 * configure: Regenerated.
15078
15079 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15080
15081 * server.c (handle_query): Never return "unsupported" for
15082 qXfer:features:read queries.
15083
15084 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15085
15086 * server.c (get_features_xml): Fix inverted condition.
15087 (handle_query): Always support qXfer:feature:read.
15088
15089 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15090
15091 * server.c (wrapper_argv): New.
15092 (start_inferior): Handle wrapper_argv. If set, expect an extra
15093 trap.
15094 (gdbserver_usage): Document --wrapper.
15095 (main): Parse --wrapper.
15096
15097 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15098
15099 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15100 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15101 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15102 (ppc_set_pc): Likewise.
15103 (ppc_arch_setup): New function.
15104 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15105 of collect_register.
15106 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15107
15108 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15109
15110 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15111 instead of linux-ppc64-low.o.
15112 * linux-ppc64-low.c: Remove file.
15113 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15114 (linux-ppc64-low.o): Remove rule.
15115
15116 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15117 (init_registers_powerpc_64): Likewise.
15118 (ppc_regmap): Conditionally define depending on __powerpc64__.
15119 (ppc_cannot_store_register): Do not special-case "fpscr" when
15120 compiled on __powerpc64__.
15121 (ppc_collect_ptrace_register): New function.
15122 (ppc_supply_ptrace_register): New function.
15123 (ppc_breakpoint): Change type to "unsigned int".
15124 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15125 (the_low_target): Conditionally provide initializers for the
15126 arch_setup member depending on __powerpc64__. Install
15127 collect_ptrace_register and supply_ptrace_register members.
15128
15129 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15130
15131 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15132 * server.c (gdbserver_xmltarget): Define.
15133 (get_features_xml): Use it to replace "target.xml" and arch_string.
15134
15135 * configure.srv: Remove srv_xmltarget. Add XML files that were
15136 mentioned there to srv_xmlfiles instead. Remove conditional tests
15137 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15138 srv_xmlfiles and srv_regobj to include all possible choices.
15139 * configure.ac (srv_xmltarget): Remove.
15140 (srv_xmlfiles): Do not add "target.xml".
15141 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15142 checks for supplementary target information.
15143 * configure: Regenerate.
15144 * Makefile.in (XML_TARGET): Remove.
15145 (target.xml): Remove rule.
15146 (clean): Do not clean up target.xml.
15147 (.PRECIOUS): Do not mention target.xml.
15148
15149 * target.h (struct target_ops): Remove arch_string member.
15150 * linux-low.c (linux_arch_string): Remove.
15151 (linux_target_ops): Remove arch_string initializer.
15152 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15153 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15154 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15155 * spu-low.c (spu_arch_string): Remove.
15156 (spu_target_ops): Remove arch_string initializer.
15157 * win32-low.c (win32_arch_string): Remove.
15158 (win32_target_ops): Remove arch_string initializer.
15159 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15160 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15161 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15162
15163 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15164
15165 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15166 by collect_ptrace_register and supply_ptrace_register hooks.
15167 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15168 instead of checking for the_low_target.left_pad_xfer.
15169 (usr_store_inferior_registers): Use collect_ptrace_register callback
15170 instead of checking for the_low_target.left_pad_xfer.
15171
15172 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15173 (s390_supply_ptrace_register): Likewise.
15174 (s390_fill_gregset): Call s390_collect_ptrace_register.
15175 (the_low_target): Update.
15176
15177 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15178 (ppc_supply_ptrace_register): Likewise.
15179 (the_low_target): Update.
15180
15181 * linux-i386-low.c (the_low_target): Update.
15182 * linux-x86-64-low.c (the_low_target): Update.
15183
15184 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15185
15186 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15187 reg-s390.o and reg-s390x.o.
15188
15189 * linux-low.c (new_inferior): New global variable.
15190 (linux_create_inferior, linux_attach): Set it.
15191 (linux_wait_for_process): Call the_low_target.arch_setup after the
15192 target has stopped for the first time.
15193 (initialize_low): Do not call the_low_target.arch_setup.
15194
15195 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15196 (s390_set_pc): Likewise.
15197 (s390_arch_setup): New function.
15198 (the_low_target): Use s390_arch_setup as arch_setup routine.
15199
15200 * regcache.c (realloc_register_cache): New function.
15201 (set_register_cache): Call it for each existing regcache.
15202
15203 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15204
15205 * server.h (init_registers): Remove prototype.
15206
15207 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15208 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15209 instead of init_registers ().
15210 * linux-arm-low.c (init_registers_arm): Add prototype.
15211 (init_registers_arm_with_iwmmxt): Likewise.
15212 (the_low_target): Add initializer for arch_setup field.
15213 * linux-cris-low.c (init_registers_cris): Add prototype.
15214 (the_low_target): Add initializer for arch_setup field.
15215 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15216 (the_low_target): Add initializer for arch_setup field.
15217 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15218 (the_low_target): Add initializer for arch_setup field.
15219 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15220 (the_low_target): Add initializer for arch_setup field.
15221 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15222 (the_low_target): Add initializer for arch_setup field.
15223 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15224 (the_low_target): Add initializer for arch_setup field.
15225 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15226 (init_registers_mips64_linux): Likewise.
15227 (the_low_target): Add initializer for arch_setup field.
15228 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15229 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15230 (the_low_target): Add initializer for arch_setup field.
15231 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15232 (init_registers_powerpc_64): Likewise.
15233 (the_low_target): Add initializer for arch_setup field.
15234 * linux-s390-low.c (init_registers_s390): Add prototype.
15235 (init_registers_s390x): Likewise.
15236 (the_low_target): Add initializer for arch_setup field.
15237 * linux-sh-low.c (init_registers_sh): Add prototype.
15238 (the_low_target): Add initializer for arch_setup field.
15239 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15240 (the_low_target): Add initializer for arch_setup field.
15241 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15242 (the_low_target): Add initializer for arch_setup field.
15243
15244 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15245 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15246 instead of init_registers ().
15247 * win32-arm-low.c (init_registers_arm): Add prototype.
15248 (the_low_target): Add initializer for arch_setup field.
15249 * win32-i386-low.c (init_registers_i386): Add prototype.
15250 (the_low_target): Add initializer for arch_setup field.
15251
15252 * spu-low.c (init_registers_spu): Add prototype.
15253 (initialize_low): Call initialie_registers_spu () instead of
15254 initialize_registers ().
15255
15256 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15257
15258 * server.c (handle_v_requests): When handling the vRun and vAttach
15259 packets, if already debugging a process, don't kill it. Return an
15260 error instead.
15261
15262 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15263
15264 * server.c (handle_query): Correct length check.
15265
15266 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15267
15268 * win32-low.c (do_initial_child_stuff): Add process handle
15269 parameter. Set current_process_handle and current_process_id from the
15270 parameters. Clear globals.
15271 (win32_create_inferior): Don't set current_process_handle and
15272 current_process_id here. Instead pass them on the call to
15273 do_initial_child_stuff.
15274 (win32_attach): Likewise.
15275 (win32_clear_inferiors): New.
15276 (win32_kill): Don't close the current process handle or the
15277 current thread handle here. Instead call win32_clear_inferiors.
15278 (win32_detach): Don't open a new handle to the process. Call
15279 win32_clear_inferiors.
15280 (win32_join): Don't rely on current_process_handle; open a new
15281 handle using the process id.
15282 (win32_wait): Call win32_clear_inferiors when the inferior process
15283 has exited.
15284
15285 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15286
15287 * server.c (monitor_show_help): Add "exit".
15288
15289 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15290
15291 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15292 (clean): Add reg-xtensa.c.
15293 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15294 * configure.srv (xtensa*-*-linux*) New target.
15295 * linux-xtensa-low.c: New.
15296 * xtensa-xtregs.c: New.
15297
15298 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15299
15300 * hostio.c: Don't include errno.h.
15301 (errno_to_fileio_errno): Move to hostio-errno.
15302 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15303 error number outputting to the target->hostio_last_error callback.
15304 (hostio_packet_error): Use FILEIO_EINVAL directly.
15305 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15306 calls to hostio_error.
15307 * hostio-errno.c: New.
15308 * server.h (hostio_last_error_from_errno): Declare.
15309 * target.h (target_ops): Add hostio_last_error member.
15310 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15311 as hostio_last_error handler.
15312 * spu-low.c (spu_target_ops): Likewise.
15313 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15314 (wince_hostio_last_error): New functions.
15315 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15316 as hostio_last_error handler.
15317 (win32_target_ops) [!_WIN32_WCE]: Register
15318 hostio_last_error_from_errno as hostio_last_error handler.
15319 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15320 (hostio-errno.o): New rule.
15321 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15322 * configure.srv (srv_hostio_err_objs): New variable. Default to
15323 hostio-errno.o.
15324 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15325 * configure: Regenerate.
15326
15327 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15328
15329 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15330 (linux_kill, linux_detach): Clean up the process list.
15331 * remote-utils.c (remote_open): Improve port number parsing.
15332 (putpkt_binary, input_interrupt): Only send interrupts if the target
15333 is running.
15334 * server.c (extended_protocol): Make static.
15335 (attached): Define earlier.
15336 (exit_requested, response_needed, program_argv): New variables.
15337 (target_running): New.
15338 (start_inferior): Clear attached here.
15339 (attach_inferior): Set attached here.
15340 (require_running): Define.
15341 (handle_query): Use require_running and target_running. Implement
15342 "monitor exit".
15343 (handle_v_attach, handle_v_run): New.
15344 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15345 (gdbserver_usage): Update.
15346 (main): Redo argument parsing. Handle --debug and --multi. Handle
15347 --attach along with other options or after the port. Save
15348 program_argv. Support no initial program. Resynchronize
15349 communication with GDB after an error. Handle "monitor exit".
15350 Use require_running and target_running. Always allow the extended
15351 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15352 restart in extended mode.
15353 * README: Refer to the GDB manual. Update --attach usage.
15354
15355 2007-12-20 Andreas Schwab <schwab@suse.de>
15356
15357 * linux-low.c (STACK_SIZE): Define.
15358 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15359 (linux_test_for_tracefork): Likewise.
15360
15361 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15362
15363 * linux-low.c (linux_wait_for_event): Update messages. Do not
15364 reinsert auto-delete breakpoints.
15365 * mem-break.c (struct breakpoint): Change return type of handler to
15366 int.
15367 (set_breakpoint_at): Update handler type.
15368 (reinsert_breakpoint_handler): Return 1 instead of calling
15369 delete_breakpoint.
15370 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15371 setting a new one.
15372 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15373 * mem-break.h (set_breakpoint_at): Update handler type.
15374 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15375 * win32-low.c (auto_delete_breakpoint): New.
15376 (get_child_debug_event): Use it.
15377
15378 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15379
15380 * configure.ac: Check for pread and pwrite.
15381 * hostio.c (handle_pread): Fall back to lseek and read.
15382 (handle_pwrite): Fall back to lseek and write.
15383 * config.in, configure: Regenerated.
15384
15385 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15386
15387 * server.c (myresume): Add own_buf argument.
15388 (main): Update calls.
15389
15390 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15391
15392 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15393 * remote-utils.c (remote_open): Do not call disable_async_io.
15394 (block_async_io): Delete.
15395 (unblock_async_io): Make static.
15396 (initialize_async_io): New.
15397 * server.c (handle_v_cont): Handle async I/O here.
15398 (myresume): Likewise. Move other common resume tasks here...
15399 (main): ... from here. Call initialize_async_io. Disable async
15400 I/O before the main loop.
15401 * server.h (initialize_async_io): Declare.
15402 (block_async_io, unblock_async_io): Delete prototypes.
15403 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15404
15405 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15406
15407 * remote-utils.c (readchar): Allow binary data in received messages.
15408
15409 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15410
15411 * win32-low.c (attaching): New global.
15412 (win32_create_inferior): Clear the `attaching' global.
15413 (win32_attach): Set the `attaching' global.
15414 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15415 attaching. Only set a breakpoint at the entry point if not
15416 attaching.
15417
15418 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15419
15420 * server.c (main): Don't report dll events on the initial
15421 connection on attaches.
15422
15423 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15424
15425 * server.c (main): Relax numerical bases supported for the pid of
15426 the --attach command line argument.
15427
15428 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15429
15430 * win32-low.c (win32_attach): Call OpenProcess before
15431 DebugActiveProcess, not after. Add last error output to error
15432 call.
15433
15434 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15435
15436 * win32-low.c (win32_get_thread_context)
15437 (win32_set_thread_context): New functions.
15438 (thread_rec): Use win32_get_thread_context.
15439 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15440 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15441 field.
15442
15443 2007-12-03 Leo Zayas
15444 Pedro Alves <pedro_alves@portugalmail.pt>
15445
15446 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15447 global variables.
15448 (child_add_thread): Minor cleanup.
15449 (child_continue): Resume artificially suspended threads before
15450 calling ContinueDebugEvent.
15451 (suspend_one_thread): New.
15452 (fake_breakpoint_event): New.
15453 (get_child_debug_event): Change return type to int. Check here if
15454 gdb sent an interrupt request. If a soft interrupt was requested,
15455 fake a breakpoint event. Return 0 if there is no event to handle,
15456 and 1 otherwise.
15457 (win32_wait): Don't check here if gdb sent an interrupt request.
15458 Ensure there is a valid event to handle.
15459 (win32_request_interrupt): Add soft interruption method as last
15460 resort.
15461
15462 2007-12-03 Leo Zayas
15463 Pedro Alves <pedro_alves@portugalmail.pt>
15464
15465 * win32-low.h (win32_thread_info): Add descriptions to the
15466 structure members. Replace `suspend_count' counter by a
15467 `suspended' flag.
15468 * win32-low.c (thread_rec): Update condition of when to get the
15469 context from the inferior. Rely on ContextFlags being set if it
15470 has already been retrieved. Only suspend the inferior thread if
15471 we haven't already. Warn if that fails.
15472 (continue_one_thread): s/suspend_count/suspended/. Only call
15473 ResumeThread once. Warn if that fails.
15474
15475 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15476
15477 * win32-low.c (win32_wait): Don't read from the inferior when it
15478 has already exited.
15479
15480 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15481
15482 * Makefile.in (win32_low_h): New variable.
15483 (win32-low.o): Add dependency on $(win32_low_h).
15484 (win32-arm-low.o, win32-i386-low.o): New rules.
15485
15486 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15487
15488 * hostio.c: Correct copyright year.
15489
15490 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15491
15492 * Makefile.in (OBS): Add hostio.o.
15493 (hostio.o): New rule.
15494 * server.h (handle_vFile): Declare.
15495 * hostio.c: New file.
15496 * server.c (handle_v_requests): Take packet_len and new_packet_len
15497 for binary packets. Call handle_vFile.
15498 (main): Update call to handle_v_requests.
15499
15500 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15501
15502 * linux-low.c: Include <sched.h>.
15503
15504 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15505
15506 * linux-low.c (linux_tracefork_grandchild): New.
15507 (linux_tracefork_child): Use clone.
15508 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15509
15510 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15511
15512 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15513
15514 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15515
15516 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15517
15518 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15519
15520 * inferiors.c (change_inferior_id): Delete.
15521 (add_pid_to_list, pull_pid_from_list): New.
15522 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15523 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15524 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15525 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15526 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15527 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15528 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15529 (using_threads): Always set to 1.
15530 (handle_extended_wait): New.
15531 (add_process): Do not set TID.
15532 (linux_create_inferior): Set must_set_ptrace_flags.
15533 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15534 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15535 (linux_thread_alive): Rename TID argument to LWPID.
15536 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15537 (linux_wait_for_event): Do not use TID or check using_threads. Update
15538 call to dead_thread_notify. Call handle_extended_wait.
15539 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15540 (send_sigstop): Delete sigstop_sent.
15541 (wait_for_sigstop): Avoid TID.
15542 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15543 (linux_test_for_tracefork): New.
15544 (linux_lookup_signals): Use thread_db_active and
15545 linux_supports_tracefork_flag.
15546 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15547 * linux-low.h (get_process_thread): Avoid TID.
15548 (struct process_ifo): Move thread_known and tid to the end. Remove
15549 sigstop_sent.
15550 (linux_attach_lwp, thread_db_init): Update prototypes.
15551 * server.h (change_inferior_id): Delete prototype.
15552 (add_pid_to_list, pull_pid_from_list): New prototypes.
15553 * thread-db.c (thread_db_use_events): New.
15554 (find_first_thread): Rename to...
15555 (find_one_thread): ...this. Update callers and messages. Do not
15556 call fatal. Check thread_db_use_events. Do not call
15557 change_inferior_id or new_thread_notify.
15558 (maybe_attach_thread): Update. Do not call new_thread_notify.
15559 (thread_db_init): Set thread_db_use_events. Check use_events.
15560 * utils.c (fatal, warning): Correct message prefix.
15561
15562 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15563
15564 * Makefile.in (clean): Remove new files.
15565 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15566 (powerpc-64.o, powerpc-64.c): New rules.
15567 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15568 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15569 with SPE.
15570 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15571 SPE targets.
15572 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15573 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15574 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15575 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15576 (target_regsets): Add AltiVec and SPE register sets.
15577 * configure.ac: Check for AltiVec and SPE.
15578 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
15579 (ppc_fill_vrregset, ppc_store_vrregset): New.
15580 (target_regsets): Add AltiVec register set.
15581 * configure: Regenerated.
15582
15583 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
15584
15585 * linux-low.c (O_LARGEFILE): Define.
15586 (linux_read_memory): Use /proc/PID/mem.
15587 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
15588 * configure, config.in: Regenerated.
15589
15590 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15591
15592 * linux-low.c (linux_wait_for_event): Do not pass signals while
15593 single-stepping.
15594
15595 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15596
15597 * win32-low.c (create_process): New.
15598 (win32_create_inferior): Use create_process instead of
15599 CreateProcess. If create_process failed retry appending an ".exe"
15600 suffix. Store the GetLastError result immediatelly after
15601 create_process calls and use it on the call to error.
15602
15603 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15604
15605 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
15606
15607 2007-08-23 Joel Brobecker <brobecker@adacore.com>
15608
15609 * configure.ac: Switch license to GPLv3.
15610
15611 2007-08-01 Michael Snyder <msnyder@access-company.com>
15612
15613 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
15614
15615 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
15616
15617 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
15618 typedef.
15619 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
15620 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
15621 CloseToolhelp32Snapshot.
15622 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
15623 CloseToolhelp32Snapshot.
15624
15625 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
15626
15627 * server.c (main): Check for inferior exit before main loop.
15628
15629 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
15630
15631 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
15632 instead of on tmp_desc.
15633
15634 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
15635 Daniel Jacobowitz <dan@codesourcery.com>
15636
15637 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
15638 (add_thread): Minor cleanups.
15639 (clear_inferiors): Move lower in the file. Clear the DLL
15640 list.
15641 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
15642 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
15643 (xml_escape_text): New.
15644 * server.c (handle_query): Handle qXfer:libraries:read. Report it
15645 for qSupported.
15646 (handle_v_cont): Report errors.
15647 (gdbserver_version): Update.
15648 (main): Correct size of own_buf. Do not report initial DLL events.
15649 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
15650 (unloaded_dll, xml_escape_text): New.
15651 * win32-low.c (enum target_waitkind): Update comments.
15652 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
15653 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
15654 (win32_EnumProcessModules, win32_GetModuleInformation)
15655 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
15656 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
15657 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
15658 (win32_Module32First, win32_Module32Next, load_toolhelp)
15659 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
15660 (get_child_debug_event): Handle DLL events.
15661 (win32_wait): Likewise.
15662
15663 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
15664
15665 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
15666 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
15667
15668 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15669
15670 * win32-low.c (handle_output_debug_string): Ignore event if not
15671 waiting.
15672
15673 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15674
15675 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
15676
15677 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
15678
15679 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
15680
15681 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
15682
15683 * inferiors.c (change_inferior_id): Add comment.
15684 * linux-low.c (check_removed_breakpoint): Add an early
15685 prototype. Improve debug output.
15686 (linux_attach): Doc update.
15687 (linux_detach_one_process, linux_detach): Clean up before releasing
15688 each process.
15689 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
15690 * linux-low.h (struct process_info): Doc improvement.
15691 * mem-break.c (delete_all_breakpoints): New.
15692 * mem-break.h (delete_all_breakpoints): New prototype.
15693 * thread-db.c (find_first_thread): New.
15694 (thread_db_create_event): Call it instead of
15695 thread_db_find_new_threads. Clean up unused variables.
15696 (maybe_attach_thread): Remove first thread handling.
15697 (thread_db_find_new_threads): Use find_first_thread.
15698 (thread_db_get_tls_address): Likewise.
15699
15700 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
15701
15702 * thread-db.c (thread_db_find_new_threads): Add prototype.
15703 (thread_db_create_event): Check for the main thread before adding
15704 a new thread.
15705 (maybe_attach_thread): Only enable event reporting if TID == 0.
15706 (thread_db_get_tls_address): Check for new threads.
15707
15708 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
15709
15710 * linux-low.c (linux_create_inferior): Try execv before execvp.
15711 * spu-low.c (spu_create_inferior): Likewise.
15712
15713 2007-06-13 Mike Frysinger <vapier@gentoo.org>
15714
15715 * linux-low.c (linux_create_inferior): Change execv to execvp.
15716 * spu-low.c (spu_create_inferior): Likewies.
15717
15718 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
15719
15720 * Makefile.in (clean): Clean new files instead of deleted ones.
15721 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
15722 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
15723 rules.
15724 * configure.srv: Specify XML files and new regformats for MIPS and
15725 MIPS64 GNU/Linux.
15726 * linux-mips-low.c (mips_num_regs): Set to only used registers.
15727 (mips_regmap): Do not fetch $0. Remove unused registers. Add
15728 an entry for the restart register.
15729 (mips_cannot_fetch_register, mips_cannot_store_register)
15730 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
15731 register names to match the XML descriptions.
15732 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
15733 restart register instead of $0.
15734
15735 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15736 Markus Deuling <deuling@de.ibm.com>
15737
15738 * remote-utils.c (decode_xfer_write): New function.
15739 * server.h (decode_xfer_write): Add prototype.
15740 * server.c (handle_query): Add PACKET_LEN argument. Support
15741 qXfer:spu:read and qXfer:spu:write packets.
15742 (main): Pass packet_len to handle_query.
15743 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
15744 * target.h (target_ops): Add qxfer_spu.
15745
15746 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15747
15748 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
15749 accessing non-seekable spufs files.
15750
15751 2007-05-16 Markus Deuling <deuling@de.ibm.com>
15752
15753 * server.c (handle_query): Add reply for qC packet.
15754
15755 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15756 Leo Zayas <lerele@champenstudios@com>
15757
15758 * server.h (check_remote_input_interrupt_request): New function.
15759 * remote_utils.c (INVALID_DESCRIPTOR): New define.
15760 (remote_desc): Initialize with INVALID_DESCRIPTOR.
15761 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
15762 (check_remote_input_interrupt_request): New function.
15763 * server.h (check_remote_input_interrupt_request): Declare.
15764 * win32-low.c (winapi_DebugBreakProcess,
15765 winapi_GenerateConsoleCtrlEvent): New typedefs.
15766 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
15767 to 250 ms.
15768 (win32_wait): Check for remote interrupt request
15769 with check_remote_input_interrupt_request.
15770 (win32_request_interrupt): New function.
15771 (win32_target_op): Set request_interrupt to win32_request_interrupt.
15772
15773 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15774
15775 * win32-low.c (debug_registers_changed,
15776 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
15777 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
15778 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
15779 (thread_rec): Get context using the low target.
15780 (child_add_thread): Call thread_added on the low target,
15781 which does the same thing.
15782 (regptr): Delete.
15783 (do_initial_child_stuff): Remove debug registers references.
15784 Set context using the low target. Resume threads after
15785 setting the contexts.
15786 (child_continue): Remove dead variable. Remove debug
15787 registers references.
15788 (child_fetch_inferior_registers): Go through the low target.
15789 (do_child_store_inferior_registers): Remove.
15790 (child_store_inferior_registers): Go through the low target.
15791 (win32_resume): Remove debug registers references.
15792 Set context using the low target.
15793 (handle_exception): Change return type to void. Don't record
15794 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
15795 first chance exception.
15796 (get_child_debug_event): Change return type to void. Remove
15797 goto loop. Always return after waiting for debug event.
15798 (win32_wait): Convert to switch statement. Handle spurious
15799 events.
15800
15801 * win32-i386-low.c (debug_registers_changed,
15802 debug_registers_used): New.
15803 (initial_stuff): Rename to ...
15804 (i386_initial_stuff): ... this. Clear debug registers
15805 state variables.
15806 (store_debug_registers): Delete.
15807 (i386_get_thread_context): New.
15808 (load_debug_registers): Delete.
15809 (i386_set_thread_context): New.
15810 (i386_thread_added): New.
15811 (single_step): Rename to ...
15812 (i386_single_step): ... this.
15813 (do_fetch_inferior_registers): Rename to ...
15814 (i386_fetch_inferior_register): ... this.
15815 (i386_store_inferior_register): New.
15816 (the_low_target): Adapt to new interface.
15817
15818 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
15819 (arm_get_thread_context): New.
15820 (arm_set_thread_context): New.
15821 (regptr): New.
15822 (do_fetch_inferior_registers): Rename to ...
15823 (arm_fetch_inferior_register): ... this.
15824 (arm_store_inferior_register): New.
15825 (arm_wince_breakpoint): Reimplement as unsigned long.
15826 (arm_wince_breakpoint_len): Define.
15827 (the_low_target): Adapt to new interface.
15828
15829 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
15830 load_debug_registers. Add get_thread_context, set_thread_context,
15831 thread_added and store_inferior_register. Rename
15832 fetch_inferior_registers to fetch_inferior_register.
15833 (regptr): Remove declaration.
15834
15835 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15836
15837 * linux-low.c (linux_detach): Change return type to int. Return 0.
15838 * spu-low.c (spu_detach): Likewise.
15839
15840 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15841
15842 * target.h (target_ops): Change return type of detach to int.
15843 Add join.
15844 (join_inferior): New.
15845 * server.c (main): Don't skip detach support on mingw32.
15846 If the inferior doesn't support detaching return error.
15847 Call join_inferior instead of using waitpid.
15848 * linux-low.c (linux_join): New.
15849 (linux_target_op): Add linux_join.
15850 * spu-low.c (spu_join): New.
15851 (spu_target_ops): Add spu_join.
15852 * win32-low.c (win32_detach): Adapt to new interface.
15853 Reopen current_process_handle before detaching. Issue a child
15854 resume before detaching.
15855 (win32_join): New.
15856 (win32_target_op): Add win32_join.
15857
15858 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15859
15860 * win32-low.c (win32-attach): Fix return value.
15861 * target.h (target_ops): Describe ATTACH return values.
15862
15863 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15864
15865 * win32-low.c (GETPROCADDRESS): Define.
15866 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
15867 (winapi_DebugSetProcessKillOnExit): Likewise.
15868 (win32_create_inferior): Force usage of ansi CreateProcessA.
15869 (win32_attach): Use GETPROCADDRESS.
15870 (win32_detach): Likewise.
15871
15872 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15873
15874 * win32-low.c (win32_wait): Don't use WSTOPSIG.
15875
15876 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
15877
15878 * win32-low.c: Commit leftover changes from 2007-03-29.
15879
15880 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15881
15882 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
15883 fields short instead of int. Add explicit padding.
15884 (i387_cache_to_fsave): Remove unnecessary casts.
15885 (i387_fsave_to_cache): Doc fix.
15886 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
15887
15888 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15889
15890 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
15891 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
15892
15893 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15894
15895 * configure.srv (arm*-*-mingw32ce*): Move near the other
15896 arm targets.
15897
15898 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15899
15900 * configure.ac: Add errno checking.
15901 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
15902 sys/file.h and malloc.h.
15903 (AC_CHECK_DECLS): Add perror.
15904 (srv_mingwce): Handle.
15905 * configure.srv (i[34567]86-*-cygwin*): Add
15906 win32-i386-low.o to srv_tgtobj.
15907 (i[34567]86-*-mingw*): Likewise.
15908 (arm*-*-mingw32ce*): Add case.
15909 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15910 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
15911 [__MINGW32CE__] (strerror): New function.
15912 [__MINGW32CE__] (errno): Define to GetLastError.
15913 [__MINGW32CE__] (COUNTOF): New macro.
15914 (remote_open): Remove extra close call.
15915 * mem-break.c (delete_breakpoint_at): New function.
15916 * mem-break.h (delete_breakpoint_at): Declare.
15917 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15918 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
15919 [USE_WIN32API] (read, write): Add char* casts.
15920 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
15921 * server.h: Include wincecompat.h on Windows CE.
15922 [HAVE_ERRNO_H]: Check.
15923 (perror): Declare if not declared.
15924 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
15925 (perror_with_name): Remove errno declaration.
15926 * wincecompat.h: New.
15927 * wincecompat.c: New.
15928 * win32-low.h: New.
15929 * win32-arm-low.c: New.
15930 * win32-i386-low.c: New.
15931 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
15932 (OUTMSG2): Make it safe.
15933 (_T): New macro.
15934 (COUNTOF): New macro.
15935 (NUM_REGS): Get it from the low target.
15936 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
15937 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
15938 (thread_rec): Let low target handle debug registers.
15939 (child_add_thread): Likewise.
15940 (child_init_thread_list): Likewise.
15941 (continue_one_thread): Likewise.
15942 (regptr): New.
15943 (do_child_fetch_inferior_registers): Move to ...
15944 * win32-i386-low.c: ... here, and rename to ...
15945 (do_fetch_inferior_registers): ... this.
15946 * win32-low.c (child_fetch_inferior_registers):
15947 Go through the low target.
15948 (do_child_store_inferior_registers): Use regptr.
15949 (strwinerror): New function.
15950 (win32_create_inferior): Handle Windows CE.
15951 Use strwinerror instead of strerror on Windows error
15952 codes. Add program to the error output.
15953 Don't close the main thread handle on Windows CE.
15954 (win32_attach): Use coredll.dll on Windows CE.
15955 (win32_kill): Close current process and current
15956 thread handles.
15957 (win32_detach): Use coredll.dll on Windows CE.
15958 (win32_resume): Let low target handle debug registers, and
15959 step request.
15960 (handle_exception): Add/Remove initial breakpoint. Avoid
15961 non-existant WSTOPSIG on Windows CE.
15962 (win32_read_inferior_memory): Cast to remove warning.
15963 (win32_arch_string): Go through the low target.
15964 (initialize_low): Call set_breakpoint_data with the low
15965 target's breakpoint.
15966 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
15967 FOP_REGNUM, mappings): Move to ...
15968 * win32-i386-low.c: ... here.
15969 * win32-low.c (win32_thread_info): Move to ...
15970 * win32-low.h: ... here.
15971 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
15972 win32-arm-low.c and wincecompat.c.
15973 (all:): Add $EXEEXT.
15974 (install-only:): Likewise.
15975 (gdbserver:): Likewise.
15976 (gdbreplay:): Likewise.
15977 * config.in: Regenerate.
15978 * configure: Regenerate.
15979
15980 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15981
15982 * win32-low.c: Rename typedef thread_info to
15983 win32_thread_info throughout.
15984
15985 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15986
15987 * win32-i386-low.c: Rename to ...
15988 * win32-low.c: ... this.
15989 * configure.srv: Replace win32-i386-low.o with win32-low.o.
15990 * Makefile.in: Likewise.
15991
15992 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
15993
15994 * remote-utils.c (monitor_output): Constify msg parameter.
15995 * server.h (monitor_output): Likewise.
15996 * win32-i386-low.c (handle_output_debug_string): New.
15997 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
15998 handle_output_debug_string.
15999 (get_child_debug_event): Likewise.
16000
16001 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16002
16003 * server.c (main): Correct strtoul check.
16004
16005 2007-03-27 Jon Ringle <jon@ringle.org>
16006
16007 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16008
16009 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16010
16011 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16012
16013 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16014
16015 * terminal.h: Check HAVE_SGTTY_H.
16016
16017 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16018
16019 * remote-utils.c (remote_open): Print out the assigned port number.
16020
16021 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16022
16023 * remote-utils.c (monitor_output): New function.
16024 * server.c (debug_threads): Define here.
16025 (monitor_show_help): New function.
16026 (handle_query): Handle qRcmd.
16027 (main): Do not handle 'd' packet.
16028 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16029 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16030 of debug_threads.
16031
16032 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16033
16034 * Makefile.in (EXEEXT): New.
16035 (clean): Use $(EXEEXT).
16036
16037 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16038
16039 * target.h (target_ops): Rename send_signal to request_interrupt,
16040 and remove enum target_signal parameter.
16041 * linux-low.c (linux_request_interrupt): Rename from
16042 linux_send_signal, and always send SIGINT.
16043 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16044 and always send SIGINT.
16045 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16046 of send_signal.
16047 (input_interrupt): Likewise.
16048
16049 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16050
16051 * server.c (get_features_xml): Check if target implemented
16052 arch_string.
16053 * win32-i386-low.c (win32_arch_string): New.
16054 (win32_target_ops): Add win32_arch_string as arch_string member.
16055
16056 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16057
16058 * spu-low.c (spu_arch_string): New.
16059 (spu_target_ops): Add spu_arch_string.
16060
16061 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16062
16063 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16064 * configure.ac: Do not check for terminal.h.
16065 * configure, config.in: Regenerated.
16066
16067 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16068
16069 * Makefile.in (OBS): Add $(XML_BUILTIN).
16070 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16071 (clean): Update.
16072 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16073 (arm-with-iwmmxt.c): New.
16074 * config.in, configure: Regenerate.
16075 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16076 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16077 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16078 (arm*-*-linux*): Add iWMMXt and regset support.
16079 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16080 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16081 (arm_store_wmmxregset, target_regsets): New.
16082 * server.c (get_features_xml): Take annex argument. Check builtin
16083 XML documents.
16084 (handle_query): Handle multiple annexes.
16085
16086 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16087
16088 * remote-utils.c [USE_WIN32API] (read, write): Define.
16089 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16090 write.
16091
16092 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16093
16094 * linux-i386-low.c (the_low_target): Set arch_string.
16095 * linux-x86-64-low.c (the_low_target): Likewise.
16096 * linux-low.c (linux_arch_string): New.
16097 (linux_target_ops): Add it.
16098 * linux-low.h (struct linux_target_ops): Add arch_string.
16099 * server.c (write_qxfer_response): Use const void * for DATA.
16100 (get_features_xml): New.
16101 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16102 * target.h (struct target_ops): Add arch_string method.
16103
16104 2007-01-03 Denis Pilat <denis.pilat@st.com>
16105 Daniel Jacobowitz <dan@codesourcery.com>
16106
16107 * linux-low.c (linux_kill): Handle being called with no threads.
16108 * win32-i386-low.c (win32_kill): Likewise.
16109 (get_child_debug_event): Clear current_process_handle.
16110
16111 2006-12-30 Denis PILAT <denis.pilat@st.com>
16112 Daniel Jacobowitz <dan@codesourcery.com>
16113
16114 * remote-utils.c (remote_open): Check the type of specified
16115 serial port devices before opening them.
16116 * server.c (main): Kill the inferior if an error occurs during
16117 the first remote_open.
16118
16119 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16120
16121 * README: Update supported targets.
16122
16123 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16124
16125 * Makefile.in (clean): Remove reg-mips64.c.
16126 (reg-mips64.c, reg-mips64.o): New rules.
16127 * configure.srv: Handle mips64. Include regset support for mips.
16128 * linux-mips-low.c (union mips_register): New.
16129 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16130 (mips_breakpoint, mips_breakpoint_at): Use int.
16131 (mips_collect_register, mips_supply_register)
16132 (mips_collect_register_32bit, mips_supply_register_32bit)
16133 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16134 (mips_store_fpregset, target_regsets): New.
16135 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16136
16137 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16138
16139 * configure.srv: Add target "spu*-*-*".
16140 * Makefile.in (clean): Remove reg-spu.c.
16141 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16142 * spu-low.c: New file.
16143
16144 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16145
16146 * configure.ac: Correct td_thr_tls_get_addr test.
16147 * configure: Regenerated.
16148
16149 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16150
16151 * linux-low.c (linux_wait_for_event): Reformat. Use the
16152 pass_signals array.
16153 * remote-utils.c (decode_address_to_semicolon): New.
16154 * server.c (pass_signals, handle_general_set): New.
16155 (handle_query): Mention QPassSignals for qSupported.
16156 (main): Call handle_general_set.
16157 * server.h (pass_signals, decode_address_to_semicolon): New.
16158
16159 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16160
16161 * server.c (handle_query): Correct error handling for read_auxv.
16162
16163 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16164
16165 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16166 and srv_linux_thread_db to yes.
16167 * linux-s390-low.c (s390_fill_gregset): New function.
16168 (target_regsets): Define data structure.
16169
16170 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16171
16172 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16173 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16174 * config.in, configure: Regenerated.
16175 * inferiors.c (gdb_id_to_thread): New function.
16176 (gdb_id_to_thread_id): Use it.
16177 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16178 * linux-low.h (struct process_info): Add th member.
16179 (thread_db_get_tls_address): New prototype.
16180 * remote-utils.c (decode_address): Make non-static.
16181 * server.c (handle_query): Handle qGetTLSAddr.
16182 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16183 * target.h (struct target_ops): Add get_tls_address.
16184 * thread-db.c (maybe_attach_thread): Save the thread handle.
16185 (thread_db_get_tls_address): New.
16186
16187 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16188
16189 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16190 (linux_resume_one_process): Take a siginfo_t *. Update all
16191 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16192 (struct pending_signals): Add a siginfo_t.
16193 (linux_wait_for_process): Always set last_status.
16194 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16195 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16196 * linux-low.h (struct process_info): Add last_status.
16197
16198 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16199
16200 * remote-utils.c (try_rle): New function.
16201 (putpkt_binary): Use it.
16202
16203 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16204
16205 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16206 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16207 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16208 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16209 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16210 point registers.
16211
16212 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16213
16214 * server.c (terminal_fd): New variable.
16215 (old_foreground_pgrp): Likewise.
16216 (restore_old_foreground_pgrp): New function.
16217 (start_inferior): Record the terminal file descriptor in terminal_fd
16218 and its original foreground group in old_foreground_pgrp. Register
16219 restore_old_foreground_pgrp with atexit().
16220
16221 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16222
16223 * server.c (handle_query): Correct qPart to qXfer.
16224
16225 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16226
16227 * configure.ac: Check for more headers which are missing on
16228 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16229 * configure.srv: Add Cygwin and mingw32.
16230 * remote-utils.c: Don't include headers unconditionally which
16231 are missing on mingw32. Include <winsock.h> for mingw32.
16232 (remote_open): Adjust for mingw32 support. Flush
16233 standard error after writing to it.
16234 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16235 (unblock_async_io, enable_async_io, disable_async_io)
16236 (readchar, getpkt): Update for Winsock support.
16237 (prepare_resume_reply): Expect a protocol signal number.
16238 * server.c: Disable <sys/wait.h> on mingw32.
16239 (start_inferior): Adjust for mingw32 support. Flush
16240 standard error after writing to it.
16241 (attach_inferior): Likewise. Use protocol signal
16242 numbers.
16243 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16244 and names.
16245 * win32-i386-low.c: New file.
16246 * Makefile.in (XM_CLIBS): Set.
16247 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16248 (win32-i386-low.o): New dependency rule.
16249 * linux-low.c (linux_wait): Use target signal numbers.
16250 * target.h (struct target_ops): Doc fix.
16251 * server.h (target_signal_to_name): New prototype.
16252 * gdbreplay.c: Don't include headers unconditionally which
16253 are missing on mingw32. Include <winsock.h> for mingw32.
16254 (remote_close, remote_open): Adjust for Winsock support.
16255 * configure, config.in: Regenerated.
16256
16257 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16258
16259 * server.c (decode_xfer_read, write_qxfer_response): New.
16260 (handle_query): Take a packet length argument. Handle
16261 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16262 the qSupported response.
16263 (main): Update call to handle_query.
16264
16265 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16266
16267 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16268 (putpkt_binary): Renamed from putpkt and adjusted for binary
16269 data.
16270 (putpkt): New wrapper for putpkt_binary.
16271 (readchar): Don't mask off the high bit.
16272 (decode_X_packet): New function.
16273 * server.c (main): Call putpkt_binary if a handler sets the packet
16274 length. Save the length of the incoming packet. Handle 'X'.
16275 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16276
16277 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16278
16279 * server.c (handle_query): Handle qSupported.
16280
16281 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16282
16283 * remote-utils.c (all_symbols_looked_up): New variable.
16284 (look_up_one_symbol): Check it.
16285 * server.h (look_up_one_symbol): New declaration.
16286 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16287
16288 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16289
16290 * Makefile.in (linux-arm-low.o): Update dependencies.
16291 * linux-arm-low.c: Include "gdb_proc_service.h".
16292 (PTRACE_GET_THREAD_AREA): Define.
16293 (ps_get_thread_area): New function.
16294
16295 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16296
16297 * configure.srv (m68k*-*-uclinux*): New target.
16298 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16299 (linux_resume_one_process): Remove extraneous cast.
16300 (linux_read_offsets): New.
16301 (linux_target_op): Add linux_read_offsets on mmuless systems.
16302 * server.c (handle_query): Add qOffsets logic.
16303 * target.h (struct target_ops): Add read_offsets.
16304
16305 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16306
16307 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16308 (PTRACE_GET_THREAD_AREA): Define.
16309 (ps_get_thread_area): New function.
16310 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16311 (linux-x86-64-low.o): Update.
16312
16313 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16314
16315 * configure.ac: Remove checks for prfpregset_t.
16316 * gdb_proc_service.h: New file.
16317 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16318 new "gdb_proc_service.h".
16319 * proc-service.c: Likewise.
16320 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16321 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16322 * Makefile.in (gdb_proc_service_h): Updated.
16323 * configure, config.in: Regenerated.
16324
16325 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16326
16327 * remote-utils.c (prepare_resume_reply): Move declaration
16328 of gdb_id_from_wait to the top of the block.
16329
16330 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16331
16332 * linux-low.c (regsets_store_inferior_registers): Read the regset
16333 from the target before filling it.
16334
16335 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16336
16337 * server.c (attach_inferior): Return SIGTRAP for a successful
16338 attach.
16339
16340 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16341
16342 * Makefile.in (OBS): Add version.o.
16343 (STAGESTUFF): Delete.
16344 (version.o): Add dependencies.
16345 (version.c): Replace rule.
16346 (clean): Remove version.c.
16347 * server.c (gdbserver_version): New.
16348 (gdbserver_usage): Use printf.
16349 (main): Handle --version and --help.
16350 * server.h (version, host_name): Add declarations.
16351
16352 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16353
16354 * linux-arm-low.c:
16355 * linux-arm-low.c:
16356 * inferiors.c:
16357 * i387-fp.h:
16358 * i387-fp.c:
16359 * gdbreplay.c:
16360 * regcache.c:
16361 * proc-service.c:
16362 * mem-break.h:
16363 * mem-break.c:
16364 * linux-x86-64-low.c:
16365 * linux-sh-low.c:
16366 * linux-s390-low.c:
16367 * linux-ppc64-low.c:
16368 * linux-ppc-low.c:
16369 * linux-mips-low.c:
16370 * linux-m68k-low.c:
16371 * linux-m32r-low.c:
16372 * linux-low.h:
16373 * linux-low.c:
16374 * linux-ia64-low.c:
16375 * linux-i386-low.c:
16376 * linux-crisv32-low.c:
16377 * thread-db.c:
16378 * terminal.h:
16379 * target.h:
16380 * target.c:
16381 * server.h:
16382 * server.c:
16383 * remote-utils.c:
16384 * regcache.h:
16385 * utils.c:
16386 * Makefile.in:
16387 * configure.ac:
16388 * gdbserver.1: Add (C) after Copyright. Update the FSF
16389 address.
16390
16391 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16392
16393 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16394 (arm_breakpoint_at): Recognize both breakpoints.
16395 (the_low_target): Use the correct breakpoint instruction.
16396
16397 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16398
16399 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16400 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16401 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16402 (the_low_target): Update.
16403
16404 2005-10-25 Andreas Schwab <schwab@suse.de>
16405
16406 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16407
16408 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16409 (ia64_num_regs): Reduce to 462.
16410
16411 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16412
16413 * acinclude.m4: Correct quoting.
16414 * aclocal.m4: Regenerated.
16415
16416 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16417 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16418 (thread_db_init): Call thread_db_err_str.
16419 * configure.ac: Check for TD_VERSION.
16420 * config.in, configure: Regenerated.
16421
16422 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16423
16424 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16425
16426 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16427
16428 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16429 is not available. Define HAVE_PTRACE_GETREGS if it is.
16430 * config.in, configure: Regenerated.
16431 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16432 * linux-i386-low.c, linux-m68k-low.c: Update to use
16433 HAVE_PTRACE_GETREGS.
16434 * linux-low.c (regsets_fetch_inferior_registers)
16435 (regsets_store_inferior_registers): Only return 0 if we processed
16436 GENERAL_REGS.
16437 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16438 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16439
16440 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16441
16442 * inferiors.c (struct thread_info): Add gdb_id.
16443 (add_thread): Add gdb_id argument.
16444 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16445 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16446 calls to add_thread.
16447 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16448 * server.c (handle_query): Use thread_to_gdb_id.
16449 (handle_v_cont, main): Use gdb_id_to_thread_id.
16450 * server.h (add_thread): Update prototype.
16451 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16452 prototypes.
16453
16454 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16455
16456 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16457 left-padded registers.
16458 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16459 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16460
16461 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16462
16463 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16464 * configure: Regenerate.
16465 * config.in: Regenerate.
16466 * server.h (NEED_DECLARATION_STRERROR):
16467 Replace with !HAVE_DECL_STRERROR.
16468
16469 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16470
16471 * linux-low.c (linux_wait, linux_send_signal): Don't test
16472 an unsigned long variable for > 0 if it could be MAX_ULONG.
16473 * server.c (myresume): Likewise.
16474 * target.c (set_desired_inferior): Likewise.
16475
16476 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16477
16478 * configure.ac: Simplify and improve check for socklen_t.
16479 * configure, config.in: Regenerate.
16480
16481 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16482
16483 * acconfig.h: Remove.
16484 * configure.ac: Add a test for socklen_t. Use three-argument
16485 AC_DEFINE throughout.
16486 * config.in: Regenerated using autoheader 2.59.
16487 * configure: Regenerated.
16488
16489 * gdbreplay.c (socklen_t): Provide a default.
16490 (remote_open): Use socklen_t.
16491 * remote-utils.c (socklen_t): Provide a default.
16492 (remote_open): Use socklen_t.
16493 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16494 unsigned char.
16495
16496 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16497 char for buffers.
16498 * linux-low.c (linux_read_memory, linux_write_memory)
16499 (linux_read_auxv): Likewise.
16500 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16501 (check_mem_write): Likewise.
16502 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16503 Likewise.
16504 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16505 (registers_from_string, register_data): Likewise.
16506 * server.c (handle_query, main): Likewise.
16507 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16508 (decode_M_packet): Likewise.
16509 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16510 * target.h (struct target_ops): Update read_memory, write_memory,
16511 and read_auxv.
16512 (read_inferior_memory, write_inferior_memory): Update.
16513 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16514 to unsigned char *.
16515 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16516 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16517 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16518 linux-s390-low.c, linux-sh-low.c: Update for changes in
16519 read_inferior_memory and the_low_target->breakpoint.
16520
16521 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16522
16523 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16524 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16525 * configure.srv: Add powerpc64-*-linux*.
16526 * linux-ppc64-low.c: New file.
16527
16528 2005-05-23 Orjan Friberg <orjanf@axis.com>
16529
16530 * linux-cris-low.c: New file with support for CRIS.
16531 * linux-crisv32-low.c: Ditto for CRISv32.
16532 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16533 (clean): Add reg-cris.c and reg-crisv32.c.
16534 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16535 reg-crisv32.o, and reg-crisv32.c to make rules.
16536 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16537 recognized targets.
16538
16539 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16540
16541 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16542 of sizeof (PTRACE_XFER_TYPE).
16543 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16544
16545 2005-05-12 Orjan Friberg <orjanf@axis.com>
16546
16547 * target.h (struct target_ops): Add insert_watchpoint,
16548 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16549 pointers for hardware watchpoint support.
16550 * linux-low.h (struct linux_target_ops): Ditto.
16551 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16552 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16553 to linux_target_ops.
16554 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16555 reply packet.
16556 * server.c (main): Recognize 'Z' and 'z' packets.
16557
16558 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16559
16560 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16561 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16562 (the_low_target): Add new members.
16563
16564 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16565
16566 * proc-service.c (ps_lgetregs): Search all_processes instead of
16567 all_threads.
16568
16569 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16570
16571 * server.c (start_inferior): Change return type to int.
16572 (attach_inferior): Change sigptr to int *.
16573 (handle_v_cont, handle_v_requests): Change signal to int *.
16574 (main): Change signal to int.
16575
16576 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16577
16578 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
16579 * configure.srv: Add m32r*-*-linux*.
16580 * linux-m32r-low.c: New file.
16581
16582 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
16583
16584 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
16585
16586 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16587
16588 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
16589 Take unsigned long arguments for PIDs.
16590 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
16591 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
16592 (wait_for_sigstop, linux_resume_one_process)
16593 (regsets_fetch_inferior_registers, linux_send_signal)
16594 (linux_read_auxv): Likewise. Update the types of variables holding
16595 PIDs. Update format string specifiers.
16596 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
16597 * remote-utils.c (prepare_resume_reply): Likewise.
16598 * server.c (cont_thread, general_thread, step_thread)
16599 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
16600 unsigned long.
16601 (handle_query): Update format specifiers.
16602 (handle_v_cont, main): Use strtoul for thread IDs.
16603 * server.h (struct inferior_list_entry): Use unsigned long for ID.
16604 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
16605 (general_thread, step_thread, thread_from_wait)
16606 (old_thread_from_wait): Update.
16607 * target.h (struct thread_resume): Use unsigned long for THREAD.
16608 (struct target_ops): Use unsigned long for arguments to attach and
16609 thread_alive.
16610
16611 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
16612
16613 * acinclude.m4: Include bfd/bfd.m4 directly.
16614 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
16615 <agriffis@toolchain.org>.
16616 * aclocal.m4, configure: Regenerated.
16617
16618 2005-01-07 Andrew Cagney <cagney@gnu.org>
16619
16620 * configure.ac: Rename configure.in, require autoconf 2.59.
16621 * configure: Re-generate.
16622
16623 2004-12-08 Daniel Jacobowitz <dan@debian.org>
16624
16625 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
16626 LIBS when finished.
16627 * aclocal.m4: Regenerated.
16628 * configure: Regenerated.
16629
16630 2004-11-21 Andreas Schwab <schwab@suse.de>
16631
16632 * linux-m68k-low.c (m68k_num_gregs): Define.
16633 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
16634 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
16635 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
16636 (m68k_breakpoint_at): New. Add to the_low_target.
16637
16638 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
16639 srv_linux_thread_db to yes.
16640
16641 2004-10-20 Joel Brobecker <brobecker@gnat.com>
16642
16643 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
16644 (ARCH_SET_FS): Likewise.
16645 (ARCH_GET_FS): Likewise.
16646 (ARCH_GET_GS): Likewise.
16647
16648 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16649
16650 * linux-i386-low.c (ps_get_thread_area): New.
16651 * linux-x86-64-low.c (ps_get_thread_area): New.
16652 * linux-low.c: Include <sys/syscall.h>.
16653 (linux_kill_one_process): Don't kill the first thread here.
16654 (linux_kill): Kill the first thread here.
16655 (kill_lwp): New function.
16656 (send_sigstop, linux_send_signal): Use it.
16657 * proc-service.c: Clean up #ifdefs.
16658 (fpregset_info): Delete.
16659 (ps_lgetregs): Update and enable implementation.
16660 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
16661 implementations.
16662 * remote-utils.c (struct sym_cache, symbol_cache): New.
16663 (input_interrupt): Print a clearer message.
16664 (async_io_enabled): New variable.
16665 (enable_async_io, disable_async_io): Use it. Update comments.
16666 (look_up_one_symbol): Use the symbol cache.
16667 * thread-db.c (thread_db_look_up_symbols): New function.
16668 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
16669
16670 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16671
16672 * configure.in: Test for -rdynamic.
16673 * configure: Regenerated.
16674 * Makefile (INTERNAL_LDFLAGS): New.
16675 (gdbserver, gdbreplay): Use it.
16676
16677 2004-09-02 Andrew Cagney <cagney@gnu.org>
16678
16679 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
16680
16681 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
16682
16683 * linux-low.c (linux_wait): Clear all_processes list also.
16684
16685 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16686
16687 * linux-low.c: Include <errno.h>. Remove extern declaration of
16688 errno.
16689
16690 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16691
16692 * gdbreplay.c, server.h, utils.c: Update copyright years.
16693
16694 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16695
16696 * server.c (main): Print child status or termination signal from
16697 variable 'signal', not 'sig'.
16698
16699 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16700
16701 * linux-low.c (linux_read_memory): Change return type to
16702 int. Check for and return error from ptrace().
16703 * target.c (read_inferior_memory): Change return type to int. Pass
16704 back return status from the_target->read_memory().
16705 * target.h (struct target_ops): Adapt *read_memory() prototype.
16706 Update comment.
16707 (read_inferior_memory): Adapt prototype.
16708 * server.c (main): Return an error packet if
16709 read_inferior_memory() returns an error.
16710
16711 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
16712
16713 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
16714 Unify with other clean targets.
16715
16716 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16717
16718 * server.c (handle_v_cont): Call set_desired_inferior.
16719
16720 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16721
16722 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
16723
16724 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16725
16726 * linux-low.c (linux_wait): Unblock async I/O.
16727 (linux_resume): Block and enable async I/O.
16728 * remote-utils.c (block_async_io, unblock_async_io): New functions.
16729 * server.h (block_async_io, unblock_async_io): Add prototypes.
16730
16731 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16732
16733 * remote-utils.c (remote_open): Print a status notice after
16734 opening a TCP port.
16735 * server.c (attach_inferior): Print a status notice after
16736 attaching.
16737
16738 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16739
16740 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
16741
16742 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
16743
16744 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
16745 error packet.
16746 * server.c, target.h: Update copyright years.
16747
16748 2004-02-25 Roland McGrath <roland@redhat.com>
16749
16750 * target.h (struct target_ops): New member `read_auxv'.
16751 * server.c (handle_query): Handle qPart:auxv:read: query using that.
16752 * linux-low.c (linux_read_auxv): New function.
16753 (linux_target_ops): Initialize `read_auxv' member to that.
16754
16755 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
16756
16757 Committed by Jim Blandy <jimb@redhat.com>.
16758
16759 * linux-s390-low.c (s390_num_regs): Update.
16760 (s390_regmap): Remove control registers. Use __s390x__ predefine
16761 instead of GPR_SIZE to distiguish s390 and s390x targets.
16762
16763 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
16764
16765 * linux-low.c: Update copyright year.
16766 (check_removed_breakpoint): Clear pending_is_breakpoint.
16767 (linux_set_resume_request, linux_queue_one_thread)
16768 (resume_status_pending_p): New functions.
16769 (linux_continue_one_thread): Use process->resume.
16770 (linux_resume): Only resume threads if there are no pending events.
16771 * linux-low.h (struct process_info): Add resume request
16772 pointer.
16773
16774 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
16775
16776 * regcache.c (new_register_cache): Clear the allocated register
16777 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
16778
16779 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
16780
16781 * linux-low.c (linux_resume): Take a struct thread_resume *
16782 argument.
16783 (linux_wait): Update call.
16784 (resume_ptr): New static variable.
16785 (linux_continue_one_thread): Renamed from
16786 linux_continue_one_process. Use resume_ptr.
16787 (linux_resume): Use linux_continue_one_thread.
16788 * server.c (handle_v_cont, handle_v_requests): New functions.
16789 (myresume): New function.
16790 (main): Handle 'v' case.
16791 * target.h (struct thread_resume): New type.
16792 (struct target_ops): Change argument of "resume" to struct
16793 thread_resume *.
16794 (myresume): Delete macro.
16795
16796 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
16797
16798 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
16799 (uninstall): Support DESTDIR.
16800
16801 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
16802
16803 * configure.srv: Add xscale*linux copy of arm*linux entry.
16804
16805 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
16806
16807 * linux-arm-low.c (arm_reinsert_addr): New function.
16808 (the_low_target): Add arm_reinsert_addr.
16809
16810 2003-07-08 Mark Kettenis <kettenis@gnu.org>
16811
16812 * mem-break.c: Remove whitespace at end of file.
16813
16814 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
16815
16816 * configure.in: Check whether we need to prototype strerror.
16817 * server.h: Optionally prototype strerror.
16818 * gdbreplay.c (perror_with_name): Use strerror.
16819 * linux-low.c (linux_attach_lwp): Use strerror.
16820 * utils.c (perror_with_name): Use strerror.
16821 * config.in, configure: Regenerated.
16822
16823 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
16824
16825 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
16826 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
16827
16828 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
16829
16830 * Makefile.in (SFILES): Update.
16831 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
16832 low-sun3.c: Remove files.
16833
16834 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
16835
16836 * linux-low.c: Move comment to linux_thread_alive where it belonged.
16837 (linux_detach_one_process, linux_detach): New functions.
16838 (linux_target_ops): Add linux_detach.
16839 * server.c (main): Handle 'D' packet.
16840 * target.h (struct target_ops): Add "detach" member.
16841 (detach_inferior): Define.
16842
16843 2003-06-13 Mark Kettenis <kettenis@gnu.org>
16844
16845 From Kelley Cook <kelleycook@wideopenwest.com>:
16846 * configure.srv: Accept i[34567]86 variants.
16847
16848 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
16849
16850 * linux-low.c (linux_wait_for_event): Correct comment typos.
16851 (linux_resume_one_process): Call check_removed_breakpoint.
16852 (linux_send_signal): New function.
16853 (linux_target_ops): Add linux_send_signal.
16854 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
16855 of kill.
16856 * target.h (struct target_ops): Add send_signal.
16857
16858 2003-05-29 Jim Blandy <jimb@redhat.com>
16859
16860 * linux-low.c (usr_store_inferior_registers): Transfer buf in
16861 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
16862 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
16863 away part of the register's value.
16864
16865 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
16866
16867 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
16868 (linux_wait_for_event, linux_init_signals): Likewise.
16869
16870 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
16871
16872 * configure.in: Check for stdlib.h.
16873 * configure: Regenerated.
16874 * config.in: Regenerated.
16875
16876 2003-01-04 Andreas Schwab <schwab@suse.de>
16877
16878 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
16879
16880 2003-01-02 Andrew Cagney <ac131313@redhat.com>
16881
16882 * Makefile.in: Remove obsolete code.
16883
16884 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
16885
16886 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
16887 defined(PT_FPR0_HI).
16888
16889 2002-11-17 Stuart Hughes <seh@zee2.com>
16890
16891 * linux-arm-low.c (arm_num_regs): Increase.
16892 (arm_regmap): Include status register.
16893
16894 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
16895
16896 * linux-low.c (register_addr): Remove incorrect -1 check.
16897
16898 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
16899
16900 * linux-low.c (linux_create_inferior): Call setpgid. Return
16901 the new PID.
16902 (unstopped_p, linux_signal_pid): Remove.
16903 (linux_target_ops): Remove linux_signal_pid.
16904 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
16905 global instead of target method.
16906 * target.h (struct target_ops): Remove signal_pid. Update comment
16907 for create_inferior.
16908 * server.c (signal_pid): New variable.
16909 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
16910 gdbserver. Set the child to be the foreground process group.
16911 (attach_inferior): Set signal_pid.
16912
16913 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
16914
16915 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
16916
16917 2002-08-20 Jim Blandy <jimb@redhat.com>
16918
16919 * Makefile.in (LDFLAGS): Allow the configure script to establish a
16920 default for this.
16921
16922 2002-08-01 Andrew Cagney <cagney@redhat.com>
16923
16924 * Makefile.in: Make chill references obsolete.
16925
16926 2002-07-24 Kevin Buettner <kevinb@redhat.com>
16927
16928 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
16929 * configure: Regenerate.
16930 * config.in: Regenerate.
16931
16932 2002-07-09 David O'Brien <obrien@FreeBSD.org>
16933
16934 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
16935 (perror_with_name, remote_close, remote_open, expect, play): Static.
16936
16937 2002-07-04 Michal Ludvig <mludvig@suse.cz>
16938
16939 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
16940 byte offsets instead of an array of indexes.
16941 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
16942
16943 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
16944
16945 * regcache.c: Add comment.
16946
16947 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
16948
16949 * thread-db.c: New file.
16950 * proc-service.c: New file.
16951 * acinclude.m4: New file.
16952 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
16953 proc-service.o, and thread-db.o.
16954 (linux-low.o): Add USE_THREAD_DB.
16955 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
16956 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
16957 * aclocal.m4: Regenerated.
16958 * config.in: Regenerated.
16959 * configure: Regenerated.
16960 * configure.in: Check for proc_service.h, sys/procfs.h,
16961 thread_db.h, and linux/elf.h headrs.
16962 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
16963 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
16964 Check for -lthread_db and thread support.
16965 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
16966 PowerPC, and SuperH.
16967 * i387-fp.c: Constify arguments.
16968 * i387-fp.h: Likewise.
16969 * inferiors.c: (struct thread_info): Renamed from
16970 `struct inferior_info'. Remove PID member. Use generic inferior
16971 list header. All uses updated.
16972 (inferiors, signal_pid): Removed.
16973 (all_threads): New variable.
16974 (get_thread): Define.
16975 (add_inferior_to_list): New function.
16976 (for_each_inferior): New function.
16977 (change_inferior_id): New function.
16978 (add_inferior): Removed.
16979 (remove_inferior): New function.
16980 (add_thread): New function.
16981 (free_one_thread): New function.
16982 (remove_thread): New function.
16983 (clear_inferiors): Use for_each_inferior and free_one_thread.
16984 (find_inferior): New function.
16985 (find_inferior_id): New function.
16986 (inferior_target_data): Update argument type.
16987 (set_inferior_target_data): Likewise.
16988 (inferior_regcache_data): Likewise.
16989 (set_inferior_regcache_data): Likewise.
16990 * linux-low.c (linux_bp_reinsert): Remove.
16991 (all_processes, stopping_threads, using_thrads)
16992 (struct pending_signals, debug_threads, pid_of): New.
16993 (inferior_pid): Replace with macro.
16994 (struct inferior_linux_data): Remove.
16995 (get_stop_pc, add_process): New functions.
16996 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
16997 Use add_process and add_thread.
16998 (linux_attach_lwp): New function, based on old linux_attach. Use
16999 add_process and add_thread. Set stop_expected for new threads.
17000 (linux_attach): New function.
17001 (linux_kill_one_process): New function.
17002 (linux_kill): Kill all LWPs.
17003 (linux_thread_alive): Use find_inferior_id.
17004 (check_removed_breakpoints, status_pending_p): New functions.
17005 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17006 Update. Use WNOHANG. Wait for cloned processes also. Update process
17007 struct for the found process.
17008 (linux_wait_for_event): New function.
17009 (linux_wait): Use it. Support LWPs.
17010 (send_sigstop, wait_for_sigstop, stop_all_processes)
17011 (linux_resume_one_process, linux_continue_one_process): New functions.
17012 (linux_resume): Support LWPs.
17013 (REGISTER_RAW_SIZE): Remove.
17014 (fetch_register): Use register_size instead. Call supply_register.
17015 (usr_store_inferior_registers): Likewise. Call collect_register.
17016 Fix recursive case.
17017 (regsets_fetch_inferior_registers): Improve error message.
17018 (regsets_store_inferior_registers): Add debugging.
17019 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17020 (unstopped_p, linux_signal_pid): New functions.
17021 (linux_target_ops): Add linux_signal_pid.
17022 (linux_init_signals): New function.
17023 (initialize_low): Call it. Initialize using_threads.
17024 * regcache.c (inferior_regcache_data): Add valid
17025 flag.
17026 (get_regcache): Fetch registers lazily. Add fetch argument
17027 and update all callers.
17028 (regcache_invalidate_one, regcache_invalidate): New
17029 functions.
17030 (new_register_cache): Renamed from create_register_cache.
17031 Return the new regcache.
17032 (free_register_cache): Change argument to a void *.
17033 (registers_to_string, registers_from_string): Call get_regcache
17034 with fetch flag set.
17035 (register_data): Make static. Pass fetch flag to get_regcache.
17036 (supply_register): Call get_regcache with fetch flag clear.
17037 (collect_register): Call get_regcache with fetch flag set.
17038 (collect_register_as_string): New function.
17039 * regcache.h: Update.
17040 * remote-utils.c (putpkt): Flush after debug output and use
17041 stderr.
17042 Handle input interrupts while waiting for an ACK.
17043 (input_interrupt): Use signal_pid method.
17044 (getpkt): Flush after debug output and use stderr.
17045 (outreg): Use collect_register_as_string.
17046 (new_thread_notify, dead_thread_notify): New functions.
17047 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17048 and general_thread.
17049 (look_up_one_symbol): Flush after debug output.
17050 * server.c (step_thread, server_waiting): New variables.
17051 (start_inferior): Don't use signal_pid. Update call to mywait.
17052 (attach_inferior): Update call to mywait.
17053 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17054 (main): Don't fetch/store registers explicitly. Use
17055 set_desired_inferior. Support proposed ``Hs'' packet. Update
17056 calls to mywait.
17057 * server.h: Update.
17058 (struct inferior_list, struct_inferior_list_entry): New.
17059 * target.c (set_desired_inferior): New.
17060 (write_inferior_memory): Constify.
17061 (mywait): New function.
17062 * target.h: Update.
17063 (struct target_ops): New signal_pid method.
17064 (mywait): Removed macro, added prototype.
17065
17066 * linux-low.h (regset_func): Removed.
17067 (regset_fill_func, regset_store_func): New.
17068 (enum regset_type): New.
17069 (struct regset_info): Add type field. Use new operation types.
17070 (struct linux_target_ops): stop_pc renamed to get_pc.
17071 Add decr_pc_after_break and breakpoint_at.
17072 (get_process, get_thread_proess, get_process_thread)
17073 (strut process_info, all_processes, linux_attach_lwp)
17074 (thread_db_init): New.
17075
17076 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17077 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17078 (the_low_target): Add new members.
17079 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17080 (i386_store_fpxregset): Constify.
17081 (target_regsets): Add new kind identifier.
17082 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17083 (i386_set_pc): Add debugging.
17084 (i386_breakpoint_at): New function.
17085 (the_low_target): Add new members.
17086 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17087 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17088 (mips_breakpoint_at): New.
17089 (the_low_target): Add new members.
17090 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17091 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17092 (the_low_target): Add new members.
17093 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17094 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17095 (the_low_target): Add new members.
17096 * linux-x86-64-low.c (target_regsets): Add new kind
17097 identifier.
17098
17099 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17100
17101 From Martin Pool <mbp@samba.org>:
17102 * server.c (gdbserver_usage): New function.
17103 (main): Call it.
17104
17105 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17106
17107 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17108 stop_at -> stop_pc.
17109
17110 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17111
17112 * Makefile.in: Remove obsolete code.
17113
17114 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17115
17116 * linux-low.c (regsets_fetch_inferior_registers),
17117 (regsets_store_inferior_registers): Removed cast to int from
17118 ptrace() calls.
17119 * regcache.h: Added declaration of struct inferior_info.
17120
17121 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17122
17123 * inferiors.c (struct inferior_info): Add regcache_data.
17124 (add_inferior): Call create_register_cache.
17125 (clear_inferiors): Call free_register_cache.
17126 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17127 * regcache.c (struct inferior_regcache_data): New.
17128 (registers): Remove.
17129 (get_regcache): New function.
17130 (create_register_cache, free_register_cache): New functions.
17131 (set_register_cache): Don't initialize the register cache here.
17132 (registers_to_string, registers_from_string, register_data): Call
17133 get_regcache.
17134 * regcache.h: Add prototypes.
17135 * server.h: Likewise.
17136
17137 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17138
17139 * mem-break.c: New file.
17140 * mem-break.h: New file.
17141 * Makefile.in: Add mem-break.o rule; update server.h
17142 dependencies.
17143 * inferiors.c (struct inferior_info): Add target_data
17144 member.
17145 (clear_inferiors): Free target_data member if set.
17146 (inferior_target_data, set_inferior_target_data): New functions.
17147 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17148 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17149 * linux-low.c (linux_bp_reinsert): New variable.
17150 (struct inferior_linux_data): New.
17151 (linux_create_inferior): Use set_inferior_target_data.
17152 (linux_attach): Likewise. Call add_inferior.
17153 (linux_wait_for_one_inferior): New function.
17154 (linux_wait): Call it.
17155 (linux_write_memory): Add const.
17156 (initialize_low): Call set_breakpoint_data.
17157 * linux-low.h (struct linux_target_ops): Add breakpoint
17158 handling members.
17159 * server.c (attach_inferior): Remove extra add_inferior
17160 call.
17161 * server.h: Include mem-break.h. Update inferior.c
17162 prototypes.
17163 * target.c (read_inferior_memory)
17164 (write_inferior_memory): New functions.
17165 * target.h (read_inferior_memory)
17166 (write_inferior_memory): Change macros to prototypes.
17167 (struct target_ops): Update comments. Add const to write_memory
17168 definition.
17169
17170 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17171
17172 * linux-low.c (usr_store_inferior_registers): Support
17173 registers which are allowed to fail to store.
17174 * linux-low.h (linux_target_ops): Likewise.
17175 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17176 (ppc_cannot_store_register): FPSCR may not be storable.
17177
17178 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17179
17180 * server.h: Include <string.h> if HAVE_STRING_H.
17181 * ChangeLog: Correct paths in last ChangeLog entry.
17182
17183 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17184
17185 * linux-low.h: Remove obsolete prototypes.
17186 (struct linux_target_ops): New.
17187 (extern the_low_target): New.
17188 * linux-low.c (num_regs, regmap): Remove declarations.
17189 (register_addr): Use the_low_target explicitly.
17190 (fetch_register): Likewise.
17191 (usr_fetch_inferior_registers): Likewise.
17192 (usr_store_inferior_registers): Likewise.
17193 * linux-arm-low.c (num_regs): Remove.
17194 (arm_num_regs): Define.
17195 (arm_regmap): Renamed from regmap, made static.
17196 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17197 made static.
17198 (arm_cannot_store_register): Renamed from cannot_store_register,
17199 made static.
17200 (the_low_target): New.
17201 * linux-i386-low.c (num_regs): Remove.
17202 (i386_num_regs): Define.
17203 (i386_regmap): Renamed from regmap, made static.
17204 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17205 made static.
17206 (i386_cannot_store_register): Renamed from cannot_store_register,
17207 made static.
17208 (the_low_target): New.
17209 * linux-ia64-low.c (num_regs): Remove.
17210 (ia64_num_regs): Define.
17211 (ia64_regmap): Renamed from regmap, made static.
17212 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17213 made static.
17214 (ia64_cannot_store_register): Renamed from cannot_store_register,
17215 made static.
17216 (the_low_target): New.
17217 * linux-m68k-low.c (num_regs): Remove.
17218 (m68k_num_regs): Define.
17219 (m68k_regmap): Renamed from regmap, made static.
17220 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17221 made static.
17222 (m68k_cannot_store_register): Renamed from cannot_store_register,
17223 made static.
17224 (the_low_target): New.
17225 * linux-mips-low.c (num_regs): Remove.
17226 (mips_num_regs): Define.
17227 (mips_regmap): Renamed from regmap, made static.
17228 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17229 made static.
17230 (mips_cannot_store_register): Renamed from cannot_store_register,
17231 made static.
17232 (the_low_target): New.
17233 * linux-ppc-low.c (num_regs): Remove.
17234 (ppc_num_regs): Define.
17235 (ppc_regmap): Renamed from regmap, made static.
17236 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17237 made static.
17238 (ppc_cannot_store_register): Renamed from cannot_store_register,
17239 made static.
17240 (the_low_target): New.
17241 * linux-s390-low.c (num_regs): Remove.
17242 (s390_num_regs): Define.
17243 (s390_regmap): Renamed from regmap, made static.
17244 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17245 made static.
17246 (s390_cannot_store_register): Renamed from cannot_store_register,
17247 made static.
17248 (the_low_target): New.
17249 * linux-sh-low.c (num_regs): Remove.
17250 (sh_num_regs): Define.
17251 (sh_regmap): Renamed from regmap, made static.
17252 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17253 made static.
17254 (sh_cannot_store_register): Renamed from cannot_store_register,
17255 made static.
17256 (the_low_target): New.
17257 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17258 (the_low_target): New.
17259
17260 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17261
17262 * Makefile.in: Add stamp-h target.
17263 * configure.in: Create stamp-h.
17264 * configure: Regenerated.
17265
17266 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17267
17268 * inferiors.c: New file.
17269 * target.c: New file.
17270 * target.h: New file.
17271 * Makefile.in: Add target.o and inferiors.o. Update
17272 dependencies.
17273 * linux-low.c (inferior_pid): New static variable,
17274 moved from server.c.
17275 (linux_create_inferior): Renamed from create_inferior.
17276 Call add_inferior. Return 0 on success instead of a PID.
17277 (linux_attach): Renamed from myattach.
17278 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17279 (linux_thread_alive): Renamed from mythread_alive.
17280 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17281 child dies.
17282 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17283 (regsets_store_inferior_registers): Correct error message.
17284 Add missing ``return 0''.
17285 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17286 (linux_store_registers): Renamed from store_inferior_registers.
17287 (linux_read_memory): Renamed from read_inferior_memory.
17288 (linux_write_memory): Renamed from write_inferior_memory.
17289 (linux_target_ops): New structure.
17290 (initialize_low): Call set_target_ops ().
17291 * remote-utils.c (unhexify): New function.
17292 (hexify): New function.
17293 (input_interrupt): Send signals to ``signal_pid''.
17294 * server.c (inferior_pid): Remove.
17295 (start_inferior): Update create_inferior call.
17296 (attach_inferior): Call add_inferior.
17297 (handle_query): New function.
17298 (main): Call handle_query for `q' packets.
17299 * server.h: Include "target.h". Remove obsolete prototypes.
17300 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17301
17302 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17303
17304 * Makefile.in: Add WARN_CFLAGS. Update configury
17305 dependencies.
17306 * configure.in: Check for <string.h>
17307 * configure: Regenerate.
17308 * config.in: Regenerate.
17309 * gdbreplay.c: Include needed system headers.
17310 (remote_open): Remove strchr prototype.
17311 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17312 * regcache.c (supply_register): Change buf argument to const void *.
17313 (supply_register_by_name): Likewise.
17314 (collect_register): Change buf argument to void *.
17315 (collect_register_by_name): Likewise.
17316 * regcache.h: Add missing prototypes.
17317 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17318 * server.c (handle_query): New function.
17319 (attached): New static variable, moved out of main.
17320 (main): Quiet longjmp clobber warnings.
17321 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17322 * utils.c (error): Remove NORETURN.
17323 (fatal): Likewise.
This page took 0.408383 seconds and 5 git commands to generate.