Normalize include guards in gdb
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-02-07 Tom Tromey <tom@tromey.com>
2
3 * x86-tdesc.h: Rename include guard.
4 * x86-low.h: Add include guard.
5 * wincecompat.h: Rename include guard.
6 * win32-low.h: Add include guard.
7 * utils.h: Rename include guard.
8 * tracepoint.h: Rename include guard.
9 * tdesc.h: Rename include guard.
10 * target.h: Rename include guard.
11 * server.h: Rename include guard.
12 * remote-utils.h: Rename include guard.
13 * regcache.h: Rename include guard.
14 * nto-low.h: Rename include guard.
15 * notif.h: Add include guard.
16 * mem-break.h: Rename include guard.
17 * lynx-low.h: Add include guard.
18 * linux-x86-tdesc.h: Add include guard.
19 * linux-s390-tdesc.h: Add include guard.
20 * linux-ppc-tdesc-init.h: Add include guard.
21 * linux-low.h: Add include guard.
22 * linux-aarch64-tdesc.h: Add include guard.
23 * linux-aarch32-low.h: Add include guard.
24 * inferiors.h: Rename include guard.
25 * i387-fp.h: Rename include guard.
26 * hostio.h: Rename include guard.
27 * gdbthread.h: Rename include guard.
28 * gdb_proc_service.h: Rename include guard.
29 * event-loop.h: Rename include guard.
30 * dll.h: Rename include guard.
31 * debug.h: Rename include guard.
32 * ax.h: Rename include guard.
33
34 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
35
36 PR gdb/23985
37 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
38 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
39
40 2019-01-25 Tom Tromey <tom@tromey.com>
41
42 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
43
44 2019-01-25 Tom Tromey <tom@tromey.com>
45
46 * win32-low.c: Fix common/ includes.
47 * win32-i386-low.c: Fix common/ includes.
48 * tracepoint.c: Fix common/ includes.
49 * thread-db.c: Fix common/ includes.
50 * target.h: Fix common/ includes.
51 * symbol.c: Fix common/ includes.
52 * spu-low.c: Fix common/ includes.
53 * server.h: Fix common/ includes.
54 * server.c: Fix common/ includes.
55 * remote-utils.c: Fix common/ includes.
56 * regcache.h: Fix common/ includes.
57 * regcache.c: Fix common/ includes.
58 * nto-x86-low.c: Fix common/ includes.
59 * notif.h: Fix common/ includes.
60 * mem-break.h: Fix common/ includes.
61 * lynx-low.c: Fix common/ includes.
62 * lynx-i386-low.c: Fix common/ includes.
63 * linux-x86-tdesc-selftest.c: Fix common/ includes.
64 * linux-x86-low.c: Fix common/ includes.
65 * linux-low.c: Fix common/ includes.
66 * inferiors.h: Fix common/ includes.
67 * i387-fp.c: Fix common/ includes.
68 * hostio.c: Fix common/ includes.
69 * hostio-errno.c: Fix common/ includes.
70 * gdbthread.h: Fix common/ includes.
71 * gdbreplay.c: Fix common/ includes.
72 * fork-child.c: Fix common/ includes.
73 * event-loop.c: Fix common/ includes.
74 * ax.c:
75 (enum gdb_agent_op): Fix common/ includes.
76
77 2019-01-21 Tom Tromey <tom@tromey.com>
78
79 * tracepoint.c: Fix includes.
80 * remote-utils.c: Fix includes.
81 * linux-x86-low.c: Fix includes.
82
83 2019-01-01 Joel Brobecker <brobecker@adacore.com>
84
85 * gdbreplay.c (gdbreplay_version): Update copyright year in
86 version message.
87 * server.c (gdbserver_version): Likewise.
88
89 2018-12-05 Alan Hayward <alan.hayward@arm.com>
90
91 * linux-low.c (add_lwp): Switch ordering.
92
93 2018-11-29 Tom Tromey <tom@tromey.com>
94
95 * win32-low.c (win32_join): Take pid, not process.
96 * target.h (struct target_ops) <join>: Change argument type.
97 (join_inferior): Change argument name.
98 * spu-low.c (spu_join): Take pid, not process.
99 * server.c (handle_detach): Preserve pid before destroying
100 process.
101 * lynx-low.c (lynx_join): Take pid, not process.
102 * linux-low.c (linux_join): Take pid, not process.
103
104 2018-11-23 Alan Hayward <alan.hayward@arm.com>
105
106 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
107 (aarch64_cannot_fetch_register): Likewise.
108 (struct linux_target_ops): Update references.
109
110 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
111
112 * linux-ppc-low.c: Include nat/linux-ptrace.h.
113
114 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
115
116 * configure.srv (ipa_ppc_linux_regobj): Add
117 powerpc-isa207-htm-vsx32l-ipa.o and
118 powerpc-isa207-htm-vsx64l-ipa.o.
119 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
120 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
121 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
122 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
123 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
124 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
125 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
126 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
127 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
128 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
129 (init_registers_powerpc_isa207_htm_vsx32l)
130 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
131 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
132 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
133 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
134 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
135 (ppc_store_tm_ctarregset): New functions.
136 (ppc_regsets): Add entries for HTM regsets.
137 (ppc_arch_setup): Set htm in features struct when needed. Set
138 sizes for the HTM regsets.
139 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
140 (initialize_low_arch): Call
141 init_registers_powerpc_isa207_htm_vsx32l and
142 init_registers_powerpc_isa207_htm_vsx64l.
143 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
144 PPC_TDESC_ISA207_HTM_VSX.
145 (initialize_low_tracepoint): Call
146 init_registers_powerpc_isa207_htm_vsx32l and
147 init_registers_powerpc_isa207_htm_vsx64l.
148
149 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
150
151 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
152 rs6000/power-linux-pmu.xml to srv_xmlfiles.
153 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
154 (ppc_store_pmuregset): New functions.
155 (ppc_regsets): Add entries for ebb and pmu regsets.
156 (ppc_arch_setup): Set isa207 in features struct if the ebb and
157 pmu regsets are available. Set sizes for these regsets.
158
159 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
160
161 * configure.srv (ipa_ppc_linux_regobj): Add
162 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
163 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
164 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
165 rs6000/powerpc-isa207-vsx32l.xml, and
166 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
167 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
168 <PPC_TDESC_ISA207_VSX>: New enum value.
169 (init_registers_powerpc_isa207_vsx32l): Declare.
170 (init_registers_powerpc_isa207_vsx64l): Declare.
171 * linux-ppc-low.c (ppc_fill_tarregset): New function.
172 (ppc_store_tarregset): New function.
173 (ppc_regsets): Add entry for the TAR regset.
174 (ppc_arch_setup): Set isa207 in features struct when needed. Set
175 size for the TAR regsets.
176 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
177 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
178 and init_registers_powerpc_isa207_vsx64l.
179 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
180 (initialize_low_tracepoint): Call
181 init_registers_powerpc_isa207_vsx32l and
182 init_registers_powerpc_isa207_vsx64l.
183
184 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
185 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
186
187 * configure.srv (ipa_ppc_linux_regobj): Add
188 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
189 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
190 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
191 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
192 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
193 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
194 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
195 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
196 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
197 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
198 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
199 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
200 (ppc_hwcap): Add comment.
201 (ppc_hwcap2): New global.
202 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
203 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
204 (ppc_regsets): Add entries for the DSCR and PPR regsets.
205 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
206 when needed. Set sizes for the the DSCR and PPR regsets.
207 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
208 (initialize_low_arch): Call
209 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
210 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
211 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
212 PPC_TDESC_ISA205_PPR_DSCR_VSX.
213 (initialize_low_tracepoint): Call
214 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
215 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
216
217 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
218
219 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
220
221 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
222 Simon Marchi <simark@simark.ca>
223
224 * acinclude.m4: Include "../selftest.m4".
225 * configure: Regenerate.
226 * configure.ac: Use "GDB_AC_SELFTEST".
227 * configure.srv: Use "$enable_unittests" instead of
228 "$development" when checking whether unit tests have been
229 enabled.
230 * server.c (captured_main): Update message informing that
231 selftests have been disabled.
232
233 2018-10-04 Tom Tromey <tom@tromey.com>
234
235 * configure: Rebuild.
236
237 2018-10-04 Tom Tromey <tom@tromey.com>
238
239 * server.c (handle_status): Rename inner "thread".
240 (process_serial_event): Declare "res" in 'm' case.
241 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
242 (iterate_over_lwps): Rename inner "thread".
243 (linux_qxfer_libraries_svr4): Rename inner "len".
244 * gdbthread.h (find_thread_in_random): Rename inner "thread".
245
246 2018-10-01 Gary Benson <gbenson@redhat.com>
247
248 * gdb_proc_service.h: Moved common code to
249 common/gdb_proc_service.h.
250
251 2018-10-01 Gary Benson <gbenson@redhat.com>
252
253 * gdb_proc_service.h: Synchronize comments and whitespace with
254 GDB's version of this file.
255
256 2018-09-25 Tom Tromey <tom@tromey.com>
257
258 * configure: Rebuild.
259 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
260
261 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
262
263 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
264 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
265 ($(IPA_LIB)): Sort IPA_OBJS.
266
267 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
268
269 * Makefile.in: Remove references to $(ADD_DEPS).
270
271 2018-09-16 Tom Tromey <tom@tromey.com>
272
273 * remote-utils.c (remote_open): Use GNU style for metasyntactic
274 variables.
275 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
276 variables.
277
278 2018-09-05 Tom Tromey <tom@tromey.com>
279
280 * configure: Rebuild.
281
282 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
283
284 PR build/23399
285 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
286
287 2018-08-27 Tom Tromey <tom@tromey.com>
288
289 PR build/23087:
290 * configure: Rebuild.
291
292 2018-08-27 Tom Tromey <tom@tromey.com>
293
294 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
295 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
296 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
297 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
298 (s390x_emit_stack_adjust): Add casts to unsigned char.
299
300 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
301
302 PR gdb/23374
303 PR gdb/23375
304 * server.h (struct client_state) <disable_randomization>:
305 Initialize to 1.
306
307 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
308
309 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
310 variable.
311 (mips_supply_ptrace_register): Likewise.
312
313 2018-07-22 Tom Tromey <tom@tromey.com>
314
315 * configure: Rebuild.
316
317 2018-07-22 Tom Tromey <tom@tromey.com>
318
319 * win32-low.c (win32_create_inferior): Remove unused variables.
320 * gdbreplay.c (remote_open): Remove unused variable.
321 * remote-utils.c (remote_prepare): Remove unused variable.
322 * x86-tdesc.h (X86_TDESC_H): Define.
323 (amd64_expedite_regs): Define conditionally.
324 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
325 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
326 * remote-utils.c (readchar): Remove unused variable.
327
328 2018-07-13 Pedro Alves <palves@redhat.com>
329
330 * linux-low.c (linux_kill): Change parameter to process_info
331 pointer instead of pid. Adjust.
332 * lynx-low.c (lynx_kill): Likewise.
333 * nto-low.c (nto_kill): Likewise.
334 * spu-low.c (spu_kill): Likewise.
335 * win32-low.c (win32_kill): Likewise.
336 * server.c (handle_v_kill, kill_inferior_callback)
337 (detach_or_kill_for_exit): Adjust.
338 * target.c (kill_inferior): Change parameter to process_info
339 pointer instead of pid. Adjust.
340 * target.h (struct target_ops) <kill>: Change parameter to
341 process_info pointer instead of pid. Adjust all implementations
342 and callers.
343 (kill_inferior): Likewise.
344
345 2018-07-13 Pedro Alves <palves@redhat.com>
346
347 * linux-low.c (linux_detach, linux_join): Change parameter to
348 process_info pointer instead of pid. Adjust.
349 * lynx-low.c (lynx_detach, lynx_join): Likewise.
350 * nto-low.c (nto_detach): Likewise.
351 * spu-low.c (spu_detach, spu_join): Likewise.
352 * win32-low.c (win32_detach, win32_join): Likewise.
353 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
354 * target.h (struct target_ops) <detach, join>: Change parameter to
355 process_info pointer instead of pid. Adjust all implementations
356 and callers.
357 (detach_inferior, join_inferior): Rename 'pid' parameter to
358 'proc'.
359
360 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
361 Jan Kratochvil <jan.kratochvil@redhat.com>
362 Paul Fertser <fercerpav@gmail.com>
363 Tsutomu Seki <sekiriki@gmail.com>
364
365 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
366 (OBS): Add 'common/netstuff.o'.
367 (GDBREPLAY_OBS): Likewise.
368 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
369 (remote_open): Implement support for IPv6
370 connections.
371 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
372 and 'wspiapi.h'.
373 (handle_accept_event): Accept connections from IPv6 sources.
374 (remote_prepare): Handle IPv6-style hostnames; implement
375 support for IPv6 connections.
376 (remote_open): Implement support for printing connections from
377 IPv6 sources.
378
379 2018-07-11 Pedro Alves <palves@redhat.com>
380
381 PR gdb/23377
382 * mem-break.c (any_persistent_commands): Add process_info
383 parameter and use it instead of relying on the current process.
384 Change return type to bool.
385 * mem-break.h (any_persistent_commands): Add process_info
386 parameter and change return type to bool.
387 * server.c (handle_detach): Remove require_running_or_return call.
388 Look up the process_info for the process we're about to detach.
389 If not found, return back error to GDB. Adjust
390 any_persistent_commands call to pass down a process pointer.
391
392 2018-07-11 Pedro Alves <palves@redhat.com>
393
394 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
395 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
396 instead of collect_register_by_name.
397 * regcache.c (regcache_raw_get_unsigned_by_name): New.
398 * regcache.h (regcache_raw_get_unsigned_by_name): New.
399
400 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
401 Pedro Alves <palves@redhat.com>
402
403 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
404
405 2018-07-03 Tom Tromey <tom@tromey.com>
406
407 * linux-low.c: Update.
408 * lynx-low.c: Update.
409 * mem-break.c: Update.
410 * nto-low.c: Update.
411 * remote-utils.c: Update.
412 * server.c: Update.
413 * spu-low.c: Update.
414 * target.c: Update.
415 * win32-low.c: Update.
416
417 2018-07-03 Tom Tromey <tom@tromey.com>
418
419 * server.c: Update.
420
421 2018-07-03 Tom Tromey <tom@tromey.com>
422
423 * linux-low.c: Update.
424
425 2018-07-03 Tom Tromey <tom@tromey.com>
426
427 * target.c: Update.
428
429 2018-07-03 Tom Tromey <tom@tromey.com>
430
431 * linux-low.c: Update.
432 * linux-mips-low.c: Update.
433 * lynx-low.c: Update.
434 * nto-low.c: Update.
435 * remote-utils.c: Update.
436 * server.c: Update.
437 * spu-low.c: Update.
438 * target.c: Update.
439 * thread-db.c: Update.
440
441 2018-07-03 Tom Tromey <tom@tromey.com>
442
443 * linux-low.c: Update.
444 * linux-mips-low.c: Update.
445 * lynx-low.c: Update.
446 * mem-break.c: Update.
447 * nto-low.c: Update.
448 * remote-utils.c: Update.
449 * server.c: Update.
450 * spu-low.c: Update.
451 * target.c: Update.
452 * tracepoint.c: Update.
453
454 2018-07-03 Tom Tromey <tom@tromey.com>
455
456 * linux-low.c: Update.
457 * linux-ppc-low.c: Update.
458 * linux-x86-low.c: Update.
459 * proc-service.c: Update.
460 * server.c: Update.
461 * spu-low.c: Update.
462 * thread-db.c: Update.
463 * win32-low.c: Update.
464
465 2018-07-03 Tom Tromey <tom@tromey.com>
466
467 * linux-low.c: Update.
468 * lynx-low.c: Update.
469 * nto-low.c: Update.
470 * remote-utils.c: Update.
471 * spu-low.c: Update.
472 * thread-db.c: Update.
473 * win32-low.c: Update.
474
475 2018-06-29 Joel Brobecker <brobecker@adacore.com>
476
477 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
478 parameter in call to 'amd64_create_target_description'.
479
480 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
481
482 * x86-tdesc.h: Remove executable permission flag.
483
484 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
485
486 * configure.ac: Remove AC_PREREQ, add missing quoting.
487 * configure: Re-generate.
488 * config.in: Re-generate.
489 * aclocal.m4: Re-generate.
490
491 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
492
493 * tracepoint.h (current_traceframe): Remove declaration.
494
495 2018-06-18 Alan Hayward <alan.hayward@arm.com>
496
497 * linux-aarch64-low.c (is_sve_tdesc): New function.
498 (aarch64_sve_regs_copy_to_regcache): Likewise.
499 (aarch64_sve_regs_copy_from_regcache): Likewise.
500 (aarch64_regs_info): Add SVE checks.
501 (initialize_low_arch): Initialize SVE.
502
503 2018-06-18 Alan Hayward <alan.hayward@arm.com>
504
505 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
506
507 2018-06-11 Alan Hayward <alan.hayward@arm.com>
508
509 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
510 (initialize_low_tracepoint): Likewise
511 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
512 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
513 param.
514 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
515 checks.
516 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
517
518 2018-06-11 Alan Hayward <alan.hayward@arm.com>
519
520 * server.h (PBUFSIZ): Increase size
521
522 2018-06-11 Alan Hayward <alan.hayward@arm.com>
523
524 * regcache.c (regcache::raw_compare): New function.
525 * regcache.h (regcache::raw_compare): New declaration.
526
527 2018-06-11 Alan Hayward <alan.hayward@arm.com>
528
529 * regcache.c (new_register_cache): Use new.
530 (free_register_cache): Use delete.
531 (register_data): Use const.
532 (supply_register): Move body inside regcache.
533 (regcache::raw_supply): New override function.
534 (collect_register): Move body inside regcache.
535 (regcache::raw_collect): New override function.
536 (regcache::get_register_status): New override function.
537 * regcache.h (struct regcache): Inherit from reg_buffer_common.
538
539 2018-06-09 Tom Tromey <tom@tromey.com>
540
541 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
542 declare queue.
543 (event_queue): Use std::queue.
544 (gdb_event_xfree): Remove.
545 (initialize_event_loop, process_event, wait_for_event): Update.
546
547 2018-06-08 Stan Cox <scox@redhat.com>
548
549 * win32-low.c (win32_create_inferior): last_ptid and last_status
550 moved to client_state.
551
552 2018-06-08 Pedro Alves <palves@redhat.com>
553
554 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
555 common/common-exceptions.o, common/common-utils.o,
556 common/errors.o, common/print-utils.o and utils.o.
557 * gdbreplay.c: Include "common-defs.h" instead of the two
558 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
559 string.h or alloca.h.
560 (perror_with_name): Delete.
561 (remote_open): Use xstrdup instead of strdup.
562 (main): Rename to ...
563 (captured_main): ... this.
564 (main): New.
565
566 2018-06-08 Tom Tromey <tom@tromey.com>
567
568 * linux-low.c (linux_low_read_btrace): Update.
569
570 2018-06-04 Stan Cox <scox@redhat.com>
571
572 * server.h (struct client_state): New.
573 * server.c (cont_thread, general_thread, multi_process)
574 (report_fork_events, report_vfork_events, report_exec_events)
575 (report_thread_events, swbreak_feature, hwbreak_feature)
576 (vCont_supported, disable_randomization, pass_signals)
577 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
578 Moved to client_state.
579 * remote-utils.c (remote_debug, noack_mode)
580 (transport_is_reliable): Moved to client_state.
581 * tracepoint.c (current_traceframe): Moved to client_state.
582
583 Update all callers.
584 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
585 linux-low.c, remote-utils.h, target.c: Use client_state.
586
587 2018-05-31 Alan Hayward <alan.hayward@arm.com>
588
589 * configure.srv: Add new c/h file.
590
591 2018-05-31 Alan Hayward <alan.hayward@arm.com>
592
593 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
594 null VQ.
595
596 2018-05-25 Maciej W. Rozycki <macro@mips.com>
597
598 * gdb.arch/mips-fpregset-core.exp: New test.
599 * gdb.arch/mips-fpregset-core.c: New test source.
600
601 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
602
603 PR server/23198
604 * hostio.c (require_int): Do not report overflow for integers
605 between 0xfffffff and 0x7fffffff.
606
607 2018-05-22 Maciej W. Rozycki <macro@mips.com>
608
609 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
610 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
611 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
612 functions.
613 (the_low_target): Wire them.
614
615 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
616
617 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
618 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
619 mode. Call collect_register_by_name with vscr using
620 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
621 (ppc_store_vrregset): Add and set vscr_offset variable as in
622 ppc_fill_vrregset. Call supply_register_by_name with vscr using
623 vscr_offset.
624
625 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
626
627 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
628 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
629 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
630
631 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
632
633 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
634 (ppc_store_vsxregset): Likewise.
635 (ppc_fill_vrregset): Likewise.
636 (ppc_store_vrregset): Likewise.
637 (ppc_fill_evrregset): Likewise.
638 (ppc_store_evrregset): Likewise.
639 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
640 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
641 needed.
642
643 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
644
645 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
646 wordsize of the inferior. Call ppc_linux_target_wordsize.
647
648 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
649
650 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
651 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
652 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
653 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
654 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
655 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
656 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
657 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
658 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
659 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
660 (tdesc_powerpc_e500l): Remove.
661 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
662 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
663 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
664 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
665 linux-ppc-tdesc.h.
666 (ppc_arch_setup): Remove target description matching code. Fill a
667 ppc_linux_features struct and call ppc_linux_match_description
668 with it.
669
670 2018-05-22 Maciej W. Rozycki <macro@mips.com>
671
672 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
673 width of the requested register exceeds the width of the
674 `ptrace' data type.
675 (mips_cannot_store_register): Likewise.
676
677 2018-05-21 Maciej W. Rozycki <macro@mips.com>
678
679 * linux-mips-low.c (mips_fetch_register): New function. Update
680 preceding comment.
681 (mips_store_gregset): Supply 0 rather than $restart for $zero.
682 (the_low_target): Wire `mips_fetch_register'.
683
684 2018-05-10 Joel Brobecker <brobecker@adacore.com>
685
686 * lynx-i386-low.c (LYNXOS_178): New macro.
687 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
688 the layout on LynxOS-178.
689 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
690 handle floating point registers that are not supported by
691 LynxOS-178.
692
693 2018-05-10 Tom Tromey <tom@tromey.com>
694
695 * configure: Rebuild.
696
697 2018-05-10 Joel Brobecker <brobecker@adacore.com>
698
699 PR server/23158:
700 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
701 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
702 Use it to set the expedite_regs field in the given tdesc.
703 * x86-tdesc.h: New file.
704 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
705 Adjust following the addition of the new expedite_regs parameter
706 to init_target_desc.
707 * linux-tic6x-low.c (tic6x_read_description): Likewise.
708 * linux-x86-tdesc.c: #include "x86-tdesc.h".
709 (i386_linux_read_description, amd64_linux_read_description):
710 Adjust following the addition of the new expedite_regs parameter
711 to init_target_desc.
712 * lynx-i386-low.c: #include "x86-tdesc.h".
713 (lynx_i386_arch_setup): Adjust following the addition of the new
714 expedite_regs parameter to init_target_desc.
715 * nto-x86-low.c: #include "x86-tdesc.h".
716 (nto_x86_arch_setup): Adjust following the addition of the new
717 expedite_regs parameter to init_target_desc.
718 * win32-i386-low.c: #include "x86-tdesc.h".
719 (i386_arch_setup): Adjust following the addition of the new
720 expedite_regs parameter to init_target_desc.
721
722 2018-05-10 Joel Brobecker <brobecker@adacore.com>
723
724 PR server/23158:
725 * win32-low.c (win32_create_inferior): Add call to my_wait
726 setting last_status global.
727
728 2018-05-10 Joel Brobecker <brobecker@adacore.com>
729
730 PR server/23158:
731 * win32-low.c (create_process): Only call gdb_tilde_expand if
732 inferior_cwd is not NULL.
733
734 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
735
736 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
737 registers to the cache if their values have changed.
738 (i387_xsave_to_cache): Provide default values for x87 control
739 registers when these features are available, but disabled.
740 * regcache.c (supply_register_by_name_zeroed): New function.
741 * regcache.h (supply_register_by_name_zeroed): Declare new
742 function.
743
744 2018-05-07 Tom Tromey <tom@tromey.com>
745
746 * configure: Rebuild.
747
748 2018-05-04 Tom Tromey <tom@tromey.com>
749
750 * configure: Rebuild.
751
752 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
753 Pedro Alves <palves@redhat.com>
754
755 * linux-aarch64-low.c (aarch64_stopped_data_address):
756 Likewise.
757
758 2018-04-27 Tom Tromey <tom@tromey.com>
759
760 * configure: Rebuild.
761
762 2018-04-23 Tom Tromey <tom@tromey.com>
763
764 * configure: Rebuild.
765
766 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
767
768 * Makefile.in (depcomp): Add "..".
769 (all_deps_files): New and use it.
770
771 2018-04-18 Alan Hayward <alan.hayward@arm.com>
772
773 * configure.srv (aarch64*-*-linux*): Don't include xml.
774 (i[34567]86-*-cygwin*): Likewise.
775 (i[34567]86-*-linux*): Likewise.
776 (i[34567]86-*-lynxos*): Likewise.
777 (i[34567]86-*-mingw32ce*): Likewise.
778 (i[34567]86-*-mingw*): Likewise.
779 (i[34567]86-*-nto*): Likewise.
780 (tic6x-*-uclinux): Likewise.
781 (x86_64-*-linux*): Likewise.
782 (x86_64-*-mingw*): Likewise.
783 (x86_64-*-cygwin*): Likewise.
784
785 2018-04-18 Alan Hayward <alan.hayward@arm.com>
786
787 * tdesc.c: Remove xml parameter.
788
789 2018-04-18 Alan Hayward <alan.hayward@arm.com>
790
791 * server.c (get_features_xml): Remove cast.
792 * tdesc.c (void target_desc::accept): Fill in function.
793 (tdesc_get_features_xml): Remove old xml creation.
794 (print_xml_feature::visit_pre): Add xml vistor.
795 * tdesc.h (struct target_desc): Make xmltarget mutable.
796 (tdesc_get_features_xml): Remove declaration.
797
798 2018-04-18 Alan Hayward <alan.hayward@arm.com>
799
800 * tdesc.c (tdesc_architecture_name): Add new function.
801 (tdesc_osabi_name): Likewise.
802 (tdesc_get_features_xml): Use new functions.
803
804 2018-04-18 Alan Hayward <alan.hayward@arm.com>
805
806 * tdesc.c (tdesc_create_flags): Remove.
807 (tdesc_add_flag): Likewise.
808 (tdesc_named_type): Likewise.
809 (tdesc_create_union): Likewise.
810 (tdesc_create_struct): Likewise.
811 (tdesc_create_vector): Likewise.
812 (tdesc_add_bitfield): Likewise.
813 (tdesc_add_field): Likewise.
814 (tdesc_set_struct_size): Likewise.
815
816 2018-04-18 Alan Hayward <alan.hayward@arm.com>
817
818 * tdesc.c (~target_desc): Remove implictly deleted items.
819 (init_target_desc): Iterate all features.
820 (tdesc_get_features_xml): Use vector.
821 (tdesc_create_feature): Create feature.
822 * tdesc.h (tdesc_feature) Remove
823 (target_desc): Add features.
824
825 2018-04-18 Alan Hayward <alan.hayward@arm.com>
826
827 * Makefile.in: Add common/tdesc.c
828 * tdesc.c (init_target_desc): init all reg_defs from register
829 vector.
830 (tdesc_create_reg): Create tdesc_reg.
831 * tdesc.h (tdesc_feature): Add register vector.
832
833 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
834
835 * tdesc.h (struct target_desc) <features>: Change type to
836 std::vector<std::string>.
837 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
838 changes.
839 (tdesc_get_features_xml): Likewise.
840 (tdesc_create_feature): Likewise.
841
842 2018-03-26 Alan Hayward <alan.hayward@arm.com>
843
844 * regcache.c (find_register_by_number): Return a ref.
845 (find_regno): Use references.
846 (register_size): Likewise.
847 (register_data): Likewise.
848 * tdesc.c (target_desc::~target_desc): Remove free calls.
849 (target_desc::operator==): Use std::vector compare.
850 (init_target_desc): Use reference.
851 (tdesc_create_reg): Use reg constructors.
852 * tdesc.h (struct target_desc): Replace pointer with object.
853
854 2018-03-23 Alan Hayward <alan.hayward@arm.com>
855
856 * regcache.c (find_register_by_number): Make static.
857 (find_regno): Use find_register_by_number
858 * regcache.h (struct reg): Remove declaration.
859
860 2018-03-23 Alan Hayward <alan.hayward@arm.com>
861
862 * tdesc.c (target_desc::~target_desc): Move to here.
863 (target_desc::operator==): Likewise.
864 * tdesc.h (target_desc::~target_desc): Move from here.
865 (target_desc::operator==): Likewise.
866
867 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
868
869 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
870
871 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
872
873 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
874 S390_TDESC_GS.
875 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
876 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
877 and init_registers_s390_gs_linux64.
878
879 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
880
881 * linux-s390-low.c (s390_fill_gs): Remove function.
882 (s390_fill_gsbc): Remove function.
883 (s390_regsets): Set fill functions for the guarded storage regsets
884 to NULL.
885
886 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
887
888 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
889 the word size. Add comment.
890 (s390_get_wordsize): New function.
891 (s390_arch_setup): No longer select a temporary tdesc to fetch the
892 pswm with it. Instead, use s390_get_wordsize to determine the
893 word size first and derive the correct tdesc from that directly.
894
895 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
896
897 * Makefile.in: Include silent-rules.mk.
898 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
899 (COMPILE): Add ECHO_CXX.
900 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
901 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
902 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
903 (version-generated.c): Add ECHO_GEN.
904 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
905 (IPAGENT_COMPILE): Add ECHO_CXX.
906 (%-generated.c): Add ECHO_REGDAT.
907
908 2018-03-14 Tom Tromey <tom@tromey.com>
909
910 PR cli/14977:
911 * ax.c (ax_printf): Special case for NULL.
912
913 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
914
915 * linux-low.c (linux_qxfer_libraries_svr4): Use
916 xml_escape_text_append.
917
918 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
919
920 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
921
922 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
923
924 * server.c (handle_general_set): Remove unnecessary xstrdup.
925
926 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
927
928 * server.c (parse_debug_format_options): Adjust to
929 delim_string_to_char_ptr_vec changes.
930 * thread-db.c (thread_db_load_search): Adjust to
931 dirnames_to_char_ptr_vec changes.
932
933 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
934
935 * target.h (target_enable_btrace, target_disable_btrace)
936 (target_read_btrace, target_read_btrace_conf): Turn macro into
937 inline function. Throw error if target method is not defined.
938 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
939 check for btrace target method. Be prepared to handle exceptions
940 from btrace target methods.
941
942 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
943
944 * server.c (captured_main): Change order of error message printed
945 when the current working directory cannot be found.
946
947 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
948
949 * server.c: Include "filenames.h" and "pathstuff.h".
950 (program_name): Delete variable.
951 (program_path): New anonymous class.
952 (get_exec_wrapper): Use "program_path" instead of
953 "program_name".
954 (handle_v_run): Likewise.
955 (captured_main): Likewise.
956 (process_serial_event): Likewise.
957
958 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
959
960 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
961 (OBJS): Add "pathstuff.o".
962 * server.c (current_directory): New global variable.
963 (captured_main): Initialize "current_directory".
964
965 2018-02-26 Alan Hayward <alan.hayward@arm.com>
966
967 * tdesc.c: Use common/tdesc.h.
968 * tdesc.h: Likewise.
969
970 2018-02-20 Alan Hayward <alan.hayward@arm.com>
971 Simon Marchi <simon.marchi@ericsson.com>
972
973 * Makefile.in: Switch order of make rules.
974
975 2018-02-19 Alan Hayward <alan.hayward@arm.com>
976
977 * Makefile.in: Add common directory in build.
978 * configure.ac: Add common reference.
979 * configure: Regenerate.
980
981 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
982
983 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
984 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
985 * spu-low.c (spu_target_ops): Likewise.
986 * win32-low.c (win32_target_ops): Likewise.
987 * server.c (supported_btrace_packets): Report packets unconditionally.
988 * target.h (target_ops) <supports_btrace>: Remove.
989 (target_supports_btrace): Remove.
990
991 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
992
993 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
994 (handle_btrace_disable): Change return type to void. Use exceptions
995 to report errors.
996 (handle_btrace_general_set): Catch exception and copy message to
997 return message.
998
999 2018-02-08 Tom Tromey <tom@tromey.com>
1000
1001 * linux-low.c (install_software_single_step_breakpoints): Use
1002 make_scoped_restore.
1003 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1004 (do_restore_current_thread_cleanup): Remove.
1005 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1006 declare.
1007
1008 2018-02-08 Tom Tromey <tom@tromey.com>
1009
1010 * mem-break.c (set_raw_breakpoint_at): Use
1011 gdb::unique_xmalloc_ptr.
1012
1013 2018-01-30 Pedro Alves <palves@redhat.com>
1014
1015 PR gdb/13211
1016 * target.c (target_terminal::terminal_state): Rename to ...
1017 (target_terminal::m_terminal_state): ... this.
1018
1019 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1020
1021 * linux-low.c (handle_extended_wait): Surround call to
1022 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1023
1024 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1025
1026 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1027 linux_ptrace_attach_fail_reason_string now returning an
1028 std::string.
1029 (linux_attach): Likewise.
1030 * thread-db.c (attach_thread): Likewise.
1031
1032 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1033
1034 PR gdb/21559
1035 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1036 checking for fs_base/gs_base fields in struct user_regs_struct.
1037 * configure: Regenerate.
1038
1039 2018-01-16 Yao Qi <yao.qi@linaro.org>
1040
1041 PR gdb/18749
1042 * linux-low.c (fetch_register): Call supply_register instead of
1043 error.
1044
1045 2018-01-08 Yao Qi <yao.qi@linaro.org>
1046 Simon Marchi <simon.marchi@ericsson.com>
1047
1048 * Makefile.in (OBS): Remove selftest.o.
1049 * configure.ac: Set srv_selftest_objs if $development is true.
1050 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1051 * configure: Re-generated.
1052 * server.c (captured_main): Wrap variable selftest_filter with
1053 GDB_SELF_TEST.
1054
1055 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1056
1057 * server.c (parse_debug_format_options): Return std::string.
1058 (handle_monitor_command, captured_main): Adjust.
1059
1060 2018-01-05 Pedro Alves <palves@redhat.com>
1061
1062 PR gdb/18653
1063 * server.c (captured_main): Pass quiet=false to
1064 save_original_signals_state.
1065
1066 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1067
1068 * gdbreplay.c (gdbreplay_version): Update copyright year in
1069 version message.
1070 * server.c (gdbserver_version): Likewise.
1071
1072 2017-12-08 Tom Tromey <tom@tromey.com>
1073
1074 * ax.c (ax_printf): Update.
1075
1076 2017-12-07 Yao Qi <yao.qi@linaro.org>
1077
1078 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1079 aarch64_linux_read_description.
1080 * linux-amd64-ipa.c (idx2mask): New array.
1081 (get_ipa_tdesc): Move idx2mask out.
1082 (initialize_low_tracepoint): Initialize target descriptions.
1083 * linux-i386-ipa.c (idx2mask): New array.
1084 (get_ipa_tdesc): Move idx2mask out.
1085 (initialize_low_tracepoint): Initialize target descriptions.
1086
1087 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1088
1089 * tdesc.c (struct tdesc_type): Change return type.
1090 (tdesc_add_flag): Change parameter type.
1091 (tdesc_add_bitfield): Likewise.
1092 (tdesc_add_field): Likewise.
1093 (tdesc_set_struct_size): Likewise.
1094
1095 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1096
1097 * regcache.c (registers_to_string): Remove unused variable.
1098
1099 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1100
1101 * inferiors.c (for_each_inferior_with_data): Remove.
1102 * inferiors.h (for_each_inferior_with_data): Remove.
1103 * server.c (handle_qxfer_threads_worker): Change parameter type.
1104 (handle_qxfer_threads_proper): Use for_each_thread.
1105
1106 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1107
1108 * inferiors.c (for_each_inferior): Remove.
1109 (clear_inferiors): Use for_each_thread.
1110 * inferiors.h (for_each_inferior): Remove.
1111 * linux-low.c (linux_wait_for_event_filtered): Use
1112 for_each_thread.
1113 (linux_stabilize_threads): Likewise.
1114 * regcache.c (regcache_release): Likewise.
1115 * server.c (gdb_wants_all_threads_stopped): Likewise.
1116 (clear_pending_status_callback): Remove.
1117 (handle_status): Use for_each_thread.
1118 (captured_main): Likewise.
1119 * win32-low.c (child_init_thread_list): Likewise.
1120 (win32_clear_inferiors): Likewise.
1121 (fake_breakpoint_event): Likewise.
1122
1123 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1124
1125 * inferiors.h (find_inferior): Remove.
1126 * inferiors.c (find_inferior): Remove.
1127
1128 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1129
1130 * linux-low.c (resume_status_pending_p): Update comment.
1131 (need_step_over_p): Update comment.
1132
1133 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1134
1135 * linux-low.c (proceed_one_lwp): Return void, change parameter
1136 type.
1137 (unsuspend_and_proceed_one_lwp): Likewise.
1138 (proceed_all_lwps): Use for_each_thread.
1139 (unstop_all_lwps): Likewise.
1140
1141 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1142
1143 * linux-low.c (linux_resume_one_thread): Return void, take
1144 parameter directly.
1145 (linux_resume): Use for_each_thread.
1146
1147 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1148
1149 * linux-low.c (send_sigstop_callback): Return void, change
1150 parameter type. Rename to...
1151 (send_sigstop): ... this.
1152 (suspend_and_send_sigstop_callback): Return void, change parameter
1153 type. Rename to...
1154 (suspend_and_send_sigstop): ... this.
1155 (stop_all_lwps): Use for_each_thread.
1156
1157 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1158
1159 * linux-low.c (lwp_running): Return bool, remove unused
1160 argument.
1161 (linux_stabilize_threads): Use find_thread.
1162
1163 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1164
1165 * linux-low.c (select_singlestep_lwp_callback): Remove.
1166 (count_events_callback): Remove.
1167 (select_event_lwp_callback): Remove.
1168 (select_event_lwp): Use find_thread/for_each_thread.
1169
1170 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1171
1172 * linux-low.c (not_stopped_callback): Return bool, take filter
1173 argument directly.
1174 (linux_wait_for_event_filtered): Use find_thread.
1175 (linux_wait_1): Likewise.
1176
1177 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1178
1179 * linux-low.c (same_lwp): Remove.
1180 (find_lwp_pid): Use find_thread.
1181
1182 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1183
1184 * linux-low.c (delete_lwp_callback): Remove.
1185 (linux_mourn): Use for_each_thread.
1186
1187 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1188
1189 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1190 args parameter, don't check for pid.
1191 (linux_detach): Use for_each_thread.
1192
1193 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1194
1195 * linux-low.c (struct counter): Remove.
1196 (second_thread_of_pid_p): Remove.
1197 (last_thread_of_process_p): Use find_thread.
1198
1199 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1200
1201 * inferiors.c (find_inferior_in_random): Remove.
1202 * inferiors.h (find_inferior_in_random): Remove.
1203 * linux-low.c (status_pending_p_callback): Return bool, accept
1204 parameter ptid directly.
1205 (linux_wait_for_event_filtered): Use find_thread_in_random.
1206 (linux_wait_1): Likewise.
1207
1208 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1209
1210 * inferiors.c (find_inferior_id): Remove.
1211 (find_thread_ptid): Move implemention from find_inferior_id to
1212 here.
1213 * inferiors.h (find_inferior_id): Remove.
1214 * server.c (handle_status): Use find_thread_ptid.
1215 (process_serial_event): Likewise.
1216 * thread-db.c (find_one_thread): Likewise.
1217 (thread_db_thread_handle): Likewise.
1218 * win32-low.c (thread_rec): Likewise.
1219 (child_delete_thread): Likewise.
1220 (win32_thread_alive): Likewise.
1221 (get_child_debug_event): Likewise.
1222
1223 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1224
1225 * linux-mips-low.c (update_watch_registers_callback): Return
1226 void, remove pid_p parameter, don't check for pid.
1227 (mips_insert_point, mips_remove_point): Use for_each_thread.
1228
1229 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1230
1231 * lynx.low (lynx_delete_thread_callback): Remove.
1232 (lynx_mourn): Use for_each_thread.
1233
1234 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1235
1236 * regcache.c (regcache_invalidate_one): Remove.
1237 (regcache_invalidate_pid): use for_each_thread.
1238
1239 2017-11-26 Tom Tromey <tom@tromey.com>
1240
1241 * linux-low.c (linux_create_inferior): Update.
1242
1243 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1244
1245 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1246
1247 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1248
1249 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1250 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1251 * linux-aarch64-tdesc-selftest.c: New file.
1252 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1253
1254 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1255
1256 * configure.srv: Add new file.
1257 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1258 * linux-aarch64-tdesc-selftest.c: New file.
1259 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1260
1261 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1262
1263 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1264 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1265 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1266
1267 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1268
1269 * configure.srv: Add new files.
1270 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1271 aarch64_linux_read_description.
1272 * linux-aarch64-low.c (aarch64_linux_read_description):
1273 Merge with aarch64_arch_setup.
1274 (aarch64_arch_setup): Call aarch64_linux_read_description.
1275 * linux-aarch64-tdesc.c: New file.
1276 * linux-aarch64-tdesc.h: New file.
1277
1278 2017-11-24 Yao Qi <yao.qi@linaro.org>
1279
1280 * configure.srv: Set $srv_regobj for tic6x-linux.
1281 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1282 (tic6x_read_description): Move some code to tic6x_arch_setup.
1283 (tic6x_tdesc_test): New function.
1284 (initialize_low_arch): Call selftests::register_test.
1285
1286 2017-11-22 Yao Qi <yao.qi@linaro.org>
1287
1288 * remote-utils.c (prepare_resume_reply): Use memcpy.
1289
1290 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1291
1292 * linux-low.c (kill_one_lwp_callback): Return void, take
1293 argument directly, don't filter on pid.
1294 (linux_kill): Use for_each_thread.
1295
1296 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1297
1298 * linux-low.c (need_step_over_p): Return bool, remove dummy
1299 argument.
1300 (linux_resume, proceed_all_lwps): Use find_thread.
1301
1302 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1303
1304 * linux-low.c (resume_status_pending_p): Return bool, remove
1305 flag_p argument.
1306 (linux_resume): Use find_thread.
1307
1308 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1309
1310 * linux-low.c (struct thread_resume_array): Remove.
1311 (linux_set_resume_request): Return void, take arguments
1312 directly.
1313 (linux_resume): Use for_each_thread.
1314
1315 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1316
1317 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1318 return bool, remove data argument.
1319 (linux_stabilize_threads): Use find_thread.
1320
1321 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1322
1323 * linux-low.c (unsuspend_one_lwp): Remove.
1324 (unsuspend_all_lwps): Use for_each_thread, inline code from
1325 unsuspend_one_lwp.
1326
1327 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1328
1329 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1330 * linux-low.c (struct iterate_over_lwps_args): Remove.
1331 (iterate_over_lwps_filter): Remove.
1332 (iterate_over_lwps): Use find_thread.
1333
1334 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1335
1336 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1337 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1338 code from reset_lwp_ptrace_options_callback.
1339
1340 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1341
1342 * linux-arm-low.c (struct update_registers_data): Remove.
1343 (update_registers_callback): Return void, take arguments
1344 directly, don't check thread's pid.
1345 (arm_insert_point, arm_remove_point): Use for_each_thread.
1346
1347 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1348
1349 * win32-low.c (continue_one_thread): Return void, take argument
1350 directly.
1351 (child_continue): Use for_each_thread.
1352
1353 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1354
1355 * win32-i386-low.c (update_debug_registers_callback): Rename
1356 to ...
1357 (update_debug_registers): ... this, return void, remove pid_p arg.
1358 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1359
1360 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1361
1362 * inferiors.h (struct process_info): Add constructor, initialize
1363 fields..
1364 <syscalls_to_catch>: Change type to std::vector<int>.
1365 * inferiors.c (add_process): Allocate process_info with new.
1366 (remove_process): Free process_info with delete.
1367 * linux-low.c (handle_extended_wait): Adjust.
1368 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1369 * server.c (handle_general_set): Adjust.
1370
1371 2017-11-16 Pedro Alves <palves@redhat.com>
1372
1373 * remote-utils.c (remote_close): Block SIGIO signals instead of
1374 uninstalling the SIGIO handler.
1375
1376 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1377
1378 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1379
1380 2017-11-16 Yao Qi <yao.qi@linaro.org>
1381
1382 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1383 (tic6x_store_gregset): Likewise.
1384 (tic6x_usrregs_info): Move it up.
1385
1386 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1387
1388 * Makefile.in: Update arch rules.
1389 * configure.srv: Explicitly mark arch/ files.
1390
1391 2017-11-13 Andreas Schwab <schwab@suse.de>
1392
1393 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1394 function.
1395 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1396
1397 2017-11-06 Pedro Alves <palves@redhat.com>
1398
1399 * config.in, configure: Regenerate.
1400
1401 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1402
1403 * target.c (struct thread_search): Remove.
1404 (thread_search_callback): Remove.
1405 (prepare_to_access_memory): Use for_each_thread instead of
1406 find_inferior. Inline code from thread_search_callback.
1407
1408 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1409
1410 * server.c (struct visit_actioned_threads_data): Remove.
1411 (visit_actioned_threads): Change prototype to take arguments
1412 directly.
1413 (resume): Use find_thread instead of find_inferior.
1414
1415 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1416
1417 * server.c (queue_stop_reply_callback): Change prototype, return
1418 void.
1419 (find_status_pending_thread_callback): Remove.
1420 (handle_status): Replace find_inferior with find_thread and
1421 for_each_thread.
1422
1423 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1424
1425 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1426 with REGNO.
1427 (aarch64_store_gregset): Likewise.
1428 (aarch64_fill_fpregset): Likewise.
1429 (aarch64_store_fpregset): Likewise.
1430
1431 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1432
1433 * gdbthread.h (find_thread, for_each_thread): New functions.
1434 * inferiors.c (thread_of_pid): Remove.
1435 (find_any_thread_of_pid): Use find_thread.
1436 * linux-low.c (num_lwps): Use for_each_thread.
1437
1438 2017-10-17 Yao Qi <yao.qi@linaro.org>
1439
1440 * Makefile.in: Remove one rule.
1441 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1442
1443 2017-10-17 Yao Qi <yao.qi@linaro.org>
1444
1445 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1446 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1447
1448 2017-10-17 Yao Qi <yao.qi@linaro.org>
1449
1450 * configure.srv: Rename arm.o with arch/arm.o.
1451
1452 2017-10-17 Yao Qi <yao.qi@linaro.org>
1453
1454 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1455 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1456 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1457 (arch-i386.o, arch-amd64.o): Remove rules.
1458 (arch/%.o): New rule.
1459 Update POSTCOMPILE and COMPILE.pre.
1460 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1461 * configure: Re-generated.
1462 * configure.srv: Replace arch-i386.o with arch/i386.o.
1463 Replace arch-amd64.o with arch/amd64.o.
1464
1465 2017-10-16 Yao Qi <yao.qi@linaro.org>
1466
1467 * configure: Regenerated.
1468
1469 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1470
1471 * inferiors.h: (struct inferior_list): Remove.
1472 (struct inferior_list_entry); Remove.
1473 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
1474 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
1475 get_first_inferior): Remove.
1476 (for_each_inferior, for_each_inferior_with_data, find_inferior,
1477 find_inferior_id, find_inferior_in_random): Change signature.
1478 * inferiors.c (all_threads): Change type to
1479 std::list<thread_info *>.
1480 (get_thread): Remove macro.
1481 (find_inferior, find_inferior_id): Change signature, implement
1482 using find_thread.
1483 (find_inferior_in_random): Change signature, implement using
1484 find_thread_in_random.
1485 (for_each_inferior, for_each_inferior_with_data): Change
1486 signature, implement using for_each_thread.
1487 (add_inferior_to_list, remove_inferior): Remove.
1488 (add_thread, get_first_thread, thread_of_pid,
1489 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
1490 (get_first_inferior, one_inferior_p, clear_inferior_list):
1491 Remove.
1492 (clear_inferiors, get_thread_process): Update.
1493 * gdbthread.h: Include <list>.
1494 (struct thread_info) <entry>: Remove field.
1495 <id>: New field.
1496 (all_threads): Change type to std::list<thread_info *>.
1497 (get_first_inferior): Add doc.
1498 (find_thread, for_each_thread, find_thread_in_random): New
1499 functions.
1500 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
1501 * linux-arm-low.c (update_registers_callback): Update.
1502 * linux-low.c (second_thread_of_pid_p): Update.
1503 (kill_one_lwp_callback, linux_detach_lwp_callback,
1504 delete_lwp_callback, status_pending_p_callback, same_lwp,
1505 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
1506 iterate_over_lwps, not_stopped_callback,
1507 resume_stopped_resumed_lwps, count_events_callback,
1508 select_singlestep_lwp_callback, select_event_lwp_callback,
1509 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
1510 suspend_and_send_sigstop_callback, wait_for_sigstop,
1511 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
1512 lwp_running, linux_set_resume_request, resume_status_pending_p,
1513 need_step_over_p, start_step_over, linux_resume_one_thread,
1514 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
1515 reset_lwp_ptrace_options_callback): Update.
1516 * linux-mips-low.c (update_watch_registers_callback): Update.
1517 * regcache.c (regcache_invalidate_one, regcache_invalidate):
1518 Update.
1519 (free_register_cache_thread_one): Remove.
1520 (regcache_release): Update.
1521 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
1522 handle_qxfer_threads_worker): Update.
1523 (handle_query): Update, use list iterator.
1524 (visit_actioned_threads, handle_pending_status,
1525 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
1526 clear_pending_status_callback, set_pending_status_callback,
1527 find_status_pending_thread_callback, handle_status,
1528 process_serial_event): Update.
1529 * target.c (thread_search_callback): Update.
1530 * thread-db.c (thread_db_get_tls_address): Update.
1531 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
1532 Update.
1533 * win32-i386-low.c (update_debug_registers_callback): Update.
1534 * win32-low.c (delete_thread_info, child_delete_thread,
1535 continue_one_thread, suspend_one_thread,
1536 get_child_debug_event): Adjust.
1537
1538 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1539
1540 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
1541 * inferiors.h: Include <list>.
1542 (struct process_info) <entry>: Remove field.
1543 <pid>: New field.
1544 (pid_of): Change macro to function.
1545 (ptid_of, lwpid_of): Remove macro.
1546 (all_processes): Change type to std::list<process_info *>.
1547 (ALL_PROCESSES): Remove macro.
1548 (for_each_process, find_process): New function.
1549 * inferiors.c (all_processes): Change type to
1550 std::list<process_info *>.
1551 (find_thread_process): Adjust.
1552 (add_process): Likewise.
1553 (remove_process): Likewise.
1554 (find_process_pid): Likewise.
1555 (get_first_process): Likewise.
1556 (started_inferior_callback): Remove.
1557 (have_started_inferiors_p): Adjust.
1558 (attached_inferior_callback): Remove.
1559 (have_attached_inferiors_p): Adjust.
1560 * linux-low.c (check_zombie_leaders): Likewise.
1561 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
1562 (x86_linux_update_xmltarget): Adjust.
1563 * server.c (handle_query): Likewise.
1564 (gdb_reattached_process): Remove.
1565 (handle_status): Adjust.
1566 (kill_inferior_callback): Likewise.
1567 (detach_or_kill_inferior): Remove.
1568 (print_started_pid): Likewise.
1569 (print_attached_pid): Likewise.
1570 (detach_or_kill_for_exit): Update.
1571 (process_serial_event): Likewise.
1572 * linux-arm-low.c (arm_new_fork): Likewise.
1573
1574 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1575
1576 * dll.h: Include <list>.
1577 (struct dll_info): Add constructor.
1578 <entry>: Remove field.
1579 (all_dlls): Change type to std::list<dll_info>.
1580 * dll.c: Include <algorithm>.
1581 (get_dll): Remove macro.
1582 (all_dlls): Change type to std::list<dll_info *>.
1583 (free_one_dll): Remove.
1584 (match_dll): Likewise.
1585 (loaded_dll): Adjust.
1586 (unloaded_dll): Adjust to all_dlls type change, use
1587 std::find_if. Inline code from match_dll.
1588 (clear_dlls): Adjust to all_dlls type change.
1589 * server.c (emit_dll_description): Remove.
1590 (handle_qxfer_libraries): Adjust to all_dlls type change,
1591 integrate emit_dll_description's functionality.
1592
1593 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1594
1595 * linux-low.h (struct linux_target_ops) <delete_process>: New
1596 field.
1597 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
1598 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
1599 (struct linux_target_ops): Add delete_process callback.
1600 * linux-arm-low.c (arm_delete_process): New.
1601 (struct linux_target_ops): Add delete_process callback.
1602 * linux-bfin-low.c (struct linux_target_ops): Likewise.
1603 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
1604 * linux-m32r-low.c (struct linux_target_ops): Likewise.
1605 * linux-mips-low.c (mips_linux_delete_process): New.
1606 (struct linux_target_ops): Add delete_process callback.
1607 * linux-ppc-low.c (struct linux_target_ops): Likewise.
1608 * linux-s390-low.c (struct linux_target_ops): Likewise.
1609 * linux-sh-low.c (struct linux_target_ops): Likewise.
1610 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
1611 * linux-tile-low.c (struct linux_target_ops): Likewise.
1612 * linux-x86-low.c (x86_linux_delete_process): New.
1613 (struct linux_target_ops): Add delete_process callback.
1614 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
1615
1616 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1617
1618 * linux-aarch64-low.c (the_low_target): Add thread delete
1619 callback.
1620 * linux-arm-low.c (arm_delete_thread): New function.
1621 (the_low_target): Add thread delete callback.
1622 * linux-bfin-low.c (the_low_target): Likewise.
1623 * linux-crisv32-low.c (the_low_target): Likewise.
1624 * linux-low.c (delete_lwp): Invoke delete_thread callback if
1625 set.
1626 * linux-low.h (struct linux_target_ops) <delete_thread>: New
1627 field.
1628 * linux-m32r-low.c (the_low_target): Add thread delete callback.
1629 * linux-mips-low.c (mips_linux_delete_thread): New function.
1630 (the_low_target): Add thread delete callback.
1631 * linux-ppc-low.c (the_low_target): Likewise.
1632 * linux-s390-low.c (the_low_target): Likewise.
1633 * linux-sh-low.c (the_low_target): Likewise.
1634 * linux-tic6x-low.c (the_low_target): Likewise.
1635 * linux-tile-low.c (the_low_target): Likewise.
1636 * linux-x86-low.c (the_low_target): Likewise.
1637 * linux-xtensa-low.c (the_low_target): Likewise.
1638
1639 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
1640
1641 * win32-low.c: Include "common-inferior.h".
1642
1643 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1644
1645 * inferiors.c (set_inferior_cwd): New function.
1646 * server.c (handle_general_set): Handle QSetWorkingDir packet.
1647 (handle_query): Inform that QSetWorkingDir is supported.
1648 * win32-low.c (create_process): Pass the inferior's cwd to
1649 CreateProcess.
1650
1651 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1652
1653 * inferiors.c (current_inferior_cwd): New global variable.
1654 (get_inferior_cwd): New function.
1655 * inferiors.h (struct process_info) <cwd>: New field.
1656
1657 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1658
1659 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
1660 (OBS): Add gdb_tilde_expand.o.
1661
1662 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
1663
1664 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
1665 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
1666
1667 2017-09-29 Pedro Alves <palves@redhat.com>
1668
1669 * ax.c (gdb_parse_agent_expr): Constify.
1670 * ax.h (gdb_parse_agent_expr): Constify.
1671 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
1672 Constify.
1673 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
1674 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
1675 * remote-utils.h (read_ptid): Constify.
1676 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
1677 (process_point_options, process_serial_event): Constify.
1678 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
1679 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
1680 (cmd_qtbuffer): Constify.
1681
1682 2017-09-29 Pedro Alves <palves@redhat.com>
1683
1684 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
1685 fails.
1686
1687 2017-09-29 Pedro Alves <palves@redhat.com>
1688
1689 * linux-low.c (handle_extended_wait): Pass parent thread instead
1690 of process to thread_db_notice_clone.
1691 * linux-low.h (thread_db_notice_clone): Replace parent process
1692 parameter with parent thread parameter.
1693 * thread-db.c (find_one_thread): Add comment.
1694 (thread_db_notice_clone): Replace parent process parameter with
1695 parent thread parameter. Temporarily switch to the parent thread.
1696
1697 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
1698
1699 * gdbthread.h: Include "common-gdbthread.h".
1700 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
1701 "if" when validating the ptid.
1702 * remote-utils.c: Include "gdbthread.h".
1703 (prepare_resume_reply): Use "switch_to_thread".
1704 * target.c (done_accessing_memory): Likewise.
1705
1706 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1707
1708 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
1709 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
1710 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
1711 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
1712 s390x-gs-linux64-ipa.o to ipa_obj.
1713 * linux-s390-low.c (HWCAP_S390_GS): New define.
1714 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
1715 New functions.
1716 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
1717 (s390_arch_setup): Check for guarded-storage support and choose
1718 appropriate tdesc.
1719 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
1720 init_registers_s390x_gs_linux64.
1721 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
1722 enum value.
1723 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
1724 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
1725
1726 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
1727
1728 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
1729
1730 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1731
1732 * linux-low.h (struct lwp_info): Add new field, thread_handle.
1733 (thread_db_thread_handle): Declare.
1734 * linux-low.c (linux_target_ops): Initialize thread_handle.
1735 * server.c (handle_qxfer_threads_worker): Add support for
1736 "handle" attribute.
1737 * target.h (struct target_ops): Add new function pointer,
1738 thread_handle.
1739 (target_thread_handle): Define.
1740 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
1741 field in lwp.
1742 (thread_db_thread_handle): New function.
1743
1744 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1745
1746 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
1747 * linux-low.h (thread_db_notice_clone): Declare.
1748 * thread-db.c (thread_db_notice_clone): New function.
1749
1750 2017-09-21 Pedro Alves <palves@redhat.com>
1751
1752 * server.c (gdb_read_memory, handle_status, process_serial_event)
1753 (handle_serial_event, handle_target_event): Adjust to
1754 set_desired_thread prototype change.
1755 * target.c (set_desired_thread): Remove 'use_general' parameter
1756 and adjust.
1757 * target.h (set_desired_thread): Remove 'use_general' parameter.
1758
1759 2017-09-20 Tom Tromey <tom@tromey.com>
1760
1761 * target.c (target_terminal::terminal_state): Define.
1762 (target_terminal::init): Rename from target_terminal_init.
1763 (target_terminal::inferior): Rename from
1764 target_terminal_inferior.
1765 (target_terminal::ours): Rename from target_terminal_ours.
1766 (target_terminal::ours_for_output, target_terminal::info): New.
1767
1768 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1769
1770 * server.c (accumulate_file_name_length): Remove.
1771 (emit_dll_description): Adjust to std::string change.
1772 (handle_qxfer_libraries): Use std::string to hold document.
1773
1774 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1775
1776 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
1777 return type of xml_escape_text.
1778 * server.c (emit_dll_description): Likewise.
1779
1780 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1781
1782 * server.c (captured_main): Accept argument for --selftest.
1783 Update run_tests call.
1784 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
1785 when registering selftests.
1786
1787 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
1788
1789 * regcache.c (get_thread_regcache): Update code to use "std::vector"
1790 instead of "VEC" for "target_desc.reg_defs".
1791 (regcache_cpy): Likewise.
1792 (registers_to_string): Likewise.
1793 (registers_from_string): Likewise.
1794 (find_regno): Likewise.
1795 (supply_regblock): Likewise.
1796 (regcache_raw_read_unsigned): Likewise.
1797 * tdesc.c (init_target_desc): Likewise.
1798 (tdesc_create_reg): Likewise.
1799 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
1800 (struct target_desc) <reg_defs>: Convert to "std::vector".
1801 (target_desc): Do not initialize "reg_defs".
1802 (~target_desc): Update code to use "std::vector" instead of "VEC"
1803 for "target_desc.reg_defs".
1804 (operator==): Likewise.
1805
1806 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1807
1808 * inferiors.h (thread_to_gdb_id): Remove.
1809 * inferiors.c (thread_to_gdb_id): Remove.
1810 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
1811 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
1812 lynx_store_registers, lynx_read_memory, lynx_write_memory):
1813 Likewise.
1814 * nto-low.c (nto_fetch_registers, nto_store_registers,
1815 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
1816
1817 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1818
1819 * inferiors.h (gdb_id_to_thread_id): Remove.
1820 * inferiors.c (gdb_id_to_thread_id): Remove.
1821 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
1822 removal. Move pid declaration closer to where it's used.
1823
1824 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1825
1826 * server.c (handle_detach): New function.
1827 (process_serial_event): Move code out, call handle_detach.
1828
1829 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1830
1831 * server.c (require_running): Rename to ...
1832 (require_running_or_return): ... this ...
1833 (require_running_or_break): ... and this.
1834 (handle_query, process_serial_event): Adjust.
1835
1836 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1837
1838 * linux-low.c (linux_set_resume_request): Remove unused
1839 variables.
1840
1841 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1842
1843 * server.c (first_thread_of): Remove.
1844 (process_serial_event): Replace usage of first_thread_of with
1845 find_any_thread_of_pid.
1846 * tracepoint.c (same_process_p): Remove.
1847 (gdb_agent_about_to_close): Replace usage of same_process_p with
1848 find_any_thread_of_pid.
1849 * linux-x86-low.c (same_process_callback): Remove.
1850 (x86_arch_setup_process_callback): Replace usage of
1851 same_process_callback with find_any_thread_of_pid.
1852 * thread-db.c (any_thread_of): Remove.
1853 (switch_to_process): Replace usage of any_thread_of with
1854 find_any_thread_of_pid.
1855 * inferiors.c (thread_pid_matches_callback): Remove.
1856 (find_thread_process): Adjust to use find_any_thread_of_pid.
1857
1858 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1859
1860 * regcache.c (get_thread_regcache): Guard calls to "memset"
1861 with "!VEC_empty".
1862
1863 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1864
1865 * linux-low.c (handle_extended_wait): Use
1866 "allocate_target_description" instead of "XNEW".
1867 * linux-x86-low.c (initialize_low_arch): Likewise.
1868
1869 2017-09-05 Yao Qi <yao.qi@linaro.org>
1870
1871 * configure.srv (srv_i386_regobj): Remove.
1872 (srv_amd64_regobj): Remove.
1873 (srv_regobj): Set it to "" for x86 non-linux targets.
1874 * linux-x86-tdesc.c (i386_linux_read_description):
1875 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
1876 (init_registers_i386): Remove the declaration.
1877 (tdesc_i386): Remove the declaration.
1878 (lynx_i386_arch_setup): Call i386_create_target_description.
1879 * nto-x86-low.c: Likewise.
1880 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
1881 [!__x86_64__]: include arch/i386.h.
1882 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
1883
1884 2017-09-05 Yao Qi <yao.qi@linaro.org>
1885
1886 * configure.srv (srv_amd64_linux_xmlfiles): Remove
1887 i386/amd64-XXX-linux from it.
1888
1889 2017-09-05 Yao Qi <yao.qi@linaro.org>
1890
1891 * configure.srv: Empty srv_amd64_linux_regobj if $development is
1892 false.
1893 (ipa_amd64_linux_regobj): Remove.
1894 (ipa_x32_linux_regobj): Remove.
1895
1896 2017-09-05 Yao Qi <yao.qi@linaro.org>
1897
1898 * Makefile.in (arch-amd64.o): New rule.
1899 * configure.srv: Append arch-amd64.o.
1900 * linux-amd64-ipa.c: Include common/x86-xstate.h.
1901 (get_ipa_tdesc): Call amd64_linux_read_description.
1902 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
1903 and init_registers_amd64_XXX.
1904 * linux-x86-low.c (x86_linux_read_description): Call
1905 amd64_linux_read_description.
1906 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
1907 (initialize_low_arch): Don't call init_registers_x32_XXX and
1908 init_registers_amd64_XXX.
1909 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
1910 and tdesc_amd64_XXX.
1911 [__x86_64__] (amd64_tdesc_test): New function.
1912 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
1913 and init_registers_amd64_XXX.
1914 * linux-x86-tdesc.c: Include arch/amd64.h.
1915 (xcr0_to_tdesc_idx): New function.
1916 (i386_linux_read_description): New function.
1917 (amd64_get_ipa_tdesc_idx): New function.
1918 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
1919 (amd64_get_ipa_tdesc): Declare.
1920
1921 2017-09-05 Yao Qi <yao.qi@linaro.org>
1922
1923 * configure.srv (srv_i386_linux_xmlfiles): Remove
1924 i386/i386-XXX-linux.xml from it.
1925
1926 2017-09-05 Yao Qi <yao.qi@linaro.org>
1927
1928 * configure.srv: Set srv_i386_linux_regobj empty if $development
1929 is false.
1930 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
1931 initialize_low_tdesc.
1932 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
1933 with #if initialize_low_tdesc.
1934 * linux-x86-tdesc-selftest.c: New file.
1935 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
1936
1937 2017-09-05 Yao Qi <yao.qi@linaro.org>
1938
1939 * Makefile.in (arch-i386.o): New rule.
1940 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
1941 (x86_64-*-linux*): Likewise.
1942 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
1943 include arch/i386.h.
1944 (i386_linux_read_description): Remove code and call
1945 i386_create_target_description.
1946 * tdesc.c (allocate_target_description): New function.
1947 * tdesc.h (set_tdesc_architecture): Remove declaration.
1948 (set_tdesc_osabi): Likewise.
1949
1950 2017-09-05 Yao Qi <yao.qi@linaro.org>
1951
1952 * linux-x86-tdesc.c: Don't include <inttypes.h>.
1953 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
1954 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
1955 .xmltarget.
1956 * server.c (get_features_xml): Call tdesc_get_features_xml.
1957 * tdesc.c (set_tdesc_architecture): New function.
1958 (set_tdesc_osabi): New function.
1959 (tdesc_get_features_xml): New function.
1960 (tdesc_create_feature): Add an argument.
1961 * tdesc.h (struct target_desc) <features>: New field.
1962 <arch, osabi>: New field.
1963 (~target_desc): xfree features, arch, and osabi.
1964 (target_desc::oerator==): Don't compare .xmltarget.
1965 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
1966 (set_tdesc_osabi): Likewise.
1967 (tdesc_get_features_xml): Likewise.
1968
1969 2017-09-05 Yao Qi <yao.qi@linaro.org>
1970
1971 * linux-x86-tdesc.c: Include selftest.h.
1972 (i386_tdesc_test): New function.
1973 (initialize_low_tdesc): Call selftests::register_test.
1974 * tdesc.h: Include regdef.h.
1975 (target_desc): Override operator == and !=.
1976
1977 2017-09-05 Yao Qi <yao.qi@linaro.org>
1978
1979 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
1980 (ipa_obj): Likewise.
1981 * linux-i386-ipa.c: Include common/x86-xstate.h
1982 (get_ipa_tdesc): Call i386_linux_read_description.
1983 (initialize_low_tracepoint): Don't call init_registers_XXX
1984 functions, call initialize_low_tdesc instead.
1985 * linux-x86-low.c (x86_linux_read_description): Call
1986 i386_linux_read_description.
1987 (initialize_low_arch): Don't call init_registers_i386_XXX
1988 functions, call initialize_low_tdesc.
1989 * linux-x86-tdesc.c: New file.
1990 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
1991 (i386_get_ipa_tdesc_idx): Declare.
1992 (i386_get_ipa_tdesc): Declare.
1993 (initialize_low_tdesc): Declare.
1994
1995 2017-09-05 Yao Qi <yao.qi@linaro.org>
1996
1997 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
1998 instead of 0.
1999
2000 2017-09-05 Yao Qi <yao.qi@linaro.org>
2001
2002 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2003 * regcache.c (get_thread_regcache): Use VEC_length.
2004 (init_register_cache): Likewise.
2005 (regcache_cpy): Likewise.
2006 (registers_to_string): Iterate reg_defs via VEC_iterate.
2007 (find_regno): Likewise.
2008 (find_register_by_number): Use VEC_index.
2009 (register_size): Call find_register_by_number.
2010 (register_data): Call find_register_by_number.
2011 (supply_regblock): Use VEC_length.
2012 (regcache_raw_read_unsigned): Likewise.
2013 * tdesc.c (init_target_desc): Iterate reg_defs via
2014 VEC_iterate.
2015 (default_description): Update initializer.
2016 (copy_target_description): Don't update field num_registers.
2017 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2018 <num_registers>: Remove.
2019
2020 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2021
2022 * Makefile.in (.SECONDARY): Define target.
2023
2024 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2025
2026 * linux-low.c (linux_wait_1): Adjust.
2027 * server.c (queue_stop_reply_callback): Adjust.
2028
2029 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2030
2031 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2032 QEnvironmentUnset and QEnvironmentReset packets.
2033 (handle_query): Inform remote that QEnvironmentHexEncoded,
2034 QEnvironmentUnset and QEnvironmentReset are supported.
2035
2036 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2037
2038 * inferiors.h (inferior_target_data): Rename to ...
2039 (thread_target_data): ... this.
2040 (inferior_regcache_data): Rename to ...
2041 (thread_regcache_data): ... this.
2042 (set_inferior_regcache_data): Rename to ...
2043 (set_thread_regcache_data): ... this.
2044 * inferiors.c (inferior_target_data): Rename to ...
2045 (thread_target_data): ... this.
2046 (inferior_regcache_data): Rename to ...
2047 (thread_regcache_data): ... this.
2048 (set_inferior_regcache_data): Rename to ...
2049 (set_thread_regcache_data): ... this.
2050 (free_one_thread): Update.
2051 * linux-low.h (get_thread_lwp): Update.
2052 * regcache.c (get_thread_regcache): Update.
2053 (regcache_invalidate_thread): Update.
2054 (free_register_cache_thread): Update.
2055 * win32-i386-low.c (update_debug_registers_callback): Update.
2056 (win32_get_current_dr): Update.
2057 * win32-low.c (thread_rec): Update.
2058 (delete_thread_info): Update.
2059 (continue_one_thread): Update.
2060 (suspend_one_thread): Update.
2061
2062 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2063
2064 * inferiors.c (set_inferior_target_data): Remove.
2065 * inferiors.h (set_inferior_target_data): Remove.
2066
2067 2017-08-18 Yao Qi <yao.qi@linaro.org>
2068
2069 * Makefile.in (OBS): Add selftest.o.
2070 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2071 * configure, config.in: Re-generated.
2072 * server.c: Include common/sefltest.h.
2073 (captured_main): Handle option --selftest.
2074
2075 2017-08-09 Yao Qi <yao.qi@linaro.org>
2076
2077 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2078 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2079 i386-avx-mpx.o and i386-mmx.o.
2080 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2081 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2082 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2083 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2084 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2085 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2086 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2087 i386/amd64-avx-mpx.xml.
2088
2089 2017-08-09 Yao Qi <yao.qi@linaro.org>
2090
2091 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2092 and x32-avx-avx512.o.
2093 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2094 i386/x32-avx-avx512.xml.
2095
2096 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2097
2098 * tracepoint.h (enum class fast_tpoint_collect_result): New
2099 enumeration.
2100 (fast_tracepoint_collecting): Change return type to
2101 fast_tpoint_collect_result.
2102 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2103 * linux-low.h: Include tracepoint.h.
2104 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2105 fast_tpoint_collect_result.
2106 * linux-low.c (handle_tracepoints): Adjust.
2107 (linux_fast_tracepoint_collecting): Change return type to
2108 fast_tpoint_collect_result.
2109 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2110 linux_wait_1, stuck_in_jump_pad_callback,
2111 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2112 proceed_one_lwp): Adjust to type change.
2113
2114 2017-07-10 Yao Qi <yao.qi@linaro.org>
2115
2116 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2117
2118 2017-06-29 Yao Qi <yao.qi@linaro.org>
2119
2120 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2121 Remove.
2122 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2123
2124 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2125
2126 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2127
2128 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2129
2130 * linux-low.c (linux_create_inferior): Adjust code to access the
2131 environment information via 'gdb_environ' class.
2132 * lynx-low.c (lynx_create_inferior): Likewise.
2133 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2134 (get_environ): Return a pointer to 'our_environ'.
2135 (captured_main): Initialize 'our_environ'.
2136 * server.h (get_environ): Adjust prototype.
2137 * spu-low.c (spu_create_inferior): Adjust code to access the
2138 environment information via 'gdb_environ' class.
2139
2140 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2141
2142 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2143 usage of "register" keyword.
2144
2145 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2146
2147 * configure: Re-generate.
2148
2149 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2150
2151 * configure: Re-generate.
2152
2153 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2154
2155 * Makefile.in (COMPILE.pre): Add "-x c++".
2156
2157 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2158
2159 * fork-child.c: Conditionally include <signal.h>.
2160
2161 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2162
2163 * server.c (handle_general_set): Handle new packet
2164 "QStartupWithShell".
2165 (handle_query): Add "QStartupWithShell" to the list of supported
2166 packets.
2167 (gdbserver_usage): Add help text explaining the
2168 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2169 options.
2170 (captured_main): Recognize and act upon the presence of the new
2171 CLI options.
2172
2173 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2174 Pedro Alves <palves@redhat.com>
2175
2176 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2177 * configure: Regenerate.
2178 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2179 "fork-inferior.o".
2180 (i[34567]86-*-lynxos*): Likewise.
2181 (spu*-*-*): Likewise.
2182 * fork-child.c: New file.
2183 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2184 and "environ.h".
2185 (linux_ptrace_fun): New function.
2186 (linux_create_inferior): Adjust function prototype to reflect
2187 change on "target.h". Adjust function code to use
2188 "fork_inferior".
2189 (linux_request_interrupt): Delete "signal_pid".
2190 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2191 (lynx_ptrace_fun): New function.
2192 (lynx_create_inferior): Adjust function prototype to reflect
2193 change on "target.h". Adjust function code to use
2194 "fork_inferior".
2195 * nto-low.c (nto_create_inferior): Adjust function prototype and
2196 code to reflect change on "target.h". Update comments.
2197 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2198 "common-terminal.h" and "environ.h".
2199 (terminal_fd): Moved to fork-child.c.
2200 (old_foreground_pgrp): Likewise.
2201 (restore_old_foreground_pgrp): Likewise.
2202 (last_status): Make it global.
2203 (last_ptid): Likewise.
2204 (our_environ): New variable.
2205 (startup_with_shell): Likewise.
2206 (program_name): Likewise.
2207 (program_argv): Rename to...
2208 (program_args): ...this.
2209 (wrapper_argv): New variable.
2210 (start_inferior): Delete function.
2211 (get_exec_wrapper): New function.
2212 (get_exec_file): Likewise.
2213 (get_environ): Likewise.
2214 (prefork_hook): Likewise.
2215 (post_fork_inferior): Likewise.
2216 (postfork_hook): Likewise.
2217 (postfork_child_hook): Likewise.
2218 (handle_v_run): Update code to deal with arguments coming from the
2219 remote host. Update calls from "start_inferior" to
2220 "create_inferior".
2221 (captured_main): Likewise. Initialize environment variable. Call
2222 "have_job_control".
2223 * server.h (post_fork_inferior): New prototype.
2224 (get_environ): Likewise.
2225 (last_status): Declare.
2226 (last_ptid): Likewise.
2227 (signal_pid): Likewise.
2228 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2229 (spu_ptrace_fun): New function.
2230 (spu_create_inferior): Adjust function prototype to reflect change
2231 on "target.h". Adjust function code to use "fork_inferior".
2232 * target.c (target_terminal_init): New function.
2233 (target_terminal_inferior): Likewise.
2234 (target_terminal_ours): Likewise.
2235 * target.h: Include <vector>.
2236 (struct target_ops) <create_inferior>: Update prototype.
2237 (create_inferior): Update macro.
2238 * utils.c (gdb_flush_out_err): New function.
2239 * win32-low.c (win32_create_inferior): Adjust function prototype
2240 and code to reflect change on "target.h".
2241
2242 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2243
2244 * inferiors.c (switch_to_thread): New function.
2245
2246 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2247
2248 * Makefile.in (SFILE): Add "common/job-control.c".
2249 (OBS): Add "job-control.o".
2250
2251 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2252
2253 * Makefile: Remove "@host_makefile_frag@".
2254
2255 2017-05-05 Pedro Alves <palves@redhat.com>
2256
2257 * configure: Regenerate.
2258
2259 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2260
2261 * configure: Regenerate.
2262
2263 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2264
2265 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2266 software_single_step change of return type to
2267 std::vector<CORE_ADDR>.
2268 * linux-low.c (install_software_single_step_breakpoints):
2269 Likewise.
2270 * linux-low.h (install_software_single_step_breakpoints):
2271 Likewise.
2272
2273 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2274
2275 * remote-utils.c: Include "gdb_termios.h" instead of
2276 "terminal.h".
2277 * terminal.h: Delete file.
2278
2279 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2280
2281 * server.c: Include <vector>.
2282 <program_argv, wrapper_argv>: Convert to std::vector.
2283 (start_inferior): Rewrite function to use C++.
2284 (handle_v_run): Likewise. Update code that calculates the argv
2285 based on the vRun packet; use C++.
2286 (captured_main): Likewise.
2287
2288 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2289
2290 * server.c (handle_v_cont): Initialize thread_resume::thread
2291 with null_ptid.
2292
2293 2017-04-05 Pedro Alves <palves@redhat.com>
2294
2295 * configure: Regenerate.
2296
2297 2017-04-05 Pedro Alves <palves@redhat.com>
2298
2299 * gdbreplay.c (sync_error): Constify.
2300 * linux-x86-low.c (push_opcode): Constify.
2301
2302 2017-04-05 Pedro Alves <palves@redhat.com>
2303
2304 * win32-low.c (get_child_debug_event)
2305 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2306 Report TARGET_WAITKIND_SPURIOUS instead.
2307
2308 2017-04-05 Pedro Alves <palves@redhat.com>
2309
2310 * remote-utils.c (remote_prepare, remote_open): Constify.
2311 * remote-utils.h (remote_prepare, remote_open): Constify.
2312 * server.c (captured_main): Constify 'port' handling.
2313
2314 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2315
2316 * Makefile.in (clean): Clear .deps.
2317
2318 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2319
2320 * .gitignore: Remove generated files, replace with wildcard.
2321 * (clean): Replace removal of generated files with wildcard.
2322 (version.c): Replace with...
2323 (version-generated.c): ...this.
2324 (xml-builtin.c): Replace with...
2325 (xml-builtin-generated.c): ...this.
2326 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2327 (%.c: *regformats*): Replace with...
2328 (%-generated.c: *regformats*): ...this.
2329
2330 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2331
2332 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2333 (xtensa_fill_gregset): Call collect_register_by_name for
2334 threadptr register.
2335 (xtensa_store_gregset): Call supply_register_by_name for
2336 threadptr register.
2337
2338 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2339
2340 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2341 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2342 (xtensa_store_gregset): Call supply_register for all registers in
2343 a0_regnum..a0_regnum + C0_NREGS range.
2344
2345 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2346
2347 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2348 (ax-ipa.o: ax.c): Remove.
2349 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2350 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2351 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2352 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2353 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2354
2355 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2356
2357 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2358 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2359 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2360 (errors-ipa.o: ../common/errors.c): Remove.
2361 (format-ipa.o: ../common/format.c): Remove.
2362 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2363
2364 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2365
2366 * Makefile.in (%-ipa.o: %.c): New rule.
2367 (tracepoint-ipa.o: tracepoint.c): Remove.
2368 (utils-ipa.o: utils.c): Remove.
2369 (remote-utils-ipa.o: remote-utils.c): Remove.
2370 (regcache-ipa.o: regcache.c): Remove.
2371 (i386-linux-ipa.o: i386-linux.c): Remove.
2372 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2373 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2374 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2375 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2376 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2377 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2378 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2379 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2380 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2381 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2382 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2383 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2384 (aarch64-ipa.o: aarch64.c): Remove.
2385 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2386 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2387 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2388 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2389 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2390 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2391 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2392 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2393 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2394 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2395 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2396 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2397 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2398 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2399 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2400 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2401 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2402 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2403 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2404 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2405 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2406 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2407 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2408 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2409 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2410 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2411 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2412 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2413 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2414 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2415 (tdesc-ipa.o: tdesc.c): Remove.
2416 (x32-linux-ipa.o: x32-linux.c): Remove.
2417 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2418 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2419
2420 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2421
2422 * Makefile.in (%.o: ../arch/%.c): New rule.
2423 (arm.o: ../arch/arm.c): Remove.
2424 (arm-linux.o: ../arch/arm-linux.c): Remove.
2425 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2426 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2427
2428 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2429
2430 * Makefile.in (%.o: ../nat/%.c): New rule.
2431 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2432 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2433 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2434 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2435 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2436 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2437 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2438 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2439 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2440 (linux-personality.o: ../nat/linux-personality.c): Remove.
2441 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2442 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2443 (x86-linux.o: ../nat/x86-linux.c): Remove.
2444 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2445 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2446
2447 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2448
2449 * Makefile.in (%.o: ../common/%.c): New rule.
2450 (signals.o: ../common/signals.c): Remove.
2451 (print-utils.o: ../common/print-utils.c): Remove.
2452 (rsp-low.o: ../common/rsp-low.c): Remove.
2453 (common-utils.o: ../common/common-utils.c): Remove.
2454 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2455 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2456 (vec.o: ../common/vec.c): Remove.
2457 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2458 (xml-utils.o: ../common/xml-utils.c): Remove.
2459 (ptid.o: ../common/ptid.c): Remove.
2460 (buffer.o: ../common/buffer.c): Remove.
2461 (format.o: ../common/format.c): Remove.
2462 (filestuff.o: ../common/filestuff.c): Remove.
2463 (agent.o: ../common/agent.c): Remove.
2464 (errors.o: ../common/errors.c): Remove.
2465 (environ.o: ../common/environ.c): Remove.
2466 (common-debug.o: ../common/common-debug.c): Remove.
2467 (cleanups.o: ../common/cleanups.c): Remove.
2468 (common-exceptions.o: ../common/common-exceptions.c): Remove.
2469 (fileio.o: ../common/fileio.c): Remove.
2470 (common-regcache.o: ../common/common-regcache.c): Remove.
2471 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
2472 (new-op.o: ../common/new-op.c): Remove.
2473 (btrace-common.o: ../common/btrace-common.c): Remove.
2474
2475 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2476
2477 * Makefile.in (%.o: ../target/%.c): New rule.
2478 (waitstatus.o: ../target/waitstatus.c): Remove.
2479
2480 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2481
2482 * Makefile.in
2483 (%.c: ../regformats/%.dat,
2484 (%.c: ../regformats/arm/%.dat,
2485 (%.c: ../regformats/i386/%.dat,
2486 (%.c: ../regformats/rs6000/%.dat): New rules.
2487 (aarch64.c): Remove.
2488 (reg-arm.c): Remove.
2489 (arm-with-iwmmxt.c): Remove.
2490 (arm-with-vfpv2.c): Remove.
2491 (arm-with-vfpv3.c): Remove.
2492 (arm-with-neon.c): Remove.
2493 (reg-bfin.c): Remove.
2494 (reg-cris.c): Remove.
2495 (reg-crisv32.c): Remove.
2496 (i386.c): Remove.
2497 (i386-linux.c): Remove.
2498 (i386-avx.c): Remove.
2499 (i386-avx-linux.c): Remove.
2500 (i386-avx-avx512.c): Remove.
2501 (i386-avx-avx512-linux.c): Remove.
2502 (i386-mpx.c): Remove.
2503 (i386-mpx-linux.c): Remove.
2504 (i386-avx-mpx-avx512-pku.c): Remove.
2505 (i386-avx-mpx-avx512-pku-linux.c): Remove.
2506 (i386-avx-mpx.c): Remove.
2507 (i386-avx-mpx-linux.c): Remove.
2508 (i386-mmx.c): Remove.
2509 (i386-mmx-linux.c): Remove.
2510 (reg-ia64.c): Remove.
2511 (reg-m32r.c): Remove.
2512 (reg-m68k.c): Remove.
2513 (reg-cf.c): Remove.
2514 (mips-linux.c): Remove.
2515 (mips-dsp-linux.c): Remove.
2516 (mips64-linux.c): Remove.
2517 (mips64-dsp-linux.c): Remove.
2518 (nios2-linux.c): Remove.
2519 (powerpc-32.c): Remove.
2520 (powerpc-32l.c): Remove.
2521 (powerpc-altivec32l.c): Remove.
2522 (powerpc-cell32l.c): Remove.
2523 (powerpc-vsx32l.c): Remove.
2524 (powerpc-isa205-32l.c): Remove.
2525 (powerpc-isa205-altivec32l.c): Remove.
2526 (powerpc-isa205-vsx32l.c): Remove.
2527 (powerpc-e500l.c): Remove.
2528 (powerpc-64l.c): Remove.
2529 (powerpc-altivec64l.c): Remove.
2530 (powerpc-cell64l.c): Remove.
2531 (powerpc-vsx64l.c): Remove.
2532 (powerpc-isa205-64l.c): Remove.
2533 (powerpc-isa205-altivec64l.c): Remove.
2534 (powerpc-isa205-vsx64l.c): Remove.
2535 (s390-linux32.c): Remove.
2536 (s390-linux32v1.c): Remove.
2537 (s390-linux32v2.c): Remove.
2538 (s390-linux64.c): Remove.
2539 (s390-linux64v1.c): Remove.
2540 (s390-linux64v2.c): Remove.
2541 (s390-te-linux64.c): Remove.
2542 (s390-vx-linux64.c): Remove.
2543 (s390-tevx-linux64.c): Remove.
2544 (s390x-linux64.c): Remove.
2545 (s390x-linux64v1.c): Remove.
2546 (s390x-linux64v2.c): Remove.
2547 (s390x-te-linux64.c): Remove.
2548 (s390x-vx-linux64.c): Remove.
2549 (s390x-tevx-linux64.c): Remove.
2550 (tic6x-c64xp-linux.c): Remove.
2551 (tic6x-c64x-linux.c): Remove.
2552 (tic6x-c62x-linux.c): Remove.
2553 (reg-sh.c): Remove.
2554 (reg-sparc64.c): Remove.
2555 (reg-spu.c): Remove.
2556 (amd64.c): Remove.
2557 (amd64-linux.c): Remove.
2558 (amd64-avx.c): Remove.
2559 (amd64-avx-linux.c): Remove.
2560 (amd64-avx-avx512.c): Remove.
2561 (amd64-avx-avx512-linux.c): Remove.
2562 (amd64-mpx.c): Remove.
2563 (amd64-mpx-linux.c): Remove.
2564 (amd64-avx-mpx-avx512-pku.c): Remove.
2565 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
2566 (amd64-avx-mpx.c): Remove.
2567 (amd64-avx-mpx-linux.c): Remove.
2568 (x32.c): Remove.
2569 (x32-linux.c): Remove.
2570 (x32-avx.c): Remove.
2571 (x32-avx-linux.c): Remove.
2572 (x32-avx-avx512.c): Remove.
2573 (x32-avx-avx512-linux.c): Remove.
2574 (reg-xtensa.c): Remove.
2575 (reg-tilegx.c): Remove.
2576 (reg-tilegx32.c): Remove.
2577
2578 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
2579
2580 * Makefile.in (SFILES): Add "common/environ.c".
2581 (OBJS): Add "common/environ.h".
2582
2583 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
2584
2585 * configure.ac: Check if the fs_base and gs_base members of
2586 `struct user_regs_struct' exist.
2587 * config.in: Regenerated.
2588 * configure: Likewise.
2589
2590 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
2591
2592 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
2593 target_read_memory.
2594 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
2595 (get_next_pcs_syscall_next_pc): Likewise.
2596
2597 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
2598
2599 * win32-i386-low.c: Fix incorrect reference to a couple source files.
2600 * nto-x86-low.c: Likewise.
2601
2602 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
2603
2604 * Makefile.in: Include disable-implicit-rules.mk.
2605
2606 2016-11-23 Pedro Alves <palves@redhat.com>
2607
2608 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
2609 (debug_vprintf): Use std::chrono::steady_clock instead of
2610 gettimeofday. Use '.' instead of ':'.
2611 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
2612 (get_timestamp): Use std::chrono::steady_clock instead of
2613 gettimeofday.
2614
2615 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2616
2617 * Makefile.in: Fix whitespace formatting.
2618
2619 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2620
2621 * Makefile.in (SFILES, OBS): Flatten list and order
2622 alphabetically.
2623
2624 2016-11-23 Pedro Alves <palves@redhat.com>
2625
2626 * event-loop.c (handle_file_event): Use warning.
2627 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
2628 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2629 Use warning.
2630
2631 2016-11-23 Pedro Alves <palves@redhat.com>
2632
2633 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
2634 output.
2635 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
2636 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
2637 debug_printf and debug_flush for debug output.
2638 * server.c (handle_general_set): Likewise.
2639 * thread-db.c (try_thread_db_load): Use debug_printf for debug
2640 output.
2641
2642 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2643
2644 * Makefile.in (.c.o): Replace rule with ...
2645 (%.o: %.c): ... this one.
2646
2647 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2648
2649 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
2650 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
2651 make.
2652 * configure.ac: Remove checks for the make program.
2653 * configure: Re-generate.
2654
2655 2016-10-28 Pedro Alves <palves@redhat.com>
2656
2657 * Makefile.in (CXX_DIALECT): Get from configure.
2658 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
2659 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
2660 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
2661 * config.in: Regenerate.
2662 * configure: Regenerate.
2663
2664 2016-10-27 Yao Qi <yao.qi@linaro.org>
2665
2666 * linux-low.c (linux_supports_range_stepping): Return true if
2667 can_software_single_step return true.
2668
2669 2016-10-27 Yao Qi <yao.qi@linaro.org>
2670
2671 * inferiors.c (find_inferior_in_random): New function.
2672 * inferiors.h (find_inferior_in_random): Declare.
2673 * linux-low.c (linux_wait_for_event_filtered): Call
2674 find_inferior_in_random instead of find_inferior.
2675
2676 2016-10-27 Yao Qi <yao.qi@linaro.org>
2677
2678 * linux-low.c (linux_wait_1): If single-step breakpoints are
2679 inserted, remove them.
2680
2681 2016-10-26 Pedro Alves <palves@redhat.com>
2682
2683 * linux-low.c (handle_extended_wait): Link parent/child fork
2684 threads.
2685 (linux_wait_1): Unlink them.
2686 (linux_set_resume_request): Ignore resume requests for
2687 already-resumed and unhandled fork child threads.
2688 * linux-low.h (struct lwp_info) <fork_relative>: New field.
2689 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
2690 New functions.
2691 (handle_v_requests) <vCont>: Don't call require_running.
2692 * server.h (in_queued_stop_replies): New declaration.
2693
2694 2016-10-24 Yao Qi <yao.qi@linaro.org>
2695
2696 PR server/20733
2697 * linux-aarch64-low.c (append_insns): Cast the return value to
2698 'uint32_t *'.
2699
2700 2016-10-10 Yao Qi <yao.qi@linaro.org>
2701
2702 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
2703
2704 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
2705
2706 * target.c (target_supports_multi_process): New function, moved
2707 from...
2708 * target.h (target_supports_multi_process): ... here. Remove
2709 macro.
2710
2711 2016-10-05 Tom Tromey <tom@tromey.com>
2712
2713 PR remote/20655:
2714 * tracepoint.c (handle_tracepoint_bkpts): Check
2715 ipa_error_tracepoint, not ipa_stopping_tracepoint.
2716
2717 2016-10-05 Yao Qi <yao.qi@linaro.org>
2718
2719 * configure.srv: Update the path of arm-*.xml files.
2720
2721 2016-10-05 Terry Guo <terry.guo@arm.com>
2722 Yao Qi <yao.qi@linaro.org>
2723
2724 * Makefile.in: Adjust the path of rules.
2725 * configure.srv: Update the path of xml files.
2726 * regformats/arm-with-iwmmxt.dat: Regenerated.
2727 * regformats/arm-with-neon.dat: Likewise.
2728 * regformats/arm-with-vfpv2.dat: Likewise.
2729 * regformats/arm-with-vfpv3.dat Likewise.
2730
2731 2016-09-30 Yao Qi <yao.qi@linaro.org>
2732
2733 PR gdbserver/20627
2734 * target.c (target_stop_and_wait): Don't call
2735 target_continue_no_signal, use resume_stop instead.
2736
2737 2016-09-26 Yao Qi <yao.qi@linaro.org>
2738
2739 * linux-low.c (linux_wait_1): Call debug_exit.
2740
2741 2016-09-23 Pedro Alves <palves@redhat.com>
2742
2743 * Makefile.in (SFILES): Add common/new-op.c.
2744 (OBS): Add common/new-op.o.
2745 (new-op.o): New rule.
2746
2747 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
2748
2749 * .gitinore: Ignore more files.
2750
2751 2016-09-21 Yao Qi <yao.qi@linaro.org>
2752
2753 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
2754 23.
2755
2756 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
2757
2758 * server.c (start_inferior): Call target_mourn_inferior instead of
2759 mourn_inferior; pass ptid_t argument to it.
2760 (resume): Likewise.
2761 (handle_target_event): Likewise.
2762 * target.c (target_mourn_inferior): New function.
2763 * target.h (mourn_inferior): Delete macro.
2764
2765 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
2766
2767 * linux-low.c (lwp_is_stepping): New function.
2768
2769 2016-09-06 Carl Love <cel@us.ibm.com>
2770
2771 * server.c (start_inferior): Fixed comment, requested comment change
2772 didn't get updated correctly. Removed reference to ptrace () call as
2773 it is only true on Linux systems.
2774
2775 2016-09-06 Carl Love <cel@us.ibm.com>
2776
2777 * server.c (start_inferior): Do not call
2778 function target_post_create_inferior () if the
2779 inferior process has already exited.
2780
2781 2016-09-05 Pedro Alves <palves@redhat.com>
2782
2783 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
2784 (COMPILE.pre, CC_LD): Use CXX directly.
2785 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
2786 * acinclude.m4: Don't include build-with-cxx.m4.
2787 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
2788 * configure: Regenerate.
2789
2790 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
2791
2792 PR gdb/19495
2793 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
2794 call writing data to own_buf.
2795
2796 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2797
2798 * target.c (mywait): Call target_wait instead of
2799 the_target->wait.
2800 (target_wait): New function.
2801
2802 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2803
2804 * server.c (start_inferior): New variable 'ptid'. Replace calls
2805 to the_target->resume by target_continue{,_no_signal}, depending
2806 on the case.
2807 * target.c (target_stop_and_wait): Call target_continue_no_signal
2808 instead of the_target->resume.
2809 (target_continue): New function.
2810
2811 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
2812
2813 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
2814
2815 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
2816
2817 PR server/20491
2818 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
2819 ps_prochandle.
2820 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
2821 * linux-arm-low.c (ps_get_thread_area): Likewise.
2822 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
2823 * linux-m68k-low.c (ps_get_thread_area): Likewise.
2824 * linux-mips-low.c (ps_get_thread_area): Likewise.
2825 * linux-nios2-low.c (ps_get_thread_area): Likewise.
2826 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
2827 * linux-x86-low.c (ps_get_thread_area): Likewise.
2828 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
2829
2830 2016-08-19 Pedro Alves <palves@redhat.com>
2831
2832 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
2833
2834 2016-08-19 Pedro Alves <palves@redhat.com>
2835
2836 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
2837 comment. Use memcpy instead of casting through unsigned long.
2838
2839 2016-08-19 Pedro Alves <palves@redhat.com>
2840
2841 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
2842 allocating around 0x80000000.
2843
2844 2016-08-19 Pedro Alves <palves@redhat.com>
2845
2846 PR gdb/20415
2847 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
2848 (x32-avx512-linux-ipa.o): New rules.
2849 * configure.ac (x86_64-*-linux*): New x32 check.
2850 * configure.srv (ipa_x32_linux_regobj): New.
2851 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
2852 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
2853 descriptions.
2854 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
2855 descriptions.
2856 * configure: Regenerate.
2857
2858 2016-08-09 Pedro Alves <palves@redhat.com>
2859
2860 PR gdb/18653
2861 * Makefile.in (OBS): Add signals-state-save-restore.o.
2862 (signals-state-save-restore.o): New rule.
2863 * config.in: Regenerate.
2864 * configure: Regenerate.
2865 * linux-low.c: Include "signals-state-save-restore.h".
2866 (linux_create_inferior): Call
2867 restore_original_signals_state.
2868 * server.c: Include "dispositions-save-restore.h".
2869 (captured_main): Call save_original_signals_state.
2870
2871 2016-08-05 Pedro Alves <palves@redhat.com>
2872
2873 * configure: Regenerate.
2874
2875 2016-08-04 Yao Qi <yao.qi@linaro.org>
2876
2877 * linux-low.c (regsets_fetch_inferior_registers): Check
2878 errno is ESRCH or not.
2879
2880 2016-08-02 Yao Qi <yao.qi@linaro.org>
2881
2882 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
2883 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
2884 (thread_db_load_search): Update.
2885 (try_thread_db_load_1): Don't look for td_ta_event_addr,
2886 td_ta_set_event and td_ta_event_getmsg.
2887
2888 2016-07-26 Pedro Alves <palves@redhat.com>
2889
2890 PR server/20414
2891 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
2892 of unsigned long for 64-bit registers and use uint32_t instead of
2893 unsigned int for 32-bit registers.
2894
2895 2016-07-26 Pedro Alves <palves@redhat.com>
2896
2897 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
2898 to 'ptrace'.
2899
2900 2016-07-21 Tom Tromey <tom@tromey.com>
2901
2902 * configure: Rebuild.
2903
2904 2016-07-21 Yao Qi <yao.qi@linaro.org>
2905
2906 * mem-break.c (find_gdb_breakpoint): Cast bp to
2907 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
2908
2909 2016-07-21 Yao Qi <yao.qi@linaro.org>
2910
2911 * server.c (handle_v_requests): Support s and S actions
2912 if target_supports_software_single_step return true.
2913
2914 2016-07-21 Yao Qi <yao.qi@linaro.org>
2915
2916 * linux-low.c (resume_stopped_resumed_lwps): If resume request
2917 is resume_step, call maybe_hw_step.
2918 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
2919 and unstop them.
2920 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
2921 breakpoints or not.
2922 (proceed_one_lwp): If resume request is resume_step, install
2923 reinsert breakpoints and call maybe_hw_step.
2924
2925 2016-07-21 Yao Qi <yao.qi@linaro.org>
2926
2927 * linux-low.c (proceed_one_lwp): Declare.
2928 (linux_resume_one_thread): Remove local variable 'step'.
2929 Lift code enqueue signal. Call proceed_one_lwp instead of
2930 linux_resume_one_lwp.
2931
2932 2016-07-21 Yao Qi <yao.qi@linaro.org>
2933
2934 * linux-low.c (linux_resume_one_thread): Call
2935 enqueue_pending_signal.
2936
2937 2016-07-21 Yao Qi <yao.qi@linaro.org>
2938
2939 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
2940 * inferiors.c (do_restore_current_thread_cleanup): New function.
2941 (make_cleanup_restore_current_thread): Likewise.
2942 * linux-low.c (install_software_single_step_breakpoints): Call
2943 make_cleanup_restore_current_thread. Switch current_thread to
2944 thread.
2945
2946 2016-07-21 Yao Qi <yao.qi@linaro.org>
2947
2948 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
2949 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
2950 (clone_one_breakpoint): Likewise.
2951 (delete_reinsert_breakpoints): Change parameter to thread.
2952 Callers updated.
2953 (has_reinsert_breakpoints): Likewise.
2954 (uninsert_reinsert_breakpoints): Likewise.
2955 (reinsert_reinsert_breakpoints): Likewise.
2956 * mem-break.h (set_reinsert_breakpoint): Update declaration.
2957 (delete_reinsert_breakpoints): Likewise.
2958 (reinsert_reinsert_breakpoints): Likewise.
2959 (uninsert_reinsert_breakpoints): Likewise.
2960 (has_reinsert_breakpoints): Likewise.
2961
2962 2016-07-21 Yao Qi <yao.qi@linaro.org>
2963
2964 * inferiors.c (get_thread_process): Make parameter const.
2965 * inferiors.h (get_thread_process): Update declaration.
2966 * mem-break.c (clone_all_breakpoints): Remove all parameters.
2967 Add new parameters child_thread and parent_thread. Callers
2968 updated.
2969 * mem-break.h (clone_all_breakpoints): Update declaration.
2970
2971 2016-07-21 Yao Qi <yao.qi@linaro.org>
2972
2973 * mem-break.c (struct breakpoint) <cond_list>: Remove.
2974 <command_list, handler>: Remove.
2975 (struct gdb_breakpoint): New.
2976 (struct other_breakpoint): New.
2977 (struct reinsert_breakpoint): New.
2978 (is_gdb_breakpoint): New function.
2979 (any_persistent_commands): Update command_list if
2980 is_gdb_breakpoint returns true.
2981 (set_breakpoint): Create breakpoints according to their types.
2982 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
2983 (set_gdb_breakpoint_1): Likewise.
2984 (set_gdb_breakpoint): Likewise.
2985 (clear_breakpoint_conditions): Change parameter type to
2986 'struct gdb_breakpoint *'.
2987 (clear_breakpoint_commands): Likewise.
2988 (clear_breakpoint_conditions_and_commands): Likewise.
2989 (add_condition_to_breakpoint): Likewise.
2990 (add_breakpoint_condition): Likewise.
2991 (add_commands_to_breakpoint): Likewise.
2992 (check_breakpoints): Check other_breakpoint.
2993 (clone_one_breakpoint): Clone breakpopint according to its type.
2994 * mem-break.h (struct gdb_breakpoint): Declare.
2995 (set_gdb_breakpoint): Update declaration.
2996 (clear_breakpoint_conditions_and_commands): Likewise.
2997 (add_breakpoint_condition): Likewise.
2998 (add_breakpoint_commands): Likewise.
2999 * server.c (process_point_options): Change parameter type to
3000 'struct gdb_breakpoint *'.
3001
3002 2016-07-21 Yao Qi <yao.qi@linaro.org>
3003
3004 * mem-break.c (set_breakpoint_at): Rename it to ...
3005 (set_breakpoint_type_at): ... it.
3006 (set_breakpoint_at): Call set_breakpoint_type_at.
3007 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3008 * mem-break.h (set_breakpoint_at): Update comments.
3009
3010 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3011
3012 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3013 to buf parameter.
3014 (nios2_store_gregset): Likewise.
3015
3016 2016-07-01 Pedro Alves <palves@redhat.com>
3017 Antoine Tremblay <antoine.tremblay@ericsson.com>
3018
3019 * linux-low.c: Change interface to take the target lwp_info
3020 pointer directly and return void. Handle detaching from a zombie
3021 thread.
3022 (linux_detach_lwp_callback): New function.
3023 (linux_detach): Detach from the leader thread after detaching from
3024 the clone threads.
3025
3026 2016-06-28 Yao Qi <yao.qi@linaro.org>
3027
3028 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3029 for variable new_offset.
3030 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3031 (aarch64_ftrace_insn_reloc_cb): Likewise.
3032 (aarch64_ftrace_insn_reloc_tb): Likewise.
3033 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3034 PRIx64 instead of PRIx32.
3035
3036 2016-06-28 Yao Qi <yao.qi@linaro.org>
3037
3038 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3039 (the_low_target): Install arm_get_syscall_trapinfo.
3040
3041 2016-06-28 Yao Qi <yao.qi@linaro.org>
3042
3043 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3044 function.
3045 (the_low_target): Install aarch64_get_syscall_trapinfo.
3046
3047 2016-06-28 Yao Qi <yao.qi@linaro.org>
3048
3049 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3050 Callers updated.
3051 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3052 Remove parameter sysno.
3053 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3054 sysret.
3055
3056 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3057
3058 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3059 (s390_emit_ne_goto): Likewise.
3060 (s390_emit_lt_goto): Likewise.
3061 (s390_emit_le_goto): Likewise.
3062 (s390_emit_gt_goto): Likewise.
3063 (s390_emit_ge_goto): Likewise.
3064 (s390x_emit_eq_goto): Likewise.
3065 (s390x_emit_ne_goto): Likewise.
3066 (s390x_emit_lt_goto): Likewise.
3067 (s390x_emit_le_goto): Likewise.
3068 (s390x_emit_gt_goto): Likewise.
3069 (s390x_emit_ge_goto): Likewise.
3070 (s390_emit_ops_impl): Mark variable static.
3071 (s390x_emit_ops): Likewise.
3072
3073 2016-06-17 Yao Qi <yao.qi@linaro.org>
3074
3075 * linux-low.c (handle_extended_wait): Call
3076 uninsert_reinsert_breakpoints for the parent process. Remove
3077 reinsert breakpoints from the child process. Reinsert them to
3078 the parent process when vfork is done.
3079 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3080 (reinsert_reinsert_breakpoints): New function.
3081 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3082 (reinsert_reinsert_breakpoints): Declare.
3083
3084 2016-06-17 Yao Qi <yao.qi@linaro.org>
3085
3086 * linux-low.c (handle_extended_wait): If the parent is doing
3087 step-over, remove the reinsert breakpoints from the forked child.
3088
3089 2016-06-17 Yao Qi <yao.qi@linaro.org>
3090
3091 * linux-low.c (unsuspend_all_lwps): Declare.
3092 (linux_low_filter_event): If thread exited, call finish_step_over.
3093 If step-over is finished, unsuspend other threads.
3094
3095 2016-06-17 Yao Qi <yao.qi@linaro.org>
3096
3097 * linux-low.c (linux_resume_one_lwp_throw): Assert
3098 has_reinsert_breakpoints returns false.
3099 * mem-break.c (delete_disabled_breakpoints): Assert
3100 bp type isn't reinsert_breakpoint.
3101
3102 2016-06-17 Yao Qi <yao.qi@linaro.org>
3103
3104 * linux-low.c (maybe_hw_step): New function.
3105 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3106 (finish_step_over): Switch current_thread to lwp temporarily,
3107 and assert has_reinsert_breakpoints returns true.
3108 (proceed_one_lwp): Call maybe_hw_step.
3109 * mem-break.c (has_reinsert_breakpoints): New function.
3110 * mem-break.h (has_reinsert_breakpoints): Declare.
3111
3112 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3113
3114 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3115
3116 2016-05-17 Yao Qi <yao.qi@linaro.org>
3117
3118 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3119 instead of find_inferior.
3120
3121 2016-05-05 Yao Qi <yao.qi@linaro.org>
3122
3123 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3124 Initialize res to zero.
3125
3126 2016-05-05 Yao Qi <yao.qi@linaro.org>
3127
3128 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3129 to uint32_t.
3130
3131 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3132
3133 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3134 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3135 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3136
3137 2016-04-28 Par Olsson <par.olsson@windriver.com>
3138 Simon Marchi <simon.marchi@ericsson.com>
3139
3140 * tracepoint.c (write_inferior_int8): New function.
3141 (cmd_qtenable_disable): Write enable flag using
3142 write_inferior_int8.
3143
3144 2016-04-25 Yao Qi <yao.qi@linaro.org>
3145
3146 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3147 (need_step_over_p): Return zero if the LWP has pending signals
3148 can be delivered on software single step target.
3149
3150 2016-04-25 Yao Qi <yao.qi@linaro.org>
3151
3152 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3153 return instead of error.
3154
3155 2016-04-22 Yao Qi <yao.qi@linaro.org>
3156
3157 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3158 to 23.
3159
3160 2016-04-22 Yao Qi <yao.qi@linaro.org>
3161
3162 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3163 signal when stepping over breakpoint with software single
3164 step.
3165
3166 2016-04-21 Pedro Alves <palves@redhat.com>
3167
3168 * linux-s390-low.c (s390_collect_ptrace_register)
3169 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3170 add casts.
3171 (s390_check_regset): Use void * instead of gdb_byte *.
3172
3173 2016-04-20 Pedro Alves <palves@redhat.com>
3174
3175 * configure: Renegerate.
3176
3177 2016-04-20 Yao Qi <yao.qi@linaro.org>
3178
3179 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3180 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3181 number 16.
3182 (arm_store_gregset): Likewise.
3183
3184 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3185
3186 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3187 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3188 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3189 (amd64-avx-mpx-linux.c): New rules.
3190 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3191 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3192 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3193 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3194 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3195 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3196 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3197 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3198 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3199 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3200 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3201 * linux-x86-low.c (x86_linux_read_description): Add case for
3202 X86_XSTATE_AVX_MPX_MASK.
3203 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3204 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3205 init_registers_i386_avx_mpx_linux.
3206 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3207 (initialize_low_tracepoint): Call
3208 init_registers_i386_avx_mpx_linux.
3209 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3210 (initialize_low_tracepoint): Call
3211 init_registers_amd64_avx_mpx_linux.
3212 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3213 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3214 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3215 declarations.
3216
3217 2016-04-18 Pedro Alves <palves@redhat.com>
3218
3219 * configure: Regenerate.
3220
3221 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3222
3223 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3224 (aarch64_emit_sub): Likewise.
3225
3226 2016-04-12 Pedro Alves <palves@redhat.com>
3227
3228 * utils.c (prepare_to_throw_exception): Delete.
3229
3230 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3231
3232 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3233
3234 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3235
3236 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3237
3238 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3239
3240 * linux-aarch64-ipa.c: Add <elf.h> include.
3241 * linux-ppc-ipa.c: Add <elf.h> include.
3242 * linux-s390-ipa.c: Add <elf.h> include.
3243
3244 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3245
3246 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3247 (get_raw_reg_ptr): Likewise.
3248 (get_trace_state_variable_value_ptr): Likewise.
3249 (set_trace_state_variable_value_ptr): Likewise.
3250 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3251 char *.
3252
3253 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3254 Marcin Kościelnicki <koriakin@0x04.net>
3255
3256 PR/17221
3257 * linux-ppc-low.c (emit_insns): New function.
3258 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3259 (ppc_emit_prologue): New function.
3260 (ppc_emit_epilogue): New function.
3261 (ppc_emit_add): New function.
3262 (ppc_emit_sub): New function.
3263 (ppc_emit_mul): New function.
3264 (ppc_emit_lsh): New function.
3265 (ppc_emit_rsh_signed): New function.
3266 (ppc_emit_rsh_unsigned): New function.
3267 (ppc_emit_ext): New function.
3268 (ppc_emit_zero_ext): New function.
3269 (ppc_emit_log_not): New function.
3270 (ppc_emit_bit_and): New function.
3271 (ppc_emit_bit_or): New function.
3272 (ppc_emit_bit_xor): New function.
3273 (ppc_emit_bit_not): New function.
3274 (ppc_emit_equal): New function.
3275 (ppc_emit_less_signed): New function.
3276 (ppc_emit_less_unsigned): New function.
3277 (ppc_emit_ref): New function.
3278 (ppc_emit_const): New function.
3279 (ppc_emit_reg): New function.
3280 (ppc_emit_pop): New function.
3281 (ppc_emit_stack_flush): New function.
3282 (ppc_emit_swap): New function.
3283 (ppc_emit_stack_adjust): New function.
3284 (ppc_emit_call): New function.
3285 (ppc_emit_int_call_1): New function.
3286 (ppc_emit_void_call_2): New function.
3287 (ppc_emit_if_goto): New function.
3288 (ppc_emit_goto): New function.
3289 (ppc_emit_eq_goto): New function.
3290 (ppc_emit_ne_goto): New function.
3291 (ppc_emit_lt_goto): New function.
3292 (ppc_emit_le_goto): New function.
3293 (ppc_emit_gt_goto): New function.
3294 (ppc_emit_ge_goto): New function.
3295 (ppc_write_goto_address): New function.
3296 (ppc_emit_ops_impl): New static variable.
3297 (ppc64v1_emit_prologue): New function.
3298 (ppc64v2_emit_prologue): New function.
3299 (ppc64_emit_epilogue): New function.
3300 (ppc64_emit_add): New function.
3301 (ppc64_emit_sub): New function.
3302 (ppc64_emit_mul): New function.
3303 (ppc64_emit_lsh): New function.
3304 (ppc64_emit_rsh_signed): New function.
3305 (ppc64_emit_rsh_unsigned): New function.
3306 (ppc64_emit_ext): New function.
3307 (ppc64_emit_zero_ext): New function.
3308 (ppc64_emit_log_not): New function.
3309 (ppc64_emit_bit_and): New function.
3310 (ppc64_emit_bit_or): New function.
3311 (ppc64_emit_bit_xor): New function.
3312 (ppc64_emit_bit_not): New function.
3313 (ppc64_emit_equal): New function.
3314 (ppc64_emit_less_signed): New function.
3315 (ppc64_emit_less_unsigned): New function.
3316 (ppc64_emit_ref): New function.
3317 (ppc64_emit_const): New function.
3318 (ppc64v1_emit_reg): New function.
3319 (ppc64v2_emit_reg): New function.
3320 (ppc64_emit_pop): New function.
3321 (ppc64_emit_stack_flush): New function.
3322 (ppc64_emit_swap): New function.
3323 (ppc64v1_emit_call): New function.
3324 (ppc64v2_emit_call): New function.
3325 (ppc64v1_emit_int_call_1): New function.
3326 (ppc64v2_emit_int_call_1): New function.
3327 (ppc64v1_emit_void_call_2): New function.
3328 (ppc64v2_emit_void_call_2): New function.
3329 (ppc64_emit_if_goto): New function.
3330 (ppc64_emit_eq_goto): New function.
3331 (ppc64_emit_ne_goto): New function.
3332 (ppc64_emit_lt_goto): New function.
3333 (ppc64_emit_le_goto): New function.
3334 (ppc64_emit_gt_goto): New function.
3335 (ppc64_emit_ge_goto): New function.
3336 (ppc64v1_emit_ops_impl): New static variable.
3337 (ppc64v2_emit_ops_impl): New static variable.
3338 (ppc_emit_ops): New function.
3339 (linux_low_target): Wire in ppc_emit_ops.
3340
3341 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3342 Marcin Kościelnicki <koriakin@0x04.net>
3343
3344 PR/17221
3345 * Makefile.in: Add powerpc-*-ipa.o
3346 * configure.srv: Add ipa_obj for powerpc*-linux.
3347 * linux-ppc-ipa.c: New file.
3348 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3349 includes.
3350 (PPC_FIELD): New macro.
3351 (PPC_SEXT): New macro.
3352 (PPC_OP6): New macro.
3353 (PPC_BO): New macro.
3354 (PPC_LI): New macro.
3355 (PPC_BD): New macro.
3356 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3357 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3358 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3359 (ppc_get_thread_area): New function.
3360 (is_elfv2_inferior): New function.
3361 (gen_ds_form): New function.
3362 (GEN_STD): New macro.
3363 (GEN_STDU): New macro.
3364 (GEN_LD): New macro.
3365 (GEN_LDU): New macro.
3366 (gen_d_form): New function.
3367 (GEN_ADDI): New macro.
3368 (GEN_ADDIS): New macro.
3369 (GEN_LI): New macro.
3370 (GEN_LIS): New macro.
3371 (GEN_ORI): New macro.
3372 (GEN_ORIS): New macro.
3373 (GEN_LWZ): New macro.
3374 (GEN_STW): New macro.
3375 (GEN_STWU): New macro.
3376 (gen_xfx_form): New function.
3377 (GEN_MFSPR): New macro.
3378 (GEN_MTSPR): New macro.
3379 (GEN_MFCR): New macro.
3380 (GEN_MTCR): New macro.
3381 (GEN_SYNC): New macro.
3382 (GEN_LWSYNC): New macro.
3383 (gen_x_form): New function.
3384 (GEN_OR): New macro.
3385 (GEN_MR): New macro.
3386 (GEN_LWARX): New macro.
3387 (GEN_STWCX): New macro.
3388 (GEN_CMPW): New macro.
3389 (gen_md_form): New function.
3390 (GEN_RLDICL): New macro.
3391 (GEN_RLDICR): New macro.
3392 (gen_i_form): New function.
3393 (GEN_B): New macro.
3394 (GEN_BL): New macro.
3395 (gen_b_form): New function.
3396 (GEN_BNE): New macro.
3397 (GEN_LOAD): New macro.
3398 (GEN_STORE): New macro.
3399 (gen_limm): New function.
3400 (gen_atomic_xchg): New function.
3401 (gen_call): New function.
3402 (ppc_relocate_instruction): New function.
3403 (ppc_install_fast_tracepoint_jump_pad): New function.
3404 (ppc_get_min_fast_tracepoint_insn_len): New function.
3405 (ppc_get_ipa_tdesc_idx): New function.
3406 (the_low_target): Wire in the new functions.
3407 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3408 tdescs.
3409 * linux-ppc-tdesc.h: New file.
3410
3411 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3412
3413 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3414 (alloc_jump_pad_buffer): New function.
3415 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3416 (alloc_jump_pad_buffer): New function.
3417 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3418 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3419 (alloc_jump_pad_buffer): New function.
3420 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3421 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3422 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3423 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3424
3425 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3426
3427 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3428 * linux-amd64-ipa.c: Likewise.
3429 * linux-i386-ipa.c: Likewise.
3430 * linux-s390-ipa.c: Likewise.
3431 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3432 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3433 set_trace_state_variable_value_ptr.
3434 (struct ipa_sym_addresses): Likewise.
3435 (symbol_list): Likewise.
3436 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3437 accessing gdb_collect directly.
3438 (gdb_collect_ptr_type): New typedef.
3439 (get_raw_reg_ptr_type): New typedef.
3440 (get_trace_state_variable_value_ptr_type): New typedef.
3441 (set_trace_state_variable_value_ptr_type): New typedef.
3442 (gdb_collect_ptr): New global.
3443 (get_raw_reg_ptr): New global.
3444 (get_trace_state_variable_value_ptr): New global.
3445 (set_trace_state_variable_value_ptr): New global.
3446 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3447 accessing get_raw_reg directly.
3448 (get_get_tsv_func_addr): Likewise for
3449 get_trace_state_variable_value_ptr.
3450 (get_set_tsv_func_addr): Likewise for
3451 set_trace_state_variable_value_ptr.
3452 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3453
3454 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3455
3456 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3457
3458 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3459
3460 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3461 packets.
3462 (relocate_instruction): Remove own_buf.
3463 * server.c (own_buf): Make global.
3464 (handle_v_requests): Make global.
3465 * server.h (own_buf): New declaration.
3466 (handle_v_requests): New prototype.
3467
3468 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3469
3470 PR 18377
3471 * linux-s390-low.c (add_insns): New function.
3472 (s390_emit_prologue): New function.
3473 (s390_emit_epilogue): New function.
3474 (s390_emit_add): New function.
3475 (s390_emit_sub): New function.
3476 (s390_emit_mul): New function.
3477 (s390_emit_lsh): New function.
3478 (s390_emit_rsh_signed): New function.
3479 (s390_emit_rsh_unsigned): New function.
3480 (s390_emit_ext): New function.
3481 (s390_emit_log_not): New function.
3482 (s390_emit_bit_and): New function.
3483 (s390_emit_bit_or): New function.
3484 (s390_emit_bit_xor): New function.
3485 (s390_emit_bit_not): New function.
3486 (s390_emit_equal): New function.
3487 (s390_emit_less_signed): New function.
3488 (s390_emit_less_unsigned): New function.
3489 (s390_emit_ref): New function.
3490 (s390_emit_if_goto): New function.
3491 (s390_emit_goto): New function.
3492 (s390_write_goto_address): New function.
3493 (s390_emit_litpool): New function.
3494 (s390_emit_const): New function.
3495 (s390_emit_call): New function.
3496 (s390_emit_reg): New function.
3497 (s390_emit_pop): New function.
3498 (s390_emit_stack_flush): New function.
3499 (s390_emit_zero_ext): New function.
3500 (s390_emit_swap): New function.
3501 (s390_emit_stack_adjust): New function.
3502 (s390_emit_set_r2): New function.
3503 (s390_emit_int_call_1): New function.
3504 (s390_emit_void_call_2): New function.
3505 (s390_emit_eq_goto): New function.
3506 (s390_emit_ne_goto): New function.
3507 (s390_emit_lt_goto): New function.
3508 (s390_emit_le_goto): New function.
3509 (s390_emit_gt_goto): New function.
3510 (s390_emit_ge_goto): New function.
3511 (s390x_emit_prologue): New function.
3512 (s390x_emit_epilogue): New function.
3513 (s390x_emit_add): New function.
3514 (s390x_emit_sub): New function.
3515 (s390x_emit_mul): New function.
3516 (s390x_emit_lsh): New function.
3517 (s390x_emit_rsh_signed): New function.
3518 (s390x_emit_rsh_unsigned): New function.
3519 (s390x_emit_ext): New function.
3520 (s390x_emit_log_not): New function.
3521 (s390x_emit_bit_and): New function.
3522 (s390x_emit_bit_or): New function.
3523 (s390x_emit_bit_xor): New function.
3524 (s390x_emit_bit_not): New function.
3525 (s390x_emit_equal): New function.
3526 (s390x_emit_less_signed): New function.
3527 (s390x_emit_less_unsigned): New function.
3528 (s390x_emit_ref): New function.
3529 (s390x_emit_if_goto): New function.
3530 (s390x_emit_const): New function.
3531 (s390x_emit_call): New function.
3532 (s390x_emit_reg): New function.
3533 (s390x_emit_pop): New function.
3534 (s390x_emit_stack_flush): New function.
3535 (s390x_emit_zero_ext): New function.
3536 (s390x_emit_swap): New function.
3537 (s390x_emit_stack_adjust): New function.
3538 (s390x_emit_int_call_1): New function.
3539 (s390x_emit_void_call_2): New function.
3540 (s390x_emit_eq_goto): New function.
3541 (s390x_emit_ne_goto): New function.
3542 (s390x_emit_lt_goto): New function.
3543 (s390x_emit_le_goto): New function.
3544 (s390x_emit_gt_goto): New function.
3545 (s390x_emit_ge_goto): New function.
3546 (s390_emit_ops): New function.
3547 (struct linux_target_ops): Fill in emit_ops hook.
3548
3549 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3550
3551 PR 18377
3552 * Makefile.in: Add s390 IPA files.
3553 * configure.srv: Build IPA for s390.
3554 * linux-s390-ipa.c: New file.
3555 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
3556 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
3557 (tdesc_s390_linux32): Likewise.
3558 (init_registers_s390_linux32v1): Likewise.
3559 (tdesc_s390_linux32v1): Likewise.
3560 (init_registers_s390_linux32v2): Likewise.
3561 (tdesc_s390_linux32v2): Likewise.
3562 (init_registers_s390_linux64): Likewise.
3563 (tdesc_s390_linux64): Likewise.
3564 (init_registers_s390_linux64v1): Likewise.
3565 (tdesc_s390_linux64v1): Likewise.
3566 (init_registers_s390_linux64v2): Likewise.
3567 (tdesc_s390_linux64v2): Likewise.
3568 (init_registers_s390_te_linux64): Likewise.
3569 (tdesc_s390_te_linux64): Likewise.
3570 (init_registers_s390_vx_linux64): Likewise.
3571 (tdesc_s390_vx_linux64): Likewise.
3572 (init_registers_s390_tevx_linux64): Likewise.
3573 (tdesc_s390_tevx_linux64): Likewise.
3574 (init_registers_s390x_linux64): Likewise.
3575 (tdesc_s390x_linux64): Likewise.
3576 (init_registers_s390x_linux64v1): Likewise.
3577 (tdesc_s390x_linux64v1): Likewise.
3578 (init_registers_s390x_linux64v2): Likewise.
3579 (tdesc_s390x_linux64v2): Likewise.
3580 (init_registers_s390x_te_linux64): Likewise.
3581 (tdesc_s390x_te_linux64): Likewise.
3582 (init_registers_s390x_vx_linux64): Likewise.
3583 (tdesc_s390x_vx_linux64): Likewise.
3584 (init_registers_s390x_tevx_linux64): Likewise.
3585 (tdesc_s390x_tevx_linux64): Likewise.
3586 (have_hwcap_s390_vx): New static variable.
3587 (s390_arch_setup): Fill have_hwcap_s390_vx.
3588 (s390_get_thread_area): New function.
3589 (s390_ft_entry_gpr_esa): New const.
3590 (s390_ft_entry_gpr_zarch): New const.
3591 (s390_ft_entry_misc): New const.
3592 (s390_ft_entry_fr): New const.
3593 (s390_ft_entry_vr): New const.
3594 (s390_ft_main_31): New const.
3595 (s390_ft_main_64): New const.
3596 (s390_ft_exit_fr): New const.
3597 (s390_ft_exit_vr): New const.
3598 (s390_ft_exit_misc): New const.
3599 (s390_ft_exit_gpr_esa): New const.
3600 (s390_ft_exit_gpr_zarch): New const.
3601 (append_insns): New function.
3602 (s390_relocate_instruction): New function.
3603 (s390_install_fast_tracepoint_jump_pad): New function.
3604 (s390_get_min_fast_tracepoint_insn_len): New function.
3605 (s390_get_ipa_tdesc_idx): New function.
3606 (struct linux_target_ops): Wire in the above functions.
3607 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
3608 * linux-s390-tdesc.h: New file.
3609
3610 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3611
3612 * linux-s390-low.c (s390_supports_tracepoints): New function.
3613 (struct linux_target_ops): Fill supports_tracepoints hook.
3614
3615 2016-03-18 Yao Qi <yao.qi@linaro.org>
3616
3617 * linux-low.c (lwp_signal_can_be_delivered): New function.
3618 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
3619
3620 2016-03-18 Yao Qi <yao.qi@linaro.org>
3621
3622 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
3623 0 if signal is enqueued. Remove 'signal' from one debugging
3624 message. Move one debugging message to some lines below.
3625 Remove code setting 'signal' to 0.
3626
3627 2016-03-18 Yao Qi <yao.qi@linaro.org>
3628
3629 * linux-low.c (linux_low_filter_event): Remove redundant
3630 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
3631
3632 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
3633
3634 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
3635 (struct linux_target_ops): Wire in the above.
3636
3637 2016-03-03 Yao Qi <yao.qi@linaro.org>
3638
3639 * linux-low.c: Update comments to start_step_over.
3640
3641 2016-03-03 Yao Qi <yao.qi@linaro.org>
3642
3643 PR server/19736
3644 * linux-low.c (handle_extended_wait): Set child suspended
3645 if event_lwp->bp_reinsert isn't zero.
3646
3647 2016-03-02 Yao Qi <yao.qi@linaro.org>
3648
3649 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
3650 enqueue_pending_signal.
3651
3652 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
3653
3654 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
3655 is actually loaded.
3656
3657 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3658
3659 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
3660 (s390_regmap_3264) [!__s390x__]: New global.
3661 (s390_collect_ptrace_register): Skip map entries containing -1.
3662 (s390_supply_ptrace_register): Ditto.
3663 (s390_fill_gprs_high): New function.
3664 (s390_store_gprs_high): New function.
3665 (s390_regsets): Add NT_S390_HIGH_GPRS.
3666 (s390_get_hwcap): Enable on 31-bit.
3667 (have_hwcap_s390_high_gprs): Enable on 31-bit.
3668 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
3669 Detect NT_S390_HIGH_GPRS.
3670 (s390_usrregs_info_3264): Enable on 31-bit.
3671 (s390_regs_info): Enable regs_info_3264 on 31-bit.
3672 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
3673
3674 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3675
3676 PR gdb/13808
3677 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
3678 * configure.srv: Ditto.
3679 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
3680 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
3681 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
3682 (init_registers_amd64_linux): Remove prototype.
3683 (tdesc_amd64_linux): Remove declaration.
3684 (get_ipa_tdesc): New function.
3685 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3686 initialize remaining tdescs.
3687 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
3688 (init_registers_i386_linux): Remove prototype.
3689 (tdesc_i386_linux): Remove declaration.
3690 (get_ipa_tdesc): New function.
3691 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3692 initialize remaining tdescs.
3693 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
3694 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
3695 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
3696 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
3697 (x86_get_ipa_tdesc_idx): New function.
3698 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
3699 * linux-x86-tdesc.h: New file.
3700 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
3701 (target_get_ipa_tdesc_idx): New macro.
3702 * tracepoint.c (ipa_tdesc_idx): New macro.
3703 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
3704 (symbol_list): Add ipa_tdesc_idx.
3705 (cmd_qtstart): Write ipa_tdesc_idx in the target.
3706 (ipa_tdesc): Remove.
3707 (ipa_tdesc_idx): New variable.
3708 (get_context_regcache): Use get_ipa_tdesc.
3709 (gdb_collect): Ditto.
3710 (gdb_probe): Ditto.
3711 * tracepoint.h (get_ipa_tdesc): New prototype.
3712 (ipa_tdesc): Remove.
3713
3714 2016-02-24 Pedro Alves <palves@redhat.com>
3715
3716 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
3717 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
3718 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
3719 Factor out common code between the USE_SIGTRAP_SIGINFO and
3720 !USE_SIGTRAP_SIGINFO blocks.
3721 (linux_low_filter_event): Call save_stop_reason instead of
3722 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
3723 Update comments.
3724 (linux_wait_1): Update comments.
3725
3726 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
3727
3728 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
3729 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
3730 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
3731 ppc_insert_point, ppc_remove_point.
3732
3733 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
3734
3735 * linux-s390-low.c (s390_supports_z_point_type): New function.
3736 (struct linux_target_ops): Wire s390_supports_z_point_type in.
3737
3738 2016-02-16 Yao Qi <yao.qi@linaro.org>
3739
3740 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
3741 PC. Get pc from regcache_read_pc.
3742
3743 2016-02-12 Yao Qi <yao.qi@linaro.org>
3744
3745 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
3746 or linux_get_pc_32bit.
3747 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
3748
3749 2016-02-12 Yao Qi <yao.qi@linaro.org>
3750
3751 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
3752 arm_linux_get_next_pcs_fixup.
3753
3754 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
3755
3756 * tracepoint.c (x_tracepoint_action_download): Change
3757 write_inferior_data_ptr to write_inferior_data_pointer.
3758 (cmd_qtstart): Likewise.
3759 (write_inferior_data_ptr): Remove.
3760 (download_agent_expr): Change write_inferior_data_ptr to
3761 write_inferior_data_pointer.
3762 (download_tracepoint_1): Likewise.
3763 (download_tracepoint): Likewise.
3764 (download_trace_state_variables): Likewise.
3765
3766 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
3767 Marcin Kościelnicki <koriakin@0x04.net>
3768
3769 * tracepoint.c (struct tracepoint_action_ops): Remove.
3770 (struct tracepoint_action): Remove ops.
3771 (m_tracepoint_action_download, r_tracepoint_action_download)
3772 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
3773 size and offset accordingly.
3774 (m_tracepoint_action_ops, r_tracepoint_action_ops)
3775 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
3776 (tracepoint_action_send, tracepoint_action_download): New functions.
3777 Helpers for trace action handlers.
3778 (add_tracepoint_action): Remove setup actions ops.
3779 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
3780
3781 2016-02-10 Yao Qi <yao.qi@linaro.org>
3782
3783 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
3784
3785 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3786
3787 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
3788 to AC_OUTPUT.
3789 * configure: Regenerate.
3790
3791 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3792
3793 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
3794 void * to gdb_byte *.
3795 * linux-low.c (siginfo_fixup): Likewise.
3796 (linux_xfer_siginfo): Likewise.
3797 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
3798 Likewise.
3799 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
3800
3801 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
3802
3803 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
3804 to srv_tgtobj.
3805 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
3806 to srv_tgtobj.
3807 * linux-x86-low.c [__x86_64__]: Include
3808 "nat/amd64-linux-siginfo.h".
3809 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
3810 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
3811 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
3812 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
3813 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
3814 (cpt_si_fd, si_timerid, si_overrun): Move from
3815 nat/amd64-linux-siginfo.c.
3816 * Makefile.in (amd64-linux-siginfo.o:): New rule.
3817
3818 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
3819
3820 * server.c (skip_to_semicolon): Remove.
3821 (process_point_options): Use strchrnul instead of
3822 skip_to_semicolon.
3823
3824 2016-01-26 Yao Qi <yao.qi@linaro.org>
3825
3826 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
3827 * linux-low.c (install_software_single_step_breakpoints): Don't
3828 call regcache_read_pc.
3829 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
3830 argument pc.
3831
3832 2016-01-26 Yao Qi <yao.qi@linaro.org>
3833
3834 * linux-low.c (install_software_single_step_breakpoints): Call
3835 regcache_read_pc instead of get_pc.
3836
3837 2016-01-26 Yao Qi <yao.qi@linaro.org>
3838
3839 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
3840 (unblock_async_io): Rename to ...
3841 (block_unblock_async_io): ... it. New function.
3842 (enable_async_io): Don't install SIGIO handler. Unblock it
3843 instead.
3844 (disable_async_io): Don't ignore SIGIO. Block it instead.
3845 (initialize_async_io): Install SIGIO handler. Don't call
3846 unblock_async_io.
3847
3848 2016-01-26 Yao Qi <yao.qi@linaro.org>
3849
3850 * remote-utils.c (getpkt): If the buffer isn't empty, and the
3851 first character is '\003', call *the_target->request_interrupt.
3852
3853 2016-01-25 Yao Qi <yao.qi@linaro.org>
3854
3855 * remote-utils.c (new_thread_notify): Remove.
3856 (dead_thread_notify): Likewise.
3857 * remote-utils.h (new_thread_notify): Remove declaration.
3858 (dead_thread_notify): Likewise.
3859
3860 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
3861
3862 * gdb.trace/pending.exp: Fix expected message on continue.
3863
3864 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
3865
3866 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
3867 it works properly on big-endian machines where sizeof (CORE_ADDR)
3868 != sizeof (void *).
3869
3870 2016-01-21 Pedro Alves <palves@redhat.com>
3871
3872 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
3873 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
3874 * configure: Regenerate.
3875
3876 2016-01-21 Yao Qi <yao.qi@linaro.org>
3877
3878 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
3879 is_thumb and set it according to CPSR saved on the stack.
3880 (get_next_pcs_syscall_next_pc): Pass is_thumb to
3881 arm_sigreturn_next_pc.
3882
3883 2016-01-18 Yao Qi <yao.qi@linaro.org>
3884
3885 * linux-low.c (linux_set_pc_64bit): New function.
3886 (linux_get_pc_64bit): New function.
3887 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
3888 Declare.
3889 * linux-sparc-low.c (debug_threads): Remove declaration.
3890 (sparc_get_pc): Remove.
3891 (the_low_target): Use linux_get_pc_64bit instead of
3892 sparc_get_pc.
3893 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
3894 (the_low_target): Use linux_get_pc_64bit and
3895 linux_set_pc_64bit.
3896
3897 2016-01-18 Yao Qi <yao.qi@linaro.org>
3898
3899 * linux-arm-low.c (debug_threads): Remove declaration.
3900 (arm_get_pc, arm_set_pc): Remove.
3901 (the_low_target): Use linux_get_pc_32bit and
3902 linux_set_pc_32bit.
3903 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
3904 (the_low_target): Use linux_get_pc_32bit and
3905 linux_set_pc_32bit.
3906 * linux-cris-low.c (debug_threads): Remove declaration.
3907 (cris_get_pc, cris_set_pc,): Remove.
3908 (the_low_target): Use linux_get_pc_32bit and
3909 linux_set_pc_32bit.
3910 * linux-crisv32-low.c (debug_threads): Remove declaration.
3911 (cris_get_pc, cris_set_pc): Remove.
3912 (the_low_target): Use linux_get_pc_32bit and
3913 linux_set_pc_32bit.
3914 * linux-low.c: Include inttypes.h.
3915 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
3916 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
3917 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
3918 (the_low_target): Use linux_get_pc_32bit and
3919 linux_set_pc_32bit.
3920 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
3921 (the_low_target): Use linux_get_pc_32bit and
3922 linux_set_pc_32bit.
3923 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
3924 (the_low_target): Use linux_get_pc_32bit and
3925 linux_set_pc_32bit.
3926 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
3927 (the_low_target): Use linux_get_pc_32bit and
3928 linux_set_pc_32bit.
3929 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
3930 (the_low_target): Use linux_get_pc_32bit and
3931 linux_set_pc_32bit.
3932
3933 2016-01-18 Gary Benson <gbenson@redhat.com>
3934
3935 * configure.ac (AC_FUNC_FORK): New check.
3936 * config.in: Regenerate.
3937 * configure: Likewise.
3938
3939 2016-01-14 Yao Qi <yao.qi@linaro.org>
3940
3941 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
3942 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
3943 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
3944 arm_get_next_pcs_ctor.
3945
3946 2016-01-12 Josh Stone <jistone@redhat.com>
3947 Philippe Waroquiers <philippe.waroquiers@skynet.be>
3948
3949 * inferiors.h: Include "gdb_vecs.h".
3950 (struct process_info): Add syscalls_to_catch.
3951 * inferiors.c (remove_process): Free syscalls_to_catch.
3952 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
3953 syscall_return stops.
3954 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
3955 * server.c (handle_general_set): Handle QCatchSyscalls.
3956 (handle_query): Report support for QCatchSyscalls.
3957 * target.h (struct target_ops): Add supports_catch_syscall.
3958 (target_supports_catch_syscall): New macro.
3959 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
3960 (struct lwp_info): Add syscall_state.
3961 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
3962 Maintain syscall_state and syscalls_to_catch across exec.
3963 (get_syscall_trapinfo): New function, proxy to the_low_target.
3964 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
3965 (linux_low_filter_event): Toggle syscall_state entry/return for
3966 syscall traps, and set it ignored for all others.
3967 (gdb_catching_syscalls_p): New function.
3968 (gdb_catch_this_syscall_p): New function.
3969 (linux_wait_1): Handle SYSCALL_SIGTRAP.
3970 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
3971 (linux_supports_catch_syscall): New function.
3972 (linux_target_ops): Install it.
3973 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
3974 (the_low_target): Install it.
3975
3976 2016-01-12 Mike Frysinger <vapier@gentoo.org>
3977
3978 * acinclude.m4: Include new ../warning.m4 file.
3979 * configure: Regenerated.
3980 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
3981
3982 2016-01-12 Mike Frysinger <vapier@gentoo.org>
3983
3984 * ax.c (is_goto_target): Mark static.
3985 * linux-low.c (register_addr): Likewise.
3986 (linux_fetch_registers, linux_store_registers): Likewise.
3987 * mem-break.c (any_persistent_commands): Fix old prototype.
3988 (add_commands_to_breakpoint): Mark static.
3989 * regcache.c (find_register_by_name): Delete unused func.
3990 * remote-utils.c (hex_or_minus_one): Mark static.
3991 * server.c (monitor_show_help): Mark static.
3992 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
3993 handle_v_requests): Likewise.
3994
3995 2016-01-12 Pedro Alves <palves@redhat.com>
3996
3997 Remove use of the registered trademark symbol throughout.
3998
3999 2016-01-08 Yao Qi <yao.qi@linaro.org>
4000
4001 * remote-utils.c (getpkt): If c is '\003', call target hook
4002 request_interrupt.
4003
4004 2016-01-06 Yao Qi <yao.qi@linaro.org>
4005
4006 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4007 linux-aarch32-low.c.
4008 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4009 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4010 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4011 (thumb2_breakpoint): Declare.
4012 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4013 linux-aarch32-low.h.
4014 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4015 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4016 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4017
4018 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4019
4020 * gdbreplay.c (gdbreplay_version): Change copyright year in
4021 version message.
4022 * server.c (gdbserver_version): Likewise.
4023
4024 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4025
4026 * server.c (crc32_table): Delete.
4027 (crc32): Use libiberty's xcrc32 function.
4028
4029 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4030
4031 * lynx-low.c (lynx_delete_thread_callback): New function.
4032 (lynx_mourn): Properly delete our process and all of its
4033 threads. Remove call to clear_inferiors.
4034
4035 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4036
4037 * target.c (thread_search_callback): Add check that
4038 the thread_stopped target callback is not NULL before
4039 calling it.
4040
4041 2015-12-21 Yao Qi <yao.qi@linaro.org>
4042
4043 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4044 arm breakpoint.
4045
4046 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4047
4048 * server.c (handle_query): Call target_supports_software_single_step.
4049
4050 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4051
4052 * linux-low.c (single_step): New function.
4053 (linux_resume_one_lwp_throw): Call single_step.
4054 (start_step_over): Likewise.
4055
4056 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4057
4058 * Makefile.in (SFILES): Append arch/arm-linux.c,
4059 arch/arm-get-next-pcs.c.
4060 (arm-linux.o): New rule.
4061 (arm-get-next-pcs.o): New rule.
4062 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4063 arm-linux.o.
4064 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4065 to linux-aarch32-low.c.
4066 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4067 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4068 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4069 (thumb2_breakpoint_len): Likewise.
4070 (arm_is_thumb_mode): Make non-static.
4071 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4072 from linux-aarch32-low.c.
4073 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4074 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4075 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4076 (thumb2_breakpoint_len): Likewise.
4077 (arm_is_thumb_mode): New declaration.
4078 * linux-arm-low.c: Include arch/arm-linux.h
4079 aarch/arm-get-next-pcs.h, sys/syscall.h.
4080 (get_next_pcs_ops): New struct.
4081 (get_next_pcs_addr_bits_remove): New function.
4082 (get_next_pcs_is_thumb): New function.
4083 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4084 (arm_sigreturn_next_pc): Likewise.
4085 (get_next_pcs_syscall_next_pc): Likewise.
4086 (arm_gdbserver_get_next_pcs): Likewise.
4087 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4088 Initialize.
4089 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4090 * server.h: Include gdb_vecs.h.
4091
4092 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4093
4094 * Makefile.in (SFILES): Append common/common-regcache.c.
4095 (OBS): Append common-regcache.o.
4096 (common-regcache.o): New rule.
4097 * regcache.c (init_register_cache): Initialize cache to
4098 REG_UNAVAILABLE.
4099 (regcache_raw_read_unsigned): New function.
4100 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4101 register_status enum.
4102
4103 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4104
4105 * linux-aarch64-low.c (the_low_targets): Rename
4106 breakpoint_reinsert_addr to get_next_pcs.
4107 * linux-arm-low.c (the_low_targets): Likewise.
4108 * linux-bfin-low.c (the_low_targets): Likewise.
4109 * linux-cris-low.c (the_low_targets): Likewise.
4110 * linux-crisv32-low.c (the_low_targets): Likewise.
4111 * linux-low.c (can_software_single_step): Likewise.
4112 (install_software_single_step_breakpoints): New function.
4113 (start_step_over): Use install_software_single_step_breakpoints.
4114 * linux-low.h: New CORE_ADDR vector.
4115 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4116 get_next_pcs.
4117 * linux-mips-low.c (the_low_targets): Likewise.
4118 * linux-nios2-low.c (the_low_targets): Likewise.
4119 * linux-sparc-low.c (the_low_targets): Likewise.
4120
4121 2015-12-17 Pedro Alves <palves@redhat.com>
4122
4123 * linux-low.c (linux_kill_one_lwp): Remove references to
4124 LinuxThreads.
4125 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4126 to 'kill'.
4127 (linux_init_signals): Delete.
4128 (initialize_low): Adjust.
4129 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4130
4131 2015-12-16 Pedro Alves <palves@redhat.com>
4132
4133 * configure.ac (compiler warning flags): When testing a
4134 -Wno-foo option, check whether -Wfoo works instead.
4135 * configure: Regenerate.
4136
4137 2015-12-11 Don Breazeal <donb@codesourcery.com>
4138
4139 * server.c (process_serial_event): Don't exit from gdbserver
4140 in remote mode if there are still active inferiors.
4141
4142 2015-12-11 Yao Qi <yao.qi@linaro.org>
4143
4144 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4145 arm_breakpoint_at if the process is 32-bit.
4146
4147 2015-12-11 Yao Qi <yao.qi@linaro.org>
4148
4149 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4150 arm breakpoint.
4151
4152 2015-12-07 Yao Qi <yao.qi@linaro.org>
4153
4154 * configure.srv: Append arm.o to srv_tgtobj for
4155 aarch64*-*-linux* target.
4156 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4157 from linux-arm-low.c.
4158 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4159 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4160 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4161 (thumb2_breakpoint_len): Likewise.
4162 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4163 (arm_breakpoint_kinds): Likewise.
4164 (arm_breakpoint_kind_from_pc): Likewise.
4165 (arm_sw_breakpoint_from_kind): Likewise.
4166 (arm_breakpoint_kind_from_current_state): Likewise.
4167 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4168 (arm_sw_breakpoint_from_kind): Declare.
4169 (arm_breakpoint_kind_from_current_state): Declare.
4170 (arm_breakpoint_at): Declare.
4171 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4172 arm_sw_breakpoint_from_kind if process is 32-bit.
4173 (aarch64_breakpoint_kind_from_pc): New function.
4174 (aarch64_breakpoint_kind_from_current_state): New function.
4175 (the_low_target): Initialize fields breakpoint_kind_from_pc
4176 and breakpoint_kind_from_current_state.
4177 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4178 linux-aarch32-low.c.
4179 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4180 (arm_breakpoint, arm_breakpoint_len): Likewise.
4181 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4182 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4183 (arm_is_thumb_mode): Likewise.
4184 (arm_breakpoint_at): Likewise.
4185 (arm_breakpoint_kind_from_pc): Likewise.
4186 (arm_sw_breakpoint_from_kind): Likewise.
4187 (arm_breakpoint_kind_from_current_state): Likewise.
4188
4189 Revert:
4190 2015-08-04 Yao Qi <yao.qi@linaro.org>
4191
4192 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4193 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4194 * server.c (extended_protocol): Remove "static".
4195 * server.h (extended_protocol): Declare it.
4196
4197 2015-12-04 Josh Stone <jistone@redhat.com>
4198
4199 * target.h (struct target_ops) <arch_setup>: Rename to ...
4200 (struct target_ops) <post_create_inferior>: ... this.
4201 (target_arch_setup): Rename to ...
4202 (target_post_create_inferior): ... this, calling post_create_inferior.
4203 * server.c (start_inferior): Update target_arch_setup calls to
4204 target_post_create_inferior.
4205 * linux-low.c (linux_low_ptrace_options): Forward declare.
4206 (linux_arch_setup): Update its comment for general use.
4207 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4208 (struct linux_target_ops): Use linux_post_create_inferior.
4209 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4210 to post_create_inferior.
4211 * nto-low.c (struct nto_target_ops): Likewise.
4212 * spu-low.c (struct spu_target_ops): Likewise.
4213 * win32-low.c (struct win32_target_ops): Likewise.
4214
4215 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4216
4217 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4218
4219 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4220
4221 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4222 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4223 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4224 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4225 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4226 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4227 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4228 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4229 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4230 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4231 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4232 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4233
4234 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4235
4236 * linux-low.c (linux_look_up_symbols): Don't call
4237 linux_supports_traceclone.
4238 * linux-low.h (thread_db_init): Remove use_events argument.
4239 * thread-db.c (thread_db_use_event): Remove global variable.
4240 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4241 (struct thread_db) <td_create_bp>: Remove field.
4242 (thread_db_create_event): Remove function.
4243 (thread_db_enable_reporting): Likewise.
4244 (find_one_thread): Don't check for thread_db_use_events.
4245 (attach_thread): Likewise.
4246 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4247 (try_thread_db_load_1): Don't check for thread_db_use_events.
4248 (thread_db_init): Remove use_events argument and thread events
4249 handling.
4250 (remove_thread_event_breakpoints): Remove function.
4251 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4252
4253 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4254
4255 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4256 New function.
4257 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4258 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4259 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4260 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4261 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4262 Initialize.
4263 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4264 New function.
4265 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4266 * linux-low.c (can_hardware_single_step): Use
4267 supports_hardware_single_step.
4268 (can_software_single_step): New function.
4269 (start_step_over): Call can_software_single_step.
4270 (linux_supports_hardware_single_step): New function.
4271 (struct target_ops) <supports_software_single_step>: Initialize.
4272 * linux-low.h (struct linux_target_ops)
4273 <supports_hardware_single_step>: Initialize.
4274 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4275 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4276 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4277 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4278 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4279 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4280 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4281 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4282 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4283 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4284 Initialize.
4285 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4286 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4287 Initialize.
4288 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4289 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4290 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4291 New function.
4292 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4293 * target.h (struct target_ops): <supports_software_single_step>:
4294 New field.
4295 (target_supports_software_single_step): New macro.
4296
4297 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4298
4299 * linux-low.c (linux_wait_1): Fix pc advance condition.
4300 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4301 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4302
4303 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4304
4305 * linux-arm-low.c (arm_is_thumb_mode): New function.
4306 (arm_breakpoint_at): Use arm_is_thumb_mode.
4307 (arm_breakpoint_kind_from_current_state): New function.
4308 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4309 Initialize.
4310 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4311 (linux_breakpoint_kind_from_current_state): New function.
4312 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4313 * linux-low.h (struct linux_target_ops)
4314 <breakpoint_kind_from_current_state>: New field.
4315 * target.h (struct target_ops): Likewise.
4316 (target_breakpoint_kind_from_current_state): New macro.
4317
4318 2015-11-30 Pedro Alves <palves@redhat.com>
4319
4320 * linux-low.c (linux_resume): Wake up the event loop before
4321 returning.
4322
4323 2015-11-30 Pedro Alves <palves@redhat.com>
4324
4325 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4326 check.
4327 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4328 to -1.
4329 * target.c (struct thread_search): New structure.
4330 (thread_search_callback): New function.
4331 (prev_general_thread): New global.
4332 (prepare_to_access_memory, done_accessing_memory): New functions.
4333 * target.h (prepare_to_access_memory, done_accessing_memory):
4334 Replace macros with function declarations.
4335
4336 2015-11-30 Pedro Alves <palves@redhat.com>
4337
4338 PR 14618
4339 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4340 report TARGET_WAITKIND_NO_RESUMED.
4341 * remote-utils.c (prepare_resume_reply): Handle
4342 TARGET_WAITKIND_NO_RESUMED.
4343 * server.c (report_no_resumed): New global.
4344 (handle_query) <qSupported>: Handle "no-resumed+". Report
4345 "no-resumed+" support.
4346 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4347 return error if the client doesn't support no-resumed events.
4348 (push_stop_notification): New function.
4349 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4350 events if the client supports them.
4351
4352 2015-11-30 Pedro Alves <palves@redhat.com>
4353
4354 * linux-low.c (thread_still_has_status_pending_p): Don't check
4355 vCont;t here.
4356 (lwp_resumed): New function.
4357 (status_pending_p_callback): Return early if the LWP is not
4358 supposed to be resumed.
4359
4360 2015-11-30 Pedro Alves <palves@redhat.com>
4361
4362 * linux-low.c (handle_extended_wait): Assert that the LWP's
4363 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4364 thread create events, leave the new child's status pending.
4365 (linux_low_filter_event): If GDB wants to hear about thread exit
4366 events, leave the LWP marked dead and don't delete it.
4367 (linux_wait_for_event_filtered): Don't check for thread exit.
4368 (filter_exit_event): New function.
4369 (linux_wait_1): Use it, when returning an exit event.
4370 (linux_resume_one_lwp_throw): Assert that the LWP's
4371 waitstatus is TARGET_WAITKIND_IGNORE.
4372 * remote-utils.c (prepare_resume_reply): Handle
4373 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4374 * server.c (report_thread_events): New global.
4375 (handle_general_set): Handle QThreadEvents.
4376 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4377 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4378 TARGET_WAITKIND_THREAD_EXITED.
4379 * server.h (report_thread_events): Declare.
4380
4381 2015-11-30 Pedro Alves <palves@redhat.com>
4382
4383 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4384 the thread's last_resume_kind was resume_stop.
4385
4386 2015-11-30 Pedro Alves <palves@redhat.com>
4387
4388 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4389 before returning.
4390
4391 2015-11-30 Pedro Alves <palves@redhat.com>
4392
4393 * server.c (handle_v_requests): Handle vCtrlC.
4394
4395 2015-11-30 Pedro Alves <palves@redhat.com>
4396
4397 * gdbthread.h (find_any_thread_of_pid): Declare.
4398 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4399 functions.
4400 * server.c (handle_query): If current_thread is NULL, look for
4401 another thread of the selected process.
4402
4403 2015-11-26 Daniel Colascione <dancol@dancol.org>
4404 Simon Marchi <simon.marchi@ericsson.com>
4405
4406 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4407 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4408 name in reply.
4409 * target.h (struct target_ops) <thread_name>: New field.
4410 (target_thread_name): New macro.
4411
4412 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4413
4414 * regcache.h (regcache_invalidate_pid): Add declaration.
4415 * regcache.c (regcache_invalidate_pid): New function, extracted
4416 from regcache_invalidate.
4417 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4418 Add trivial documentation comment.
4419 * lynx-low.c: Use regcache_invalidate_pid instead of
4420 regcache_invalidate.
4421
4422 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4423
4424 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4425 and Elf64_auxv_t if the target is Android.
4426
4427 2015-11-22 Doug Evans <xdje42@gmail.com>
4428
4429 * target.h: #include <sys/types.h>.
4430
4431 2015-11-19 Pedro Alves <palves@redhat.com>
4432
4433 * linux-low.c (linux_process_qsupported): Change prototype.
4434 Adjust.
4435 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4436 Change prototype.
4437 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4438 and adjust to loop over all features.
4439 * server.c (handle_query) <qSupported>: Adjust to call
4440 target_process_qsupported once, passing it a vector of unprocessed
4441 features.
4442 * target.h (struct target_ops) <process_qsupported>: Change
4443 prototype.
4444 (target_process_qsupported): Adjust.
4445
4446 2015-11-19 Pedro Alves <palves@redhat.com>
4447
4448 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4449 mode.
4450 * configure: Regenerate.
4451
4452 2015-11-19 Pedro Alves <palves@redhat.com>
4453
4454 * configure: Regenerate.
4455
4456 2015-11-19 Yao Qi <yao.qi@linaro.org>
4457
4458 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4459 type to uint32_t.
4460
4461 2015-11-19 Yao Qi <yao.qi@linaro.org>
4462
4463 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4464 (struct aarch64_operand): Move enum out.
4465
4466 2015-11-19 Yao Qi <yao.qi@linaro.org>
4467
4468 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
4469 struct user_fpsimd_state *.
4470 (aarch64_store_fpregset): Likewise.
4471
4472 2015-11-19 Yao Qi <yao.qi@linaro.org>
4473
4474 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
4475 struct user_pt_regs *.
4476 (aarch64_store_gregset): Likewise.
4477
4478 2015-11-18 Pedro Alves <palves@redhat.com>
4479
4480 * Makefile.in (all_object_files): Add $IPA_OBJS.
4481
4482 2015-11-17 Pedro Alves <palves@redhat.com>
4483
4484 * win32-low.c (win32_resume): Use gdb_signal_from_host,
4485 GDB_SIGNAL_0 and gdb_signal_to_string.
4486
4487 2015-11-17 Pedro Alves <palves@redhat.com>
4488
4489 * win32-low.c (handle_output_debug_string): Remove parameter.
4490 (win32_kill): Remove our_status local and adjust call to
4491 handle_output_debug_string.
4492 (get_child_debug_event): Adjust call to
4493 handle_output_debug_string.
4494
4495 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4496
4497 * linux-mips-low.c (mips_fill_gregset): Add cast.
4498 (mips_store_gregset): Likewise.
4499 (mips_fill_fpregset): Likewise.
4500 (mips_store_fpregset): Likewise.
4501
4502 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4503
4504 * linux-mips-low.c (mips_add_watchpoint): Rename private to
4505 priv.
4506
4507 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4508
4509 * linux-mips-low.c (mips_linux_new_thread): Change type of
4510 watch_type to enum target_hw_bp_type.
4511
4512 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4513
4514 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
4515 Change return type to arm_hwbp_type.
4516
4517 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4518
4519 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
4520 (arm_store_gregset): Likewise.
4521 * linux-arm-low.c (arm_get_hwcap): Likewise.
4522 (arm_read_description): Likewise.
4523
4524 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4525
4526 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
4527
4528 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4529
4530 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
4531 (ppc_fill_vsxregset): Likewise.
4532 (ppc_store_vsxregset): Likewise.
4533 (ppc_fill_vrregset): Likewise.
4534 (ppc_store_vrregset): Likewise.
4535 (ppc_fill_evrregset): Likewise.
4536 (ppc_store_evrregset): Likewise.
4537
4538 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4539
4540 * linux-ppc-low.c (ppc_usrregs_info): Remove
4541 forward-declaration.
4542 (ppc_arch_setup): Move lower in file.
4543
4544 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
4545
4546 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
4547 (ps_pdwrite): Likewise.
4548
4549 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
4550
4551 * linux-arm-low.c (arm_new_thread): Move pointer dereference
4552 to after assert checks.
4553
4554 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
4555
4556 * proc-service.c (ps_pdread): Add/adjust casts.
4557 (ps_pdwrite): Add/adjust casts.
4558
4559 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4560
4561 * server.c (handle_search_memory_1): Cast return value of
4562 memmem.
4563
4564 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4565
4566 * server.c (write_qxfer_response): Change type of data to
4567 gdb_byte *.
4568
4569 2015-10-29 Pedro Alves <palves@redhat.com>
4570
4571 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
4572
4573 2015-10-29 Pedro Alves <palves@redhat.com>
4574
4575 * tracepoint.c (clear_installed_tracepoints): Add casts.
4576
4577 2015-10-29 Pedro Alves <palves@redhat.com>
4578
4579 * server.c (handle_v_cont, process_serial_event): Add enum
4580 gdb_signal casts to signal parsing code.
4581
4582 2015-10-29 Pedro Alves <palves@redhat.com>
4583
4584 * linux-low.h (NULL_REGSET): Define.
4585 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4586 * linux-arm-low.c (arm_regsets): Likewise.
4587 * linux-crisv32-low.c (cris_regsets): Likewise.
4588 * linux-m68k-low.c (m68k_regsets): Likewise.
4589 * linux-mips-low.c (mips_regsets): Likewise.
4590 * linux-nios2-low.c (nios2_regsets): Likewise.
4591 * linux-ppc-low.c (ppc_regsets): Likewise.
4592 * linux-s390-low.c (s390_regsets): Likewise.
4593 * linux-sh-low.c (sh_regsets): Likewise.
4594 * linux-sparc-low.c (sparc_regsets): Likewise.
4595 * linux-tic6x-low.c (tic6x_regsets): Likewise.
4596 * linux-tile-low.c (tile_regsets): Likewise.
4597 * linux-x86-low.c (x86_regsets): Likewise.
4598 * linux-xtensa-low.c (xtensa_regsets): Likewise.
4599
4600 2015-10-29 Pedro Alves <palves@redhat.com>
4601
4602 * linux-low.h (NULL_REGSET): Define.
4603 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4604 * linux-arm-low.c (arm_regsets): Likewise.
4605 * linux-crisv32-low.c (cris_regsets): Likewise.
4606 * linux-m68k-low.c (m68k_regsets): Likewise.
4607 * linux-mips-low.c (mips_regsets): Likewise.
4608 * linux-nios2-low.c (nios2_regsets): Likewise.
4609 * linux-ppc-low.c (ppc_regsets): Likewise.
4610 * linux-s390-low.c (s390_regsets): Likewise.
4611 * linux-sh-low.c (sh_regsets): Likewise.
4612 * linux-sparc-low.c (sparc_regsets): Likewise.
4613 * linux-tic6x-low.c (tic6x_regsets): Likewise.
4614 * linux-tile-low.c (tile_regsets): Likewise.
4615 * linux-x86-low.c (x86_regsets): Likewise.
4616 * linux-xtensa-low.c (xtensa_regsets): Likewise.
4617
4618 2015-10-26 Doug Evans <dje@google.com>
4619
4620 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
4621
4622 2015-10-26 Doug Evans <dje@google.com>
4623
4624 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
4625
4626 2015-10-26 Doug Evans <dje@google.com>
4627
4628 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
4629 for debug_printf.
4630 (attach_thread, find_new_threads_callback): Ditto.
4631
4632 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4633
4634 * mem-break.h (set_breakpoint_data): Remove.
4635
4636 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4637
4638 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
4639 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4640 (initialize_low): Remove set_breakpoint_data call.
4641 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
4642 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
4643 (initialize_low): Remove set_breakpoint_data call.
4644 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
4645 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4646 (initialize_low): Remove set_breakpoint_data call.
4647
4648 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4649
4650 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
4651 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
4652 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
4653 * target.h (target_breakpoint_kind_from_pc): New macro.
4654
4655 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
4656
4657 * linux-low.c (default_breakpoint_kind_from_pc): New function.
4658 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
4659 the default breakpoint kind.
4660
4661 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4662
4663 * linux-arm-low.c (arm_supports_z_point_type): Add software
4664 breakpoint support.
4665
4666 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4667
4668 * linux-arm-low.c: Refactor breakpoint definitions.
4669 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
4670 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
4671
4672 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4673
4674 * Makefile.in: Add arm.c/o.
4675 * configure.srv: Likewise.
4676 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
4677 (arm_breakpoint_kind_from_pc): New function.
4678 (arm_sw_breakpoint_from_kind): Return proper kind.
4679 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
4680
4681 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4682
4683 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
4684 removal.
4685 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
4686 (struct raw_breakpoint) <size>: Remove.
4687 (struct raw_breakpoint) <kind>: Add.
4688 (bp_size): New function.
4689 (bp_opcode): Likewise.
4690 (find_raw_breakpoint_at): Adjust for kind.
4691 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
4692 (remove_memory_breakpoint): Adjust for kind call bp_size.
4693 (set_raw_breakpoint_at): Adjust for kind.
4694 (set_breakpoint): Likewise.
4695 (set_breakpoint_at): Call breakpoint_kind_from_pc.
4696 (delete_raw_breakpoint): Adjust for kind.
4697 (delete_breakpoint): Likewise.
4698 (find_gdb_breakpoint): Likewise.
4699 (set_gdb_breakpoint_1): Likewise.
4700 (set_gdb_breakpoint): Likewise.
4701 (delete_gdb_breakpoint_1): Likewise.
4702 (delete_gdb_breakpoint): Likewise.
4703 (uninsert_raw_breakpoint): Likewise.
4704 (reinsert_raw_breakpoint): Likewise.
4705 (set_breakpoint_data): Remove.
4706 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
4707 (check_mem_read): Adjust for kind call bp_size.
4708 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
4709 (clone_one_breakpoint): Adjust for kind.
4710 * mem-break.h (set_gdb_breakpoint): Likewise.
4711 (delete_gdb_breakpoint): Likewise.
4712 * server.c (process_serial_event): Likewise.
4713
4714 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4715
4716 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
4717 (struct linux_target_ops) <breakpoint>: Remove.
4718 (struct linux_target_ops) <breakpoint_len>: Remove.
4719 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4720 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4721 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
4722 (arm_sw_breakpoint_from_kind): New function.
4723 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
4724 (struct linux_target_ops) <breakpoint>: Remove.
4725 (struct linux_target_ops) <breakpoint_len>: Remove.
4726 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4727 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4728 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
4729 (struct linux_target_ops) <breakpoint>: Remove.
4730 (struct linux_target_ops) <breakpoint_len>: Remove.
4731 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4732 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4733 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
4734 (struct linux_target_ops) <breakpoint>: Remove.
4735 (struct linux_target_ops) <breakpoint_len>: Remove.
4736 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4737 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4738 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
4739 and sw_breakpoint_from_kind to increment the pc.
4740 (linux_breakpoint_kind_from_pc): New function.
4741 (linux_sw_breakpoint_from_kind): New function.
4742 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
4743 (initialize_low): Call breakpoint_kind_from_pc and
4744 sw_breakpoint_from_kind to replace breakpoint_data/len.
4745 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
4746 New field.
4747 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
4748 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
4749 (struct linux_target_ops) <breakpoint>: Remove.
4750 (struct linux_target_ops) <breakpoint_len>: Remove.
4751 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4752 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4753 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
4754 (struct linux_target_ops) <breakpoint>: Remove.
4755 (struct linux_target_ops) <breakpoint_len>: Remove.
4756 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4757 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4758 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
4759 (struct linux_target_ops) <breakpoint>: Remove.
4760 (struct linux_target_ops) <breakpoint_len>: Remove.
4761 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4762 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4763 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
4764 (struct linux_target_ops) <breakpoint>: Remove.
4765 (struct linux_target_ops) <breakpoint_len>: Remove.
4766 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4767 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4768 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
4769 (struct linux_target_ops) <breakpoint>: Remove.
4770 (struct linux_target_ops) <breakpoint_len>: Remove.
4771 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4772 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4773 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
4774 (struct linux_target_ops) <breakpoint>: Remove.
4775 (struct linux_target_ops) <breakpoint_len>: Remove.
4776 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4777 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4778 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
4779 (struct linux_target_ops) <breakpoint>: Remove.
4780 (struct linux_target_ops) <breakpoint_len>: Remove.
4781 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4782 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4783 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
4784 (struct linux_target_ops) <breakpoint>: Remove.
4785 (struct linux_target_ops) <breakpoint_len>: Remove.
4786 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4787 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4788 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
4789 (struct linux_target_ops) <breakpoint>: Remove.
4790 (struct linux_target_ops) <breakpoint_len>: Remove.
4791 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4792 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4793 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
4794 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
4795 (struct linux_target_ops) <breakpoint>: Remove.
4796 (struct linux_target_ops) <breakpoint_len>: Remove.
4797 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4798 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4799 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
4800 (struct linux_target_ops) <breakpoint>: Remove.
4801 (struct linux_target_ops) <breakpoint_len>: Remove.
4802 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4803 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4804
4805 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4806
4807 * linux-cris-low.c (cris_get_pc): Remove void arg.
4808
4809 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4810
4811 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
4812 variable name.
4813
4814 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4815
4816 * inferiors.c (thread_pid_matches_callback): New function.
4817 (find_thread_process): New function.
4818 (remove_thread): Reset current_thread.
4819 (remove_process): Assert threads have been removed first.
4820
4821 2015-10-15 Yao Qi <yao.qi@linaro.org>
4822
4823 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
4824 if it is 3.
4825 (aarch64_remove_point): Likewise.
4826 * regcache.c (regcache_register_size): New function.
4827
4828 2015-10-12 Yao Qi <yao.qi@linaro.org>
4829
4830 * linux-aarch64-low.c: Update all callers as emit_load_store
4831 is renamed to aarch64_emit_load_store.
4832
4833 2015-10-12 Yao Qi <yao.qi@linaro.org>
4834
4835 * linux-aarch64-low.c: Update all callers of function renaming
4836 from emit_insn to aarch64_emit_insn.
4837
4838 2015-10-12 Yao Qi <yao.qi@linaro.org>
4839
4840 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
4841 arch/aarch64-insn.h.
4842 (struct aarch64_memory_operand): Likewise.
4843 (ENCODE): Likewise.
4844 (emit_insn): Move to arch/aarch64-insn.c.
4845 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
4846 (emit_load_store): Move to arch/aarch64-insn.c.
4847 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
4848 (can_encode_int32): Remove.
4849
4850 2015-10-12 Yao Qi <yao.qi@linaro.org>
4851
4852 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
4853 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
4854 (aarch64_relocate_instruction): Likewise.
4855 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
4856 (struct aarch64_insn_visitor): Likewise.
4857
4858 2015-10-12 Yao Qi <yao.qi@linaro.org>
4859
4860 * linux-aarch64-low.c (struct aarch64_insn_data): New.
4861 (struct aarch64_insn_visitor): New.
4862 (struct aarch64_insn_relocation_data): New.
4863 (aarch64_ftrace_insn_reloc_b): New function.
4864 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
4865 (aarch64_ftrace_insn_reloc_cb): Likewise.
4866 (aarch64_ftrace_insn_reloc_tb): Likewise.
4867 (aarch64_ftrace_insn_reloc_adr): Likewise.
4868 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
4869 (aarch64_ftrace_insn_reloc_others): Likewise.
4870 (visitor): New.
4871 (aarch64_relocate_instruction): Use visitor.
4872
4873 2015-10-12 Yao Qi <yao.qi@linaro.org>
4874
4875 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
4876 int. Add argument buf.
4877 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
4878 aarch64_relocate_instruction.
4879
4880 2015-10-12 Yao Qi <yao.qi@linaro.org>
4881
4882 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
4883 argument insn. Remove local variable insn. Don't call
4884 target_read_uint32.
4885 (aarch64_install_fast_tracepoint_jump_pad): Call
4886 target_read_uint32.
4887
4888 2015-09-30 Yao Qi <yao.qi@linaro.org>
4889
4890 * linux-aarch64-low.c (emit_movk): Shorten a long line.
4891 (emit_load_store_pair): Likewise.
4892
4893 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
4894
4895 * dll.c (match_dll): Add cast(s).
4896 (unloaded_dll): Likewise.
4897 * linux-low.c (second_thread_of_pid_p): Likewise.
4898 (delete_lwp_callback): Likewise.
4899 (count_events_callback): Likewise.
4900 (select_event_lwp_callback): Likewise.
4901 (linux_set_resume_request): Likewise.
4902 * server.c (accumulate_file_name_length): Likewise.
4903 (emit_dll_description): Likewise.
4904 (handle_qxfer_threads_worker): Likewise.
4905 (visit_actioned_threads): Likewise.
4906 * thread-db.c (any_thread_of): Likewise.
4907 * tracepoint.c (same_process_p): Likewise.
4908 (match_blocktype): Likewise.
4909 (build_traceframe_info_xml): Likewise.
4910
4911 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
4912
4913 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
4914 assignment.
4915 (gdb_unparse_agent_expr): Likewise.
4916 * hostio.c (require_data): Likewise.
4917 (handle_pread): Likewise.
4918 * linux-low.c (disable_regset): Likewise.
4919 (fetch_register): Likewise.
4920 (store_register): Likewise.
4921 (get_dynamic): Likewise.
4922 (linux_qxfer_libraries_svr4): Likewise.
4923 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
4924 (set_fast_tracepoint_jump): Likewise.
4925 (uninsert_fast_tracepoint_jumps_at): Likewise.
4926 (reinsert_fast_tracepoint_jumps_at): Likewise.
4927 (validate_inserted_breakpoint): Likewise.
4928 (clone_agent_expr): Likewise.
4929 * regcache.c (init_register_cache): Likewise.
4930 * remote-utils.c (putpkt_binary_1): Likewise.
4931 (decode_M_packet): Likewise.
4932 (decode_X_packet): Likewise.
4933 (look_up_one_symbol): Likewise.
4934 (relocate_instruction): Likewise.
4935 (monitor_output): Likewise.
4936 * server.c (handle_search_memory): Likewise.
4937 (handle_qxfer_exec_file): Likewise.
4938 (handle_qxfer_libraries): Likewise.
4939 (handle_qxfer): Likewise.
4940 (handle_query): Likewise.
4941 (handle_v_cont): Likewise.
4942 (handle_v_run): Likewise.
4943 (captured_main): Likewise.
4944 * target.c (write_inferior_memory): Likewise.
4945 * thread-db.c (try_thread_db_load_from_dir): Likewise.
4946 * tracepoint.c (init_trace_buffer): Likewise.
4947 (add_tracepoint_action): Likewise.
4948 (add_traceframe): Likewise.
4949 (add_traceframe_block): Likewise.
4950 (cmd_qtdpsrc): Likewise.
4951 (cmd_qtdv): Likewise.
4952 (cmd_qtstatus): Likewise.
4953 (response_source): Likewise.
4954 (response_tsv): Likewise.
4955 (cmd_qtnotes): Likewise.
4956 (gdb_collect): Likewise.
4957 (initialize_tracepoint): Likewise.
4958
4959 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
4960
4961 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
4962 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
4963 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
4964 <NOP>: New.
4965 (enum aarch64_condition_codes): New enum.
4966 (w0): New static global.
4967 (fp): Likewise.
4968 (lr): Likewise.
4969 (struct aarch64_memory_operand) <type>: New
4970 MEMORY_OPERAND_POSTINDEX type.
4971 (postindex_memory_operand): New helper function.
4972 (emit_ret): New function.
4973 (emit_load_store_pair): New function, factored out of emit_stp
4974 with support for MEMORY_OPERAND_POSTINDEX.
4975 (emit_stp): Rewrite using emit_load_store_pair.
4976 (emit_ldp): New function.
4977 (emit_load_store): Likewise.
4978 (emit_ldr): Mention post-index instruction in comment.
4979 (emit_ldrh): New function.
4980 (emit_ldrb): New function.
4981 (emit_ldrsw): Mention post-index instruction in comment.
4982 (emit_str): Likewise.
4983 (emit_subs): New function.
4984 (emit_cmp): Likewise.
4985 (emit_and): Likewise.
4986 (emit_orr): Likewise.
4987 (emit_orn): Likewise.
4988 (emit_eor): Likewise.
4989 (emit_mvn): Likewise.
4990 (emit_lslv): Likewise.
4991 (emit_lsrv): Likewise.
4992 (emit_asrv): Likewise.
4993 (emit_mul): Likewise.
4994 (emit_sbfm): Likewise.
4995 (emit_sbfx): Likewise.
4996 (emit_ubfm): Likewise.
4997 (emit_ubfx): Likewise.
4998 (emit_csinc): Likewise.
4999 (emit_cset): Likewise.
5000 (emit_nop): Likewise.
5001 (emit_ops_insns): New helper function.
5002 (emit_pop): Likewise.
5003 (emit_push): Likewise.
5004 (aarch64_emit_prologue): New function.
5005 (aarch64_emit_epilogue): Likewise.
5006 (aarch64_emit_add): Likewise.
5007 (aarch64_emit_sub): Likewise.
5008 (aarch64_emit_mul): Likewise.
5009 (aarch64_emit_lsh): Likewise.
5010 (aarch64_emit_rsh_signed): Likewise.
5011 (aarch64_emit_rsh_unsigned): Likewise.
5012 (aarch64_emit_ext): Likewise.
5013 (aarch64_emit_log_not): Likewise.
5014 (aarch64_emit_bit_and): Likewise.
5015 (aarch64_emit_bit_or): Likewise.
5016 (aarch64_emit_bit_xor): Likewise.
5017 (aarch64_emit_bit_not): Likewise.
5018 (aarch64_emit_equal): Likewise.
5019 (aarch64_emit_less_signed): Likewise.
5020 (aarch64_emit_less_unsigned): Likewise.
5021 (aarch64_emit_ref): Likewise.
5022 (aarch64_emit_if_goto): Likewise.
5023 (aarch64_emit_goto): Likewise.
5024 (aarch64_write_goto_address): Likewise.
5025 (aarch64_emit_const): Likewise.
5026 (aarch64_emit_call): Likewise.
5027 (aarch64_emit_reg): Likewise.
5028 (aarch64_emit_pop): Likewise.
5029 (aarch64_emit_stack_flush): Likewise.
5030 (aarch64_emit_zero_ext): Likewise.
5031 (aarch64_emit_swap): Likewise.
5032 (aarch64_emit_stack_adjust): Likewise.
5033 (aarch64_emit_int_call_1): Likewise.
5034 (aarch64_emit_void_call_2): Likewise.
5035 (aarch64_emit_eq_goto): Likewise.
5036 (aarch64_emit_ne_goto): Likewise.
5037 (aarch64_emit_lt_goto): Likewise.
5038 (aarch64_emit_le_goto): Likewise.
5039 (aarch64_emit_gt_goto): Likewise.
5040 (aarch64_emit_ge_got): Likewise.
5041 (aarch64_emit_ops_impl): New static global variable.
5042 (aarch64_emit_ops): New target function, return
5043 &aarch64_emit_ops_impl.
5044 (struct linux_target_ops): Install it.
5045
5046 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5047
5048 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5049 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5050 aarch64-ipa.o.
5051 * linux-aarch64-ipa.c: New file.
5052 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5053 and endian.h.
5054 (aarch64_get_thread_area): New target method.
5055 (extract_signed_bitfield): New helper function.
5056 (aarch64_decode_ldr_literal): New function.
5057 (enum aarch64_opcodes): New enum.
5058 (struct aarch64_register): New struct.
5059 (struct aarch64_operand): New struct.
5060 (x0): New static global.
5061 (x1): Likewise.
5062 (x2): Likewise.
5063 (x3): Likewise.
5064 (x4): Likewise.
5065 (w2): Likewise.
5066 (ip0): Likewise.
5067 (sp): Likewise.
5068 (xzr): Likewise.
5069 (aarch64_register): New helper function.
5070 (register_operand): Likewise.
5071 (immediate_operand): Likewise.
5072 (struct aarch64_memory_operand): New struct.
5073 (offset_memory_operand): New helper function.
5074 (preindex_memory_operand): Likewise.
5075 (enum aarch64_system_control_registers): New enum.
5076 (ENCODE): New macro.
5077 (emit_insn): New helper function.
5078 (emit_b): New function.
5079 (emit_bcond): Likewise.
5080 (emit_cb): Likewise.
5081 (emit_tb): Likewise.
5082 (emit_blr): Likewise.
5083 (emit_stp): Likewise.
5084 (emit_ldp_q_offset): Likewise.
5085 (emit_stp_q_offset): Likewise.
5086 (emit_load_store): Likewise.
5087 (emit_ldr): Likewise.
5088 (emit_ldrsw): Likewise.
5089 (emit_str): Likewise.
5090 (emit_ldaxr): Likewise.
5091 (emit_stxr): Likewise.
5092 (emit_stlr): Likewise.
5093 (emit_data_processing_reg): Likewise.
5094 (emit_data_processing): Likewise.
5095 (emit_add): Likewise.
5096 (emit_sub): Likewise.
5097 (emit_mov): Likewise.
5098 (emit_movk): Likewise.
5099 (emit_mov_addr): Likewise.
5100 (emit_mrs): Likewise.
5101 (emit_msr): Likewise.
5102 (emit_sevl): Likewise.
5103 (emit_wfe): Likewise.
5104 (append_insns): Likewise.
5105 (can_encode_int32_in): New helper function.
5106 (aarch64_relocate_instruction): New function.
5107 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5108 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5109 (struct linux_target_ops): Install aarch64_get_thread_area,
5110 aarch64_install_fast_tracepoint_jump_pad and
5111 aarch64_get_min_fast_tracepoint_insn_len.
5112
5113 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5114
5115 * Makefile.in (aarch64-insn.o): New rule.
5116 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5117
5118 2015-09-21 Yao Qi <yao.qi@linaro.org>
5119
5120 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5121
5122 2015-09-21 Yao Qi <yao.qi@linaro.org>
5123
5124 * tracepoint.c (max_jump_pad_size): Remove.
5125
5126 2015-09-18 Yao Qi <yao.qi@linaro.org>
5127
5128 * linux-aarch64-low.c: Don't include sys/uio.h.
5129 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5130
5131 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5132
5133 * tracepoint.c (eval_result_type): Change prototype.
5134 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5135
5136 2015-09-15 Pedro Alves <palves@redhat.com>
5137
5138 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5139 Check whether to report exec events instead of checking whether
5140 multiprocess is enabled.
5141
5142 2015-09-15 Pedro Alves <palves@redhat.com>
5143
5144 PR remote/18965
5145 * remote-utils.c (prepare_resume_reply): Merge
5146 TARGET_WAITKIND_VFORK_DONE switch case with the
5147 TARGET_WAITKIND_FORKED case.
5148
5149 2015-09-15 Yao Qi <yao.qi@linaro.org>
5150
5151 * server.c (handle_query): Check string comparison using
5152 "else if" instead of "if".
5153
5154 2015-09-15 Yao Qi <yao.qi@linaro.org>
5155
5156 * server.c (vCont_supported): New global variable.
5157 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5158 matches. Append ";vContSupported+" to own_buf.
5159 (handle_v_requests): Append ";s;S" to own_buf if target supports
5160 hardware single step or vCont_supported is false.
5161 (capture_main): Set vCont_supported to zero.
5162
5163 2015-09-15 Yao Qi <yao.qi@linaro.org>
5164
5165 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5166 it to ...
5167 (linux_supports_hardware_single_step): ... New function.
5168 (linux_target_ops): Update.
5169 * lynx-low.c (lynx_target_ops): Set field
5170 supports_hardware_single_step to target_can_do_hardware_single_step.
5171 * nto-low.c (nto_target_ops): Likewise.
5172 * spu-low.c (spu_target_ops): Likewise.
5173 * win32-low.c (win32_target_ops): Likewise.
5174 * target.c (target_can_do_hardware_single_step): New function.
5175 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5176 Remove. <supports_hardware_single_step>: New field.
5177 (target_supports_conditional_breakpoints): Remove.
5178 (target_supports_hardware_single_step): New macro.
5179 (target_can_do_hardware_single_step): Declare.
5180 * server.c (handle_query): Use target_supports_hardware_single_step
5181 instead of target_supports_conditional_breakpoints.
5182
5183 2015-09-15 Yao Qi <yao.qi@linaro.org>
5184
5185 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5186 function.
5187 (struct linux_target_ops the_low_target): Install
5188 aarch64_linux_siginfo_fixup.
5189
5190 2015-09-11 Don Breazeal <donb@codesourcery.com>
5191 Luis Machado <lgustavo@codesourcery.com>
5192
5193 * linux-low.c (linux_mourn): Static declaration.
5194 (linux_arch_setup): Move in front of
5195 handle_extended_wait.
5196 (linux_arch_setup_thread): New function.
5197 (handle_extended_wait): Handle exec events. Call
5198 linux_arch_setup_thread. Make event_lwp argument a
5199 pointer-to-a-pointer.
5200 (check_zombie_leaders): Do not check stopped threads.
5201 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5202 (linux_low_filter_event): Add lwp and thread for exec'ing
5203 non-leader thread if leader thread has been deleted.
5204 Refactor code into linux_arch_setup_thread and call it.
5205 Pass child lwp pointer by reference to handle_extended_wait.
5206 (linux_wait_for_event_filtered): Update comment.
5207 (linux_wait_1): Prevent clobbering exec event status.
5208 (linux_supports_exec_events): New function.
5209 (linux_target_ops) <supports_exec_events>: Initialize new member.
5210 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5211 new member.
5212 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5213 * server.c (report_exec_events): New global variable.
5214 (handle_query): Handle qSupported query for exec-events feature.
5215 (captured_main): Initialize report_exec_events.
5216 * server.h (report_exec_events): Declare new global variable.
5217 * target.h (struct target_ops) <supports_exec_events>: New
5218 member.
5219 (target_supports_exec_events): New macro.
5220 * win32-low.c (win32_target_ops) <supports_exec_events>:
5221 Initialize new member.
5222
5223 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5224
5225 * linux-low.c (linux_low_enable_btrace): Remove.
5226 (linux_target_ops): Replace linux_low_enable_btrace with
5227 linux_enable_btrace.
5228
5229 2015-09-03 Yao Qi <yao.qi@linaro.org>
5230
5231 * linux-aarch64-low.c (aarch64_insert_point): Call
5232 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5233 returns true.
5234
5235 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5236
5237 * linux-low.c (check_stopped_by_breakpoint): Use
5238 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5239
5240 2015-08-27 Pedro Alves <palves@redhat.com>
5241
5242 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5243
5244 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5245
5246 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5247 the XNEW-family equivalent.
5248 (compile_bytecodes): Likewise.
5249 * dll.c (loaded_dll): Likewise.
5250 * event-loop.c (append_callback_event): Likewise.
5251 (create_file_handler): Likewise.
5252 (create_file_event): Likewise.
5253 * hostio.c (handle_open): Likewise.
5254 * inferiors.c (add_thread): Likewise.
5255 (add_process): Likewise.
5256 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5257 * linux-arm-low.c (arm_new_process): Likewise.
5258 (arm_new_thread): Likewise.
5259 * linux-low.c (add_to_pid_list): Likewise.
5260 (linux_add_process): Likewise.
5261 (handle_extended_wait): Likewise.
5262 (add_lwp): Likewise.
5263 (enqueue_one_deferred_signal): Likewise.
5264 (enqueue_pending_signal): Likewise.
5265 (linux_resume_one_lwp_throw): Likewise.
5266 (linux_resume_one_thread): Likewise.
5267 (linux_read_memory): Likewise.
5268 (linux_write_memory): Likewise.
5269 * linux-mips-low.c (mips_linux_new_process): Likewise.
5270 (mips_linux_new_thread): Likewise.
5271 (mips_add_watchpoint): Likewise.
5272 * linux-x86-low.c (initialize_low_arch): Likewise.
5273 * lynx-low.c (lynx_add_process): Likewise.
5274 * mem-break.c (set_raw_breakpoint_at): Likewise.
5275 (set_breakpoint): Likewise.
5276 (add_condition_to_breakpoint): Likewise.
5277 (add_commands_to_breakpoint): Likewise.
5278 (clone_agent_expr): Likewise.
5279 (clone_one_breakpoint): Likewise.
5280 * regcache.c (new_register_cache): Likewise.
5281 * remote-utils.c (look_up_one_symbol): Likewise.
5282 * server.c (queue_stop_reply): Likewise.
5283 (start_inferior): Likewise.
5284 (queue_stop_reply_callback): Likewise.
5285 (handle_target_event): Likewise.
5286 * spu-low.c (fetch_ppc_memory): Likewise.
5287 (store_ppc_memory): Likewise.
5288 * target.c (set_target_ops): Likewise.
5289 * thread-db.c (thread_db_load_search): Likewise.
5290 (try_thread_db_load_1): Likewise.
5291 * tracepoint.c (add_tracepoint): Likewise.
5292 (add_tracepoint_action): Likewise.
5293 (create_trace_state_variable): Likewise.
5294 (cmd_qtdpsrc): Likewise.
5295 (cmd_qtro): Likewise.
5296 (add_while_stepping_state): Likewise.
5297 * win32-low.c (child_add_thread): Likewise.
5298 (get_image_name): Likewise.
5299
5300 2015-08-25 Yao Qi <yao.qi@linaro.org>
5301
5302 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5303
5304 2015-08-25 Yao Qi <yao.qi@linaro.org>
5305
5306 * Makefile.in (aarch64-linux.o): New rule.
5307 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5308 srv_tgtobj.
5309 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5310 (aarch64_init_debug_reg_state): Make it extern.
5311 (aarch64_linux_prepare_to_resume): Remove.
5312
5313 2015-08-25 Yao Qi <yao.qi@linaro.org>
5314
5315 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5316 lwp_arch_private_info and ptid_of_lwp.
5317
5318 2015-08-25 Yao Qi <yao.qi@linaro.org>
5319
5320 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5321 Find proc_info by find_process_pid. All callers updated.
5322
5323 2015-08-25 Yao Qi <yao.qi@linaro.org>
5324
5325 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5326 Remove.
5327 (debug_reg_change_callback): Remove.
5328 (aarch64_notify_debug_reg_change): Remove.
5329
5330 2015-08-25 Yao Qi <yao.qi@linaro.org>
5331
5332 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5333 Call current_lwp_ptid.
5334
5335 2015-08-25 Yao Qi <yao.qi@linaro.org>
5336
5337 * linux-aarch64-low.c (debug_reg_change_callback): Use
5338 debug_printf.
5339
5340 2015-08-25 Yao Qi <yao.qi@linaro.org>
5341
5342 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5343
5344 2015-08-25 Yao Qi <yao.qi@linaro.org>
5345
5346 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5347
5348 2015-08-25 Yao Qi <yao.qi@linaro.org>
5349
5350 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5351 the code.
5352
5353 2015-08-25 Yao Qi <yao.qi@linaro.org>
5354
5355 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5356 Remove.
5357 (debug_reg_change_callback): Remove argument entry and add argument
5358 lwp. Remove local variable thread. Don't print thread id in the
5359 debugging output. Don't check whether pid of thread equals to pid.
5360 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5361 iterate_over_lwps instead find_inferior.
5362
5363 2015-08-24 Pedro Alves <palves@redhat.com>
5364
5365 * inferiors.c (get_first_process): New function.
5366 * inferiors.h (get_first_process): New declaration.
5367 * remote-utils.c (read_ptid): Default to the first process in the
5368 list, instead of to the current thread's process.
5369
5370 2015-08-24 Pedro Alves <palves@redhat.com>
5371
5372 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5373 * event-loop.c: Likewise.
5374 * remote-utils.c: Likewise.
5375 * tracepoint.c: Likewise.
5376
5377 2015-08-24 Pedro Alves <palves@redhat.com>
5378
5379 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5380 ptid_get_lwp.
5381
5382 2015-08-21 Pedro Alves <palves@redhat.com>
5383
5384 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5385 instead of literal 1.
5386
5387 2015-08-21 Pedro Alves <palves@redhat.com>
5388
5389 * tdesc.c (default_description): Explicitly zero-initialize.
5390
5391 2015-08-21 Pedro Alves <palves@redhat.com>
5392
5393 PR gdb/18749
5394 * inferiors.c (remove_thread): Discard any pending stop reply for
5395 this thread.
5396 * server.c (remove_all_on_match_pid): Rename to ...
5397 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5398 instead of a pid.
5399 (discard_queued_stop_replies): Change parameter to a ptid. Now
5400 extern.
5401 (handle_v_kill, kill_inferior_callback, captured_main)
5402 (process_serial_event): Adjust.
5403 * server.h (discard_queued_stop_replies): Declare.
5404
5405 2015-08-21 Pedro Alves <palves@redhat.com>
5406
5407 * linux-low.c (wait_for_sigstop): Always switch to no thread
5408 selected if the previously current thread dies.
5409 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5410 process instead of the current thread's.
5411 * remote-utils.c (input_interrupt): Don't check if there's no
5412 current thread.
5413 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5414 current thread to the general thread fails, error out.
5415 (handle_qxfer_auxv, handle_qxfer_libraries)
5416 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5417 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5418 (handle_query): Check if there's a thread selected instead of
5419 checking whether there's any thread in the thread list.
5420 (handle_qxfer_threads, handle_qxfer_btrace)
5421 (handle_qxfer_btrace_conf): Don't error out early if there's no
5422 thread in the thread list.
5423 (handle_v_cont, myresume): Don't set the current thread to the
5424 continue thread.
5425 (process_serial_event) <Hg handling>: Also set thread_id if the
5426 previous general thread is still alive.
5427 (process_serial_event) <g/G handling>: If setting the current
5428 thread to the general thread fails, error out.
5429 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5430 thread's lwp instead of the current thread's.
5431 * target.c (set_desired_thread): If the desired thread was not
5432 found, leave the current thread pointing to NULL. Return an int
5433 (boolean) indicating success.
5434 * target.h (set_desired_thread): Change return type to int.
5435
5436 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5437
5438 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5439 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5440 #includes.
5441 (ps_get_thread_area): New function.
5442
5443 2015-08-19 Gary Benson <gbenson@redhat.com>
5444
5445 * hostio.c (handle_pread): Do not attempt to read more data
5446 than hostio_reply_with_data can fit in a packet.
5447
5448 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5449
5450 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5451
5452 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5453
5454 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5455
5456 2015-08-06 Pedro Alves <palves@redhat.com>
5457
5458 * tracepoint.c (expr_eval_result): Now an int.
5459
5460 2015-08-06 Pedro Alves <palves@redhat.com>
5461
5462 * gdbthread.h (struct regcache): Forward declare.
5463 (struct thread_info) <regcache_data>: Now a struct regcache
5464 pointer.
5465 * inferiors.c (inferior_regcache_data)
5466 (set_inferior_regcache_data): Now work with struct regcache
5467 pointers.
5468 * inferiors.h (struct regcache): Forward declare.
5469 (inferior_regcache_data, set_inferior_regcache_data): Now work
5470 with struct regcache pointers.
5471 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
5472 (free_register_cache_thread): Remove struct regcache pointer
5473 casts.
5474
5475 2015-08-06 Pedro Alves <palves@redhat.com>
5476
5477 * server.c (captured_main): On error, print the exception message
5478 to stderr, and if run_once is set, throw a quit.
5479
5480 2015-08-06 Pedro Alves <palves@redhat.com>
5481
5482 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
5483 the current thread.
5484
5485 2015-08-06 Pedro Alves <palves@redhat.com>
5486
5487 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
5488 reading beyond the passed in buffer length.
5489
5490 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
5491
5492 * tracepoint.c (symbol_list) <required>: Remove.
5493
5494 2015-08-06 Pedro Alves <palves@redhat.com>
5495
5496 * linux-low.c (handle_extended_wait): Set the fork child's suspend
5497 count if stopping and suspending threads.
5498 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
5499 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
5500 (linux_detach): Complete an ongoing step-over.
5501 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
5502 throughout.
5503 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
5504 (linux_wait_1): If passing a signal to the inferior after
5505 finishing a step-over, unsuspend and re-resume all lwps. If we
5506 see a single-step event but the thread should be continuing, don't
5507 pass the trap to gdb.
5508 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
5509 internal_error instead of gdb_assert.
5510 (enqueue_pending_signal): New function.
5511 (check_ptrace_stopped_lwp_gone): Add debug output.
5512 (start_step_over): Use internal_error instead of gdb_assert.
5513 (complete_ongoing_step_over): New function.
5514 (linux_resume_one_thread): Don't resume a suspended thread.
5515 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
5516 it stepping.
5517
5518 2015-08-06 Pedro Alves <palves@redhat.com>
5519
5520 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
5521 (linux_thread_alive): Use lwp_is_marked_dead.
5522 (extended_event_reported): Delete.
5523 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
5524 instead of extended_event_reported.
5525 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
5526 as well.
5527 (lwp_is_marked_dead): New function.
5528 (lwp_running): Use lwp_is_marked_dead.
5529 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
5530 comment.
5531
5532 2015-08-06 Pedro Alves <palves@redhat.com>
5533
5534 * linux-low.c (linux_wait_1): Move fork event output out of the
5535 !report_to_gdb check. Pass event_child->waitstatus to
5536 target_waitstatus_to_string instead of ourstatus.
5537
5538 2015-08-04 Yao Qi <yao.qi@linaro.org>
5539
5540 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
5541 if current_thread is 32 bit.
5542
5543 2015-08-04 Yao Qi <yao.qi@linaro.org>
5544
5545 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5546 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5547 * server.c (extended_protocol): Remove "static".
5548 * server.h (extended_protocol): Declare it.
5549
5550 2015-08-04 Yao Qi <yao.qi@linaro.org>
5551
5552 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
5553 both aarch64 and aarch32.
5554 (aarch64_set_pc): Likewise.
5555
5556 2015-08-04 Yao Qi <yao.qi@linaro.org>
5557
5558 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
5559 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
5560 arm-with-neon.xml to srv_xmlfiles.
5561 * linux-aarch64-low.c: Include linux-aarch32-low.h.
5562 (is_64bit_tdesc): New function.
5563 (aarch64_linux_read_description): New function.
5564 (aarch64_arch_setup): Call aarch64_linux_read_description.
5565 (regs_info): Rename to regs_info_aarch64.
5566 (aarch64_regs_info): Return right regs_info.
5567 (initialize_low_arch): Call initialize_low_arch_aarch32.
5568
5569 2015-08-04 Yao Qi <yao.qi@linaro.org>
5570
5571 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
5572 * linux-aarch32-low.c: New file.
5573 * linux-aarch32-low.h: New file.
5574 * linux-arm-low.c (arm_fill_gregset): Move it to
5575 linux-aarch32-low.c.
5576 (arm_store_gregset): Likewise.
5577 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
5578 (arm_store_vfpregset): Call arm_store_vfpregset_num.
5579 (arm_arch_setup): Check if PTRACE_GETREGSET works.
5580 (regs_info): Rename to regs_info_arm.
5581 (arm_regs_info): Return regs_info_aarch32 if
5582 have_ptrace_getregset is 1 and target description is
5583 arm_with_neon or arm_with_vfpv3.
5584 (initialize_low_arch): Don't call init_registers_arm_with_neon.
5585 Call initialize_low_arch_aarch32 instead.
5586
5587 2015-08-04 Yao Qi <yao.qi@linaro.org>
5588
5589 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
5590 * linux-low.c: ... here.
5591 * linux-low.h (have_ptrace_getregset): Declare it.
5592
5593 2015-08-04 Pedro Alves <palves@redhat.com>
5594
5595 * thread-db.c (struct thread_db): Use new typedefs.
5596 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
5597 CHK calls.
5598 (disable_thread_event_reporting): Cast result of dlsym to
5599 destination function pointer type.
5600 (thread_db_mourn): Use td_ta_delete_ftype.
5601
5602 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
5603
5604 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
5605 arch variant.
5606 (CDX_BREAKPOINT): Define for R2.
5607 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
5608 (the_low_target): Add comments.
5609
5610 2015-07-30 Yao Qi <yao.qi@linaro.org>
5611
5612 * linux-arm-low.c (arm_hwcap): Remove it.
5613 (arm_read_description): New local variable arm_hwcap. Don't
5614 set arm_hwcap to zero.
5615
5616 2015-07-30 Yao Qi <yao.qi@linaro.org>
5617
5618 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
5619 Use regcache->tdesc instead.
5620 (arm_store_wmmxregset): Likewise.
5621 (arm_fill_vfpregset): Likewise.
5622 (arm_store_vfpregset): Likewise.
5623
5624 2015-07-30 Yao Qi <yao.qi@linaro.org>
5625
5626 * linux-arm-low.c: Include arch/arm.h.
5627 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
5628 (arm_store_gregset): Likewise.
5629
5630 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
5631
5632 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
5633 ptrace's 4th parameter.
5634
5635 2015-07-27 Yao Qi <yao.qi@linaro.org>
5636
5637 * configure.srv (case aarch64*-*-linux*): Don't set
5638 srv_linux_usrregs.
5639
5640 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
5641
5642 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
5643 sys/ptrace.h.
5644 * linux-arm-low.c: Likewise.
5645 * linux-cris-low.c: Likewise.
5646 * linux-crisv32-low.c: Likewise.
5647 * linux-low.c: Likewise.
5648 * linux-m68k-low.c: Likewise.
5649 * linux-mips-low.c: Likewise.
5650 * linux-nios2-low.c: Likewise.
5651 * linux-s390-low.c: Likewise.
5652 * linux-sparc-low.c: Likewise.
5653 * linux-tic6x-low.c: Likewise.
5654 * linux-tile-low.c: Likewise.
5655 * linux-x86-low.c: Likewise.
5656
5657 2015-07-24 Pedro Alves <palves@redhat.com>
5658
5659 * config.in: Regenerate.
5660 * configure: Regenerate.
5661
5662 2015-07-24 Pedro Alves <palves@redhat.com>
5663
5664 * acinclude.m4: Include ../ptrace.m4.
5665 * configure.ac: Call GDB_AC_PTRACE.
5666 * config.in, configure: Regenerate.
5667
5668 2015-07-24 Yao Qi <yao.qi@linaro.org>
5669
5670 * linux-low.c (linux_create_inferior): Remove setting to
5671 proc->priv->new_inferior.
5672 (linux_attach): Likewise.
5673 (linux_low_filter_event): Likewise.
5674 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
5675
5676 2015-07-24 Yao Qi <yao.qi@linaro.org>
5677
5678 * linux-low.c (linux_arch_setup): New function.
5679 (linux_low_filter_event): If proc->tdesc is NULL and
5680 proc->attached is true, call the_low_target.arch_setup.
5681 Otherwise, keep status pending, and return.
5682 (linux_resume_one_lwp_throw): Don't call get_pc if
5683 thread->while_stepping isn't NULL. Don't call
5684 get_thread_regcache if proc->tdesc is NULL.
5685 (need_step_over_p): Return 0 if proc->tdesc is NULL.
5686 (linux_target_ops): Install arch_setup.
5687 * server.c (start_inferior): Call the_target->arch_setup.
5688 * target.h (struct target_ops) <arch_setup>: New field.
5689 (target_arch_setup): New marco.
5690 * lynx-low.c (lynx_target_ops): Update.
5691 * nto-low.c (nto_target_ops): Update.
5692 * spu-low.c (spu_target_ops): Update.
5693 * win32-low.c (win32_target_ops): Update.
5694
5695 2015-07-24 Yao Qi <yao.qi@linaro.org>
5696
5697 * linux-low.c (linux_add_process): Don't set
5698 proc->priv->new_inferior.
5699 (linux_create_inferior): Set proc->priv->new_inferior to 1.
5700 (linux_attach): Likewise.
5701
5702 2015-07-24 Yao Qi <yao.qi@linaro.org>
5703
5704 * server.c (start_inferior): Code refactor.
5705
5706 2015-07-24 Yao Qi <yao.qi@linaro.org>
5707
5708 * server.c (process_serial_event): Set general_thread.
5709
5710 2015-07-21 Yao Qi <yao.qi@linaro.org>
5711
5712 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
5713 aarch64_linux_get_debug_reg_capacity.
5714
5715 2015-07-17 Yao Qi <yao.qi@linaro.org>
5716
5717 * Makefile.in (aarch64-linux-hw-point.o): New rule.
5718 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
5719 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
5720 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
5721 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
5722 (AARCH64_HWP_ALIGNMENT): Likewise.
5723 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
5724 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
5725 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
5726 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
5727 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
5728 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
5729 (struct aarch64_debug_reg_state): Likewise.
5730 (struct arch_lwp_info): Likewise.
5731 (aarch64_align_watchpoint): Likewise.
5732 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
5733 (aarch64_watchpoint_length): Likewise.
5734 (aarch64_point_encode_ctrl_reg): Likewise
5735 (aarch64_point_is_aligned): Likewise.
5736 (aarch64_align_watchpoint): Likewise.
5737 (aarch64_linux_set_debug_regs):
5738 (aarch64_dr_state_insert_one_point): Likewise.
5739 (aarch64_dr_state_remove_one_point): Likewise.
5740 (aarch64_handle_breakpoint): Likewise.
5741 (aarch64_handle_aligned_watchpoint): Likewise.
5742 (aarch64_handle_unaligned_watchpoint): Likewise.
5743 (aarch64_handle_watchpoint): Likewise.
5744
5745 2015-07-17 Yao Qi <yao.qi@linaro.org>
5746
5747 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
5748 and don't aarch64_get_debug_reg_state. All callers update.
5749 (aarch64_handle_aligned_watchpoint): Likewise.
5750 (aarch64_handle_unaligned_watchpoint): Likewise.
5751 (aarch64_handle_watchpoint): Likewise.
5752 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
5753 (aarch64_remove_point): Likewise.
5754
5755 2015-07-17 Yao Qi <yao.qi@linaro.org>
5756
5757 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
5758 debug_printf.
5759 (aarch64_handle_unaligned_watchpoint): Likewise.
5760
5761 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5762
5763 Revert the previous 3 commits:
5764 Move gdb_regex* to common/
5765 Move linux_find_memory_regions_full & co.
5766 gdbserver build-id attribute generator
5767
5768 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5769 Jan Kratochvil <jan.kratochvil@redhat.com>
5770
5771 gdbserver build-id attribute generator.
5772 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
5773 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
5774 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
5775 (find_phdr): New.
5776 (get_dynamic): Use find_pdhr to traverse program headers.
5777 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
5778 (compare_mapping_entry_range, struct find_memory_region_callback_data)
5779 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
5780 (get_hex_build_id): New.
5781 (linux_qxfer_libraries_svr4): Add optional build-id attribute
5782 to reply XML document.
5783
5784 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5785 Jan Kratochvil <jan.kratochvil@redhat.com>
5786
5787 * target.c: Include target/target-utils.h and fcntl.h.
5788 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
5789 (target_fileio_read_stralloc): New functions.
5790
5791 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5792
5793 * Makefile.in (OBS): Add gdb_regex.o.
5794 (gdb_regex.o): New.
5795 * config.in: Rebuilt.
5796 * configure: Rebuilt.
5797
5798 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5799 Jan Kratochvil <jan.kratochvil@redhat.com>
5800
5801 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
5802 * Makefile.in (OBS): Add target-utils.o.
5803 (linux-maps.o, target-utils.o): New.
5804 * configure.srv (srv_linux_obj): Add linux-maps.o.
5805
5806 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
5807
5808 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
5809 function, return 1.
5810 (the_low_target): Install it.
5811
5812 2015-07-14 Pedro Alves <palves@redhat.com>
5813
5814 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
5815 Instead, ignore ECHILD, and throw an error for other errnos.
5816
5817 2015-07-10 Pedro Alves <palves@redhat.com>
5818
5819 * event-loop.c (struct callback_event) <data>: Change type to
5820 gdb_client_data instance instead of gdb_client_data pointer.
5821 (append_callback_event): Adjust.
5822
5823 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
5824
5825 * linux-aarch64-low.c: Add comments for each linux_target_ops
5826 method. Remove comments already covered in target_ops and
5827 linux_target_ops definitions.
5828 (the_low_target): Add comments for each unimplemented method.
5829
5830 2015-07-09 Yao Qi <yao.qi@linaro.org>
5831
5832 * linux-aarch64-low.c (aarch64_regmap): Remove.
5833 (aarch64_usrregs_info): Remove.
5834 (regs_info): Set field usrregs to NULL.
5835
5836 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
5837
5838 * linux-low.c: Include "rsp-low.h"
5839 (linux_low_encode_pt_config, linux_low_encode_raw): New.
5840 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
5841 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
5842 (handle_btrace_enable_pt): New.
5843 (handle_btrace_general_set): Support "pt".
5844 (handle_btrace_conf_general_set): Support "pt:size".
5845
5846 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5847
5848 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
5849 Z_PACKET_SW_BP.
5850
5851 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5852
5853 * linux-aarch64-low.c: Remove comment about endianness.
5854 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
5855 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
5856 memcmp.
5857
5858 2015-06-24 Gary Benson <gbenson@redhat.com>
5859
5860 * linux-i386-ipa.c (stdint.h): Do not include.
5861 * lynx-i386-low.c (stdint.h): Likewise.
5862 * lynx-ppc-low.c (stdint.h): Likewise.
5863 * mem-break.c (stdint.h): Likewise.
5864 * thread-db.c (stdint.h): Likewise.
5865 * tracepoint.c (stdint.h): Likewise.
5866 * win32-low.c (stdint.h): Likewise.
5867
5868 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
5869
5870 * server.c (write_qxfer_response): Update call to
5871 remote_escape_output.
5872
5873 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
5874 Jan Kratochvil <jan.kratochvil@redhat.com>
5875
5876 Merge multiple hex conversions.
5877 * gdbreplay.c (tohex): Rename to 'fromhex'.
5878 (logchar): Use fromhex.
5879
5880 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
5881
5882 * server.c (handle_qxfer_libraries): Set `version' attribute for
5883 <library-list>.
5884
5885 2015-06-10 Gary Benson <gbenson@redhat.com>
5886
5887 * target.h (struct target_ops) <multifs_open>: New field.
5888 <multifs_unlink>: Likewise.
5889 <multifs_readlink>: Likewise.
5890 * linux-low.c (nat/linux-namespaces.h): New include.
5891 (linux_target_ops): Initialize the_target->multifs_open,
5892 the_target->multifs_unlink and the_target->multifs_readlink.
5893 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
5894 * hostio.c (hostio_fs_pid): New static variable.
5895 (hostio_handle_new_gdb_connection): New function.
5896 (handle_setfs): Likewise.
5897 (handle_open): Use the_target->multifs_open as appropriate.
5898 (handle_unlink): Use the_target->multifs_unlink as appropriate.
5899 (handle_readlink): Use the_target->multifs_readlink as
5900 appropriate.
5901 (handle_vFile): Handle vFile:setfs packets.
5902 * server.c (handle_query): Call hostio_handle_new_gdb_connection
5903 after target_handle_new_gdb_connection.
5904
5905 2015-06-10 Gary Benson <gbenson@redhat.com>
5906
5907 * configure.ac (AC_CHECK_FUNCS): Add setns.
5908 * config.in: Regenerate.
5909 * configure: Likewise.
5910 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
5911 (linux-namespaces.o): New rule.
5912 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
5913
5914 2015-06-09 Gary Benson <gbenson@redhat.com>
5915
5916 * hostio.c (handle_open): Process mode argument with
5917 fileio_to_host_mode.
5918
5919 2015-06-01 Yao Qi <yao.qi@linaro.org>
5920
5921 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
5922 * linux-x86-low.c: Likewise.
5923
5924 2015-05-28 Don Breazeal <donb@codesourcery.com>
5925
5926 * linux-low.c (handle_extended_wait): Initialize
5927 thread_info.last_resume_kind for new fork children.
5928
5929 2015-05-15 Pedro Alves <palves@redhat.com>
5930
5931 * target.h (target_handle_new_gdb_connection): Rewrite using if
5932 wrapped in do/while.
5933
5934 2015-05-14 Joel Brobecker <brobecker@adacore.com>
5935
5936 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
5937 * configure, config.in: Regenerate.
5938 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
5939 Declare typedef.
5940
5941 2015-05-12 Don Breazeal <donb@codesourcery.com>
5942
5943 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
5944 PTRACE_EVENT_VFORK_DONE.
5945 (linux_low_ptrace_options, extended_event_reported): Add vfork
5946 events.
5947 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
5948 and "vforkdone" for RSP 'T' Stop Reply Packet.
5949 * server.h (report_vfork_events): Declare
5950 global variable.
5951
5952 2015-05-12 Don Breazeal <donb@codesourcery.com>
5953
5954 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
5955 (the_low_target) <new_fork>: Initialize new member.
5956 * linux-arm-low.c (arm_new_fork): New function.
5957 (the_low_target) <new_fork>: Initialize new member.
5958 * linux-low.c (handle_extended_wait): Call new target function
5959 new_fork.
5960 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
5961 * linux-mips-low.c (mips_add_watchpoint): New function
5962 extracted from mips_insert_point.
5963 (the_low_target) <new_fork>: Initialize new member.
5964 (mips_linux_new_fork): New function.
5965 (mips_insert_point): Call mips_add_watchpoint.
5966 * linux-x86-low.c (x86_linux_new_fork): New function.
5967 (the_low_target) <new_fork>: Initialize new member.
5968
5969 2015-05-12 Don Breazeal <donb@codesourcery.com>
5970
5971 * linux-low.c (handle_extended_wait): Implement return value,
5972 rename argument 'event_child' to 'event_lwp', handle
5973 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
5974 (linux_low_ptrace_options): New function.
5975 (linux_low_filter_event): Call linux_low_ptrace_options,
5976 use different argument fo linux_enable_event_reporting,
5977 use return value from handle_extended_wait.
5978 (extended_event_reported): New function.
5979 (linux_wait_1): Call extended_event_reported and set
5980 status to report fork events.
5981 (linux_write_memory): Add pid to debug message.
5982 (reset_lwp_ptrace_options_callback): New function.
5983 (linux_handle_new_gdb_connection): New function.
5984 (linux_target_ops): Initialize new structure member.
5985 * linux-low.h (struct lwp_info) <waitstatus>: New member.
5986 * lynx-low.c: Initialize new structure member.
5987 * remote-utils.c (prepare_resume_reply): Implement stop reason
5988 "fork" for "T" stop message.
5989 * server.c (handle_query): Call handle_new_gdb_connection.
5990 * server.h (report_fork_events): Declare global flag.
5991 * target.h (struct target_ops) <handle_new_gdb_connection>:
5992 New member.
5993 (target_handle_new_gdb_connection): New macro.
5994 * win32-low.c: Initialize new structure member.
5995
5996 2015-05-12 Don Breazeal <donb@codesourcery.com>
5997
5998 * mem-break.c (APPEND_TO_LIST): Define macro.
5999 (clone_agent_expr): New function.
6000 (clone_one_breakpoint): New function.
6001 (clone_all_breakpoints): New function.
6002 * mem-break.h: Declare new functions.
6003
6004 2015-05-12 Don Breazeal <donb@codesourcery.com>
6005
6006 * linux-low.c (linux_supports_fork_events): New function.
6007 (linux_supports_vfork_events): New function.
6008 (linux_target_ops): Initialize new structure members.
6009 (initialize_low): Call linux_check_ptrace_features.
6010 * lynx-low.c (lynx_target_ops): Initialize new structure
6011 members.
6012 * server.c (report_fork_events, report_vfork_events):
6013 New global flags.
6014 (handle_query): Add new features to qSupported packet and
6015 response.
6016 (captured_main): Initialize new global variables.
6017 * target.h (struct target_ops) <supports_fork_events>:
6018 New member.
6019 <supports_vfork_events>: New member.
6020 (target_supports_fork_events): New macro.
6021 (target_supports_vfork_events): New macro.
6022 * win32-low.c (win32_target_ops): Initialize new structure
6023 members.
6024
6025 2015-05-12 Gary Benson <gbenson@redhat.com>
6026
6027 * server.c (handle_qxfer_exec_file): Use current process
6028 if annex is empty.
6029
6030 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6031
6032 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6033 Remove HAVE_PTRACE_GETREGS conditionals.
6034 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6035 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6036
6037 2015-05-08 Yao Qi <yao.qi@linaro.org>
6038
6039 * linux-low.c (linux_supports_conditional_breakpoints): New
6040 function.
6041 (linux_target_ops): Install new target method.
6042 * lynx-low.c (lynx_target_ops): Install NULL hook for
6043 supports_conditional_breakpoints.
6044 * nto-low.c (nto_target_ops): Likewise.
6045 * spu-low.c (spu_target_ops): Likewise.
6046 * win32-low.c (win32_target_ops): Likewise.
6047 * server.c (handle_query): Check
6048 target_supports_conditional_breakpoints.
6049 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6050 New field.
6051 (target_supports_conditional_breakpoints): New macro.
6052
6053 2015-05-06 Pedro Alves <palves@redhat.com>
6054
6055 PR server/18081
6056 * server.c (start_inferior): If the process exits, mourn it.
6057
6058 2015-04-21 Gary Benson <gbenson@redhat.com>
6059
6060 * hostio.c (fileio_open_flags_to_host): Factored out to
6061 fileio_to_host_openflags in common/fileio.c. Single use
6062 updated.
6063
6064 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6065
6066 * linux-xtensa-low.c (xtensa_fill_gregset)
6067 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6068 XCHAL_HAVE_LOOP.
6069
6070 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6071
6072 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6073 (regs_info): Replace usrregs pointer with NULL.
6074
6075 2015-04-17 Gary Benson <gbenson@redhat.com>
6076
6077 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6078 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6079 * server.c (handle_qxfer_exec_file): New function.
6080 (qxfer_packets): Add exec-file entry.
6081 (handle_query): Report qXfer:exec-file:read as supported packet.
6082
6083 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6084
6085 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6086
6087 2015-04-09 Gary Benson <gbenson@redhat.com>
6088
6089 * hostio-errno.c (errno_to_fileio_error): Remove function.
6090 Update caller to use remote_fileio_to_fio_error.
6091
6092 2015-04-09 Yao Qi <yao.qi@linaro.org>
6093
6094 * linux-low.c (linux_insert_point): Call
6095 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6096 (linux_remove_point): Call remove_memory_breakpoint if type is
6097 raw_bkpt_type_sw.
6098 * linux-x86-low.c (x86_insert_point): Don't call
6099 insert_memory_breakpoint.
6100 (x86_remove_point): Don't call remove_memory_breakpoint.
6101
6102 2015-04-01 Pedro Alves <palves@redhat.com>
6103 Cleber Rosa <crosa@redhat.com>
6104
6105 * server.c (gdbserver_usage): Reorganize and extend the usage
6106 message.
6107
6108 2015-03-24 Pedro Alves <palves@redhat.com>
6109
6110 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6111 output. Also dump TRAP_TRACE.
6112 (linux_low_filter_event): In debug output, distinguish a
6113 resume_stop SIGSTOP from a delayed SIGSTOP.
6114
6115 2015-03-24 Gary Benson <gbenson@redhat.com>
6116
6117 * linux-x86-low.c (x86_linux_new_thread): Moved to
6118 nat/x86-linux.c.
6119 (x86_linux_prepare_to_resume): Likewise.
6120
6121 2015-03-24 Gary Benson <gbenson@redhat.com>
6122
6123 * Makefile.in (x86-linux-dregs.o): New rule.
6124 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6125 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6126 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6127 (x86_linux_dr_get): Likewise.
6128 (x86_linux_dr_set): Likewise.
6129 (update_debug_registers_callback): Likewise.
6130 (x86_linux_dr_set_addr): Likewise.
6131 (x86_linux_dr_get_addr): Likewise.
6132 (x86_linux_dr_set_control): Likewise.
6133 (x86_linux_dr_get_control): Likewise.
6134 (x86_linux_dr_get_status): Likewise.
6135 (x86_linux_update_debug_registers): Likewise.
6136
6137 2015-03-24 Gary Benson <gbenson@redhat.com>
6138
6139 * linux-x86-low.c (x86_linux_update_debug_registers):
6140 New function, factored out from...
6141 (x86_linux_prepare_to_resume): ...this.
6142
6143 2015-03-24 Gary Benson <gbenson@redhat.com>
6144
6145 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6146 (x86_linux_dr_set): Likewise.
6147 (update_debug_registers_callback): Likewise.
6148 (x86_linux_dr_set_addr): Likewise.
6149 (x86_linux_dr_get_addr): Likewise.
6150 (x86_linux_dr_set_control): Likewise.
6151 (x86_linux_dr_get_control): Likewise.
6152 (x86_linux_dr_get_status): Likewise.
6153 (x86_linux_prepare_to_resume): Likewise.
6154
6155 2015-03-24 Gary Benson <gbenson@redhat.com>
6156
6157 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6158 Use perror_with_name. Pass string through gettext.
6159 (x86_linux_dr_set): Likewise.
6160
6161 2015-03-24 Gary Benson <gbenson@redhat.com>
6162
6163 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6164 (x86_linux_dr_set_addr): ...this.
6165 (x86_dr_low_get_addr): Rename to...
6166 (x86_linux_dr_get_addr): ...this.
6167 (x86_dr_low_set_control): Rename to...
6168 (x86_linux_dr_set_control): ...this.
6169 (x86_dr_low_get_control): Rename to...
6170 (x86_linux_dr_get_control): ...this.
6171 (x86_dr_low_get_status): Rename to...
6172 (x86_linux_dr_get_status): ...this.
6173 (x86_dr_low): Update with new function names.
6174
6175 2015-03-24 Gary Benson <gbenson@redhat.com>
6176
6177 * Makefile.in (x86-linux.o): New rule.
6178 * configure.srv: Add x86-linux.o to relevant targets.
6179 * linux-low.c (lwp_set_arch_private_info): New function.
6180 (lwp_arch_private_info): Likewise.
6181 * linux-x86-low.c: Include nat/x86-linux.h.
6182 (arch_lwp_info): Removed structure.
6183 (update_debug_registers_callback):
6184 Use lwp_set_debug_registers_changed.
6185 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6186 and lwp_set_debug_registers_changed.
6187 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6188
6189 2015-03-24 Gary Benson <gbenson@redhat.com>
6190
6191 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6192 * linux-arm-low.c (arm_new_thread): Likewise.
6193 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6194 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6195 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6196 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6197
6198 2015-03-24 Gary Benson <gbenson@redhat.com>
6199
6200 * linux-low.c (ptid_of_lwp): New function.
6201 (lwp_is_stopped): Likewise.
6202 (lwp_stop_reason): Likewise.
6203 * linux-x86-low.c (update_debug_registers_callback):
6204 Use lwp_is_stopped.
6205 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6206 lwp_stop_reason.
6207
6208 2015-03-24 Gary Benson <gbenson@redhat.com>
6209
6210 * linux-low.h (linux_stop_lwp): Remove declaration.
6211
6212 2015-03-24 Gary Benson <gbenson@redhat.com>
6213
6214 * linux-low.h: Include nat/linux-nat.h.
6215 * linux-low.c (iterate_over_lwps_args): New structure.
6216 (iterate_over_lwps_filter): New function.
6217 (iterate_over_lwps): Likewise.
6218 * linux-x86-low.c (update_debug_registers_callback):
6219 Update signature to what iterate_over_lwps expects.
6220 Remove PID check that iterate_over_lwps now performs.
6221 (x86_dr_low_set_addr): Use iterate_over_lwps.
6222 (x86_dr_low_set_control): Likewise.
6223
6224 2015-03-24 Gary Benson <gbenson@redhat.com>
6225
6226 * linux-x86-low.c (x86_debug_reg_state): New function.
6227 (x86_linux_prepare_to_resume): Use the above.
6228
6229 2015-03-24 Gary Benson <gbenson@redhat.com>
6230
6231 * linux-low.c (current_lwp_ptid): New function.
6232 * linux-x86-low.c: Include nat/linux-nat.h.
6233 (x86_dr_low_get_addr): Use current_lwp_ptid.
6234 (x86_dr_low_get_control): Likewise.
6235 (x86_dr_low_get_status): Likewise.
6236
6237 2015-03-20 Pedro Alves <palves@redhat.com>
6238
6239 * tracepoint.c (cmd_qtstatus): Make "str" const.
6240
6241 2015-03-20 Pedro Alves <palves@redhat.com>
6242
6243 * server.c (handle_general_set): Make "req_str" const.
6244
6245 2015-03-19 Pedro Alves <palves@redhat.com>
6246
6247 * linux-low.c (linux_resume_one_lwp): Rename to ...
6248 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6249 instead call perror_with_name.
6250 (check_ptrace_stopped_lwp_gone): New function.
6251 (linux_resume_one_lwp): Reimplement as wrapper around
6252 linux_resume_one_lwp_throw that swallows errors if the LWP is
6253 gone.
6254
6255 2015-03-19 Pedro Alves <palves@redhat.com>
6256
6257 * linux-low.c (count_events_callback, select_event_lwp_callback):
6258 No longer check whether the thread has resume_stop as last resume
6259 kind.
6260
6261 2015-03-19 Pedro Alves <palves@redhat.com>
6262
6263 * linux-low.c (count_events_callback, select_event_lwp_callback):
6264 Use the lwp's status_pending_p field, not the thread's.
6265
6266 2015-03-19 Pedro Alves <palves@redhat.com>
6267
6268 * linux-low.c (select_event_lwp_callback): Update comments to
6269 no longer mention SIGTRAP.
6270
6271 2015-03-18 Gary Benson <gbenson@redhat.com>
6272
6273 * server.c (handle_query): Do not report vFile:fstat as supported.
6274
6275 2015-03-11 Gary Benson <gbenson@redhat.com>
6276
6277 * hostio.c (sys/types.h): New include.
6278 (sys/stat.h): Likewise.
6279 (common-remote-fileio.h): Likewise.
6280 (handle_fstat): New function.
6281 (handle_vFile): Handle vFile:fstat packets.
6282
6283 2015-03-11 Gary Benson <gbenson@redhat.com>
6284
6285 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6286 struct stat.st_blocks and struct stat.st_blksize.
6287 * configure: Regenerate.
6288 * config.in: Likewise.
6289 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6290 (OBS): Add common-remote-fileio.o.
6291 (common-remote-fileio.o): New rule.
6292
6293 2015-03-09 Pedro Alves <palves@redhat.com>
6294
6295 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6296 'struct sockaddr' pointer in 'accept' call.
6297
6298 2015-03-09 Pedro Alves <palves@redhat.com>
6299
6300 Revert:
6301 2015-03-07 Pedro Alves <palves@redhat.com>
6302 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6303 or <winsock2.h> here. Instead include "gdb_socket.h".
6304 (remote_open): Use union gdb_sockaddr_u.
6305 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6306 or <winsock2.h> here. Instead include "gdb_socket.h".
6307 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6308 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6309 or <sys/un.h>.
6310 (init_named_socket, gdb_agent_helper_thread): Use union
6311 gdb_sockaddr_u.
6312
6313 2015-03-07 Pedro Alves <palves@redhat.com>
6314
6315 * configure.ac (build_warnings): Move
6316 -Wdeclaration-after-statement to the C-specific set.
6317 * configure: Regenerate.
6318
6319 2015-03-07 Pedro Alves <palves@redhat.com>
6320
6321 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6322 or <winsock2.h> here. Instead include "gdb_socket.h".
6323 (remote_open): Use union gdb_sockaddr_u.
6324 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6325 or <winsock2.h> here. Instead include "gdb_socket.h".
6326 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6327 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6328 or <sys/un.h>.
6329 (init_named_socket, gdb_agent_helper_thread): Use union
6330 gdb_sockaddr_u.
6331
6332 2015-03-07 Pedro Alves <palves@redhat.com>
6333
6334 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6335 instead.
6336
6337 2015-03-06 Yao Qi <yao.qi@linaro.org>
6338
6339 * linux-aarch64-low.c (aarch64_insert_point): Use
6340 show_debug_regs as a boolean.
6341 (aarch64_remove_point): Likewise.
6342
6343 2015-03-05 Pedro Alves <palves@redhat.com>
6344
6345 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6346 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6347 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6348 * nto-low.c (nto_target_ops): Likewise.
6349 * spu-low.c (spu_target_ops): Likewise.
6350 * win32-low.c (win32_target_ops): Likewise.
6351
6352 2015-03-04 Pedro Alves <palves@redhat.com>
6353
6354 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6355 Decide whether a breakpoint triggered based on the SIGTRAP's
6356 siginfo.si_code.
6357 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6358 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6359 (linux_low_filter_event): Check for breakpoints before checking
6360 watchpoints.
6361 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6362 siginfo.si_code.
6363 (linux_stopped_by_sw_breakpoint)
6364 (linux_supports_stopped_by_sw_breakpoint)
6365 (linux_stopped_by_hw_breakpoint)
6366 (linux_supports_stopped_by_hw_breakpoint): New functions.
6367 (linux_target_ops): Install new target methods.
6368
6369 2015-03-04 Pedro Alves <palves@redhat.com>
6370
6371 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6372 * server.c (swbreak_feature, hwbreak_feature): New globals.
6373 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6374 (captured_main): Clear swbreak_feature and hwbreak_feature.
6375 * server.h (swbreak_feature, hwbreak_feature): Declare.
6376 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6377 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6378 supports_stopped_by_hw_breakpoint>: New fields.
6379 (target_supports_stopped_by_sw_breakpoint)
6380 (target_stopped_by_sw_breakpoint)
6381 (target_supports_stopped_by_hw_breakpoint)
6382 (target_stopped_by_hw_breakpoint): Declare.
6383
6384 2015-03-04 Pedro Alves <palves@redhat.com>
6385
6386 enum lwp_stop_reason -> enum target_stop_reason
6387 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6388 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6389 (linux_wait_1, stuck_in_jump_pad_callback)
6390 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6391 (linux_stopped_by_watchpoint):
6392 * linux-low.h (enum lwp_stop_reason): Delete.
6393 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6394 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6395
6396 2015-03-04 Yao Qi <yao.qi@linaro.org>
6397
6398 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6399
6400 2015-03-03 Gary Benson <gbenson@redhat.com>
6401
6402 * hostio.c (handle_vFile): Fix prefix lengths.
6403
6404 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6405
6406 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6407 ptr_bits.
6408
6409 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6410
6411 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6412 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6413 (clean): Add "rm -f" for above C files.
6414 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6415 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6416 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6417 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6418 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6419 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6420 (init_registers_s390x_vx_linux64)
6421 (init_registers_s390x_tevx_linux64)
6422 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6423 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6424 declarations.
6425 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6426 (s390_store_vxrs_high): New functions.
6427 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6428 NT_S390_VXRS_HIGH.
6429 (s390_arch_setup): Add logic for selecting one of the new target
6430 descriptions. Activate the new vector regsets if applicable.
6431 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6432 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6433 and init_registers_s390x_tevx_linux64.
6434
6435 2015-03-01 Pedro Alves <palves@redhat.com>
6436
6437 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6438 parameter.
6439
6440 2015-02-27 Pedro Alves <palves@redhat.com>
6441
6442 * linux-x86-low.c (u_debugreg_offset): New function.
6443 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6444
6445 2015-02-27 Pedro Alves <palves@redhat.com>
6446
6447 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6448 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6449 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6450 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6451 (ps_lsetfpregs, ps_getpid)
6452 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6453 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6454 (ps_lsetxregs, ps_plog): Declare.
6455
6456 2015-02-27 Pedro Alves <palves@redhat.com>
6457
6458 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6459 IP_AGENT_EXPORT_FUNC.
6460 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6461 IP_AGENT_EXPORT_FUNC.
6462 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6463 (IP_AGENT_EXPORT): Delete.
6464 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6465 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6466 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6467 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
6468 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
6469 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
6470 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
6471 (traceframe_read_count, traceframe_write_count)
6472 (traceframes_created, trace_state_variables, get_raw_reg)
6473 (get_trace_state_variable_value, set_trace_state_variable_value)
6474 (ust_loaded, helper_thread_id, cmd_buf): Use
6475 IPA_SYM_EXPORTED_NAME.
6476 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
6477 (tracepoints) Use IP_AGENT_EXPORT_VAR.
6478 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
6479 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6480 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
6481 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
6482 EXTERN_C_PUSH/EXTERN_C_POP.
6483 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
6484 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
6485 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6486 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
6487 (traceframe_write_count, traceframe_read_count)
6488 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
6489 (about_to_request_buffer_space, get_trace_state_variable_value)
6490 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
6491 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
6492 EXTERN_C_PUSH/EXTERN_C_POP.
6493 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
6494 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
6495 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
6496 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6497 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6498 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6499 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
6500 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
6501 Define.
6502 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
6503 (IP_AGENT_EXPORT_VAR_DECL): Define.
6504 (tracing): Declare.
6505 (gdb_agent_get_raw_reg): Declare.
6506
6507 2015-02-27 Tom Tromey <tromey@redhat.com>
6508 Pedro Alves <palves@redhat.com>
6509
6510 Rename symbols whose names are reserved C++ keywords throughout.
6511
6512 2015-02-27 Pedro Alves <palves@redhat.com>
6513
6514 * Makefile.in (COMPILER): New, get it from autoconf.
6515 (CXX): Get from autoconf instead.
6516 (COMPILE.pre): Use COMPILER.
6517 (CC-LD): Rename to ...
6518 (CC_LD): ... this. Use COMPILER.
6519 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
6520 (CXX_FOR_TARGET): Default to g++ instead of gcc.
6521 * acinclude.m4: Include build-with-cxx.m4.
6522 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
6523 Disable -Werror by default if building in C++ mode.
6524 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
6525 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
6526 the C++ compiler. Save/restore CXXFLAGS too.
6527 * configure: Regenerate.
6528
6529 2015-02-27 Pedro Alves <palves@redhat.com>
6530
6531 * acinclude.m4: Include libiberty.m4.
6532 * configure.ac: Call libiberty_INIT.
6533 * config.in, configure: Regenerate.
6534
6535 2015-02-26 Pedro Alves <palves@redhat.com>
6536
6537 * linux-low.c (linux_wait_1): When incrementing the PC past a
6538 program breakpoint always use the_low_target.breakpoint_len as
6539 increment, rather than the maximum between that and
6540 the_low_target.decr_pc_after_break.
6541
6542 2015-02-23 Pedro Alves <palves@redhat.com>
6543
6544 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
6545 thread was doing a step-over; always adjust the PC if
6546 we stepped over a permanent breakpoint.
6547 (linux_wait_1): If we stepped over breakpoint that was on top of a
6548 permanent breakpoint, manually advance the PC past it.
6549
6550 2015-02-23 Pedro Alves <palves@redhat.com>
6551
6552 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
6553 modes.
6554 (x86_fill_gregset, x86_store_gregset): Use it when handling
6555 $orig_eax.
6556
6557 2015-02-20 Pedro Alves <palves@redhat.com>
6558
6559 * thread-db.c: Include "nat/linux-procfs.h".
6560 (thread_db_init): Skip listing new threads if the kernel supports
6561 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
6562
6563 2015-02-20 Pedro Alves <palves@redhat.com>
6564
6565 * linux-low.c (status_pending_p_callback): Use ptid_match.
6566
6567 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
6568
6569 PR breakpoints/16812
6570 * linux-low.c (wstatus_maybe_breakpoint): Remove.
6571 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
6572 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
6573
6574 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
6575
6576 PR breakpoints/15956
6577 * tracepoint.c (cmd_qtinit): Add check for current_thread.
6578
6579 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6580
6581 * linux-low.c (linux_low_btrace_conf): Print size.
6582 * server.c (handle_btrace_conf_general_set): New.
6583 (hanle_general_set): Call handle_btrace_conf_general_set.
6584 (handle_query): Report Qbtrace-conf:bts:size as supported.
6585
6586 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6587
6588 * linux-low.c (linux_low_enable_btrace): Update parameters.
6589 (linux_low_btrace_conf): New.
6590 (linux_target_ops)<to_btrace_conf>: Initialize.
6591 * server.c (current_btrace_conf): New.
6592 (handle_btrace_enable): Rename to ...
6593 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
6594 to target_enable_btrace. Update comment. Update users.
6595 (handle_qxfer_btrace_conf): New.
6596 (qxfer_packets): Add btrace-conf entry.
6597 (handle_query): Report qXfer:btrace-conf:read as supported packet.
6598 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
6599 (target_ops)<read_btrace_conf>: New.
6600 (target_enable_btrace): Update parameters.
6601 (target_read_btrace_conf): New.
6602
6603 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6604
6605 * server.c (handle_btrace_general_set): Remove call to
6606 target_supports_btrace.
6607 (supported_btrace_packets): New.
6608 (handle_query): Call supported_btrace_packets.
6609 * target.h: include btrace-common.h.
6610 (btrace_target_info): Removed.
6611 (supports_btrace, target_supports_btrace): Update parameters.
6612
6613 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6614
6615 * Makefile.in (SFILES): Add common/btrace-common.c.
6616 (OBS): Add common/btrace-common.o.
6617 (btrace-common.o): Add build rules.
6618 * linux-low: Include btrace-common.h.
6619 (linux_low_read_btrace): Use struct btrace_data. Call
6620 btrace_data_init and btrace_data_fini.
6621
6622 2015-02-06 Pedro Alves <palves@redhat.com>
6623
6624 * thread-db.c (find_new_threads_callback): Add debug output.
6625
6626 2015-02-04 Pedro Alves <palves@redhat.com>
6627
6628 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
6629 (resume_stopped_resumed_lwps): New function.
6630 (linux_wait_for_event_filtered): Use it.
6631
6632 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6633
6634 * Makefile.in (SFILES): Add linux-personality.c.
6635 (linux-personality.o): New rule.
6636 * configure.srv (srv_linux_obj): Add linux-personality.o to the
6637 list of objects to be built.
6638 * linux-low.c: Include nat/linux-personality.h.
6639 (linux_create_inferior): Remove code to disable address space
6640 randomization (moved to ../nat/linux-personality.c). Create
6641 cleanup to disable address space randomization.
6642
6643 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6644
6645 * Makefile.in (posix-strerror.o): New rule.
6646 (mingw-strerror.o): Likewise.
6647 * configure: Regenerated.
6648 * configure.ac: Source file ../common/common.host. Initialize new
6649 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
6650
6651 2015-01-14 Yao Qi <yao@codesourcery.com>
6652
6653 * Makefile.in (SFILES): Add nat/ppc-linux.c.
6654 (ppc-linux.o): New rule.
6655 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
6656 * configure.ac: AC_CHECK_FUNCS(getauxval).
6657 * config.in: Re-generated.
6658 * configure: Re-generated.
6659 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
6660 ppc64_64bit_inferior_p
6661
6662 2015-01-14 Yao Qi <yao@codesourcery.com>
6663
6664 * linux-ppc-low.c: Include "nat/ppc-linux.h".
6665 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
6666 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
6667 (PT_ORIG_R3, PT_TRAP): Likewise.
6668 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
6669 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
6670 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
6671
6672 2015-01-10 Joel Brobecker <brobecker@adacore.com>
6673
6674 * i387-fp.c (i387_cache_to_xsave): In look over
6675 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
6676 zmmh_low_space field by use of zmmh_high_space.
6677
6678 2015-01-09 Pedro Alves <palves@redhat.com>
6679
6680 * linux-low.c (step_over_bkpt): Move higher up in the file.
6681 (handle_extended_wait): Don't store the stop_pc here.
6682 (get_stop_pc): Adjust comments and rename to ...
6683 (check_stopped_by_breakpoint): ... this. Record whether the LWP
6684 stopped for a software breakpoint or hardware breakpoint.
6685 (thread_still_has_status_pending_p): New function.
6686 (status_pending_p_callback): Use
6687 thread_still_has_status_pending_p. If the event is no longer
6688 interesting, resume the LWP.
6689 (handle_tracepoints): Add assert.
6690 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
6691 (wstatus_maybe_breakpoint): New function.
6692 (cancel_breakpoint): Delete function.
6693 (check_stopped_by_watchpoint): New function, factored out from
6694 linux_low_filter_event.
6695 (lp_status_maybe_breakpoint): Delete function.
6696 (linux_low_filter_event): Remove filter_ptid argument.
6697 Leave thread group exits pending here. Store the LWP's stop PC.
6698 Always leave events pending.
6699 (linux_wait_for_event_filtered): Pull all events out of the
6700 kernel, and leave them all pending.
6701 (count_events_callback, select_event_lwp_callback): Consider all
6702 events.
6703 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
6704 (select_event_lwp): Only give preference to the stepping LWP in
6705 all-stop mode. Adjust comments.
6706 (ignore_event): New function.
6707 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
6708 references to cancel_breakpoints. Adjust to renames. Also give
6709 equal priority to all LWPs that have had events in non-stop mode.
6710 If reporting a software breakpoint event, unadjust the LWP's PC.
6711 (linux_wait): If linux_wait_1 returned an ignored event, retry.
6712 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
6713 Adjust.
6714 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
6715 (resume_status_pending_p): Use thread_still_has_status_pending_p.
6716 (linux_stopped_by_watchpoint): Adjust.
6717 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
6718 * linux-low.h (enum lwp_stop_reason): New.
6719 (struct lwp_info) <stop_pc>: Adjust comment.
6720 <stopped_by_watchpoint>: Delete field.
6721 <stop_reason>: New field.
6722 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6723 * mem-break.c (software_breakpoint_inserted_here)
6724 (hardware_breakpoint_inserted_here): New function.
6725 * mem-break.h (software_breakpoint_inserted_here)
6726 (hardware_breakpoint_inserted_here): Declare.
6727 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
6728 (cancel_breakpoints): Delete.
6729 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
6730 (upload_fast_traceframes): Remove references to
6731 cancel_breakpoints.
6732
6733 2015-01-09 Pedro Alves <palves@redhat.com>
6734
6735 * thread-db.c (find_new_threads_callback): Ignore thread if the
6736 kernel thread ID is -1.
6737
6738 2015-01-09 Pedro Alves <palves@redhat.com>
6739
6740 * linux-low.c (linux_attach_fail_reason_string): Move to
6741 nat/linux-ptrace.c, and rename.
6742 (linux_attach_lwp): Update comment.
6743 (attach_proc_task_lwp_callback): New function.
6744 (linux_attach): Adjust to rename and use
6745 linux_proc_attach_tgid_threads.
6746 (linux_attach_fail_reason_string): Delete declaration.
6747
6748 2015-01-01 Joel Brobecker <brobecker@adacore.com>
6749
6750 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
6751 * server.c (gdbserver_version): Likewise.
6752
6753 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
6754
6755 * remote-utils.c: Include ctype.h.
6756 (input_interrupt): Explicitly handle the case when the char
6757 received is the NUL byte. Improve the printing of non-ASCII
6758 characters.
6759
6760 2014-12-16 Joel Brobecker <brobecker@adacore.com>
6761
6762 * linux-low.c (linux_low_filter_event): Update call to
6763 linux_enable_event_reporting following the addition of
6764 a new parameter to that function.
6765
6766 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
6767
6768 PR server/17457
6769 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
6770 (AARCH64_FPCR_REGNO): Likewise.
6771 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
6772 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
6773 (aarch64_store_fpregset): Likewise.
6774
6775 2014-12-15 Joel Brobecker <brobecker@adacore.com>
6776
6777 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
6778 Remove FIXME comment about assumption about N.
6779
6780 2014-12-13 Joel Brobecker <brobecker@adacore.com>
6781
6782 * configure.ac: If large-file support is disabled in GDBserver,
6783 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
6784 * configure: Regenerate.
6785
6786 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6787
6788 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
6789 warning upon ENODATA from ptrace.
6790 * linux-s390-low.c (s390_store_tdb): New.
6791 (s390_regsets): Add regset for NT_S390_TDB.
6792
6793 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6794
6795 * linux-low.c (regsets_store_inferior_registers): Skip regsets
6796 without a fill_function.
6797 * linux-s390-low.c (s390_fill_last_break): Remove.
6798 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
6799 (s390_arch_setup): Use regset's size instead of fill_function for
6800 loop end condition.
6801
6802 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6803
6804 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
6805 the regset's store function when ptrace returned an error.
6806 * regcache.c (get_thread_regcache): Invalidate register cache
6807 before fetching inferior's registers.
6808
6809 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6810
6811 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
6812 while-loop as for-loop.
6813 (regsets_store_inferior_registers): Likewise.
6814
6815 2014-11-28 Yao Qi <yao@codesourcery.com>
6816
6817 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
6818 * config.in, configure: Re-generate.
6819 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
6820 is defined.
6821
6822 2014-11-21 Yao Qi <yao@codesourcery.com>
6823
6824 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
6825 (AC_CHECK_HEADERS): Remove malloc.h.
6826 * configure: Re-generated.
6827 * config.in: Re-generated.
6828 * server.h: Don't include alloca.h and malloc.h.
6829 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
6830 Don't include malloc.h.
6831
6832 2014-11-17 Joel Brobecker <brobecker@adacore.com>
6833
6834 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
6835 corresponding ERRNO check in same block.
6836
6837 2014-11-12 Pedro Alves <palves@redhat.com>
6838
6839 * server.c (cont_thread): Update comment.
6840 (start_inferior, attach_inferior): No longer clear cont_thread.
6841 (handle_v_cont): No longer set cont_thread.
6842 (captured_main): Clear cont_thread each time a GDB connects.
6843
6844 2014-11-12 Pedro Alves <palves@redhat.com>
6845
6846 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
6847 thread, and don't resume all threads if the Hc thread has exited.
6848
6849 2014-11-12 Pedro Alves <palves@redhat.com>
6850
6851 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
6852 the process group instead of to a specific LWP.
6853
6854 2014-10-15 Pedro Alves <palves@redhat.com>
6855
6856 PR server/17487
6857 * win32-arm-low.c (arm_set_thread_context): Remove current_event
6858 parameter.
6859 (arm_set_thread_context): Delete.
6860 (the_low_target): Adjust.
6861 * win32-i386-low.c (debug_registers_changed)
6862 (debug_registers_used): Delete.
6863 (update_debug_registers_callback): New function.
6864 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
6865 needing to update their debug registers.
6866 (win32_get_current_dr): New function.
6867 (x86_dr_low_get_addr, x86_dr_low_get_control)
6868 (x86_dr_low_get_status): Fetch the debug register from the thread
6869 record's context.
6870 (i386_initial_stuff): Adjust.
6871 (i386_get_thread_context): Remove current_event parameter. Don't
6872 clear debug_registers_changed nor copy DR values to
6873 debug_reg_state.
6874 (i386_set_thread_context): Delete.
6875 (i386_prepare_to_resume): New function.
6876 (i386_thread_added): Mark the thread as needing to update irs
6877 debug registers.
6878 (the_low_target): Remove i386_set_thread_context and install
6879 i386_prepare_to_resume.
6880 * win32-low.c (win32_get_thread_context): Adjust.
6881 (win32_set_thread_context): Use SetThreadContext
6882 directly.
6883 (win32_prepare_to_resume): New function.
6884 (win32_require_context): New function, factored out from ...
6885 (thread_rec): ... this.
6886 (continue_one_thread): Call win32_prepare_to_resume on each thread
6887 we're about to continue.
6888 (win32_resume): Call win32_prepare_to_resume on the event thread.
6889 * win32-low.h (struct win32_thread_info)
6890 <debug_registers_changed>: New field.
6891 (struct win32_target_ops): Change prototype of set_thread_context,
6892 delete set_thread_context and add prepare_to_resume.
6893 (win32_require_context): New declaration.
6894
6895 2014-10-08 Gary Benson <gbenson@redhat.com>
6896
6897 * server.h: Do not include common-exceptions.h.
6898
6899 2014-10-08 Gary Benson <gbenson@redhat.com>
6900
6901 * server.h: Do not include cleanups.h.
6902
6903 2014-09-30 James Hogan <james.hogan@imgtec.com>
6904
6905 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
6906 mips64-dsp-linux.c.
6907
6908 2014-09-23 Yao Qi <yao@codesourcery.com>
6909
6910 * linux-low.c (lp_status_maybe_breakpoint): New function.
6911 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
6912 (count_events_callback): Likewise.
6913 (select_event_lwp_callback): Likewise.
6914 (cancel_breakpoints_callback): Likewise.
6915
6916 2014-09-19 Don Breazeal <donb@codesourcery.com>
6917
6918 * linux-low.c (handle_extended_wait): Call
6919 linux_ptrace_get_extended_event.
6920 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
6921 linux_is_extended_waitstatus.
6922
6923 2014-09-16 Joel Brobecker <brobecker@adacore.com>
6924
6925 * Makefile.in (CPPFLAGS): Define.
6926 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
6927 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
6928
6929 2014-09-16 Gary Benson <gbenson@redhat.com>
6930
6931 * inferiors.h (current_inferior): Renamed as...
6932 (current_thread): New variable. All uses updated.
6933 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
6934 (maybe_move_out_of_jump_pad): Likewise.
6935 (cancel_breakpoint): Likewise.
6936 (linux_low_filter_event): Likewise.
6937 (wait_for_sigstop): Likewise.
6938 (linux_resume_one_lwp): Likewise.
6939 (need_step_over_p): Likewise.
6940 (start_step_over): Likewise.
6941 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
6942 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
6943 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
6944 and save_inferior as saved_thread.
6945 * regcache.c (get_thread_regcache): Renamed saved_inferior as
6946 saved_thread.
6947 (regcache_invalidate_thread): Likewise.
6948 * remote-utils.c (prepare_resume_reply): Likewise.
6949 * thread-db.c (thread_db_get_tls_address): Likewise.
6950 (disable_thread_event_reporting): Likewise.
6951 (remove_thread_event_breakpoints): Likewise.
6952 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
6953 as saved_thread.
6954 * target.h (set_desired_inferior): Renamed as...
6955 (set_desired_thread): New declaration. All uses updated.
6956 * server.c (myresume): Updated comment to reference thread instead
6957 of inferior.
6958 (handle_serial_event): Likewise.
6959 (handle_target_event): Likewise.
6960
6961 2014-09-12 Tom Tromey <tromey@redhat.com>
6962 Gary Benson <gbenson@redhat.com>
6963
6964 * regcache.h: Include common-regcache.h.
6965 (regcache_read_pc): Don't declare.
6966 * regcache.c (get_thread_regcache_for_ptid): New function.
6967
6968 2014-09-11 Tom Tromey <tromey@redhat.com>
6969 Gary Benson <gbenson@redhat.com>
6970
6971 * symbol.c: New file.
6972 * Makefile.in (SFILES): Add symbol.c.
6973 (OBS): Add symbol.o.
6974
6975 2014-09-11 Gary Benson <gbenson@redhat.com>
6976
6977 * target.c (target_stop_ptid, target_continue_ptid): New
6978 functions.
6979
6980 2014-09-11 Tom Tromey <tromey@redhat.com>
6981 Gary Benson <gbenson@redhat.com>
6982
6983 * target.h: Include target/target.h.
6984 * target.c (target_read_memory, target_read_uint32)
6985 (target_write_memory): New functions.
6986
6987 2014-09-11 Gary Benson <gbenson@redhat.com>
6988
6989 * server.h (debug_hw_points): Don't declare.
6990 * server.c (debug_hw_points): Don't define. Replace all uses
6991 with show_debug_regs.
6992 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
6993 all uses with show_debug_regs.
6994
6995 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
6996
6997 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
6998 endianness into account.
6999 (ppc_supply_ptrace_register): Likewise.
7000
7001 2014-09-03 James Hogan <james.hogan@imgtec.com>
7002
7003 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7004 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7005
7006 2014-09-03 Gary Benson <gbenson@redhat.com>
7007
7008 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7009 ALL_DEBUG_ADDRESS_REGISTERS.
7010
7011 2014-09-02 Gary Benson <gbenson@redhat.com>
7012
7013 * i386-low.h: Renamed as...
7014 * x86-low.h: New file. All type, function and variable name
7015 prefixes changed from "i386_" to "x86_". All references updated.
7016 * i386-low.c: Renamed as...
7017 * x86-low.c: New file. All type, function and variable name
7018 prefixes changed from "i386_" to "x86_". All references updated.
7019
7020 2014-09-02 Gary Benson <gbenson@redhat.com>
7021
7022 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7023 (x86_linux_new_thread): Likewise.
7024
7025 2014-08-29 Gary Benson <gbenson@redhat.com>
7026
7027 * server.h (setjmp.h): Do not include.
7028 (toplevel): Do not declare.
7029 (common-exceptions.h): Include.
7030 (cleanups.h): Likewise.
7031 * server.c (toplevel): Do not define.
7032 (exit_code): New static global.
7033 (detach_or_kill_for_exit_cleanup): New function.
7034 (main): New function. Original main renamed to...
7035 (captured_main): New function.
7036 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7037
7038 2014-08-29 Gary Benson <gbenson@redhat.com>
7039
7040 * Makefile.in (SFILES): Add common/common-exceptions.c.
7041 (OBS): Add common-exceptions.o.
7042 (common-exceptions.o): New rule.
7043 * utils.c (prepare_to_throw_exception): New function.
7044
7045 2014-08-29 Gary Benson <gbenson@redhat.com>
7046
7047 * config.in: Regenerate.
7048 * configure: Likewise.
7049
7050 2014-08-29 Gary Benson <gbenson@redhat.com>
7051
7052 * Makefile.in (SFILES): Add common/cleanups.c.
7053 (OBS): cleanups.o.
7054 (cleanups.o): New rule.
7055
7056 2014-08-29 Gary Benson <gbenson@redhat.com>
7057
7058 * utils.c (internal_vwarning): New function.
7059
7060 2014-08-28 Gary Benson <gbenson@redhat.com>
7061
7062 * utils.h (fatal): Remove declaration.
7063 * utils.c (fatal): Remove function.
7064
7065 2014-08-28 Gary Benson <gbenson@redhat.com>
7066
7067 * tracepoint.c (gdb_agent_init): Replace fatal with
7068 perror_with_name.
7069 (initialize_tracepoint): Likewise.
7070
7071 2014-08-28 Gary Benson <gbenson@redhat.com>
7072
7073 * remote-utils.c (remote_prepare): Replace fatal with error.
7074
7075 2014-08-28 Gary Benson <gbenson@redhat.com>
7076
7077 * linux-low.c (linux_async): Replace fatal with warning.
7078 Tidy up and return.
7079 (linux_start_non_stop): Return -1 if linux_async failed.
7080
7081 2014-08-28 Gary Benson <gbenson@redhat.com>
7082
7083 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7084 gdb_assert.
7085 (i386_dr_low_get_addr): Remove vague comment.
7086 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7087 gdb_assert.
7088
7089 2014-08-28 Gary Benson <gbenson@redhat.com>
7090
7091 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7092 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7093 internal_error.
7094 (linux_resume_one_lwp): Likewise.
7095 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7096 gdb_assert.
7097 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7098 with internal_error.
7099 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7100 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7101 (find_register_by_name): Replace fatal with internal_error.
7102 (find_regno): Likewise.
7103 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7104 * thread-db.c (thread_db_create_event): Likewise.
7105 (thread_db_load_search): Likewise.
7106 (try_thread_db_load_1): Likewise.
7107 * tracepoint.c (get_jump_space_head): Replace fatal with
7108 internal_error.
7109 (claim_trampoline_space): Likewise.
7110 (have_fast_tracepoint_trampoline_buffer): Likewise.
7111 (cmd_qtstart): Likewise.
7112 (stop_tracing): Likewise.
7113 (fast_tracepoint_collecting): Likewise.
7114 (target_malloc): Likewise.
7115 (download_tracepoint): Likewise.
7116 (download_trace_state_variables): Replace check with gdb_assert.
7117 (upload_fast_traceframes): Replace fatal with internal_error.
7118
7119 2014-08-19 Tom Tromey <tromey@redhat.com>
7120 Gary Benson <gbenson@redhat.com>
7121
7122 * Makefile.in (SFILES): Add common/common-debug.c.
7123 (OBS): Add common-debug.o.
7124 (common-debug.o): New rule.
7125 * debug.h (debug_printf): Don't declare.
7126 * debug.c (debug_printf): Renamed and rewritten as...
7127 (debug_vprintf): New function.
7128
7129 2014-08-19 Gary Benson <gbenson@redhat.com>
7130
7131 * utils.h: Do not include print-utils.h.
7132
7133 2014-08-19 Tom Tromey <tromey@redhat.com>
7134 Gary Benson <gbenson@redhat.com>
7135
7136 * server.h: Add static assertion.
7137 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7138
7139 2014-08-19 Tom Tromey <tromey@redhat.com>
7140 Gary Benson <gbenson@redhat.com>
7141
7142 * Makefile.in (SFILES): Add common/errors.c.
7143 (OBS): Add errors.o.
7144 (IPA_OBS): Add errors-ipa.o.
7145 (errors.o): New rule.
7146 (errors-ipa.o): Likewise.
7147 * utils.h (perror_with_name, error, warning): Don't declare.
7148 * utils.c (warning): Renamed and rewritten as...
7149 (vwarning): New function.
7150 (error): Renamed and rewritten as...
7151 (verror): New function.
7152 (internal_error): Renamed and rewritten as...
7153 (internal_verror): New function.
7154
7155 2014-08-07 Gary Benson <gbenson@redhat.com>
7156
7157 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7158 * configure: Regenerate.
7159 * config.in: Likewise.
7160 * server.h: Do not include errno.h.
7161 * event-loop.c: Likewise.
7162 * hostio-errno.c: Likewise.
7163 * linux-low.c: Likewise.
7164 * remote-utils.c: Likewise.
7165 * spu-low.c: Likewise.
7166 * utils.c: Likewise.
7167 * gdbreplay.c: Unconditionally include errno.h.
7168
7169 2014-08-07 Gary Benson <gbenson@redhat.com>
7170
7171 * server.h: Do not include string.h.
7172 * event-loop.c: Likewise.
7173 * linux-low.c: Likewise.
7174 * regcache.c: Likewise.
7175 * remote-utils.c: Likewise.
7176 * spu-low.c: Likewise.
7177 * utils.c: Likewise.
7178
7179 2014-08-07 Gary Benson <gbenson@redhat.com>
7180
7181 * server.h: Do not include gdb_assert.h.
7182
7183 2014-08-07 Gary Benson <gbenson@redhat.com>
7184
7185 * server.h: Do not include common-utils.h.
7186
7187 2014-08-07 Gary Benson <gbenson@redhat.com>
7188
7189 * server.h: Do not include ptid.h.
7190 * notif.h: Likewise.
7191
7192 2014-08-07 Gary Benson <gbenson@redhat.com>
7193
7194 * server.h: Do not include gdb_locale.h.
7195
7196 2014-08-07 Gary Benson <gbenson@redhat.com>
7197
7198 * server.h: Do not include gdb/signals.h.
7199 * win32-low.c: Likewise.
7200
7201 2014-08-07 Gary Benson <gbenson@redhat.com>
7202
7203 * server.h: Do not include pathmax.h.
7204
7205 2014-08-07 Gary Benson <gbenson@redhat.com>
7206
7207 * server.h: Do not include libiberty.h.
7208 * linux-bfin-low.c: Likewise.
7209
7210 2014-08-07 Gary Benson <gbenson@redhat.com>
7211
7212 * server.h: Do not include ansidecl.h.
7213
7214 2014-08-07 Gary Benson <gbenson@redhat.com>
7215
7216 * linux-x86-low.c: Do not include stddef.h.
7217 * lynx-ppc-low.c: Likewise.
7218 * tracepoint.c: Likewise.
7219
7220 2014-08-07 Gary Benson <gbenson@redhat.com>
7221
7222 * server.h: Do not include stdarg.h.
7223 * nto-low.c: Likewise.
7224
7225 2014-08-07 Gary Benson <gbenson@redhat.com>
7226
7227 * server.h: Do not include stdlib.h.
7228 * inferiors.c: Likewise.
7229 * linux-low.c: Likewise.
7230 * regcache.c: Likewise.
7231 * spu-low.c: Likewise.
7232 * tracepoint.c: Likewise.
7233 * utils.c: Likewise.
7234
7235 2014-08-07 Gary Benson <gbenson@redhat.com>
7236
7237 * server.h: Do not include stdio.h.
7238 * linux-low.c: Likewise.
7239 * remote-utils.c: Likewise.
7240 * spu-low.c: Likewise.
7241 * utils.c: Likewise.
7242 * wincecompat.c: Likewise.
7243
7244 2014-08-06 Gary Benson <gbenson@redhat.com>
7245
7246 * regcache.c (init_register_cache): Move conditionals inside if.
7247
7248 2014-08-06 Gary Benson <gbenson@redhat.com>
7249
7250 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7251
7252 2014-07-31 Gary Benson <gbenson@redhat.com>
7253
7254 * ax.h: Do not include server.h.
7255 * gdbthread.h: Likewise.
7256 * lynx-low.h: Likewise.
7257 * notif.h: Likewise.
7258
7259 2014-07-30 Gary Benson <gbenson@redhat.com>
7260
7261 * server.h: Include common-defs.h.
7262 Do not include config.h or build-gnulib-gdbserver/config.h.
7263
7264 2014-07-30 Gary Benson <gbenson@redhat.com>
7265
7266 * hostio-errno.c: Move server.h to top of includes list.
7267 * inferiors.c: Likewise.
7268 * linux-x86-low.c: Likewise.
7269 * notif.c: Include server.h.
7270
7271 2014-07-24 Tom Tromey <tromey@redhat.com>
7272 Gary Benson <gbenson@redhat.com>
7273
7274 * server.h (CORE_ADDR): Now unsigned.
7275
7276 2014-07-16 Pedro Alves <palves@redhat.com>
7277
7278 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7279
7280 2014-07-15 Pedro Alves <palves@redhat.com>
7281
7282 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7283 copy.
7284
7285 2014-07-11 Pedro Alves <palves@redhat.com>
7286
7287 * linux-low.c (kill_wait_lwp): New function, based on
7288 kill_one_lwp_callback, but use my_waitpid directly.
7289 (kill_one_lwp_callback, linux_kill): Use it.
7290
7291 2014-06-23 Pedro Alves <palves@redhat.com>
7292
7293 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7294 before setting DR0..DR3.
7295
7296 2014-06-20 Gary Benson <gbenson@redhat.com>
7297
7298 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7299 * configure: Regenerated.
7300 * config.in: Likewise.
7301
7302 2014-06-20 Gary Benson <gbenson@redhat.com>
7303
7304 * Makefile.in (SFILES): Update locations for files moved
7305 from common to nat.
7306 (object file files): Reordered.
7307
7308 2014-06-20 Gary Benson <gbenson@redhat.com>
7309
7310 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7311 (i386_dr_low_set_addr): Likewise.
7312 (i386_dr_low_get_addr): Likewise.
7313 (i386_dr_low_can_set_control): Likewise.
7314 (i386_dr_low_set_control): Likewise.
7315 (i386_dr_low_get_control): Likewise.
7316 (i386_dr_low_get_status): Likewise.
7317 (i386_get_debug_register_length): Likewise.
7318 * linux-x86-low.c (i386_dr_low_set_addr):
7319 Changed signature. Made static.
7320 (i386_dr_low_get_addr): Likewise.
7321 (i386_dr_low_set_control): Likewise.
7322 (i386_dr_low_get_control): Likewise.
7323 (i386_dr_low_get_status): Likewise.
7324 (i386_dr_low): New global variable.
7325 * win32-i386-low.c (i386_dr_low_set_addr):
7326 Changed signature. Made static.
7327 (i386_dr_low_get_addr): Likewise.
7328 (i386_dr_low_set_control): Likewise.
7329 (i386_dr_low_get_control): Likewise.
7330 (i386_dr_low_get_status): Likewise.
7331 (i386_dr_low): New global variable.
7332
7333 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7334
7335 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7336 * Makefile.in (AR, AR_FLAGS): Define.
7337 * configure: Regenerate.
7338
7339 2014-06-19 Gary Benson <gbenson@redhat.com>
7340
7341 * Makefile.in (i386-dregs.o): New rule.
7342 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7343 * i386-low.c (target.h): Remove include.
7344 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7345 (DR_CONTROL_SHIFT): Likewise.
7346 (DR_CONTROL_SIZE): Likewise.
7347 (DR_RW_EXECUTE): Likewise.
7348 (DR_RW_WRITE): Likewise.
7349 (DR_RW_READ): Likewise.
7350 (DR_RW_IORW): Likewise.
7351 (DR_LEN_1): Likewise.
7352 (DR_LEN_2): Likewise.
7353 (DR_LEN_4): Likewise.
7354 (DR_LEN_8): Likewise.
7355 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7356 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7357 (DR_ENABLE_SIZE): Likewise.
7358 (DR_LOCAL_SLOWDOWN): Likewise.
7359 (DR_GLOBAL_SLOWDOWN): Likewise.
7360 (DR_CONTROL_RESERVED): Likewise.
7361 (I386_DR_CONTROL_MASK): Likewise.
7362 (I386_DR_VACANT): Likewise.
7363 (I386_DR_LOCAL_ENABLE): Likewise.
7364 (I386_DR_GLOBAL_ENABLE): Likewise.
7365 (I386_DR_DISABLE): Likewise.
7366 (I386_DR_SET_RW_LEN): Likewise.
7367 (I386_DR_GET_RW_LEN): Likewise.
7368 (I386_DR_WATCH_HIT): Likewise.
7369 (i386_wp_op_t): Likewise.
7370 (i386_show_dr): Likewise.
7371 (i386_length_and_rw_bits): Likewise.
7372 (i386_insert_aligned_watchpoint): Likewise.
7373 (i386_remove_aligned_watchpoint): Likewise.
7374 (i386_handle_nonaligned_watchpoint): Likewise.
7375 i386_update_inferior_debug_regs(): Likewise.
7376 (i386_dr_insert_watchpoint): Likewise.
7377 (i386_dr_remove_watchpoint): Likewise.
7378 (i386_dr_region_ok_for_watchpoint): Likewise.
7379 (i386_dr_stopped_data_address): Likewise.
7380 (i386_dr_stopped_by_watchpoint): Likewise.
7381
7382 2014-06-19 Gary Benson <gbenson@redhat.com>
7383
7384 * i386-low.c (i386_dr_show): Renamed to
7385 i386_show_dr and made static. All uses updated.
7386 (i386_dr_length_and_rw_bits): Renamed to
7387 i386_length_and_rw_bits and made static.
7388 All uses updated.
7389 (i386_dr_insert_aligned_watchpoint): Renamed to
7390 i386_insert_aligned_watchpoint and made static.
7391 All uses updated.
7392 (i386_dr_remove_aligned_watchpoint): Renamed to
7393 i386_remove_aligned_watchpoint and made static.
7394 All uses updated.
7395 (i386_dr_update_inferior_debug_regs): Renamed to
7396 i386_update_inferior_debug_regs and made static.
7397 All uses updated.
7398
7399 2014-06-18 Gary Benson <gbenson@redhat.com>
7400
7401 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7402 (i386_dr_low_can_set_control): Likewise.
7403 (i386_get_debug_register_length): Likewise.
7404 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7405 (i386_dr_low_can_set_control): Likewise.
7406 (i386_get_debug_register_length): Likewise.
7407
7408 2014-06-17 Gary Benson <gbenson@redhat.com>
7409
7410 * i386-low.h (i386-dregs.h): New include.
7411 (DR_FIRSTADDR): Now in i386-dregs.h.
7412 (DR_LASTADDR): Likewise.
7413 (DR_NADDR): Likewise.
7414 (DR_STATUS): Likewise.
7415 (DR_CONTROL): Likewise.
7416 (i386_debug_reg_state): Likewise.
7417 (i386_dr_insert_watchpoint): Likewise.
7418 (i386_dr_remove_watchpoint): Likewise.
7419 (i386_dr_region_ok_for_watchpoint): Likewise.
7420 (i386_dr_stopped_data_address): Likewise.
7421 (i386_dr_stopped_by_watchpoint): Likewise.
7422 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7423
7424 2014-06-18 Gary Benson <gbenson@redhat.com>
7425
7426 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7427 i386_dr_insert_watchpoint.
7428 (i386_low_remove_watchpoint): Renamed to
7429 i386_dr_remove_watchpoint.
7430 (i386_low_region_ok_for_watchpoint): Renamed to
7431 i386_dr_region_ok_for_watchpoint.
7432 (i386_low_stopped_data_address): Renamed to
7433 i386_dr_stopped_data_address.
7434 (i386_low_stopped_by_watchpoint): Renamed to
7435 i386_dr_stopped_by_watchpoint.
7436 * i386-low.c (i386_show_dr): Renamed to
7437 i386_dr_show and made nonstatic. All uses updated.
7438 (i386_length_and_rw_bits): Renamed to
7439 i386_dr_length_and_rw_bits and made nonstatic.
7440 All uses updated.
7441 (i386_insert_aligned_watchpoint): Renamed to
7442 i386_dr_insert_aligned_watchpoint and made nonstatic.
7443 All uses updated.
7444 (i386_remove_aligned_watchpoint): Renamed to
7445 i386_dr_remove_aligned_watchpoint and made nonstatic.
7446 All uses updated.
7447 (i386_update_inferior_debug_regs): Renamed to
7448 i386_dr_update_inferior_debug_regs and made nonstatic.
7449 All uses updated.
7450 (i386_low_insert_watchpoint): Renamed to
7451 i386_dr_insert_watchpoint. All uses updated.
7452 (i386_low_remove_watchpoint): Renamed to
7453 i386_dr_remove_watchpoint. All uses updated.
7454 (i386_low_region_ok_for_watchpoint): Renamed to
7455 i386_dr_region_ok_for_watchpoint. All uses updated.
7456 (i386_low_stopped_data_address): Renamed to
7457 i386_dr_stopped_data_address. All uses updated.
7458 (i386_low_stopped_by_watchpoint): Renamed to
7459 i386_dr_stopped_by_watchpoint. All uses updated.
7460
7461 2014-06-18 Gary Benson <gbenson@redhat.com>
7462
7463 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7464 (i386_dr_low_can_set_control): Likewise.
7465 (i386_insert_aligned_watchpoint): New check.
7466
7467 2014-06-18 Gary Benson <gbenson@redhat.com>
7468
7469 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
7470 Renamed to state.
7471
7472 2014-06-18 Gary Benson <gbenson@redhat.com>
7473
7474 * i386-low.c (i386_length_and_rw_bits): Use internal_error
7475 instead of fatal and error.
7476 (i386_handle_nonaligned_watchpoint): Likewise.
7477
7478 2014-06-18 Gary Benson <gbenson@redhat.com>
7479
7480 * i386-low.c (i386_get_debug_register_length): New macro.
7481 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
7482 (i386_show_dr): Use debug_printf instead of fprintf. Use
7483 phex to format values.
7484
7485 2014-06-18 Gary Benson <gbenson@redhat.com>
7486
7487 * i386-low.h: Comment changes.
7488 * i386-low.c: Likewise.
7489
7490 2014-06-18 Gary Benson <gbenson@redhat.com>
7491
7492 * i386-low.c: Whitespace changes.
7493
7494 2014-06-12 Tom Tromey <tromey@redhat.com>
7495
7496 * utils.c (freeargv): Remove.
7497
7498 2014-06-12 Tom Tromey <tromey@redhat.com>
7499
7500 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
7501 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
7502 (parse_debug_format_options): Likewise.
7503 (gdbserver_usage): Likewise.
7504 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
7505 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
7506 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
7507 against libiberty.
7508 ($(LIBGNU)): Depend on libiberty.
7509 (all-lib): Recurse into all subdirs.
7510 (install-only): Invoke "install" target in subdirs.
7511 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
7512 targets.
7513 * configure: Rebuild.
7514 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
7515 for vasprintf, vsnprintf, or gettimeofday.
7516 * configure.srv: Don't add safe-ctype.o or lbasename.o to
7517 srv_tgtobj.
7518
7519 2014-06-05 Joel Brobecker <brobecker@adacore.com>
7520
7521 * development.sh: Delete.
7522 * Makefile.in (config.status): Adjust dependency on development.sh.
7523 * configure.ac: Adjust development.sh source call.
7524 * configure: Regenerate.
7525
7526 2014-06-02 Pedro Alves <palves@redhat.com>
7527
7528 * ax.c (gdb_free_agent_expr): New function.
7529 * ax.h (gdb_free_agent_expr): New declaration.
7530 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
7531 list.
7532 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
7533 static.
7534 (clear_breakpoint_conditions_and_commands): New function.
7535 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
7536 (clear_breakpoint_conditions_and_commands): New declaration.
7537
7538 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
7539
7540 * linux-aarch64-low.c (asm/ptrace.h): Include.
7541
7542 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7543
7544 Fix TLS access for -static -pthread.
7545 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
7546 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
7547 (thread_db_load_search, try_thread_db_load_1): Initialize it.
7548
7549 2014-05-20 Pedro Alves <palves@redhat.com>
7550
7551 * linux-aarch64-low.c (aarch64_insert_point)
7552 (aarch64_remove_point): No longer check whether the type is
7553 supported here. Adjust to new interface.
7554 (the_low_target): Install aarch64_supports_z_point_type as
7555 supports_z_point_type method.
7556 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
7557 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
7558 instead of a Z packet char. Adjust.
7559 (arm_supports_z_point_type): New function.
7560 (arm_insert_point, arm_remove_point): Adjust to new interface.
7561 (the_low_target): Install arm_supports_z_point_type.
7562 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
7563 (cris_insert_point, cris_remove_point): Adjust to new interface.
7564 Don't check whether the type is supported here.
7565 (the_low_target): Install cris_supports_z_point_type.
7566 * linux-low.c (linux_supports_z_point_type): New function.
7567 (linux_insert_point, linux_remove_point): Adjust to new interface.
7568 * linux-low.h (struct linux_target_ops) <insert_point,
7569 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
7570 raw_breakpoint pointer parameter.
7571 <supports_z_point_type>: New method.
7572 * linux-mips-low.c (mips_supports_z_point_type): New function.
7573 (mips_insert_point, mips_remove_point): Adjust to new interface.
7574 Use mips_supports_z_point_type.
7575 (the_low_target): Install mips_supports_z_point_type.
7576 * linux-ppc-low.c (the_low_target): Install NULL as
7577 supports_z_point_type method.
7578 * linux-s390-low.c (the_low_target): Install NULL as
7579 supports_z_point_type method.
7580 * linux-sparc-low.c (the_low_target): Install NULL as
7581 supports_z_point_type method.
7582 * linux-x86-low.c (x86_supports_z_point_type): New function.
7583 (x86_insert_point): Adjust to new insert_point interface. Use
7584 insert_memory_breakpoint. Adjust to new
7585 i386_low_insert_watchpoint interface.
7586 (x86_remove_point): Adjust to remove_point interface. Use
7587 remove_memory_breakpoint. Adjust to new
7588 i386_low_remove_watchpoint interface.
7589 (the_low_target): Install x86_supports_z_point_type.
7590 * lynx-low.c (lynx_target_ops): Install NULL as
7591 supports_z_point_type callback.
7592 * nto-low.c (nto_supports_z_point_type): New.
7593 (nto_insert_point, nto_remove_point): Adjust to new interface.
7594 (nto_target_ops): Install nto_supports_z_point_type.
7595 * mem-break.c: Adjust intro comment.
7596 (struct raw_breakpoint) <raw_type, size>: New fields.
7597 <inserted>: Update comment.
7598 <shlib_disabled>: Delete field.
7599 (enum bkpt_type) <gdb_breakpoint>: Delete value.
7600 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
7601 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
7602 (raw_bkpt_type_to_target_hw_bp_type): New function.
7603 (find_enabled_raw_code_breakpoint_at): New function.
7604 (find_raw_breakpoint_at): New type and size parameters. Use them.
7605 (insert_memory_breakpoint): New function, based off
7606 set_raw_breakpoint_at.
7607 (remove_memory_breakpoint): New function.
7608 (set_raw_breakpoint_at): Reimplement.
7609 (set_breakpoint): New, based on set_breakpoint_at.
7610 (set_breakpoint_at): Reimplement.
7611 (delete_raw_breakpoint): Go through the_target->remove_point
7612 instead of assuming memory breakpoints.
7613 (find_gdb_breakpoint_at): Delete.
7614 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
7615 (find_gdb_breakpoint): New function.
7616 (set_gdb_breakpoint_at): Delete.
7617 (z_type_supported): New function.
7618 (set_gdb_breakpoint_1): New function, loosely based off
7619 set_gdb_breakpoint_at.
7620 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
7621 (delete_gdb_breakpoint_at): Delete.
7622 (delete_gdb_breakpoint_1): New function, loosely based off
7623 delete_gdb_breakpoint_at.
7624 (delete_gdb_breakpoint): New function.
7625 (clear_gdb_breakpoint_conditions): Rename to ...
7626 (clear_breakpoint_conditions): ... this. Don't handle a NULL
7627 breakpoint.
7628 (add_condition_to_breakpoint): Make static.
7629 (add_breakpoint_condition): Take a struct breakpoint pointer
7630 instead of an address. Adjust.
7631 (gdb_condition_true_at_breakpoint): Rename to ...
7632 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
7633 z_type parameter.
7634 (gdb_condition_true_at_breakpoint): Reimplement.
7635 (add_breakpoint_commands): Take a struct breakpoint pointer
7636 instead of an address. Adjust.
7637 (gdb_no_commands_at_breakpoint): Rename to ...
7638 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
7639 parameter. Return true if no breakpoint was found. Change debug
7640 output.
7641 (gdb_no_commands_at_breakpoint): Reimplement.
7642 (run_breakpoint_commands): Rename to ...
7643 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
7644 and change return type to boolean.
7645 (run_breakpoint_commands): New function.
7646 (gdb_breakpoint_here): Also check for Z1 breakpoints.
7647 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
7648 breakpoint. Go through the_target->remove_point instead of
7649 assuming memory breakpoint.
7650 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
7651 software and hardware breakpoints.
7652 (reinsert_raw_breakpoint): Go through the_target->insert_point
7653 instead of assuming memory breakpoint.
7654 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
7655 software and hardware breakpoints.
7656 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
7657 Check both software and hardware breakpoints.
7658 (validate_inserted_breakpoint): Assert the breakpoint is a
7659 software breakpoint. Set the inserted flag to -1 instead of
7660 setting shlib_disabled.
7661 (delete_disabled_breakpoints): Adjust.
7662 (validate_breakpoints): Only validate software breakpoints.
7663 Adjust to inserted flag change.
7664 (check_mem_read, check_mem_write): Skip breakpoint types other
7665 than software breakpoints. Adjust to inserted flag change.
7666 * mem-break.h (enum raw_bkpt_type): New enum.
7667 (raw_breakpoint, struct process_info): Forward declare.
7668 (Z_packet_to_target_hw_bp_type): Delete declaration.
7669 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
7670 (set_gdb_breakpoint, delete_gdb_breakpoint)
7671 (clear_breakpoint_conditions): New declarations.
7672 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
7673 (breakpoint_inserted_here): Update comment.
7674 (add_breakpoint_condition, add_breakpoint_commands): Replace
7675 address parameter with a breakpoint pointer parameter.
7676 (gdb_breakpoint_here): Update comment.
7677 (delete_gdb_breakpoint_at): Delete.
7678 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
7679 * server.c (process_point_options): Take a struct breakpoint
7680 pointer instead of an address. Adjust.
7681 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
7682 delete_gdb_breakpoint.
7683 * spu-low.c (spu_target_ops): Install NULL as
7684 supports_z_point_type method.
7685 * target.h: Include mem-break.h.
7686 (struct target_ops) <prepare_to_access_memory>: Update comment.
7687 <supports_z_point_type>: New field.
7688 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7689 instead of a char. Also take a raw breakpoint pointer.
7690 * win32-arm-low.c (the_low_target): Install NULL as
7691 supports_z_point_type.
7692 * win32-i386-low.c (i386_supports_z_point_type): New function.
7693 (i386_insert_point, i386_remove_point): Adjust to new interface.
7694 (the_low_target): Install i386_supports_z_point_type.
7695 * win32-low.c (win32_supports_z_point_type): New function.
7696 (win32_insert_point, win32_remove_point): Adjust to new interface.
7697 (win32_target_ops): Install win32_supports_z_point_type.
7698 * win32-low.h (struct win32_target_ops):
7699 <supports_z_point_type>: New method.
7700 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7701 instead of a char. Also take a raw breakpoint pointer.
7702
7703 2014-05-20 Pedro Alves <palves@redhat.com>
7704
7705 * mem-break.h: Include break-common.h.
7706 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7707 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
7708 (Z_packet_to_target_hw_bp_type): New declaration.
7709 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
7710 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
7711 (Z_PACKET_ACCESS_WP): Delete macros.
7712 (Z_packet_to_hw_type): Delete function.
7713 * i386-low.h: Don't include break-common.h here.
7714 (Z_packet_to_hw_type): Delete declaration.
7715 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
7716 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7717 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
7718 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7719 * linux-aarch64-low.c: Don't include break-common.h here.
7720 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7721 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
7722 (Z_packet_to_target_hw_bp_type): Delete function.
7723 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
7724 function.
7725 (mips_insert_point, mips_remove_point): Use
7726 Z_packet_to_target_hw_bp_type.
7727
7728 2014-05-20 Pedro Alves <palves@redhat.com>
7729
7730 * linux-aarch64-low.c: Include break-common.h.
7731 (enum target_point_type): Delete.
7732 (Z_packet_to_point_type): Rename to ...
7733 (Z_packet_to_target_hw_bp_type): ... this, and return a
7734 target_hw_bp_type instead.
7735 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
7736 instead of an enum target_point_type.
7737 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
7738 breakpoint type.
7739 (aarch64_dr_state_insert_one_point)
7740 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
7741 (aarch64_handle_aligned_watchpoint)
7742 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
7743 Take an enum target_hw_bp_type instead of an enum
7744 target_point_type.
7745 (aarch64_supports_z_point_type): New function.
7746 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
7747 use Z_packet_to_target_hw_bp_type.
7748
7749 2014-05-20 Joel Brobecker <brobecker@adacore.com>
7750
7751 * configure.ac: Only use -Werror by default when DEVELOPMENT
7752 is true.
7753 * configure: Regenerate.
7754
7755 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
7756
7757 Fix gdbserver qGetTLSAddr for x86_64 -m32.
7758 * linux-x86-low.c (X86_64_USER_REGS): New.
7759 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
7760
7761 2014-04-28 Yao Qi <yao@codesourcery.com>
7762
7763 * Makefile.in (i386-avx512.c): Fix the typo of generated file
7764 name.
7765
7766 2014-04-25 Pedro Alves <palves@redhat.com>
7767
7768 PR server/16255
7769 * linux-low.c (linux_attach_fail_reason_string): New function.
7770 (linux_attach_lwp): Delete.
7771 (linux_attach_lwp_1): Rename to ...
7772 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
7773 argument. Remove "initial" parameter. Return int instead of
7774 void. Don't error or warn here.
7775 (linux_attach): Adjust to call linux_attach_lwp. Call error on
7776 failure to attach to the tgid. Call warning when failing to
7777 attach to an lwp.
7778 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
7779 argument. Remove "initial" parameter. Return int instead of
7780 void. Don't error or warn here.
7781 (linux_attach_fail_reason_string): New declaration.
7782 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
7783 interface change. Use linux_attach_fail_reason_string.
7784
7785 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
7786 Walfred Tedeschi <walfred.tedeschi@intel.com>
7787
7788 * Makefile.in: Added rules to handle new files
7789 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
7790 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
7791 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
7792 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
7793 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
7794 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
7795 x32-avx512-linux.o.
7796 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
7797 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
7798 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
7799 i386/x32-avx512.xml.
7800 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
7801 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
7802 i386/x32-avx512-linux.xml.
7803 * i387-fp.c (num_avx512_k_registers): New constant for number
7804 of K registers.
7805 (num_avx512_zmmh_low_registers): New constant for number of
7806 lower ZMM registers (0-15).
7807 (num_avx512_zmmh_high_registers): New constant for number of
7808 higher ZMM registers (16-31).
7809 (num_avx512_ymmh_registers): New contant for number of higher
7810 YMM registers (ymm16-31 added by avx521 on x86_64).
7811 (num_avx512_xmm_registers): New constant for number of higher
7812 XMM registers (xmm16-31 added by AVX512 on x86_64).
7813 (struct i387_xsave): Add space for AVX512 registers.
7814 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
7815 Add code to handle AVX512 registers.
7816 (i387_xsave_to_cache): Add code to handle AVX512 registers.
7817 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
7818 prototypei from generated file.
7819 (tdesc_amd64_avx512_linux): Likewise.
7820 (init_registers_x32_avx512_linux): Likewise.
7821 (tdesc_x32_avx512_linux): Likewise.
7822 (init_registers_i386_avx512_linux): Likewise.
7823 (tdesc_i386_avx512_linux): Likewise.
7824 (x86_64_regmap): Add AVX512 registers.
7825 (x86_linux_read_description): Add code to handle AVX512 XSTATE
7826 mask.
7827 (initialize_low_arch): Add code to initialize AVX512 registers.
7828
7829 2014-04-23 Pedro Alves <palves@redhat.com>
7830
7831 * mem-break.c (find_gdb_breakpoint_at): Make static.
7832 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
7833
7834 2014-04-23 Pedro Alves <palves@redhat.com>
7835
7836 * i386-low.c: Don't include break-common.h here.
7837 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7838 prototype to take target_hw_bp_type as argument instead of a Z
7839 packet char.
7840 * i386-low.h: Include break-common.h here.
7841 (Z_packet_to_hw_type): Declare.
7842 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7843 prototypes.
7844 * linux-x86-low.c (x86_insert_point): Convert the packet number to
7845 a target_hw_bp_type before calling i386_low_insert_watchpoint.
7846 (x86_remove_point): Convert the packet number to a
7847 target_hw_bp_type before calling i386_low_remove_watchpoint.
7848 * win32-i386-low.c (i386_insert_point): Convert the packet number
7849 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
7850 (i386_remove_point): Convert the packet number to a
7851 target_hw_bp_type before calling i386_low_remove_watchpoint.
7852
7853 2014-04-23 Pedro Alves <palves@redhat.com>
7854
7855 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
7856
7857 2014-04-10 Pedro Alves <palves@redhat.com>
7858
7859 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7860 Check if the condition or command is NULL before checking if the
7861 breakpoint is known. On success, return true.
7862 * mem-break.h (add_breakpoint_condition): Document return.
7863 (add_breakpoint_commands): Add describing comment.
7864 * server.c (skip_to_semicolon): New function.
7865 (process_point_options): Use it.
7866
7867 2014-04-09 Pedro Alves <palves@redhat.com>
7868
7869 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
7870 to lwpid_of.
7871
7872 2014-02-27 Pedro Alves <palves@redhat.com>
7873
7874 PR 12702
7875 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
7876 macros.
7877 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
7878 output.
7879 (last_thread_of_process_p): Take a PID argument instead of a
7880 thread pointer.
7881 (linux_wait_for_lwp): Delete.
7882 (num_lwps, check_zombie_leaders, not_stopped_callback): New
7883 functions.
7884 (linux_low_filter_event): New function, party factored out from
7885 linux_wait_for_event.
7886 (linux_wait_for_event): Rename to ...
7887 (linux_wait_for_event_filtered): ... this. Add new filter ptid
7888 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
7889 sigsuspend. Check for zombie leaders.
7890 (linux_wait_for_event): Reimplement as wrapper around
7891 linux_wait_for_event_filtered.
7892 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
7893 a normal or signal exit is seen, it's the whole process exiting.
7894 (wait_for_sigstop): No longer a for_each_inferior callback.
7895 Rewrite on top of linux_wait_for_event_filtered.
7896 (stop_all_lwps): Call wait_for_sigstop directly.
7897 * server.c (resume, handle_target_event): Handle
7898 TARGET_WAITKIND_NO_RESUMED.
7899
7900 2014-02-26 Joel Brobecker <brobecker@adacore.com>
7901
7902 * win32-low.c (psapi_get_dll_name,
7903 * win32_CreateToolhelp32Snapshot): Delete.
7904 (win32_CreateToolhelp32Snapshot, win32_Module32First)
7905 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
7906 Delete.
7907 (handle_load_dll): Add function description.
7908 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
7909
7910 2014-02-26 Joel Brobecker <brobecker@adacore.com>
7911
7912 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
7913 Add comment.
7914 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
7915 base address when calling win32_add_one_solib.
7916 (handle_load_dll): Delete local variable load_addr.
7917 Remove 0x1000 offset applied to DLL base address when calling
7918 win32_add_one_solib.
7919 (handle_unload_dll): Add comment.
7920
7921 2014-02-26 Joel Brobecker <brobecker@adacore.com>
7922
7923 * win32-low.c (win32_add_all_dlls): Renames
7924 win32_ensure_ntdll_loaded. Rewrite function documentation.
7925 Adjust implementation to always load all DLLs.
7926 Add 0x1000 offset to DLL base address when calling
7927 win32_add_one_solib.
7928 (child_initialization_done): New static global.
7929 (do_initial_child_stuff): Set child_initialization_done to
7930 zero during child initialization, and 1 after. Replace call
7931 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
7932 Add comment.
7933 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
7934 (handle_unload_dll): Add function documentation.
7935 (get_child_debug_event): Ignore load and unload DLL events
7936 during child initialization.
7937
7938 2014-02-20 Doug Evans <dje@google.com>
7939
7940 Remove global all_lwps.
7941 * inferiors.h (ptid_of): Move here from linux-low.h.
7942 (pid_of, lwpid_of): Ditto.
7943 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
7944 parameter is a struct thread_info * now.
7945 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
7946 directly. Pass &all_threads to find_inferior instead of &all_lwps.
7947 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
7948 directly.
7949 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
7950 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
7951 * linux-arm-low.c (update_registers_callback): Update, "entry"
7952 parameter is a struct thread_info * now.
7953 Fetch lwpid from current_inferior directly.
7954 (arm_insert_point): Pass &all_threads to find_inferior instead of
7955 &all_lwps.
7956 (arm_remove_point): Ditto.
7957 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
7958 (arm_prepare_to_resume): Fetch pid from thread.
7959 (arm_read_description): Fetch lwpid from current_inferior directly.
7960 * linux-low.c (all_lwps): Delete.
7961 (delete_lwp): Delete call to remove_inferior.
7962 (handle_extended_wait): Fetch lwpid from thread.
7963 (add_lwp): Don't set lwp->entry.id. Remove call to
7964 add_inferior_to_list.
7965 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
7966 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
7967 (kill_one_lwp_callback): Ditto.
7968 (linux_kill): Don't dereference NULL pointer.
7969 Fetch ptid,lwpid from thread.
7970 (get_detach_signal): Fetch ptid from thread.
7971 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
7972 Simplify call to regcache_invalidate_thread.
7973 (delete_lwp_callback): Update, "entry" parameter is a
7974 struct thread_info * now. Fetch pid from thread.
7975 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
7976 (status_pending_p_callback): Update, "entry" parameter is a
7977 struct thread_info * now. Fetch ptid from thread.
7978 (find_lwp_pid): Update, "entry" parameter is a
7979 struct thread_info * now.
7980 (linux_wait_for_lwp): Fetch pid from thread.
7981 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
7982 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
7983 (enqueue_one_deferred_signal): Fetch lwpid from thread.
7984 (dequeue_one_deferred_signal): Ditto.
7985 (cancel_breakpoint): Fetch ptid from current_inferior.
7986 (linux_wait_for_event): Pass &all_threads to find_inferior,
7987 not &all_lwps. Fetch ptid, lwpid from thread.
7988 (count_events_callback): Update, "entry" parameter is a
7989 struct thread_info * now.
7990 (select_singlestep_lwp_callback): Ditto.
7991 (select_event_lwp_callback): Ditto.
7992 (cancel_breakpoints_callback): Ditto.
7993 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
7994 not &all_lwps.
7995 (select_event_lwp): Ditto. Fetch ptid from event_thread.
7996 (unsuspend_one_lwp): Update, "entry" parameter is a
7997 struct thread_info * now.
7998 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
7999 not &all_lwps.
8000 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8001 Fetch lwpid from thread, not lwp.
8002 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8003 Pass &all_threads to find_inferior, not &all_lwps.
8004 (send_sigstop): Fetch lwpid from thread, not lwp.
8005 (send_sigstop_callback): Update, "entry" parameter is a
8006 struct thread_info * now.
8007 (suspend_and_send_sigstop_callback): Ditto.
8008 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8009 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8010 struct thread_info * now.
8011 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8012 from thread, lwp.
8013 (lwp_running): Update, "entry" parameter is a
8014 struct thread_info * now.
8015 (stop_all_lwps): Fetch ptid from thread.
8016 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8017 (linux_resume_one_lwp): Fetch lwpid from thread.
8018 (linux_set_resume_request): Update, "entry" parameter is a
8019 struct thread_info * now. Fetch pid, lwpid from thread.
8020 (resume_status_pending_p): Update, "entry" parameter is a
8021 struct thread_info * now.
8022 (need_step_over_p): Ditto. Fetch lwpid from thread.
8023 (start_step_over): Fetch lwpid from thread.
8024 (linux_resume_one_thread): Update, "entry" parameter is a
8025 struct thread_info * now. Fetch lwpid from thread.
8026 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8027 (proceed_one_lwp): Update, "entry" parameter is a
8028 struct thread_info * now. Fetch lwpid from thread.
8029 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8030 struct thread_info * now.
8031 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8032 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8033 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8034 directly.
8035 (regsets_store_inferior_registers): Ditto.
8036 (fetch_register, store_register): Ditto.
8037 (linux_read_memory, linux_write_memory): Ditto.
8038 (linux_request_interrupt): Ditto.
8039 (linux_read_auxv): Ditto.
8040 (linux_xfer_siginfo): Ditto.
8041 (linux_qxfer_spu): Ditto.
8042 (linux_qxfer_libraries_svr4): Ditto.
8043 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8044 moved to inferiors.h.
8045 (get_lwp): Delete.
8046 (get_thread_lwp): Update.
8047 (struct lwp_info): Delete member "entry". Simplify comment for
8048 member "thread".
8049 (all_lwps): Delete.
8050 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8051 current_inferior directly.
8052 (update_watch_registers_callback): Update, "entry" parameter is a
8053 struct thread_info * now. Fetch pid from thread.
8054 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8055 (mips_insert_point): Fetch lwpid from current_inferior.
8056 Pass &all_threads to find_inferior, not &all_lwps.
8057 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8058 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8059 directly.
8060 (mips_stopped_data_address): Ditto.
8061 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8062 directly.
8063 * linux-tile-low.c (tile_arch_setup): Ditto.
8064 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8065 (update_debug_registers_callback): Update, "entry" parameter is a
8066 struct thread_info * now. Fetch pid from thread.
8067 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8068 Pass &all_threads to find_inferior, not &all_lwps.
8069 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8070 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8071 Pass &all_threads to find_inferior, not &all_lwps.
8072 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8073 (i386_dr_low_get_status): Ditto.
8074 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8075 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8076 (x86_linux_read_description): Ditto.
8077 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8078
8079 2014-02-20 Doug Evans <dje@google.com>
8080
8081 * inferiors.c (get_first_inferior): Fix buglet.
8082
8083 2014-02-19 Doug Evans <dje@google.com>
8084
8085 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8086 * inferiors.c (add_thread): Change result type to struct thread_info *.
8087 All callers updated.
8088 (add_lwp): Call add_thread here instead of in callers.
8089 All callers updated.
8090 * linux-low.h (get_lwp_thread): Rewrite.
8091 (struct lwp_info): New member "thread".
8092
8093 2014-02-19 Doug Evans <dje@google.com>
8094
8095 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8096 All callers updated.
8097
8098 2014-02-19 Doug Evans <dje@google.com>
8099
8100 * inferiors.c (add_thread): Fix whitespace.
8101
8102 2014-02-19 Doug Evans <dje@google.com>
8103
8104 * dll.c (clear_dlls): Replace accessing list implemention details
8105 with API function.
8106 * gdbthread.h (get_first_thread): Declare.
8107 * inferiors.c (for_each_inferior_with_data): New function.
8108 (get_first_thread): New function.
8109 (find_thread_ptid): Simplify.
8110 (get_first_inferior): New function.
8111 (clear_list): Delete.
8112 (one_inferior_p): New function.
8113 (clear_inferior_list): New function.
8114 (clear_inferiors): Update.
8115 * inferiors.h (for_each_inferior_with_data): Declare.
8116 (clear_inferior_list): Declare.
8117 (one_inferior_p): Declare.
8118 (get_first_inferior): Declare.
8119 * linux-low.c (linux_wait_for_event): Replace accessing list
8120 implemention details with API function.
8121 * server.c (target_running): Ditto.
8122 (accumulate_file_name_length): New function.
8123 (emit_dll_description): New function.
8124 (handle_qxfer_libraries): Replace accessing list implemention
8125 details with API function.
8126 (handle_qxfer_threads_worker): New function.
8127 (handle_qxfer_threads_proper): Replace accessing list implemention
8128 details with API function.
8129 (handle_query): Ditto.
8130 (visit_actioned_threads_callback_ftype): New typedef.
8131 (visit_actioned_threads_data): New struct.
8132 (visit_actioned_threads): Rewrite to be find_inferior callback.
8133 (resume): Call find_inferior.
8134 (handle_status): Replace accessing list implemention
8135 details with API function.
8136 (process_serial_event): Replace accessing list implemention details
8137 with API function.
8138 * target.c (set_desired_inferior): Replace accessing list implemention
8139 details with API function.
8140 * tracepoint.c (same_process_p): New function.
8141 (gdb_agent_about_to_close): Replace accessing list implemention
8142 details with API function.
8143 * win32-low.c (child_delete_thread): Replace accessing list
8144 implemention details with API function.
8145 (match_dll_by_basename): New function.
8146 (dll_is_loaded_by_basename): New function.
8147 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8148 details call to dll_is_loaded_by_basename.
8149
8150 2014-02-19 Doug Evans <dje@google.com>
8151
8152 * dll.h (struct dll_info): Add comment.
8153 * gdbthread.h (struct thread_info): Add comment.
8154 (current_ptid): Simplify.
8155 * inferiors.c (add_process): Update.
8156 (remove_process): Update.
8157 * inferiors.h (struct process_info): Rename member "head" to "entry".
8158 * linux-low.c (delete_lwp): Update.
8159 (add_lwp): Update.
8160 (last_thread_of_process_p): Update.
8161 (kill_one_lwp_callback, linux_kill): Update.
8162 (status_pending_p_callback): Update.
8163 (wait_for_sigstop): Update. Simplify read of ptid.
8164 (start_step_over): Update.
8165 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8166 (get_lwp_thread): Update.
8167 (struct lwp_info): Rename member "head" to "entry".
8168 * regcache.h (inferior_list_entry): Delete.
8169 * server.c (kill_inferior_callback): Update.
8170 (detach_or_kill_inferior_callback): Update.
8171 (print_started_pid): Update.
8172 (print_attached_pid): Update.
8173 (process_serial_event): Simplify read of ptid.
8174 * thread-db.c (thread_db_create_event): Update.
8175 (thread_db_get_tls_address): Update.
8176 * win32-low.c (current_inferior_ptid): Simplify.
8177
8178 2014-02-19 Tom Tromey <tromey@redhat.com>
8179
8180 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8181 argument.
8182 (target_supports_btrace): Update.
8183
8184 2014-02-14 Yao Qi <yao@codesourcery.com>
8185
8186 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8187 (rsp-low-ipa.o): New target.
8188
8189 2014-02-12 Tom Tromey <tromey@redhat.com>
8190
8191 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8192 convert_ascii_to_int.
8193 * regcache.c (registers_to_string): Likewise.
8194 * remote-utils.c (decode_M_packet): Likewise.
8195 * server.c (process_serial_event): Likewise.
8196
8197 2014-02-12 Tom Tromey <tromey@redhat.com>
8198
8199 * server.c (handle_query, handle_v_run): Use hex2bin, not
8200 unhexify.
8201 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8202
8203 2014-02-12 Tom Tromey <tromey@redhat.com>
8204
8205 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8206 convert_int_to_ascii.
8207 * regcache.c (registers_to_string, collect_register_as_string):
8208 Likewise.
8209 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8210 Likewise.
8211 * server.c (process_serial_event): Likewise.
8212 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8213 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8214
8215 2014-02-12 Tom Tromey <tromey@redhat.com>
8216
8217 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8218 bin2hex, not hexify.
8219 * tracepoint.c (cmd_qtstatus): Likewise.
8220
8221 2014-02-12 Tom Tromey <tromey@redhat.com>
8222
8223 * remote-utils.c (monitor_output): Pass explicit length to
8224 hexify.
8225
8226 2014-02-12 Tom Tromey <tromey@redhat.com>
8227
8228 * tracepoint.c: Include rsp-low.h.
8229 * server.c: Include rsp-low.h.
8230 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8231 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8232 declare.
8233 * remote-utils.c: Include rsp-low.h.
8234 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8235 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8236 (convert_int_to_ascii, convert_ascii_to_int): Move to
8237 common/rsp-low.c.
8238 * regcache.c: Include rsp-low.h.
8239 * ax.c: Include rsp-low.h.
8240 * Makefile.in (SFILES): Add common/rsp-low.c.
8241 (OBS): Add rsp-low.o.
8242 (rsp-low.o): New target.
8243
8244 2014-02-12 Tom Tromey <tromey@redhat.com>
8245
8246 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8247 Include print-utils.h.
8248 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8249 (plongest, thirty_two, phex_nz): Remove.
8250 * Makefile.in (SFILES): Add common/print-utils.c.
8251 (OBS): Add print-utils.o.
8252 (print-utils-ipa.o): New target.
8253 (print-utils.o): New target.
8254 (IPA_OBJS): Add print-utils-ipa.o.
8255
8256 2014-02-06 Tom Tromey <tromey@redhat.com>
8257
8258 * Makefile.in (SFILES): Fix indentation.
8259
8260 2014-02-05 Doug Evans <dje@google.com>
8261
8262 * linux-low.c (linux_wait_for_event): Improve comment.
8263 (linux_wait_1): Keep current_inferior in sync with event_child.
8264
8265 2014-01-22 Doug Evans <dje@google.com>
8266
8267 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8268
8269 2014-01-22 Doug Evans <dje@google.com>
8270
8271 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8272 * configure: Regenerate.
8273 * config.in: Regenerate.
8274 * Makefile.in (SFILES): Add debug.c.
8275 (OBS): Add debug.o.
8276 * debug.c: New file.
8277 * debug.h: New file.
8278 * linux-aarch64-low.c (*): Update all debugging printfs to use
8279 debug_printf instead of fprintf.
8280 * linux-arm-low.c (*): Ditto.
8281 * linux-cris-low.c (*): Ditto.
8282 * linux-crisv32-low.c (*): Ditto.
8283 * linux-m32r-low.c (*): Ditto.
8284 * linux-sparc-low.c (*): Ditto.
8285 * linux-x86.c (*): Ditto.
8286 * linux-low.c (*): Ditto.
8287 (linux_wait_1): Add calls to debug_enter, debug_exit.
8288 (linux_wait): Remove redundant debugging printf.
8289 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8290 (linux_resume, unstop_all_lwps): Ditto.
8291 * mem-break.c (*): Update all debugging printfs to use
8292 debug_printf instead of fprintf.
8293 * remote-utils.c (*): Ditto.
8294 * thread-db.c (*): Ditto.
8295 * server.c #include <ctype.h>, "gdb_vecs.h".
8296 (debug_threads): Moved to debug.c.
8297 (*): Update all debugging printfs to use debug_printf instead of
8298 fprintf.
8299 (start_inferior): Replace call to fflush with call to debug_flush.
8300 (monitor_show_help): Mention set debug-format.
8301 (parse_debug_format_options): New function.
8302 (handle_monitor_command): Handle "monitor set debug-format".
8303 (gdbserver_usage): Mention --debug-format.
8304 (main): Parse --debug-format.
8305 * server.h (debug_threads): Declaration moved to debug.h.
8306 #include "debug.h".
8307 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8308 trace_debug_1 that uses debug_printf.
8309 (tracepoint_look_up_symbols): Update all debugging printfs to use
8310 debug_printf instead of fprintf.
8311
8312 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8313
8314 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8315 sys/ptrace.h.
8316
8317 2014-01-17 Pedro Alves <palves@redhat.com>
8318
8319 PR build/16445
8320 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8321 defined after including gdb_proc_service.h.
8322
8323 2014-01-16 Doug Evans <dje@google.com>
8324
8325 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8326 (match_dll): Use it.
8327
8328 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8329
8330 * target.h (target_ops) <read_btrace>: Change parameters and
8331 return type to allow error reporting.
8332 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8333 trace reading errors on.
8334 * linux-low.c (linux_low_read_btrace): Pass trace reading
8335 errors on.
8336 (linux_low_disable_btrace): New.
8337
8338 2014-01-15 Doug Evans <dje@google.com>
8339
8340 * inferiors.c (thread_id_to_gdb_id): Delete.
8341 * inferiors.h (thread_id_to_gdb_id): Delete.
8342
8343 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8344
8345 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8346 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8347 versions.
8348
8349 2014-01-08 Pedro Alves <palves@redhat.com>
8350
8351 * server.c (handle_status): Don't discard previous queued stop
8352 replies or thread's pending status here.
8353 (main) <disconnection>: Do it here instead.
8354
8355 2014-01-08 Pedro Alves <palves@redhat.com>
8356
8357 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8358 * server.c (visit_actioned_threads, handle_pending_status): New
8359 function.
8360 (handle_v_cont): Factor out parts to ...
8361 (resume): ... this new function. If in all-stop, and a thread
8362 being resumed has a pending status, report it without actually
8363 resuming.
8364 (myresume): Adjust to use the new 'resume' function.
8365 (clear_pending_status_callback, set_pending_status_callback)
8366 (find_status_pending_thread_callback): New functions.
8367 (handle_status): Handle the case of multiple threads having
8368 interesting statuses to report. Report threads' real last signal
8369 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8370 with an interesting thread to report the status for, instead of
8371 always reporting the status of the first thread.
8372
8373 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8374
8375 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8376 * gdbreplay.c (gdbreplay_version): Likewise.
8377
8378 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8379
8380 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8381 iov.iov_len with the real length in use.
8382
8383 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8384
8385 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8386 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8387 for all targets that use win32-low.c.
8388 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8389 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8390
8391 2013-12-13 Pedro Alves <palves@redhat.com>
8392
8393 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8394 if equal to TARGET_WAITKIND_LOADED.
8395 * win32-low.c (cached_status): New static global.
8396 (win32_wait): Add declaration.
8397 (do_initial_child_stuff): Flush all initial pending debug events
8398 up to the initial breakpoint.
8399 (win32_wait): If CACHED_STATUS was set, return that instead
8400 of doing a real wait. Remove the code resuming the execution
8401 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8402 during the initial phase. Also remove the code changing
8403 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8404 TARGET_WAITKIND_STOPPED.
8405
8406 2013-12-11 Yao Qi <yao@codesourcery.com>
8407
8408 * notif.c (handle_notif_ack): Return 0 if no notification
8409 matches.
8410
8411 2013-11-20 Doug Evans <dje@google.com>
8412
8413 * linux-low.c (linux_set_resume_request): Fix comment.
8414
8415 2013-11-20 Doug Evans <dje@google.com>
8416
8417 * linux-low.c (resume_status_pending_p): Tweak comment.
8418
8419 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8420
8421 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8422 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8423 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8424 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8425 (srv_amd64_regobj): Add amd64-mpx.o.
8426 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8427 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8428 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8429 * i387-fp.c (num_pl_bnd_register) Added constant.
8430 (num_pl_bnd_cfg_registers) Added constant.
8431 (struct i387_xsave) Added reserved area and MPX fields.
8432 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8433 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8434 function.
8435 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8436 (init_registers_amd64_mpx_linux): Declare new function.
8437 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8438 (x86_64_regmap): Add MPX registers.
8439 (x86_linux_read_description): Add MPX case.
8440 (initialize_low_arch): Initialize MPX targets.
8441
8442 2013-11-18 Tom Tromey <tromey@redhat.com>
8443
8444 * configure: Rebuild.
8445 * configure.ac: Don't check for stdlib.h.
8446 * gdbreplay.c: Unconditionally include stdlib.h.
8447
8448 2013-11-18 Tom Tromey <tromey@redhat.com>
8449
8450 * config.in: Rebuild.
8451 * configure: Rebuild.
8452 * configure.ac: Don't use AC_HEADER_DIRENT.
8453
8454 2013-11-18 Tom Tromey <tromey@redhat.com>
8455
8456 * server.h: Don't check HAVE_STRING_H.
8457 * gdbreplay.c: Don't check HAVE_STRING_H.
8458 * configure: Rebuild.
8459
8460 2013-11-18 Tom Tromey <tromey@redhat.com>
8461
8462 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8463 LIBGNU.
8464
8465 2013-11-08 Tom Tromey <tromey@redhat.com>
8466
8467 * configure, config.in: Rebuild.
8468 * configure.ac: Remove unused configury.
8469
8470 2013-11-08 Tom Tromey <tromey@redhat.com>
8471
8472 * acinclude.m4: Include common.m4, codeset.m4.
8473 * configure, config.in: Rebuild.
8474 * configure.ac: Use GDB_AC_COMMON.
8475
8476 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
8477
8478 * linux-s390-low.c (HWCAP_S390_TE): New define.
8479 (s390_arch_setup): Consider the TE field in the HWCAP for
8480 determining 'have_regset_tdb'.
8481
8482 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
8483
8484 PR gdb/16014
8485 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
8486 call to sizeof.
8487
8488 2013-10-02 Pedro Alves <palves@redhat.com>
8489
8490 * server.c (process_serial_event): Don't output "GDBserver
8491 exiting" if GDB is connected through stdio.
8492 * target.c (mywait): Likewise, be silent if GDB is connected
8493 through stdio.
8494
8495 2013-10-01 Joel Brobecker <brobecker@adacore.com>
8496
8497 * lynx-low.c (lynx_add_threads_after_attach): New function.
8498 (lynx_attach): Remove call to add_thread. Add call to
8499 lynx_add_threads_after_attach instead.
8500
8501 2013-09-28 Mike Frysinger <vapier@gentoo.org>
8502
8503 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
8504 * config.in, configure: Regenerated.
8505
8506 2013-09-18 Yao Qi <yao@codesourcery.com>
8507
8508 PR server/15959
8509 * server.c (start_inferior): Clear 'resume_info'.
8510
8511 2013-09-16 Jiong Wang <jiwang@tilera.com>
8512
8513 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
8514 for each register.
8515
8516 2013-09-16 Jiong Wang <jiwang@tilera.com>
8517
8518 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
8519 linux-tile-low.o to srv_tgtobj.
8520
8521 2013-09-16 Will Newton <will.newton@linaro.org>
8522
8523 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
8524 out regs.
8525
8526 2013-09-06 Pedro Alves <palves@redhat.com>
8527
8528 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
8529 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
8530 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
8531 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
8532 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
8533 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
8534
8535 2013-09-06 Pedro Alves <palves@redhat.com>
8536
8537 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
8538 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
8539
8540 2013-09-06 Pedro Alves <palves@redhat.com>
8541
8542 * linux-amd64-ipa.c: Include tracepoint.h.
8543 * linux-i386-ipa.c: Include tracepoint.h.
8544
8545 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8546
8547 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
8548 (ps_get_thread_area): New function.
8549
8550 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8551
8552 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
8553 (initialize_low_arch): Call init_registers_crisv32 rather than
8554 init_register_crisv32.
8555
8556 2013-09-05 Pedro Alves <palves@redhat.com>
8557
8558 * server.h (handle_vFile, hostio_last_error_from_errno): Move
8559 to ...
8560 * hostio.h: ... this new file.
8561 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
8562 win32-low.c: Include hostio.h.
8563
8564 2013-09-05 Pedro Alves <palves@redhat.com>
8565
8566 * server.h (gdb_client_data, handler_func, callback_handler_func)
8567 (delete_file_handler, add_file_handler, append_callback_event)
8568 (delete_callback_event, start_event_loop, initialize_event_loop):
8569 Move to event-loop.h and include it.
8570 * event-loop.h: New file.
8571
8572 2013-09-05 Pedro Alves <palves@redhat.com>
8573
8574 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
8575 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
8576 (loaded_dll, unloaded_dll): Move to ...
8577 * dll.h: ... this new file.
8578 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
8579
8580 2013-09-05 Pedro Alves <palves@redhat.com>
8581
8582 * server.h (current_process, get_thread_process, all_processes)
8583 (add_inferior_to_list, for_each_inferior, current_inferior)
8584 (remove_inferior, add_process, remove_process, find_process_pid)
8585 (have_started_inferiors_p, have_attached_inferiors_p)
8586 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
8587 (clear_inferiors, find_inferior, find_inferior_id)
8588 (inferior_target_data, set_inferior_target_data)
8589 (inferior_regcache_data, set_inferior_regcache_data): Move to
8590 inferiors.h, and include it.
8591 * inferiors.h: New file.
8592
8593 2013-09-05 Pedro Alves <palves@redhat.com>
8594
8595 * server.h (struct emit_ops, current_insn_ptr, emit_error):
8596 Move ...
8597 * ax.h: ... here.
8598
8599 2013-09-05 Pedro Alves <palves@redhat.com>
8600
8601 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
8602 tracepoint.h.
8603 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
8604 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
8605 (handle_tracepoint_general_set, handle_tracepoint_query)
8606 (tracepoint_finished_step, tracepoint_was_hit)
8607 (release_while_stepping_state_list, current_traceframe)
8608 (in_readonly_region, traceframe_read_mem)
8609 (fetch_traceframe_registers, traceframe_read_sdata)
8610 (traceframe_read_info, struct fast_tpoint_collect_status)
8611 (fast_tracepoint_collecting, force_unlock_trace_buffer)
8612 (handle_tracepoit_bkpts, initialize_low_tracepoint)
8613 (supply_fast_tracepoint_registers)
8614 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
8615 (ipa_tdesc, claim_trampoline_space)
8616 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
8617 (agent_mem_read, agent_get_trace_state_variable_value)
8618 (agent_set_trace_state_variable_value, agent_tsv_read)
8619 (agent_mem_read_string, get_raw_reg_func_addr)
8620 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
8621 * tracepoint.h: ... this new file.
8622
8623 2013-09-05 Pedro Alves <palves@redhat.com>
8624
8625 * server.h (perror_with_name, error, fatal, warning, paddress)
8626 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
8627 include it.
8628 * utils.h: New file.
8629
8630 2013-09-05 Pedro Alves <palves@redhat.com>
8631
8632 * server.h (remote_debug, noack_mode, transport_is_reliable)
8633 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
8634 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
8635 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
8636 (write_enn, initialize_async_io, enable_async_io)
8637 (disable_async_io, check_remote_input_interrupt_request)
8638 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
8639 (dead_thread_notify, prepare_resume_reply)
8640 (decode_address_to_semicolon, decode_address, decode_m_packet)
8641 (decode_M_packet, decode_X_packet, decode_xfer_write)
8642 (decode_search_memory_packet, unhexify, hexify)
8643 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
8644 (look_up_one_symbol, relocate_instruction)
8645 (monitor_output): Move to remote-utils.h, and include it.
8646 * remote-utils.h: New file.
8647
8648 2013-09-05 Pedro Alves <palves@redhat.com>
8649
8650 * server.h (_): Delete.
8651
8652 2013-09-02 Pedro Alves <palves@redhat.com>
8653
8654 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
8655 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
8656 allocated.
8657 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
8658
8659 2013-09-02 Pierre Muller <muller@sourceware.org>
8660
8661 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
8662 or WriteProcessMemory complete successfully and handle
8663 ERROR_PARTIAL_COPY error.
8664
8665 2013-09-02 Pedro Alves <palves@redhat.com>
8666
8667 * server.c (gdb_read_memory): Return -1 on traceframe memory read
8668 error instead of EIO.
8669
8670 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
8671
8672 PR server/15604
8673 * linux-low.c: Include filestuff.h.
8674 (linux_create_inferior) <pid == 0>: Call close_most_fds.
8675 * lynx-low.c: Include filestuff.h.
8676 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
8677 * server.c: Include filestuff.h.
8678 (main): Call notice_open_fds.
8679 * spu-low.c: Include filestuff.h.
8680 (spu_create_inferior) <pid == 0>: Call close_most_fds.
8681
8682 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
8683
8684 * Makefile.in: Explain why ../target and ../nat are not
8685 listed as include file search paths.
8686 (linux-waitpid.o): New object file rule.
8687 * configure.srv (srv_native_linux_obj): New variable.
8688 Replace all occurrences of linux native object files with
8689 $srv_native_linux_obj.
8690 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
8691 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
8692 (linux_enable_event_reporting): Remove declaration.
8693 (my_waitpid): Moved to common/linux-waitpid.c.
8694 (linux_wait_for_event): Pass ptid when calling
8695 linux_enable_event_reporting.
8696 (linux_supports_tracefork_flag): Remove.
8697 (linux_enable_event_reporting): Likewise.
8698 (linux_tracefork_grandchild): Remove.
8699 (STACK_SIZE): Moved to common/linux-ptrace.c.
8700 (linux_tracefork_child): Remove.
8701 (linux_test_for_tracefork): Remove.
8702 (linux_look_up_symbols): Call linux_supports_traceclone.
8703 (initialize_low): Remove call to linux_test_for_tracefork.
8704 * linux-low.h (PTRACE_TYPE_ARG3): Move to
8705 common/linux-ptrace.h.
8706 (PTRACE_TYPE_ARG4): Likewise.
8707 Include linux-ptrace.h.
8708
8709 2013-08-21 Pedro Alves <palves@redhat.com>
8710
8711 * config.in: Renegerate.
8712
8713 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
8714
8715 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
8716 (SFILES): Remove $(srcdir)/common/target-common.c and
8717 add $(srcdir)/target/waitstatus.c.
8718 (OBS): Remove target-common.o and add waitstatus.o.
8719 (server_h): Remove $(srcdir)/../common/target-common.h and
8720 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
8721 and $(srcdir)/../target/waitstatus.h.
8722 (target-common.o): Remove.
8723 (waitstatus.o): New target object file.
8724 * target.h: Do not include target-common.h and
8725 include target/resume.h, target/wait.h and
8726 target/waitstatus.h.
8727
8728 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
8729
8730 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8731 to PTRACE_TYPE_ARG3.
8732 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8733 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
8734 PTRACE_TYPE_ARG4.
8735 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
8736 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
8737
8738 2013-07-27 Jie Zhang <jie@codesourcery.com>
8739 Daniel Jacobowitz <dan@codesourcery.com>
8740 Yao Qi <yao@codesourcery.com>
8741
8742 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
8743 (mips-linux-watch.o): New rule.
8744 (mips_linux_watch_h): New variable.
8745 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
8746 srv_tgtobj.
8747 * linux-mips-low.c: Include mips-linux-watch.h.
8748 (struct arch_process_info, struct arch_lwp_info): New.
8749 (update_watch_registers_callback): New function.
8750 (mips_linux_new_process, mips_linux_new_thread) New functions.
8751 (mips_linux_prepare_to_resume, mips_insert_point): New
8752 functions.
8753 (mips_remove_point, mips_stopped_by_watchpoint): New
8754 functions.
8755 (rsp_bp_type_to_target_hw_bp_type): New function.
8756 (mips_stopped_data_address): New function.
8757 (the_low_target): Add watchpoint support functions.
8758
8759 2013-07-27 Yao Qi <yao@codesourcery.com>
8760
8761 * i386-low.c: Include break-common.h.
8762 (enum target_hw_bp_type): Remove.
8763
8764 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
8765
8766 * Makefile.in (SFILES): /common/target-common.c.
8767 (OBS): Add target-common.o.
8768 (server_h): Add $(srcdir)/../common/target-common.h.
8769 (target-common.o): New target.
8770 * server.c (queue_stop_reply_callback): Free
8771 status string after use.
8772 * target.c (target_waitstatus_to_string): Remove.
8773 * target.h: Include target-common.h.
8774 (resume_kind): Likewise.
8775 (target_waitkind): Likewise.
8776 (target_waitstatus): Likewise.
8777 (TARGET_WNOHANG): Likewise.
8778
8779 2013-07-04 Yao Qi <yao@codesourcery.com>
8780
8781 * Makefile.in (host_alias): Use @host_noncanonical@.
8782 (target_alias): Use @target_noncanonical@.
8783 * configure.ac: Use ACX_NONCANONICAL_TARGET and
8784 ACX_NONCANONICAL_HOST.
8785 * configure: Regenerated.
8786
8787 Revert:
8788 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8789
8790 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8791 * configure: Rebuild.
8792 * Makefile.in (version_host, version_target): Get from configure.
8793 (version.c): Use $(version_host) and $(version_target).
8794
8795 2013-07-03 Pedro Alves <palves@redhat.com>
8796
8797 * Makefile.in (config.status): Depend on development.sh.
8798 * acinclude.m4: Include libmcheck.m4.
8799 * configure: Regenerate.
8800
8801 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8802
8803 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
8804 attribute inside the parentheses.
8805 (winapi_DebugSetProcessKillOnExit): Ditto.
8806 (winapi_DebugBreakProcess): Ditto.
8807 (winapi_GenerateConsoleCtrlEvent): Ditto.
8808
8809 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8810
8811 * notif.h (notif_event): Add a dummy member to avoid compiler
8812 errors.
8813
8814 2013-07-01 Pedro Alves <palves@redhat.com>
8815
8816 * hostio.c (HOSTIO_PATH_MAX): Define.
8817 (require_filename, handle_open, handle_unlink, handle_readlink):
8818 Use it.
8819
8820 2013-07-01 Pedro Alves <palves@redhat.com>
8821
8822 * server.h: Include "pathmax.h".
8823 * linux-low.c: Don't include sys/param.h.
8824 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
8825 MAXPATHLEN.
8826 * win32-low.c: Don't include sys/param.h.
8827 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
8828
8829 2013-07-01 Pedro Alves <palves@redhat.com>
8830
8831 * event-loop.c: Don't check HAVE_UNISTD_H before including
8832 <unistd.h>.
8833 * gdbreplay.c: Likewise.
8834 * remote-utils.c: Likewise.
8835 * server.c: Likewise.
8836 * configure.ac: Don't check for unistd.h.
8837 * configure: Regenerate.
8838
8839 2013-06-28 Tom Tromey <tromey@redhat.com>
8840
8841 * Makefile.in (version.c): Use version.in, not
8842 common/version.in.
8843
8844 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8845
8846 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8847 * configure: Rebuild.
8848 * Makefile.in (version_host, version_target): Get from configure.
8849 (version.c): Use $(version_host) and $(version_target).
8850
8851 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8852
8853 Fix trace-status to output user name without trailing colon.
8854 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
8855
8856 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8857
8858 Fix trace-status to output proper start-time and stop-time.
8859 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
8860 output start time and stop time in hex as gdb expects.
8861
8862 2013-06-26 Pedro Alves <pedro@codesourcery.com>
8863
8864 * tracepoint.c (build_traceframe_info_xml): Output trace state
8865 variables present in the trace buffer.
8866
8867 2013-06-24 Tom Tromey <tromey@redhat.com>
8868
8869 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
8870 create-version.sh.
8871 (version.o): Remove.
8872 * gdbreplay.c: Include version.h.
8873 (version, host_name): Don't declare.
8874 * server.h: Include version.h.
8875 (version, host_name): Don't declare.
8876
8877 2013-06-12 Pedro Alves <palves@redhat.com>
8878
8879 * linux-x86-low.c (linux_is_elf64): Delete global.
8880 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
8881 with local linux_pid_exe_is_elf_64_file use.
8882
8883 2013-06-11 Pedro Alves <palves@redhat.com>
8884
8885 * linux-low.c (regset_disabled, disable_regset): New functions.
8886 (regsets_fetch_inferior_registers)
8887 (regsets_store_inferior_registers): Use them.
8888 (initialize_regsets_info); Don't allocate the disabled_regsets
8889 array here.
8890 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
8891 comment.
8892
8893 2013-06-11 Pedro Alves <palves@redhat.com>
8894
8895 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
8896 xmalloc.
8897
8898 2013-06-11 Pedro Alves <palves@redhat.com>
8899
8900 * linux-x86-low.c (initialize_low_arch): Call
8901 init_registers_x32_avx_linux.
8902
8903 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
8904
8905 Fix compatibility with Android Bionic.
8906 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
8907 it is not empty.
8908
8909 2013-06-07 Pedro Alves <palves@redhat.com>
8910
8911 PR server/14823
8912 * Makefile.in (OBS): Add tdesc.o.
8913 (IPA_OBJS): Add tdesc-ipa.o.
8914 (tdesc-ipa.o): New rule.
8915 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
8916 interface.
8917 * linux-low.c (new_inferior): Delete.
8918 (disabled_regsets, num_regsets): Delete.
8919 (linux_add_process): Adjust to set the new per-process
8920 new_inferior flag.
8921 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
8922 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
8923 was a stop. When calling arch_setup, switch the current inferior
8924 to the thread that got an event.
8925 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
8926 (regsets_fetch_inferior_registers)
8927 (regsets_store_inferior_registers): New regsets_info parameter.
8928 Adjust to use it.
8929 (linux_register_in_regsets): New regs_info parameter. Adjust to
8930 use it.
8931 (register_addr, fetch_register, store_register): New usrregs_info
8932 parameter. Adjust to use it.
8933 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
8934 parameter regs_info. Adjust to use it.
8935 (linux_fetch_registers): Get the current inferior's regs_info, and
8936 adjust to use it.
8937 (linux_store_registers): Ditto.
8938 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
8939 (initialize_low): Don't initialize the target_regsets here. Call
8940 initialize_low_arch.
8941 * linux-low.h (target_regsets): Delete declaration.
8942 (struct regsets_info): New.
8943 (struct usrregs_info): New.
8944 (struct regs_info): New.
8945 (struct process_info_private) <new_inferior>: New field.
8946 (struct linux_target_ops): Delete the num_regs, regmap, and
8947 regset_bitmap fields. New field regs_info.
8948 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
8949 * i387-fp.c (num_xmm_registers): Delete.
8950 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
8951 calls to new interface.
8952 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
8953 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
8954 Infer the number of xmm registers from the regcache's target
8955 description.
8956 * i387-fp.h (num_xmm_registers): Delete.
8957 * inferiors.c (add_thread): Don't install the thread's regcache
8958 here.
8959 * proc-service.c (gregset_info): Fetch the current inferior's
8960 regs_info. Adjust to use it.
8961 * regcache.c: Include tdesc.h.
8962 (register_bytes, reg_defs, num_registers)
8963 (gdbserver_expedite_regs): Delete.
8964 (get_thread_regcache): If the thread doesn't have a regcache yet,
8965 create one, instead of aborting gdbserver.
8966 (regcache_invalidate_one): Rename to ...
8967 (regcache_invalidate_thread): ... this.
8968 (regcache_invalidate_one): New.
8969 (regcache_invalidate): Only invalidate registers of the current
8970 process.
8971 (init_register_cache): Add target_desc parameter, and use it.
8972 (new_register_cache): Ditto. Assert the target description has a
8973 non zero registers_size.
8974 (regcache_cpy): Add assertions. Adjust.
8975 (realloc_register_cache, set_register_cache): Delete.
8976 (registers_to_string, registers_from_string): Adjust.
8977 (find_register_by_name, find_regno, find_register_by_number)
8978 (register_cache_size): Add target_desc parameter, and use it.
8979 (free_register_cache_thread, free_register_cache_thread_one)
8980 (regcache_release, register_cache_size): New.
8981 (register_size): Add target_desc parameter, and use it.
8982 (register_data, supply_register, supply_register_zeroed)
8983 (supply_regblock, supply_register_by_name, collect_register)
8984 (collect_register_as_string, collect_register_by_name): Adjust.
8985 * regcache.h (struct target_desc): Forward declare.
8986 (struct regcache) <tdesc>: New field.
8987 (init_register_cache, new_register_cache): Add target_desc
8988 parameter.
8989 (regcache_invalidate_thread): Declare.
8990 (regcache_invalidate_one): Delete declaration.
8991 (regcache_release): Declare.
8992 (find_register_by_number, register_cache_size, register_size)
8993 (find_regno): Add target_desc parameter.
8994 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
8995 declarations.
8996 * remote-utils.c: Include tdesc.h.
8997 (outreg, prepare_resume_reply): Adjust.
8998 * server.c: Include tdesc.h.
8999 (gdbserver_xmltarget): Delete declaration.
9000 (get_features_xml, process_serial_event): Adjust.
9001 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9002 declare.
9003 (struct process_info) <tdesc>: New field.
9004 (ipa_tdesc): Declare.
9005 * tdesc.c: New file.
9006 * tdesc.h: New file.
9007 * tracepoint.c: Include tdesc.h.
9008 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9009 (get_context_regcache): Adjust to pass ipa_tdesc down.
9010 (do_action_at_tracepoint): Adjust to get the register cache size
9011 from the context regcache's description.
9012 (traceframe_walk_blocks): Adjust to get the register cache size
9013 from the current trace frame's description.
9014 (traceframe_get_pc): Adjust to get current trace frame's
9015 description and pass it down.
9016 (gdb_collect): Adjust to get the register cache size from the
9017 IPA's description.
9018 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9019 (gdbserver_xmltarget): Delete.
9020 (initialize_low_tracepoint): Set the ipa's target description.
9021 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9022 (initialize_low_tracepoint): Set the ipa's target description.
9023 * linux-x86-low.c: Include tdesc.h.
9024 [__x86_64__] (is_64bit_tdesc): New.
9025 (ps_get_thread_area, x86_get_thread_area): Use it.
9026 (i386_cannot_store_register): Rename to ...
9027 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9028 (i386_cannot_fetch_register): Rename to ...
9029 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9030 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9031 to new interface.
9032 (target_regsets): Rename to ...
9033 (x86_regsets): ... this.
9034 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9035 interface.
9036 (x86_siginfo_fixup): Use is_64bit_tdesc.
9037 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9038 (tdesc_x32_avx_linux, tdesc_x32_linux)
9039 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9040 Declare.
9041 (x86_linux_update_xmltarget): Delete.
9042 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9043 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9044 (AMD64_LINUX_USER64_CS): New.
9045 (x86_linux_read_description): New, based on
9046 x86_linux_update_xmltarget.
9047 (same_process_callback): New.
9048 (x86_arch_setup_process_callback): New.
9049 (x86_linux_update_xmltarget): New.
9050 (x86_regsets_info): New.
9051 (amd64_linux_regs_info): New.
9052 (i386_linux_usrregs_info): New.
9053 (i386_linux_regs_info): New.
9054 (x86_linux_regs_info): New.
9055 (x86_arch_setup): Reimplement.
9056 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9057 (x86_emit_ops): Ditto.
9058 (the_low_target): Adjust. Install x86_linux_regs_info,
9059 x86_cannot_fetch_register, and x86_cannot_store_register.
9060 (initialize_low_arch): New.
9061 * linux-ia64-low.c (tdesc_ia64): Declare.
9062 (ia64_fetch_register): Adjust.
9063 (ia64_usrregs_info, regs_info): New globals.
9064 (ia64_regs_info): New function.
9065 (the_low_target): Adjust.
9066 (initialize_low_arch): New function.
9067 * linux-sparc-low.c (tdesc_sparc64): Declare.
9068 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9069 Adjust.
9070 (sparc_arch_setup): New function.
9071 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9072 (the_low_target): Adjust.
9073 (initialize_low_arch): New function.
9074 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9075 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9076 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9077 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9078 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9079 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9080 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9081 (tdesc_powerpc_isa205_vsx64l): Declare.
9082 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9083 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9084 (ppc_set_pc, ppc_get_hwcap): Adjust.
9085 (ppc_usrregs_info): Forward declare.
9086 (!__powerpc64__) ppc_regmap_adjusted: New global.
9087 (ppc_arch_setup): Adjust to the current process'es target
9088 description.
9089 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9090 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9091 (ppc_store_evrregset): Adjust.
9092 (target_regsets): Rename to ...
9093 (ppc_regsets): ... this, and make static.
9094 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9095 (ppc_regs_info): New function.
9096 (the_low_target): Adjust.
9097 (initialize_low_arch): New function.
9098 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9099 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9100 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9101 (tdesc_s390x_linux64v2): Declare.
9102 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9103 (s390_fill_gregset, s390_store_last_break): Adjust.
9104 (target_regsets): Rename to ...
9105 (s390_regsets): ... this, and make static.
9106 (s390_get_pc, s390_set_pc): Adjust.
9107 (s390_get_hwcap): New target_desc parameter, and use it.
9108 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9109 (s390_arch_setup): Adjust to set the current process'es target
9110 description. Don't adjust the regmap.
9111 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9112 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9113 (regs_info_3264): New globals.
9114 (s390_regs_info): New function.
9115 (the_low_target): Adjust.
9116 (initialize_low_arch): New function.
9117 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9118 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9119 [__mips64] (init_registers_mips_linux)
9120 (init_registers_mips_dsp_linux): Delete defines.
9121 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9122 (have_dsp): New global.
9123 (mips_read_description): New, based on mips_arch_setup.
9124 (mips_arch_setup): Reimplement.
9125 (get_usrregs_info): New function.
9126 (mips_cannot_fetch_register, mips_cannot_store_register)
9127 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9128 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9129 (target_regsets): Rename to ...
9130 (mips_regsets): ... this, and make static.
9131 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9132 (dsp_regs_info, regs_info): New globals.
9133 (mips_regs_info): New function.
9134 (the_low_target): Adjust.
9135 (initialize_low_arch): New function.
9136 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9137 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9138 Declare.
9139 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9140 (arm_read_description): New, with bits factored from
9141 arm_arch_setup.
9142 (arm_arch_setup): Reimplement.
9143 (target_regsets): Rename to ...
9144 (arm_regsets): ... this, and make static.
9145 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9146 (arm_regs_info): New function.
9147 (the_low_target): Adjust.
9148 (initialize_low_arch): New function.
9149 * linux-m68k-low.c (tdesc_m68k): Declare.
9150 (target_regsets): Rename to ...
9151 (m68k_regsets): ... this, and make static.
9152 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9153 (m68k_regs_info): New function.
9154 (m68k_arch_setup): New function.
9155 (the_low_target): Adjust.
9156 (initialize_low_arch): New function.
9157 * linux-sh-low.c (tdesc_sharch): Declare.
9158 (target_regsets): Rename to ...
9159 (sh_regsets): ... this, and make static.
9160 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9161 (sh_regs_info, sh_arch_setup): New functions.
9162 (the_low_target): Adjust.
9163 (initialize_low_arch): New function.
9164 * linux-bfin-low.c (tdesc_bfin): Declare.
9165 (bfin_arch_setup): New function.
9166 (bfin_usrregs_info, regs_info): New globals.
9167 (bfin_regs_info): New function.
9168 (the_low_target): Adjust.
9169 (initialize_low_arch): New function.
9170 * linux-cris-low.c (tdesc_cris): Declare.
9171 (cris_arch_setup): New function.
9172 (cris_usrregs_info, regs_info): New globals.
9173 (cris_regs_info): New function.
9174 (the_low_target): Adjust.
9175 (initialize_low_arch): New function.
9176 * linux-cris-low.c (tdesc_crisv32): Declare.
9177 (cris_arch_setup): New function.
9178 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9179 (cris_regs_info): New function.
9180 (the_low_target): Adjust.
9181 (initialize_low_arch): New function.
9182 * linux-m32r-low.c (tdesc_m32r): Declare.
9183 (m32r_arch_setup): New function.
9184 (m32r_usrregs_info, regs_info): New globals.
9185 (m32r_regs_info): Adjust.
9186 (initialize_low_arch): New function.
9187 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9188 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9189 (tic6x_usrregs_info): Forward declare.
9190 (tic6x_read_description): New function, based on ...
9191 (tic6x_arch_setup): ... this. Reimplement.
9192 (target_regsets): Rename to ...
9193 (tic6x_regsets): ... this, and make static.
9194 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9195 (tic6x_regs_info): New function.
9196 (the_low_target): Adjust.
9197 (initialize_low_arch): New function.
9198 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9199 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9200 (target_regsets): Rename to ...
9201 (xtensa_regsets): ... this, and make static.
9202 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9203 globals.
9204 (xtensa_arch_setup, xtensa_regs_info): New functions.
9205 (the_low_target): Adjust.
9206 (initialize_low_arch): New function.
9207 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9208 (nios2_arch_setup): Set the current process'es tdesc.
9209 (target_regsets): Rename to ...
9210 (nios2_regsets): ... this.
9211 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9212 (nios2_regs_info): New function.
9213 (the_low_target): Adjust.
9214 (initialize_low_arch): New function.
9215 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9216 (aarch64_arch_setup): Set the current process'es tdesc.
9217 (target_regsets): Rename to ...
9218 (aarch64_regsets): ... this.
9219 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9220 (aarch64_regs_info): New function.
9221 (the_low_target): Adjust.
9222 (initialize_low_arch): New function.
9223 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9224 globals.
9225 (target_regsets): Rename to ...
9226 (tile_regsets): ... this.
9227 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9228 (tile_regs_info): New function.
9229 (tile_arch_setup): Set the current process'es tdesc.
9230 (the_low_target): Adjust.
9231 (initialize_low_arch): New function.
9232 * spu-low.c (tdesc_spu): Declare.
9233 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9234 * win32-arm-low.c (tdesc_arm): Declare.
9235 (arm_arch_setup): New function.
9236 (the_low_target): Install arm_arch_setup instead of
9237 init_registers_arm.
9238 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9239 (init_windows_x86): Rename to ...
9240 (i386_arch_setup): ... this. Set `win32_tdesc'.
9241 (the_low_target): Adjust.
9242 * win32-low.c (win32_tdesc): New global.
9243 (child_add_thread): Don't create the thread cache here.
9244 (do_initial_child_stuff): Set the new process'es tdesc.
9245 * win32-low.h (struct target_desc): Forward declare.
9246 (win32_tdesc): Declare.
9247 * lynx-i386-low.c (tdesc_i386): Declare global.
9248 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9249 * lynx-low.c (lynx_tdesc): New global.
9250 (lynx_add_process): Set the new process'es tdesc.
9251 * lynx-low.h (struct target_desc): Forward declare.
9252 (lynx_tdesc): Declare global.
9253 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9254 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9255 * nto-low.c (nto_tdesc): New global.
9256 (do_attach): Set the new process'es tdesc.
9257 * nto-low.h (struct target_desc): Forward declare.
9258 (nto_tdesc): Declare.
9259 * nto-x86-low.c (tdesc_i386): Declare.
9260 (nto_x86_arch_setup): Set `nto_tdesc'.
9261
9262 2013-06-04 Gary Benson <gbenson@redhat.com>
9263
9264 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9265 to qSupported response when appropriate.
9266 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9267 with nonzero-length annex.
9268 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9269 arguments supplied in annex.
9270
9271 2013-05-31 Doug Evans <dje@google.com>
9272
9273 PR server/15594
9274 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9275 64 bits in 64-cross-32 environment.
9276
9277 2013-05-28 Pedro Alves <palves@redhat.com>
9278
9279 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9280 (aarch64-without-fpu.c): Delete rule.
9281 * configure.srv (aarch64*-*-linux*): Remove references to
9282 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9283 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9284 declaration.
9285
9286 2013-05-24 Pedro Alves <palves@redhat.com>
9287
9288 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9289 instead of strchr/decode_address. Error if the range isn't split
9290 with a ','. Don't assume there's be a ':' in the action.
9291
9292 2013-05-23 Yao Qi <yao@codesourcery.com>
9293 Pedro Alves <palves@redhat.com>
9294
9295 * linux-low.c (lwp_in_step_range): New function.
9296 (linux_wait_1): If the thread was range stepping and stopped
9297 outside the stepping range, report the stop to GDB. Otherwise,
9298 continue stepping. Add range stepping debug output.
9299 (linux_set_resume_request): Copy the step range from the resume
9300 request to the lwp.
9301 (linux_supports_range_stepping): New.
9302 (linux_target_ops) <supports_range_stepping>: Set to
9303 linux_supports_range_stepping.
9304 * linux-low.h (struct linux_target_ops)
9305 <supports_range_stepping>: New field.
9306 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9307 * linux-x86-low.c (x86_supports_range_stepping): New.
9308 (the_low_target) <supports_range_stepping>: Set to
9309 x86_supports_range_stepping.
9310 * server.c (handle_v_cont): Handle 'r' action.
9311 (handle_v_requests): Append ";r" if the target supports range
9312 stepping.
9313 * target.h (struct thread_resume) <step_range_start,
9314 step_range_end>: New fields.
9315 (struct target_ops) <supports_range_stepping>:
9316 New field.
9317 (target_supports_range_stepping): New macro.
9318
9319 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9320
9321 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9322 confusion in comment.
9323
9324 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9325
9326 * lynx-low.c (struct process_info_private): New type.
9327 (lynx_add_process): New function.
9328 (lynx_create_inferior, lynx_attach): Replace calls to
9329 add_process by calls to lynx_add_process.
9330 (lynx_resume): If PTID is null, then try using
9331 current_process()->private->last_wait_event_ptid.
9332 Add comments.
9333 (lynx_clear_inferiors): Delete. The contents of that function
9334 has been inlined in lynx_mourn;
9335 (lynx_wait_1): Save the ptid in the process's private data.
9336 (lynx_mourn): Free the process' private data. Replace call
9337 to lynx_clear_inferiors by call to clear_inferiors.
9338
9339 2013-05-17 Yao Qi <yao@codesourcery.com>
9340
9341 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9342 the right place.
9343
9344 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9345
9346 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9347 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9348 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9349 PT_TEXT_END_ADDR guards. Update comments.
9350 (linux_target_op) <read_offsets>: Conditionally define to
9351 linux_read_offsets if the target is UCLIBC and if it defines
9352 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9353
9354 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9355 Andrew Jenner <andrew@codesourcery.com>
9356
9357 * Makefile.in (SFILES): Add linux-nios2-low.c.
9358 (clean): Add action to delete nios2-linux.c.
9359 (nios2-linux.c): New rule.
9360 * configure.srv: Add nios2*-*-linux*.
9361 * linux-nios2-low.c: New.
9362
9363 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9364
9365 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9366
9367 2013-04-25 Hui Zhu <hui@codesourcery.com>
9368
9369 PR gdb/15186
9370 * ax.c (ax_printf): Add fflush.
9371
9372 2013-04-22 Tom Tromey <tromey@redhat.com>
9373
9374 * Makefile.in (SFILES): Add filestuff.c.
9375 (OBS): Add filestuff.o.
9376 (filestuff.o): New target.
9377 * config.in, configure: Rebuild.
9378 * configure.ac: Check for fdwalk, pipe2.
9379
9380 2013-04-17 Pedro Alves <palves@redhat.com>
9381
9382 * configure.ac (USE_THREAD_DB): Delete variable.
9383 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9384 Don't AC_SUBST USE_THREAD_DB.
9385 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9386 * config.in, configure: Regenerate.
9387
9388 2013-04-16 Pedro Alves <palves@redhat.com>
9389
9390 * linux-low.h (struct lwp_info) <thread_known>: Move under
9391 the USE_THREAD_DB #ifdef.
9392
9393 2013-04-16 Pedro Alves <palves@redhat.com>
9394
9395 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9396 (linux-low.o): Delete rule.
9397 * linux-low.h: Always include "gdb_thread_db.h" instead of
9398 conditionally including thread_db.h.
9399 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9400 HAVE_THREAD_DB_H.
9401
9402 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9403
9404 * Makefile.in (install-only): Fix make install regression.
9405
9406 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9407
9408 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9409 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9410 installation.
9411 * gdbserver.1: Remove.
9412
9413 2013-03-22 Pedro Alves <palves@redhat.com>
9414
9415 * linux-low.c (handle_extended_wait): Don't call
9416 linux_enable_event_reporting.
9417
9418 2013-03-15 Tony Theodore <tonyt@logyst.com>
9419
9420 PR build/9098:
9421 * Makefile.in (SHELL): Use @SHELL@.
9422
9423 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9424
9425 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9426 compiler warning.
9427
9428 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9429
9430 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9431 Remove extraneous NULL element.
9432
9433 2013-03-13 Yao Qi <yao@codesourcery.com>
9434
9435 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9436 'V' block in trace frame.
9437
9438 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9439
9440 * target.h (struct target_ops): Add btrace ops.
9441 (target_supports_btrace): New macro.
9442 (target_enable_btrace): New macro.
9443 (target_disable_btrace): New macro.
9444 (target_read_btrace): New macro.
9445 * gdbthread.h (struct thread_info): Add btrace field.
9446 * server.c: Include btrace-common.h.
9447 (handle_btrace_general_set): New function.
9448 (handle_btrace_enable): New function.
9449 (handle_btrace_disable): New function.
9450 (handle_general_set): Call handle_btrace_general_set.
9451 (handle_qxfer_btrace): New function.
9452 (struct qxfer qxfer_packets[]): Add btrace entry.
9453 * inferiors.c (remove_thread): Disable btrace.
9454 * linux-low: Include linux-btrace.h.
9455 (linux_low_enable_btrace): New function.
9456 (linux_low_read_btrace): New function.
9457 (linux_target_ops): Add btrace ops.
9458 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9459 Add srv_linux_btrace=yes.
9460 (x86_64-*-linux*): Add linux-btrace.o.
9461 Add srv_linux_btrace=yes.
9462 * configure.ac: Define HAVE_LINUX_BTRACE.
9463 * config.in: Regenerated.
9464 * configure: Regenerated.
9465
9466 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9467
9468 * server.c (handle_qxfer): Preserve error message if -3 is
9469 returned.
9470 (qxfer): Document the -3 return value.
9471
9472 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9473
9474 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
9475 (linux_btrace_h): New variable.
9476 (linux-btrace.o): New rule.
9477
9478 2013-03-08 Stan Shebs <stan@codesourcery.com>
9479 Hafiz Abid Qadeer <abidh@codesourcery.com>
9480
9481 * tracepoint.c (trace_buffer_size): New global.
9482 (DEFAULT_TRACE_BUFFER_SIZE): New define.
9483 (init_trace_buffer): Change to one-argument function. Allocate
9484 trace buffer memory.
9485 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
9486 handle QTBuffer:size packet.
9487 (cmd_bigqtbuffer_size): New function.
9488 (initialize_tracepoint): Call init_trace_buffer with
9489 DEFAULT_TRACE_BUFFER_SIZE.
9490 * server.c (handle_query): Add QTBuffer:size in the
9491 supported packets.
9492
9493 2013-03-07 Yao Qi <yao@codesourcery.com>
9494
9495 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
9496 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
9497 of -1.
9498 (cmd_qtsp): Adjust condition. Do post increment.
9499 Set cur_action and cur_step_action back to 0.
9500
9501 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
9502
9503 PR server/15236
9504 * linux-low.c (linux_write_memory): Return early success if LEN is
9505 zero.
9506
9507 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
9508
9509 * configure.srv: Add x86_64-*-cygwin* as target.
9510
9511 2013-02-28 Tom Tromey <tromey@redhat.com>
9512
9513 * configure.ac: Invoke AC_SYS_LARGEFILE.
9514 * configure, config.in: Rebuild.
9515
9516 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
9517
9518 * win32-low.c: Throughout, fix format strings and casts of
9519 printf-like functions to avoid type related warnings on all
9520 platforms.
9521 (get_child_debug_event): Print dwDebugEventCode as hex since
9522 that's how it's usually documented.
9523
9524 2013-02-28 Yao Qi <yao@codesourcery.com>
9525
9526 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
9527 pulongest.
9528
9529 2013-02-27 Jiong Wang <jiwang@tilera.com>
9530
9531 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
9532 (reg-tilegx32.c): New rule.
9533 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
9534 * linux-tile-low.c (tile_arch_setup): New function. Invoke
9535 different register info initializer according to elf class.
9536 (init_registers_tilgx32): New function. The tilegx32 register info
9537 initializer.
9538 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
9539 (tile_store_gregset): Likewise.
9540
9541 2013-02-27 Yao Qi <yao@codesourcery.com>
9542
9543 * server.c (process_point_options): Print debug message when
9544 debug_threads is true.
9545
9546 2013-02-26 Yao Qi <yao@codesourcery.com>
9547
9548 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
9549
9550 2013-02-19 Pedro Alves <palves@redhat.com>
9551 Kai Tietz <ktietz@redhat.com>
9552
9553 PR gdb/15161
9554
9555 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
9556 instead of strtoul to extract address from packet.
9557 (process_serial_event) <'z'>: Likewise.
9558
9559 2013-02-18 Yao Qi <yao@codesourcery.com>
9560
9561 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
9562
9563 2013-02-14 Pedro Alves <palves@redhat.com>
9564
9565 Plug memory leak.
9566
9567 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
9568 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
9569
9570 2013-02-14 Pedro Alves <palves@redhat.com>
9571
9572 * tracepoint.c (cmd_qtdpsrc): Use savestring.
9573
9574 2013-02-14 Pedro Alves <palves@redhat.com>
9575
9576 * tracepoint.c (save_string): Delete.
9577 (add_tracepoint_action): Use savestring instead of save_string.
9578
9579 2013-02-12 Pedro Alves <palves@redhat.com>
9580
9581 * linux-xtensa-low.c: Ditto.
9582 * xtensa-xtregs.c: Ditto.
9583
9584 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
9585
9586 * thread-db.c (thread_db_get_tls_address): NULL pointer check
9587 thread_db.
9588
9589 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
9590
9591 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
9592 aarch64_num_wp_regs and aarch64_num_bp_regs to
9593 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
9594
9595 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
9596
9597 * linux-aarch64-low.c (ps_get_thread_area): Replace
9598 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
9599
9600 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
9601 Marcus Shawcroft <marcus.shawcroft@arm.com>
9602 Nigel Stephens <nigel.stephens@arm.com>
9603 Yufeng Zhang <yufeng.zhang@arm.com>
9604
9605 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
9606 (aarch64.c, aarch64-without-fpu.c): New targets.
9607 * configure.srv (aarch64*-*-linux*): New.
9608 * linux-aarch64-low.c: New file.
9609
9610 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
9611
9612 * linux-low.c (handle_extended_wait, linux_create_inferior)
9613 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
9614 (dequeue_one_deferred_signal, linux_resume_one_thread)
9615 (fetch_register, linux_write_memory, linux_enable_event_reporting)
9616 (linux_tracefork_grandchild, linux_test_for_tracefork)
9617 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
9618 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
9619 where the argument is 0.
9620
9621 2013-01-25 Yao Qi <yao@codesourcery.com>
9622
9623 * event-loop.c: Include "queue.h".
9624 (gdb_event_p): New typedef.
9625 (struct gdb_event) <next_event>: Remove.
9626 (event_queue): Change to QUEUE(gdb_event_p).
9627 (async_queue_event): Remove.
9628 (gdb_event_xfree): New.
9629 (initialize_event_loop): New.
9630 (process_event): Use API from QUEUE.
9631 (wait_for_event): Likewise.
9632 * server.c (main): Call initialize_event_loop.
9633 * server.h (initialize_event_loop): Declare.
9634
9635 2013-01-18 Yao Qi <yao@codesourcery.com>
9636
9637 * ax.h (struct eval_agent_expr_context): New.
9638 (gdb_eval_agent_expr): Update declaration.
9639 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
9640 TFRAME. Add new argument CTX.
9641 * server.h (struct eval_agent_expr_context): Declare.
9642 (agent_mem_read, agent_tsv_read): Update declaration.
9643 (agent_mem_read_string): Likewise.
9644 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
9645 (add_traceframe_block): Add new argument TPOINT.
9646 Increase TPOINT->traceframe_usage.
9647 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
9648 eval_tracepoint_agent_expr.
9649 (condition_true_at_tracepoint): Likewise.
9650 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
9651 (agent_mem_read_string, agent_tsv_read): Likewise.
9652
9653 2013-01-16 Yao Qi <yao@codesourcery.com>
9654
9655 * linux-low.c (linux_resume_one_lwp): Don't check
9656 'lwp->bp_reinsert != 0'.
9657
9658 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9659 Pedro Alves <palves@redhat.com>
9660
9661 * lynx-low.c (ptrace_request_to_str): Define a temporary
9662 macro and use it to simplify this function's implementation.
9663
9664 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9665
9666 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
9667 sets errno.
9668
9669 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9670
9671 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
9672
9673 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9674
9675 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
9676
9677 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9678
9679 * lynx-low.c (lynx_resume): Use the resume_info parameter
9680 to determine the ptid for the lynx_ptrace call, unless
9681 it is equal to minus_one_ptid, in which case we use the
9682 ptid of the current_inferior.
9683 (lynx_wait_1): After having received a thread create/exit
9684 event, resume the inferior's execution using the signaling
9685 thread's ptid, rather than the old ptid.
9686
9687 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9688
9689 * lynx-low.c (lynx_resume): Delete variable ret.
9690
9691 2013-01-01 Joel Brobecker <brobecker@adacore.com>
9692
9693 * gdbreplay.c (gdbreplay_version): Update copyright year.
9694 * server.c (gdbserver_version): Likewise.
9695
9696 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9697
9698 * lynx-low.c (lynx_wait_1): Add debug trace before adding
9699 new thread.
9700
9701 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9702
9703 * lynx-low.c (ptrace_request_to_str): Add handling for
9704 PTRACE_GETTRACESIG.
9705
9706 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9707
9708 * lynx-low.c (lynx_attach): Delete variable new_process.
9709
9710 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9711
9712 * lynx-low.c (lynx_create_inferior): Delete variable
9713 new_process.
9714
9715 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9716
9717 * lynx-low.c (ptrace_request_to_str): Do not handle
9718 PTRACE_GETTHREADLIST if this macro does not exist.
9719
9720 2012-12-15 Yao Qi <yao@codesourcery.com>
9721
9722 * Makefile.in (OBS): Add notif.o.
9723 * notif.c, notif.h: New.
9724 * server.c: Include "notif.h".
9725 (struct vstop_notif) <next>: Remove.
9726 <base>: New field.
9727 (queue_stop_reply): Update.
9728 (push_event, send_next_stop_reply): Remove.
9729 (discard_queued_stop_replies): Update.
9730 (notif_stop): New variable.
9731 (handle_v_stopped): Remove.
9732 (handle_v_requests): Don't call handle_v_stopped. Call
9733 handle_ack_notif instead.
9734 (queue_stop_reply_callback): Call notif_event_enque instead
9735 of queue_stop_reply.
9736 (handle_status): Don't call send_next_stop_reply, call
9737 notif_write_event instead.
9738 (kill_inferior_callback): Likewise.
9739 (detach_or_kill_inferior_callback): Likewise.
9740 (main): Call initialize_notif.
9741 (process_serial_event): Call QUEUE_is_empty.
9742 (handle_target_event): Call notif_push instead of push event.
9743 * server.h (push_event): Remove declaration.
9744
9745 2012-12-10 Tom Tromey <tromey@redhat.com>
9746
9747 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
9748 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
9749 macros.
9750 (.c.o): Rewrite.
9751 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
9752 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
9753 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
9754 (amd64-linux-ipa.o, ax.o): Rewrite.
9755 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
9756 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
9757 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
9758 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
9759 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
9760 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
9761 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
9762 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
9763 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
9764 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
9765 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
9766 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
9767 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
9768 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
9769 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
9770 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
9771 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
9772 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
9773 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
9774 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
9775 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
9776 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
9777 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
9778 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
9779 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
9780 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
9781 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
9782 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
9783 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
9784 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
9785 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
9786 (reg-tilegx.o): Remove.
9787 (all_object_files): New macro.
9788 Include .deps files.
9789 * aclocal.m4, configure: Rebuild.
9790 * acinclude.m4: Include depstand.m4, lead-dot.m4.
9791 * configure.ac: Invoke ZW_CREATE_DEPDIR,
9792 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
9793
9794 2012-12-05 Tom Tromey <tromey@redhat.com>
9795
9796 PR gdb/14917:
9797 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
9798
9799 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
9800
9801 * configure.ac: Check for linux/perf_event.h.
9802 * config.in: Regenerated.
9803 * configure: Regenerated.
9804
9805 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
9806
9807 * hostio.c (handle_readlink): Decrease buffer size
9808 parameter passed to readlink by one byte.
9809
9810 2012-11-26 Yao Qi <yao@codesourcery.com>
9811
9812 * configure.ac (build_warnings): Append '-Wempty-body'.
9813 * configure: Regenerated.
9814 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
9815 body.
9816
9817 2012-11-15 Pierre Muller <muller@sourceware.org>
9818
9819 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
9820 * config.in: Regenerate.
9821 * configure: Regenerate.
9822 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
9823 Use "gdb_wait.h" header instead of <sys/wait.h> header.
9824 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9825 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
9826 header.
9827 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
9828 instead of <sys/wait.h> header.
9829 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9830
9831 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
9832
9833 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
9834 (various make rules): Remove -DGDBSERVER
9835
9836 2012-11-09 Yao Qi <yao@codesourcery.com>
9837
9838 * spu-low.c (current_ptid): Move it to ..
9839 * gdbthread.h: ... here. New.
9840 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
9841 * server.c (myresume, process_serial_event): Likewise.
9842 * thread-db.c (thread_db_find_new_threads): Likewise.
9843 * tracepoint.c (run_inferior_command): Likewise.
9844
9845 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
9846
9847 * server.c (handle_search_memory_1): Include access length in
9848 warning message.
9849
9850 2012-09-05 Michael Brandt <michael.brandt@axis.com>
9851
9852 * linux-crisv32-low.c: Fix compile errors.
9853
9854 2012-09-04 Yao Qi <yao@codesourcery.com>
9855
9856 * tracepoint.c (cmd_qtsv): Adjust debug message.
9857 Don't check CUR_TPOINT.
9858
9859 2012-08-28 Yao Qi <yao@codesourcery.com>
9860
9861 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
9862 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
9863 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
9864 Remove declarations of xmalloc, xreallloc, xstrdup and
9865 freeargv.
9866 * Makefile.in (libiberty_h): New.
9867 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
9868 (linux-bfin-low.o): Append dependency 'libiberty.h'.
9869
9870 2012-08-23 Yao Qi <yao@codesourcery.com>
9871
9872 * server.h: Remove declaration of 'xsnprintf'.
9873
9874 2012-08-22 Keith Seitz <keiths@redhat.com>
9875
9876 * server.h: Include build-gnulib-gbserver/config.h.
9877 * gdbreplay.c: Likewise.
9878
9879 2012-08-08 Doug Evans <dje@google.com>
9880
9881 * Makefile.in (SFILES): Add gdb_vecs.c.
9882 (OBS): Add gdb_vecs.o.
9883 (gdb_vecs_h, host_defs_h): New variables.
9884 (thread-db.o): Add $(gdb_vecs_h) dependency.
9885 (gdb_vecs.o): New rule.
9886 * thread-db.c: #include "gdb_vecs.h".
9887 (thread_db_load_search): Use a vector to iterate over path elements.
9888 Handle text appearing after "$pdir".
9889
9890 * configure.ac: Add check for strstr.
9891 * config.in: Regenerate.
9892 * configure: Regenerate.
9893
9894 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
9895
9896 * hostio.c (handle_pread): If pread fails, fall back to attempting
9897 lseek/read.
9898 (handle_pwrite): Likewise for pwrite.
9899
9900 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
9901
9902 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
9903 between unsupported TYPE and unimplementable ADDR/LEN combination.
9904 (arm_insert_point): Act on new return value.
9905
9906 2012-07-31 Pedro Alves <palves@redhat.com>
9907
9908 * server.c (process_point_options): Only skip tokens if we find
9909 one that is unrecognized. Don't treat 'X' specially while
9910 skipping unrecognized tokens.
9911
9912 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
9913
9914 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
9915 to 4-byte-align HW breakpoint addresses for Thumb.
9916
9917 2012-07-27 Yao Qi <yao@codesourcery.com>
9918
9919 PR remote/14161.
9920
9921 * server.h: Declare gdb_agent_about_to_close.
9922 * target.c (kill_inferior): Include "agent.h".
9923 New. Send command 'kill'.
9924 * target.h (kill_inferior): Removed macro.
9925 * tracepoint.c (gdb_agent_about_to_close): New.
9926 (gdb_agent_helper_thread): Handle command 'close'.
9927 Wait endlessly until the inferior stops.
9928 Install gdb_agent_remove_socket to atexit hook.
9929 (agent_socket_name): New static variable.
9930 (gdb_agent_socket_init): Replace local variable 'name' with
9931 'agent_socket_name'.
9932 (gdb_agent_remove_socket): New.
9933
9934 2012-07-27 Yao Qi <yao@codesourcery.com>
9935
9936 * server.c (process_point_options): Stop at 'X' when parsing.
9937
9938 2012-07-19 Michael Eager <eager@eagercon.com>
9939
9940 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
9941 to hw_execute.
9942 * linux-x86-low.c (x86_insert_point, x86_remove_point):
9943 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
9944 hardware breakpoint.
9945
9946 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9947
9948 * gdbserver/linux-low.c (initialize_low): Call
9949 linux_ptrace_init_warnings.
9950
9951 2012-07-02 Doug Evans <dje@google.com>
9952
9953 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
9954 pointer to int.
9955
9956 2012-07-02 Stan Shebs <stan@codesourcery.com>
9957
9958 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
9959 (ax.o): Add it to build rule.
9960 (ax-ipa.o): Ditto.
9961 (OBS): Add format.o.
9962 (IPA_OBS): Add format.o.
9963 * server.c (handle_query): Claim support for breakpoint commands.
9964 (process_point_options): Add command case.
9965 (process_serial_event): Leave running if there are printfs in
9966 effect.
9967 * mem-break.h (any_persistent_commands): Declare.
9968 (add_breakpoint_commands): Declare.
9969 (gdb_no_commands_at_breakpoint): Declare.
9970 (run_breakpoint_commands): Declare.
9971 * mem-break.c (struct point_command_list): New struct.
9972 (struct breakpoint): New field command_list.
9973 (any_persistent_commands): New function.
9974 (add_commands_to_breakpoint): New function.
9975 (add_breakpoint_commands): New function.
9976 (gdb_no_commands_at_breakpoint): New function.
9977 (run_breakpoint_commands): New function.
9978 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
9979 locally.
9980 * ax.c: Include format.h.
9981 (ax_printf): New function.
9982 (gdb_eval_agent_expr): Add printf opcode.
9983
9984 2012-06-13 Yao Qi <yao@codesourcery.com>
9985
9986 * server.c (start_inferior): Remove duplicated writes to fields
9987 'last_resume_kind' and 'last_status' of 'current_inferior'.
9988
9989 2012-06-12 Yao Qi <yao@codesourcery.com>
9990 Pedro Alves <palves@redhat.com>
9991
9992 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
9993 comment.
9994 * server.c (handle_v_cont): Extend comment.
9995
9996 2012-06-11 Yao Qi <yao@codesourcery.com>
9997
9998 * linux-low.c (linux_attach): Add 'static'.
9999
10000 2012-06-06 Yao Qi <yao@codesourcery.com>
10001
10002 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10003
10004 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10005
10006 Fix gcc -flto compilation warning.
10007 * server.c (main): Make variable multi_mode and attach volatile.
10008
10009 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10010
10011 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10012 if the platform doesn't know about it.
10013
10014 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10015
10016 * Makefile.in (SFILES): Add linux-tile-low.c.
10017 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10018 * configure.srv: Handle tilegx-*-linux*.
10019 * linux-tile-low.c: New file.
10020
10021 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10022
10023 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10024
10025 2012-05-24 Pedro Alves <palves@redhat.com>
10026
10027 PR gdb/7205
10028
10029 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10030
10031 2012-05-24 Pedro Alves <palves@redhat.com>
10032
10033 PR gdb/7205
10034
10035 Replace target_signal with gdb_signal throughout.
10036
10037 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10038
10039 * linux-low.c (linux_store_registers): Avoid the copying sequence
10040 when no data has been retrieved by ptrace.
10041
10042 2012-05-22 Will Deacon <will.deacon@arm.com>
10043
10044 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10045 Include asm/ptrace.h.
10046 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10047 already defined.
10048
10049 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10050
10051 * linux-low.c (linux_store_registers): Don't re-retrieve data
10052 with ptrace that has already been obtained from /proc. Always
10053 copy any data retrieved with ptrace to the buffer supplied.
10054
10055 2012-05-11 Yao Qi <yao@codesourcery.com>
10056 Pedro Alves <palves@redhat.com>
10057
10058 * linux-low.c (enum stopping_threads_kind): New.
10059 (stopping_threads): Change type to `enum stopping_threads_kind'.
10060 (handle_extended_wait): If stopping and suspending threads, leave
10061 the new_lwp suspended too.
10062 (linux_wait_for_event): Adjust.
10063 (stop_all_lwps): Set `stopping_threads' to
10064 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10065 whether we're suspending threads or just stopping them. Assert no
10066 recursion happens.
10067
10068 2012-04-29 Yao Qi <yao@codesourcery.com>
10069
10070 * server.h: Move some code to ...
10071 * gdbthread.h: ... here. New.
10072 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10073 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10074 (nto-low.o, win32-low.o): Likewise.
10075 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10076 * regcache.c, remote-utils.c, server.c: Likewise.
10077 * target.c, tracepoint.c, win32-low.c: Likewise.
10078
10079 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10080
10081 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10082 (PTRACE_ARG4_TYPE): Likewise.
10083 (PTRACE_XFER_TYPE): Likewise.
10084 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10085 ptrace to PTRACE_ARG3_TYPE.
10086 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10087 (PTRACE_ARG4_TYPE): Likewise.
10088 (PTRACE_XFER_TYPE): Likewise.
10089 (linux_detach_one_lwp): Cast fourth argument of
10090 ptrace to long then PTRACE_ARG4_TYPE.
10091 (regsets_fetch_inferior_registers): Cast third argument of
10092 ptrace to long then PTRACE_ARG3_TYPE.
10093 (regsets_store_inferior_registers): Likewise.
10094
10095 2012-04-20 Pedro Alves <palves@redhat.com>
10096
10097 * configure: Regenerate.
10098
10099 2012-04-19 Pedro Alves <palves@redhat.com>
10100
10101 * Makefile.in (GNULIB_BUILDDIR): New.
10102 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10103 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10104 (all, install-only, uninstall, clean-info, all-lib, clean): No
10105 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10106 (maintainer-clean realclean distclean): Use subdir_do.
10107 (subdir_do): New.
10108 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10109 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10110 * acinclude.m4: Include acx_configure_dir.m4.
10111 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10112 calls. Call AC_PROG_RANLIB. Configure gnulib using
10113 ACX_CONFIGURE_DIR.
10114 (GNULIB): New.
10115 (GNULIB_STDINT_H): Adjust.
10116 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10117 * gdbreplay.c: Include build-gnulib/config.h.
10118 * server.h: Likewise.
10119 * aclocal.m4: Regenerate.
10120 * config.in: Regenerate.
10121 * configure: Regenerate.
10122
10123 2012-04-19 Pedro Alves <palves@redhat.com>
10124
10125 * Makefile.in (LIBGNU, INCGNU): Adjust.
10126 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10127 (all, install-only, uninstall, clean-info, all-lib, clean)
10128 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10129 * configure.ac: Adjust AC_OUTPUT output.
10130 * aclocal.m4: Regenerate.
10131 * configure: Regenerate.
10132
10133 2012-04-19 Pedro Alves <palves@redhat.com>
10134
10135 * Makefile.in (generated_files): New.
10136 (server_h): Remove the explicit dependency on config.h, and depend
10137 on $generated_files.
10138
10139 2012-04-19 Pedro Alves <palves@redhat.com>
10140
10141 * Makefile.in (INCGNU): Add -Ignulib.
10142
10143 2012-04-19 Pedro Alves <palves@redhat.com>
10144
10145 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10146 (INCGNU): ... this, and spell out -I here.
10147 (GNULIB_LIB): Rename to ...
10148 (LIBGNU): ... this.
10149 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10150
10151 2012-04-19 Pedro Alves <palves@redhat.com>
10152
10153 * config.in: Regenerate.
10154
10155 2012-04-19 Pedro Alves <palves@redhat.com>
10156
10157 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10158 * server.h (memmem): Remove declaration.
10159 * config.in: Regenerate.
10160 * configure: Regenerate.
10161
10162 2012-04-19 Yao Qi <yao@codesourcery.com>
10163
10164 * Makefile.in (SFILES): Add common/vec.c.
10165 (OBS): Add vec.o.
10166 (vec.o): New rule.
10167
10168 2012-04-19 Yao Qi <yao@codesourcery.com>
10169
10170 * remote-utils.c (prepare_resume_reply): Replace with macro
10171 target_core_of_thread.
10172 * server.c (handle_qxfer_threads_proper): Likewise.
10173 * target.h (traget_core_of_thread): New macro.
10174
10175 2012-04-18 Pedro Alves <palves@redhat.com>
10176
10177 * aclocal.m4: Regenerate.
10178 * configure: Regenerate.
10179
10180 2012-04-16 Yao Qi <yao@codesourcery.com>
10181
10182 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10183 duplicated on address.
10184
10185 2012-04-16 Yao Qi <yao@codesourcery.com>
10186
10187 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10188 (struct tracepoint_action_ops) <send>: New field.
10189 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10190 (agent_expr_send, x_tracepoint_action_send): New.
10191 (l_tracepoint_action_send): New.
10192 (cmd_qtdp): Download and install tracepoint
10193 according to `use_agent'.
10194 (run_inferior_command): Add one more parameter `len'.
10195 Update callers.
10196 (tracepoint_send_agent): New.
10197 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10198
10199 2012-04-16 Yao Qi <yao@codesourcery.com>
10200
10201 * tracepoint.c (download_tracepoints): Moved to ...
10202 (cmd_qtstart): ... here.
10203
10204 2012-04-14 Yao Qi <yao@codesourcery.com>
10205
10206 * tracepoint.c: Include inttypes.h.
10207 (struct collect_memory_action): Use sized types.
10208 (struct tracepoint): Likewise.
10209 (cmd_qtdp, stop_tracing): Update print specifiers.
10210 (cmd_qtp, response_tracepoint): Likewise.
10211 (collect_data_at_tracepoint): Likewise.
10212 (collect_data_at_step): Likewise.
10213
10214 2012-04-14 Yao Qi <yao@codesourcery.com>
10215
10216 Import gnulib module inttypes.
10217 * aclocal.m4, config.in, configure: Regenerated.
10218
10219 2012-04-14 Yao Qi <yao@codesourcery.com>
10220
10221 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10222 Makefile and config.status at last.
10223
10224 2012-04-13 Yao Qi <yao@codesourcery.com>
10225
10226 * tracepoint.c: Include stdint.h unconditionally.
10227
10228 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10229
10230 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10231 on BFD_HAVE_SYS_PROCFS_TYPE.
10232 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10233 * configure: Regenerate.
10234 * config.in: Likewise.
10235
10236 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10237
10238 * Makefile.in (clean): Also remove x32.c x32-linux.c
10239 x32-avx.c x32-avx-linux.c.
10240 (x32.o): New target.
10241 (x32.c): Likewise.
10242 (x32-linux.o): Likewise.
10243 (x32-linux.c): Likewise.
10244 (x32-avx.o): Likewise.
10245 (x32-avx.c): Likewise.
10246 (x32-avx-linux.o): Likewise.
10247 (x32-avx-linux.c): Likewise.
10248
10249 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10250 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10251 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10252 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10253 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10254 i386/x32-avx-linux.xml.
10255
10256 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10257 (init_registers_x32_avx_linux): Likwise.
10258 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10259 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10260
10261 2012-04-13 Pedro Alves <palves@redhat.com>
10262
10263 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10264 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10265 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10266 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10267 the sub-make.
10268
10269 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10270
10271 * linux-x86-low.c (compat_x32_clock_t): New.
10272 (compat_x32_siginfo_t): Likewise.
10273 (compat_x32_siginfo_from_siginfo): Likewise.
10274 (siginfo_from_compat_x32_siginfo): Likewise.
10275 (linux_is_elf64): Likewise.
10276 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10277 and siginfo_from_compat_x32_siginfo for x32.
10278 (x86_arch_setup): Set linux_is_elf64.
10279
10280 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10281
10282 PR gdb/13969
10283 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10284 e_machine field.
10285 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10286 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10287 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10288 compatible with process.
10289
10290 2012-04-12 Yao Qi <yao@codesourcery.com>
10291
10292 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10293 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10294 (install-only, install-info, clean): Handle sub dir gnulib.
10295 (all-lib, am--refresh): New targets.
10296 (memmem.o): Remove target.
10297 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10298 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10299 (AC_REPLACE_FUNCS): Remove memmem.
10300 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10301 (AC_OUTPUT): Generate Makefile in gnulib/.
10302 * aclocal.m4, config.in, configure: Regenerated.
10303
10304 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10305
10306 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10307
10308 2012-04-05 Pedro Alves <palves@redhat.com>
10309
10310 -Werror=strict-aliasing
10311
10312 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10313 pointer.
10314
10315 2012-04-04 Pedro Alves <palves@redhat.com>
10316
10317 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10318 (sparc_store_gregset_from_stack, sparc_store_gregset)
10319 (sparc_breakpoint_at): Fix formatting.
10320
10321 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10322
10323 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10324 are available.
10325 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10326 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10327 * config.in: Regenerate.
10328 * configure: Likewise.
10329
10330 2012-03-29 Pedro Alves <palves@redhat.com>
10331
10332 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10333 Correct ptrace arguments.
10334
10335 2012-03-28 Pedro Alves <palves@redhat.com>
10336
10337 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10338 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10339 (IA64_FR1_REGNUM): New defines.
10340 (ia64_fetch_register): New.
10341 (the_low_target): Install it.
10342 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10343 field.
10344 * linux-low.c (linux_fetch_registers): Try the
10345 the_low_target.fetch_register hook first.
10346
10347 * linux-arm-low.c (the_low_target): Adjust.
10348 * linux-bfin-low.c (the_low_target): Adjust.
10349 * linux-cris-low.c (the_low_target): Adjust.
10350 * linux-crisv32-low.c (the_low_target): Adjust.
10351 * linux-m32r-low.c (the_low_target): Adjust.
10352 * linux-m68k-low.c (the_low_target): Adjust.
10353 * linux-mips-low.c (the_low_target): Adjust.
10354 * linux-ppc-low.c (the_low_target): Adjust.
10355 * linux-s390-low.c (the_low_target): Adjust.
10356 * linux-sh-low.c (the_low_target): Adjust.
10357 * linux-sparc-low.c (the_low_target): Adjust.
10358 * linux-tic6x-low.c (the_low_target): Adjust.
10359 * linux-x86-low.c (the_low_target): Adjust.
10360 * linux-xtensa-low.c (the_low_target): Adjust.
10361
10362 2012-03-26 Pedro Alves <palves@redhat.com>
10363
10364 * server.c (handle_qxfer_libraries): Don't bail early if
10365 the_target->qxfer_libraries_svr4 is not NULL.
10366
10367 2012-03-26 Pedro Alves <palves@redhat.com>
10368
10369 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10370
10371 2012-03-23 Pedro Alves <palves@redhat.com>
10372
10373 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10374 "library-list-svr4" element's start tag when the the DSO list is
10375 empty.
10376
10377 2012-03-23 Pedro Alves <palves@redhat.com>
10378
10379 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10380 a variable whose type size is the same as the inferior's pointer
10381 size.
10382
10383 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10384
10385 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10386 struct siginfo.
10387 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10388 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10389 * linux-low.h: Include <signal.h>.
10390 (struct siginfo): Remove forward declaration.
10391 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10392 struct siginfo.
10393
10394 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10395
10396 * .gitignore: Ignore more files.
10397
10398 2012-03-19 Pedro Alves <palves@redhat.com>
10399 Jan Kratochvil <jan.kratochvil@redhat.com>
10400
10401 * server.c (cont_thread, general_thread): Add describing comments.
10402 (start_inferior): Clear `cont_thread'.
10403 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10404 of a process.
10405
10406 2012-03-15 Yao Qi <yao@codesourcery.com>
10407
10408 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10409 handling to ...
10410 (cmd_qtdp): ... here.
10411
10412 2012-03-15 Yao Qi <yao@codesourcery.com>
10413
10414 * tracepoint.c (struct tracepoint_action_ops): New.
10415 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10416 (m_tracepoint_action_download): New.
10417 (r_tracepoint_action_download): New.
10418 (x_tracepoint_action_download): New.
10419 (l_tracepoint_action_download): New.
10420 (add_tracepoint_action): Install `action->ops' according type.
10421 (download_tracepoint_1): Move code `download' function pointer
10422 of various tracepoint_action_ops.
10423
10424 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10425
10426 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10427 linux_ptrace_attach_warnings.
10428
10429 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10430
10431 * Makefile.in (linux-ptrace.o): New.
10432 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10433 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10434 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10435 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10436 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10437 of these targets.
10438 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10439
10440 2012-03-08 Yao Qi <yao@codesourcery.com>
10441 Pedro Alves <palves@redhat.com>
10442
10443 Fix PR server/13392.
10444 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10445 offset of JMP insn.
10446 * tracepoint.c (remove_tracepoint): New.
10447 (cmd_qtdp): Call remove_tracepoint when failed to install.
10448
10449 2012-03-07 Pedro Alves <palves@redhat.com>
10450
10451 * linux-low.c (get_detach_signal): New.
10452 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10453 Pass on pending signals to PTRACE_DETACH. Check the result of the
10454 ptrace call.
10455 * server.c (program_signals, program_signals_p): New.
10456 (handle_general_set): Handle QProgramSignals.
10457 * server.h (program_signals, program_signals_p): Declare.
10458
10459 2012-03-05 Pedro Alves <palves@redhat.com>
10460 Jan Kratochvil <jan.kratochvil@redhat.com>
10461
10462 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10463 New comment why.
10464
10465 2012-03-03 Yao Qi <yao@codesourcery.com>
10466
10467 * tracepoint.c (tracepoint_look_up_symbols): Update call to
10468 agent_look_up_symbols.
10469
10470 2012-03-03 Yao Qi <yao@codesourcery.com>
10471
10472 * Makefile.in (linux-low.o): Keep dependence on agent.h.
10473 (linux-x86-low.o): Likewise.
10474 * server.h: Remove in_process_agent_loaded.
10475 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
10476 common/agent.c.
10477 Update callers.
10478
10479 2012-03-03 Yao Qi <yao@codesourcery.com>
10480
10481 * tracepoint.c (gdb_agent_capability): New global.
10482 (in_process_agent_loaded_ust): Renamed to
10483 `in_process_agent_supports_ust'.
10484 Update callers.
10485 (in_process_agent_supports_ust): Call agent_capability_check.
10486 (clear_installed_tracepoints): Assert that agent supports
10487 agent.
10488
10489 2012-03-03 Yao Qi <yao@codesourcery.com>
10490
10491 * linux-low.c (linux_supports_agent): New.
10492 (linux_target_ops): Initialize field `supports_agent' with
10493 linux_supports_agent.
10494 * target.h (struct target_ops) <supports_agent>: New.
10495 (target_supports_agent): New macro.
10496 * server.c (handle_general_set): Handle packet 'QAgent'.
10497 (handle_query): Send `QAgent+'.
10498 * Makefile.in (server.o): Depends on agent.h.
10499
10500 2012-03-03 Yao Qi <yao@codesourcery.com>
10501
10502 * Makefile.in (OBS): Add agent.o.
10503 Add new rule for agent.o.
10504 Track dependence of tracepoint.c on agent.h.
10505 * tracepoint.c (run_inferior_command_1):
10506 (run_inferior_command): Call agent_run_command.
10507 (gdb_ust_connect_sync_socket): Deleted. Move it to
10508 common/agent.c.
10509 (resume_thread, stop_thread): Likewise.
10510 (gdb_ust_socket_init): Renamed to ...
10511 (gdb_agent_socket_init): ... New.
10512 (gdb_ust_thread): Renamed to ...
10513 (gdb_agent_helper_thread): ... New.
10514 (gdb_ust_init): Move some code to ...
10515 (gdb_agent_init): ... here. New.
10516 [HAVE_UST]: Call gdb_ust_init.
10517 (initialize_tracepoint_ftlib): Call gdb_agent_init.
10518 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
10519 * config.in, configure: Regenerated.
10520
10521 2012-03-02 Pedro Alves <palves@redhat.com>
10522
10523 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
10524 * linux-low.c (struct simple_pid_list): New.
10525 (stopped_pids): New a struct simple_pid_list pointer.
10526 (add_to_pid_list, pull_pid_from_list): New.
10527 (handle_extended_wait): Don't assume the first signal new children
10528 report is SIGSTOP. Adjust call to pull_pid_from_list.
10529 (linux_wait_for_lwp): Adjust.
10530
10531 2012-03-02 Yao Qi <yao@codesourcery.com>
10532
10533 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
10534 debug log.
10535
10536 2012-03-02 Yao Qi <yao@codesourcery.com>
10537
10538 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
10539 `stop_pc' and `tpoint'. Update caller.
10540
10541 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
10542
10543 * linux-low.h (linux_target_ops): Add regset_bitmap member.
10544 * linux-low.c (use_linux_regsets): New macro.
10545 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
10546 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
10547 (linux_register_in_regsets): New function.
10548 (usr_fetch_inferior_registers): Skip registers covered by
10549 regsets.
10550 (usr_store_inferior_registers): Likewise.
10551 (usr_fetch_inferior_registers): New macro.
10552 (usr_store_inferior_registers): Likewise.
10553 (linux_fetch_registers): Handle mixed regset/non-regset targets.
10554 (linux_store_registers): Likewise.
10555 * linux-mips-low.c (init_registers_mips_dsp_linux): New
10556 prototype.
10557 (init_registers_mips64_dsp_linux): Likewise.
10558 (init_registers_mips_linux): New macro.
10559 (init_registers_mips_dsp_linux): Likewise.
10560 (mips_dsp_num_regs): Likewise.
10561 (DSP_BASE, DSP_CONTROL): New fallback macros.
10562 (mips_base_regs): New macro.
10563 (mips_regmap): Use it. Fix the size.
10564 (mips_dsp_regmap): New variable.
10565 (mips_dsp_regset_bitmap): Likewise.
10566 (mips_arch_setup): New function.
10567 (mips_cannot_fetch_register): Use the_low_target.regmap rather
10568 than mips_regmap.
10569 (mips_cannot_store_register): Likewise.
10570 (the_low_target): Update .arch_setup, .num_regs and .regmap
10571 initializers. Add .regset_bitmap initializer.
10572 * linux-arm-low.c (the_low_target): Add .regset_bitmap
10573 initializer.
10574 * linux-bfin-low.c (the_low_target): Likewise.
10575 * linux-cris-low.c (the_low_target): Likewise.
10576 * linux-crisv32-low.c (the_low_target): Likewise.
10577 * linux-ia64-low.c (the_low_target): Likewise.
10578 * linux-m32r-low.c (the_low_target): Likewise.
10579 * linux-m68k-low.c (the_low_target): Likewise.
10580 * linux-ppc-low.c (the_low_target): Likewise.
10581 * linux-s390-low.c (the_low_target): Likewise.
10582 * linux-sh-low.c (the_low_target): Likewise.
10583 * linux-sparc-low.c (the_low_target): Likewise.
10584 * linux-tic6x-low.c (the_low_target): Likewise.
10585 * linux-x86-low.c (the_low_target): Likewise.
10586 * linux-xtensa-low.c (the_low_target): Likewise.
10587 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
10588 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
10589 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
10590 srv_xmlfiles.
10591 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
10592 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
10593
10594 2012-02-29 Yao Qi <yao@codesourcery.com>
10595 Pedro Alves <palves@redhat.com>
10596
10597 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
10598 `step_over_finished' is true.
10599
10600 2012-02-27 Pedro Alves <palves@redhat.com>
10601
10602 * linux-low.c (pid_is_stopped): Delete, moved to common/.
10603 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
10604
10605 2012-02-27 Pedro Alves <palves@redhat.com>
10606
10607 PR server/9684
10608 * linux-low.c (pid_is_stopped): New.
10609 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
10610
10611 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
10612
10613 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
10614 of conditions.
10615
10616 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
10617
10618 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
10619
10620 2012-02-24 Luis Machado <lgustavo@codesourcery>
10621
10622 * server.c (handle_query): Advertise support for target-side
10623 breakpoint condition evaluation.
10624 (process_point_options): New function.
10625 (process_serial_event): When inserting a breakpoint, check for
10626 a target-side condition that should be evaluated.
10627
10628 * mem-break.c: Include regcache.h and ax.h.
10629 (point_cond_list_t): New data structure.
10630 (breakpoint) <cond_list>: New field.
10631 (find_gdb_breakpoint_at): Make non-static.
10632 (delete_gdb_breakpoint_at): Clear any target-side
10633 conditions.
10634 (clear_gdb_breakpoint_conditions): New function.
10635 (add_condition_to_breakpoint): Likewise.
10636 (add_breakpoint_condition): Likewise.
10637 (gdb_condition_true_at_breakpoint): Likewise.
10638 (gdb_breakpoint_here): Return result directly instead
10639 of going through a local variable.
10640
10641 * mem-break.h (find_gdb_breakpoint_at): New prototype.
10642 (clear_gdb_breakpoint_conditions): Likewise.
10643 (add_breakpoint_condition): Likewise.
10644 (gdb_condition_true_at_breakpoint): Likewise.
10645
10646 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
10647 (need_step_over_p): Take target-side breakpoint condition into
10648 consideration.
10649
10650 2012-02-24 Luis Machado <lgustavo@codesourcery>
10651
10652 * server.h: Include tracepoint.h.
10653 (agent_mem_read, agent_get_trace_state_variable_value,
10654 agent_set_trace_state_variable_value,
10655 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
10656 get_set_tsv_func_addr): New prototypes.
10657
10658 * ax.h: New include file.
10659 * ax.c: New source file.
10660
10661 * tracepoint.c: Include ax.h.
10662 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
10663 agent_expr, eval_result_type): Move to ax.h.
10664 (parse_agent_expr): Rename to ...
10665 (gdb_parse_agent_expr): ... this, make it non-static and move
10666 to ax.h.
10667 (unparse_agent_expr) Rename to ...
10668 (gdb_unparse_agent_expr): ... this, make it non-static and move
10669 to ax.h.
10670 (eval_agent_expr): Rename to ...
10671 (eval_tracepoint_agent_expr): ... this.
10672 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
10673 forward declarations.
10674 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
10675 (agent_get_trace_state_variable_value): New function.
10676 (agent_set_trace_state_variable_value): New function.
10677 (cmd_qtdp): Call gdb_parse_agent_expr (...).
10678 (response_tracepoint): Call gdb_unparse_agent_expr (...).
10679 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
10680 (condition_true_at_tracepoint): Likewise.
10681 (parse_agent_expr): Rename to ...
10682 (gdb_parse_agent_expr): ... this and move to ax.c.
10683 (unparse_agent_expr): Rename to ...
10684 (gdb_unparse_agent_expr): ... this and move to ax.c.
10685 (gdb_agent_op_name): Move to ax.c.
10686 (eval_agent_expr): Rename to ...
10687 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
10688 and move to ax.c.
10689 (eval_tracepoint_agent_expr): New function.
10690 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
10691 non-static.
10692 (current_insn_ptr, emit_error, struct bytecode_address): Move to
10693 ax.c.
10694 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
10695 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
10696 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
10697 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
10698 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
10699 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
10700 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
10701 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
10702 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
10703 (compile_bytecodes): Remove forward declaration.
10704 (is_goto_target): Move to ax.c.
10705 (compile_bytecodes): Move to ax.c and call
10706 agent_get_trace_state_variable_value (...) and
10707 agent_set_trace_state_variable_value (...).
10708
10709 * Makefile.in: Update ax.c and IPA dependencies.
10710
10711 2012-02-24 Pedro Alves <palves@redhat.com>
10712
10713 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
10714 (cmd_bigqtbuffer_circular): ... this. Only handle
10715 'QTBuffer:circular:'.
10716 (handle_tracepoint_general_set): Adjust.
10717
10718 2012-02-16 Yao Qi <yao@codesourcery.com>
10719
10720 * inferiors.c: Move code to ...
10721 * dll.c: .... here. New.
10722 * server.h: Declare clear_dlls.
10723 * Makefile.in (SFILES): Add dll.c.
10724 (OBS): Add dll.o
10725 (dll.o): New rule.
10726
10727 2012-02-11 Yao Qi <yao@codesourcery.com>
10728
10729 * server.c: (handle_monitor_command): Add a new parameter
10730 `own_buf'.
10731 (handle_query): Update caller.
10732
10733 2012-02-09 Joel Brobecker <brobecker@adacore.com>
10734
10735 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
10736 * configure, config.in: Regenerate.
10737 * hostio.c: Provide an alternate implementation if HAVE_READLINK
10738 is not defined.
10739
10740 2012-02-02 Pedro Alves <palves@redhat.com>
10741
10742 Try SIGKILL first, then PTRACE_KILL.
10743 * linux-low.c (linux_kill_one_lwp): New.
10744 (linux_kill_one_lwp): Rename to ...
10745 (kill_one_lwp_callback): ... this. Use the new
10746 linux_kill_one_lwp.
10747
10748 2012-02-02 Pedro Alves <palves@redhat.com>
10749
10750 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
10751 inferior.
10752
10753 2012-01-27 Pedro Alves <palves@redhat.com>
10754
10755 * linux-low.c (linux_child_pid_to_exec_file): Delete.
10756 (elf_64_file_p): Make static.
10757 (linux_pid_exe_is_elf_64_file): New.
10758 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
10759 Delete declarations.
10760 (linux_pid_exe_is_elf_64_file): Declare.
10761 * linux-x86-low.c (x86_arch_setup): Use
10762 linux_pid_exe_is_elf_64_file.
10763
10764 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
10765
10766 * linux-low.c (linux_wait_for_event_1): Rename to ...
10767 (linux_wait_for_event): ... here and merge it with former
10768 linux_wait_for_event - new variable wait_ptid, use it.
10769 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
10770
10771 2012-01-23 Pedro Alves <palves@redhat.com>
10772
10773 * server.c (main): Avoid yet another case of infinite loop while
10774 detaching/killing after a longjmp.
10775
10776 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10777
10778 Code cleanup.
10779 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
10780
10781 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
10782
10783 * hostio.c (handle_readlink): New function.
10784 (handle_vFile): Call it to handle "vFile:readlink" packets.
10785
10786 2012-01-20 Pedro Alves <palves@redhat.com>
10787 Ulrich Weigand <ulrich.weigand@linaro.org>
10788
10789 * server.c (handle_v_requests): Only support vAttach and vRun to
10790 start multiple processes when in extended protocol mode.
10791
10792 2012-01-17 Pedro Alves <palves@redhat.com>
10793
10794 * tracepoint.c (initialize_tracepoint): Use mmap instead of
10795 memalign plus mprotect to allocate the scratch buffer.
10796
10797 2012-01-13 Pedro Alves <palves@redhat.com>
10798
10799 * server.c (attach_inferior): Clear `cont_thread'.
10800
10801 2012-01-13 Pedro Alves <palves@redhat.com>
10802
10803 * server.c (main): Avoid infinite loop while detaching/killing
10804 after a longjmp.
10805
10806 2012-01-09 Doug Evans <dje@google.com>
10807
10808 * server.c (start_inferior): Set last_ptid in --wrapper case.
10809
10810 2012-01-06 Yao Qi <yao@codesourcery.com>
10811
10812 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
10813 defined.
10814 [IN_PROCESS_AGENT] (debug_agent): New global variable.
10815
10816 2012-01-04 Yao Qi <yao@codesourcery.com>
10817
10818 * tracepoint.c (cmd_qtdp): Print debug message
10819 for static tracepoint.
10820
10821 2012-01-04 Yao Qi <yao@codesourcery.com>
10822
10823 * tracepoint.c (trace_vdebug): Differentiate debug message
10824 between gdbserver and IPA.
10825
10826 2012-01-03 Yao Qi <yao@codesourcery.com>
10827
10828 * tracepoint.c (tracepoint_was_hit): Don't collect for
10829 static tracepoint.
10830
10831 2012-01-02 Joel Brobecker <brobecker@adacore.com>
10832
10833 * terminal.h: Reformat copyright header.
10834
10835 2012-01-02 Joel Brobecker <brobecker@adacore.com>
10836
10837 * server.c (gdbserver_version): Update copyright year.
10838 * gdbreplay.c (gdbreplay_version): Likewise.
10839
10840 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
10841
10842 * linux-low.c (linux_create_inferior): Put empty if clause for write.
10843
10844 Revert:
10845 2011-12-18 Hui Zhu <teawater@gmail.com>
10846 * linux-low.c (linux_create_inferior): Save return value to ret.
10847
10848 2011-12-18 Hui Zhu <teawater@gmail.com>
10849
10850 * linux-low.c (linux_create_inferior): Save return value to ret.
10851
10852 2011-12-16 Doug Evans <dje@google.com>
10853
10854 * linux-low.c (linux_create_inferior): If stdio connection,
10855 redirect stdin from /dev/null, stdout to stderr.
10856 * remote-utils.c (remote_is_stdio): New static global.
10857 (remote_connection_is_stdio): New function.
10858 (remote_prepare): Handle stdio connection.
10859 (remote_open): Ditto.
10860 (remote_close): Don't close stdin for stdio connections.
10861 (read_prim,write_prim): New functions. Replace all calls to
10862 read/write to these.
10863 * server.c (main): Watch for "-" argument. Move call to
10864 remote_prepare before start_inferior.
10865 * server.h (STDIO_CONNECTION_NAME): New macro.
10866 (remote_connection_is_stdio): Declare.
10867
10868 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
10869 in debugging output.
10870
10871 2011-12-15 Yao Qi <yao@codesourcery.com>
10872
10873 * tracepoint.c: Include sys/syscall.h.
10874 (gdb_ust_thread): Remove preprocessor conditional.
10875
10876 2011-12-14 Pedro Alves <pedro@codesourcery.com>
10877
10878 * linux-low.c (linux_detach_one_lwp): Call
10879 the_low_target.prepare_to_resume before detaching.
10880
10881 2011-12-14 Yao Qi <yao@codesourcery.com>
10882
10883 * tracepoint.c (gdb_ust_thread): Don't ignore return value
10884 of write.
10885
10886 2011-12-14 Yao Qi <yao@codesourcery.com>
10887
10888 * i386-low.c (i386_low_stopped_data_address): Initialize local
10889 variable `control'.
10890
10891 2011-12-13 Pedro Alves <pedro@codesourcery.com>
10892
10893 PR remote/13492
10894
10895 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
10896 DR_CONTROL unless necessary. Extend comments.
10897 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
10898 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
10899
10900 2011-12-13 Yao Qi <yao@codesourcery.com>
10901
10902 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
10903 macros.
10904 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
10905
10906 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
10907
10908 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
10909 Print new debug message for such case.
10910
10911 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
10912
10913 Fix overlapping memcpy.
10914 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
10915 the read_inferior_memory transfer.
10916 (delete_fast_tracepoint_jump): New variable buf. Use it for the
10917 write_inferior_memory transfer.
10918 (set_fast_tracepoint_jump): New variable buf. Use it for the
10919 read_inferior_memory and write_inferior_memory transfers.
10920 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
10921 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
10922 Use it for the write_inferior_memory transfer.
10923 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
10924 buffers.
10925
10926 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
10927
10928 * linux-low.c (fetch_register, store_register): Make code
10929 consistent, fix formatting.
10930
10931 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
10932
10933 * linux-low.c (usr_store_inferior_registers): Factor out code
10934 to handle individual registers into...
10935 (store_register): ... this new function.
10936
10937 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
10938
10939 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
10940 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
10941 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
10942 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
10943 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
10944 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
10945 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
10946 (srv_xmlfiles): Add new XML files.
10947
10948 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
10949 and <sys/uio.h>.
10950 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
10951 (init_registers_s390_linux32v1): Add prototype.
10952 (init_registers_s390_linux32v2): Likewise.
10953 (init_registers_s390_linux64v1): Likewise.
10954 (init_registers_s390_linux64v2): Likewise.
10955 (init_registers_s390x_linux64v1): Likewise.
10956 (init_registers_s390x_linux64v2): Likewise.
10957 (s390_num_regs): Increment to 52.
10958 (s390_regmap): Add orig_r2 register.
10959 (s390_num_regs_3264): Increment to 68.
10960 (s390_regmap_3264): Add orig_r2 register.
10961 (s390_collect_ptrace_register): Handle orig_r2 register.
10962 (s390_supply_ptrace_register): Likewise.
10963 (s390_fill_last_break): New function.
10964 (s390_store_last_break): Likewise.
10965 (s390_fill_system_call): New function.
10966 (s390_store_system_call): Likewise.
10967 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
10968 register sets.
10969 (s390_check_regset): New function.
10970 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
10971 NT_S390_SYSTEM_CALL regsets and use appropriate description.
10972 Update target_regsets for available register sets.
10973
10974 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
10975 Jan Kratochvil <jan.kratochvil@redhat.com>
10976
10977 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
10978 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
10979 New.
10980 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
10981 * linux-low.h (struct process_info_private): New member r_debug.
10982 * server.c (handle_qxfer_libraries): Call
10983 the_target->qxfer_libraries_svr4.
10984 (handle_qxfer_libraries_svr4): New function.
10985 (qxfer_packets): New entry "libraries-svr4".
10986 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
10987 * target.h (struct target_ops): New member qxfer_libraries_svr4.
10988 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
10989 PACKET_qXfer_libraries_svr4.
10990
10991 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
10992
10993 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
10994 PSW address/mask between 8-byte and 16-byte formats.
10995 (s390_supply_ptrace_register): Likewise.
10996 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
10997 basic addressing mode bit.
10998
10999 2011-11-24 Stan Shebs <stan@codesourcery.com>
11000
11001 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11002
11003 2011-11-17 Stan Shebs <stan@codesourcery.com>
11004
11005 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11006 (tracing_start_time): New global.
11007 (tracing_stop_time): New global.
11008 (tracing_user_name): New global.
11009 (tracing_notes): New global.
11010 (tracing_stop_note): New global.
11011 (cmd_qtstart): Set traceframe_usage, start_time.
11012 (stop_tracing): Set stop_time.
11013 (cmd_qtstatus): Report additional status.
11014 (cmd_qtp): New function.
11015 (handle_tracepoint_query): Call it.
11016 (cmd_qtnotes): New function.
11017 (handle_tracepoint_general_set): Call it.
11018 (get_timestamp): Rename from tsv_get_timestamp.
11019
11020 2011-11-14 Stan Shebs <stan@codesourcery.com>
11021 Kwok Cheung Yeung <kcy@codesourcery.com>
11022
11023 * linux-x86-low.c (small_jump_insn): New.
11024 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11025 trampoline and error message, build a trampoline and issue a small
11026 jump instruction to it.
11027 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11028 trampoline and error message.
11029 (x86_get_min_fast_tracepoint_insn_len): New.
11030 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11031 * linux-low.h (struct linux_target_ops): Add arguments to
11032 install_fast_tracepoint_jump_pad operation, add new operation.
11033 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11034 arguments.
11035 (linux_get_min_fast_tracepoint_insn_len): New function.
11036 (linux_target_op): Add new operation.
11037 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11038 (gdb_trampoline_buffer_end): Ditto.
11039 (gdb_trampoline_buffer_error): Ditto.
11040 (struct ipa_sym_addresses): Add fields for new IPA variables.
11041 (symbol_list): Add entries for new IPA variables.
11042 (struct tracepoint): Add fields to hold the address range of the
11043 trampoline used by the tracepoint.
11044 (trampoline_buffer_head): New static variable.
11045 (trampoline_buffer_tail): Ditto.
11046 (claim_trampoline_space): New function.
11047 (have_fast_tracepoint_trampoline_buffer): New function.
11048 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11049 structure.
11050 (install_fast_tracepoint): Ditto, also add error buffer argument.
11051 (cmd_qtminftpilen): New function.
11052 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11053 (fast_tracepoint_from_trampoline_address): New function.
11054 (fast_tracepoint_collecting): Handle trampoline as part of jump
11055 pad space.
11056 (set_trampoline_buffer_space): New function.
11057 (initialize_tracepoint): Initialize new IPA variables.
11058 * target.h (struct target_ops): Add arguments to
11059 install_fast_tracepoint_jump_pad operation, add new
11060 get_min_fast_tracepoint_insn_len operation.
11061 (target_get_min_fast_tracepoint_insn_len): New.
11062 (install_fast_tracepoint_jump_pad): Add arguments.
11063 * server.h (IPA_BUFSIZ): Define.
11064 * linux-i386-ipa.c: Include extra header files.
11065 (initialize_fast_tracepoint_trampoline_buffer): New function.
11066 (initialize_low_tracepoint): Call it.
11067 * server.h (set_trampoline_buffer_space): Declare.
11068 (claim_trampoline_space): Ditto.
11069 (have_fast_tracepoint_trampoline_buffer): Ditto.
11070
11071 2011-11-14 Yao Qi <yao@codesourcery.com>
11072
11073 * server.c (handle_query): Handle InstallInTrace for qSupported.
11074 * tracepoint.c (add_tracepoint): Sort list.
11075 (install_tracepoint, download_tracepoint): New.
11076 (cmd_qtdp): Call them to install and download tracepoints.
11077 (sort_tracepoints): Removed.
11078 (cmd_qtstart): Update.
11079
11080 2011-11-14 Yao Qi <yao@codesourcery.com>
11081
11082 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11083 * mem-break.h: Declare.
11084 * tracepoint.c (cmd_qtstart): Move some code to ...
11085 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11086 New.
11087 (download_tracepoints): Move some code to ...
11088 (download_tracepoint_1): ... here. New.
11089
11090 2011-11-08 Yao Qi <yao@codesourcery.com>
11091
11092 * remote-utils.c (relocate_instruction): A comment fix.
11093
11094 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11095
11096 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11097 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11098 dr_status_mirror and dr_control_mirror from debug_reg_state.
11099 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11100 (i386_initial_stuff): Remove use of deleted globals.
11101 (i386_get_thread_context, i386_set_thread_context,
11102 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11103 from debug_reg_state.
11104
11105 2011-11-05 Yao Qi <yao@codesourcery.com>
11106
11107 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11108 address as TPOINT's.
11109
11110 2011-11-02 Stan Shebs <stan@codesourcery.com>
11111
11112 * tracepoint.c (agent_mem_read_string): New function.
11113 (eval_agent_expr): Call it for tracenz.
11114 * server.c (handle_query): Report support for tracenz.
11115
11116 2011-11-02 Yao Qi <yao@codesourcery.com>
11117
11118 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11119
11120 2011-11-02 Yao Qi <yao@codesourcery.com>
11121
11122 * target.h: Fix a typo in comment.
11123
11124 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11125
11126 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11127 clobber the breakpoints' shadows with fast tracepoint jumps.
11128 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11129 * target.c (write_inferior_memory): Also pass MYADDR down to
11130 check_mem_write.
11131
11132 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11133
11134 * configure.ac: Check support for personality routine.
11135 * configure: Regenerate.
11136 * config.in: Likewise.
11137 * linux-low.c: Include <sys/personality.h>.
11138 Define ADDR_NO_RANDOMIZE if necessary.
11139 (linux_create_inferior): Disable address space randomization when
11140 forking inferior, if requested.
11141 (linux_supports_disable_randomization): New function.
11142 (linux_target_ops): Install it.
11143 * server.h (disable_randomization): Declare.
11144 * server.c (disable_randomization): New global variable.
11145 (handle_general_set): Handle QDisableRandomization.
11146 (handle_query): Likewise for qSupported.
11147 (main): Support --disable-randomization and --no-disable-randomization
11148 command line arguments.
11149 * target.h (struct target_ops): Add supports_disable_randomization.
11150 (target_supports_disable_randomization): New macro.
11151
11152 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11153
11154 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11155 ifdef check.
11156 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11157 [!PT_GETDSBT] (target_loadmap): New definition.
11158 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11159 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11160 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11161 and PT_GETDSBT to LINUX_LOADMAP.
11162 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11163 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11164
11165 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11166
11167 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11168 (arm_linux_hwbp_cap): New static variable.
11169 (arm_linux_get_hwbp_cap): Replace by ...
11170 (arm_linux_init_hwbp_cap): ... this new function.
11171 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11172 (arm_linux_get_hw_watchpoint_count): Likewise.
11173 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11174 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11175 (arm_prepare_to_resume): Use perror_with_name instead of error.
11176
11177 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11178
11179 * linux-arm-low.c: Include <signal.h>.
11180 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11181 (struct arm_linux_hwbp_cap): New data type.
11182 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11183 (struct arm_linux_hw_breakpoint): New data type.
11184 (MAX_BPTS, MAX_WPTS): Define.
11185 (struct arch_process_info, struct arch_lwp_info): New data types.
11186 (arm_linux_get_hwbp_cap): New function.
11187 (arm_linux_get_hw_breakpoint_count): Likewise.
11188 (arm_linux_get_hw_watchpoint_count): Likewise.
11189 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11190 (arm_hwbp_control_initialize): Likewise.
11191 (arm_hwbp_control_is_enabled): Likewise.
11192 (arm_hwbp_control_is_initialized): Likewise.
11193 (arm_hwbp_control_disable): Likewise.
11194 (arm_linux_hw_breakpoint_equal): Likewise.
11195 (arm_linux_hw_point_initialize): Likewise.
11196 (struct update_registers_data): New data structure.
11197 (update_registers_callback: New function.
11198 (arm_insert_point): Likewise.
11199 (arm_remove_point): Likewise.
11200 (arm_stopped_by_watchpoint): Likewise.
11201 (arm_stopped_data_address): Likewise.
11202 (arm_new_process): Likewise.
11203 (arm_new_thread): Likewise.
11204 (arm_prepare_to_resume): Likewise.
11205 (the_low_target): Register arm_insert_point, arm_remove_point,
11206 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11207 arm_new_thread, and arm_prepare_to_resume.
11208
11209 2011-09-15 Stan Shebs <stan@codesourcery.com>
11210
11211 * server.h (struct emit_ops): Add compare-goto fields.
11212 * tracepoint.c (gdb_agent_op_sizes): New table.
11213 (emit_eq_goto): New function.
11214 (emit_ne_goto): New function.
11215 (emit_lt_goto): New function.
11216 (emit_le_goto): New function.
11217 (emit_gt_goto): New function.
11218 (emit_ge_goto): New function.
11219 (is_goto_target): New function.
11220 (compile_bytecodes): Recognize special cases of compare-goto
11221 combinations and call specialized emitters for them.
11222 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11223 (amd64_emit_ne_goto): New function.
11224 (amd64_emit_lt_goto): New function.
11225 (amd64_emit_le_goto): New function.
11226 (amd64_emit_gt_goto): New function.
11227 (amd64_emit_ge_goto): New function.
11228 (amd64_emit_ops): Add the new functions.
11229 (i386_emit_eq_goto): New function.
11230 (i386_emit_ne_goto): New function.
11231 (i386_emit_lt_goto): New function.
11232 (i386_emit_le_goto): New function.
11233 (i386_emit_gt_goto): New function.
11234 (i386_emit_ge_goto): New function.
11235 (i386_emit_ops): Add the new functions.
11236
11237 2011-09-08 Stan Shebs <stan@codesourcery.com>
11238
11239 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11240 (i386_emit_epilogue): Restore %ebx.
11241
11242 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11243
11244 * server.c (step_thread): Remove definition.
11245 (process_serial_event): Don't handle Hs.
11246 * server.h (step_thread): Remove declaration.
11247 * target.c (set_desired_inferior): Remove use of step_thread.
11248
11249 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11250
11251 * linux-low.c: Include linux-procfs.h.
11252 (linux_attach_lwp_1): Update comments.
11253 (linux_attach): Scan for existing threads when attaching to a
11254 process that is the tgid.
11255 * Makefile.in: Update dependencies.
11256
11257 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11258
11259 * configure.srv: Add linux-procfs.o dependencies.
11260
11261 2011-08-14 Yao Qi <yao@codesourcery.com>
11262
11263 * target.h (struct target_ops): Fix indent.
11264 * win32-low.c (win32_target_ops): Fix comment.
11265
11266 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11267 Yao Qi <yao@codesourcery.com>
11268
11269 * Makefile.in (clean): Remove tic6x-*.c files.
11270 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11271 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11272 (tic6x-c64xp-linux.c): Likewise.
11273 * configure.srv: Add support for tic6x-*-uclinux.
11274 * linux-tic6x-low.c: New.
11275 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11276
11277 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11278 Yao Qi <yao@codesourcery.com>
11279
11280 * target.h (struct target_ops): Add read_loadmap.
11281 * linux-low.c (struct target_loadseg): New type.
11282 (struct target_loadmap): New type.
11283 (linux_read_loadmap): New function.
11284 (linux_target_ops): Add linux_read_loadmap.
11285 * server.c (handle_query): Support qXfer:fdpic:read packet.
11286 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11287 to NULL.
11288
11289 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11290
11291 * win32-low.c: Include <stdint.h>.
11292
11293 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11294
11295 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11296 to the inferior here.
11297 (i386_remove_aligned_watchpoint): Ditto.
11298 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11299 fit part of the watchpoint in the debug registers.
11300 (i386_update_inferior_debug_regs): New.
11301 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11302 registers, and only update the inferior on success.
11303 (i386_low_remove_watchpoint): Ditto.
11304
11305 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11306
11307 * linux-low.c (compare_ints, unique, list_threads, show_process,
11308 linux_core_of_thread): Delete.
11309 (linux_target_ops): Change linux_core_of_thread to
11310 linux_common_core_of_thread.
11311 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11312 * utils.c (malloc_failure): Change type of argument.
11313 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11314 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11315 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11316 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11317 (IPA_OBJS): Add common-utils-ipa.o.
11318 (ptid_h, linux_osdata_h): New macros.
11319 (server_h): Add common/common-utils.h, common/xml-utils.h,
11320 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11321 common/ptid.h.
11322 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11323 ptid.o, buffer.o): New rules.
11324 (linux-low.o): Add common/linux-osdata.h as a dependency.
11325 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11326 * configure.ac: Add AC_HEADER_DIRENT check.
11327 * config.in: Regenerate.
11328 * configure: Regenerate.
11329 * remote-utils.c (xml_escape_text): Delete.
11330 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11331 buffer_xml_printf): Move to common/buffer.c.
11332 * server.c (main): Remove call to initialize_inferiors.
11333 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11334 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11335 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11336 internal_error, gdb_assert, gdb_assert_fail): Delete.
11337 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11338 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11339 common/buffer.h.
11340 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11341 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11342 initialize_inferiors): Delete.
11343
11344 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11345
11346 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11347 symbol error.
11348
11349 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11350
11351 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11352 assertion.
11353 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11354
11355 2011-05-26 Yao Qi <yao@codesourcery.com>
11356
11357 * Makefile.in (thread-db.o): Track dependence to
11358 common/gdb_thread_db.h.
11359 * thread-db.c: include gdb_thread_db.h from right place.
11360
11361 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11362
11363 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11364 __FILE__ and __LINE__ to internal_error.
11365
11366 2011-05-13 Doug Evans <dje@google.com>
11367
11368 * thread-db.c (try_thread_db_load_from_sdir): New function.
11369 (try_thread_db_load_from_dir): New function.
11370 (thread_db_load_search): Handle $sdir, ignore $pdir.
11371 Remove trying of system directories if search of
11372 libthread-db-search-path fails, that is now done via $sdir.
11373
11374 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11375
11376 * server.c (handle_query): Add EnableDisableTracepoints to the list
11377 of supported features.
11378 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11379 tracepoints.
11380 (cmd_qtenable_disable): New.
11381 (cmd_qtstart): Install tracepoints even if disabled.
11382 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11383 receiving a QTEnable or QTDisable packet.
11384 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11385 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11386 tracepoints.
11387 (gdb_probe): Skip data collection if static tracepoint is disabled.
11388
11389 2011-05-10 Doug Evans <dje@google.com>
11390
11391 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11392
11393 2011-05-04 Doug Evans <dje@google.com>
11394
11395 * linux-low.c (linux_join): Skip process lookup.
11396 * spu-low.c (spu_join): Ditto.
11397 * server.c (join_inferiors_callback): Delete.
11398 (process_serial_event): For 'D' packet (detach) call join_inferior
11399 directly.
11400
11401 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11402
11403 * README: Don't mention xscale*-*-linux*.
11404 * configure.srv (xscale*-*-linux*): Don't handle target.
11405
11406 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11407
11408 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11409 casting pointers.
11410 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11411 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11412 (i386_emit_void_call_2): Likewise.
11413
11414 2011-04-26 Yao Qi <yao@codesourcery.com>
11415
11416 * linux-low.c: Move common macros to linux-ptrace.h.
11417 Include linux-ptrace.h.
11418 * Makefile.in (linux_ptrace_h): New.
11419 (linux-low.o): Depends on linux-ptrace.h.
11420
11421 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11422
11423 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11424 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11425 (remote_prepare): New function with most of the TCP code from ...
11426 (remote_open): ... here. Detect PORT here unconditionally. Move also
11427 setting transport_is_reliable.
11428 * server.c (run_once): New variable.
11429 (gdbserver_usage): Document it.
11430 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11431 the first run if RUN_ONCE.
11432 * server.h (run_once, remote_prepare): New declarations.
11433
11434 2011-04-19 Tom Tromey <tromey@redhat.com>
11435
11436 * win32-low.c (handle_load_dll): Remove duplicate "the".
11437
11438 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11439
11440 Remove support for old Cygwin 1.5 versions.
11441 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11442 function to avoid warning.
11443 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11444 warning.
11445
11446 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11447
11448 * gdbserver/server.h (Macro _): Define it if not available.
11449
11450 2011-03-14 Michael Snyder <msnyder@vmware.com>
11451
11452 * hostio.c (handle_close): Remove unnecessary null test.
11453
11454 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11455
11456 * Makefile.in (maintainer-clean realclean distclean): Remove
11457 "make ... subdir_do" command.
11458
11459 2011-03-10 Michael Snyder <msnyder@vmware.com>
11460
11461 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11462
11463 * server.c (handle_v_run): Free alloced buffer on early return.
11464
11465 2011-03-09 Yao Qi <yao@codesourcery.com>
11466
11467 Revert:
11468 2011-03-04 Yao Qi <yao@codesourcery.com>
11469
11470 * Makefile.in: Remove GNU make feature --directory.
11471
11472 2011-03-05 Yao Qi <yao@codesourcery.com>
11473
11474 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11475 (subdir_do): New make target. Copied from gdb/Makefile.
11476 (maintainer-clean, realclean, distclean, clean): Call corresponding
11477 make targets in common/Makefile.
11478
11479 2011-02-11 Yao Qi <yao@codesourcery.com>
11480
11481 * configure.ac: Call AC_PROG_RANLIB.
11482 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11483 * configure: Regenerate.
11484
11485 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11486
11487 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
11488
11489 2011-03-06 Yao Qi <yao@codesourcery.com>
11490
11491 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
11492
11493 2011-03-05 Yao Qi <yao@codesourcery.com>
11494
11495 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11496 (subdir_do): New make target. Copied from gdb/Makefile.
11497 (maintainer-clean, realclean, distclean, clean): Call corresponding
11498 make targets in common/Makefile.
11499
11500 2011-03-04 Yao Qi <yao@codesourcery.com>
11501
11502 * Makefile.in: Remove GNU make feature --directory.
11503
11504 2011-03-04 Michael Snyder <msnyder@vmware.com>
11505
11506 * server.c (queue_stop_reply): Call xmalloc not malloc.
11507
11508 2011-03-02 Michael Snyder <msnyder@vmware.com>
11509
11510 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
11511
11512 2011-02-28 Michael Snyder <msnyder@vmware.com>
11513
11514 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
11515 (cmd_qtframe): Ditto.
11516 (cmd_qtbuffer): Ditto.
11517 (cmd_bigqtbuffer): Ditto.
11518
11519 * utils.c (decimal2str): Initialize 'width' to nine, then
11520 don't mess with it.
11521
11522 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11523
11524 * hostio.c (require_data): Free *data, not data.
11525
11526 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11527
11528 * hostio.c (require_data): Use free, not xfree.
11529
11530 2011-02-27 Michael Snyder <msnyder@vmware.com>
11531
11532 * server.c (handle_query): Discard unused value.
11533
11534 * hostio.c (require_data): Free malloc memory before returning
11535 error.
11536
11537 2011-02-26 Michael Snyder <msnyder@vmware.com>
11538
11539 * linux-low.c (list_threads): Call closedir for dirent.
11540
11541 2011-02-27 Michael Snyder <msnyder@vmware.com>
11542
11543 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
11544 a case statement falls through.
11545
11546 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
11547
11548 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
11549 in comparison.
11550
11551 2011-02-26 Michael Snyder <msnyder@vmware.com>
11552
11553 * utils.c (decimal2str): Eliminate dead code and dead param.
11554 (pulongest): Drop dead param from call to decimal2str.
11555 (plongest): Ditto.
11556
11557 2011-02-24 Joel Brobecker <brobecker@adacore.com>
11558
11559 Revert the following patch (not approved yet):
11560 2011-02-21 Hui Zhu <teawater@gmail.com>
11561 * tracepoint.c (tp_printf): New function.
11562 (eval_agent_expr): Handle gdb_agent_op_printf.
11563
11564 2011-02-21 Hui Zhu <teawater@gmail.com>
11565
11566 * tracepoint.c (tp_printf): New function.
11567 (eval_agent_expr): Handle gdb_agent_op_printf.
11568
11569 2011-02-18 Tom Tromey <tromey@redhat.com>
11570
11571 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
11572 (tracepoint.o): Likewise.
11573 * tracepoint.c (enum gdb_agent_op): Use ax.def.
11574 (gdb_agent_op_names): Likewise.
11575
11576 2011-02-18 Tom Tromey <tromey@redhat.com>
11577
11578 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
11579 gdb_agent_op_rot>: New constants.
11580 (gdb_agent_op_names): Add pick and roll.
11581 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
11582 cases.
11583
11584 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
11585
11586 * aclocal.m4: Regenerated with aclocal-1.11.1.
11587
11588 2011-02-14 Pedro Alves <pedro@codesourcery.com>
11589
11590 * server.c (handle_qxfer_traceframe_info): New.
11591 (qxfer_packets): Register "traceframe-info".
11592 (handle_query): Report support for qXfer:traceframe-info:read+.
11593 * tracepoint.c (match_blocktype): New.
11594 (traceframe_find_block_type): Rename to ...
11595 (traceframe_walk_blocks): ... this. Add callback filter argument,
11596 and use it.
11597 (traceframe_find_block_type): New, reimplemented on top of
11598 traceframe_walk_blocks.
11599 (build_traceframe_info_xml): New.
11600 (traceframe_read_info): New.
11601 * server.h (traceframe_read_info): Declare.
11602
11603 2011-02-11 Yao Qi <yao@codesourcery.com>
11604
11605 * configure.ac: Call AC_PROG_RANLIB.
11606 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11607 * configure: Regenerate.
11608
11609 2011-02-07 Pedro Alves <pedro@codesourcery.com>
11610
11611 * server.c (gdb_read_memory): Change return semantics to allow
11612 partial transfers.
11613 (handle_search_memory_1): Adjust.
11614 (process_serial_event) <'m' packet>: Handle partial transfers.
11615 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
11616
11617 2011-01-28 Pedro Alves <pedro@codesourcery.com>
11618
11619 * regcache.c (init_register_cache): Initialize
11620 regcache->register_status.
11621 (free_register_cache): Release regcache->register_status.
11622 (regcache_cpy): Copy register_status.
11623 (registers_to_string): Print 'x's for unavailable registers.
11624 (supply_register): Mark the register's status valid or
11625 unavailable, depending on whether a buffer was passed in or not.
11626 (supply_register_zeroed): New.
11627 (supply_regblock): Mark the registers' status valid or
11628 unavailable, depending on whether a buffer was passed in or not.
11629 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
11630 (struct regcache): New `register_status' field.
11631 (supply_register_zeroed): Declare.
11632 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
11633 supply_register_zeroed, rather than passing a NULL buffer to
11634 supply_register.
11635 * tracepoint.c (fetch_traceframe_registers): Update comment.
11636
11637 2011-01-28 Pedro Alves <pedro@codesourcery.com>
11638
11639 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
11640 buffer explicit.
11641
11642 2011-01-25 Pedro Alves <pedro@codesourcery.com>
11643
11644 * server.h (decode_xfer_write): Change prototype.
11645 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
11646 and don't extract the annex here.
11647 * server.c (decode_xfer_read): Remove `annex' parameter,
11648 and don't extract the annex here.
11649 (decode_xfer): New.
11650 (struct qxfer): New.
11651 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
11652 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
11653 (handle_qxfer_statictrace): New functions, abstracted out from
11654 handle_query, and made to use the struct qxfer interface.
11655 (handle_threads_qxfer_proper): Rename to ...
11656 (handle_qxfer_threads_proper): ... this.
11657 (handle_threads_qxfer): Rename to ...
11658 (handle_qxfer_threads): ... this. Adjust.
11659 (qxfer_packets): New array.
11660 (handle_qxfer): New function.
11661 (handle_query): Use handle_qxfer.
11662
11663 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
11664
11665 * gdbreplay.c: Shorten lines of >= 80 columns.
11666 * linux-low.c: Ditto.
11667 * linux-ppc-low.c: Ditto.
11668 * linux-s390-low.c: Ditto.
11669 * linux-sparc-low.c: Ditto.
11670 * linux-x86-low.c: Ditto.
11671 * linux-xtensa-low.c: Ditto.
11672 * mem-break.c: Ditto.
11673 * nto-low.c: Ditto.
11674 * regcache.h: Ditto.
11675 * remote-utils.c: Ditto.
11676 * server.c: Ditto.
11677 * server.h: Ditto.
11678 * thread-db.c: Ditto.
11679 * tracepoint.c: Ditto.
11680 * utils.c: Ditto.
11681 * win32-low.h: Ditto.
11682
11683 2011-01-05 Joel Brobecker <brobecker@adacore.com>
11684
11685 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
11686 update.
11687
11688 2011-01-01 Joel Brobecker <brobecker@adacore.com>
11689
11690 * server.c (gdbserver_version): Update copyright year in version
11691 output.
11692 * gdbreplay.c (gdbreplay_version): Ditto.
11693
11694 2010-12-29 Jie Zhang <jie.zhang@analog.com>
11695
11696 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
11697 * linux-bfin-low.c: New file.
11698 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
11699 PT_DATA_ADDR for BFIN targets.
11700 * Makefile.in (SFILES): Add linux-bfin-low.c.
11701 (clean): Remove reg-bfin.c.
11702 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
11703 * README: Mention supported Blackfin targets.
11704
11705 2010-12-23 Mike Frysinger <vapier@gentoo.org>
11706
11707 * .gitignore: New file.
11708
11709 2010-11-16 Mike Frysinger <vapier@gentoo.org>
11710
11711 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
11712
11713 2010-10-22 Jie Zhang <jie@codesourcery.com>
11714
11715 * Makefile.in: Add FLAGS_TO_PASS variable.
11716 (install): Remove dependency of install-only and recursively
11717 invoke make for install-only.
11718
11719 2010-10-04 Doug Evans <dje@google.com>
11720
11721 * Makefile.in (uninstall): Use $(DESTDIR).
11722
11723 2010-09-24 Pedro Alves <pedro@codesourcery.com>
11724
11725 PR gdb/11842
11726
11727 * linux-x86-low.c (compat_siginfo_from_siginfo)
11728 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
11729 si_code is < 0. Check for si_code == SI_TIMER before checking for
11730 si_code < 0.
11731
11732 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11733
11734 * lynx-i386-low.c: New file.
11735 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
11736
11737 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11738
11739 * lynx-low.c (ptrace_request_to_str): Remove handling for
11740 request values that have been removed in LynxOS 5.x.
11741
11742 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11743
11744 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
11745 <ptrace.h>
11746
11747 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
11748
11749 * configure.ac: Add --enable-inprocess-agent option.
11750 * configure: Rebuilt.
11751
11752 2010-09-06 Yao Qi <yao@codesourcery.com>
11753
11754 * linux-low.c (linux_kill): Remove unused variable.
11755 (linux_stabilize_threads): Likewise.
11756 * server.c (start_inferior): Likewise.
11757 (queue_stop_reply_callback): Likewise.
11758 * tracepoint.c (do_action_at_tracepoint): Likewise.
11759
11760 2010-09-06 Yao Qi <yao@codesourcery.com>
11761
11762 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
11763 on return.
11764
11765 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11766
11767 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
11768
11769 2010-09-06 Pedro Alves <pedro@codesourcery.com>
11770
11771 * Makefile.in (install-only): Replace $IPA_DEPFILES with
11772 "$(IPA_DEPFILES)".
11773
11774 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11775
11776 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
11777 gdbserver/lynx-ppc-low.c: New files.
11778 * Makefile.in (lynx_low_h): New variable.
11779 (lynx-low.o, lynx-ppc-low.o): New rules.
11780 * configure.ac: On LynxOS, link with -lnetinet.
11781 * configure.srv: Add handling of powerpc-*-lynxos* targets.
11782 * configure: regenerate.
11783
11784 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11785
11786 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
11787 * configure.ac: Add check for vasprintf and vsnprintf.
11788 * configure, config.in: Regenerate.
11789 * server.h (vasprintf, vsnprintf): Add conditional declarations.
11790
11791 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11792
11793 * gdbreplay.c: Move include of alloca.h up, next to include of
11794 malloc.h.
11795 * server.h: Add include of malloc.h.
11796 * mem-break.c: Remove include of malloc.h.
11797 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
11798
11799 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11800
11801 * Makefile.in (memmem.o): Build with -Wno-error.
11802
11803 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11804
11805 * utils.c (xsnprintf): Make non-static.
11806 * server.h: Add xsnprintf declaration.
11807 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
11808 replace calls to snprintf by calls to xsnprintf throughout.
11809
11810 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11811
11812 * configure.ac: Add configure check for alloca.
11813 * configure, config.in: Regenerate.
11814 * server.h: Include alloca.h if it exists.
11815 * gdbreplay.c: Include alloca.h if it exists.
11816
11817 2010-08-28 Pedro Alves <pedro@codesourcery.com>
11818
11819 * linux-low.c (__SIGRTMIN): Define if not already defined.
11820 (linux_create_inferior): Check for __ANDROID__ rather than
11821 __SIGRTMIN.
11822 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
11823 are already deferred.
11824 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
11825 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
11826 stopped and already has a pending signal to report.
11827 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
11828 a pending signal to report or is moving out of a jump pad.
11829 (linux_init_signals): Check for __ANDROID__ rather than
11830 __SIGRTMIN.
11831
11832 2010-08-28 Pedro Alves <pedro@codesourcery.com>
11833
11834 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
11835 debug_threads check. Avoid a linear search when not doing debug
11836 output.
11837
11838 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11839
11840 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
11841 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
11842 (struct file_handler) <fd>: Change type to gdb_fildes_t.
11843 (process_event): Change local fd's type to gdb_fildes_t.
11844 (create_file_handler): Adjust prototype.
11845 (delete_file_handler): Adjust prototype.
11846 (handle_file_event): Adjust prototype. Use pfildes.
11847 (create_file_event): Adjsut prototype.
11848 * remote-utils.c (remote_desc, listen_desc): Change type to
11849 gdb_fildes_t.
11850 * server.h: New gdb_fildes_t typedef.
11851 [USE_WIN32API]: Include winsock2.h.
11852 (delete_file_handler, add_file_handler): Adjust prototypes.
11853 (pfildes): Declare.
11854 * utils.c (pfildes): New.
11855
11856 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11857
11858 * configure.ac (build_warnings): Add -Wno-char-subscripts.
11859 * configure: Regenerate.
11860
11861 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11862
11863 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
11864 (linux_done_accessing_memory): ... this.
11865 (linux_target_ops): Adjust.
11866 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
11867 * nto-low.c (nto_target_ops): Adjust comment.
11868 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
11869 * spu-low.c (spu_target_ops): Adjust comment.
11870 * target.h (target_ops): Rename unprepare_to_access_memory field
11871 to done_accessing_memory.
11872 (unprepare_to_access_memory): Rename to ...
11873 (done_accessing_memory): ... this.
11874
11875 2010-08-26 Pedro Alves <pedro@codesourcery.com>
11876
11877 * linux-low.c (linux_prepare_to_access_memory): New.
11878 (linux_unprepare_to_access_memory): New.
11879 (linux_target_ops): Install them.
11880 * server.c (read_memory): Rename to ...
11881 (gdb_read_memory): ... this. Use
11882 prepare_to_access_memory/prepare_to_access_memory.
11883 (write_memory): Rename to ...
11884 (gdb_write_memory): ... this. Use
11885 prepare_to_access_memory/prepare_to_access_memory.
11886 (handle_search_memory_1): Adjust.
11887 (process_serial_event): Adjust.
11888 * target.h (struct target_ops): New fields
11889 prepare_to_access_memory and unprepare_to_access_memory.
11890 (prepare_to_access_memory, unprepare_to_access_memory): New.
11891 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
11892 prepare_to_access_memory/prepare_to_access_memory.
11893 * nto-low.c (nto_target_ops): Adjust.
11894 * spu-low.c (spu_target_ops): Adjust.
11895 * win32-low.c (win32_target_ops): Adjust.
11896
11897 2010-08-26 Pedro Alves <pedro@codesourcery.com>
11898
11899 * Makefile.in (WARN_CFLAGS): Get it from configure.
11900 (WERROR_CFLAGS): New.
11901 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
11902 * configure.ac: Introduce --enable-werror, which adds -Werror to
11903 the compiler command line. Enabled by default. Disable with
11904 --disable-werror. Add -Wdeclaration-after-statement
11905 Wpointer-arith and -Wformat-nonliteral to warning flags.
11906 * configure: Regenerate.
11907
11908 2010-08-26 Pedro Alves <pedro@codesourcery.com>
11909
11910 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
11911
11912 2010-08-26 Pedro Alves <pedro@codesourcery.com>
11913
11914 * gdbreplay.c (remote_error): New.
11915 (gdbchar): New.
11916 (expect): Use gdbchar. Check for error reading from GDB.
11917 Clarify sync error output.
11918 (play): Check for errors writing to GDB.
11919 * linux-low.c (sigchld_handler): Really ignore `write' errors.
11920 * remote-utils.c (getpkt): Check for errors writing to the remote
11921 descriptor.
11922
11923 2010-08-25 Pedro Alves <pedro@codesourcery.com>
11924
11925 * linux-low.c (linux_wait_1): Move non-debugging code out of
11926 `debug_threads' control.
11927
11928 2010-08-25 Pedro Alves <pedro@codesourcery.com>
11929
11930 * linux-low.c (linux_wait_1): Don't set last_status here.
11931 * server.c (push_event, queue_stop_reply_callback): Assert we're
11932 not pushing a TARGET_WAITKIND_IGNORE event.
11933 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
11934 (myresume, handle_target_event): Set the thread's last_resume_kind
11935 and last_status from the target returned status.
11936
11937 2010-08-25 Pedro Alves <pedro@codesourcery.com>
11938
11939 PR threads/10729
11940
11941 * linux-x86-low.c (update_debug_registers_callback): New.
11942 (i386_dr_low_set_addr): Use it.
11943 (i386_dr_low_get_addr): New.
11944 (i386_dr_low_set_control): Use update_debug_registers_callback.
11945 (i386_dr_low_get_control): New.
11946 (i386_dr_low_get_status): Adjust.
11947 * linux-low.c (linux_stop_lwp): New.
11948 * linux-low.h (linux_stop_lwp): Declare.
11949
11950 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
11951 argument instead of a i386_debug_reg_state.
11952 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
11953 a i386_debug_reg_state.
11954 (i386_insert_aligned_watchpoint): Adjust.
11955 (i386_remove_aligned_watchpoint): Adjust.
11956 (i386_low_stopped_data_address): Read the debug registers from the
11957 inferior instead of from the mirrors.
11958 * i386-low.h (struct i386_debug_reg_state): Extend comment.
11959 (i386_dr_low_get_addr): Declare.
11960 (i386_dr_low_get_control): Declare.
11961 (i386_dr_low_get_status): Change prototype.
11962
11963 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
11964 (i386_dr_low_get_addr): New.
11965 (i386_dr_low_get_control): New.
11966 (i386_dr_low_get_status): Adjust prototype. Return
11967 dr_status_mirror.
11968 (i386_initial_stuff): Clear dr_status_mirror and
11969 dr_control_mirror.
11970 (i386_get_thread_context): Adjust.
11971 (i386_set_thread_context): Adjust.
11972 (i386_thread_added): Adjust.
11973
11974 2010-08-24 Pedro Alves <pedro@codesourcery.com>
11975
11976 * linux-low.h (linux_thread_area): Delete declaration.
11977
11978 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
11979
11980 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
11981 after its termination.
11982
11983 2010-08-09 Pedro Alves <pedro@codesourcery.com>
11984
11985 * linux-low.c (gdb_wants_lwp_stopped): Delete.
11986 (gdb_wants_all_stopped): Delete.
11987 (linux_wait_1): Don't call them.
11988 * server.c (handle_v_cont): Tag all threads as want-stopped.
11989 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
11990 stopped as "client-wants-stopped".
11991
11992 2010-07-31 Pedro Alves <pedro@codesourcery.com>
11993
11994 * Makefile.in (signals_h): New.
11995 (server_h): Depend on it.
11996 (server.o): Don't depend on $(signals_def).
11997 (signals.o): Depend on $(signals_def).
11998
11999 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12000
12001 * Makefile.in (signals_def): New.
12002 (server_h): Append include/gdb/signals.h and signals_def.
12003 (server.o): Append signals_def.
12004
12005 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12006
12007 * server.c (handle_target_event): Use target_signal_to_host for
12008 resume_info.sig initialization.
12009 * target.h (struct thread_resume) <sig>: New comment.
12010
12011 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12012
12013 * server.c (handle_query): strcpy() the returned string from paddress()
12014 instead of sprintf().
12015 * utils.c (paddress): Return phex_nz().
12016
12017 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12018
12019 * server.c (handle_v_cont): Call mourn_inferior if process
12020 just exited.
12021 (myresume): Likewise.
12022
12023 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12024
12025 Static tracepoints, and integration with UST.
12026
12027 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12028 * mem-break.c (uninsert_all_breakpoints)
12029 (reinsert_all_breakpoints): New.
12030 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12031 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12032 (gdb_agent_ust_loaded, helper_thread_id)
12033 (gdb_agent_helper_thread_id): New macros.
12034 (struct ipa_sym_addresses): Add addr_ust_loaded,
12035 addr_helper_thread_id, addr_cmd_buf.
12036 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12037 (in_process_agent_loaded_ust): New.
12038 (write_e_ust_not_loaded): New.
12039 (maybe_write_ipa_ust_not_loaded): New.
12040 (struct collect_static_trace_data_action): New.
12041 (enum tracepoint_type) <static_tracepoint>: New.
12042 (struct tracepoint) <handle>: Mention static tracepoints.
12043 (struct static_tracepoint_ctx): New.
12044 (CMD_BUF_SIZE): New.
12045 (add_tracepoint_action): Handle static tracepoint actions.
12046 (unprobe_marker_at): New.
12047 (clear_installed_tracepoints): Handle static tracepoints.
12048 (cmd_qtdp): Handle static tracepoints.
12049 (probe_marker_at): New.
12050 (cmd_qtstart): Handle static tracepoints.
12051 (response_tracepoint): Handle static tracepoints.
12052 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12053 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12054 (get_context_regcache): Handle static tracepoints.
12055 (do_action_at_tracepoint): Handle static tracepoint actions.
12056 (traceframe_find_block_type): Handle static trace data blocks.
12057 (traceframe_read_sdata): New.
12058 (download_tracepoints): Download static tracepoint actions.
12059 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12060 (GDB_PROBE_NAME): New.
12061 (ust_ops): New.
12062 (GET_UST_SYM): New.
12063 (USTF): New.
12064 (dlsym_ust): New.
12065 (ust_marker_to_static_tracepoint): New.
12066 (gdb_probe): New.
12067 (collect_ust_data_at_tracepoint): New.
12068 (gdb_ust_probe): New.
12069 (UNIX_PATH_MAX, SOCK_DIR): New.
12070 (gdb_ust_connect_sync_socket): New.
12071 (resume_thread, stop_thread): New.
12072 (run_inferior_command): New.
12073 (init_named_socket): New.
12074 (gdb_ust_socket_init): New.
12075 (cstr_to_hexstr): New.
12076 (next_st): New.
12077 (first_marker, next_marker): New.
12078 (response_ust_marker): New.
12079 (cmd_qtfstm, cmd_qtsstm): New.
12080 (unprobe_marker_at, probe_marker_at): New.
12081 (cmd_qtstmat, gdb_ust_thread): New.
12082 (gdb_ust_init): New.
12083 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12084 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12085 (ST_REGENTRY): New.
12086 (x86_64_st_collect_regmap): New.
12087 (X86_64_NUM_ST_COLLECT_GREGS): New.
12088 (AMD64_RIP_REGNUM): New.
12089 (supply_static_tracepoint_registers): New.
12090 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12091 (ST_REGENTRY): New.
12092 (i386_st_collect_regmap): New.
12093 (i386_NUM_ST_COLLECT_GREGS): New.
12094 (supply_static_tracepoint_registers): New.
12095 * server.c (handle_query): Handle qXfer:statictrace:read.
12096 <qSupported>: Report support for StaticTracepoints, and
12097 qXfer:statictrace:read features.
12098 * server.h (traceframe_read_sdata)
12099 (supply_static_tracepoint_registers): Declare.
12100 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12101 (unpack_varlen_hex): Include in IPA build.
12102 * Makefile.in (ustlibs, ustinc): New.
12103 (IPA_OBJS): Add remote-utils-ipa.o.
12104 ($(IPA_LIB)): Link -ldl and -lpthread.
12105 (UST_CFLAGS): New.
12106 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12107 * config.in, configure: Regenerate.
12108
12109 2010-06-20 Ian Lance Taylor <iant@google.com>
12110 Pedro Alves <pedro@codesourcery.com>
12111
12112 * linux-x86-low.c (always_true): Delete.
12113 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12114 trying to fool the compiler with always_true.
12115
12116 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12117
12118 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12119 conditions in gdbserver.
12120
12121 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12122
12123 * spu-low.c (spu_read_memory): Wrap around local store limit.
12124 (spu_write_memory): Likewise.
12125
12126 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12127
12128 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12129 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12130 LONGEST uses.
12131 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12132 uses.
12133 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12134 uses with LONGEST uses.
12135
12136 2010-06-14 Stan Shebs <stan@codesourcery.com>
12137 Pedro Alves <pedro@codesourcery.com>
12138
12139 Bytecode compiler.
12140
12141 * linux-x86-low.c: Include limits.h.
12142 (add_insns): New.
12143 (always_true): New.
12144 (EMIT_ASM): New.
12145 (EMIT_ASM32): New.
12146 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12147 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12148 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12149 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12150 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12151 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12152 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12153 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12154 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12155 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12156 (amd64_emit_void_call_2): New.
12157 (amd64_emit_ops): New.
12158 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12159 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12160 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12161 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12162 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12163 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12164 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12165 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12166 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12167 (i386_emit_stack_adjust, i386_emit_int_call_1)
12168 (i386_emit_void_call_2): New.
12169 (i386_emit_ops): New.
12170 (x86_emit_ops): New.
12171 (the_low_target): Install x86_emit_ops.
12172 * server.h (struct emit_ops): New.
12173 (get_raw_reg_func_addr): Declare.
12174 (current_insn_ptr, emit_error): Declare.
12175 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12176 (set_trace_state_variable_value): New defines.
12177 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12178 addr_get_trace_state_variable_value and
12179 addr_set_trace_state_variable_value.
12180 (symbol_list): New fields for get_raw_reg,
12181 get_trace_state_variable_value and set_trace_state_variable_value.
12182 (condfn): New typedef.
12183 (struct tracepoint): New field `compiled_cond'.
12184 (do_action_at_tracepoint): Clear compiled_cond.
12185 (get_trace_state_variable_value, set_trace_state_variable_value):
12186 Export in the IPA.
12187 (condition_true_at_tracepoint): If there's a compiled condition,
12188 run that.
12189 (current_insn_ptr, emit_error): New globals.
12190 (struct bytecode_address): New.
12191 (get_raw_reg_func_addr): New.
12192 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12193 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12194 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12195 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12196 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12197 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12198 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12199 (compile_tracepoint_condition, compile_bytecodes): New.
12200 * target.h (emit_ops): Forward declare.
12201 (struct target_ops): New field emit_ops.
12202 (target_emit_ops): New.
12203 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12204 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12205 * linux-low.c (linux_emit_ops): New.
12206 (linux_target_ops): Install it.
12207 * linux-low.h (struct linux_target_ops): New field emit_ops.
12208
12209 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12210
12211 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12212 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12213
12214 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12215 Stan Shebs <stan@codesourcery.com>
12216
12217 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12218 (all): Depend on $(extra_libraries).
12219 (install-only): Install the IPA.
12220 (IPA_OBJS, IPA_LIB): New.
12221 (clean): Remove the IPA lib.
12222 (IPAGENT_CFLAGS): New.
12223 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12224 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12225 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12226 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12227 * configure.ac: Check for atomic builtins support in the compiler.
12228 (IPA_DEPFILES, extra_libraries): Define.
12229 * configure.srv (ipa_obj): Add description.
12230 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12231 (i[34567]86-*-linux*): Set ipa_obj.
12232 (x86_64-*-linux*): Set ipa_obj.
12233 * linux-low.c (stabilizing_threads): New.
12234 (supports_fast_tracepoints): New.
12235 (linux_detach): Stabilize threads before detaching.
12236 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12237 the lwp is either not stabilizing, or is moving out of a jump pad.
12238 (linux_fast_tracepoint_collecting): New.
12239 (maybe_move_out_of_jump_pad): New.
12240 (enqueue_one_deferred_signal): New.
12241 (dequeue_one_deferred_signal): New.
12242 (linux_wait_for_event_1): If moving out of a jump pad, defer
12243 pending signals to later.
12244 (linux_stabilize_threads): New.
12245 (linux_wait_1): Check if threads need moving out of jump pads, and
12246 do it if so.
12247 (stuck_in_jump_pad_callback): New.
12248 (move_out_of_jump_pad_callback): New.
12249 (lwp_running): New.
12250 (linux_resume_one_lwp): Handle moving out of jump pads.
12251 (linux_set_resume_request): Dequeue deferred signals.
12252 (need_step_over_p): Also step over fast tracepoint jumps.
12253 (start_step_over): Also uninsert fast tracepoint jumps.
12254 (finish_step_over): Also reinsert fast tracepoint jumps.
12255 (linux_install_fast_tracepoint_jump): New.
12256 (linux_target_ops): Install linux_stabilize_threads and
12257 linux_install_fast_tracepoint_jump_pad.
12258 * linux-low.h (linux_target_ops) <get_thread_area,
12259 install_fast_tracepoint_jump_pad>: New fields.
12260 (struct lwp_info) <collecting_fast_tracepoint,
12261 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12262 (linux_get_thread_area): Declare.
12263 * linux-x86-low.c (jump_insn): New.
12264 (x86_get_thread_area): New.
12265 (append_insns): New.
12266 (push_opcode): New.
12267 (amd64_install_fast_tracepoint_jump_pad): New.
12268 (i386_install_fast_tracepoint_jump_pad): New.
12269 (x86_install_fast_tracepoint_jump_pad): New.
12270 (the_low_target): Install x86_get_thread_area and
12271 x86_install_fast_tracepoint_jump_pad.
12272 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12273 (struct fast_tracepoint_jump): New.
12274 (fast_tracepoint_jump_insn): New.
12275 (fast_tracepoint_jump_shadow): New.
12276 (find_fast_tracepoint_jump_at): New.
12277 (fast_tracepoint_jump_here): New.
12278 (delete_fast_tracepoint_jump): New.
12279 (set_fast_tracepoint_jump): New.
12280 (uninsert_fast_tracepoint_jumps_at): New.
12281 (reinsert_fast_tracepoint_jumps_at): New.
12282 (set_breakpoint_at): Use write_inferior_memory.
12283 (uninsert_raw_breakpoint): Use write_inferior_memory.
12284 (check_mem_read): Mask out fast tracepoint jumps.
12285 (check_mem_write): Mask out fast tracepoint jumps.
12286 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12287 (set_fast_tracepoint_jump): Declare.
12288 (delete_fast_tracepoint_jump)
12289 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12290 (reinsert_fast_tracepoint_jumps_at): Declare.
12291 * regcache.c: Don't compile many functions when building the
12292 in-process agent library.
12293 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12294 the register buffer in the heap.
12295 (free_register_cache): If the register buffer isn't owned by the
12296 regcache, don't free it.
12297 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12298 pre-existing register caches.
12299 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12300 type.
12301 (convert_ascii_to_int): : Constify `from' parameter type.
12302 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12303 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12304 the needed buffer in-place.
12305 (relocate_instruction): New.
12306 * server.c (handle_query) <qSymbols>: If the target supports
12307 tracepoints, give it a chance of looking up symbols. Report
12308 support for fast tracepoints.
12309 (handle_status): Stabilize threads.
12310 (process_serial_event): Adjust.
12311 * server.h (struct fast_tracepoint_jump): Forward declare.
12312 (struct process_info) <fast_tracepoint_jumps>: New field.
12313 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12314 (decode_X_packet, decode_M_packet): Adjust.
12315 (relocate_instruction): Declare.
12316 (in_process_agent_loaded): Declare.
12317 (tracepoint_look_up_symbols): Declare.
12318 (struct fast_tpoint_collect_status): Declare.
12319 (fast_tracepoint_collecting): Declare.
12320 (force_unlock_trace_buffer): Declare.
12321 (handle_tracepoint_bkpts): Declare.
12322 (initialize_low_tracepoint)
12323 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12324 * target.h (struct target_ops) <stabilize_threads,
12325 install_fast_tracepoint_jump_pad>: New fields.
12326 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12327 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12328 [HAVE_STDINT_H]: Include stdint.h.
12329 (trace_debug_1): Rename to ...
12330 (trace_vdebug): ... this.
12331 (trace_debug): Rename to ...
12332 (trace_debug_1): ... this. Add `level' parameter.
12333 (trace_debug): New.
12334 (ATTR_USED, ATTR_NOINLINE): New.
12335 (IP_AGENT_EXPORT): New.
12336 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12337 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12338 (about_to_request_buffer_space, trace_buffer_is_full)
12339 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12340 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12341 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12342 (traceframe_write_count, traceframes_created)
12343 (trace_state_variables)
12344 New renaming defines.
12345 (struct ipa_sym_addresses): New.
12346 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12347 (symbol_list): New.
12348 (ipa_sym_addrs): New.
12349 (all_tracepoint_symbols_looked_up): New.
12350 (in_process_agent_loaded): New.
12351 (write_e_ipa_not_loaded): New.
12352 (maybe_write_ipa_not_loaded): New.
12353 (tracepoint_look_up_symbols): New.
12354 (debug_threads) [IN_PROCESS_AGENT]: New.
12355 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12356 (UNKNOWN_SIDE_EFFECTS): New.
12357 (stop_tracing): New.
12358 (flush_trace_buffer): New.
12359 (stop_tracing_bkpt): New.
12360 (flush_trace_buffer_bkpt): New.
12361 (read_inferior_integer): New.
12362 (read_inferior_uinteger): New.
12363 (read_inferior_data_pointer): New.
12364 (write_inferior_data_pointer): New.
12365 (write_inferior_integer): New.
12366 (write_inferior_uinteger): New.
12367 (struct collect_static_trace_data_action): Delete.
12368 (enum tracepoint_type): New.
12369 (struct tracepoint) <type>: New field `type'.
12370 <actions_str, step_actions, step_actions_str>: Only include in
12371 GDBserver.
12372 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12373 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12374 (tracepoints): Use IP_AGENT_EXPORT.
12375 (last_tracepoint): Don't include in the IPA.
12376 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12377 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12378 (alloced_trace_state_variables): New.
12379 (trace_state_variables): Use IP_AGENT_EXPORT.
12380 (traceframe_t): Delete unused variable.
12381 (circular_trace_buffer): Don't include in the IPA.
12382 (trace_buffer_start): Delete.
12383 (struct trace_buffer_control): New.
12384 (trace_buffer_free): Delete.
12385 (struct ipa_trace_buffer_control): New.
12386 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12387 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12388 New.
12389 (trace_buffer_ctrl): New.
12390 (TRACE_BUFFER_CTRL_CURR): New.
12391 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12392 Reimplement as macros.
12393 (trace_buffer_wrap): Delete.
12394 (traceframe_write_count, traceframe_read_count)
12395 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12396 (struct tracepoint_hit_ctx) <type>: New field.
12397 (struct fast_tracepoint_ctx): New.
12398 (memory_barrier): New.
12399 (cmpxchg): New.
12400 (record_tracepoint_error): Update atomically in the IPA.
12401 (clear_inferior_trace_buffer): New.
12402 (about_to_request_buffer_space): New.
12403 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12404 updating the same buffer.
12405 (add_tracepoint): Default the tracepoint's type to trap
12406 tracepoint, and orig_size to -1.
12407 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12408 internal variables.
12409 (create_trace_state_variable): New parameter `gdb'. Handle it.
12410 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12411 (cmd_qtdp): Handle fast tracepoints.
12412 (cmd_qtdv): Adjust.
12413 (max_jump_pad_size): New.
12414 (gdb_jump_pad_head): New.
12415 (get_jump_space_head): New.
12416 (claim_jump_space): New.
12417 (sort_tracepoints): New.
12418 (MAX_JUMP_SIZE): New.
12419 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12420 IPA.
12421 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12422 support. Upload fast traceframes, and delete internal IPA
12423 breakpoints.
12424 (stop_tracing_handler): New.
12425 (flush_trace_buffer_handler): New.
12426 (cmd_qtstop): Upload fast tracepoints.
12427 (response_tracepoint): Handle fast tracepoints.
12428 (tracepoint_finished_step): Upload fast traceframes. Set the
12429 tracepoint hit context's tracepoint type.
12430 (handle_tracepoint_bkpts): New.
12431 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12432 type. Add comment about fast tracepoints.
12433 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12434 non-existing action_str field.
12435 (get_context_regcache): Handle fast tracepoints.
12436 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12437 to the regcache.
12438 (fast_tracepoint_from_jump_pad_address): New.
12439 (fast_tracepoint_from_ipa_tpoint_address): New.
12440 (collecting_t): New.
12441 (force_unlock_trace_buffer): New.
12442 (fast_tracepoint_collecting): New.
12443 (collecting): New.
12444 (gdb_collect): New.
12445 (write_inferior_data_ptr): New.
12446 (target_tp_heap): New.
12447 (target_malloc): New.
12448 (download_agent_expr): New.
12449 (UALIGN): New.
12450 (download_tracepoints): New.
12451 (download_trace_state_variables): New.
12452 (upload_fast_traceframes): New.
12453 (IPA_FIRST_TRACEFRAME): New.
12454 (IPA_NEXT_TRACEFRAME_1): New.
12455 (IPA_NEXT_TRACEFRAME): New.
12456 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12457 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12458 (gdb_jump_pad_buffer_end): New.
12459 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12460 (initialize_tracepoint): Adjust.
12461 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12462 buffer. Initialize the low module.
12463 * utils.c (PREFIX, TOOLNAME): New.
12464 (malloc_failure): Use PREFIX.
12465 (error): In the IPA, an error causes an exit.
12466 (fatal, warning): Use PREFIX.
12467 (internal_error): Use TOOLNAME.
12468 (NUMCELLS): Increase to 10.
12469 * configure, config.in: Regenerate.
12470
12471 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12472
12473 * server.c (handle_query) <qSupported>: Do two passes over the
12474 qSupported string to avoid nesting strtok.
12475
12476 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12477
12478 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
12479 (CDEPS): New.
12480 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
12481 -Wl,--dynamic-list.
12482 * configure: Regenerate.
12483 * proc-service.list: New.
12484
12485 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12486
12487 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
12488 New comment.
12489
12490 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
12491
12492 * gdbreplay.c (remote_open): Check error return from socket() call by
12493 its equality to -1 not by it being negative.
12494 * remote-utils.c (remote_open): Likewise.
12495
12496 2010-05-23 Pedro Alves <pedro@codesourcery.com>
12497
12498 * config.h: Regenerate.
12499
12500 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12501
12502 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
12503 doesn't provide PTRACE_GET_THREAD_AREA.
12504
12505 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12506
12507 * linux-m68k-low.c: Include <asm/ptrace.h>
12508 (ps_get_thread_area): Implement.
12509
12510 2010-05-03 Doug Evans <dje@google.com>
12511
12512 * event-loop.c (struct callback_event): New struct.
12513 (callback_list): New global.
12514 (append_callback_event, delete_callback_event): New functions.
12515 (process_callback): New function.
12516 (start_event_loop): Call it.
12517 * remote-utils.c (NOT_SCHEDULED): Define.
12518 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
12519 moved out of readchar.
12520 (readchar): Rewrite. Call reschedule before returning.
12521 (reset_readchar): New function.
12522 (remote_close): Call it.
12523 (process_remaining, reschedule): New functions.
12524 * server.h (callback_handler_func): New typedef.
12525 (append_callback_event, delete_callback_event): Declare.
12526
12527 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12528
12529 * proc-service.c (ps_pglobal_lookup): Use
12530 thread_db_look_up_one_symbol.
12531 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
12532 parameter. Use it instead of all_symbols_looked_up.
12533 * server.h (struct process_info) <all_symbols_looked_up>: Delete
12534 field.
12535 (all_symbols_looked_up): Don't declare.
12536 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
12537 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
12538 field.
12539 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
12540 Set all_symbols_looked_up here.
12541 (thread_db_look_up_one_symbol): New.
12542 (thread_db_get_tls_address): Adjust.
12543 (thread_db_load_search, try_thread_db_load_1): Always allocate the
12544 thread_db object on the heap, and tentatively set it in the
12545 process structure.
12546 (thread_db_init): Don't set all_symbols_looked_up here.
12547 * linux-low.h (thread_db_look_up_one_symbol): Declare.
12548
12549 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12550
12551 * linux-low.c (linux_kill, linux_detach): Adjust.
12552 (status_pending_p_callback): Remove redundant statement. Check
12553 for !TARGET_WAITIKIND_IGNORE, instead of
12554 TARGET_WAITKIND_STOPPED.
12555 (handle_tracepoints): Make sure LWP is locked. Adjust.
12556 (linux_wait_for_event_1): Adjust.
12557 (linux_cancel_breakpoints): New.
12558 (unsuspend_one_lwp): New.
12559 (unsuspend_all_lwps): New.
12560 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
12561 (send_sigstop_callback): Change return type to int, add new
12562 `except' parameter and handle it.
12563 (suspend_and_send_sigstop_callback): New.
12564 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
12565 pass them down. If SUSPEND, also increment the lwp's suspend
12566 count.
12567 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
12568 (need_step_over_p): Don't consider suspended LWPs.
12569 (start_step_over): Adjust.
12570 (proceed_one_lwp): Change return type to int, add new `except'
12571 parameter and handle it.
12572 (unsuspend_and_proceed_one_lwp): New.
12573 (proceed_all_lwps): Use find_inferior instead of
12574 for_each_inferior.
12575 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
12576 also decrement the suspend count of LWPs. Pass `except' down,
12577 instead of hacking its suspend count.
12578 (linux_pause_all): Add `freeze' parameter. Adjust.
12579 (linux_unpause_all): New.
12580 (linux_target_ops): Install linux_unpause_all.
12581 * server.c (handle_status): Adjust.
12582 * target.h (struct target_ops): New fields `unpause_all' and
12583 `cancel_breakpoints'. Add new parameter to `pause_all'.
12584 (pause_all): Add new `freeze' parameter.
12585 (unpause_all): New.
12586 (cancel_breakpoints): New.
12587 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
12588 cancel breakpoints.
12589 (cmd_qtstart): Pause threads.
12590 (stop_tracing): Pause threads, and cancel breakpoints.
12591 * win32-low.c (win32_target_ops): Adjust.
12592
12593 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12594
12595 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
12596 the inferior right away from here...
12597 (linux_wait_1): ... to here, and adjust to check the thread's
12598 last_resume_kind instead of the lwp's step or stop_expected flags.
12599
12600 2010-05-02 Pedro Alves <pedro@codesourcery.com>
12601
12602 * README: Use consistent `GDB' and `GDBserver' spellings.
12603
12604 2010-05-02 Pedro Alves <pedro@codesourcery.com>
12605
12606 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
12607 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
12608 (linux_detach_one_lwp): Assume the lwp is stopped.
12609 (any_thread_of): Delete.
12610 (linux_detach): Stop all lwps here. Don't blindly delete all
12611 breakpoints.
12612 (delete_lwp_callback): New.
12613 (linux_mourn): Delete all lwps of the process that is gone.
12614 (linux_wait_1): Don't delete the last lwp of the process here.
12615 * mem-break.h (mark_breakpoints_out): Declare.
12616 * mem-break.c (mark_breakpoints_out): New.
12617 (free_all_breakpoints): Use it.
12618 * server.c (handle_target_event): If the process is gone, mark
12619 breakpoints out.
12620 * thread-db.c (struct thread_db) <create_bp>: New field.
12621 (thread_db_enable_reporting): Fix prototype. Store a thread event
12622 breakpoint reference in the thread_db struct.
12623 (thread_db_load_search): Clear the thread_db object.
12624 (try_thread_db_load_1): Ditto.
12625 (switch_to_process): New.
12626 (disable_thread_event_reporting): Use it.
12627 (remove_thread_event_breakpoints): New.
12628 (thread_db_detach, thread_db_mourn): Use it.
12629
12630 2010-05-01 Pedro Alves <pedro@codesourcery.com>
12631
12632 * linux-low.c (linux_enable_event_reporting): New.
12633 (linux_wait_for_event_1, handle_extended_wait): Use it.
12634
12635 2010-04-30 Pedro Alves <pedro@codesourcery.com>
12636
12637 * linux-low.c (linux_kill_one_lwp, linux_kill)
12638 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
12639 (send_sigstop): Take an lwp_info as parameter instead. Queue a
12640 SIGSTOP even if the LWP is stopped.
12641 (send_sigstop_callback): New.
12642 (stop_all_lwps): Use send_sigstop_callback instead.
12643 (linux_resume_one_thread): Adjust.
12644 (proceed_one_lwp): Still proceed an LWP that the client has
12645 requested to stop, if we haven't reported it as stopped yet. Make
12646 sure that LWPs the client want stopped, have a pending SIGSTOP.
12647
12648 2010-04-26 Doug Evans <dje@google.com>
12649
12650 * server.c (handle_general_set): Make static.
12651
12652 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
12653 Print received char after testing for error/eof instead of before.
12654 (input_interrupt): Tweak comment.
12655
12656 2010-04-23 Doug Evans <dje@google.com>
12657
12658 * server.c (start_inferior): Print inferior argv if --debug.
12659
12660 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
12661
12662 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
12663 * nto-x86-low.c: Include server.h
12664
12665 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
12666
12667 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
12668 be consistent with other sources of this directory.
12669 (init_registers_amd64): Correct name of source file of this function
12670 in the comment.
12671
12672 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12673
12674 * configure.srv (x86_64-*-mingw*): New configuration for Windows
12675 64-bit executables.
12676
12677 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12678
12679 * win32-i386-low.c: Add 64-bit support.
12680 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
12681 (init_registers_amd64): Declare.
12682 (mappings): Add 64-bit version of array.
12683 (init_windows_x86): New function.
12684 (the_low_target): Change init_arch field to init_windows_x86.
12685
12686 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12687
12688 * win32-low.c: Adapt to support also 64-bit architecture.
12689 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
12690 (get_image_name): Use SIZE_T type for local variable `done'.
12691 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
12692 (toolhelp_get_dll_name): Idem.
12693 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
12694 Use uintptr_t typecast to avoid warning.
12695 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
12696 (handle_exception): Use phex_nz to avoid warning.
12697 (win32_wait): Remove unused local variable `process'.
12698
12699 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12700
12701 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
12702 `amd64-avx.o'.
12703
12704 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
12705
12706 * configure.ac: Use `ws2_32' library for srv_mingw.
12707 * configure: Regenerate.
12708 * gdbreplay.c: Include winsock2.h instead of winsock.h.
12709 * remote-utils.c: Likewise.
12710
12711 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
12712
12713 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
12714 if __x86_64__ is defined.
12715
12716 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12717
12718 * configure: Regenerate.
12719
12720 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12721
12722 * server.c (handle_query): Handle 'qGetTIBAddr' query.
12723 * target.h (target_ops): New get_tib_address field.
12724 * win32-low.h (win32_thread_info): Add thread_local_base field.
12725 * win32-low.c (child_add_thread): Add tlb argument.
12726 Set thread_local_base field to TLB.
12727 (get_child_debug_event): Adapt to child_add_thread change.
12728 (win32_get_tib_address): New function.
12729 (win32_target_ops): Set get_tib_address field to
12730 win32_get_tib_address.
12731 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
12732
12733 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12734
12735 * linux-low.c (linux_mourn): Also remove the process.
12736 * server.c (handle_target_event): Don't remove the process here.
12737 * nto-low.c (nto_mourn): New.
12738 (nto_target_ops): Install it.
12739 * spu-low.c (spu_mourn): New.
12740 (spu_target_ops): Install it.
12741 * win32-low.c (win32_mourn): New.
12742 (win32_target_ops): Install it.
12743
12744 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12745
12746 * server.h (buffer_xml_printf): Remove redundant `;'.
12747
12748 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12749
12750 * regcache.c (set_register_cache): Invalidate regcaches before
12751 changing the register cache layout.
12752 (regcache_invalidate_one): Allow a NULL regcache.
12753 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
12754 regcaches before changing the register cache layout or the target
12755 regsets.
12756
12757 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
12758
12759 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
12760 variable warning on Linux/x86-64.
12761
12762 2010-04-11 Pedro Alves <pedro@codesourcery.com>
12763
12764 GDBserver disconnected tracing support.
12765
12766 * linux-low.c (linux_remove_process): Delete.
12767 (add_lwp): Don't set last_resume_kind here.
12768 (linux_kill): Use `mourn'.
12769 (linux_detach): Use `thread_db_detach', and `mourn'.
12770 (linux_mourn): New.
12771 (linux_attach_lwp_1): Adjust comment.
12772 (linux_attach): last_resume_kind moved the thread_info; adjust.
12773 (status_pending_p_callback): Adjust.
12774 (linux_wait_for_event_1): Adjust.
12775 (count_events_callback, select_singlestep_lwp_callback)
12776 (select_event_lwp_callback, cancel_breakpoints_callback)
12777 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
12778 (proceed_one_lwp): Adjust.
12779 (linux_async): Add debug output.
12780 (linux_thread_stopped): New.
12781 (linux_pause_all): New.
12782 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
12783 linux_pause_all.
12784 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
12785 (thread_db_free): Delete declaration.
12786 (thread_db_detach, thread_db_mourn): Declare.
12787 * thread-db.c (thread_db_init): Use thread_db_mourn.
12788 (thread_db_free): Delete, split in two.
12789 (disable_thread_event_reporting): New.
12790 (thread_db_detach): New.
12791 (thread_db_mourn): New.
12792
12793 * server.h (struct thread_info) <last_resume_kind>: New field.
12794 <attached>: Add comment.
12795 <gdb_detached>: New field.
12796 (handler_func): Change return type to int.
12797 (handle_serial_event, handle_target_event): Ditto.
12798 (gdb_connected): Declare.
12799 (tracing): Delete.
12800 (disconnected_tracing): Declare.
12801 (stop_tracing): Declare.
12802
12803 * server.c (handle_query) <qSupported>: Report support for
12804 disconnected tracing.
12805 (queue_stop_reply_callback): Account for running threads.
12806 (gdb_wants_thread_stopped): New.
12807 (gdb_wants_all_threads_stopped): New.
12808 (gdb_reattached_process): New.
12809 (handle_status): Clear the `gdb_detached' flag of all processes.
12810 In all-stop, stop all threads.
12811 (main): Be sure to leave tfind mode. Handle disconnected tracing.
12812 (process_serial_event): If the remote connection breaks, or if an
12813 exit was forced with "monitor exit", force an event loop exit.
12814 Handle disconnected tracing on detach.
12815 (handle_serial_event): Adjust.
12816 (handle_target_event): If GDB isn't connected, forward events back
12817 to the inferior, unless the last process exited, in which case,
12818 exit gdbserver. Adjust interface.
12819
12820 * remote-utils.c (remote_open): Don't block in accept. Instead
12821 register an event loop source on the listen socket file
12822 descriptor. Refactor bits into ...
12823 (listen_desc): ... this new global.
12824 (gdb_connected): ... this new function.
12825 (enable_async_notification): ... this new function.
12826 (handle_accept_event): ... this new function.
12827 (remote_close): Clear remote_desc.
12828
12829 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
12830
12831 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
12832 New fields.
12833 (mourn_inferior): Define.
12834 (target_process_qsupported): Avoid the dangling else problem.
12835 (thread_stopped): Define.
12836 (pause_all): Define.
12837 (target_waitstatus_to_string): Declare.
12838 * target.c (target_waitstatus_to_string): New.
12839
12840 * tracepoint.c (tracing): Make extern.
12841 (disconnected_tracing): New.
12842 (stop_tracing): Make extern. Handle tracing stops due to GDB
12843 disconnecting.
12844 (cmd_qtdisconnected): New.
12845 (cmd_qtstatus): Report disconnected tracing status in trace reply.
12846 (handle_tracepoint_general_set): Handle QTDisconnected.
12847
12848 * event-loop.c (event_handler_func): Change return type to int.
12849 (process_event): Bail out if the event handler wants the event
12850 loop to stop.
12851 (handle_file_event): Ditto.
12852 (start_event_loop): Bail out if the event handler wants the event
12853 loop to stop.
12854
12855 * nto-low.c (nto_target_ops): Adjust.
12856 * spu-low.c (spu_wait): Don't remove the process here.
12857 (spu_target_ops): Adjust.
12858 * win32-low.c (win32_wait): Don't remove the process here.
12859 (win32_target_ops): Adjust.
12860
12861 2010-04-11 Pedro Alves <pedro@codesourcery.com>
12862
12863 * regcache.c (realloc_register_cache): Invalidate inferior's
12864 regcache before recreating it.
12865
12866 2010-04-09 Pedro Alves <pedro@codesourcery.com>
12867
12868 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
12869
12870 2010-04-09 Stan Shebs <stan@codesourcery.com>
12871 Pedro Alves <pedro@codesourcery.com>
12872
12873 * server.h (LONGEST): New.
12874 (struct thread_info) <while_stepping>: New field.
12875 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
12876 Declare.
12877 (initialize_tracepoint, handle_tracepoint_general_set)
12878 (handle_tracepoint_query, tracepoint_finished_step)
12879 (tracepoint_was_hit, release_while_stepping_state_list):
12880 (current_traceframe): Declare.
12881 * server.c (handle_general_set): Handle tracepoint packets.
12882 (read_memory): New.
12883 (write_memory): New.
12884 (handle_search_memory_1): Use read_memory.
12885 (handle_query): Report support for conditional tracepoints, trace
12886 state variables, and tracepoint sources. Handle tracepoint
12887 queries.
12888 (main): Initialize the tracepoints module.
12889 (process_serial_event): Handle traceframe reads/writes.
12890
12891 * linux-low.c (handle_tracepoints): New.
12892 (linux_wait_1): Call it.
12893 (linux_resume_one_lwp): Handle while-stepping.
12894 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
12895 (linux_target_ops): Install them.
12896 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
12897 New field.
12898 * linux-x86-low.c (x86_supports_tracepoints): New.
12899 (the_low_target). Install it.
12900
12901 * mem-break.h (delete_breakpoint): Declare.
12902 * mem-break.c (delete_breakpoint): Make external.
12903
12904 * target.h (struct target_ops): Add `supports_tracepoints',
12905 `read_pc', and `write_pc' fields.
12906 (target_supports_tracepoints): Define.
12907 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
12908 (phex_nz): New.
12909
12910 * regcache.h (struct regcache) <registers_owned>: New field.
12911 (init_register_cache, regcache_cpy): Declare.
12912 (regcache_read_pc, regcache_write_pc): Declare.
12913 (register_cache_size): Declare.
12914 (supply_regblock): Declare.
12915 * regcache.c (init_register_cache): New.
12916 (new_register_cache): Use it.
12917 (regcache_cpy): New.
12918 (register_cache_size): New.
12919 (supply_regblock): New.
12920 (regcache_read_pc, regcache_write_pc): New.
12921
12922 * tracepoint.c: New.
12923
12924 * Makefile.in (OBS): Add tracepoint.o.
12925 (tracepoint.o): New rule.
12926
12927 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
12928
12929 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
12930 (i386-mmx.o): New.
12931 (i386-mmx.c): Likewise.
12932 (i386-mmx-linux.o): Likewise.
12933 (i386-mmx-linux.c): Likewise.
12934
12935 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
12936 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
12937 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
12938 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
12939
12940 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
12941 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
12942 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
12943
12944 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
12945
12946 * Makefile.in (clean): Updated.
12947 (i386-avx.o): New.
12948 (i386-avx.c): Likewise.
12949 (i386-avx-linux.o): Likewise.
12950 (i386-avx-linux.c): Likewise.
12951 (amd64-avx.o): Likewise.
12952 (amd64-avx.c): Likewise.
12953 (amd64-avx-linux.o): Likewise.
12954 (amd64-avx-linux.c): Likewise.
12955
12956 * configure.srv (srv_i386_regobj): Add i386-avx.o.
12957 (srv_i386_linux_regobj): Add i386-avx-linux.o.
12958 (srv_amd64_regobj): Add amd64-avx.o.
12959 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
12960 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
12961 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
12962 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
12963 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
12964 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
12965 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
12966
12967 * i387-fp.c: Include "i386-xstate.h".
12968 (i387_xsave): New.
12969 (i387_cache_to_xsave): Likewise.
12970 (i387_xsave_to_cache): Likewise.
12971 (x86_xcr0): Likewise.
12972
12973 * i387-fp.h (i387_cache_to_xsave): Likewise.
12974 (i387_xsave_to_cache): Likewise.
12975 (x86_xcr0): Likewise.
12976
12977 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
12978 * linux-crisv32-low.c (target_regsets): Likewise.
12979 * linux-m68k-low.c (target_regsets): Likewise.
12980 * linux-mips-low.c (target_regsets): Likewise.
12981 * linux-ppc-low.c (target_regsets): Likewise.
12982 * linux-s390-low.c (target_regsets): Likewise.
12983 * linux-sh-low.c (target_regsets): Likewise.
12984 * linux-sparc-low.c (target_regsets): Likewise.
12985 * linux-xtensa-low.c (target_regsets): Likewise.
12986
12987 * linux-low.c: Include <sys/uio.h>.
12988 (regsets_fetch_inferior_registers): Support nt_type.
12989 (regsets_store_inferior_registers): Likewise.
12990 (linux_process_qsupported): New.
12991 (linux_target_ops): Add linux_process_qsupported.
12992
12993 * linux-low.h (regset_info): Add nt_type.
12994 (linux_target_ops): Add process_qsupported.
12995
12996 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
12997 and <sys/uio.h>.
12998 (init_registers_i386_avx_linux): New.
12999 (init_registers_amd64_avx_linux): Likewise.
13000 (xmltarget_i386_linux_no_xml): Likewise.
13001 (xmltarget_amd64_linux_no_xml): Likewise.
13002 (PTRACE_GETREGSET): Likewise.
13003 (PTRACE_SETREGSET): Likewise.
13004 (x86_fill_xstateregset): Likewise.
13005 (x86_store_xstateregset): Likewise.
13006 (use_xml): Likewise.
13007 (x86_linux_update_xmltarget): Likewise.
13008 (x86_linux_process_qsupported): Likewise.
13009 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13010 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13011 init_registers_i386_linux here. Call
13012 x86_linux_update_xmltarget.
13013 (the_low_target): Add x86_linux_process_qsupported.
13014
13015 * server.c (handle_query): Call target_process_qsupported.
13016
13017 * target.h (target_ops): Add process_qsupported.
13018 (target_process_qsupported): New.
13019
13020 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13021
13022 * inferiors.c (add_thread): Set last_status kind to
13023 TARGET_WAITKIND_IGNORE.
13024 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13025 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13026 (linux_wait_1): Move `thread' local definition to block that uses
13027 it. Don't NULL initialize `event_child'.
13028 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13029 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13030 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13031
13032 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13033
13034 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13035 an extended waitstatus, or by a watchpoint.
13036 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13037 thread was stepping or has been stopped by a watchpoint.
13038
13039 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13040
13041 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13042 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13043 of another, then delete the previous, and validate all
13044 breakpoints.
13045 (validate_inserted_breakpoint): New.
13046 (delete_disabled_breakpoints): New.
13047 (validate_breakpoints): New.
13048 (check_mem_read): Validate breakpoints before trusting their
13049 shadow. Delete disabled breakpoints.
13050 (check_mem_write): Validate breakpoints before trusting they
13051 should be inserted. Delete disabled breakpoints.
13052 * mem-break.h (validate_breakpoints):
13053 * server.c (handle_query): Validate breakpoints when we see a
13054 qSymbol query.
13055
13056 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13057
13058 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13059 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13060 if we could tell there's a GDB breakpoint at stop_pc.
13061 (need_step_over_p): Don't do a step over if we find a GDB
13062 breakpoint at the resume PC.
13063
13064 * mem-break.c (struct raw_breakpoint): New.
13065 (enum bkpt_type): New type `gdb_breakpoint'.
13066 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13067 fields. New field `raw'.
13068 (find_raw_breakpoint_at): New.
13069 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13070 breakpoint instead.
13071 (set_breakpoint_at): Adjust.
13072 (delete_raw_breakpoint): New.
13073 (release_breakpoint): New.
13074 (delete_breakpoint): Rename to...
13075 (delete_breakpoint_1): ... this. Add proc parameter. Use
13076 release_breakpoint. Return ENOENT.
13077 (delete_breakpoint): Reimplement.
13078 (find_breakpoint_at): Delete.
13079 (find_gdb_breakpoint_at): New.
13080 (delete_breakpoint_at): Delete.
13081 (set_gdb_breakpoint_at): New.
13082 (delete_gdb_breakpoint_at): New.
13083 (gdb_breakpoint_here): New.
13084 (set_reinsert_breakpoint): Use release_breakpoint.
13085 (uninsert_breakpoint): Rename to ...
13086 (uninsert_raw_breakpoint): ... this.
13087 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13088 (reinsert_raw_breakpoint): Change parameter type to
13089 raw_breakpoint.
13090 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13091 instead.
13092 (check_breakpoints): Adjust. Use release_breakpoint.
13093 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13094 (breakpoint_inserted_here): Ditto.
13095 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13096 Don't trust the breakpoint's shadow if it is not inserted.
13097 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13098 (delete_all_breakpoints): Adjust.
13099 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13100 use delete_breakpoint_1.
13101
13102 * mem-break.h (breakpoints_supported): Delete declaration.
13103 (set_gdb_breakpoint_at): Declare.
13104 (gdb_breakpoint_here): Declare.
13105 (delete_breakpoint_at): Delete.
13106 (delete_gdb_breakpoint_at): Declare.
13107
13108 * server.h (struct raw_breakpoint): Forward declare.
13109 (struct process_info): New field `raw_breakpoints'.
13110
13111 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13112 breakpoints.
13113
13114 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13115
13116 * linux-low.c (status_pending_p_callback): Fix comment.
13117 (linux_wait_for_event_1): Move most of the internal breakpoint
13118 handling from here...
13119 (linux_wait_1): ... to here.
13120 (count_events_callback): New.
13121 (select_singlestep_lwp_callback): New.
13122 (select_event_lwp_callback): New.
13123 (cancel_breakpoints_callback): New.
13124 (select_event_lwp): New.
13125 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13126 priority to all LWPs that have had events that should be reported
13127 to the client. Cancel breakpoints when about to reporting the
13128 event to the client, not while stopping lwps. No longer cancel
13129 finished single-steps here.
13130 (cancel_finished_single_step): Delete.
13131 (cancel_finished_single_steps): Delete.
13132
13133 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13134
13135 * mem-break.c (enum bkpt_type): New.
13136 (struct breakpoint): New field `type'.
13137 (set_breakpoint_at): Change return type to struct breakpoint
13138 pointer. Set type to `other_breakpoint' by default.
13139 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13140 in the breakpoint list.
13141 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13142 (reinsert_breakpoint): Rename to ...
13143 (reinsert_raw_breakpoint): ... this.
13144 (reinsert_breakpoints_at): Adjust.
13145 * mem-break.h (struct breakpoint): Declare.
13146 (set_breakpoint_at): Change return type to struct breakpoint
13147 pointer.
13148
13149 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13150
13151 * server.c (handle_query): Assign, not compare.
13152
13153 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13154
13155 Teach linux gdbserver to step-over-breakpoints.
13156
13157 * linux-low.c (can_hardware_single_step): New.
13158 (supports_breakpoints): New.
13159 (handle_extended_wait): If stopping threads, read the stop pc of
13160 the new cloned LWP.
13161 (get_pc): New.
13162 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13163 low target doesn't support retrieving the PC.
13164 (add_lwp): Set last_resume_kind to resume_continue.
13165 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13166 (linux_attach): Don't clear stop_expected. Set the lwp's
13167 last_resume_kind to resume_stop.
13168 (linux_detach_one_lwp): Don't check for removed breakpoints.
13169 (check_removed_breakpoint): Delete.
13170 (status_pending_p): Rename to ...
13171 (status_pending_p_callback): ... this. Don't check for removed
13172 breakpoints. Don't consider threads that are stopped from GDB's
13173 perspective.
13174 (linux_wait_for_lwp): Always read the stop_pc here.
13175 (cancel_breakpoint): New.
13176 (step_over_bkpt): New global.
13177 (linux_wait_for_event_1): Implement stepping over breakpoints.
13178 (gdb_wants_lwp_stopped): New.
13179 (gdb_wants_all_stopped): New.
13180 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13181 single-step traps here. Store the thread's last reported target
13182 wait status.
13183 (send_sigstop): Don't clear stop_expected. Always set it,
13184 instead.
13185 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13186 (cancel_finished_single_step): New.
13187 (cancel_finished_single_steps): New.
13188 (wait_for_sigstop): Don't cancel finished single-step traps here.
13189 (linux_resume_one_lwp): Don't check for removed breakpoints.
13190 Don't set `step' on non-hardware step archs.
13191 (linux_set_resume_request): Ignore resume_stop requests if already
13192 stopping or stopped. Set the lwp's last_resume_kind.
13193 (resume_status_pending_p): Don't check for removed breakpoints.
13194 (need_step_over_p): New.
13195 (start_step_over): New.
13196 (finish_step_over): New.
13197 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13198 requests. Clear the thread's last reported target waitstatus.
13199 Don't use the `suspended' flag. Don't consider pending breakpoints.
13200 (linux_resume): Start a step-over if necessary.
13201 (proceed_one_lwp): New.
13202 (proceed_all_lwps): New.
13203 (unstop_all_lwps): New.
13204 * linux-low.h (struct lwp_info): Rewrite comment for the
13205 `suspended' flag. Add the `stop_pc' field. Delete the
13206 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13207 Add `'last_resume_kind' and `need_step_over' fields.
13208 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13209 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13210 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13211 (set_raw_breakpoint_at): New.
13212 (set_breakpoint_at): Rewrite to use it.
13213 (reinsert_breakpoint_handler): Delete.
13214 (set_reinsert_breakpoint): New.
13215 (reinsert_breakpoint_by_bp): Delete.
13216 (delete_reinsert_breakpoints): New.
13217 (uninsert_breakpoint): Rewrite.
13218 (uninsert_breakpoints_at): New.
13219 (reinsert_breakpoint): Rewrite.
13220 (reinsert_breakpoints_at): New.
13221 (check_breakpoints): Rewrite.
13222 (breakpoint_here): New.
13223 (breakpoint_inserted_here): New.
13224 (check_mem_read): Adjust.
13225 * mem-break.h (breakpoints_supported, breakpoint_here)
13226 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13227 (reinsert_breakpoint_by_bp): Delete declaration.
13228 (delete_reinsert_breakpoints): Declare.
13229 (reinsert_breakpoint): Delete declaration.
13230 (reinsert_breakpoints_at): Declare.
13231 (uninsert_breakpoint): Delete declaration.
13232 (uninsert_breakpoints_at): Declare.
13233 (check_breakpoints): Adjust prototype.
13234 * server.h: Adjust include order.
13235 (struct thread_info): Declare here. Add a `last_status' field.
13236
13237 2010-03-23 Michael Snyder <msnyder@vmware.com>
13238
13239 * server.c (crc32): New function.
13240 (handle_query): Add handling for 'qCRC:' request.
13241
13242 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13243
13244 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13245 lwp had been stopped by a watchpoint.
13246
13247 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13248
13249 * server.h (internal_error): Declare.
13250 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13251 * utils.c (internal_error): New function.
13252
13253 2010-03-15 Andreas Schwab <schwab@redhat.com>
13254
13255 * configure.srv: Fix typo setting srv_regobj.
13256
13257 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13258
13259 * linux-low.c (fetch_register): Avoid passing a non string literal
13260 format to `error'.
13261 (usr_store_inferior_registers): Ditto.
13262
13263 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13264
13265 * linux-low.c (linux_write_memory): Bail out early if peeking
13266 memory failed.
13267
13268 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13269
13270 * linux-low.h (struct lwp_info): New fields
13271 `stopped_by_watchpoint' and `stopped_data_address'.
13272 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13273 here, and cache them in the lwp object.
13274 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13275 directly.
13276 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13277 field.
13278 (linux_stopped_by_watchpoint): Rewrite.
13279 (linux_stopped_data_address): Rewrite.
13280
13281 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13282
13283 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13284 switching the current inferior, not before.
13285
13286 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13287
13288 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13289 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13290 i386-linux.c and amd64-linux.c.
13291 (reg-i386.o): Removed.
13292 (reg-i386.c): Likewise.
13293 (reg-i386-linux.o): Likewise.
13294 (reg-i386-linux.c): Likewise.
13295 (reg-x86-64.o): Likewise.
13296 (reg-x86-64.c): Likewise.
13297 (reg-x86-64-linux.o): Likewise.
13298 (reg-x86-64-linux.c): Likewise.
13299 (i386.o): New.
13300 (i386.c): Likewise.
13301 (i386-linux.o): Likewise.
13302 (i386-linux.c): Likewise.
13303 (amd64.o): Likewise.
13304 (amd64.c): Likewise.
13305 (amd64-linux.o): Likewise.
13306 (amd64-linux.c): Likewise.
13307
13308 * configure.srv (srv_i386_regobj): New.
13309 (srv_i386_linux_regobj): Likewise.
13310 (srv_amd64_regobj): Likewise.
13311 (srv_amd64_linux_regobj): Likewise.
13312 (srv_i386_32bit_xmlfiles): Likewise.
13313 (srv_i386_64bit_xmlfiles): Likewise.
13314 (srv_i386_xmlfiles): Likewise.
13315 (srv_amd64_xmlfiles): Likewise.
13316 (srv_i386_linux_xmlfiles): Likewise.
13317 (srv_amd64_linux_xmlfiles): Likewise.
13318 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13319 srv_xmlfiles to $srv_i386_xmlfiles.
13320 (i[34567]86-*-mingw32ce*): Likewise.
13321 (i[34567]86-*-mingw*): Likewise.
13322 (i[34567]86-*-nto*): Likewise.
13323 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13324 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13325 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13326 (x86_64-*-linux*): Likewise.
13327
13328 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13329 (init_registers_amd64_linux): New.
13330 (x86_arch_setup): Replace init_registers_x86_64_linux with
13331 init_registers_amd64_linux.
13332
13333 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13334
13335 * configure.ac: Check for libdl. If it is not available link against
13336 static libthread_db.
13337 * configure: Regenerate.
13338
13339 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13340
13341 PR9605
13342
13343 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13344 handing a read watchpoint.
13345 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13346
13347 2010-02-12 Doug Evans <dje@google.com>
13348
13349 * linux-low.c (linux_supports_tracefork_flag): Document.
13350 (linux_look_up_symbols): Add comment.
13351
13352 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13353
13354 * regcache.c (supply_register): Clear regcache if buf is NULL.
13355
13356 2010-02-02 Nicolas Roche <roche@sourceware.org>
13357 Joel Brobecker <brobecker@adacore.com>
13358
13359 * inferiors.c (find_inferior): Add function documentation.
13360 (unloaded_dll): Handle the case where the unloaded dll has not
13361 been previously registered in the dll list.
13362
13363 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13364
13365 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13366 (thumb2_breakpoint): New.
13367 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13368
13369 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13370
13371 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13372 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13373 breakpoints.
13374
13375 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13376
13377 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13378
13379 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13380
13381 * linux-s390-low.c (s390_collect_ptrace_register)
13382 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13383
13384 2010-01-21 Doug Evans <dje@google.com>
13385
13386 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13387 (PTRACE_ARG4_TYPE): New macro.
13388 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13389 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13390 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13391 (usr_store_inferior_registers): Ditto.
13392 (linux_read_memory, linux_write_memory): Ditto.
13393 (linux_test_for_tracefork): Ditto.
13394
13395 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13396 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13397
13398 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13399
13400 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13401 target.
13402
13403 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13404
13405 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13406 prototype to take a regcache. Adjust.
13407
13408 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13409
13410 * regcache.h (struct thread_info): Forward declare.
13411 (struct regcache): New.
13412 (new_register_cache): Adjust prototype.
13413 (get_thread_regcache): Declare.
13414 (free_register_cache): Adjust prototype.
13415 (registers_to_string, registers_from_string): Ditto.
13416 (supply_register, supply_register_by_name, collect_register)
13417 (collect_register_as_string, collect_register_by_name): Ditto.
13418 * regcache.c (struct inferior_regcache_data): Delete.
13419 (get_regcache): Rename to ...
13420 (get_thread_regcache): ... this. Adjust. Switch inferior before
13421 fetching registers.
13422 (regcache_invalidate_one): Adjust.
13423 (regcache_invalidate): Fix prototype.
13424 (new_register_cache): Return the new register cache.
13425 (free_register_cache): Change prototype.
13426 (realloc_register_cache): Adjust.
13427 (registers_to_string): Change prototype to take a regcache. Adjust.
13428 (registers_from_string): Ditto.
13429 (register_data): Ditto.
13430 (supply_register): Ditto.
13431 (supply_register_by_name): Ditto.
13432 (collect_register): Ditto.
13433 (collect_register_as_string): Ditto.
13434 (collect_register_by_name): Ditto.
13435 * server.c (process_serial_event): Adjust.
13436 * linux-low.h (regset_fill_func, regset_store_func): Change
13437 prototype.
13438 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13439 Change prototype.
13440 * linux-low.c (get_stop_pc): Adjust.
13441 (check_removed_breakpoint): Adjust.
13442 (linux_wait_for_event): Adjust.
13443 (linux_resume_one_lwp): Adjust.
13444 (fetch_register): Add regcache parameter. Adjust.
13445 (usr_store_inferior_registers): Ditto.
13446 (regsets_fetch_inferior_registers): Ditto.
13447 (regsets_store_inferior_registers): Ditto.
13448 (linux_fetch_registers, linux_store_registers): Ditto.
13449 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13450 regcache. Adjust.
13451 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13452 Ditto.
13453 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13454 prototype to take a regcache.
13455 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13456 * remote-utils.c (convert_ascii_to_int, outreg)
13457 (prepare_resume_reply): Change prototype to take a regcache.
13458 Adjust.
13459 * target.h (struct target_ops) <fetch_registers, store_registers>:
13460 Change prototype to take a regcache.
13461 (fetch_inferior_registers, store_inferior_registers): Change
13462 prototype to take a regcache. Adjust.
13463 * proc-service.c (ps_lgetregs): Adjust.
13464 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13465 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13466 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13467 take a regcache. Adjust.
13468 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
13469 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
13470 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
13471 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
13472 * linux-cris-low.c (cris_get_pc, cris_set_pc)
13473 (cris_cannot_fetch_register):
13474 (cris_breakpoint_at): Change prototype to take a regcache.
13475 Adjust.
13476 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
13477 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
13478 to take a regcache. Adjust.
13479 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
13480 Adjust.
13481 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
13482 take a regcache. Adjust.
13483 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
13484 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
13485 (m68k_set_pc): Change prototype to take a regcache. Adjust.
13486 * linux-mips-low.c (mips_get_pc):
13487 (mips_set_pc): Change prototype to take a regcache. Adjust.
13488 (mips_reinsert_addr): Adjust.
13489 (mips_collect_register): Change prototype to take a regcache.
13490 Adjust.
13491 (mips_supply_register):
13492 (mips_collect_register_32bit, mips_supply_register_32bit)
13493 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
13494 (mips_store_fpregset): Ditto.
13495 * linux-ppc-low.c (ppc_supply_ptrace_register)
13496 (ppc_supply_ptrace_register): Ditto.
13497 (parse_spufs_run): Adjust.
13498 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
13499 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
13500 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
13501 take a regcache. Adjust.
13502 * linux-s390-low.c (s390_collect_ptrace_register)
13503 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
13504 (s390_set_pc): Change prototype to take a regcache. Adjust.
13505 (s390_arch_setup): Adjust.
13506 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
13507 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
13508 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13509 (sparc_fill_gregset, sparc_store_gregset_from_stack)
13510 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
13511 regcache. Adjust.
13512 (sparc_breakpoint_at): Adjust.
13513 * linux-xtensa-low.c (xtensa_fill_gregset):
13514 (xtensa_store_gregset):
13515 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
13516 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
13517 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
13518 prototype to take a regcache. Adjust.
13519 * win32-arm-low.c (arm_fetch_inferior_register)
13520 (arm_store_inferior_register): Change prototype to take a
13521 regcache. Adjust.
13522 * win32-i386-low.c (i386_fetch_inferior_register)
13523 (i386_store_inferior_register): Change prototype to take a
13524 regcache. Adjust.
13525 * win32-low.c (child_fetch_inferior_registers)
13526 (child_store_inferior_registers): Change prototype to take a
13527 regcache. Adjust.
13528 (win32_wait): Adjust.
13529 (win32_fetch_inferior_registers): Change prototype to take a
13530 regcache. Adjust.
13531 (win32_store_inferior_registers): Adjust.
13532 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
13533 store_inferior_register>: Change prototype to take a regcache.
13534
13535 2010-01-20 Doug Evans <dje@google.com>
13536
13537 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
13538 #ifdef.
13539 (linux_wait_for_event1, linux_init_signals): Ditto.
13540 (W_STOPCODE): Provide definition if missing.
13541
13542 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
13543
13544 * linux-low.c (linux_core_of_thread): New.
13545 (compare_ints, show_process, list_threads): New.
13546 (linux_qxfer_osdata): Report threads and cores.
13547 (linux_target_op): Register linux_core_of_thread.
13548 * remote-utils.c (prepare_resume_reply): Report the core.
13549 (buffer_xml_printf): Support %d specifier.
13550 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
13551 New.
13552 (handle_query): Handle qXfer:threads. Announce availability
13553 thereof.
13554 * target.h (struct target_ops): New field core_of_thread.
13555
13556 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
13557
13558 * Makefile.in (clean): Remove new generated files.
13559 (reg-s390.o, reg-s390.c): Remove rules.
13560 (reg-s390x.o, reg-s390x.c): Likewise.
13561 (s390-linux32.o, s390-linux32.c): Add rules.
13562 (s390-linux64.o, s390-linux64.c): Likewise.
13563 (s390x-linux64.o, s390x-linux64.c): Likewise.
13564 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
13565 * linux-s390-low.c: Include <elf.h>.
13566 (HWCAP_S390_HIGH_GPRS): Define if undefined.
13567 (init_registers_s390): Remove prototype.
13568 (init_registers_s390x): Likewise.
13569 (init_registers_s390_linux32): Add prototype.
13570 (init_registers_s390_linux64): Likewise.
13571 (init_registers_s390x_linux64): Likewise.
13572 (s390_num_regs_3264): New define.
13573 (s390_regmap_3264): New global variable.
13574 (s390_cannot_fetch_register): Remove obsolete check.
13575 (s390_cannot_store_register): Likewise.
13576 (s390_collect_ptrace_register): Handle upper/lower register halves.
13577 (s390_supply_ptrace_register): Likewise.
13578 (s390_fill_gregset): Update to register number changes.
13579 (s390_get_hwcap): New routine.
13580 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
13581 Install appropriate regmap and register set.
13582
13583 2010-01-01 Joel Brobecker <brobecker@adacore.com>
13584
13585 * server.c (gdbserver_version): Update copyright year to 2010.
13586 * gdbreplay.c (gdbreplay_version): Likewise.
13587
13588 2009-12-28 Doug Evans <dje@google.com>
13589
13590 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
13591 elf/external.h. Include <elf.h> instead but only if necessary.
13592
13593 2009-12-28 Pedro Alves <pedro@codesourcery.com>
13594
13595 * linux-low.c (linux_remove_process): Remove `detaching'
13596 parameter. Don't release/detach from thread_db here.
13597 (linux_kill): Release/detach from thread_db here, ...
13598 (linux_detach): ... and here, before actually detaching.
13599 (linux_wait_1): ... and here, when a process exits.
13600 * thread-db.c (any_thread_of): New.
13601 (thread_db_free): Switch the current inferior to a thread of the
13602 passed in process.
13603
13604 2009-12-21 Doug Evans <dje@google.com>
13605
13606 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
13607
13608 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
13609 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
13610 warning ifndef __NR_tkill. Move setting of errno there too.
13611 Delete unnecessary resetting of errno after syscall.
13612 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
13613
13614 * configure.ac: Check for dladdr.
13615 * config.in: Regenerate.
13616 * configure: Regenerate.
13617 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
13618 (try_thread_db_load): Update.
13619
13620 * linux-low.c (my_waitpid): Delete unnecessary prototype.
13621
13622 2009-12-18 Doug Evans <dje@google.com>
13623
13624 * event-loop.c: Include unistd.h if it exists.
13625
13626 * linux-low.c (my_waitpid): Move definition away from being in
13627 between linux_tracefork_child/linux_test_for_tracefork.
13628
13629 * gdb_proc_service.h (psaddr_t): Fix type.
13630 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
13631 signature to match glibc.
13632
13633 2009-12-16 Doug Evans <dje@google.com>
13634
13635 * linux-low.c (linux_read_memory): Fix argument to read.
13636
13637 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13638
13639 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
13640 events, don't leave current_inferior pointing at null.
13641
13642 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13643
13644 * win32-low.c (LOG): Delete.
13645 (OUTMSG): Output to stderr.
13646 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
13647 on compile time LOG macro.
13648 (win32_wait): Fix debug output.
13649
13650 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13651
13652 * win32-low.c (win32_add_one_solib): If the dll name is
13653 "ntdll.dll", prepend the system directory to the dll path.
13654
13655 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
13656
13657 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
13658
13659 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
13660 Vladimir Prus <vladimir@codesourcery.com>
13661
13662 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
13663 * configure.ac: Check for __mcoldfire__ and set
13664 gdb_cv_m68k_is_coldfire.
13665 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
13666 reg-cf.o and reg-m68k.o.
13667 * configure: Regenerated.
13668
13669 2009-11-16 Pedro Alves <pedro@codesourcery.com>
13670
13671 * linux-low.c (linux_remove_process): Add `detaching' parameter.
13672 Pass it to thread_db_free.
13673 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
13674 proper `detaching' argument to linux_remove_process.
13675 * linux-low.h (thread_db_free): Add `detaching' parameter.
13676 * thread-db.c (thread_db_init): Pass false as `detaching' argument
13677 to thread_db_free.
13678 (thread_db_free): Add `detaching' parameter. Only
13679 call td_ta_clear_event if detaching from process.
13680
13681 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
13682
13683 * thread-db.c (thread_db_free): Fix typo.
13684
13685 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
13686
13687 PR gdb/10838
13688 * thread-db.c (thread_db_free): Call td_ta_clear_event.
13689
13690 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
13691
13692 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
13693 with an i686 compiler.
13694 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
13695 needed.
13696 * configure: Rebuilt.
13697
13698 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
13699
13700 PR gdb/10783
13701
13702 * server.c (handle_search_memory_1): Correct read_addr initialization
13703 in loop for searching subsequent chunks.
13704
13705 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
13706
13707 * configure.ac: New --with-libthread-db option.
13708 * thread-db.c: Allow direct dependence on libthread_db.
13709 (thread_db_free): Adjust.
13710 * config.in: Regenerate.
13711 * configure: Likewise.
13712
13713 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
13714
13715 PR gdb/10757
13716 * thread-db.c (attach_thread): New function.
13717 (maybe_attach_thread): Return success/failure.
13718 (find_new_threads_callback): Adjust.
13719 (thread_db_find_new_threads): Loop until no new threads.
13720
13721 2009-10-13 Pedro Alves <pedro@codesourcery.com>
13722
13723 * proc-service.c (ps_lgetregs): Formatting.
13724
13725 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
13726
13727 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
13728 * configure.ac: Adjust.
13729 * linux-low.h (struct process_info_private): Move members to struct
13730 thread_db.
13731 (thread_db_free, thread_db_handle_monitor_command): New prototype.
13732 * linux-low.c (linux_remove_process): Adjust.
13733 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
13734 * server.c (handle_query): Move code ...
13735 (handle_monitor_command): ... here. New function.
13736 * target.h (struct target_ops): New member.
13737 * thread-db.c (struct thread_db): New.
13738 (libthread_db_search_path): New variable.
13739 (thread_db_create_event, thread_db_enable_reporting)
13740 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
13741 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
13742 (try_thread_db_load_1, dladdr_to_soname): New functions.
13743 (try_thread_db_load, thread_db_load_search): New functions.
13744 (thread_db_init): Search for libthread_db.
13745 (thread_db_free): New function.
13746 (thread_db_handle_monitor_command): Likewise.
13747 * config.in: Regenerate.
13748 * configure: Regenerate.
13749
13750 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
13751
13752 * spu-low.c (spu_kill): Wait for inferior to terminate.
13753 Call clear_inferiors.
13754 (spu_detach): Call clear_inferiors.
13755
13756 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13757
13758 * aclocal.m4: Regenerate.
13759 * config.in: Likewise.
13760 * configure: Likewise.
13761
13762 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13763
13764 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
13765 (parse_spufs_run): New function.
13766 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
13767 (ppc_breakpoint_at): Handle SPU breakpoints.
13768
13769 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13770
13771 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
13772 (SPUFS_MAGIC): Define.
13773 (spu_enumerate_spu_ids): New function.
13774 (linux_qxfer_spu): New function.
13775 (linux_target_ops): Install linux_qxfer_spu.
13776
13777 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13778
13779 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
13780 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
13781 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
13782 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
13783 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
13784 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
13785 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
13786 (init_registers_powerpc_cell32l): Add prototype.
13787 (init_registers_powerpc_cell64l): Likewise.
13788 (ppc_arch_setup): Detect Cell/B.E. architecture.
13789
13790 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13791
13792 * Makefile.in (datarootdir): New variable.
13793
13794 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13795
13796 * linux-low.c (linux_write_memory): Update debugging output.
13797 * Makefile.in (clean): Add new descriptions.
13798 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
13799 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
13800 * configure.srv: Add new files for arm*-*-linux*.
13801 * linux-arm-low.c: Add new declarations.
13802 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
13803 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
13804 (HWCAP_VFPv3D16): New.
13805 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
13806 instead of __IWMMXT__.
13807 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
13808 (arm_arch_setup): New.
13809 (target_regsets): Remove #ifdef. Add VFP regset.
13810 (the_low_target): Use arm_arch_setup.
13811
13812 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13813
13814 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
13815 the main thread again.
13816
13817 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
13818
13819 Adding Neutrino gdbserver.
13820 * configure: Regenerated.
13821 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
13822 * configure.srv (i[34567]86-*-nto*): New target.
13823 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
13824 * remote-utils.c [__QNX__]: Include sys/iomgr.h
13825 (nto_comctrl) [__QNX__]: New function.
13826 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
13827
13828 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
13829
13830 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
13831 srv_tgtobj.
13832
13833 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
13834 Pedro Alves <pedro@codesourcery.com>
13835
13836 * win32-i386-low.c (i386_get_thread_context): Handle systems that
13837 don't support CONTEXT_EXTENDED_REGISTERS.
13838 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
13839 (the_low_target): Install them.
13840 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
13841 failing with ERROR_PIPE_NOT_CONNECTED.
13842
13843 2009-06-30 Doug Evans <dje@google.com>
13844 Pierre Muller <muller@ics.u-strasbg.fr>
13845
13846 Add h/w watchpoint support to x86-linux, win32-i386.
13847 * Makefile.in (SFILES): Add i386-low.c
13848 (i386_low_h): Define.
13849 (i386-low.o): Add dependencies.
13850 (linux-x86-low.o): Add i386-low.h dependency.
13851 (win32-i386-low.o): Ditto.
13852 * i386-low.c: New file.
13853 * i386-low.h: New file.
13854 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
13855 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
13856 * linux-low.c (linux_add_process): Initialize arch_private.
13857 (linux_remove_process): Free arch_private.
13858 (add_lwp): Initialize arch_private.
13859 (delete_lwp): Free arch_private.
13860 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
13861 provided.
13862 * linux-low.h (process_info_private): New member arch_private.
13863 (lwp_info): New member arch_private.
13864 (linux_target_ops): New members new_process, new_thread,
13865 prepare_to_resume.
13866 (ptid_of): New macro.
13867 * linux-x86-low.c: Include stddef.h, i386-low.h.
13868 (arch_process_info): New struct.
13869 (arch_lwp_info): New struct.
13870 (x86_linux_dr_get, x86_linux_dr_set): New functions.
13871 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
13872 (i386_dr_low_get_status): New function.
13873 (x86_insert_point, x86_remove_point): New functions.
13874 (x86_stopped_by_watchpoint): New function.
13875 (x86_stopped_data_address): New function.
13876 (x86_linux_new_process, x86_linux_new_thread): New functions.
13877 (x86_linux_prepare_to_resume): New function.
13878 (the_low_target): Add entries for insert_point, remove_point,
13879 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
13880 prepare_to_resume.
13881 * server.c (debug_hw_points): New global.
13882 (monitor_show_help): Document set debug-hw-points.
13883 (handle_query): Process "set debug-hw-points".
13884 * server.h (debug_hw_points): Declare.
13885 (paddress): Declare.
13886 * utils.c (NUMCELLS, CELLSIZE): New macros.
13887 (get_sell, xsnprintf, paddress): New functions.
13888 * win32-arm-low.c (the_low_target): Add entries for insert_point,
13889 remove_point, stopped_by_watchpoint, stopped_data_address.
13890 * win32-i386-low.c: Include i386-low.h.
13891 (debug_reg_state): Replaces dr.
13892 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
13893 (i386_dr_low_get_status): New function.
13894 (i386_insert_point, i386_remove_point): New functions.
13895 (i386_stopped_by_watchpoint): New function.
13896 (i386_stopped_data_address): New function.
13897 (i386_initial_stuff): Update.
13898 (get_thread_context,set_thread_context,i386_thread_added): Update.
13899 (the_low_target): Add entries for insert_point,
13900 remove_point, stopped_by_watchpoint, stopped_data_address.
13901 * win32-low.c (win32_insert_watchpoint): New function.
13902 (win32_remove_watchpoint): New function.
13903 (win32_stopped_by_watchpoint): New function.
13904 (win32_stopped_data_address): New function.
13905 (win32_target_ops): Add entries for insert_watchpoint,
13906 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
13907 * win32-low.h (win32_target_ops): New members insert_point,
13908 remove_point, stopped_by_watchpoint, stopped_data_address.
13909
13910 2009-06-25 Pedro Alves <pedro@codesourcery.com>
13911
13912 * server.c (process_serial_event): Re-return unsupported, not
13913 error, if the type isn't recognized. Re-allow supporting only
13914 insert or remove packets. Also call require_running for
13915 breakpoints. Add missing break statement to default case. Tidy.
13916 * target.h (struct target_ops): Rename insert_watchpoint to
13917 insert_point, and remove_watchpoint to remove_point.
13918
13919 * linux-low.h (struct linux_target_ops): Likewise.
13920 * linux-low.c (linux_insert_watchpoint): Rename to ...
13921 (linux_insert_point): ... this. Adjust.
13922 (linux_remove_watchpoint): Rename to ...
13923 (linux_remove_point): ... this. Adjust.
13924 (linux_target_ops): Adjust.
13925 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
13926 (cris_insert_point): ... this.
13927 (cris_remove_watchpoint): Rename to ...
13928 (cris_remove_point): ... this.
13929 (the_low_target): Adjust.
13930
13931 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
13932
13933 * server.c (handle_v_kill): Pass signal_pid to
13934 kill_inferior if multi_process is zero.
13935
13936 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
13937
13938 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
13939 * target.h (target_ops): Comment for *_watchpoint to make it clear
13940 the functions can get types '0' and '1'.
13941
13942 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
13943
13944 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
13945 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
13946 * regcache.c (get_regcache): Likewise.
13947 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
13948 * win32-low.c (child_fetch_inferior_registers): Remove check for
13949 regno 0.
13950
13951 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
13952 Pedro Alves <pedro@codesourcery.com>
13953
13954 * target.h (struct target_ops) <supports_multi_process>: New
13955 callback.
13956 (target_supports_multi_process): New.
13957 * server.c (handle_query): Even if GDB reports support, only
13958 enable multi-process if the target also supports it. Report
13959 multi-process support only if the target backend supports it.
13960 * linux-low.c (linux_supports_multi_process): New function.
13961 (linux_target_ops): Install it as target_supports_multi_process
13962 callback.
13963
13964 2009-05-24 Doug Evans <dje@google.com>
13965
13966 Global renaming of find_thread_pid to find_thread_ptid.
13967 * server.h (find_thread_ptid): Renamed from find_thread_pid.
13968 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
13969 All callers updated.
13970
13971 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
13972 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
13973 directly.
13974
13975 * linux-low.c (get_stop_pc): Print pc if debug_threads.
13976 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
13977 (linux_resume_one_lwp): Ditto.
13978
13979 2009-05-23 Doug Evans <dje@google.com>
13980
13981 * linux-low.c (linux_resume_one_lwp): Change type of first arg
13982 from struct inferior_list_entry * to struct lwp_info *.
13983 All callers updated.
13984
13985 2009-05-13 Doug Evans <dje@google.com>
13986
13987 * linux-x86-low.c: Don't include assert.h.
13988 (x86_siginfo_fixup): Use fatal, not assert.
13989 (x86_arch_setup): Fix comment.
13990
13991 2009-05-12 Doug Evans <dje@google.com>
13992
13993 Biarch support for i386/amd64 gdbserver.
13994 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
13995 Add linux-x86-low.c.
13996 (linux-i386-low.o, linux-x86-64-low.o): Delete.
13997 (linux-x86-low.o): Add.
13998 * linux-x86-64-low.c: Delete.
13999 * linux-i386-low.c: Delete.
14000 * linux-x86-low.c: New file.
14001 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14002 linux-x86-low.o.
14003 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14004 linux-x86-low.o.
14005 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14006 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14007 (linux_child_pid_to_exec_file): New function.
14008 (elf_64_header_p, elf_64_file_p): New functions.
14009 (siginfo_fixup): New function.
14010 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14011 give target a chance to convert layout.
14012 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14013 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14014
14015 2009-05-07 Doug Evans <dje@google.com>
14016
14017 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14018 (regsets_store_inferior_registers): Ditto.
14019
14020 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14021
14022 PR server/10048
14023
14024 * linux-low.c (must_set_ptrace_flags): Delete.
14025 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14026 of the global.
14027 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14028 `lwp->must_set_ptrace_flags' instead.
14029 (linux_wait_for_event_1): Set ptrace options here.
14030 (linux_wait_1): ... not here.
14031
14032 2009-04-30 Doug Evans <dje@google.com>
14033
14034 * inferiors.c (started_inferior_callback): New function.
14035 (attached_inferior_callback): New function.
14036 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14037 * server.c (print_started_pid, print_attached_pid): New functions.
14038 (detach_or_kill_for_exit): New function.
14039 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14040 * server.h (have_started_inferiors_p): Declare.
14041 (have_attached_inferiors_p): Declare.
14042
14043 * inferiors.c (remove_process): Fix memory leak, free process.
14044 * linux-low.c (linux_remove_process): New function.
14045 (linux_kill): Call it instead of remove_process.
14046 (linux_detach, linux_wait_1): Ditto.
14047
14048 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14049
14050 * configure.srv: Add x86 Windows CE target.
14051
14052 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14053
14054 * inferiors.c (get_thread_process): Make global.
14055 * server.h (get_thread_process): Add prototype.
14056 * thread-db.c (find_one_thread): Use get_thread_process
14057 instead of current_process.
14058 (thread_db_get_tls_address): Do not crash if called when
14059 thread layer is not yet initialized.
14060
14061 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14062
14063 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14064 * spu-low.c (current_tid): Rename to ...
14065 (current_ptid): ... this.
14066 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14067 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14068 ptid_get_lwp (current_ptid) instead of current_tid.
14069 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14070 instead of current_tid. Use find_process_pid to verify pid
14071 argument is valid. Pass proper argument to remove_process.
14072 (spu_thread_alive): Compare current_ptid instead of current_tid.
14073 (spu_resume): Likewise.
14074
14075 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14076
14077 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14078 variable.
14079
14080 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14081
14082 Implement the multiprocess extensions, and add linux multiprocess
14083 support.
14084
14085 * server.h (ULONGEST): Declare.
14086 (struct ptid, ptid_t): New.
14087 (minus_one_ptid, null_ptid): Declare.
14088 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14089 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14090 (struct inferior_list_entry): Change `id' type from unsigned from
14091 to ptid_t.
14092 (struct sym_cache, struct breakpoint, struct
14093 process_info_private): Forward declare.
14094 (struct process_info): Declare.
14095 (current_process): Declare.
14096 (all_processes): Declare.
14097 (initialize_inferiors): Declare.
14098 (add_thread): Adjust to use ptid_t.
14099 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14100 (add_process, remove_process, find_thread_pid): Declare.
14101 (find_inferior_id): Adjust to use ptid_t.
14102 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14103 (multi_process): Declare.
14104 (push_event): Adjust to use ptid_t.
14105 (read_ptid, write_ptid): Declare.
14106 (prepare_resume_reply): Adjust to use ptid_t.
14107 (clear_symbol_cache): Declare.
14108 * inferiors.c (all_processes): New.
14109 (null_ptid, minus_one_ptid): New.
14110 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14111 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14112 (add_thread): Change unsigned long to ptid. Remove gdb_id
14113 parameter. Adjust.
14114 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14115 (gdb_id_to_thread): Rename to ...
14116 (find_thread_pid): ... this. Change unsigned long to ptid.
14117 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14118 (loaded_dll, pull_pid_from_list): Adjust.
14119 (add_process, remove_process, find_process_pid)
14120 (get_thread_process, current_process, initialize_inferiors): New.
14121 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14122 (struct target_waitstatus) <related_pid>: Ditto.
14123 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14124 return type to int.
14125 (struct target_ops) <join>: Add `pid' argument.
14126 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14127 (struct target_ops) <wait>: Add `ptid' field. Change return type
14128 to ptid.
14129 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14130 (mywait): Add `ptid' argument. Change return type to ptid_t.
14131 (target_pid_to_str): Declare.
14132 * target.c (set_desired_inferior): Adjust to use ptids.
14133 (mywait): Add new `ptid' argument. Adjust.
14134 (target_pid_to_str): New.
14135 * mem-break.h (free_all_breakpoints): Declare.
14136 * mem-break.c (breakpoints): Delelete.
14137 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14138 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14139 to use per-process breakpoint list.
14140 (free_all_breakpoints): New.
14141 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14142 (symbol_cache, all_symbols_looked_up): Delete.
14143 (hexchars): New.
14144 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14145 read_ptid): New.
14146 (prepare_resume_reply): Change ptid argument's type from unsigned
14147 long to ptid_t. Adjust. Implement W;process and X;process.
14148 (free_sym_cache, clear_symbol_cache): New.
14149 (look_up_one_symbol): Adjust to per-process symbol cache. *
14150 * server.c (cont_thread, general_thread, step_thread): Change type
14151 to ptid_t.
14152 (attached): Delete.
14153 (multi_process): New.
14154 (last_ptid): Change type to ptid_t.
14155 (struct vstop_notif) <ptid>: Change type to ptid_t.
14156 (queue_stop_reply, push_event): Change `ptid' argument's type to
14157 ptid_t.
14158 (discard_queued_stop_replies): Add `pid' argument.
14159 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14160 changes. Don't reference the `attached' global.
14161 (attach_inferior): Adjust to mywait interface changes.
14162 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14163 features. Handle and report "multiprocess+". Handle
14164 "qAttached:PID".
14165 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14166 changes.
14167 (handle_v_kill): New.
14168 (handle_v_stopped): Adjust to use target_pid_to_str.
14169 (handle_v_requests): Allow multiple attaches and runs when
14170 multiprocess extensions are in effect. Handle "vKill".
14171 (myresume): Adjust to use ptids.
14172 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14173 (handle_status): Adjust to discard_queued_stop_replies interface
14174 change.
14175 (first_thread_of, kill_inferior_callback)
14176 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14177 (main): Call initialize_inferiors. Adjust to use ptids, killing
14178 and detaching from all inferiors. Handle multiprocess packet
14179 variants.
14180 * linux-low.h: Include gdb_proc_service.h.
14181 (struct process_info_private): New.
14182 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14183 <lwpid_of>: Use ptid_get_lwp.
14184 (get_lwp_thread): Adjust.
14185 (struct lwp_info): Add `dead' member.
14186 (find_lwp_pid): Declare.
14187 * linux-low.c (thread_db_active): Delete.
14188 (new_inferior): Adjust comment.
14189 (inferior_pid): Delete.
14190 (linux_add_process): New.
14191 (handle_extended_wait): Adjust.
14192 (add_lwp): Change unsigned long to ptid.
14193 (linux_create_inferior): Add process to processes table. Adjust
14194 to use ptids. Don't set new_inferior here.
14195 (linux_attach_lwp): Rename to ...
14196 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14197 it. Adjust to use ptids.
14198 (linux_attach_lwp): New.
14199 (linux_attach): Add process to processes table. Don't set
14200 new_inferior here.
14201 (struct counter): New.
14202 (second_thread_of_pid_p, last_thread_of_process_p): New.
14203 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14204 multiple processes.
14205 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14206 processes. Remove process from process table.
14207 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14208 to multiple processes.
14209 (any_thread_of): New.
14210 (linux_detach): Add `pid' argument, and handle it. Remove process
14211 from processes table.
14212 (linux_join): Add `pid' argument. Handle it.
14213 (linux_thread_alive): Change unsighed long argument to ptid_t.
14214 Consider dead lwps as not being alive.
14215 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14216 threads we're not interested in.
14217 (same_lwp, find_lwp_pid): New.
14218 (linux_wait_for_lwp): Change `pid' argument's type from int to
14219 ptid_t. Adjust.
14220 (linux_wait_for_event): Rename to ...
14221 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14222 from int to ptid_t. Adjust.
14223 (linux_wait_for_event): New.
14224 (linux_wait_1): Add `ptid' argument. Change return type to
14225 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14226 that exit from the process table.
14227 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14228 Adjust.
14229 (mark_lwp_dead): New.
14230 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14231 stopping all threads, mark its main lwp as dead.
14232 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14233 ptids.
14234 (fetch_register, usr_store_inferior_registers)
14235 (regsets_fetch_inferior_registers)
14236 (regsets_store_inferior_registers, linux_read_memory)
14237 (linux_write_memory): Inline `inferior_pid'.
14238 (linux_look_up_symbols): Adjust to use per-process
14239 `thread_db_active'.
14240 (linux_request_interrupt): Adjust to use ptids.
14241 (linux_read_auxv): Inline `inferior_pid'.
14242 (initialize_low): Don't reference thread_db_active.
14243 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14244 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14245 (ps_getpid): Return the pid of the current inferior.
14246 * thread-db.c (proc_handle, thread_agent): Delete.
14247 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14248 per-process data.
14249 (find_one_thread): Change argument type to ptid_t. Adjust to
14250 per-process data.
14251 (maybe_attach_thread): Adjust to per-process data and ptids.
14252 (thread_db_find_new_threads): Ditto.
14253 (thread_db_init): Ditto.
14254 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14255 processes table. Adjust to use ptids.
14256 (spu_kill, spu_detach): Adjust interface. Remove process from
14257 processes table.
14258 (spu_join, spu_thread_alive): Adjust interface.
14259 (spu_wait): Adjust interface. Remove process from processes
14260 table. Adjust to use ptids.
14261 * win32-low.c (current_inferior_tid): Delete.
14262 (current_inferior_ptid): New.
14263 (debug_event_ptid): New.
14264 (thread_rec): Take a ptid. Adjust.
14265 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14266 (child_delete_thread): Ditto.
14267 (do_initial_child_stuff): Add `attached' argument. Add process to
14268 processes table.
14269 (child_fetch_inferior_registers, child_store_inferior_registers):
14270 Adjust.
14271 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14272 (win32_attach): Pass 1 to do_initial_child_stuff.
14273 (win32_kill): Adjust interface. Remove process from processes
14274 table.
14275 (win32_detach): Ditto.
14276 (win32_join): Adjust interface.
14277 (win32_thread_alive): Take a ptid.
14278 (win32_resume): Adjust to use ptids.
14279 (get_child_debug_event): Ditto.
14280 (win32_wait): Adjust interface. Remove exiting process from
14281 processes table.
14282
14283 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14284
14285 Non-stop mode support.
14286
14287 * server.h (non_stop): Declare.
14288 (gdb_client_data, handler_func): Declare.
14289 (delete_file_handler, add_file_handler, start_event_loop):
14290 Declare.
14291 (handle_serial_event, handle_target_event, push_event)
14292 (putpkt_notif): Declare.
14293 * target.h (enum resume_kind): New.
14294 (struct thread_resume): Replace `step' field by `kind' field.
14295 (TARGET_WNOHANG): Define.
14296 (struct target_ops) <wait>: Add `options' argument.
14297 <supports_non_stop, async, start_non_stop>: New fields.
14298 (target_supports_non_stop, target_async): New.
14299 (start_non_stop): Declare.
14300 (mywait): Add `options' argument.
14301 * target.c (mywait): Add `options' argument. Print child exit
14302 notifications here.
14303 (start_non_stop): New.
14304 * server.c (non_stop, own_buf, mem_buf): New globals.
14305 (struct vstop_notif): New.
14306 (notif_queue): New global.
14307 (queue_stop_reply, push_event, discard_queued_stop_replies)
14308 (send_next_stop_reply): New.
14309 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14310 interface changes.
14311 (attach_inferior): In non-stop mode, don't wait for the target
14312 here.
14313 (handle_general_set): Handle QNonStop.
14314 (handle_query): When handling qC, return the current general
14315 thread, instead of the first thread of the list.
14316 (handle_query): If the backend supports non-stop mode, include
14317 QNonStop+ in the qSupported query response.
14318 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14319 and non-stop mode.
14320 (handle_v_attach, handle_v_run): Handle non-stop mode.
14321 (handle_v_stopped): New.
14322 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14323 (myresume): Adjust to use resume_kind. Handle non-stop.
14324 (queue_stop_reply_callback): New.
14325 (handle_status): Handle non-stop mode.
14326 (main): Clear non_stop flag on reconnection. Use the event-loop.
14327 Refactor serial protocol handling from here ...
14328 (process_serial_event): ... to this new function. When GDB
14329 selects any thread, select one here. In non-stop mode, wait until
14330 GDB acks all pending events before exiting.
14331 (handle_serial_event, handle_target_event): New.
14332 * remote-utils.c (remote_open): Install remote_desc in the event
14333 loop.
14334 (remote_close): Remove remote_desc from the event loop.
14335 (putpkt_binary): Rename to...
14336 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14337 (putpkt_binary): New as wrapper around putpkt_binary_1.
14338 (putpkt_notif): New.
14339 (prepare_resume_reply): In non-stop mode, don't change the
14340 general_thread.
14341 * event-loop.c: New.
14342 * Makefile.in (OBJ): Add event-loop.o.
14343 (event-loop.o): New rule.
14344
14345 * linux-low.h (pid_of): Moved here.
14346 (lwpid_of): New.
14347 (get_lwp_thread): Use lwpid_of.
14348 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14349 * linux-low.c (pid_of): Delete.
14350 (inferior_pid): Use lwpid_of.
14351 (linux_event_pipe): New.
14352 (target_is_async_p): New.
14353 (delete_lwp): New.
14354 (handle_extended_wait): Use lwpid_of.
14355 (add_lwp): Don't set lwpid field.
14356 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14357 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14358 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14359 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14360 first. Adjust to linux_wait_for_event interface changes. Use
14361 lwpid_of.
14362 (linux_detach): Don't delete the main lwp here.
14363 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14364 (status_pending_p): Don't consider explicitly suspended lwps.
14365 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14366 pointer. Add OPTIONS argument. Change return type to int. Use
14367 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14368 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14369 pointer. Add status pointer argument. Return a pid instead of a
14370 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14371 changes. In non-stop mode, don't switch to a random thread.
14372 (linux_wait): Rename to...
14373 (linux_wait_1): ... this. Add target_options argument, and handle
14374 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14375 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14376 clean exit and signal exit code. Don't stop all threads in
14377 non-stop mode. In all-stop mode, only stop all threads when
14378 reporting a stop to GDB. Handle explicit thread stop requests.
14379 (async_file_flush, async_file_mark): New.
14380 (linux_wait): New.
14381 (send_sigstop): Use lwpid_of.
14382 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14383 interface changes. In non-stop mode, don't switch to a random
14384 thread.
14385 (linux_resume_one_lwp): Use lwpid_of.
14386 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14387 (linux_resume_one_thread): ... this. Handle resume_stop. In
14388 non-stop mode, don't look for pending flag in all threads.
14389 (resume_status_pending_p): Don't consider explicitly suspended
14390 threads.
14391 (my_waitpid): Reimplement. Emulate __WALL.
14392 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14393 Use lwpid_of.
14394 (sigchld_handler, linux_supports_non_stop, linux_async)
14395 (linux_start_non_stop): New.
14396 (linux_target_ops): Register linux_supports_non_stop, linux_async
14397 and linux_start_non_stop.
14398 (initialize_low): Install SIGCHLD handler.
14399 * thread-db.c (thread_db_create_event, find_one_thread)
14400 (thread_db_get_tls_address): Use lwpid_of.
14401 * win32-low.c (win32_detach): Adjust to use resume_kind.
14402 (win32_wait): Add `options' argument.
14403 * spu-low.c (spu_resume): Adjust to use resume_kind.
14404 (spu_wait): Add `options' argument.
14405
14406 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14407
14408 Decouple target code from remote protocol.
14409
14410 * target.h (enum target_waitkind): New.
14411 (struct target_waitstatus): New.
14412 (struct target_ops) <wait>: Return an unsigned long. Take a
14413 target_waitstatus pointer instead of a char pointer.
14414 (mywait): Likewise.
14415 * target.c (mywait): Change prototype to return an unsigned long.
14416 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14417 * server.h (thread_from_wait, old_thread_from_wait): Delete
14418 declarations.
14419 (prepare_resume_reply): Change prototype to take a
14420 target_waitstatus.
14421 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14422 (last_status, last_ptid): New.
14423 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14424 pid instead of a signal.
14425 (attach_inferior): Remove "status" and "signal" parameters.
14426 Adjust.
14427 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14428 not as an address.
14429 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14430 (handle_v_requests, myresume): Remove "status" and "signal"
14431 parameters. Adjust.
14432 (handle_status): New.
14433 (main): Delete local `status'. Adjust.
14434 * remote-utils.c: Include target.h.
14435 (prepare_resume_reply): Change prototype to take a
14436 target_waitstatus. Adjust.
14437
14438 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14439 interface.
14440 * spu-low.c (spu_wait): Adjust.
14441 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14442 Delete.
14443 (win32_wait): Adjust.
14444
14445 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14446
14447 * target.h (struct thread_resume): Delete leave_stopped member.
14448 (struct target_ops): Add a `n' argument to the `resume' callback.
14449 * server.c (start_inferior): Adjust.
14450 (handle_v_cont, myresume): Adjust.
14451 * linux-low.c (check_removed_breakpoint): Adjust to resume
14452 interface change, and to removed leave_stopped field.
14453 (resume_ptr): Delete.
14454 (struct thread_resume_array): New.
14455 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14456 resume interface change.
14457 (linux_continue_one_thread, linux_queue_one_thread)
14458 (resume_status_pending_p): Check if the resume field is NULL
14459 instead of checking the leave_stopped member.
14460 (linux_resume): Adjust to the target resume interface change.
14461 * spu-low.c (spu_resume): Adjust to the target resume interface
14462 change.
14463 * win32-low.c (win32_detach, win32_resume): Ditto.
14464
14465 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14466
14467 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
14468 flag.
14469 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
14470 pending.
14471 (linux_continue_one_thread): Only preserve the stepping flag if
14472 there's a pending breakpoint.
14473
14474 2009-03-31 Pedro Alves <pedro@codesourcery.com>
14475
14476 * server.c (main): After the inferior having exited, call
14477 remote_close before exiting gdbserver.
14478
14479 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
14480
14481 Fix size of FPSCR in Power 7 processors.
14482 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
14483 (PPC_FEATURE_HAS_DFP): New #define.
14484 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
14485 size of the FPSCR.
14486
14487 2009-03-23 Pedro Alves <pedro@codesourcery.com>
14488
14489 * server.c (handle_query) Whitespace and formatting.
14490
14491 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14492
14493 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
14494 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
14495 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
14496 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
14497 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
14498 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
14499 Makefile.in, configure.ac: Fix whitespace throughout.
14500 * configure: Regenerate.
14501
14502 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14503
14504 * inferiors.c (find_inferior): Make it safe for the callback
14505 function to delete the currently iterated inferior.
14506
14507 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14508
14509 * Makefile.in (linuw_low_h): Move higher.
14510 (thread-db.o): Depend on $(linux_low_h).
14511
14512 2009-03-17 Pedro Alves <pedro@codesourcery.com>
14513
14514 Rename "process" to "lwp" throughout.
14515
14516 * linux-low.c (all_processes): Rename to...
14517 (all_lwps): ... this.
14518 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
14519 (add_process): Rename to ...
14520 (add_lwp): ... this. Adjust.
14521 (linux_create_inferior): Adjust.
14522 (linux_attach_lwp): Adjust.
14523 (linux_attach): Adjust.
14524 (linux_kill_one_process): Rename to ...
14525 (linux_kill_one_lwp): ... this. Adjust.
14526 (linux_kill): Adjust.
14527 (linux_detach_one_process): Rename to ...
14528 (linux_detach_one_lwp): ... this. Adjust.
14529 (linux_detach): Adjust.
14530 (check_removed_breakpoint): Adjust.
14531 (status_pending_p): Adjust.
14532 (linux_wait_for_process): Rename to ...
14533 (linux_wait_for_lwp): ... this. Adjust.
14534 (linux_wait_for_event): Adjust.
14535 (send_sigstop): Adjust.
14536 (wait_for_sigstop): Adjust.
14537 (stop_all_processes): Rename to ...
14538 (stop_all_lwps): ... this.
14539 (linux_resume_one_process): Rename to ...
14540 (linux_resume_one_lwp): ... this. Adjust.
14541 (linux_set_resume_request, linux_continue_one_thread)
14542 (linux_queue_one_thread, resume_status_pending_p)
14543 (usr_store_inferior_registers, regsets_store_inferior_registers)
14544 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14545 Adjust.
14546 * linux-low.h (get_process): Rename to ...
14547 (get_lwp): ... this. Adjust.
14548 (get_thread_process): Rename to ...
14549 (get_thread_lwp): ... this. Adjust.
14550 (get_process_thread): Rename to ...
14551 (get_lwp_thread): ... this. Adjust.
14552 (struct process_info): Rename to ...
14553 (struct lwp_info): ... this.
14554 (all_processes): Rename to ...
14555 (all_lwps): ... this.
14556 * proc-service.c (ps_lgetregs): Adjust.
14557 * thread-db.c (thread_db_create_event, find_one_thread)
14558 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
14559
14560 2009-03-14 Pedro Alves <pedro@codesourcery.com>
14561
14562 * server.c (handle_query): Handle "qAttached".
14563
14564 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
14565
14566 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
14567 GPLv3, update license URL.
14568
14569 2009-03-01 Doug Evans <dje@google.com>
14570
14571 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
14572 (server_h): Add gdb_signals.h.
14573 (signals.o): Update.
14574 * server.h (target_signal_from_host,target_signal_to_host_p)
14575 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
14576
14577 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
14578
14579 * remote-utils.c (getpkt): Also generate remote-debug
14580 information if noack_mode is set.
14581
14582 2009-02-06 Pedro Alves <pedro@codesourcery.com>
14583
14584 * server.c (handle_query): Report qXfer:siginfo:read and
14585 qXfer:siginfo:write as supported and handle them.
14586 * target.h (struct target_ops) <qxfer_siginfo>: New field.
14587 * linux-low.c (linux_xfer_siginfo): New.
14588 (linux_target_ops): Set it.
14589
14590 2009-01-26 Pedro Alves <pedro@codesourcery.com>
14591
14592 * server.c (gdbserver_usage): Mention --remote-debug.
14593 (main): Accept '--remote-debug' switch.
14594
14595 2009-01-18 Doug Evans <dje@google.com>
14596
14597 * regcache.c (new_register_cache): No need to check result of xcalloc.
14598 * server.c (handle_search_memory): Back out calls to xmalloc,
14599 result is checked and error is returned to user upon failure.
14600 (handle_query): Ditto. Add more checks for result of malloc.
14601 (handle_v_cont): Check result of malloc, report error back to
14602 user upon failure.
14603 (handle_v_run): Ditto. Call freeargv.
14604 * server.h (freeargv): Declare.
14605 * utils.c (freeargv): New fn.
14606
14607 2009-01-15 Doug Evans <dje@google.com>
14608
14609 * gdbreplay.c (perror_with_name): Make arg const char *.
14610 * server.h (target_signal_to_name): Make return type const char *.
14611 * thread-db.c (thread_db_err_str): Make return type const char *.
14612 * utils.c (perror_with_name): Make arg const char *.
14613
14614 2009-01-14 Pedro Alves <pedro@codesourcery.com>
14615
14616 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
14617 when handling a EXIT_PROCESS_DEBUG_EVENT.
14618
14619 2009-01-06 Joel Brobecker <brobecker@adacore.com>
14620
14621 * gdbreplay.c (gdbreplay_version): Update copyright year.
14622 * server.c (gdbserver_version): Likewise.
14623
14624 2009-01-05 Doug Evans <dje@google.com>
14625
14626 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
14627 (handle_extended_wait): Improve comment.
14628
14629 2008-12-13 Doug Evans <dje@google.com>
14630
14631 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
14632 * server.h (ATTR_MALLOC): New macro.
14633 (xmalloc,xcalloc,xstrdup): Declare.
14634 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
14635 * inferiors.c: Ditto.
14636 * linux-low.c: Ditto.
14637 * mem-break.c: Ditto.
14638 * regcache.c: Ditto.
14639 * remote-utils.c: Ditto.
14640 * server.c: Ditto.
14641 * target.c: Ditto.
14642 * win32-low.c: Ditto.
14643
14644 2008-12-12 Doug Evans <dje@google.com>
14645
14646 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
14647 in debugging printf.
14648
14649 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
14650
14651 2008-12-09 Doug Evans <dje@google.com>
14652
14653 * linux-low.h (struct process_info): Delete member tid, unused.
14654 * thread-db.c (find_one_thread): Update.
14655 (maybe_attach_thread): Update.
14656
14657 2008-12-02 Pedro Alves <pedro@codesourcery.com>
14658
14659 * target.h (struct target_ops): Add qxfer_osdata member.
14660 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
14661 and dirent.h.
14662 (linux_qxfer_osdata): New functions.
14663 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
14664 callback.
14665 * server.c (handle_query): Handle "qXfer:osdata:read:".
14666 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
14667 (buffer_xml_printf): New functions.
14668 * server.h (struct buffer): New.
14669 (buffer_grow_str, buffer_grow_str0): New macros.
14670 (buffer_grow, buffer_free, buffer_init, buffer_finish)
14671 (buffer_xml_printf): Declare.
14672
14673 2008-11-24 Doug Evans <dje@google.com>
14674
14675 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
14676
14677 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
14678
14679 * server.c (handle_v_run): Always use the supplied argument list.
14680
14681 2008-11-19 Bob Wilson <bob.wilson@acm.org>
14682
14683 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
14684 (xtensa_regmap_table): Add entry for scompare1.
14685
14686 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
14687
14688 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
14689 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
14690 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
14691 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
14692 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
14693 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
14694 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
14695 XML target descriptions.
14696 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
14697 when inferior is running on an ISA 2.05 or later processor. Add
14698 special case to return offset for full 64-bit slot of FPSCR when
14699 in 32-bits.
14700
14701 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
14702
14703 * Makefile.in (SFILES, clean): Added sparc64 files.
14704 (reg-sparc64.o, reg-sparc64.c): New.
14705 * configure.srv (sparc*-*-linux*): New configuration.
14706 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
14707 syscall arguments for SPARC.
14708 (regsets_store_inferior_registers): Likewise.
14709 * linux-sparc-low.c: New file.
14710
14711 2008-10-21 Doug Evans <dje@google.com>
14712
14713 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
14714 (READLINE_DIR,READLINE_DEP): Delete.
14715 (INTERNAL_CFLAGS): Update.
14716 (LINTFLAGS): Update.
14717
14718 2008-10-10 Pedro Alves <pedro@codesourcery.com>
14719
14720 * server.c (handle_v_run): If GDB didn't specify an argv, use the
14721 whole argv from the last run, not just argv[0].
14722
14723 2008-09-08 Pedro Alves <pedro@codesourcery.com>
14724
14725 * regcache.c (new_register_cache): Return NULL if the register
14726 cache size isn't known yet.
14727 (free_register_cache): Avoid dereferencing a NULL regcache.
14728
14729 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
14730
14731 * configure.srv: Merge MIPS and MIPS64.
14732
14733 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
14734
14735 * Makefile.in (uninstall): Apply $(EXEEXT) too.
14736
14737 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
14738
14739 * Makefile.in: Add required vsx dependencies.
14740
14741 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
14742 Declare init_registers_powerpc_vsx32l.
14743 Declare init_registers_powerpc_vsx64l.
14744 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
14745 (ppc_arch_setup): Check for VSX in hwcap.
14746 (ppc_fill_vsxregset): New function.
14747 (ppc_store_vsxregset): New function.
14748 Add new VSX entry in regset_info target_regsets.
14749
14750 * configure.srv: Add new VSX dependencies.
14751
14752 2008-08-12 Pedro Alves <pedro@codesourcery.com>
14753
14754 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
14755 (remote_open): Set or clear transport_is_reliable.
14756 (putpkt_binary): Don't expect acks in noack mode.
14757 (getpkt): Don't send ack/nac in noack mode.
14758 * server.c (handle_general_set): Handle QStartNoAckMode.
14759 (handle_query): If connected by tcp pass QStartNoAckMode+ in
14760 qSupported.
14761 (main): Reset noack_mode on every connection.
14762 * server.h (noack_mode): Declare.
14763
14764 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14765
14766 * Makefile.in (GDBREPLAY_OBS): New variable.
14767 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
14768
14769 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
14770 Daniel Jacobowitz <dan@codesourcery.com>
14771
14772 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
14773 (usr_store_inferior_registers): Likewise.
14774 (regsets_store_inferior_registers): Likewise.
14775
14776 2008-07-31 Rolf Jansen <rj@surtec.com>
14777 Pedro Alves <pedro@codesourcery.com>
14778
14779 * configure.ac: Check for memmem declaration.
14780 * server.c [HAVE_MALLOC_H]: Include malloc.h.
14781 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
14782 (disable_packet_qfThreadInfo): Unconditionally compile.
14783 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
14784 * configure, config.in: Regenerate.
14785
14786 2008-07-28 Doug Kwan <dougkwan@google.com>
14787
14788 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
14789 (linux_write_memory): Remove declaration of errno.
14790
14791 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
14792
14793 * linux-low.c (handle_extended_wait): Do not use "status"
14794 variable uninitialized.
14795
14796 2008-07-07 Pedro Alves <pedro@codesourcery.com>
14797
14798 * server.c (handle_v_attach): Inhibit reporting dll changes.
14799
14800 2008-06-27 Pedro Alves <pedro@codesourcery.com>
14801
14802 * remote-utils.c (prepare_resume_reply): If requested, don't
14803 output "thread:TID" in the T stop reply.
14804
14805 * server.c (disable_packet_vCont, disable_packet_Tthread)
14806 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
14807 (handle_query): If requested, disable support for qC, qfThreadInfo
14808 and qsThreadInfo.
14809 (handle_v_requests): If requested, disable support for vCont.
14810 (gdbserver_show_disableable): New.
14811 (main): Handle --disable-packet and --disable-packet=LIST.
14812
14813 * server.h (disable_packet_vCont, disable_packet_Tthread)
14814 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
14815
14816 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
14817
14818 * server.c (gdbserver_usage): Mention --version.
14819
14820 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
14821
14822 * Makefile.in (gdbreplay.o): New rule.
14823
14824 2008-06-06 Joseph Myers <joseph@codesourcery.com>
14825
14826 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
14827 message, not gdbserver.
14828
14829 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
14830 Nathan Sidwell <nathan@codesourcery.com>
14831 Joseph Myers <joseph@codesourcery.com>
14832
14833 * acinclude.m4: Include ../../config/acx.m4.
14834 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
14835 * configure, config.in: Regenerate.
14836 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
14837 * server.c (gdbserver_version): Print PKGVERSION.
14838 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
14839 (main): Adjust gdbserver_usage calls.
14840 * gdbreplay.c (version, host_name): Add declarations.
14841 (gdbreplay_version, gdbreplay_usage): New.
14842 (main): Accept --version and --help options.
14843
14844 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
14845
14846 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
14847 (arm_breakpoint_at): Handle Thumb.
14848 (the_low_target): Add comment.
14849
14850 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
14851
14852 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
14853
14854 2008-05-09 Doug Evans <dje@google.com>
14855
14856 * server.h (decode_search_memory_packet): Declare.
14857 * remote-utils.c (decode_search_memory_packet): New fn.
14858 * server.c (handle_search_memory_1): New fn.
14859 (handle_search_memory): New fn.
14860 (handle_query): Process qSearch:memory packets.
14861
14862 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
14863
14864 * regcache.c (registers_length): Remove.
14865 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
14866 full register packet.
14867 * regcache.h (registers_length): Remove prototype.
14868 * server.h (PBUFSIZ): Define to 16384.
14869
14870 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
14871
14872 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
14873 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
14874 powerpc-64l.o, and powerpc-altivec64l.o.
14875 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
14876 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
14877 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
14878 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
14879 rs6000/power-linux.xml, and rs6000/power64-linux.xml
14880 to srv_xmlfiles.
14881
14882 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
14883 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
14884 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
14885 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
14886 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
14887 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
14888 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
14889 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
14890 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
14891 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
14892 (clean): Update.
14893
14894 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
14895 (init_registers_powerpc_32l): ... this new prototype.
14896 (init_registers_powerpc_32): Remove, replace by ...
14897 (init_registers_powerpc_altivec32l): ... this new prototype.
14898 (init_registers_powerpc_e500): Remove, replace by ...
14899 (init_registers_powerpc_e500l): ... this new prototype.
14900 (init_registers_ppc64): Remove, replace by ...
14901 (init_registers_powerpc_64l): ... this new prototype.
14902 (init_registers_powerpc_64): Remove, replace by ...
14903 (init_registers_powerpc_altivec64l): ... this new prototype.
14904 (ppc_num_regs): Set to 73.
14905 (PT_ORIG_R3, PT_TRAP): Define if necessary.
14906 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
14907 (ppc_cannot_store_register): Handle orig_r3 and trap.
14908 (ppc_arch_setup): Update init_registers_... calls.
14909 (ppc_fill_gregset): Handle orig_r3 and trap.
14910
14911 * inferiors.c (clear_inferiors): Reset current_inferior.
14912
14913 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
14914
14915 * acinclude.m4: Add override.m4.
14916 * configure: Regenerate.
14917
14918 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
14919
14920 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
14921 initial call to init_register_ppc64.
14922
14923 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
14924
14925 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
14926 single powerpc*-*-linux* case.
14927 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
14928
14929 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
14930
14931 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
14932 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
14933 from reg_xmlfiles.
14934 * linux-ppc-low.c: Include <elf.h>.
14935 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
14936 (ppc_hwcap): New global variable.
14937 (ppc_regmap): Remove __SPE__ #ifdef sections.
14938 (ppc_regmap_e500): New global variable.
14939 (ppc_cannot_store_register): Update __SPE__ special case.
14940 (ppc_get_hwcap): New function.
14941 (ppc_arch_setup): Use it to determine whether inferior supports
14942 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
14943 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
14944 Do not access registers if target does not support AltiVec.
14945 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
14946 Do not access registers if target does not support SPE.
14947 (target_regsets): Unconditionally include AltiVec and SPE regsets.
14948
14949 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
14950
14951 * linux-low.c (disabled_regsets, num_regsets): New.
14952 (use_regsets_p): Delete.
14953 (linux_wait_for_process): Clear disabled_regsets.
14954 (regsets_fetch_inferior_registers): Check and set it.
14955 (regsets_store_inferior_registers): Likewise.
14956 (linux_fetch_registers, linux_store_registers): Do not use
14957 use_regsets_p.
14958 (initialize_low): Allocate disabled_regsets.
14959
14960 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
14961
14962 * Makefile.in (LIBOBJS): New.
14963 (OBS): Use LIBOBJS.
14964 (memmem.o): New rule.
14965 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
14966 * configure: Regenerated.
14967
14968 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
14969
14970 * server.c (handle_query): Never return "unsupported" for
14971 qXfer:features:read queries.
14972
14973 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
14974
14975 * server.c (get_features_xml): Fix inverted condition.
14976 (handle_query): Always support qXfer:feature:read.
14977
14978 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
14979
14980 * server.c (wrapper_argv): New.
14981 (start_inferior): Handle wrapper_argv. If set, expect an extra
14982 trap.
14983 (gdbserver_usage): Document --wrapper.
14984 (main): Parse --wrapper.
14985
14986 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14987
14988 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
14989 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
14990 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
14991 (ppc_set_pc): Likewise.
14992 (ppc_arch_setup): New function.
14993 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
14994 of collect_register.
14995 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
14996
14997 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
14998
14999 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15000 instead of linux-ppc64-low.o.
15001 * linux-ppc64-low.c: Remove file.
15002 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15003 (linux-ppc64-low.o): Remove rule.
15004
15005 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15006 (init_registers_powerpc_64): Likewise.
15007 (ppc_regmap): Conditionally define depending on __powerpc64__.
15008 (ppc_cannot_store_register): Do not special-case "fpscr" when
15009 compiled on __powerpc64__.
15010 (ppc_collect_ptrace_register): New function.
15011 (ppc_supply_ptrace_register): New function.
15012 (ppc_breakpoint): Change type to "unsigned int".
15013 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15014 (the_low_target): Conditionally provide initializers for the
15015 arch_setup member depending on __powerpc64__. Install
15016 collect_ptrace_register and supply_ptrace_register members.
15017
15018 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15019
15020 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15021 * server.c (gdbserver_xmltarget): Define.
15022 (get_features_xml): Use it to replace "target.xml" and arch_string.
15023
15024 * configure.srv: Remove srv_xmltarget. Add XML files that were
15025 mentioned there to srv_xmlfiles instead. Remove conditional tests
15026 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15027 srv_xmlfiles and srv_regobj to include all possible choices.
15028 * configure.ac (srv_xmltarget): Remove.
15029 (srv_xmlfiles): Do not add "target.xml".
15030 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15031 checks for supplementary target information.
15032 * configure: Regenerate.
15033 * Makefile.in (XML_TARGET): Remove.
15034 (target.xml): Remove rule.
15035 (clean): Do not clean up target.xml.
15036 (.PRECIOUS): Do not mention target.xml.
15037
15038 * target.h (struct target_ops): Remove arch_string member.
15039 * linux-low.c (linux_arch_string): Remove.
15040 (linux_target_ops): Remove arch_string initializer.
15041 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15042 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15043 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15044 * spu-low.c (spu_arch_string): Remove.
15045 (spu_target_ops): Remove arch_string initializer.
15046 * win32-low.c (win32_arch_string): Remove.
15047 (win32_target_ops): Remove arch_string initializer.
15048 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15049 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15050 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15051
15052 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15053
15054 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15055 by collect_ptrace_register and supply_ptrace_register hooks.
15056 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15057 instead of checking for the_low_target.left_pad_xfer.
15058 (usr_store_inferior_registers): Use collect_ptrace_register callback
15059 instead of checking for the_low_target.left_pad_xfer.
15060
15061 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15062 (s390_supply_ptrace_register): Likewise.
15063 (s390_fill_gregset): Call s390_collect_ptrace_register.
15064 (the_low_target): Update.
15065
15066 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15067 (ppc_supply_ptrace_register): Likewise.
15068 (the_low_target): Update.
15069
15070 * linux-i386-low.c (the_low_target): Update.
15071 * linux-x86-64-low.c (the_low_target): Update.
15072
15073 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15074
15075 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15076 reg-s390.o and reg-s390x.o.
15077
15078 * linux-low.c (new_inferior): New global variable.
15079 (linux_create_inferior, linux_attach): Set it.
15080 (linux_wait_for_process): Call the_low_target.arch_setup after the
15081 target has stopped for the first time.
15082 (initialize_low): Do not call the_low_target.arch_setup.
15083
15084 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15085 (s390_set_pc): Likewise.
15086 (s390_arch_setup): New function.
15087 (the_low_target): Use s390_arch_setup as arch_setup routine.
15088
15089 * regcache.c (realloc_register_cache): New function.
15090 (set_register_cache): Call it for each existing regcache.
15091
15092 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15093
15094 * server.h (init_registers): Remove prototype.
15095
15096 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15097 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15098 instead of init_registers ().
15099 * linux-arm-low.c (init_registers_arm): Add prototype.
15100 (init_registers_arm_with_iwmmxt): Likewise.
15101 (the_low_target): Add initializer for arch_setup field.
15102 * linux-cris-low.c (init_registers_cris): Add prototype.
15103 (the_low_target): Add initializer for arch_setup field.
15104 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15105 (the_low_target): Add initializer for arch_setup field.
15106 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15107 (the_low_target): Add initializer for arch_setup field.
15108 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15109 (the_low_target): Add initializer for arch_setup field.
15110 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15111 (the_low_target): Add initializer for arch_setup field.
15112 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15113 (the_low_target): Add initializer for arch_setup field.
15114 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15115 (init_registers_mips64_linux): Likewise.
15116 (the_low_target): Add initializer for arch_setup field.
15117 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15118 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15119 (the_low_target): Add initializer for arch_setup field.
15120 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15121 (init_registers_powerpc_64): Likewise.
15122 (the_low_target): Add initializer for arch_setup field.
15123 * linux-s390-low.c (init_registers_s390): Add prototype.
15124 (init_registers_s390x): Likewise.
15125 (the_low_target): Add initializer for arch_setup field.
15126 * linux-sh-low.c (init_registers_sh): Add prototype.
15127 (the_low_target): Add initializer for arch_setup field.
15128 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15129 (the_low_target): Add initializer for arch_setup field.
15130 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15131 (the_low_target): Add initializer for arch_setup field.
15132
15133 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15134 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15135 instead of init_registers ().
15136 * win32-arm-low.c (init_registers_arm): Add prototype.
15137 (the_low_target): Add initializer for arch_setup field.
15138 * win32-i386-low.c (init_registers_i386): Add prototype.
15139 (the_low_target): Add initializer for arch_setup field.
15140
15141 * spu-low.c (init_registers_spu): Add prototype.
15142 (initialize_low): Call initialie_registers_spu () instead of
15143 initialize_registers ().
15144
15145 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15146
15147 * server.c (handle_v_requests): When handling the vRun and vAttach
15148 packets, if already debugging a process, don't kill it. Return an
15149 error instead.
15150
15151 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15152
15153 * server.c (handle_query): Correct length check.
15154
15155 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15156
15157 * win32-low.c (do_initial_child_stuff): Add process handle
15158 parameter. Set current_process_handle and current_process_id from the
15159 parameters. Clear globals.
15160 (win32_create_inferior): Don't set current_process_handle and
15161 current_process_id here. Instead pass them on the call to
15162 do_initial_child_stuff.
15163 (win32_attach): Likewise.
15164 (win32_clear_inferiors): New.
15165 (win32_kill): Don't close the current process handle or the
15166 current thread handle here. Instead call win32_clear_inferiors.
15167 (win32_detach): Don't open a new handle to the process. Call
15168 win32_clear_inferiors.
15169 (win32_join): Don't rely on current_process_handle; open a new
15170 handle using the process id.
15171 (win32_wait): Call win32_clear_inferiors when the inferior process
15172 has exited.
15173
15174 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15175
15176 * server.c (monitor_show_help): Add "exit".
15177
15178 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15179
15180 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15181 (clean): Add reg-xtensa.c.
15182 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15183 * configure.srv (xtensa*-*-linux*) New target.
15184 * linux-xtensa-low.c: New.
15185 * xtensa-xtregs.c: New.
15186
15187 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15188
15189 * hostio.c: Don't include errno.h.
15190 (errno_to_fileio_errno): Move to hostio-errno.
15191 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15192 error number outputting to the target->hostio_last_error callback.
15193 (hostio_packet_error): Use FILEIO_EINVAL directly.
15194 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15195 calls to hostio_error.
15196 * hostio-errno.c: New.
15197 * server.h (hostio_last_error_from_errno): Declare.
15198 * target.h (target_ops): Add hostio_last_error member.
15199 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15200 as hostio_last_error handler.
15201 * spu-low.c (spu_target_ops): Likewise.
15202 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15203 (wince_hostio_last_error): New functions.
15204 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15205 as hostio_last_error handler.
15206 (win32_target_ops) [!_WIN32_WCE]: Register
15207 hostio_last_error_from_errno as hostio_last_error handler.
15208 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15209 (hostio-errno.o): New rule.
15210 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15211 * configure.srv (srv_hostio_err_objs): New variable. Default to
15212 hostio-errno.o.
15213 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15214 * configure: Regenerate.
15215
15216 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15217
15218 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15219 (linux_kill, linux_detach): Clean up the process list.
15220 * remote-utils.c (remote_open): Improve port number parsing.
15221 (putpkt_binary, input_interrupt): Only send interrupts if the target
15222 is running.
15223 * server.c (extended_protocol): Make static.
15224 (attached): Define earlier.
15225 (exit_requested, response_needed, program_argv): New variables.
15226 (target_running): New.
15227 (start_inferior): Clear attached here.
15228 (attach_inferior): Set attached here.
15229 (require_running): Define.
15230 (handle_query): Use require_running and target_running. Implement
15231 "monitor exit".
15232 (handle_v_attach, handle_v_run): New.
15233 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15234 (gdbserver_usage): Update.
15235 (main): Redo argument parsing. Handle --debug and --multi. Handle
15236 --attach along with other options or after the port. Save
15237 program_argv. Support no initial program. Resynchronize
15238 communication with GDB after an error. Handle "monitor exit".
15239 Use require_running and target_running. Always allow the extended
15240 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15241 restart in extended mode.
15242 * README: Refer to the GDB manual. Update --attach usage.
15243
15244 2007-12-20 Andreas Schwab <schwab@suse.de>
15245
15246 * linux-low.c (STACK_SIZE): Define.
15247 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15248 (linux_test_for_tracefork): Likewise.
15249
15250 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15251
15252 * linux-low.c (linux_wait_for_event): Update messages. Do not
15253 reinsert auto-delete breakpoints.
15254 * mem-break.c (struct breakpoint): Change return type of handler to
15255 int.
15256 (set_breakpoint_at): Update handler type.
15257 (reinsert_breakpoint_handler): Return 1 instead of calling
15258 delete_breakpoint.
15259 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15260 setting a new one.
15261 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15262 * mem-break.h (set_breakpoint_at): Update handler type.
15263 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15264 * win32-low.c (auto_delete_breakpoint): New.
15265 (get_child_debug_event): Use it.
15266
15267 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15268
15269 * configure.ac: Check for pread and pwrite.
15270 * hostio.c (handle_pread): Fall back to lseek and read.
15271 (handle_pwrite): Fall back to lseek and write.
15272 * config.in, configure: Regenerated.
15273
15274 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15275
15276 * server.c (myresume): Add own_buf argument.
15277 (main): Update calls.
15278
15279 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15280
15281 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15282 * remote-utils.c (remote_open): Do not call disable_async_io.
15283 (block_async_io): Delete.
15284 (unblock_async_io): Make static.
15285 (initialize_async_io): New.
15286 * server.c (handle_v_cont): Handle async I/O here.
15287 (myresume): Likewise. Move other common resume tasks here...
15288 (main): ... from here. Call initialize_async_io. Disable async
15289 I/O before the main loop.
15290 * server.h (initialize_async_io): Declare.
15291 (block_async_io, unblock_async_io): Delete prototypes.
15292 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15293
15294 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15295
15296 * remote-utils.c (readchar): Allow binary data in received messages.
15297
15298 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15299
15300 * win32-low.c (attaching): New global.
15301 (win32_create_inferior): Clear the `attaching' global.
15302 (win32_attach): Set the `attaching' global.
15303 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15304 attaching. Only set a breakpoint at the entry point if not
15305 attaching.
15306
15307 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15308
15309 * server.c (main): Don't report dll events on the initial
15310 connection on attaches.
15311
15312 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15313
15314 * server.c (main): Relax numerical bases supported for the pid of
15315 the --attach command line argument.
15316
15317 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15318
15319 * win32-low.c (win32_attach): Call OpenProcess before
15320 DebugActiveProcess, not after. Add last error output to error
15321 call.
15322
15323 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15324
15325 * win32-low.c (win32_get_thread_context)
15326 (win32_set_thread_context): New functions.
15327 (thread_rec): Use win32_get_thread_context.
15328 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15329 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15330 field.
15331
15332 2007-12-03 Leo Zayas
15333 Pedro Alves <pedro_alves@portugalmail.pt>
15334
15335 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15336 global variables.
15337 (child_add_thread): Minor cleanup.
15338 (child_continue): Resume artificially suspended threads before
15339 calling ContinueDebugEvent.
15340 (suspend_one_thread): New.
15341 (fake_breakpoint_event): New.
15342 (get_child_debug_event): Change return type to int. Check here if
15343 gdb sent an interrupt request. If a soft interrupt was requested,
15344 fake a breakpoint event. Return 0 if there is no event to handle,
15345 and 1 otherwise.
15346 (win32_wait): Don't check here if gdb sent an interrupt request.
15347 Ensure there is a valid event to handle.
15348 (win32_request_interrupt): Add soft interruption method as last
15349 resort.
15350
15351 2007-12-03 Leo Zayas
15352 Pedro Alves <pedro_alves@portugalmail.pt>
15353
15354 * win32-low.h (win32_thread_info): Add descriptions to the
15355 structure members. Replace `suspend_count' counter by a
15356 `suspended' flag.
15357 * win32-low.c (thread_rec): Update condition of when to get the
15358 context from the inferior. Rely on ContextFlags being set if it
15359 has already been retrieved. Only suspend the inferior thread if
15360 we haven't already. Warn if that fails.
15361 (continue_one_thread): s/suspend_count/suspended/. Only call
15362 ResumeThread once. Warn if that fails.
15363
15364 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15365
15366 * win32-low.c (win32_wait): Don't read from the inferior when it
15367 has already exited.
15368
15369 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15370
15371 * Makefile.in (win32_low_h): New variable.
15372 (win32-low.o): Add dependency on $(win32_low_h).
15373 (win32-arm-low.o, win32-i386-low.o): New rules.
15374
15375 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15376
15377 * hostio.c: Correct copyright year.
15378
15379 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15380
15381 * Makefile.in (OBS): Add hostio.o.
15382 (hostio.o): New rule.
15383 * server.h (handle_vFile): Declare.
15384 * hostio.c: New file.
15385 * server.c (handle_v_requests): Take packet_len and new_packet_len
15386 for binary packets. Call handle_vFile.
15387 (main): Update call to handle_v_requests.
15388
15389 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15390
15391 * linux-low.c: Include <sched.h>.
15392
15393 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15394
15395 * linux-low.c (linux_tracefork_grandchild): New.
15396 (linux_tracefork_child): Use clone.
15397 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15398
15399 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15400
15401 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15402
15403 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15404
15405 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15406
15407 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15408
15409 * inferiors.c (change_inferior_id): Delete.
15410 (add_pid_to_list, pull_pid_from_list): New.
15411 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15412 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15413 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15414 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15415 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15416 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15417 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15418 (using_threads): Always set to 1.
15419 (handle_extended_wait): New.
15420 (add_process): Do not set TID.
15421 (linux_create_inferior): Set must_set_ptrace_flags.
15422 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15423 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15424 (linux_thread_alive): Rename TID argument to LWPID.
15425 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15426 (linux_wait_for_event): Do not use TID or check using_threads. Update
15427 call to dead_thread_notify. Call handle_extended_wait.
15428 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15429 (send_sigstop): Delete sigstop_sent.
15430 (wait_for_sigstop): Avoid TID.
15431 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15432 (linux_test_for_tracefork): New.
15433 (linux_lookup_signals): Use thread_db_active and
15434 linux_supports_tracefork_flag.
15435 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15436 * linux-low.h (get_process_thread): Avoid TID.
15437 (struct process_ifo): Move thread_known and tid to the end. Remove
15438 sigstop_sent.
15439 (linux_attach_lwp, thread_db_init): Update prototypes.
15440 * server.h (change_inferior_id): Delete prototype.
15441 (add_pid_to_list, pull_pid_from_list): New prototypes.
15442 * thread-db.c (thread_db_use_events): New.
15443 (find_first_thread): Rename to...
15444 (find_one_thread): ...this. Update callers and messages. Do not
15445 call fatal. Check thread_db_use_events. Do not call
15446 change_inferior_id or new_thread_notify.
15447 (maybe_attach_thread): Update. Do not call new_thread_notify.
15448 (thread_db_init): Set thread_db_use_events. Check use_events.
15449 * utils.c (fatal, warning): Correct message prefix.
15450
15451 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15452
15453 * Makefile.in (clean): Remove new files.
15454 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15455 (powerpc-64.o, powerpc-64.c): New rules.
15456 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15457 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15458 with SPE.
15459 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15460 SPE targets.
15461 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15462 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15463 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15464 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15465 (target_regsets): Add AltiVec and SPE register sets.
15466 * configure.ac: Check for AltiVec and SPE.
15467 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
15468 (ppc_fill_vrregset, ppc_store_vrregset): New.
15469 (target_regsets): Add AltiVec register set.
15470 * configure: Regenerated.
15471
15472 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
15473
15474 * linux-low.c (O_LARGEFILE): Define.
15475 (linux_read_memory): Use /proc/PID/mem.
15476 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
15477 * configure, config.in: Regenerated.
15478
15479 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15480
15481 * linux-low.c (linux_wait_for_event): Do not pass signals while
15482 single-stepping.
15483
15484 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15485
15486 * win32-low.c (create_process): New.
15487 (win32_create_inferior): Use create_process instead of
15488 CreateProcess. If create_process failed retry appending an ".exe"
15489 suffix. Store the GetLastError result immediatelly after
15490 create_process calls and use it on the call to error.
15491
15492 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15493
15494 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
15495
15496 2007-08-23 Joel Brobecker <brobecker@adacore.com>
15497
15498 * configure.ac: Switch license to GPLv3.
15499
15500 2007-08-01 Michael Snyder <msnyder@access-company.com>
15501
15502 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
15503
15504 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
15505
15506 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
15507 typedef.
15508 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
15509 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
15510 CloseToolhelp32Snapshot.
15511 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
15512 CloseToolhelp32Snapshot.
15513
15514 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
15515
15516 * server.c (main): Check for inferior exit before main loop.
15517
15518 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
15519
15520 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
15521 instead of on tmp_desc.
15522
15523 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
15524 Daniel Jacobowitz <dan@codesourcery.com>
15525
15526 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
15527 (add_thread): Minor cleanups.
15528 (clear_inferiors): Move lower in the file. Clear the DLL
15529 list.
15530 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
15531 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
15532 (xml_escape_text): New.
15533 * server.c (handle_query): Handle qXfer:libraries:read. Report it
15534 for qSupported.
15535 (handle_v_cont): Report errors.
15536 (gdbserver_version): Update.
15537 (main): Correct size of own_buf. Do not report initial DLL events.
15538 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
15539 (unloaded_dll, xml_escape_text): New.
15540 * win32-low.c (enum target_waitkind): Update comments.
15541 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
15542 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
15543 (win32_EnumProcessModules, win32_GetModuleInformation)
15544 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
15545 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
15546 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
15547 (win32_Module32First, win32_Module32Next, load_toolhelp)
15548 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
15549 (get_child_debug_event): Handle DLL events.
15550 (win32_wait): Likewise.
15551
15552 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
15553
15554 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
15555 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
15556
15557 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15558
15559 * win32-low.c (handle_output_debug_string): Ignore event if not
15560 waiting.
15561
15562 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15563
15564 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
15565
15566 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
15567
15568 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
15569
15570 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
15571
15572 * inferiors.c (change_inferior_id): Add comment.
15573 * linux-low.c (check_removed_breakpoint): Add an early
15574 prototype. Improve debug output.
15575 (linux_attach): Doc update.
15576 (linux_detach_one_process, linux_detach): Clean up before releasing
15577 each process.
15578 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
15579 * linux-low.h (struct process_info): Doc improvement.
15580 * mem-break.c (delete_all_breakpoints): New.
15581 * mem-break.h (delete_all_breakpoints): New prototype.
15582 * thread-db.c (find_first_thread): New.
15583 (thread_db_create_event): Call it instead of
15584 thread_db_find_new_threads. Clean up unused variables.
15585 (maybe_attach_thread): Remove first thread handling.
15586 (thread_db_find_new_threads): Use find_first_thread.
15587 (thread_db_get_tls_address): Likewise.
15588
15589 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
15590
15591 * thread-db.c (thread_db_find_new_threads): Add prototype.
15592 (thread_db_create_event): Check for the main thread before adding
15593 a new thread.
15594 (maybe_attach_thread): Only enable event reporting if TID == 0.
15595 (thread_db_get_tls_address): Check for new threads.
15596
15597 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
15598
15599 * linux-low.c (linux_create_inferior): Try execv before execvp.
15600 * spu-low.c (spu_create_inferior): Likewise.
15601
15602 2007-06-13 Mike Frysinger <vapier@gentoo.org>
15603
15604 * linux-low.c (linux_create_inferior): Change execv to execvp.
15605 * spu-low.c (spu_create_inferior): Likewies.
15606
15607 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
15608
15609 * Makefile.in (clean): Clean new files instead of deleted ones.
15610 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
15611 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
15612 rules.
15613 * configure.srv: Specify XML files and new regformats for MIPS and
15614 MIPS64 GNU/Linux.
15615 * linux-mips-low.c (mips_num_regs): Set to only used registers.
15616 (mips_regmap): Do not fetch $0. Remove unused registers. Add
15617 an entry for the restart register.
15618 (mips_cannot_fetch_register, mips_cannot_store_register)
15619 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
15620 register names to match the XML descriptions.
15621 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
15622 restart register instead of $0.
15623
15624 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15625 Markus Deuling <deuling@de.ibm.com>
15626
15627 * remote-utils.c (decode_xfer_write): New function.
15628 * server.h (decode_xfer_write): Add prototype.
15629 * server.c (handle_query): Add PACKET_LEN argument. Support
15630 qXfer:spu:read and qXfer:spu:write packets.
15631 (main): Pass packet_len to handle_query.
15632 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
15633 * target.h (target_ops): Add qxfer_spu.
15634
15635 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15636
15637 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
15638 accessing non-seekable spufs files.
15639
15640 2007-05-16 Markus Deuling <deuling@de.ibm.com>
15641
15642 * server.c (handle_query): Add reply for qC packet.
15643
15644 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15645 Leo Zayas <lerele@champenstudios@com>
15646
15647 * server.h (check_remote_input_interrupt_request): New function.
15648 * remote_utils.c (INVALID_DESCRIPTOR): New define.
15649 (remote_desc): Initialize with INVALID_DESCRIPTOR.
15650 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
15651 (check_remote_input_interrupt_request): New function.
15652 * server.h (check_remote_input_interrupt_request): Declare.
15653 * win32-low.c (winapi_DebugBreakProcess,
15654 winapi_GenerateConsoleCtrlEvent): New typedefs.
15655 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
15656 to 250 ms.
15657 (win32_wait): Check for remote interrupt request
15658 with check_remote_input_interrupt_request.
15659 (win32_request_interrupt): New function.
15660 (win32_target_op): Set request_interrupt to win32_request_interrupt.
15661
15662 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15663
15664 * win32-low.c (debug_registers_changed,
15665 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
15666 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
15667 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
15668 (thread_rec): Get context using the low target.
15669 (child_add_thread): Call thread_added on the low target,
15670 which does the same thing.
15671 (regptr): Delete.
15672 (do_initial_child_stuff): Remove debug registers references.
15673 Set context using the low target. Resume threads after
15674 setting the contexts.
15675 (child_continue): Remove dead variable. Remove debug
15676 registers references.
15677 (child_fetch_inferior_registers): Go through the low target.
15678 (do_child_store_inferior_registers): Remove.
15679 (child_store_inferior_registers): Go through the low target.
15680 (win32_resume): Remove debug registers references.
15681 Set context using the low target.
15682 (handle_exception): Change return type to void. Don't record
15683 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
15684 first chance exception.
15685 (get_child_debug_event): Change return type to void. Remove
15686 goto loop. Always return after waiting for debug event.
15687 (win32_wait): Convert to switch statement. Handle spurious
15688 events.
15689
15690 * win32-i386-low.c (debug_registers_changed,
15691 debug_registers_used): New.
15692 (initial_stuff): Rename to ...
15693 (i386_initial_stuff): ... this. Clear debug registers
15694 state variables.
15695 (store_debug_registers): Delete.
15696 (i386_get_thread_context): New.
15697 (load_debug_registers): Delete.
15698 (i386_set_thread_context): New.
15699 (i386_thread_added): New.
15700 (single_step): Rename to ...
15701 (i386_single_step): ... this.
15702 (do_fetch_inferior_registers): Rename to ...
15703 (i386_fetch_inferior_register): ... this.
15704 (i386_store_inferior_register): New.
15705 (the_low_target): Adapt to new interface.
15706
15707 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
15708 (arm_get_thread_context): New.
15709 (arm_set_thread_context): New.
15710 (regptr): New.
15711 (do_fetch_inferior_registers): Rename to ...
15712 (arm_fetch_inferior_register): ... this.
15713 (arm_store_inferior_register): New.
15714 (arm_wince_breakpoint): Reimplement as unsigned long.
15715 (arm_wince_breakpoint_len): Define.
15716 (the_low_target): Adapt to new interface.
15717
15718 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
15719 load_debug_registers. Add get_thread_context, set_thread_context,
15720 thread_added and store_inferior_register. Rename
15721 fetch_inferior_registers to fetch_inferior_register.
15722 (regptr): Remove declaration.
15723
15724 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15725
15726 * linux-low.c (linux_detach): Change return type to int. Return 0.
15727 * spu-low.c (spu_detach): Likewise.
15728
15729 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15730
15731 * target.h (target_ops): Change return type of detach to int.
15732 Add join.
15733 (join_inferior): New.
15734 * server.c (main): Don't skip detach support on mingw32.
15735 If the inferior doesn't support detaching return error.
15736 Call join_inferior instead of using waitpid.
15737 * linux-low.c (linux_join): New.
15738 (linux_target_op): Add linux_join.
15739 * spu-low.c (spu_join): New.
15740 (spu_target_ops): Add spu_join.
15741 * win32-low.c (win32_detach): Adapt to new interface.
15742 Reopen current_process_handle before detaching. Issue a child
15743 resume before detaching.
15744 (win32_join): New.
15745 (win32_target_op): Add win32_join.
15746
15747 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15748
15749 * win32-low.c (win32-attach): Fix return value.
15750 * target.h (target_ops): Describe ATTACH return values.
15751
15752 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15753
15754 * win32-low.c (GETPROCADDRESS): Define.
15755 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
15756 (winapi_DebugSetProcessKillOnExit): Likewise.
15757 (win32_create_inferior): Force usage of ansi CreateProcessA.
15758 (win32_attach): Use GETPROCADDRESS.
15759 (win32_detach): Likewise.
15760
15761 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15762
15763 * win32-low.c (win32_wait): Don't use WSTOPSIG.
15764
15765 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
15766
15767 * win32-low.c: Commit leftover changes from 2007-03-29.
15768
15769 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15770
15771 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
15772 fields short instead of int. Add explicit padding.
15773 (i387_cache_to_fsave): Remove unnecessary casts.
15774 (i387_fsave_to_cache): Doc fix.
15775 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
15776
15777 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15778
15779 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
15780 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
15781
15782 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15783
15784 * configure.srv (arm*-*-mingw32ce*): Move near the other
15785 arm targets.
15786
15787 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15788
15789 * configure.ac: Add errno checking.
15790 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
15791 sys/file.h and malloc.h.
15792 (AC_CHECK_DECLS): Add perror.
15793 (srv_mingwce): Handle.
15794 * configure.srv (i[34567]86-*-cygwin*): Add
15795 win32-i386-low.o to srv_tgtobj.
15796 (i[34567]86-*-mingw*): Likewise.
15797 (arm*-*-mingw32ce*): Add case.
15798 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15799 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
15800 [__MINGW32CE__] (strerror): New function.
15801 [__MINGW32CE__] (errno): Define to GetLastError.
15802 [__MINGW32CE__] (COUNTOF): New macro.
15803 (remote_open): Remove extra close call.
15804 * mem-break.c (delete_breakpoint_at): New function.
15805 * mem-break.h (delete_breakpoint_at): Declare.
15806 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15807 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
15808 [USE_WIN32API] (read, write): Add char* casts.
15809 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
15810 * server.h: Include wincecompat.h on Windows CE.
15811 [HAVE_ERRNO_H]: Check.
15812 (perror): Declare if not declared.
15813 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
15814 (perror_with_name): Remove errno declaration.
15815 * wincecompat.h: New.
15816 * wincecompat.c: New.
15817 * win32-low.h: New.
15818 * win32-arm-low.c: New.
15819 * win32-i386-low.c: New.
15820 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
15821 (OUTMSG2): Make it safe.
15822 (_T): New macro.
15823 (COUNTOF): New macro.
15824 (NUM_REGS): Get it from the low target.
15825 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
15826 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
15827 (thread_rec): Let low target handle debug registers.
15828 (child_add_thread): Likewise.
15829 (child_init_thread_list): Likewise.
15830 (continue_one_thread): Likewise.
15831 (regptr): New.
15832 (do_child_fetch_inferior_registers): Move to ...
15833 * win32-i386-low.c: ... here, and rename to ...
15834 (do_fetch_inferior_registers): ... this.
15835 * win32-low.c (child_fetch_inferior_registers):
15836 Go through the low target.
15837 (do_child_store_inferior_registers): Use regptr.
15838 (strwinerror): New function.
15839 (win32_create_inferior): Handle Windows CE.
15840 Use strwinerror instead of strerror on Windows error
15841 codes. Add program to the error output.
15842 Don't close the main thread handle on Windows CE.
15843 (win32_attach): Use coredll.dll on Windows CE.
15844 (win32_kill): Close current process and current
15845 thread handles.
15846 (win32_detach): Use coredll.dll on Windows CE.
15847 (win32_resume): Let low target handle debug registers, and
15848 step request.
15849 (handle_exception): Add/Remove initial breakpoint. Avoid
15850 non-existant WSTOPSIG on Windows CE.
15851 (win32_read_inferior_memory): Cast to remove warning.
15852 (win32_arch_string): Go through the low target.
15853 (initialize_low): Call set_breakpoint_data with the low
15854 target's breakpoint.
15855 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
15856 FOP_REGNUM, mappings): Move to ...
15857 * win32-i386-low.c: ... here.
15858 * win32-low.c (win32_thread_info): Move to ...
15859 * win32-low.h: ... here.
15860 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
15861 win32-arm-low.c and wincecompat.c.
15862 (all:): Add $EXEEXT.
15863 (install-only:): Likewise.
15864 (gdbserver:): Likewise.
15865 (gdbreplay:): Likewise.
15866 * config.in: Regenerate.
15867 * configure: Regenerate.
15868
15869 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15870
15871 * win32-low.c: Rename typedef thread_info to
15872 win32_thread_info throughout.
15873
15874 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15875
15876 * win32-i386-low.c: Rename to ...
15877 * win32-low.c: ... this.
15878 * configure.srv: Replace win32-i386-low.o with win32-low.o.
15879 * Makefile.in: Likewise.
15880
15881 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
15882
15883 * remote-utils.c (monitor_output): Constify msg parameter.
15884 * server.h (monitor_output): Likewise.
15885 * win32-i386-low.c (handle_output_debug_string): New.
15886 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
15887 handle_output_debug_string.
15888 (get_child_debug_event): Likewise.
15889
15890 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
15891
15892 * server.c (main): Correct strtoul check.
15893
15894 2007-03-27 Jon Ringle <jon@ringle.org>
15895
15896 * linux-low.c: Check __ARCH_HAS_MMU__ also.
15897
15898 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
15899
15900 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
15901
15902 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
15903
15904 * terminal.h: Check HAVE_SGTTY_H.
15905
15906 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
15907
15908 * remote-utils.c (remote_open): Print out the assigned port number.
15909
15910 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
15911
15912 * remote-utils.c (monitor_output): New function.
15913 * server.c (debug_threads): Define here.
15914 (monitor_show_help): New function.
15915 (handle_query): Handle qRcmd.
15916 (main): Do not handle 'd' packet.
15917 * server.h (debug_threads, remote_debug, monitor_output): Declare.
15918 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
15919 of debug_threads.
15920
15921 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
15922
15923 * Makefile.in (EXEEXT): New.
15924 (clean): Use $(EXEEXT).
15925
15926 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
15927
15928 * target.h (target_ops): Rename send_signal to request_interrupt,
15929 and remove enum target_signal parameter.
15930 * linux-low.c (linux_request_interrupt): Rename from
15931 linux_send_signal, and always send SIGINT.
15932 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
15933 and always send SIGINT.
15934 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
15935 of send_signal.
15936 (input_interrupt): Likewise.
15937
15938 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
15939
15940 * server.c (get_features_xml): Check if target implemented
15941 arch_string.
15942 * win32-i386-low.c (win32_arch_string): New.
15943 (win32_target_ops): Add win32_arch_string as arch_string member.
15944
15945 2007-02-22 Markus Deuling <deuling@de.ibm.com>
15946
15947 * spu-low.c (spu_arch_string): New.
15948 (spu_target_ops): Add spu_arch_string.
15949
15950 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
15951
15952 * remote-utils.c: Remove HAVE_TERMINAL_H check.
15953 * configure.ac: Do not check for terminal.h.
15954 * configure, config.in: Regenerated.
15955
15956 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
15957
15958 * Makefile.in (OBS): Add $(XML_BUILTIN).
15959 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
15960 (clean): Update.
15961 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
15962 (arm-with-iwmmxt.c): New.
15963 * config.in, configure: Regenerate.
15964 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
15965 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
15966 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
15967 (arm*-*-linux*): Add iWMMXt and regset support.
15968 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
15969 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
15970 (arm_store_wmmxregset, target_regsets): New.
15971 * server.c (get_features_xml): Take annex argument. Check builtin
15972 XML documents.
15973 (handle_query): Handle multiple annexes.
15974
15975 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15976
15977 * remote-utils.c [USE_WIN32API] (read, write): Define.
15978 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
15979 write.
15980
15981 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
15982
15983 * linux-i386-low.c (the_low_target): Set arch_string.
15984 * linux-x86-64-low.c (the_low_target): Likewise.
15985 * linux-low.c (linux_arch_string): New.
15986 (linux_target_ops): Add it.
15987 * linux-low.h (struct linux_target_ops): Add arch_string.
15988 * server.c (write_qxfer_response): Use const void * for DATA.
15989 (get_features_xml): New.
15990 (handle_query): Handle qXfer:features:read. Report it for qSupported.
15991 * target.h (struct target_ops): Add arch_string method.
15992
15993 2007-01-03 Denis Pilat <denis.pilat@st.com>
15994 Daniel Jacobowitz <dan@codesourcery.com>
15995
15996 * linux-low.c (linux_kill): Handle being called with no threads.
15997 * win32-i386-low.c (win32_kill): Likewise.
15998 (get_child_debug_event): Clear current_process_handle.
15999
16000 2006-12-30 Denis PILAT <denis.pilat@st.com>
16001 Daniel Jacobowitz <dan@codesourcery.com>
16002
16003 * remote-utils.c (remote_open): Check the type of specified
16004 serial port devices before opening them.
16005 * server.c (main): Kill the inferior if an error occurs during
16006 the first remote_open.
16007
16008 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16009
16010 * README: Update supported targets.
16011
16012 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16013
16014 * Makefile.in (clean): Remove reg-mips64.c.
16015 (reg-mips64.c, reg-mips64.o): New rules.
16016 * configure.srv: Handle mips64. Include regset support for mips.
16017 * linux-mips-low.c (union mips_register): New.
16018 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16019 (mips_breakpoint, mips_breakpoint_at): Use int.
16020 (mips_collect_register, mips_supply_register)
16021 (mips_collect_register_32bit, mips_supply_register_32bit)
16022 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16023 (mips_store_fpregset, target_regsets): New.
16024 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16025
16026 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16027
16028 * configure.srv: Add target "spu*-*-*".
16029 * Makefile.in (clean): Remove reg-spu.c.
16030 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16031 * spu-low.c: New file.
16032
16033 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16034
16035 * configure.ac: Correct td_thr_tls_get_addr test.
16036 * configure: Regenerated.
16037
16038 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16039
16040 * linux-low.c (linux_wait_for_event): Reformat. Use the
16041 pass_signals array.
16042 * remote-utils.c (decode_address_to_semicolon): New.
16043 * server.c (pass_signals, handle_general_set): New.
16044 (handle_query): Mention QPassSignals for qSupported.
16045 (main): Call handle_general_set.
16046 * server.h (pass_signals, decode_address_to_semicolon): New.
16047
16048 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16049
16050 * server.c (handle_query): Correct error handling for read_auxv.
16051
16052 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16053
16054 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16055 and srv_linux_thread_db to yes.
16056 * linux-s390-low.c (s390_fill_gregset): New function.
16057 (target_regsets): Define data structure.
16058
16059 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16060
16061 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16062 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16063 * config.in, configure: Regenerated.
16064 * inferiors.c (gdb_id_to_thread): New function.
16065 (gdb_id_to_thread_id): Use it.
16066 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16067 * linux-low.h (struct process_info): Add th member.
16068 (thread_db_get_tls_address): New prototype.
16069 * remote-utils.c (decode_address): Make non-static.
16070 * server.c (handle_query): Handle qGetTLSAddr.
16071 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16072 * target.h (struct target_ops): Add get_tls_address.
16073 * thread-db.c (maybe_attach_thread): Save the thread handle.
16074 (thread_db_get_tls_address): New.
16075
16076 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16077
16078 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16079 (linux_resume_one_process): Take a siginfo_t *. Update all
16080 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16081 (struct pending_signals): Add a siginfo_t.
16082 (linux_wait_for_process): Always set last_status.
16083 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16084 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16085 * linux-low.h (struct process_info): Add last_status.
16086
16087 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16088
16089 * remote-utils.c (try_rle): New function.
16090 (putpkt_binary): Use it.
16091
16092 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16093
16094 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16095 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16096 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16097 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16098 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16099 point registers.
16100
16101 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16102
16103 * server.c (terminal_fd): New variable.
16104 (old_foreground_pgrp): Likewise.
16105 (restore_old_foreground_pgrp): New function.
16106 (start_inferior): Record the terminal file descriptor in terminal_fd
16107 and its original foreground group in old_foreground_pgrp. Register
16108 restore_old_foreground_pgrp with atexit().
16109
16110 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16111
16112 * server.c (handle_query): Correct qPart to qXfer.
16113
16114 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16115
16116 * configure.ac: Check for more headers which are missing on
16117 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16118 * configure.srv: Add Cygwin and mingw32.
16119 * remote-utils.c: Don't include headers unconditionally which
16120 are missing on mingw32. Include <winsock.h> for mingw32.
16121 (remote_open): Adjust for mingw32 support. Flush
16122 standard error after writing to it.
16123 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16124 (unblock_async_io, enable_async_io, disable_async_io)
16125 (readchar, getpkt): Update for Winsock support.
16126 (prepare_resume_reply): Expect a protocol signal number.
16127 * server.c: Disable <sys/wait.h> on mingw32.
16128 (start_inferior): Adjust for mingw32 support. Flush
16129 standard error after writing to it.
16130 (attach_inferior): Likewise. Use protocol signal
16131 numbers.
16132 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16133 and names.
16134 * win32-i386-low.c: New file.
16135 * Makefile.in (XM_CLIBS): Set.
16136 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16137 (win32-i386-low.o): New dependency rule.
16138 * linux-low.c (linux_wait): Use target signal numbers.
16139 * target.h (struct target_ops): Doc fix.
16140 * server.h (target_signal_to_name): New prototype.
16141 * gdbreplay.c: Don't include headers unconditionally which
16142 are missing on mingw32. Include <winsock.h> for mingw32.
16143 (remote_close, remote_open): Adjust for Winsock support.
16144 * configure, config.in: Regenerated.
16145
16146 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16147
16148 * server.c (decode_xfer_read, write_qxfer_response): New.
16149 (handle_query): Take a packet length argument. Handle
16150 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16151 the qSupported response.
16152 (main): Update call to handle_query.
16153
16154 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16155
16156 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16157 (putpkt_binary): Renamed from putpkt and adjusted for binary
16158 data.
16159 (putpkt): New wrapper for putpkt_binary.
16160 (readchar): Don't mask off the high bit.
16161 (decode_X_packet): New function.
16162 * server.c (main): Call putpkt_binary if a handler sets the packet
16163 length. Save the length of the incoming packet. Handle 'X'.
16164 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16165
16166 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16167
16168 * server.c (handle_query): Handle qSupported.
16169
16170 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16171
16172 * remote-utils.c (all_symbols_looked_up): New variable.
16173 (look_up_one_symbol): Check it.
16174 * server.h (look_up_one_symbol): New declaration.
16175 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16176
16177 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16178
16179 * Makefile.in (linux-arm-low.o): Update dependencies.
16180 * linux-arm-low.c: Include "gdb_proc_service.h".
16181 (PTRACE_GET_THREAD_AREA): Define.
16182 (ps_get_thread_area): New function.
16183
16184 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16185
16186 * configure.srv (m68k*-*-uclinux*): New target.
16187 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16188 (linux_resume_one_process): Remove extraneous cast.
16189 (linux_read_offsets): New.
16190 (linux_target_op): Add linux_read_offsets on mmuless systems.
16191 * server.c (handle_query): Add qOffsets logic.
16192 * target.h (struct target_ops): Add read_offsets.
16193
16194 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16195
16196 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16197 (PTRACE_GET_THREAD_AREA): Define.
16198 (ps_get_thread_area): New function.
16199 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16200 (linux-x86-64-low.o): Update.
16201
16202 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16203
16204 * configure.ac: Remove checks for prfpregset_t.
16205 * gdb_proc_service.h: New file.
16206 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16207 new "gdb_proc_service.h".
16208 * proc-service.c: Likewise.
16209 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16210 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16211 * Makefile.in (gdb_proc_service_h): Updated.
16212 * configure, config.in: Regenerated.
16213
16214 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16215
16216 * remote-utils.c (prepare_resume_reply): Move declaration
16217 of gdb_id_from_wait to the top of the block.
16218
16219 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16220
16221 * linux-low.c (regsets_store_inferior_registers): Read the regset
16222 from the target before filling it.
16223
16224 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16225
16226 * server.c (attach_inferior): Return SIGTRAP for a successful
16227 attach.
16228
16229 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16230
16231 * Makefile.in (OBS): Add version.o.
16232 (STAGESTUFF): Delete.
16233 (version.o): Add dependencies.
16234 (version.c): Replace rule.
16235 (clean): Remove version.c.
16236 * server.c (gdbserver_version): New.
16237 (gdbserver_usage): Use printf.
16238 (main): Handle --version and --help.
16239 * server.h (version, host_name): Add declarations.
16240
16241 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16242
16243 * linux-arm-low.c:
16244 * linux-arm-low.c:
16245 * inferiors.c:
16246 * i387-fp.h:
16247 * i387-fp.c:
16248 * gdbreplay.c:
16249 * regcache.c:
16250 * proc-service.c:
16251 * mem-break.h:
16252 * mem-break.c:
16253 * linux-x86-64-low.c:
16254 * linux-sh-low.c:
16255 * linux-s390-low.c:
16256 * linux-ppc64-low.c:
16257 * linux-ppc-low.c:
16258 * linux-mips-low.c:
16259 * linux-m68k-low.c:
16260 * linux-m32r-low.c:
16261 * linux-low.h:
16262 * linux-low.c:
16263 * linux-ia64-low.c:
16264 * linux-i386-low.c:
16265 * linux-crisv32-low.c:
16266 * thread-db.c:
16267 * terminal.h:
16268 * target.h:
16269 * target.c:
16270 * server.h:
16271 * server.c:
16272 * remote-utils.c:
16273 * regcache.h:
16274 * utils.c:
16275 * Makefile.in:
16276 * configure.ac:
16277 * gdbserver.1: Add (C) after Copyright. Update the FSF
16278 address.
16279
16280 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16281
16282 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16283 (arm_breakpoint_at): Recognize both breakpoints.
16284 (the_low_target): Use the correct breakpoint instruction.
16285
16286 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16287
16288 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16289 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16290 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16291 (the_low_target): Update.
16292
16293 2005-10-25 Andreas Schwab <schwab@suse.de>
16294
16295 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16296
16297 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16298 (ia64_num_regs): Reduce to 462.
16299
16300 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16301
16302 * acinclude.m4: Correct quoting.
16303 * aclocal.m4: Regenerated.
16304
16305 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16306 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16307 (thread_db_init): Call thread_db_err_str.
16308 * configure.ac: Check for TD_VERSION.
16309 * config.in, configure: Regenerated.
16310
16311 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16312
16313 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16314
16315 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16316
16317 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16318 is not available. Define HAVE_PTRACE_GETREGS if it is.
16319 * config.in, configure: Regenerated.
16320 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16321 * linux-i386-low.c, linux-m68k-low.c: Update to use
16322 HAVE_PTRACE_GETREGS.
16323 * linux-low.c (regsets_fetch_inferior_registers)
16324 (regsets_store_inferior_registers): Only return 0 if we processed
16325 GENERAL_REGS.
16326 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16327 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16328
16329 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16330
16331 * inferiors.c (struct thread_info): Add gdb_id.
16332 (add_thread): Add gdb_id argument.
16333 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16334 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16335 calls to add_thread.
16336 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16337 * server.c (handle_query): Use thread_to_gdb_id.
16338 (handle_v_cont, main): Use gdb_id_to_thread_id.
16339 * server.h (add_thread): Update prototype.
16340 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16341 prototypes.
16342
16343 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16344
16345 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16346 left-padded registers.
16347 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16348 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16349
16350 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16351
16352 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16353 * configure: Regenerate.
16354 * config.in: Regenerate.
16355 * server.h (NEED_DECLARATION_STRERROR):
16356 Replace with !HAVE_DECL_STRERROR.
16357
16358 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16359
16360 * linux-low.c (linux_wait, linux_send_signal): Don't test
16361 an unsigned long variable for > 0 if it could be MAX_ULONG.
16362 * server.c (myresume): Likewise.
16363 * target.c (set_desired_inferior): Likewise.
16364
16365 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16366
16367 * configure.ac: Simplify and improve check for socklen_t.
16368 * configure, config.in: Regenerate.
16369
16370 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16371
16372 * acconfig.h: Remove.
16373 * configure.ac: Add a test for socklen_t. Use three-argument
16374 AC_DEFINE throughout.
16375 * config.in: Regenerated using autoheader 2.59.
16376 * configure: Regenerated.
16377
16378 * gdbreplay.c (socklen_t): Provide a default.
16379 (remote_open): Use socklen_t.
16380 * remote-utils.c (socklen_t): Provide a default.
16381 (remote_open): Use socklen_t.
16382 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16383 unsigned char.
16384
16385 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16386 char for buffers.
16387 * linux-low.c (linux_read_memory, linux_write_memory)
16388 (linux_read_auxv): Likewise.
16389 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16390 (check_mem_write): Likewise.
16391 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16392 Likewise.
16393 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16394 (registers_from_string, register_data): Likewise.
16395 * server.c (handle_query, main): Likewise.
16396 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16397 (decode_M_packet): Likewise.
16398 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16399 * target.h (struct target_ops): Update read_memory, write_memory,
16400 and read_auxv.
16401 (read_inferior_memory, write_inferior_memory): Update.
16402 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16403 to unsigned char *.
16404 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16405 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16406 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16407 linux-s390-low.c, linux-sh-low.c: Update for changes in
16408 read_inferior_memory and the_low_target->breakpoint.
16409
16410 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16411
16412 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16413 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16414 * configure.srv: Add powerpc64-*-linux*.
16415 * linux-ppc64-low.c: New file.
16416
16417 2005-05-23 Orjan Friberg <orjanf@axis.com>
16418
16419 * linux-cris-low.c: New file with support for CRIS.
16420 * linux-crisv32-low.c: Ditto for CRISv32.
16421 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16422 (clean): Add reg-cris.c and reg-crisv32.c.
16423 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16424 reg-crisv32.o, and reg-crisv32.c to make rules.
16425 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16426 recognized targets.
16427
16428 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16429
16430 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16431 of sizeof (PTRACE_XFER_TYPE).
16432 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16433
16434 2005-05-12 Orjan Friberg <orjanf@axis.com>
16435
16436 * target.h (struct target_ops): Add insert_watchpoint,
16437 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16438 pointers for hardware watchpoint support.
16439 * linux-low.h (struct linux_target_ops): Ditto.
16440 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16441 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16442 to linux_target_ops.
16443 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16444 reply packet.
16445 * server.c (main): Recognize 'Z' and 'z' packets.
16446
16447 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16448
16449 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16450 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16451 (the_low_target): Add new members.
16452
16453 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16454
16455 * proc-service.c (ps_lgetregs): Search all_processes instead of
16456 all_threads.
16457
16458 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16459
16460 * server.c (start_inferior): Change return type to int.
16461 (attach_inferior): Change sigptr to int *.
16462 (handle_v_cont, handle_v_requests): Change signal to int *.
16463 (main): Change signal to int.
16464
16465 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16466
16467 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
16468 * configure.srv: Add m32r*-*-linux*.
16469 * linux-m32r-low.c: New file.
16470
16471 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
16472
16473 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
16474
16475 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16476
16477 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
16478 Take unsigned long arguments for PIDs.
16479 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
16480 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
16481 (wait_for_sigstop, linux_resume_one_process)
16482 (regsets_fetch_inferior_registers, linux_send_signal)
16483 (linux_read_auxv): Likewise. Update the types of variables holding
16484 PIDs. Update format string specifiers.
16485 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
16486 * remote-utils.c (prepare_resume_reply): Likewise.
16487 * server.c (cont_thread, general_thread, step_thread)
16488 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
16489 unsigned long.
16490 (handle_query): Update format specifiers.
16491 (handle_v_cont, main): Use strtoul for thread IDs.
16492 * server.h (struct inferior_list_entry): Use unsigned long for ID.
16493 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
16494 (general_thread, step_thread, thread_from_wait)
16495 (old_thread_from_wait): Update.
16496 * target.h (struct thread_resume): Use unsigned long for THREAD.
16497 (struct target_ops): Use unsigned long for arguments to attach and
16498 thread_alive.
16499
16500 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
16501
16502 * acinclude.m4: Include bfd/bfd.m4 directly.
16503 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
16504 <agriffis@toolchain.org>.
16505 * aclocal.m4, configure: Regenerated.
16506
16507 2005-01-07 Andrew Cagney <cagney@gnu.org>
16508
16509 * configure.ac: Rename configure.in, require autoconf 2.59.
16510 * configure: Re-generate.
16511
16512 2004-12-08 Daniel Jacobowitz <dan@debian.org>
16513
16514 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
16515 LIBS when finished.
16516 * aclocal.m4: Regenerated.
16517 * configure: Regenerated.
16518
16519 2004-11-21 Andreas Schwab <schwab@suse.de>
16520
16521 * linux-m68k-low.c (m68k_num_gregs): Define.
16522 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
16523 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
16524 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
16525 (m68k_breakpoint_at): New. Add to the_low_target.
16526
16527 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
16528 srv_linux_thread_db to yes.
16529
16530 2004-10-20 Joel Brobecker <brobecker@gnat.com>
16531
16532 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
16533 (ARCH_SET_FS): Likewise.
16534 (ARCH_GET_FS): Likewise.
16535 (ARCH_GET_GS): Likewise.
16536
16537 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16538
16539 * linux-i386-low.c (ps_get_thread_area): New.
16540 * linux-x86-64-low.c (ps_get_thread_area): New.
16541 * linux-low.c: Include <sys/syscall.h>.
16542 (linux_kill_one_process): Don't kill the first thread here.
16543 (linux_kill): Kill the first thread here.
16544 (kill_lwp): New function.
16545 (send_sigstop, linux_send_signal): Use it.
16546 * proc-service.c: Clean up #ifdefs.
16547 (fpregset_info): Delete.
16548 (ps_lgetregs): Update and enable implementation.
16549 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
16550 implementations.
16551 * remote-utils.c (struct sym_cache, symbol_cache): New.
16552 (input_interrupt): Print a clearer message.
16553 (async_io_enabled): New variable.
16554 (enable_async_io, disable_async_io): Use it. Update comments.
16555 (look_up_one_symbol): Use the symbol cache.
16556 * thread-db.c (thread_db_look_up_symbols): New function.
16557 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
16558
16559 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16560
16561 * configure.in: Test for -rdynamic.
16562 * configure: Regenerated.
16563 * Makefile (INTERNAL_LDFLAGS): New.
16564 (gdbserver, gdbreplay): Use it.
16565
16566 2004-09-02 Andrew Cagney <cagney@gnu.org>
16567
16568 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
16569
16570 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
16571
16572 * linux-low.c (linux_wait): Clear all_processes list also.
16573
16574 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16575
16576 * linux-low.c: Include <errno.h>. Remove extern declaration of
16577 errno.
16578
16579 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16580
16581 * gdbreplay.c, server.h, utils.c: Update copyright years.
16582
16583 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16584
16585 * server.c (main): Print child status or termination signal from
16586 variable 'signal', not 'sig'.
16587
16588 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16589
16590 * linux-low.c (linux_read_memory): Change return type to
16591 int. Check for and return error from ptrace().
16592 * target.c (read_inferior_memory): Change return type to int. Pass
16593 back return status from the_target->read_memory().
16594 * target.h (struct target_ops): Adapt *read_memory() prototype.
16595 Update comment.
16596 (read_inferior_memory): Adapt prototype.
16597 * server.c (main): Return an error packet if
16598 read_inferior_memory() returns an error.
16599
16600 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
16601
16602 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
16603 Unify with other clean targets.
16604
16605 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16606
16607 * server.c (handle_v_cont): Call set_desired_inferior.
16608
16609 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16610
16611 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
16612
16613 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16614
16615 * linux-low.c (linux_wait): Unblock async I/O.
16616 (linux_resume): Block and enable async I/O.
16617 * remote-utils.c (block_async_io, unblock_async_io): New functions.
16618 * server.h (block_async_io, unblock_async_io): Add prototypes.
16619
16620 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16621
16622 * remote-utils.c (remote_open): Print a status notice after
16623 opening a TCP port.
16624 * server.c (attach_inferior): Print a status notice after
16625 attaching.
16626
16627 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16628
16629 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
16630
16631 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
16632
16633 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
16634 error packet.
16635 * server.c, target.h: Update copyright years.
16636
16637 2004-02-25 Roland McGrath <roland@redhat.com>
16638
16639 * target.h (struct target_ops): New member `read_auxv'.
16640 * server.c (handle_query): Handle qPart:auxv:read: query using that.
16641 * linux-low.c (linux_read_auxv): New function.
16642 (linux_target_ops): Initialize `read_auxv' member to that.
16643
16644 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
16645
16646 Committed by Jim Blandy <jimb@redhat.com>.
16647
16648 * linux-s390-low.c (s390_num_regs): Update.
16649 (s390_regmap): Remove control registers. Use __s390x__ predefine
16650 instead of GPR_SIZE to distiguish s390 and s390x targets.
16651
16652 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
16653
16654 * linux-low.c: Update copyright year.
16655 (check_removed_breakpoint): Clear pending_is_breakpoint.
16656 (linux_set_resume_request, linux_queue_one_thread)
16657 (resume_status_pending_p): New functions.
16658 (linux_continue_one_thread): Use process->resume.
16659 (linux_resume): Only resume threads if there are no pending events.
16660 * linux-low.h (struct process_info): Add resume request
16661 pointer.
16662
16663 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
16664
16665 * regcache.c (new_register_cache): Clear the allocated register
16666 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
16667
16668 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
16669
16670 * linux-low.c (linux_resume): Take a struct thread_resume *
16671 argument.
16672 (linux_wait): Update call.
16673 (resume_ptr): New static variable.
16674 (linux_continue_one_thread): Renamed from
16675 linux_continue_one_process. Use resume_ptr.
16676 (linux_resume): Use linux_continue_one_thread.
16677 * server.c (handle_v_cont, handle_v_requests): New functions.
16678 (myresume): New function.
16679 (main): Handle 'v' case.
16680 * target.h (struct thread_resume): New type.
16681 (struct target_ops): Change argument of "resume" to struct
16682 thread_resume *.
16683 (myresume): Delete macro.
16684
16685 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
16686
16687 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
16688 (uninstall): Support DESTDIR.
16689
16690 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
16691
16692 * configure.srv: Add xscale*linux copy of arm*linux entry.
16693
16694 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
16695
16696 * linux-arm-low.c (arm_reinsert_addr): New function.
16697 (the_low_target): Add arm_reinsert_addr.
16698
16699 2003-07-08 Mark Kettenis <kettenis@gnu.org>
16700
16701 * mem-break.c: Remove whitespace at end of file.
16702
16703 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
16704
16705 * configure.in: Check whether we need to prototype strerror.
16706 * server.h: Optionally prototype strerror.
16707 * gdbreplay.c (perror_with_name): Use strerror.
16708 * linux-low.c (linux_attach_lwp): Use strerror.
16709 * utils.c (perror_with_name): Use strerror.
16710 * config.in, configure: Regenerated.
16711
16712 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
16713
16714 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
16715 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
16716
16717 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
16718
16719 * Makefile.in (SFILES): Update.
16720 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
16721 low-sun3.c: Remove files.
16722
16723 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
16724
16725 * linux-low.c: Move comment to linux_thread_alive where it belonged.
16726 (linux_detach_one_process, linux_detach): New functions.
16727 (linux_target_ops): Add linux_detach.
16728 * server.c (main): Handle 'D' packet.
16729 * target.h (struct target_ops): Add "detach" member.
16730 (detach_inferior): Define.
16731
16732 2003-06-13 Mark Kettenis <kettenis@gnu.org>
16733
16734 From Kelley Cook <kelleycook@wideopenwest.com>:
16735 * configure.srv: Accept i[34567]86 variants.
16736
16737 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
16738
16739 * linux-low.c (linux_wait_for_event): Correct comment typos.
16740 (linux_resume_one_process): Call check_removed_breakpoint.
16741 (linux_send_signal): New function.
16742 (linux_target_ops): Add linux_send_signal.
16743 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
16744 of kill.
16745 * target.h (struct target_ops): Add send_signal.
16746
16747 2003-05-29 Jim Blandy <jimb@redhat.com>
16748
16749 * linux-low.c (usr_store_inferior_registers): Transfer buf in
16750 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
16751 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
16752 away part of the register's value.
16753
16754 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
16755
16756 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
16757 (linux_wait_for_event, linux_init_signals): Likewise.
16758
16759 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
16760
16761 * configure.in: Check for stdlib.h.
16762 * configure: Regenerated.
16763 * config.in: Regenerated.
16764
16765 2003-01-04 Andreas Schwab <schwab@suse.de>
16766
16767 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
16768
16769 2003-01-02 Andrew Cagney <ac131313@redhat.com>
16770
16771 * Makefile.in: Remove obsolete code.
16772
16773 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
16774
16775 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
16776 defined(PT_FPR0_HI).
16777
16778 2002-11-17 Stuart Hughes <seh@zee2.com>
16779
16780 * linux-arm-low.c (arm_num_regs): Increase.
16781 (arm_regmap): Include status register.
16782
16783 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
16784
16785 * linux-low.c (register_addr): Remove incorrect -1 check.
16786
16787 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
16788
16789 * linux-low.c (linux_create_inferior): Call setpgid. Return
16790 the new PID.
16791 (unstopped_p, linux_signal_pid): Remove.
16792 (linux_target_ops): Remove linux_signal_pid.
16793 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
16794 global instead of target method.
16795 * target.h (struct target_ops): Remove signal_pid. Update comment
16796 for create_inferior.
16797 * server.c (signal_pid): New variable.
16798 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
16799 gdbserver. Set the child to be the foreground process group.
16800 (attach_inferior): Set signal_pid.
16801
16802 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
16803
16804 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
16805
16806 2002-08-20 Jim Blandy <jimb@redhat.com>
16807
16808 * Makefile.in (LDFLAGS): Allow the configure script to establish a
16809 default for this.
16810
16811 2002-08-01 Andrew Cagney <cagney@redhat.com>
16812
16813 * Makefile.in: Make chill references obsolete.
16814
16815 2002-07-24 Kevin Buettner <kevinb@redhat.com>
16816
16817 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
16818 * configure: Regenerate.
16819 * config.in: Regenerate.
16820
16821 2002-07-09 David O'Brien <obrien@FreeBSD.org>
16822
16823 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
16824 (perror_with_name, remote_close, remote_open, expect, play): Static.
16825
16826 2002-07-04 Michal Ludvig <mludvig@suse.cz>
16827
16828 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
16829 byte offsets instead of an array of indexes.
16830 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
16831
16832 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
16833
16834 * regcache.c: Add comment.
16835
16836 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
16837
16838 * thread-db.c: New file.
16839 * proc-service.c: New file.
16840 * acinclude.m4: New file.
16841 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
16842 proc-service.o, and thread-db.o.
16843 (linux-low.o): Add USE_THREAD_DB.
16844 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
16845 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
16846 * aclocal.m4: Regenerated.
16847 * config.in: Regenerated.
16848 * configure: Regenerated.
16849 * configure.in: Check for proc_service.h, sys/procfs.h,
16850 thread_db.h, and linux/elf.h headrs.
16851 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
16852 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
16853 Check for -lthread_db and thread support.
16854 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
16855 PowerPC, and SuperH.
16856 * i387-fp.c: Constify arguments.
16857 * i387-fp.h: Likewise.
16858 * inferiors.c: (struct thread_info): Renamed from
16859 `struct inferior_info'. Remove PID member. Use generic inferior
16860 list header. All uses updated.
16861 (inferiors, signal_pid): Removed.
16862 (all_threads): New variable.
16863 (get_thread): Define.
16864 (add_inferior_to_list): New function.
16865 (for_each_inferior): New function.
16866 (change_inferior_id): New function.
16867 (add_inferior): Removed.
16868 (remove_inferior): New function.
16869 (add_thread): New function.
16870 (free_one_thread): New function.
16871 (remove_thread): New function.
16872 (clear_inferiors): Use for_each_inferior and free_one_thread.
16873 (find_inferior): New function.
16874 (find_inferior_id): New function.
16875 (inferior_target_data): Update argument type.
16876 (set_inferior_target_data): Likewise.
16877 (inferior_regcache_data): Likewise.
16878 (set_inferior_regcache_data): Likewise.
16879 * linux-low.c (linux_bp_reinsert): Remove.
16880 (all_processes, stopping_threads, using_thrads)
16881 (struct pending_signals, debug_threads, pid_of): New.
16882 (inferior_pid): Replace with macro.
16883 (struct inferior_linux_data): Remove.
16884 (get_stop_pc, add_process): New functions.
16885 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
16886 Use add_process and add_thread.
16887 (linux_attach_lwp): New function, based on old linux_attach. Use
16888 add_process and add_thread. Set stop_expected for new threads.
16889 (linux_attach): New function.
16890 (linux_kill_one_process): New function.
16891 (linux_kill): Kill all LWPs.
16892 (linux_thread_alive): Use find_inferior_id.
16893 (check_removed_breakpoints, status_pending_p): New functions.
16894 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
16895 Update. Use WNOHANG. Wait for cloned processes also. Update process
16896 struct for the found process.
16897 (linux_wait_for_event): New function.
16898 (linux_wait): Use it. Support LWPs.
16899 (send_sigstop, wait_for_sigstop, stop_all_processes)
16900 (linux_resume_one_process, linux_continue_one_process): New functions.
16901 (linux_resume): Support LWPs.
16902 (REGISTER_RAW_SIZE): Remove.
16903 (fetch_register): Use register_size instead. Call supply_register.
16904 (usr_store_inferior_registers): Likewise. Call collect_register.
16905 Fix recursive case.
16906 (regsets_fetch_inferior_registers): Improve error message.
16907 (regsets_store_inferior_registers): Add debugging.
16908 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
16909 (unstopped_p, linux_signal_pid): New functions.
16910 (linux_target_ops): Add linux_signal_pid.
16911 (linux_init_signals): New function.
16912 (initialize_low): Call it. Initialize using_threads.
16913 * regcache.c (inferior_regcache_data): Add valid
16914 flag.
16915 (get_regcache): Fetch registers lazily. Add fetch argument
16916 and update all callers.
16917 (regcache_invalidate_one, regcache_invalidate): New
16918 functions.
16919 (new_register_cache): Renamed from create_register_cache.
16920 Return the new regcache.
16921 (free_register_cache): Change argument to a void *.
16922 (registers_to_string, registers_from_string): Call get_regcache
16923 with fetch flag set.
16924 (register_data): Make static. Pass fetch flag to get_regcache.
16925 (supply_register): Call get_regcache with fetch flag clear.
16926 (collect_register): Call get_regcache with fetch flag set.
16927 (collect_register_as_string): New function.
16928 * regcache.h: Update.
16929 * remote-utils.c (putpkt): Flush after debug output and use
16930 stderr.
16931 Handle input interrupts while waiting for an ACK.
16932 (input_interrupt): Use signal_pid method.
16933 (getpkt): Flush after debug output and use stderr.
16934 (outreg): Use collect_register_as_string.
16935 (new_thread_notify, dead_thread_notify): New functions.
16936 (prepare_resume_reply): Check using_threads. Set thread_from_wait
16937 and general_thread.
16938 (look_up_one_symbol): Flush after debug output.
16939 * server.c (step_thread, server_waiting): New variables.
16940 (start_inferior): Don't use signal_pid. Update call to mywait.
16941 (attach_inferior): Update call to mywait.
16942 (handle_query): Handle qfThreadInfo and qsThreadInfo.
16943 (main): Don't fetch/store registers explicitly. Use
16944 set_desired_inferior. Support proposed ``Hs'' packet. Update
16945 calls to mywait.
16946 * server.h: Update.
16947 (struct inferior_list, struct_inferior_list_entry): New.
16948 * target.c (set_desired_inferior): New.
16949 (write_inferior_memory): Constify.
16950 (mywait): New function.
16951 * target.h: Update.
16952 (struct target_ops): New signal_pid method.
16953 (mywait): Removed macro, added prototype.
16954
16955 * linux-low.h (regset_func): Removed.
16956 (regset_fill_func, regset_store_func): New.
16957 (enum regset_type): New.
16958 (struct regset_info): Add type field. Use new operation types.
16959 (struct linux_target_ops): stop_pc renamed to get_pc.
16960 Add decr_pc_after_break and breakpoint_at.
16961 (get_process, get_thread_proess, get_process_thread)
16962 (strut process_info, all_processes, linux_attach_lwp)
16963 (thread_db_init): New.
16964
16965 * linux-arm-low.c (arm_get_pc, arm_set_pc,
16966 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
16967 (the_low_target): Add new members.
16968 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
16969 (i386_store_fpxregset): Constify.
16970 (target_regsets): Add new kind identifier.
16971 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
16972 (i386_set_pc): Add debugging.
16973 (i386_breakpoint_at): New function.
16974 (the_low_target): Add new members.
16975 * linux-mips-low.c (mips_get_pc, mips_set_pc)
16976 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
16977 (mips_breakpoint_at): New.
16978 (the_low_target): Add new members.
16979 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
16980 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
16981 (the_low_target): Add new members.
16982 * linux-sh-low.c (sh_get_pc, sh_set_pc)
16983 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
16984 (the_low_target): Add new members.
16985 * linux-x86-64-low.c (target_regsets): Add new kind
16986 identifier.
16987
16988 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
16989
16990 From Martin Pool <mbp@samba.org>:
16991 * server.c (gdbserver_usage): New function.
16992 (main): Call it.
16993
16994 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
16995
16996 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
16997 stop_at -> stop_pc.
16998
16999 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17000
17001 * Makefile.in: Remove obsolete code.
17002
17003 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17004
17005 * linux-low.c (regsets_fetch_inferior_registers),
17006 (regsets_store_inferior_registers): Removed cast to int from
17007 ptrace() calls.
17008 * regcache.h: Added declaration of struct inferior_info.
17009
17010 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17011
17012 * inferiors.c (struct inferior_info): Add regcache_data.
17013 (add_inferior): Call create_register_cache.
17014 (clear_inferiors): Call free_register_cache.
17015 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17016 * regcache.c (struct inferior_regcache_data): New.
17017 (registers): Remove.
17018 (get_regcache): New function.
17019 (create_register_cache, free_register_cache): New functions.
17020 (set_register_cache): Don't initialize the register cache here.
17021 (registers_to_string, registers_from_string, register_data): Call
17022 get_regcache.
17023 * regcache.h: Add prototypes.
17024 * server.h: Likewise.
17025
17026 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17027
17028 * mem-break.c: New file.
17029 * mem-break.h: New file.
17030 * Makefile.in: Add mem-break.o rule; update server.h
17031 dependencies.
17032 * inferiors.c (struct inferior_info): Add target_data
17033 member.
17034 (clear_inferiors): Free target_data member if set.
17035 (inferior_target_data, set_inferior_target_data): New functions.
17036 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17037 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17038 * linux-low.c (linux_bp_reinsert): New variable.
17039 (struct inferior_linux_data): New.
17040 (linux_create_inferior): Use set_inferior_target_data.
17041 (linux_attach): Likewise. Call add_inferior.
17042 (linux_wait_for_one_inferior): New function.
17043 (linux_wait): Call it.
17044 (linux_write_memory): Add const.
17045 (initialize_low): Call set_breakpoint_data.
17046 * linux-low.h (struct linux_target_ops): Add breakpoint
17047 handling members.
17048 * server.c (attach_inferior): Remove extra add_inferior
17049 call.
17050 * server.h: Include mem-break.h. Update inferior.c
17051 prototypes.
17052 * target.c (read_inferior_memory)
17053 (write_inferior_memory): New functions.
17054 * target.h (read_inferior_memory)
17055 (write_inferior_memory): Change macros to prototypes.
17056 (struct target_ops): Update comments. Add const to write_memory
17057 definition.
17058
17059 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17060
17061 * linux-low.c (usr_store_inferior_registers): Support
17062 registers which are allowed to fail to store.
17063 * linux-low.h (linux_target_ops): Likewise.
17064 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17065 (ppc_cannot_store_register): FPSCR may not be storable.
17066
17067 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17068
17069 * server.h: Include <string.h> if HAVE_STRING_H.
17070 * ChangeLog: Correct paths in last ChangeLog entry.
17071
17072 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17073
17074 * linux-low.h: Remove obsolete prototypes.
17075 (struct linux_target_ops): New.
17076 (extern the_low_target): New.
17077 * linux-low.c (num_regs, regmap): Remove declarations.
17078 (register_addr): Use the_low_target explicitly.
17079 (fetch_register): Likewise.
17080 (usr_fetch_inferior_registers): Likewise.
17081 (usr_store_inferior_registers): Likewise.
17082 * linux-arm-low.c (num_regs): Remove.
17083 (arm_num_regs): Define.
17084 (arm_regmap): Renamed from regmap, made static.
17085 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17086 made static.
17087 (arm_cannot_store_register): Renamed from cannot_store_register,
17088 made static.
17089 (the_low_target): New.
17090 * linux-i386-low.c (num_regs): Remove.
17091 (i386_num_regs): Define.
17092 (i386_regmap): Renamed from regmap, made static.
17093 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17094 made static.
17095 (i386_cannot_store_register): Renamed from cannot_store_register,
17096 made static.
17097 (the_low_target): New.
17098 * linux-ia64-low.c (num_regs): Remove.
17099 (ia64_num_regs): Define.
17100 (ia64_regmap): Renamed from regmap, made static.
17101 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17102 made static.
17103 (ia64_cannot_store_register): Renamed from cannot_store_register,
17104 made static.
17105 (the_low_target): New.
17106 * linux-m68k-low.c (num_regs): Remove.
17107 (m68k_num_regs): Define.
17108 (m68k_regmap): Renamed from regmap, made static.
17109 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17110 made static.
17111 (m68k_cannot_store_register): Renamed from cannot_store_register,
17112 made static.
17113 (the_low_target): New.
17114 * linux-mips-low.c (num_regs): Remove.
17115 (mips_num_regs): Define.
17116 (mips_regmap): Renamed from regmap, made static.
17117 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17118 made static.
17119 (mips_cannot_store_register): Renamed from cannot_store_register,
17120 made static.
17121 (the_low_target): New.
17122 * linux-ppc-low.c (num_regs): Remove.
17123 (ppc_num_regs): Define.
17124 (ppc_regmap): Renamed from regmap, made static.
17125 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17126 made static.
17127 (ppc_cannot_store_register): Renamed from cannot_store_register,
17128 made static.
17129 (the_low_target): New.
17130 * linux-s390-low.c (num_regs): Remove.
17131 (s390_num_regs): Define.
17132 (s390_regmap): Renamed from regmap, made static.
17133 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17134 made static.
17135 (s390_cannot_store_register): Renamed from cannot_store_register,
17136 made static.
17137 (the_low_target): New.
17138 * linux-sh-low.c (num_regs): Remove.
17139 (sh_num_regs): Define.
17140 (sh_regmap): Renamed from regmap, made static.
17141 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17142 made static.
17143 (sh_cannot_store_register): Renamed from cannot_store_register,
17144 made static.
17145 (the_low_target): New.
17146 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17147 (the_low_target): New.
17148
17149 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17150
17151 * Makefile.in: Add stamp-h target.
17152 * configure.in: Create stamp-h.
17153 * configure: Regenerated.
17154
17155 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17156
17157 * inferiors.c: New file.
17158 * target.c: New file.
17159 * target.h: New file.
17160 * Makefile.in: Add target.o and inferiors.o. Update
17161 dependencies.
17162 * linux-low.c (inferior_pid): New static variable,
17163 moved from server.c.
17164 (linux_create_inferior): Renamed from create_inferior.
17165 Call add_inferior. Return 0 on success instead of a PID.
17166 (linux_attach): Renamed from myattach.
17167 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17168 (linux_thread_alive): Renamed from mythread_alive.
17169 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17170 child dies.
17171 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17172 (regsets_store_inferior_registers): Correct error message.
17173 Add missing ``return 0''.
17174 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17175 (linux_store_registers): Renamed from store_inferior_registers.
17176 (linux_read_memory): Renamed from read_inferior_memory.
17177 (linux_write_memory): Renamed from write_inferior_memory.
17178 (linux_target_ops): New structure.
17179 (initialize_low): Call set_target_ops ().
17180 * remote-utils.c (unhexify): New function.
17181 (hexify): New function.
17182 (input_interrupt): Send signals to ``signal_pid''.
17183 * server.c (inferior_pid): Remove.
17184 (start_inferior): Update create_inferior call.
17185 (attach_inferior): Call add_inferior.
17186 (handle_query): New function.
17187 (main): Call handle_query for `q' packets.
17188 * server.h: Include "target.h". Remove obsolete prototypes.
17189 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17190
17191 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17192
17193 * Makefile.in: Add WARN_CFLAGS. Update configury
17194 dependencies.
17195 * configure.in: Check for <string.h>
17196 * configure: Regenerate.
17197 * config.in: Regenerate.
17198 * gdbreplay.c: Include needed system headers.
17199 (remote_open): Remove strchr prototype.
17200 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17201 * regcache.c (supply_register): Change buf argument to const void *.
17202 (supply_register_by_name): Likewise.
17203 (collect_register): Change buf argument to void *.
17204 (collect_register_by_name): Likewise.
17205 * regcache.h: Add missing prototypes.
17206 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17207 * server.c (handle_query): New function.
17208 (attached): New static variable, moved out of main.
17209 (main): Quiet longjmp clobber warnings.
17210 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17211 * utils.c (error): Remove NORETURN.
17212 (fatal): Likewise.
This page took 0.403503 seconds and 5 git commands to generate.