Make exceptions use std::string and be self-managing
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-04-08 Tom Tromey <tom@tromey.com>
2
3 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
4 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
5 (captured_main, main): Update.
6 * gdbreplay.c (main): Update.
7
8 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
9
10 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
11 value in argument pointer, return 1 if the entry is found and 0
12 otherwise. Move comment.
13 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
14 * linux-low.h (linux_get_auxv): Declare.
15 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
16
17 2019-04-05 Tom Tromey <tromey@adacore.com>
18
19 * server.c (gdbserver_usage): Use upper-case for metasyntactic
20 variables.
21
22 2019-03-28 Alan Hayward <alan.hayward@arm.com>
23
24 * linux-low.c (AT_HWCAP2): Add define if not already included.
25
26 2019-03-26 Alan Hayward <alan.hayward@arm.com>
27
28 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
29 (aarch64_arch_setup): Call linux_get_hwcap.
30 * linux-arm-low.c (arm_get_hwcap): Remove function.
31 (arm_read_description): Call linux_get_hwcap.
32 * linux-low.c (linux_get_auxv): New function.
33 (linux_get_hwcap): Likewise.
34 (linux_get_hwcap2): Likewise.
35 * linux-low.h (linux_get_hwcap): New declaration.
36 (linux_get_hwcap2): Likewise.
37 * linux-ppc-low.c (ppc_get_auxv): Remove function.
38 (ppc_arch_setup): Call linux_get_hwcap.
39 * linux-s390-low.c (s390_get_hwcap): Remove function.
40 (s390_arch_setup): Call linux_get_hwcap.
41
42 2019-03-22 Alan Hayward <alan.hayward@arm.com>
43 Jiong Wang <jiong.wang@arm.com>
44
45 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
46 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
47 to fail.
48 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
49
50 2019-03-22 Alan Hayward <alan.hayward@arm.com>
51 Jiong Wang <jiong.wang@arm.com>
52
53 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
54 (aarch64_get_hwcap): New function.
55 (aarch64_arch_setup): Read APIA hwcap.
56
57 2019-03-22 Alan Hayward <alan.hayward@arm.com>
58 Jiong Wang <jiong.wang@arm.com>
59
60 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
61 (initialize_low_tracepoint): Likewise.
62 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
63 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
64 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
65 (aarch64_linux_read_description): Likewise.
66 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
67
68 2019-03-12 John Baldwin <jhb@FreeBSD.org>
69
70 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
71 i386_create_target_description for 'segments' parameter.
72 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
73 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
74 * win32-i386-low.c (i386_arch_setup): Likewise.
75
76 2019-03-12 Tom Tromey <tromey@adacore.com>
77
78 * linux-low.c (iterate_over_lwps): Update.
79
80 2019-03-06 Tom Tromey <tom@tromey.com>
81
82 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
83 (captured_main): Use SCOPE_EXIT.
84
85 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
86
87 * configure.srv: Use '$enable_unittest' instead of '$development'
88 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
89 case.
90
91 2019-02-27 Tom Tromey <tromey@adacore.com>
92
93 * gdbreplay.c (logchar): Handle \r\n.
94
95 2019-02-07 Alan Hayward <alan.hayward@arm.com>
96
97 * linux-low.c (linux_attach): Add process before lwp.
98 * server.c (attach_inferior): Check if already attached.
99
100 2019-02-07 Tom Tromey <tom@tromey.com>
101
102 * x86-tdesc.h: Rename include guard.
103 * x86-low.h: Add include guard.
104 * wincecompat.h: Rename include guard.
105 * win32-low.h: Add include guard.
106 * utils.h: Rename include guard.
107 * tracepoint.h: Rename include guard.
108 * tdesc.h: Rename include guard.
109 * target.h: Rename include guard.
110 * server.h: Rename include guard.
111 * remote-utils.h: Rename include guard.
112 * regcache.h: Rename include guard.
113 * nto-low.h: Rename include guard.
114 * notif.h: Add include guard.
115 * mem-break.h: Rename include guard.
116 * lynx-low.h: Add include guard.
117 * linux-x86-tdesc.h: Add include guard.
118 * linux-s390-tdesc.h: Add include guard.
119 * linux-ppc-tdesc-init.h: Add include guard.
120 * linux-low.h: Add include guard.
121 * linux-aarch64-tdesc.h: Add include guard.
122 * linux-aarch32-low.h: Add include guard.
123 * inferiors.h: Rename include guard.
124 * i387-fp.h: Rename include guard.
125 * hostio.h: Rename include guard.
126 * gdbthread.h: Rename include guard.
127 * gdb_proc_service.h: Rename include guard.
128 * event-loop.h: Rename include guard.
129 * dll.h: Rename include guard.
130 * debug.h: Rename include guard.
131 * ax.h: Rename include guard.
132
133 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
134
135 PR gdb/23985
136 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
137 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
138
139 2019-01-25 Tom Tromey <tom@tromey.com>
140
141 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
142
143 2019-01-25 Tom Tromey <tom@tromey.com>
144
145 * win32-low.c: Fix common/ includes.
146 * win32-i386-low.c: Fix common/ includes.
147 * tracepoint.c: Fix common/ includes.
148 * thread-db.c: Fix common/ includes.
149 * target.h: Fix common/ includes.
150 * symbol.c: Fix common/ includes.
151 * spu-low.c: Fix common/ includes.
152 * server.h: Fix common/ includes.
153 * server.c: Fix common/ includes.
154 * remote-utils.c: Fix common/ includes.
155 * regcache.h: Fix common/ includes.
156 * regcache.c: Fix common/ includes.
157 * nto-x86-low.c: Fix common/ includes.
158 * notif.h: Fix common/ includes.
159 * mem-break.h: Fix common/ includes.
160 * lynx-low.c: Fix common/ includes.
161 * lynx-i386-low.c: Fix common/ includes.
162 * linux-x86-tdesc-selftest.c: Fix common/ includes.
163 * linux-x86-low.c: Fix common/ includes.
164 * linux-low.c: Fix common/ includes.
165 * inferiors.h: Fix common/ includes.
166 * i387-fp.c: Fix common/ includes.
167 * hostio.c: Fix common/ includes.
168 * hostio-errno.c: Fix common/ includes.
169 * gdbthread.h: Fix common/ includes.
170 * gdbreplay.c: Fix common/ includes.
171 * fork-child.c: Fix common/ includes.
172 * event-loop.c: Fix common/ includes.
173 * ax.c:
174 (enum gdb_agent_op): Fix common/ includes.
175
176 2019-01-21 Tom Tromey <tom@tromey.com>
177
178 * tracepoint.c: Fix includes.
179 * remote-utils.c: Fix includes.
180 * linux-x86-low.c: Fix includes.
181
182 2019-01-01 Joel Brobecker <brobecker@adacore.com>
183
184 * gdbreplay.c (gdbreplay_version): Update copyright year in
185 version message.
186 * server.c (gdbserver_version): Likewise.
187
188 2018-12-05 Alan Hayward <alan.hayward@arm.com>
189
190 * linux-low.c (add_lwp): Switch ordering.
191
192 2018-11-29 Tom Tromey <tom@tromey.com>
193
194 * win32-low.c (win32_join): Take pid, not process.
195 * target.h (struct target_ops) <join>: Change argument type.
196 (join_inferior): Change argument name.
197 * spu-low.c (spu_join): Take pid, not process.
198 * server.c (handle_detach): Preserve pid before destroying
199 process.
200 * lynx-low.c (lynx_join): Take pid, not process.
201 * linux-low.c (linux_join): Take pid, not process.
202
203 2018-11-23 Alan Hayward <alan.hayward@arm.com>
204
205 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
206 (aarch64_cannot_fetch_register): Likewise.
207 (struct linux_target_ops): Update references.
208
209 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
210
211 * linux-ppc-low.c: Include nat/linux-ptrace.h.
212
213 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
214
215 * configure.srv (ipa_ppc_linux_regobj): Add
216 powerpc-isa207-htm-vsx32l-ipa.o and
217 powerpc-isa207-htm-vsx64l-ipa.o.
218 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
219 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
220 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
221 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
222 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
223 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
224 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
225 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
226 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
227 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
228 (init_registers_powerpc_isa207_htm_vsx32l)
229 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
230 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
231 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
232 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
233 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
234 (ppc_store_tm_ctarregset): New functions.
235 (ppc_regsets): Add entries for HTM regsets.
236 (ppc_arch_setup): Set htm in features struct when needed. Set
237 sizes for the HTM regsets.
238 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
239 (initialize_low_arch): Call
240 init_registers_powerpc_isa207_htm_vsx32l and
241 init_registers_powerpc_isa207_htm_vsx64l.
242 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
243 PPC_TDESC_ISA207_HTM_VSX.
244 (initialize_low_tracepoint): Call
245 init_registers_powerpc_isa207_htm_vsx32l and
246 init_registers_powerpc_isa207_htm_vsx64l.
247
248 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
249
250 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
251 rs6000/power-linux-pmu.xml to srv_xmlfiles.
252 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
253 (ppc_store_pmuregset): New functions.
254 (ppc_regsets): Add entries for ebb and pmu regsets.
255 (ppc_arch_setup): Set isa207 in features struct if the ebb and
256 pmu regsets are available. Set sizes for these regsets.
257
258 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
259
260 * configure.srv (ipa_ppc_linux_regobj): Add
261 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
262 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
263 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
264 rs6000/powerpc-isa207-vsx32l.xml, and
265 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
266 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
267 <PPC_TDESC_ISA207_VSX>: New enum value.
268 (init_registers_powerpc_isa207_vsx32l): Declare.
269 (init_registers_powerpc_isa207_vsx64l): Declare.
270 * linux-ppc-low.c (ppc_fill_tarregset): New function.
271 (ppc_store_tarregset): New function.
272 (ppc_regsets): Add entry for the TAR regset.
273 (ppc_arch_setup): Set isa207 in features struct when needed. Set
274 size for the TAR regsets.
275 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
276 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
277 and init_registers_powerpc_isa207_vsx64l.
278 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
279 (initialize_low_tracepoint): Call
280 init_registers_powerpc_isa207_vsx32l and
281 init_registers_powerpc_isa207_vsx64l.
282
283 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
284 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
285
286 * configure.srv (ipa_ppc_linux_regobj): Add
287 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
288 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
289 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
290 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
291 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
292 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
293 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
294 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
295 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
296 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
297 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
298 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
299 (ppc_hwcap): Add comment.
300 (ppc_hwcap2): New global.
301 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
302 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
303 (ppc_regsets): Add entries for the DSCR and PPR regsets.
304 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
305 when needed. Set sizes for the the DSCR and PPR regsets.
306 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
307 (initialize_low_arch): Call
308 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
309 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
310 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
311 PPC_TDESC_ISA205_PPR_DSCR_VSX.
312 (initialize_low_tracepoint): Call
313 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
314 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
315
316 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
317
318 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
319
320 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
321 Simon Marchi <simark@simark.ca>
322
323 * acinclude.m4: Include "../selftest.m4".
324 * configure: Regenerate.
325 * configure.ac: Use "GDB_AC_SELFTEST".
326 * configure.srv: Use "$enable_unittests" instead of
327 "$development" when checking whether unit tests have been
328 enabled.
329 * server.c (captured_main): Update message informing that
330 selftests have been disabled.
331
332 2018-10-04 Tom Tromey <tom@tromey.com>
333
334 * configure: Rebuild.
335
336 2018-10-04 Tom Tromey <tom@tromey.com>
337
338 * server.c (handle_status): Rename inner "thread".
339 (process_serial_event): Declare "res" in 'm' case.
340 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
341 (iterate_over_lwps): Rename inner "thread".
342 (linux_qxfer_libraries_svr4): Rename inner "len".
343 * gdbthread.h (find_thread_in_random): Rename inner "thread".
344
345 2018-10-01 Gary Benson <gbenson@redhat.com>
346
347 * gdb_proc_service.h: Moved common code to
348 common/gdb_proc_service.h.
349
350 2018-10-01 Gary Benson <gbenson@redhat.com>
351
352 * gdb_proc_service.h: Synchronize comments and whitespace with
353 GDB's version of this file.
354
355 2018-09-25 Tom Tromey <tom@tromey.com>
356
357 * configure: Rebuild.
358 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
359
360 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
361
362 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
363 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
364 ($(IPA_LIB)): Sort IPA_OBJS.
365
366 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
367
368 * Makefile.in: Remove references to $(ADD_DEPS).
369
370 2018-09-16 Tom Tromey <tom@tromey.com>
371
372 * remote-utils.c (remote_open): Use GNU style for metasyntactic
373 variables.
374 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
375 variables.
376
377 2018-09-05 Tom Tromey <tom@tromey.com>
378
379 * configure: Rebuild.
380
381 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
382
383 PR build/23399
384 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
385
386 2018-08-27 Tom Tromey <tom@tromey.com>
387
388 PR build/23087:
389 * configure: Rebuild.
390
391 2018-08-27 Tom Tromey <tom@tromey.com>
392
393 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
394 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
395 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
396 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
397 (s390x_emit_stack_adjust): Add casts to unsigned char.
398
399 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
400
401 PR gdb/23374
402 PR gdb/23375
403 * server.h (struct client_state) <disable_randomization>:
404 Initialize to 1.
405
406 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
407
408 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
409 variable.
410 (mips_supply_ptrace_register): Likewise.
411
412 2018-07-22 Tom Tromey <tom@tromey.com>
413
414 * configure: Rebuild.
415
416 2018-07-22 Tom Tromey <tom@tromey.com>
417
418 * win32-low.c (win32_create_inferior): Remove unused variables.
419 * gdbreplay.c (remote_open): Remove unused variable.
420 * remote-utils.c (remote_prepare): Remove unused variable.
421 * x86-tdesc.h (X86_TDESC_H): Define.
422 (amd64_expedite_regs): Define conditionally.
423 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
424 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
425 * remote-utils.c (readchar): Remove unused variable.
426
427 2018-07-13 Pedro Alves <palves@redhat.com>
428
429 * linux-low.c (linux_kill): Change parameter to process_info
430 pointer instead of pid. Adjust.
431 * lynx-low.c (lynx_kill): Likewise.
432 * nto-low.c (nto_kill): Likewise.
433 * spu-low.c (spu_kill): Likewise.
434 * win32-low.c (win32_kill): Likewise.
435 * server.c (handle_v_kill, kill_inferior_callback)
436 (detach_or_kill_for_exit): Adjust.
437 * target.c (kill_inferior): Change parameter to process_info
438 pointer instead of pid. Adjust.
439 * target.h (struct target_ops) <kill>: Change parameter to
440 process_info pointer instead of pid. Adjust all implementations
441 and callers.
442 (kill_inferior): Likewise.
443
444 2018-07-13 Pedro Alves <palves@redhat.com>
445
446 * linux-low.c (linux_detach, linux_join): Change parameter to
447 process_info pointer instead of pid. Adjust.
448 * lynx-low.c (lynx_detach, lynx_join): Likewise.
449 * nto-low.c (nto_detach): Likewise.
450 * spu-low.c (spu_detach, spu_join): Likewise.
451 * win32-low.c (win32_detach, win32_join): Likewise.
452 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
453 * target.h (struct target_ops) <detach, join>: Change parameter to
454 process_info pointer instead of pid. Adjust all implementations
455 and callers.
456 (detach_inferior, join_inferior): Rename 'pid' parameter to
457 'proc'.
458
459 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
460 Jan Kratochvil <jan.kratochvil@redhat.com>
461 Paul Fertser <fercerpav@gmail.com>
462 Tsutomu Seki <sekiriki@gmail.com>
463
464 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
465 (OBS): Add 'common/netstuff.o'.
466 (GDBREPLAY_OBS): Likewise.
467 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
468 (remote_open): Implement support for IPv6
469 connections.
470 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
471 and 'wspiapi.h'.
472 (handle_accept_event): Accept connections from IPv6 sources.
473 (remote_prepare): Handle IPv6-style hostnames; implement
474 support for IPv6 connections.
475 (remote_open): Implement support for printing connections from
476 IPv6 sources.
477
478 2018-07-11 Pedro Alves <palves@redhat.com>
479
480 PR gdb/23377
481 * mem-break.c (any_persistent_commands): Add process_info
482 parameter and use it instead of relying on the current process.
483 Change return type to bool.
484 * mem-break.h (any_persistent_commands): Add process_info
485 parameter and change return type to bool.
486 * server.c (handle_detach): Remove require_running_or_return call.
487 Look up the process_info for the process we're about to detach.
488 If not found, return back error to GDB. Adjust
489 any_persistent_commands call to pass down a process pointer.
490
491 2018-07-11 Pedro Alves <palves@redhat.com>
492
493 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
494 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
495 instead of collect_register_by_name.
496 * regcache.c (regcache_raw_get_unsigned_by_name): New.
497 * regcache.h (regcache_raw_get_unsigned_by_name): New.
498
499 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
500 Pedro Alves <palves@redhat.com>
501
502 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
503
504 2018-07-03 Tom Tromey <tom@tromey.com>
505
506 * linux-low.c: Update.
507 * lynx-low.c: Update.
508 * mem-break.c: Update.
509 * nto-low.c: Update.
510 * remote-utils.c: Update.
511 * server.c: Update.
512 * spu-low.c: Update.
513 * target.c: Update.
514 * win32-low.c: Update.
515
516 2018-07-03 Tom Tromey <tom@tromey.com>
517
518 * server.c: Update.
519
520 2018-07-03 Tom Tromey <tom@tromey.com>
521
522 * linux-low.c: Update.
523
524 2018-07-03 Tom Tromey <tom@tromey.com>
525
526 * target.c: Update.
527
528 2018-07-03 Tom Tromey <tom@tromey.com>
529
530 * linux-low.c: Update.
531 * linux-mips-low.c: Update.
532 * lynx-low.c: Update.
533 * nto-low.c: Update.
534 * remote-utils.c: Update.
535 * server.c: Update.
536 * spu-low.c: Update.
537 * target.c: Update.
538 * thread-db.c: Update.
539
540 2018-07-03 Tom Tromey <tom@tromey.com>
541
542 * linux-low.c: Update.
543 * linux-mips-low.c: Update.
544 * lynx-low.c: Update.
545 * mem-break.c: Update.
546 * nto-low.c: Update.
547 * remote-utils.c: Update.
548 * server.c: Update.
549 * spu-low.c: Update.
550 * target.c: Update.
551 * tracepoint.c: Update.
552
553 2018-07-03 Tom Tromey <tom@tromey.com>
554
555 * linux-low.c: Update.
556 * linux-ppc-low.c: Update.
557 * linux-x86-low.c: Update.
558 * proc-service.c: Update.
559 * server.c: Update.
560 * spu-low.c: Update.
561 * thread-db.c: Update.
562 * win32-low.c: Update.
563
564 2018-07-03 Tom Tromey <tom@tromey.com>
565
566 * linux-low.c: Update.
567 * lynx-low.c: Update.
568 * nto-low.c: Update.
569 * remote-utils.c: Update.
570 * spu-low.c: Update.
571 * thread-db.c: Update.
572 * win32-low.c: Update.
573
574 2018-06-29 Joel Brobecker <brobecker@adacore.com>
575
576 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
577 parameter in call to 'amd64_create_target_description'.
578
579 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
580
581 * x86-tdesc.h: Remove executable permission flag.
582
583 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
584
585 * configure.ac: Remove AC_PREREQ, add missing quoting.
586 * configure: Re-generate.
587 * config.in: Re-generate.
588 * aclocal.m4: Re-generate.
589
590 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
591
592 * tracepoint.h (current_traceframe): Remove declaration.
593
594 2018-06-18 Alan Hayward <alan.hayward@arm.com>
595
596 * linux-aarch64-low.c (is_sve_tdesc): New function.
597 (aarch64_sve_regs_copy_to_regcache): Likewise.
598 (aarch64_sve_regs_copy_from_regcache): Likewise.
599 (aarch64_regs_info): Add SVE checks.
600 (initialize_low_arch): Initialize SVE.
601
602 2018-06-18 Alan Hayward <alan.hayward@arm.com>
603
604 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
605
606 2018-06-11 Alan Hayward <alan.hayward@arm.com>
607
608 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
609 (initialize_low_tracepoint): Likewise
610 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
611 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
612 param.
613 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
614 checks.
615 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
616
617 2018-06-11 Alan Hayward <alan.hayward@arm.com>
618
619 * server.h (PBUFSIZ): Increase size
620
621 2018-06-11 Alan Hayward <alan.hayward@arm.com>
622
623 * regcache.c (regcache::raw_compare): New function.
624 * regcache.h (regcache::raw_compare): New declaration.
625
626 2018-06-11 Alan Hayward <alan.hayward@arm.com>
627
628 * regcache.c (new_register_cache): Use new.
629 (free_register_cache): Use delete.
630 (register_data): Use const.
631 (supply_register): Move body inside regcache.
632 (regcache::raw_supply): New override function.
633 (collect_register): Move body inside regcache.
634 (regcache::raw_collect): New override function.
635 (regcache::get_register_status): New override function.
636 * regcache.h (struct regcache): Inherit from reg_buffer_common.
637
638 2018-06-09 Tom Tromey <tom@tromey.com>
639
640 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
641 declare queue.
642 (event_queue): Use std::queue.
643 (gdb_event_xfree): Remove.
644 (initialize_event_loop, process_event, wait_for_event): Update.
645
646 2018-06-08 Stan Cox <scox@redhat.com>
647
648 * win32-low.c (win32_create_inferior): last_ptid and last_status
649 moved to client_state.
650
651 2018-06-08 Pedro Alves <palves@redhat.com>
652
653 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
654 common/common-exceptions.o, common/common-utils.o,
655 common/errors.o, common/print-utils.o and utils.o.
656 * gdbreplay.c: Include "common-defs.h" instead of the two
657 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
658 string.h or alloca.h.
659 (perror_with_name): Delete.
660 (remote_open): Use xstrdup instead of strdup.
661 (main): Rename to ...
662 (captured_main): ... this.
663 (main): New.
664
665 2018-06-08 Tom Tromey <tom@tromey.com>
666
667 * linux-low.c (linux_low_read_btrace): Update.
668
669 2018-06-04 Stan Cox <scox@redhat.com>
670
671 * server.h (struct client_state): New.
672 * server.c (cont_thread, general_thread, multi_process)
673 (report_fork_events, report_vfork_events, report_exec_events)
674 (report_thread_events, swbreak_feature, hwbreak_feature)
675 (vCont_supported, disable_randomization, pass_signals)
676 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
677 Moved to client_state.
678 * remote-utils.c (remote_debug, noack_mode)
679 (transport_is_reliable): Moved to client_state.
680 * tracepoint.c (current_traceframe): Moved to client_state.
681
682 Update all callers.
683 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
684 linux-low.c, remote-utils.h, target.c: Use client_state.
685
686 2018-05-31 Alan Hayward <alan.hayward@arm.com>
687
688 * configure.srv: Add new c/h file.
689
690 2018-05-31 Alan Hayward <alan.hayward@arm.com>
691
692 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
693 null VQ.
694
695 2018-05-25 Maciej W. Rozycki <macro@mips.com>
696
697 * gdb.arch/mips-fpregset-core.exp: New test.
698 * gdb.arch/mips-fpregset-core.c: New test source.
699
700 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
701
702 PR server/23198
703 * hostio.c (require_int): Do not report overflow for integers
704 between 0xfffffff and 0x7fffffff.
705
706 2018-05-22 Maciej W. Rozycki <macro@mips.com>
707
708 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
709 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
710 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
711 functions.
712 (the_low_target): Wire them.
713
714 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
715
716 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
717 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
718 mode. Call collect_register_by_name with vscr using
719 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
720 (ppc_store_vrregset): Add and set vscr_offset variable as in
721 ppc_fill_vrregset. Call supply_register_by_name with vscr using
722 vscr_offset.
723
724 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
725
726 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
727 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
728 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
729
730 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
731
732 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
733 (ppc_store_vsxregset): Likewise.
734 (ppc_fill_vrregset): Likewise.
735 (ppc_store_vrregset): Likewise.
736 (ppc_fill_evrregset): Likewise.
737 (ppc_store_evrregset): Likewise.
738 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
739 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
740 needed.
741
742 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
743
744 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
745 wordsize of the inferior. Call ppc_linux_target_wordsize.
746
747 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
748
749 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
750 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
751 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
752 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
753 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
754 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
755 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
756 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
757 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
758 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
759 (tdesc_powerpc_e500l): Remove.
760 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
761 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
762 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
763 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
764 linux-ppc-tdesc.h.
765 (ppc_arch_setup): Remove target description matching code. Fill a
766 ppc_linux_features struct and call ppc_linux_match_description
767 with it.
768
769 2018-05-22 Maciej W. Rozycki <macro@mips.com>
770
771 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
772 width of the requested register exceeds the width of the
773 `ptrace' data type.
774 (mips_cannot_store_register): Likewise.
775
776 2018-05-21 Maciej W. Rozycki <macro@mips.com>
777
778 * linux-mips-low.c (mips_fetch_register): New function. Update
779 preceding comment.
780 (mips_store_gregset): Supply 0 rather than $restart for $zero.
781 (the_low_target): Wire `mips_fetch_register'.
782
783 2018-05-10 Joel Brobecker <brobecker@adacore.com>
784
785 * lynx-i386-low.c (LYNXOS_178): New macro.
786 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
787 the layout on LynxOS-178.
788 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
789 handle floating point registers that are not supported by
790 LynxOS-178.
791
792 2018-05-10 Tom Tromey <tom@tromey.com>
793
794 * configure: Rebuild.
795
796 2018-05-10 Joel Brobecker <brobecker@adacore.com>
797
798 PR server/23158:
799 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
800 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
801 Use it to set the expedite_regs field in the given tdesc.
802 * x86-tdesc.h: New file.
803 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
804 Adjust following the addition of the new expedite_regs parameter
805 to init_target_desc.
806 * linux-tic6x-low.c (tic6x_read_description): Likewise.
807 * linux-x86-tdesc.c: #include "x86-tdesc.h".
808 (i386_linux_read_description, amd64_linux_read_description):
809 Adjust following the addition of the new expedite_regs parameter
810 to init_target_desc.
811 * lynx-i386-low.c: #include "x86-tdesc.h".
812 (lynx_i386_arch_setup): Adjust following the addition of the new
813 expedite_regs parameter to init_target_desc.
814 * nto-x86-low.c: #include "x86-tdesc.h".
815 (nto_x86_arch_setup): Adjust following the addition of the new
816 expedite_regs parameter to init_target_desc.
817 * win32-i386-low.c: #include "x86-tdesc.h".
818 (i386_arch_setup): Adjust following the addition of the new
819 expedite_regs parameter to init_target_desc.
820
821 2018-05-10 Joel Brobecker <brobecker@adacore.com>
822
823 PR server/23158:
824 * win32-low.c (win32_create_inferior): Add call to my_wait
825 setting last_status global.
826
827 2018-05-10 Joel Brobecker <brobecker@adacore.com>
828
829 PR server/23158:
830 * win32-low.c (create_process): Only call gdb_tilde_expand if
831 inferior_cwd is not NULL.
832
833 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
834
835 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
836 registers to the cache if their values have changed.
837 (i387_xsave_to_cache): Provide default values for x87 control
838 registers when these features are available, but disabled.
839 * regcache.c (supply_register_by_name_zeroed): New function.
840 * regcache.h (supply_register_by_name_zeroed): Declare new
841 function.
842
843 2018-05-07 Tom Tromey <tom@tromey.com>
844
845 * configure: Rebuild.
846
847 2018-05-04 Tom Tromey <tom@tromey.com>
848
849 * configure: Rebuild.
850
851 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
852 Pedro Alves <palves@redhat.com>
853
854 * linux-aarch64-low.c (aarch64_stopped_data_address):
855 Likewise.
856
857 2018-04-27 Tom Tromey <tom@tromey.com>
858
859 * configure: Rebuild.
860
861 2018-04-23 Tom Tromey <tom@tromey.com>
862
863 * configure: Rebuild.
864
865 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
866
867 * Makefile.in (depcomp): Add "..".
868 (all_deps_files): New and use it.
869
870 2018-04-18 Alan Hayward <alan.hayward@arm.com>
871
872 * configure.srv (aarch64*-*-linux*): Don't include xml.
873 (i[34567]86-*-cygwin*): Likewise.
874 (i[34567]86-*-linux*): Likewise.
875 (i[34567]86-*-lynxos*): Likewise.
876 (i[34567]86-*-mingw32ce*): Likewise.
877 (i[34567]86-*-mingw*): Likewise.
878 (i[34567]86-*-nto*): Likewise.
879 (tic6x-*-uclinux): Likewise.
880 (x86_64-*-linux*): Likewise.
881 (x86_64-*-mingw*): Likewise.
882 (x86_64-*-cygwin*): Likewise.
883
884 2018-04-18 Alan Hayward <alan.hayward@arm.com>
885
886 * tdesc.c: Remove xml parameter.
887
888 2018-04-18 Alan Hayward <alan.hayward@arm.com>
889
890 * server.c (get_features_xml): Remove cast.
891 * tdesc.c (void target_desc::accept): Fill in function.
892 (tdesc_get_features_xml): Remove old xml creation.
893 (print_xml_feature::visit_pre): Add xml vistor.
894 * tdesc.h (struct target_desc): Make xmltarget mutable.
895 (tdesc_get_features_xml): Remove declaration.
896
897 2018-04-18 Alan Hayward <alan.hayward@arm.com>
898
899 * tdesc.c (tdesc_architecture_name): Add new function.
900 (tdesc_osabi_name): Likewise.
901 (tdesc_get_features_xml): Use new functions.
902
903 2018-04-18 Alan Hayward <alan.hayward@arm.com>
904
905 * tdesc.c (tdesc_create_flags): Remove.
906 (tdesc_add_flag): Likewise.
907 (tdesc_named_type): Likewise.
908 (tdesc_create_union): Likewise.
909 (tdesc_create_struct): Likewise.
910 (tdesc_create_vector): Likewise.
911 (tdesc_add_bitfield): Likewise.
912 (tdesc_add_field): Likewise.
913 (tdesc_set_struct_size): Likewise.
914
915 2018-04-18 Alan Hayward <alan.hayward@arm.com>
916
917 * tdesc.c (~target_desc): Remove implictly deleted items.
918 (init_target_desc): Iterate all features.
919 (tdesc_get_features_xml): Use vector.
920 (tdesc_create_feature): Create feature.
921 * tdesc.h (tdesc_feature) Remove
922 (target_desc): Add features.
923
924 2018-04-18 Alan Hayward <alan.hayward@arm.com>
925
926 * Makefile.in: Add common/tdesc.c
927 * tdesc.c (init_target_desc): init all reg_defs from register
928 vector.
929 (tdesc_create_reg): Create tdesc_reg.
930 * tdesc.h (tdesc_feature): Add register vector.
931
932 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
933
934 * tdesc.h (struct target_desc) <features>: Change type to
935 std::vector<std::string>.
936 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
937 changes.
938 (tdesc_get_features_xml): Likewise.
939 (tdesc_create_feature): Likewise.
940
941 2018-03-26 Alan Hayward <alan.hayward@arm.com>
942
943 * regcache.c (find_register_by_number): Return a ref.
944 (find_regno): Use references.
945 (register_size): Likewise.
946 (register_data): Likewise.
947 * tdesc.c (target_desc::~target_desc): Remove free calls.
948 (target_desc::operator==): Use std::vector compare.
949 (init_target_desc): Use reference.
950 (tdesc_create_reg): Use reg constructors.
951 * tdesc.h (struct target_desc): Replace pointer with object.
952
953 2018-03-23 Alan Hayward <alan.hayward@arm.com>
954
955 * regcache.c (find_register_by_number): Make static.
956 (find_regno): Use find_register_by_number
957 * regcache.h (struct reg): Remove declaration.
958
959 2018-03-23 Alan Hayward <alan.hayward@arm.com>
960
961 * tdesc.c (target_desc::~target_desc): Move to here.
962 (target_desc::operator==): Likewise.
963 * tdesc.h (target_desc::~target_desc): Move from here.
964 (target_desc::operator==): Likewise.
965
966 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
967
968 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
969
970 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
971
972 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
973 S390_TDESC_GS.
974 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
975 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
976 and init_registers_s390_gs_linux64.
977
978 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
979
980 * linux-s390-low.c (s390_fill_gs): Remove function.
981 (s390_fill_gsbc): Remove function.
982 (s390_regsets): Set fill functions for the guarded storage regsets
983 to NULL.
984
985 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
986
987 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
988 the word size. Add comment.
989 (s390_get_wordsize): New function.
990 (s390_arch_setup): No longer select a temporary tdesc to fetch the
991 pswm with it. Instead, use s390_get_wordsize to determine the
992 word size first and derive the correct tdesc from that directly.
993
994 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
995
996 * Makefile.in: Include silent-rules.mk.
997 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
998 (COMPILE): Add ECHO_CXX.
999 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1000 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1001 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1002 (version-generated.c): Add ECHO_GEN.
1003 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1004 (IPAGENT_COMPILE): Add ECHO_CXX.
1005 (%-generated.c): Add ECHO_REGDAT.
1006
1007 2018-03-14 Tom Tromey <tom@tromey.com>
1008
1009 PR cli/14977:
1010 * ax.c (ax_printf): Special case for NULL.
1011
1012 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1013
1014 * linux-low.c (linux_qxfer_libraries_svr4): Use
1015 xml_escape_text_append.
1016
1017 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1018
1019 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1020
1021 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1022
1023 * server.c (handle_general_set): Remove unnecessary xstrdup.
1024
1025 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1026
1027 * server.c (parse_debug_format_options): Adjust to
1028 delim_string_to_char_ptr_vec changes.
1029 * thread-db.c (thread_db_load_search): Adjust to
1030 dirnames_to_char_ptr_vec changes.
1031
1032 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1033
1034 * target.h (target_enable_btrace, target_disable_btrace)
1035 (target_read_btrace, target_read_btrace_conf): Turn macro into
1036 inline function. Throw error if target method is not defined.
1037 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1038 check for btrace target method. Be prepared to handle exceptions
1039 from btrace target methods.
1040
1041 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1042
1043 * server.c (captured_main): Change order of error message printed
1044 when the current working directory cannot be found.
1045
1046 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1047
1048 * server.c: Include "filenames.h" and "pathstuff.h".
1049 (program_name): Delete variable.
1050 (program_path): New anonymous class.
1051 (get_exec_wrapper): Use "program_path" instead of
1052 "program_name".
1053 (handle_v_run): Likewise.
1054 (captured_main): Likewise.
1055 (process_serial_event): Likewise.
1056
1057 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1058
1059 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1060 (OBJS): Add "pathstuff.o".
1061 * server.c (current_directory): New global variable.
1062 (captured_main): Initialize "current_directory".
1063
1064 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1065
1066 * tdesc.c: Use common/tdesc.h.
1067 * tdesc.h: Likewise.
1068
1069 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1070 Simon Marchi <simon.marchi@ericsson.com>
1071
1072 * Makefile.in: Switch order of make rules.
1073
1074 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1075
1076 * Makefile.in: Add common directory in build.
1077 * configure.ac: Add common reference.
1078 * configure: Regenerate.
1079
1080 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1081
1082 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1083 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1084 * spu-low.c (spu_target_ops): Likewise.
1085 * win32-low.c (win32_target_ops): Likewise.
1086 * server.c (supported_btrace_packets): Report packets unconditionally.
1087 * target.h (target_ops) <supports_btrace>: Remove.
1088 (target_supports_btrace): Remove.
1089
1090 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1091
1092 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1093 (handle_btrace_disable): Change return type to void. Use exceptions
1094 to report errors.
1095 (handle_btrace_general_set): Catch exception and copy message to
1096 return message.
1097
1098 2018-02-08 Tom Tromey <tom@tromey.com>
1099
1100 * linux-low.c (install_software_single_step_breakpoints): Use
1101 make_scoped_restore.
1102 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1103 (do_restore_current_thread_cleanup): Remove.
1104 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1105 declare.
1106
1107 2018-02-08 Tom Tromey <tom@tromey.com>
1108
1109 * mem-break.c (set_raw_breakpoint_at): Use
1110 gdb::unique_xmalloc_ptr.
1111
1112 2018-01-30 Pedro Alves <palves@redhat.com>
1113
1114 PR gdb/13211
1115 * target.c (target_terminal::terminal_state): Rename to ...
1116 (target_terminal::m_terminal_state): ... this.
1117
1118 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1119
1120 * linux-low.c (handle_extended_wait): Surround call to
1121 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1122
1123 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1124
1125 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1126 linux_ptrace_attach_fail_reason_string now returning an
1127 std::string.
1128 (linux_attach): Likewise.
1129 * thread-db.c (attach_thread): Likewise.
1130
1131 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1132
1133 PR gdb/21559
1134 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1135 checking for fs_base/gs_base fields in struct user_regs_struct.
1136 * configure: Regenerate.
1137
1138 2018-01-16 Yao Qi <yao.qi@linaro.org>
1139
1140 PR gdb/18749
1141 * linux-low.c (fetch_register): Call supply_register instead of
1142 error.
1143
1144 2018-01-08 Yao Qi <yao.qi@linaro.org>
1145 Simon Marchi <simon.marchi@ericsson.com>
1146
1147 * Makefile.in (OBS): Remove selftest.o.
1148 * configure.ac: Set srv_selftest_objs if $development is true.
1149 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1150 * configure: Re-generated.
1151 * server.c (captured_main): Wrap variable selftest_filter with
1152 GDB_SELF_TEST.
1153
1154 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1155
1156 * server.c (parse_debug_format_options): Return std::string.
1157 (handle_monitor_command, captured_main): Adjust.
1158
1159 2018-01-05 Pedro Alves <palves@redhat.com>
1160
1161 PR gdb/18653
1162 * server.c (captured_main): Pass quiet=false to
1163 save_original_signals_state.
1164
1165 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1166
1167 * gdbreplay.c (gdbreplay_version): Update copyright year in
1168 version message.
1169 * server.c (gdbserver_version): Likewise.
1170
1171 2017-12-08 Tom Tromey <tom@tromey.com>
1172
1173 * ax.c (ax_printf): Update.
1174
1175 2017-12-07 Yao Qi <yao.qi@linaro.org>
1176
1177 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1178 aarch64_linux_read_description.
1179 * linux-amd64-ipa.c (idx2mask): New array.
1180 (get_ipa_tdesc): Move idx2mask out.
1181 (initialize_low_tracepoint): Initialize target descriptions.
1182 * linux-i386-ipa.c (idx2mask): New array.
1183 (get_ipa_tdesc): Move idx2mask out.
1184 (initialize_low_tracepoint): Initialize target descriptions.
1185
1186 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1187
1188 * tdesc.c (struct tdesc_type): Change return type.
1189 (tdesc_add_flag): Change parameter type.
1190 (tdesc_add_bitfield): Likewise.
1191 (tdesc_add_field): Likewise.
1192 (tdesc_set_struct_size): Likewise.
1193
1194 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1195
1196 * regcache.c (registers_to_string): Remove unused variable.
1197
1198 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1199
1200 * inferiors.c (for_each_inferior_with_data): Remove.
1201 * inferiors.h (for_each_inferior_with_data): Remove.
1202 * server.c (handle_qxfer_threads_worker): Change parameter type.
1203 (handle_qxfer_threads_proper): Use for_each_thread.
1204
1205 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1206
1207 * inferiors.c (for_each_inferior): Remove.
1208 (clear_inferiors): Use for_each_thread.
1209 * inferiors.h (for_each_inferior): Remove.
1210 * linux-low.c (linux_wait_for_event_filtered): Use
1211 for_each_thread.
1212 (linux_stabilize_threads): Likewise.
1213 * regcache.c (regcache_release): Likewise.
1214 * server.c (gdb_wants_all_threads_stopped): Likewise.
1215 (clear_pending_status_callback): Remove.
1216 (handle_status): Use for_each_thread.
1217 (captured_main): Likewise.
1218 * win32-low.c (child_init_thread_list): Likewise.
1219 (win32_clear_inferiors): Likewise.
1220 (fake_breakpoint_event): Likewise.
1221
1222 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1223
1224 * inferiors.h (find_inferior): Remove.
1225 * inferiors.c (find_inferior): Remove.
1226
1227 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1228
1229 * linux-low.c (resume_status_pending_p): Update comment.
1230 (need_step_over_p): Update comment.
1231
1232 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1233
1234 * linux-low.c (proceed_one_lwp): Return void, change parameter
1235 type.
1236 (unsuspend_and_proceed_one_lwp): Likewise.
1237 (proceed_all_lwps): Use for_each_thread.
1238 (unstop_all_lwps): Likewise.
1239
1240 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1241
1242 * linux-low.c (linux_resume_one_thread): Return void, take
1243 parameter directly.
1244 (linux_resume): Use for_each_thread.
1245
1246 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1247
1248 * linux-low.c (send_sigstop_callback): Return void, change
1249 parameter type. Rename to...
1250 (send_sigstop): ... this.
1251 (suspend_and_send_sigstop_callback): Return void, change parameter
1252 type. Rename to...
1253 (suspend_and_send_sigstop): ... this.
1254 (stop_all_lwps): Use for_each_thread.
1255
1256 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1257
1258 * linux-low.c (lwp_running): Return bool, remove unused
1259 argument.
1260 (linux_stabilize_threads): Use find_thread.
1261
1262 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1263
1264 * linux-low.c (select_singlestep_lwp_callback): Remove.
1265 (count_events_callback): Remove.
1266 (select_event_lwp_callback): Remove.
1267 (select_event_lwp): Use find_thread/for_each_thread.
1268
1269 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1270
1271 * linux-low.c (not_stopped_callback): Return bool, take filter
1272 argument directly.
1273 (linux_wait_for_event_filtered): Use find_thread.
1274 (linux_wait_1): Likewise.
1275
1276 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1277
1278 * linux-low.c (same_lwp): Remove.
1279 (find_lwp_pid): Use find_thread.
1280
1281 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1282
1283 * linux-low.c (delete_lwp_callback): Remove.
1284 (linux_mourn): Use for_each_thread.
1285
1286 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1287
1288 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1289 args parameter, don't check for pid.
1290 (linux_detach): Use for_each_thread.
1291
1292 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1293
1294 * linux-low.c (struct counter): Remove.
1295 (second_thread_of_pid_p): Remove.
1296 (last_thread_of_process_p): Use find_thread.
1297
1298 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1299
1300 * inferiors.c (find_inferior_in_random): Remove.
1301 * inferiors.h (find_inferior_in_random): Remove.
1302 * linux-low.c (status_pending_p_callback): Return bool, accept
1303 parameter ptid directly.
1304 (linux_wait_for_event_filtered): Use find_thread_in_random.
1305 (linux_wait_1): Likewise.
1306
1307 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1308
1309 * inferiors.c (find_inferior_id): Remove.
1310 (find_thread_ptid): Move implemention from find_inferior_id to
1311 here.
1312 * inferiors.h (find_inferior_id): Remove.
1313 * server.c (handle_status): Use find_thread_ptid.
1314 (process_serial_event): Likewise.
1315 * thread-db.c (find_one_thread): Likewise.
1316 (thread_db_thread_handle): Likewise.
1317 * win32-low.c (thread_rec): Likewise.
1318 (child_delete_thread): Likewise.
1319 (win32_thread_alive): Likewise.
1320 (get_child_debug_event): Likewise.
1321
1322 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1323
1324 * linux-mips-low.c (update_watch_registers_callback): Return
1325 void, remove pid_p parameter, don't check for pid.
1326 (mips_insert_point, mips_remove_point): Use for_each_thread.
1327
1328 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1329
1330 * lynx.low (lynx_delete_thread_callback): Remove.
1331 (lynx_mourn): Use for_each_thread.
1332
1333 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1334
1335 * regcache.c (regcache_invalidate_one): Remove.
1336 (regcache_invalidate_pid): use for_each_thread.
1337
1338 2017-11-26 Tom Tromey <tom@tromey.com>
1339
1340 * linux-low.c (linux_create_inferior): Update.
1341
1342 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1343
1344 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1345
1346 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1347
1348 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1349 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1350 * linux-aarch64-tdesc-selftest.c: New file.
1351 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1352
1353 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1354
1355 * configure.srv: Add new file.
1356 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1357 * linux-aarch64-tdesc-selftest.c: New file.
1358 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1359
1360 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1361
1362 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1363 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1364 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1365
1366 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1367
1368 * configure.srv: Add new files.
1369 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1370 aarch64_linux_read_description.
1371 * linux-aarch64-low.c (aarch64_linux_read_description):
1372 Merge with aarch64_arch_setup.
1373 (aarch64_arch_setup): Call aarch64_linux_read_description.
1374 * linux-aarch64-tdesc.c: New file.
1375 * linux-aarch64-tdesc.h: New file.
1376
1377 2017-11-24 Yao Qi <yao.qi@linaro.org>
1378
1379 * configure.srv: Set $srv_regobj for tic6x-linux.
1380 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1381 (tic6x_read_description): Move some code to tic6x_arch_setup.
1382 (tic6x_tdesc_test): New function.
1383 (initialize_low_arch): Call selftests::register_test.
1384
1385 2017-11-22 Yao Qi <yao.qi@linaro.org>
1386
1387 * remote-utils.c (prepare_resume_reply): Use memcpy.
1388
1389 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1390
1391 * linux-low.c (kill_one_lwp_callback): Return void, take
1392 argument directly, don't filter on pid.
1393 (linux_kill): Use for_each_thread.
1394
1395 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1396
1397 * linux-low.c (need_step_over_p): Return bool, remove dummy
1398 argument.
1399 (linux_resume, proceed_all_lwps): Use find_thread.
1400
1401 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1402
1403 * linux-low.c (resume_status_pending_p): Return bool, remove
1404 flag_p argument.
1405 (linux_resume): Use find_thread.
1406
1407 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1408
1409 * linux-low.c (struct thread_resume_array): Remove.
1410 (linux_set_resume_request): Return void, take arguments
1411 directly.
1412 (linux_resume): Use for_each_thread.
1413
1414 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1415
1416 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1417 return bool, remove data argument.
1418 (linux_stabilize_threads): Use find_thread.
1419
1420 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1421
1422 * linux-low.c (unsuspend_one_lwp): Remove.
1423 (unsuspend_all_lwps): Use for_each_thread, inline code from
1424 unsuspend_one_lwp.
1425
1426 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1427
1428 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1429 * linux-low.c (struct iterate_over_lwps_args): Remove.
1430 (iterate_over_lwps_filter): Remove.
1431 (iterate_over_lwps): Use find_thread.
1432
1433 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1434
1435 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1436 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1437 code from reset_lwp_ptrace_options_callback.
1438
1439 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1440
1441 * linux-arm-low.c (struct update_registers_data): Remove.
1442 (update_registers_callback): Return void, take arguments
1443 directly, don't check thread's pid.
1444 (arm_insert_point, arm_remove_point): Use for_each_thread.
1445
1446 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1447
1448 * win32-low.c (continue_one_thread): Return void, take argument
1449 directly.
1450 (child_continue): Use for_each_thread.
1451
1452 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1453
1454 * win32-i386-low.c (update_debug_registers_callback): Rename
1455 to ...
1456 (update_debug_registers): ... this, return void, remove pid_p arg.
1457 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1458
1459 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1460
1461 * inferiors.h (struct process_info): Add constructor, initialize
1462 fields..
1463 <syscalls_to_catch>: Change type to std::vector<int>.
1464 * inferiors.c (add_process): Allocate process_info with new.
1465 (remove_process): Free process_info with delete.
1466 * linux-low.c (handle_extended_wait): Adjust.
1467 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1468 * server.c (handle_general_set): Adjust.
1469
1470 2017-11-16 Pedro Alves <palves@redhat.com>
1471
1472 * remote-utils.c (remote_close): Block SIGIO signals instead of
1473 uninstalling the SIGIO handler.
1474
1475 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1476
1477 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1478
1479 2017-11-16 Yao Qi <yao.qi@linaro.org>
1480
1481 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1482 (tic6x_store_gregset): Likewise.
1483 (tic6x_usrregs_info): Move it up.
1484
1485 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1486
1487 * Makefile.in: Update arch rules.
1488 * configure.srv: Explicitly mark arch/ files.
1489
1490 2017-11-13 Andreas Schwab <schwab@suse.de>
1491
1492 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1493 function.
1494 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1495
1496 2017-11-06 Pedro Alves <palves@redhat.com>
1497
1498 * config.in, configure: Regenerate.
1499
1500 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1501
1502 * target.c (struct thread_search): Remove.
1503 (thread_search_callback): Remove.
1504 (prepare_to_access_memory): Use for_each_thread instead of
1505 find_inferior. Inline code from thread_search_callback.
1506
1507 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1508
1509 * server.c (struct visit_actioned_threads_data): Remove.
1510 (visit_actioned_threads): Change prototype to take arguments
1511 directly.
1512 (resume): Use find_thread instead of find_inferior.
1513
1514 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1515
1516 * server.c (queue_stop_reply_callback): Change prototype, return
1517 void.
1518 (find_status_pending_thread_callback): Remove.
1519 (handle_status): Replace find_inferior with find_thread and
1520 for_each_thread.
1521
1522 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1523
1524 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1525 with REGNO.
1526 (aarch64_store_gregset): Likewise.
1527 (aarch64_fill_fpregset): Likewise.
1528 (aarch64_store_fpregset): Likewise.
1529
1530 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1531
1532 * gdbthread.h (find_thread, for_each_thread): New functions.
1533 * inferiors.c (thread_of_pid): Remove.
1534 (find_any_thread_of_pid): Use find_thread.
1535 * linux-low.c (num_lwps): Use for_each_thread.
1536
1537 2017-10-17 Yao Qi <yao.qi@linaro.org>
1538
1539 * Makefile.in: Remove one rule.
1540 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1541
1542 2017-10-17 Yao Qi <yao.qi@linaro.org>
1543
1544 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1545 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1546
1547 2017-10-17 Yao Qi <yao.qi@linaro.org>
1548
1549 * configure.srv: Rename arm.o with arch/arm.o.
1550
1551 2017-10-17 Yao Qi <yao.qi@linaro.org>
1552
1553 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1554 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1555 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1556 (arch-i386.o, arch-amd64.o): Remove rules.
1557 (arch/%.o): New rule.
1558 Update POSTCOMPILE and COMPILE.pre.
1559 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1560 * configure: Re-generated.
1561 * configure.srv: Replace arch-i386.o with arch/i386.o.
1562 Replace arch-amd64.o with arch/amd64.o.
1563
1564 2017-10-16 Yao Qi <yao.qi@linaro.org>
1565
1566 * configure: Regenerated.
1567
1568 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1569
1570 * inferiors.h: (struct inferior_list): Remove.
1571 (struct inferior_list_entry); Remove.
1572 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
1573 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
1574 get_first_inferior): Remove.
1575 (for_each_inferior, for_each_inferior_with_data, find_inferior,
1576 find_inferior_id, find_inferior_in_random): Change signature.
1577 * inferiors.c (all_threads): Change type to
1578 std::list<thread_info *>.
1579 (get_thread): Remove macro.
1580 (find_inferior, find_inferior_id): Change signature, implement
1581 using find_thread.
1582 (find_inferior_in_random): Change signature, implement using
1583 find_thread_in_random.
1584 (for_each_inferior, for_each_inferior_with_data): Change
1585 signature, implement using for_each_thread.
1586 (add_inferior_to_list, remove_inferior): Remove.
1587 (add_thread, get_first_thread, thread_of_pid,
1588 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
1589 (get_first_inferior, one_inferior_p, clear_inferior_list):
1590 Remove.
1591 (clear_inferiors, get_thread_process): Update.
1592 * gdbthread.h: Include <list>.
1593 (struct thread_info) <entry>: Remove field.
1594 <id>: New field.
1595 (all_threads): Change type to std::list<thread_info *>.
1596 (get_first_inferior): Add doc.
1597 (find_thread, for_each_thread, find_thread_in_random): New
1598 functions.
1599 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
1600 * linux-arm-low.c (update_registers_callback): Update.
1601 * linux-low.c (second_thread_of_pid_p): Update.
1602 (kill_one_lwp_callback, linux_detach_lwp_callback,
1603 delete_lwp_callback, status_pending_p_callback, same_lwp,
1604 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
1605 iterate_over_lwps, not_stopped_callback,
1606 resume_stopped_resumed_lwps, count_events_callback,
1607 select_singlestep_lwp_callback, select_event_lwp_callback,
1608 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
1609 suspend_and_send_sigstop_callback, wait_for_sigstop,
1610 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
1611 lwp_running, linux_set_resume_request, resume_status_pending_p,
1612 need_step_over_p, start_step_over, linux_resume_one_thread,
1613 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
1614 reset_lwp_ptrace_options_callback): Update.
1615 * linux-mips-low.c (update_watch_registers_callback): Update.
1616 * regcache.c (regcache_invalidate_one, regcache_invalidate):
1617 Update.
1618 (free_register_cache_thread_one): Remove.
1619 (regcache_release): Update.
1620 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
1621 handle_qxfer_threads_worker): Update.
1622 (handle_query): Update, use list iterator.
1623 (visit_actioned_threads, handle_pending_status,
1624 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
1625 clear_pending_status_callback, set_pending_status_callback,
1626 find_status_pending_thread_callback, handle_status,
1627 process_serial_event): Update.
1628 * target.c (thread_search_callback): Update.
1629 * thread-db.c (thread_db_get_tls_address): Update.
1630 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
1631 Update.
1632 * win32-i386-low.c (update_debug_registers_callback): Update.
1633 * win32-low.c (delete_thread_info, child_delete_thread,
1634 continue_one_thread, suspend_one_thread,
1635 get_child_debug_event): Adjust.
1636
1637 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1638
1639 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
1640 * inferiors.h: Include <list>.
1641 (struct process_info) <entry>: Remove field.
1642 <pid>: New field.
1643 (pid_of): Change macro to function.
1644 (ptid_of, lwpid_of): Remove macro.
1645 (all_processes): Change type to std::list<process_info *>.
1646 (ALL_PROCESSES): Remove macro.
1647 (for_each_process, find_process): New function.
1648 * inferiors.c (all_processes): Change type to
1649 std::list<process_info *>.
1650 (find_thread_process): Adjust.
1651 (add_process): Likewise.
1652 (remove_process): Likewise.
1653 (find_process_pid): Likewise.
1654 (get_first_process): Likewise.
1655 (started_inferior_callback): Remove.
1656 (have_started_inferiors_p): Adjust.
1657 (attached_inferior_callback): Remove.
1658 (have_attached_inferiors_p): Adjust.
1659 * linux-low.c (check_zombie_leaders): Likewise.
1660 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
1661 (x86_linux_update_xmltarget): Adjust.
1662 * server.c (handle_query): Likewise.
1663 (gdb_reattached_process): Remove.
1664 (handle_status): Adjust.
1665 (kill_inferior_callback): Likewise.
1666 (detach_or_kill_inferior): Remove.
1667 (print_started_pid): Likewise.
1668 (print_attached_pid): Likewise.
1669 (detach_or_kill_for_exit): Update.
1670 (process_serial_event): Likewise.
1671 * linux-arm-low.c (arm_new_fork): Likewise.
1672
1673 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1674
1675 * dll.h: Include <list>.
1676 (struct dll_info): Add constructor.
1677 <entry>: Remove field.
1678 (all_dlls): Change type to std::list<dll_info>.
1679 * dll.c: Include <algorithm>.
1680 (get_dll): Remove macro.
1681 (all_dlls): Change type to std::list<dll_info *>.
1682 (free_one_dll): Remove.
1683 (match_dll): Likewise.
1684 (loaded_dll): Adjust.
1685 (unloaded_dll): Adjust to all_dlls type change, use
1686 std::find_if. Inline code from match_dll.
1687 (clear_dlls): Adjust to all_dlls type change.
1688 * server.c (emit_dll_description): Remove.
1689 (handle_qxfer_libraries): Adjust to all_dlls type change,
1690 integrate emit_dll_description's functionality.
1691
1692 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1693
1694 * linux-low.h (struct linux_target_ops) <delete_process>: New
1695 field.
1696 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
1697 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
1698 (struct linux_target_ops): Add delete_process callback.
1699 * linux-arm-low.c (arm_delete_process): New.
1700 (struct linux_target_ops): Add delete_process callback.
1701 * linux-bfin-low.c (struct linux_target_ops): Likewise.
1702 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
1703 * linux-m32r-low.c (struct linux_target_ops): Likewise.
1704 * linux-mips-low.c (mips_linux_delete_process): New.
1705 (struct linux_target_ops): Add delete_process callback.
1706 * linux-ppc-low.c (struct linux_target_ops): Likewise.
1707 * linux-s390-low.c (struct linux_target_ops): Likewise.
1708 * linux-sh-low.c (struct linux_target_ops): Likewise.
1709 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
1710 * linux-tile-low.c (struct linux_target_ops): Likewise.
1711 * linux-x86-low.c (x86_linux_delete_process): New.
1712 (struct linux_target_ops): Add delete_process callback.
1713 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
1714
1715 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
1716
1717 * linux-aarch64-low.c (the_low_target): Add thread delete
1718 callback.
1719 * linux-arm-low.c (arm_delete_thread): New function.
1720 (the_low_target): Add thread delete callback.
1721 * linux-bfin-low.c (the_low_target): Likewise.
1722 * linux-crisv32-low.c (the_low_target): Likewise.
1723 * linux-low.c (delete_lwp): Invoke delete_thread callback if
1724 set.
1725 * linux-low.h (struct linux_target_ops) <delete_thread>: New
1726 field.
1727 * linux-m32r-low.c (the_low_target): Add thread delete callback.
1728 * linux-mips-low.c (mips_linux_delete_thread): New function.
1729 (the_low_target): Add thread delete callback.
1730 * linux-ppc-low.c (the_low_target): Likewise.
1731 * linux-s390-low.c (the_low_target): Likewise.
1732 * linux-sh-low.c (the_low_target): Likewise.
1733 * linux-tic6x-low.c (the_low_target): Likewise.
1734 * linux-tile-low.c (the_low_target): Likewise.
1735 * linux-x86-low.c (the_low_target): Likewise.
1736 * linux-xtensa-low.c (the_low_target): Likewise.
1737
1738 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
1739
1740 * win32-low.c: Include "common-inferior.h".
1741
1742 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1743
1744 * inferiors.c (set_inferior_cwd): New function.
1745 * server.c (handle_general_set): Handle QSetWorkingDir packet.
1746 (handle_query): Inform that QSetWorkingDir is supported.
1747 * win32-low.c (create_process): Pass the inferior's cwd to
1748 CreateProcess.
1749
1750 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1751
1752 * inferiors.c (current_inferior_cwd): New global variable.
1753 (get_inferior_cwd): New function.
1754 * inferiors.h (struct process_info) <cwd>: New field.
1755
1756 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
1757
1758 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
1759 (OBS): Add gdb_tilde_expand.o.
1760
1761 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
1762
1763 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
1764 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
1765
1766 2017-09-29 Pedro Alves <palves@redhat.com>
1767
1768 * ax.c (gdb_parse_agent_expr): Constify.
1769 * ax.h (gdb_parse_agent_expr): Constify.
1770 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
1771 Constify.
1772 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
1773 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
1774 * remote-utils.h (read_ptid): Constify.
1775 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
1776 (process_point_options, process_serial_event): Constify.
1777 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
1778 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
1779 (cmd_qtbuffer): Constify.
1780
1781 2017-09-29 Pedro Alves <palves@redhat.com>
1782
1783 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
1784 fails.
1785
1786 2017-09-29 Pedro Alves <palves@redhat.com>
1787
1788 * linux-low.c (handle_extended_wait): Pass parent thread instead
1789 of process to thread_db_notice_clone.
1790 * linux-low.h (thread_db_notice_clone): Replace parent process
1791 parameter with parent thread parameter.
1792 * thread-db.c (find_one_thread): Add comment.
1793 (thread_db_notice_clone): Replace parent process parameter with
1794 parent thread parameter. Temporarily switch to the parent thread.
1795
1796 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
1797
1798 * gdbthread.h: Include "common-gdbthread.h".
1799 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
1800 "if" when validating the ptid.
1801 * remote-utils.c: Include "gdbthread.h".
1802 (prepare_resume_reply): Use "switch_to_thread".
1803 * target.c (done_accessing_memory): Likewise.
1804
1805 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
1806
1807 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
1808 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
1809 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
1810 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
1811 s390x-gs-linux64-ipa.o to ipa_obj.
1812 * linux-s390-low.c (HWCAP_S390_GS): New define.
1813 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
1814 New functions.
1815 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
1816 (s390_arch_setup): Check for guarded-storage support and choose
1817 appropriate tdesc.
1818 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
1819 init_registers_s390x_gs_linux64.
1820 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
1821 enum value.
1822 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
1823 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
1824
1825 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
1826
1827 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
1828
1829 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1830
1831 * linux-low.h (struct lwp_info): Add new field, thread_handle.
1832 (thread_db_thread_handle): Declare.
1833 * linux-low.c (linux_target_ops): Initialize thread_handle.
1834 * server.c (handle_qxfer_threads_worker): Add support for
1835 "handle" attribute.
1836 * target.h (struct target_ops): Add new function pointer,
1837 thread_handle.
1838 (target_thread_handle): Define.
1839 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
1840 field in lwp.
1841 (thread_db_thread_handle): New function.
1842
1843 2017-09-21 Kevin Buettner <kevinb@redhat.com>
1844
1845 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
1846 * linux-low.h (thread_db_notice_clone): Declare.
1847 * thread-db.c (thread_db_notice_clone): New function.
1848
1849 2017-09-21 Pedro Alves <palves@redhat.com>
1850
1851 * server.c (gdb_read_memory, handle_status, process_serial_event)
1852 (handle_serial_event, handle_target_event): Adjust to
1853 set_desired_thread prototype change.
1854 * target.c (set_desired_thread): Remove 'use_general' parameter
1855 and adjust.
1856 * target.h (set_desired_thread): Remove 'use_general' parameter.
1857
1858 2017-09-20 Tom Tromey <tom@tromey.com>
1859
1860 * target.c (target_terminal::terminal_state): Define.
1861 (target_terminal::init): Rename from target_terminal_init.
1862 (target_terminal::inferior): Rename from
1863 target_terminal_inferior.
1864 (target_terminal::ours): Rename from target_terminal_ours.
1865 (target_terminal::ours_for_output, target_terminal::info): New.
1866
1867 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1868
1869 * server.c (accumulate_file_name_length): Remove.
1870 (emit_dll_description): Adjust to std::string change.
1871 (handle_qxfer_libraries): Use std::string to hold document.
1872
1873 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1874
1875 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
1876 return type of xml_escape_text.
1877 * server.c (emit_dll_description): Likewise.
1878
1879 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
1880
1881 * server.c (captured_main): Accept argument for --selftest.
1882 Update run_tests call.
1883 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
1884 when registering selftests.
1885
1886 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
1887
1888 * regcache.c (get_thread_regcache): Update code to use "std::vector"
1889 instead of "VEC" for "target_desc.reg_defs".
1890 (regcache_cpy): Likewise.
1891 (registers_to_string): Likewise.
1892 (registers_from_string): Likewise.
1893 (find_regno): Likewise.
1894 (supply_regblock): Likewise.
1895 (regcache_raw_read_unsigned): Likewise.
1896 * tdesc.c (init_target_desc): Likewise.
1897 (tdesc_create_reg): Likewise.
1898 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
1899 (struct target_desc) <reg_defs>: Convert to "std::vector".
1900 (target_desc): Do not initialize "reg_defs".
1901 (~target_desc): Update code to use "std::vector" instead of "VEC"
1902 for "target_desc.reg_defs".
1903 (operator==): Likewise.
1904
1905 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1906
1907 * inferiors.h (thread_to_gdb_id): Remove.
1908 * inferiors.c (thread_to_gdb_id): Remove.
1909 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
1910 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
1911 lynx_store_registers, lynx_read_memory, lynx_write_memory):
1912 Likewise.
1913 * nto-low.c (nto_fetch_registers, nto_store_registers,
1914 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
1915
1916 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1917
1918 * inferiors.h (gdb_id_to_thread_id): Remove.
1919 * inferiors.c (gdb_id_to_thread_id): Remove.
1920 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
1921 removal. Move pid declaration closer to where it's used.
1922
1923 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1924
1925 * server.c (handle_detach): New function.
1926 (process_serial_event): Move code out, call handle_detach.
1927
1928 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1929
1930 * server.c (require_running): Rename to ...
1931 (require_running_or_return): ... this ...
1932 (require_running_or_break): ... and this.
1933 (handle_query, process_serial_event): Adjust.
1934
1935 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1936
1937 * linux-low.c (linux_set_resume_request): Remove unused
1938 variables.
1939
1940 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
1941
1942 * server.c (first_thread_of): Remove.
1943 (process_serial_event): Replace usage of first_thread_of with
1944 find_any_thread_of_pid.
1945 * tracepoint.c (same_process_p): Remove.
1946 (gdb_agent_about_to_close): Replace usage of same_process_p with
1947 find_any_thread_of_pid.
1948 * linux-x86-low.c (same_process_callback): Remove.
1949 (x86_arch_setup_process_callback): Replace usage of
1950 same_process_callback with find_any_thread_of_pid.
1951 * thread-db.c (any_thread_of): Remove.
1952 (switch_to_process): Replace usage of any_thread_of with
1953 find_any_thread_of_pid.
1954 * inferiors.c (thread_pid_matches_callback): Remove.
1955 (find_thread_process): Adjust to use find_any_thread_of_pid.
1956
1957 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1958
1959 * regcache.c (get_thread_regcache): Guard calls to "memset"
1960 with "!VEC_empty".
1961
1962 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
1963
1964 * linux-low.c (handle_extended_wait): Use
1965 "allocate_target_description" instead of "XNEW".
1966 * linux-x86-low.c (initialize_low_arch): Likewise.
1967
1968 2017-09-05 Yao Qi <yao.qi@linaro.org>
1969
1970 * configure.srv (srv_i386_regobj): Remove.
1971 (srv_amd64_regobj): Remove.
1972 (srv_regobj): Set it to "" for x86 non-linux targets.
1973 * linux-x86-tdesc.c (i386_linux_read_description):
1974 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
1975 (init_registers_i386): Remove the declaration.
1976 (tdesc_i386): Remove the declaration.
1977 (lynx_i386_arch_setup): Call i386_create_target_description.
1978 * nto-x86-low.c: Likewise.
1979 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
1980 [!__x86_64__]: include arch/i386.h.
1981 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
1982
1983 2017-09-05 Yao Qi <yao.qi@linaro.org>
1984
1985 * configure.srv (srv_amd64_linux_xmlfiles): Remove
1986 i386/amd64-XXX-linux from it.
1987
1988 2017-09-05 Yao Qi <yao.qi@linaro.org>
1989
1990 * configure.srv: Empty srv_amd64_linux_regobj if $development is
1991 false.
1992 (ipa_amd64_linux_regobj): Remove.
1993 (ipa_x32_linux_regobj): Remove.
1994
1995 2017-09-05 Yao Qi <yao.qi@linaro.org>
1996
1997 * Makefile.in (arch-amd64.o): New rule.
1998 * configure.srv: Append arch-amd64.o.
1999 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2000 (get_ipa_tdesc): Call amd64_linux_read_description.
2001 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2002 and init_registers_amd64_XXX.
2003 * linux-x86-low.c (x86_linux_read_description): Call
2004 amd64_linux_read_description.
2005 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2006 (initialize_low_arch): Don't call init_registers_x32_XXX and
2007 init_registers_amd64_XXX.
2008 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2009 and tdesc_amd64_XXX.
2010 [__x86_64__] (amd64_tdesc_test): New function.
2011 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2012 and init_registers_amd64_XXX.
2013 * linux-x86-tdesc.c: Include arch/amd64.h.
2014 (xcr0_to_tdesc_idx): New function.
2015 (i386_linux_read_description): New function.
2016 (amd64_get_ipa_tdesc_idx): New function.
2017 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2018 (amd64_get_ipa_tdesc): Declare.
2019
2020 2017-09-05 Yao Qi <yao.qi@linaro.org>
2021
2022 * configure.srv (srv_i386_linux_xmlfiles): Remove
2023 i386/i386-XXX-linux.xml from it.
2024
2025 2017-09-05 Yao Qi <yao.qi@linaro.org>
2026
2027 * configure.srv: Set srv_i386_linux_regobj empty if $development
2028 is false.
2029 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2030 initialize_low_tdesc.
2031 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2032 with #if initialize_low_tdesc.
2033 * linux-x86-tdesc-selftest.c: New file.
2034 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2035
2036 2017-09-05 Yao Qi <yao.qi@linaro.org>
2037
2038 * Makefile.in (arch-i386.o): New rule.
2039 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2040 (x86_64-*-linux*): Likewise.
2041 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2042 include arch/i386.h.
2043 (i386_linux_read_description): Remove code and call
2044 i386_create_target_description.
2045 * tdesc.c (allocate_target_description): New function.
2046 * tdesc.h (set_tdesc_architecture): Remove declaration.
2047 (set_tdesc_osabi): Likewise.
2048
2049 2017-09-05 Yao Qi <yao.qi@linaro.org>
2050
2051 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2052 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2053 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2054 .xmltarget.
2055 * server.c (get_features_xml): Call tdesc_get_features_xml.
2056 * tdesc.c (set_tdesc_architecture): New function.
2057 (set_tdesc_osabi): New function.
2058 (tdesc_get_features_xml): New function.
2059 (tdesc_create_feature): Add an argument.
2060 * tdesc.h (struct target_desc) <features>: New field.
2061 <arch, osabi>: New field.
2062 (~target_desc): xfree features, arch, and osabi.
2063 (target_desc::oerator==): Don't compare .xmltarget.
2064 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2065 (set_tdesc_osabi): Likewise.
2066 (tdesc_get_features_xml): Likewise.
2067
2068 2017-09-05 Yao Qi <yao.qi@linaro.org>
2069
2070 * linux-x86-tdesc.c: Include selftest.h.
2071 (i386_tdesc_test): New function.
2072 (initialize_low_tdesc): Call selftests::register_test.
2073 * tdesc.h: Include regdef.h.
2074 (target_desc): Override operator == and !=.
2075
2076 2017-09-05 Yao Qi <yao.qi@linaro.org>
2077
2078 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2079 (ipa_obj): Likewise.
2080 * linux-i386-ipa.c: Include common/x86-xstate.h
2081 (get_ipa_tdesc): Call i386_linux_read_description.
2082 (initialize_low_tracepoint): Don't call init_registers_XXX
2083 functions, call initialize_low_tdesc instead.
2084 * linux-x86-low.c (x86_linux_read_description): Call
2085 i386_linux_read_description.
2086 (initialize_low_arch): Don't call init_registers_i386_XXX
2087 functions, call initialize_low_tdesc.
2088 * linux-x86-tdesc.c: New file.
2089 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2090 (i386_get_ipa_tdesc_idx): Declare.
2091 (i386_get_ipa_tdesc): Declare.
2092 (initialize_low_tdesc): Declare.
2093
2094 2017-09-05 Yao Qi <yao.qi@linaro.org>
2095
2096 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2097 instead of 0.
2098
2099 2017-09-05 Yao Qi <yao.qi@linaro.org>
2100
2101 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2102 * regcache.c (get_thread_regcache): Use VEC_length.
2103 (init_register_cache): Likewise.
2104 (regcache_cpy): Likewise.
2105 (registers_to_string): Iterate reg_defs via VEC_iterate.
2106 (find_regno): Likewise.
2107 (find_register_by_number): Use VEC_index.
2108 (register_size): Call find_register_by_number.
2109 (register_data): Call find_register_by_number.
2110 (supply_regblock): Use VEC_length.
2111 (regcache_raw_read_unsigned): Likewise.
2112 * tdesc.c (init_target_desc): Iterate reg_defs via
2113 VEC_iterate.
2114 (default_description): Update initializer.
2115 (copy_target_description): Don't update field num_registers.
2116 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2117 <num_registers>: Remove.
2118
2119 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2120
2121 * Makefile.in (.SECONDARY): Define target.
2122
2123 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2124
2125 * linux-low.c (linux_wait_1): Adjust.
2126 * server.c (queue_stop_reply_callback): Adjust.
2127
2128 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2129
2130 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2131 QEnvironmentUnset and QEnvironmentReset packets.
2132 (handle_query): Inform remote that QEnvironmentHexEncoded,
2133 QEnvironmentUnset and QEnvironmentReset are supported.
2134
2135 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2136
2137 * inferiors.h (inferior_target_data): Rename to ...
2138 (thread_target_data): ... this.
2139 (inferior_regcache_data): Rename to ...
2140 (thread_regcache_data): ... this.
2141 (set_inferior_regcache_data): Rename to ...
2142 (set_thread_regcache_data): ... this.
2143 * inferiors.c (inferior_target_data): Rename to ...
2144 (thread_target_data): ... this.
2145 (inferior_regcache_data): Rename to ...
2146 (thread_regcache_data): ... this.
2147 (set_inferior_regcache_data): Rename to ...
2148 (set_thread_regcache_data): ... this.
2149 (free_one_thread): Update.
2150 * linux-low.h (get_thread_lwp): Update.
2151 * regcache.c (get_thread_regcache): Update.
2152 (regcache_invalidate_thread): Update.
2153 (free_register_cache_thread): Update.
2154 * win32-i386-low.c (update_debug_registers_callback): Update.
2155 (win32_get_current_dr): Update.
2156 * win32-low.c (thread_rec): Update.
2157 (delete_thread_info): Update.
2158 (continue_one_thread): Update.
2159 (suspend_one_thread): Update.
2160
2161 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2162
2163 * inferiors.c (set_inferior_target_data): Remove.
2164 * inferiors.h (set_inferior_target_data): Remove.
2165
2166 2017-08-18 Yao Qi <yao.qi@linaro.org>
2167
2168 * Makefile.in (OBS): Add selftest.o.
2169 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2170 * configure, config.in: Re-generated.
2171 * server.c: Include common/sefltest.h.
2172 (captured_main): Handle option --selftest.
2173
2174 2017-08-09 Yao Qi <yao.qi@linaro.org>
2175
2176 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2177 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2178 i386-avx-mpx.o and i386-mmx.o.
2179 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2180 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2181 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2182 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2183 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2184 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2185 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2186 i386/amd64-avx-mpx.xml.
2187
2188 2017-08-09 Yao Qi <yao.qi@linaro.org>
2189
2190 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2191 and x32-avx-avx512.o.
2192 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2193 i386/x32-avx-avx512.xml.
2194
2195 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2196
2197 * tracepoint.h (enum class fast_tpoint_collect_result): New
2198 enumeration.
2199 (fast_tracepoint_collecting): Change return type to
2200 fast_tpoint_collect_result.
2201 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2202 * linux-low.h: Include tracepoint.h.
2203 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2204 fast_tpoint_collect_result.
2205 * linux-low.c (handle_tracepoints): Adjust.
2206 (linux_fast_tracepoint_collecting): Change return type to
2207 fast_tpoint_collect_result.
2208 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2209 linux_wait_1, stuck_in_jump_pad_callback,
2210 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2211 proceed_one_lwp): Adjust to type change.
2212
2213 2017-07-10 Yao Qi <yao.qi@linaro.org>
2214
2215 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2216
2217 2017-06-29 Yao Qi <yao.qi@linaro.org>
2218
2219 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2220 Remove.
2221 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2222
2223 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2224
2225 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2226
2227 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2228
2229 * linux-low.c (linux_create_inferior): Adjust code to access the
2230 environment information via 'gdb_environ' class.
2231 * lynx-low.c (lynx_create_inferior): Likewise.
2232 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2233 (get_environ): Return a pointer to 'our_environ'.
2234 (captured_main): Initialize 'our_environ'.
2235 * server.h (get_environ): Adjust prototype.
2236 * spu-low.c (spu_create_inferior): Adjust code to access the
2237 environment information via 'gdb_environ' class.
2238
2239 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2240
2241 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2242 usage of "register" keyword.
2243
2244 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2245
2246 * configure: Re-generate.
2247
2248 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2249
2250 * configure: Re-generate.
2251
2252 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2253
2254 * Makefile.in (COMPILE.pre): Add "-x c++".
2255
2256 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2257
2258 * fork-child.c: Conditionally include <signal.h>.
2259
2260 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2261
2262 * server.c (handle_general_set): Handle new packet
2263 "QStartupWithShell".
2264 (handle_query): Add "QStartupWithShell" to the list of supported
2265 packets.
2266 (gdbserver_usage): Add help text explaining the
2267 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2268 options.
2269 (captured_main): Recognize and act upon the presence of the new
2270 CLI options.
2271
2272 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2273 Pedro Alves <palves@redhat.com>
2274
2275 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2276 * configure: Regenerate.
2277 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2278 "fork-inferior.o".
2279 (i[34567]86-*-lynxos*): Likewise.
2280 (spu*-*-*): Likewise.
2281 * fork-child.c: New file.
2282 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2283 and "environ.h".
2284 (linux_ptrace_fun): New function.
2285 (linux_create_inferior): Adjust function prototype to reflect
2286 change on "target.h". Adjust function code to use
2287 "fork_inferior".
2288 (linux_request_interrupt): Delete "signal_pid".
2289 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2290 (lynx_ptrace_fun): New function.
2291 (lynx_create_inferior): Adjust function prototype to reflect
2292 change on "target.h". Adjust function code to use
2293 "fork_inferior".
2294 * nto-low.c (nto_create_inferior): Adjust function prototype and
2295 code to reflect change on "target.h". Update comments.
2296 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2297 "common-terminal.h" and "environ.h".
2298 (terminal_fd): Moved to fork-child.c.
2299 (old_foreground_pgrp): Likewise.
2300 (restore_old_foreground_pgrp): Likewise.
2301 (last_status): Make it global.
2302 (last_ptid): Likewise.
2303 (our_environ): New variable.
2304 (startup_with_shell): Likewise.
2305 (program_name): Likewise.
2306 (program_argv): Rename to...
2307 (program_args): ...this.
2308 (wrapper_argv): New variable.
2309 (start_inferior): Delete function.
2310 (get_exec_wrapper): New function.
2311 (get_exec_file): Likewise.
2312 (get_environ): Likewise.
2313 (prefork_hook): Likewise.
2314 (post_fork_inferior): Likewise.
2315 (postfork_hook): Likewise.
2316 (postfork_child_hook): Likewise.
2317 (handle_v_run): Update code to deal with arguments coming from the
2318 remote host. Update calls from "start_inferior" to
2319 "create_inferior".
2320 (captured_main): Likewise. Initialize environment variable. Call
2321 "have_job_control".
2322 * server.h (post_fork_inferior): New prototype.
2323 (get_environ): Likewise.
2324 (last_status): Declare.
2325 (last_ptid): Likewise.
2326 (signal_pid): Likewise.
2327 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2328 (spu_ptrace_fun): New function.
2329 (spu_create_inferior): Adjust function prototype to reflect change
2330 on "target.h". Adjust function code to use "fork_inferior".
2331 * target.c (target_terminal_init): New function.
2332 (target_terminal_inferior): Likewise.
2333 (target_terminal_ours): Likewise.
2334 * target.h: Include <vector>.
2335 (struct target_ops) <create_inferior>: Update prototype.
2336 (create_inferior): Update macro.
2337 * utils.c (gdb_flush_out_err): New function.
2338 * win32-low.c (win32_create_inferior): Adjust function prototype
2339 and code to reflect change on "target.h".
2340
2341 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2342
2343 * inferiors.c (switch_to_thread): New function.
2344
2345 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2346
2347 * Makefile.in (SFILE): Add "common/job-control.c".
2348 (OBS): Add "job-control.o".
2349
2350 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2351
2352 * Makefile: Remove "@host_makefile_frag@".
2353
2354 2017-05-05 Pedro Alves <palves@redhat.com>
2355
2356 * configure: Regenerate.
2357
2358 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2359
2360 * configure: Regenerate.
2361
2362 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2363
2364 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2365 software_single_step change of return type to
2366 std::vector<CORE_ADDR>.
2367 * linux-low.c (install_software_single_step_breakpoints):
2368 Likewise.
2369 * linux-low.h (install_software_single_step_breakpoints):
2370 Likewise.
2371
2372 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2373
2374 * remote-utils.c: Include "gdb_termios.h" instead of
2375 "terminal.h".
2376 * terminal.h: Delete file.
2377
2378 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2379
2380 * server.c: Include <vector>.
2381 <program_argv, wrapper_argv>: Convert to std::vector.
2382 (start_inferior): Rewrite function to use C++.
2383 (handle_v_run): Likewise. Update code that calculates the argv
2384 based on the vRun packet; use C++.
2385 (captured_main): Likewise.
2386
2387 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2388
2389 * server.c (handle_v_cont): Initialize thread_resume::thread
2390 with null_ptid.
2391
2392 2017-04-05 Pedro Alves <palves@redhat.com>
2393
2394 * configure: Regenerate.
2395
2396 2017-04-05 Pedro Alves <palves@redhat.com>
2397
2398 * gdbreplay.c (sync_error): Constify.
2399 * linux-x86-low.c (push_opcode): Constify.
2400
2401 2017-04-05 Pedro Alves <palves@redhat.com>
2402
2403 * win32-low.c (get_child_debug_event)
2404 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2405 Report TARGET_WAITKIND_SPURIOUS instead.
2406
2407 2017-04-05 Pedro Alves <palves@redhat.com>
2408
2409 * remote-utils.c (remote_prepare, remote_open): Constify.
2410 * remote-utils.h (remote_prepare, remote_open): Constify.
2411 * server.c (captured_main): Constify 'port' handling.
2412
2413 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2414
2415 * Makefile.in (clean): Clear .deps.
2416
2417 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2418
2419 * .gitignore: Remove generated files, replace with wildcard.
2420 * (clean): Replace removal of generated files with wildcard.
2421 (version.c): Replace with...
2422 (version-generated.c): ...this.
2423 (xml-builtin.c): Replace with...
2424 (xml-builtin-generated.c): ...this.
2425 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2426 (%.c: *regformats*): Replace with...
2427 (%-generated.c: *regformats*): ...this.
2428
2429 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2430
2431 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2432 (xtensa_fill_gregset): Call collect_register_by_name for
2433 threadptr register.
2434 (xtensa_store_gregset): Call supply_register_by_name for
2435 threadptr register.
2436
2437 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2438
2439 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2440 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2441 (xtensa_store_gregset): Call supply_register for all registers in
2442 a0_regnum..a0_regnum + C0_NREGS range.
2443
2444 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2445
2446 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2447 (ax-ipa.o: ax.c): Remove.
2448 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2449 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2450 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2451 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2452 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2453
2454 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2455
2456 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2457 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2458 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2459 (errors-ipa.o: ../common/errors.c): Remove.
2460 (format-ipa.o: ../common/format.c): Remove.
2461 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2462
2463 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2464
2465 * Makefile.in (%-ipa.o: %.c): New rule.
2466 (tracepoint-ipa.o: tracepoint.c): Remove.
2467 (utils-ipa.o: utils.c): Remove.
2468 (remote-utils-ipa.o: remote-utils.c): Remove.
2469 (regcache-ipa.o: regcache.c): Remove.
2470 (i386-linux-ipa.o: i386-linux.c): Remove.
2471 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2472 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2473 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2474 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2475 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2476 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2477 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2478 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2479 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2480 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2481 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2482 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2483 (aarch64-ipa.o: aarch64.c): Remove.
2484 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2485 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2486 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2487 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2488 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2489 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2490 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2491 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2492 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2493 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2494 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2495 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2496 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2497 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2498 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2499 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2500 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2501 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2502 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2503 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2504 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2505 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2506 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2507 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2508 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2509 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2510 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2511 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2512 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2513 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2514 (tdesc-ipa.o: tdesc.c): Remove.
2515 (x32-linux-ipa.o: x32-linux.c): Remove.
2516 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2517 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2518
2519 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2520
2521 * Makefile.in (%.o: ../arch/%.c): New rule.
2522 (arm.o: ../arch/arm.c): Remove.
2523 (arm-linux.o: ../arch/arm-linux.c): Remove.
2524 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2525 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2526
2527 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2528
2529 * Makefile.in (%.o: ../nat/%.c): New rule.
2530 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2531 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2532 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2533 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2534 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2535 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2536 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2537 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2538 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2539 (linux-personality.o: ../nat/linux-personality.c): Remove.
2540 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2541 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2542 (x86-linux.o: ../nat/x86-linux.c): Remove.
2543 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2544 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2545
2546 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2547
2548 * Makefile.in (%.o: ../common/%.c): New rule.
2549 (signals.o: ../common/signals.c): Remove.
2550 (print-utils.o: ../common/print-utils.c): Remove.
2551 (rsp-low.o: ../common/rsp-low.c): Remove.
2552 (common-utils.o: ../common/common-utils.c): Remove.
2553 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2554 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2555 (vec.o: ../common/vec.c): Remove.
2556 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2557 (xml-utils.o: ../common/xml-utils.c): Remove.
2558 (ptid.o: ../common/ptid.c): Remove.
2559 (buffer.o: ../common/buffer.c): Remove.
2560 (format.o: ../common/format.c): Remove.
2561 (filestuff.o: ../common/filestuff.c): Remove.
2562 (agent.o: ../common/agent.c): Remove.
2563 (errors.o: ../common/errors.c): Remove.
2564 (environ.o: ../common/environ.c): Remove.
2565 (common-debug.o: ../common/common-debug.c): Remove.
2566 (cleanups.o: ../common/cleanups.c): Remove.
2567 (common-exceptions.o: ../common/common-exceptions.c): Remove.
2568 (fileio.o: ../common/fileio.c): Remove.
2569 (common-regcache.o: ../common/common-regcache.c): Remove.
2570 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
2571 (new-op.o: ../common/new-op.c): Remove.
2572 (btrace-common.o: ../common/btrace-common.c): Remove.
2573
2574 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2575
2576 * Makefile.in (%.o: ../target/%.c): New rule.
2577 (waitstatus.o: ../target/waitstatus.c): Remove.
2578
2579 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2580
2581 * Makefile.in
2582 (%.c: ../regformats/%.dat,
2583 (%.c: ../regformats/arm/%.dat,
2584 (%.c: ../regformats/i386/%.dat,
2585 (%.c: ../regformats/rs6000/%.dat): New rules.
2586 (aarch64.c): Remove.
2587 (reg-arm.c): Remove.
2588 (arm-with-iwmmxt.c): Remove.
2589 (arm-with-vfpv2.c): Remove.
2590 (arm-with-vfpv3.c): Remove.
2591 (arm-with-neon.c): Remove.
2592 (reg-bfin.c): Remove.
2593 (reg-cris.c): Remove.
2594 (reg-crisv32.c): Remove.
2595 (i386.c): Remove.
2596 (i386-linux.c): Remove.
2597 (i386-avx.c): Remove.
2598 (i386-avx-linux.c): Remove.
2599 (i386-avx-avx512.c): Remove.
2600 (i386-avx-avx512-linux.c): Remove.
2601 (i386-mpx.c): Remove.
2602 (i386-mpx-linux.c): Remove.
2603 (i386-avx-mpx-avx512-pku.c): Remove.
2604 (i386-avx-mpx-avx512-pku-linux.c): Remove.
2605 (i386-avx-mpx.c): Remove.
2606 (i386-avx-mpx-linux.c): Remove.
2607 (i386-mmx.c): Remove.
2608 (i386-mmx-linux.c): Remove.
2609 (reg-ia64.c): Remove.
2610 (reg-m32r.c): Remove.
2611 (reg-m68k.c): Remove.
2612 (reg-cf.c): Remove.
2613 (mips-linux.c): Remove.
2614 (mips-dsp-linux.c): Remove.
2615 (mips64-linux.c): Remove.
2616 (mips64-dsp-linux.c): Remove.
2617 (nios2-linux.c): Remove.
2618 (powerpc-32.c): Remove.
2619 (powerpc-32l.c): Remove.
2620 (powerpc-altivec32l.c): Remove.
2621 (powerpc-cell32l.c): Remove.
2622 (powerpc-vsx32l.c): Remove.
2623 (powerpc-isa205-32l.c): Remove.
2624 (powerpc-isa205-altivec32l.c): Remove.
2625 (powerpc-isa205-vsx32l.c): Remove.
2626 (powerpc-e500l.c): Remove.
2627 (powerpc-64l.c): Remove.
2628 (powerpc-altivec64l.c): Remove.
2629 (powerpc-cell64l.c): Remove.
2630 (powerpc-vsx64l.c): Remove.
2631 (powerpc-isa205-64l.c): Remove.
2632 (powerpc-isa205-altivec64l.c): Remove.
2633 (powerpc-isa205-vsx64l.c): Remove.
2634 (s390-linux32.c): Remove.
2635 (s390-linux32v1.c): Remove.
2636 (s390-linux32v2.c): Remove.
2637 (s390-linux64.c): Remove.
2638 (s390-linux64v1.c): Remove.
2639 (s390-linux64v2.c): Remove.
2640 (s390-te-linux64.c): Remove.
2641 (s390-vx-linux64.c): Remove.
2642 (s390-tevx-linux64.c): Remove.
2643 (s390x-linux64.c): Remove.
2644 (s390x-linux64v1.c): Remove.
2645 (s390x-linux64v2.c): Remove.
2646 (s390x-te-linux64.c): Remove.
2647 (s390x-vx-linux64.c): Remove.
2648 (s390x-tevx-linux64.c): Remove.
2649 (tic6x-c64xp-linux.c): Remove.
2650 (tic6x-c64x-linux.c): Remove.
2651 (tic6x-c62x-linux.c): Remove.
2652 (reg-sh.c): Remove.
2653 (reg-sparc64.c): Remove.
2654 (reg-spu.c): Remove.
2655 (amd64.c): Remove.
2656 (amd64-linux.c): Remove.
2657 (amd64-avx.c): Remove.
2658 (amd64-avx-linux.c): Remove.
2659 (amd64-avx-avx512.c): Remove.
2660 (amd64-avx-avx512-linux.c): Remove.
2661 (amd64-mpx.c): Remove.
2662 (amd64-mpx-linux.c): Remove.
2663 (amd64-avx-mpx-avx512-pku.c): Remove.
2664 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
2665 (amd64-avx-mpx.c): Remove.
2666 (amd64-avx-mpx-linux.c): Remove.
2667 (x32.c): Remove.
2668 (x32-linux.c): Remove.
2669 (x32-avx.c): Remove.
2670 (x32-avx-linux.c): Remove.
2671 (x32-avx-avx512.c): Remove.
2672 (x32-avx-avx512-linux.c): Remove.
2673 (reg-xtensa.c): Remove.
2674 (reg-tilegx.c): Remove.
2675 (reg-tilegx32.c): Remove.
2676
2677 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
2678
2679 * Makefile.in (SFILES): Add "common/environ.c".
2680 (OBJS): Add "common/environ.h".
2681
2682 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
2683
2684 * configure.ac: Check if the fs_base and gs_base members of
2685 `struct user_regs_struct' exist.
2686 * config.in: Regenerated.
2687 * configure: Likewise.
2688
2689 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
2690
2691 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
2692 target_read_memory.
2693 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
2694 (get_next_pcs_syscall_next_pc): Likewise.
2695
2696 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
2697
2698 * win32-i386-low.c: Fix incorrect reference to a couple source files.
2699 * nto-x86-low.c: Likewise.
2700
2701 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
2702
2703 * Makefile.in: Include disable-implicit-rules.mk.
2704
2705 2016-11-23 Pedro Alves <palves@redhat.com>
2706
2707 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
2708 (debug_vprintf): Use std::chrono::steady_clock instead of
2709 gettimeofday. Use '.' instead of ':'.
2710 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
2711 (get_timestamp): Use std::chrono::steady_clock instead of
2712 gettimeofday.
2713
2714 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2715
2716 * Makefile.in: Fix whitespace formatting.
2717
2718 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
2719
2720 * Makefile.in (SFILES, OBS): Flatten list and order
2721 alphabetically.
2722
2723 2016-11-23 Pedro Alves <palves@redhat.com>
2724
2725 * event-loop.c (handle_file_event): Use warning.
2726 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
2727 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2728 Use warning.
2729
2730 2016-11-23 Pedro Alves <palves@redhat.com>
2731
2732 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
2733 output.
2734 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
2735 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
2736 debug_printf and debug_flush for debug output.
2737 * server.c (handle_general_set): Likewise.
2738 * thread-db.c (try_thread_db_load): Use debug_printf for debug
2739 output.
2740
2741 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2742
2743 * Makefile.in (.c.o): Replace rule with ...
2744 (%.o: %.c): ... this one.
2745
2746 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2747
2748 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
2749 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
2750 make.
2751 * configure.ac: Remove checks for the make program.
2752 * configure: Re-generate.
2753
2754 2016-10-28 Pedro Alves <palves@redhat.com>
2755
2756 * Makefile.in (CXX_DIALECT): Get from configure.
2757 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
2758 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
2759 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
2760 * config.in: Regenerate.
2761 * configure: Regenerate.
2762
2763 2016-10-27 Yao Qi <yao.qi@linaro.org>
2764
2765 * linux-low.c (linux_supports_range_stepping): Return true if
2766 can_software_single_step return true.
2767
2768 2016-10-27 Yao Qi <yao.qi@linaro.org>
2769
2770 * inferiors.c (find_inferior_in_random): New function.
2771 * inferiors.h (find_inferior_in_random): Declare.
2772 * linux-low.c (linux_wait_for_event_filtered): Call
2773 find_inferior_in_random instead of find_inferior.
2774
2775 2016-10-27 Yao Qi <yao.qi@linaro.org>
2776
2777 * linux-low.c (linux_wait_1): If single-step breakpoints are
2778 inserted, remove them.
2779
2780 2016-10-26 Pedro Alves <palves@redhat.com>
2781
2782 * linux-low.c (handle_extended_wait): Link parent/child fork
2783 threads.
2784 (linux_wait_1): Unlink them.
2785 (linux_set_resume_request): Ignore resume requests for
2786 already-resumed and unhandled fork child threads.
2787 * linux-low.h (struct lwp_info) <fork_relative>: New field.
2788 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
2789 New functions.
2790 (handle_v_requests) <vCont>: Don't call require_running.
2791 * server.h (in_queued_stop_replies): New declaration.
2792
2793 2016-10-24 Yao Qi <yao.qi@linaro.org>
2794
2795 PR server/20733
2796 * linux-aarch64-low.c (append_insns): Cast the return value to
2797 'uint32_t *'.
2798
2799 2016-10-10 Yao Qi <yao.qi@linaro.org>
2800
2801 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
2802
2803 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
2804
2805 * target.c (target_supports_multi_process): New function, moved
2806 from...
2807 * target.h (target_supports_multi_process): ... here. Remove
2808 macro.
2809
2810 2016-10-05 Tom Tromey <tom@tromey.com>
2811
2812 PR remote/20655:
2813 * tracepoint.c (handle_tracepoint_bkpts): Check
2814 ipa_error_tracepoint, not ipa_stopping_tracepoint.
2815
2816 2016-10-05 Yao Qi <yao.qi@linaro.org>
2817
2818 * configure.srv: Update the path of arm-*.xml files.
2819
2820 2016-10-05 Terry Guo <terry.guo@arm.com>
2821 Yao Qi <yao.qi@linaro.org>
2822
2823 * Makefile.in: Adjust the path of rules.
2824 * configure.srv: Update the path of xml files.
2825 * regformats/arm-with-iwmmxt.dat: Regenerated.
2826 * regformats/arm-with-neon.dat: Likewise.
2827 * regformats/arm-with-vfpv2.dat: Likewise.
2828 * regformats/arm-with-vfpv3.dat Likewise.
2829
2830 2016-09-30 Yao Qi <yao.qi@linaro.org>
2831
2832 PR gdbserver/20627
2833 * target.c (target_stop_and_wait): Don't call
2834 target_continue_no_signal, use resume_stop instead.
2835
2836 2016-09-26 Yao Qi <yao.qi@linaro.org>
2837
2838 * linux-low.c (linux_wait_1): Call debug_exit.
2839
2840 2016-09-23 Pedro Alves <palves@redhat.com>
2841
2842 * Makefile.in (SFILES): Add common/new-op.c.
2843 (OBS): Add common/new-op.o.
2844 (new-op.o): New rule.
2845
2846 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
2847
2848 * .gitinore: Ignore more files.
2849
2850 2016-09-21 Yao Qi <yao.qi@linaro.org>
2851
2852 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
2853 23.
2854
2855 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
2856
2857 * server.c (start_inferior): Call target_mourn_inferior instead of
2858 mourn_inferior; pass ptid_t argument to it.
2859 (resume): Likewise.
2860 (handle_target_event): Likewise.
2861 * target.c (target_mourn_inferior): New function.
2862 * target.h (mourn_inferior): Delete macro.
2863
2864 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
2865
2866 * linux-low.c (lwp_is_stepping): New function.
2867
2868 2016-09-06 Carl Love <cel@us.ibm.com>
2869
2870 * server.c (start_inferior): Fixed comment, requested comment change
2871 didn't get updated correctly. Removed reference to ptrace () call as
2872 it is only true on Linux systems.
2873
2874 2016-09-06 Carl Love <cel@us.ibm.com>
2875
2876 * server.c (start_inferior): Do not call
2877 function target_post_create_inferior () if the
2878 inferior process has already exited.
2879
2880 2016-09-05 Pedro Alves <palves@redhat.com>
2881
2882 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
2883 (COMPILE.pre, CC_LD): Use CXX directly.
2884 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
2885 * acinclude.m4: Don't include build-with-cxx.m4.
2886 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
2887 * configure: Regenerate.
2888
2889 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
2890
2891 PR gdb/19495
2892 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
2893 call writing data to own_buf.
2894
2895 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2896
2897 * target.c (mywait): Call target_wait instead of
2898 the_target->wait.
2899 (target_wait): New function.
2900
2901 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
2902
2903 * server.c (start_inferior): New variable 'ptid'. Replace calls
2904 to the_target->resume by target_continue{,_no_signal}, depending
2905 on the case.
2906 * target.c (target_stop_and_wait): Call target_continue_no_signal
2907 instead of the_target->resume.
2908 (target_continue): New function.
2909
2910 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
2911
2912 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
2913
2914 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
2915
2916 PR server/20491
2917 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
2918 ps_prochandle.
2919 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
2920 * linux-arm-low.c (ps_get_thread_area): Likewise.
2921 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
2922 * linux-m68k-low.c (ps_get_thread_area): Likewise.
2923 * linux-mips-low.c (ps_get_thread_area): Likewise.
2924 * linux-nios2-low.c (ps_get_thread_area): Likewise.
2925 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
2926 * linux-x86-low.c (ps_get_thread_area): Likewise.
2927 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
2928
2929 2016-08-19 Pedro Alves <palves@redhat.com>
2930
2931 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
2932
2933 2016-08-19 Pedro Alves <palves@redhat.com>
2934
2935 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
2936 comment. Use memcpy instead of casting through unsigned long.
2937
2938 2016-08-19 Pedro Alves <palves@redhat.com>
2939
2940 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
2941 allocating around 0x80000000.
2942
2943 2016-08-19 Pedro Alves <palves@redhat.com>
2944
2945 PR gdb/20415
2946 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
2947 (x32-avx512-linux-ipa.o): New rules.
2948 * configure.ac (x86_64-*-linux*): New x32 check.
2949 * configure.srv (ipa_x32_linux_regobj): New.
2950 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
2951 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
2952 descriptions.
2953 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
2954 descriptions.
2955 * configure: Regenerate.
2956
2957 2016-08-09 Pedro Alves <palves@redhat.com>
2958
2959 PR gdb/18653
2960 * Makefile.in (OBS): Add signals-state-save-restore.o.
2961 (signals-state-save-restore.o): New rule.
2962 * config.in: Regenerate.
2963 * configure: Regenerate.
2964 * linux-low.c: Include "signals-state-save-restore.h".
2965 (linux_create_inferior): Call
2966 restore_original_signals_state.
2967 * server.c: Include "dispositions-save-restore.h".
2968 (captured_main): Call save_original_signals_state.
2969
2970 2016-08-05 Pedro Alves <palves@redhat.com>
2971
2972 * configure: Regenerate.
2973
2974 2016-08-04 Yao Qi <yao.qi@linaro.org>
2975
2976 * linux-low.c (regsets_fetch_inferior_registers): Check
2977 errno is ESRCH or not.
2978
2979 2016-08-02 Yao Qi <yao.qi@linaro.org>
2980
2981 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
2982 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
2983 (thread_db_load_search): Update.
2984 (try_thread_db_load_1): Don't look for td_ta_event_addr,
2985 td_ta_set_event and td_ta_event_getmsg.
2986
2987 2016-07-26 Pedro Alves <palves@redhat.com>
2988
2989 PR server/20414
2990 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
2991 of unsigned long for 64-bit registers and use uint32_t instead of
2992 unsigned int for 32-bit registers.
2993
2994 2016-07-26 Pedro Alves <palves@redhat.com>
2995
2996 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
2997 to 'ptrace'.
2998
2999 2016-07-21 Tom Tromey <tom@tromey.com>
3000
3001 * configure: Rebuild.
3002
3003 2016-07-21 Yao Qi <yao.qi@linaro.org>
3004
3005 * mem-break.c (find_gdb_breakpoint): Cast bp to
3006 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3007
3008 2016-07-21 Yao Qi <yao.qi@linaro.org>
3009
3010 * server.c (handle_v_requests): Support s and S actions
3011 if target_supports_software_single_step return true.
3012
3013 2016-07-21 Yao Qi <yao.qi@linaro.org>
3014
3015 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3016 is resume_step, call maybe_hw_step.
3017 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3018 and unstop them.
3019 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3020 breakpoints or not.
3021 (proceed_one_lwp): If resume request is resume_step, install
3022 reinsert breakpoints and call maybe_hw_step.
3023
3024 2016-07-21 Yao Qi <yao.qi@linaro.org>
3025
3026 * linux-low.c (proceed_one_lwp): Declare.
3027 (linux_resume_one_thread): Remove local variable 'step'.
3028 Lift code enqueue signal. Call proceed_one_lwp instead of
3029 linux_resume_one_lwp.
3030
3031 2016-07-21 Yao Qi <yao.qi@linaro.org>
3032
3033 * linux-low.c (linux_resume_one_thread): Call
3034 enqueue_pending_signal.
3035
3036 2016-07-21 Yao Qi <yao.qi@linaro.org>
3037
3038 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3039 * inferiors.c (do_restore_current_thread_cleanup): New function.
3040 (make_cleanup_restore_current_thread): Likewise.
3041 * linux-low.c (install_software_single_step_breakpoints): Call
3042 make_cleanup_restore_current_thread. Switch current_thread to
3043 thread.
3044
3045 2016-07-21 Yao Qi <yao.qi@linaro.org>
3046
3047 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3048 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3049 (clone_one_breakpoint): Likewise.
3050 (delete_reinsert_breakpoints): Change parameter to thread.
3051 Callers updated.
3052 (has_reinsert_breakpoints): Likewise.
3053 (uninsert_reinsert_breakpoints): Likewise.
3054 (reinsert_reinsert_breakpoints): Likewise.
3055 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3056 (delete_reinsert_breakpoints): Likewise.
3057 (reinsert_reinsert_breakpoints): Likewise.
3058 (uninsert_reinsert_breakpoints): Likewise.
3059 (has_reinsert_breakpoints): Likewise.
3060
3061 2016-07-21 Yao Qi <yao.qi@linaro.org>
3062
3063 * inferiors.c (get_thread_process): Make parameter const.
3064 * inferiors.h (get_thread_process): Update declaration.
3065 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3066 Add new parameters child_thread and parent_thread. Callers
3067 updated.
3068 * mem-break.h (clone_all_breakpoints): Update declaration.
3069
3070 2016-07-21 Yao Qi <yao.qi@linaro.org>
3071
3072 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3073 <command_list, handler>: Remove.
3074 (struct gdb_breakpoint): New.
3075 (struct other_breakpoint): New.
3076 (struct reinsert_breakpoint): New.
3077 (is_gdb_breakpoint): New function.
3078 (any_persistent_commands): Update command_list if
3079 is_gdb_breakpoint returns true.
3080 (set_breakpoint): Create breakpoints according to their types.
3081 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3082 (set_gdb_breakpoint_1): Likewise.
3083 (set_gdb_breakpoint): Likewise.
3084 (clear_breakpoint_conditions): Change parameter type to
3085 'struct gdb_breakpoint *'.
3086 (clear_breakpoint_commands): Likewise.
3087 (clear_breakpoint_conditions_and_commands): Likewise.
3088 (add_condition_to_breakpoint): Likewise.
3089 (add_breakpoint_condition): Likewise.
3090 (add_commands_to_breakpoint): Likewise.
3091 (check_breakpoints): Check other_breakpoint.
3092 (clone_one_breakpoint): Clone breakpopint according to its type.
3093 * mem-break.h (struct gdb_breakpoint): Declare.
3094 (set_gdb_breakpoint): Update declaration.
3095 (clear_breakpoint_conditions_and_commands): Likewise.
3096 (add_breakpoint_condition): Likewise.
3097 (add_breakpoint_commands): Likewise.
3098 * server.c (process_point_options): Change parameter type to
3099 'struct gdb_breakpoint *'.
3100
3101 2016-07-21 Yao Qi <yao.qi@linaro.org>
3102
3103 * mem-break.c (set_breakpoint_at): Rename it to ...
3104 (set_breakpoint_type_at): ... it.
3105 (set_breakpoint_at): Call set_breakpoint_type_at.
3106 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3107 * mem-break.h (set_breakpoint_at): Update comments.
3108
3109 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3110
3111 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3112 to buf parameter.
3113 (nios2_store_gregset): Likewise.
3114
3115 2016-07-01 Pedro Alves <palves@redhat.com>
3116 Antoine Tremblay <antoine.tremblay@ericsson.com>
3117
3118 * linux-low.c: Change interface to take the target lwp_info
3119 pointer directly and return void. Handle detaching from a zombie
3120 thread.
3121 (linux_detach_lwp_callback): New function.
3122 (linux_detach): Detach from the leader thread after detaching from
3123 the clone threads.
3124
3125 2016-06-28 Yao Qi <yao.qi@linaro.org>
3126
3127 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3128 for variable new_offset.
3129 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3130 (aarch64_ftrace_insn_reloc_cb): Likewise.
3131 (aarch64_ftrace_insn_reloc_tb): Likewise.
3132 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3133 PRIx64 instead of PRIx32.
3134
3135 2016-06-28 Yao Qi <yao.qi@linaro.org>
3136
3137 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3138 (the_low_target): Install arm_get_syscall_trapinfo.
3139
3140 2016-06-28 Yao Qi <yao.qi@linaro.org>
3141
3142 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3143 function.
3144 (the_low_target): Install aarch64_get_syscall_trapinfo.
3145
3146 2016-06-28 Yao Qi <yao.qi@linaro.org>
3147
3148 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3149 Callers updated.
3150 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3151 Remove parameter sysno.
3152 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3153 sysret.
3154
3155 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3156
3157 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3158 (s390_emit_ne_goto): Likewise.
3159 (s390_emit_lt_goto): Likewise.
3160 (s390_emit_le_goto): Likewise.
3161 (s390_emit_gt_goto): Likewise.
3162 (s390_emit_ge_goto): Likewise.
3163 (s390x_emit_eq_goto): Likewise.
3164 (s390x_emit_ne_goto): Likewise.
3165 (s390x_emit_lt_goto): Likewise.
3166 (s390x_emit_le_goto): Likewise.
3167 (s390x_emit_gt_goto): Likewise.
3168 (s390x_emit_ge_goto): Likewise.
3169 (s390_emit_ops_impl): Mark variable static.
3170 (s390x_emit_ops): Likewise.
3171
3172 2016-06-17 Yao Qi <yao.qi@linaro.org>
3173
3174 * linux-low.c (handle_extended_wait): Call
3175 uninsert_reinsert_breakpoints for the parent process. Remove
3176 reinsert breakpoints from the child process. Reinsert them to
3177 the parent process when vfork is done.
3178 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3179 (reinsert_reinsert_breakpoints): New function.
3180 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3181 (reinsert_reinsert_breakpoints): Declare.
3182
3183 2016-06-17 Yao Qi <yao.qi@linaro.org>
3184
3185 * linux-low.c (handle_extended_wait): If the parent is doing
3186 step-over, remove the reinsert breakpoints from the forked child.
3187
3188 2016-06-17 Yao Qi <yao.qi@linaro.org>
3189
3190 * linux-low.c (unsuspend_all_lwps): Declare.
3191 (linux_low_filter_event): If thread exited, call finish_step_over.
3192 If step-over is finished, unsuspend other threads.
3193
3194 2016-06-17 Yao Qi <yao.qi@linaro.org>
3195
3196 * linux-low.c (linux_resume_one_lwp_throw): Assert
3197 has_reinsert_breakpoints returns false.
3198 * mem-break.c (delete_disabled_breakpoints): Assert
3199 bp type isn't reinsert_breakpoint.
3200
3201 2016-06-17 Yao Qi <yao.qi@linaro.org>
3202
3203 * linux-low.c (maybe_hw_step): New function.
3204 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3205 (finish_step_over): Switch current_thread to lwp temporarily,
3206 and assert has_reinsert_breakpoints returns true.
3207 (proceed_one_lwp): Call maybe_hw_step.
3208 * mem-break.c (has_reinsert_breakpoints): New function.
3209 * mem-break.h (has_reinsert_breakpoints): Declare.
3210
3211 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3212
3213 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3214
3215 2016-05-17 Yao Qi <yao.qi@linaro.org>
3216
3217 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3218 instead of find_inferior.
3219
3220 2016-05-05 Yao Qi <yao.qi@linaro.org>
3221
3222 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3223 Initialize res to zero.
3224
3225 2016-05-05 Yao Qi <yao.qi@linaro.org>
3226
3227 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3228 to uint32_t.
3229
3230 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3231
3232 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3233 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3234 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3235
3236 2016-04-28 Par Olsson <par.olsson@windriver.com>
3237 Simon Marchi <simon.marchi@ericsson.com>
3238
3239 * tracepoint.c (write_inferior_int8): New function.
3240 (cmd_qtenable_disable): Write enable flag using
3241 write_inferior_int8.
3242
3243 2016-04-25 Yao Qi <yao.qi@linaro.org>
3244
3245 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3246 (need_step_over_p): Return zero if the LWP has pending signals
3247 can be delivered on software single step target.
3248
3249 2016-04-25 Yao Qi <yao.qi@linaro.org>
3250
3251 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3252 return instead of error.
3253
3254 2016-04-22 Yao Qi <yao.qi@linaro.org>
3255
3256 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3257 to 23.
3258
3259 2016-04-22 Yao Qi <yao.qi@linaro.org>
3260
3261 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3262 signal when stepping over breakpoint with software single
3263 step.
3264
3265 2016-04-21 Pedro Alves <palves@redhat.com>
3266
3267 * linux-s390-low.c (s390_collect_ptrace_register)
3268 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3269 add casts.
3270 (s390_check_regset): Use void * instead of gdb_byte *.
3271
3272 2016-04-20 Pedro Alves <palves@redhat.com>
3273
3274 * configure: Renegerate.
3275
3276 2016-04-20 Yao Qi <yao.qi@linaro.org>
3277
3278 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3279 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3280 number 16.
3281 (arm_store_gregset): Likewise.
3282
3283 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3284
3285 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3286 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3287 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3288 (amd64-avx-mpx-linux.c): New rules.
3289 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3290 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3291 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3292 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3293 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3294 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3295 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3296 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3297 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3298 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3299 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3300 * linux-x86-low.c (x86_linux_read_description): Add case for
3301 X86_XSTATE_AVX_MPX_MASK.
3302 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3303 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3304 init_registers_i386_avx_mpx_linux.
3305 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3306 (initialize_low_tracepoint): Call
3307 init_registers_i386_avx_mpx_linux.
3308 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3309 (initialize_low_tracepoint): Call
3310 init_registers_amd64_avx_mpx_linux.
3311 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3312 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3313 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3314 declarations.
3315
3316 2016-04-18 Pedro Alves <palves@redhat.com>
3317
3318 * configure: Regenerate.
3319
3320 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3321
3322 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3323 (aarch64_emit_sub): Likewise.
3324
3325 2016-04-12 Pedro Alves <palves@redhat.com>
3326
3327 * utils.c (prepare_to_throw_exception): Delete.
3328
3329 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3330
3331 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3332
3333 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3334
3335 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3336
3337 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3338
3339 * linux-aarch64-ipa.c: Add <elf.h> include.
3340 * linux-ppc-ipa.c: Add <elf.h> include.
3341 * linux-s390-ipa.c: Add <elf.h> include.
3342
3343 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3344
3345 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3346 (get_raw_reg_ptr): Likewise.
3347 (get_trace_state_variable_value_ptr): Likewise.
3348 (set_trace_state_variable_value_ptr): Likewise.
3349 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3350 char *.
3351
3352 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3353 Marcin Kościelnicki <koriakin@0x04.net>
3354
3355 PR/17221
3356 * linux-ppc-low.c (emit_insns): New function.
3357 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3358 (ppc_emit_prologue): New function.
3359 (ppc_emit_epilogue): New function.
3360 (ppc_emit_add): New function.
3361 (ppc_emit_sub): New function.
3362 (ppc_emit_mul): New function.
3363 (ppc_emit_lsh): New function.
3364 (ppc_emit_rsh_signed): New function.
3365 (ppc_emit_rsh_unsigned): New function.
3366 (ppc_emit_ext): New function.
3367 (ppc_emit_zero_ext): New function.
3368 (ppc_emit_log_not): New function.
3369 (ppc_emit_bit_and): New function.
3370 (ppc_emit_bit_or): New function.
3371 (ppc_emit_bit_xor): New function.
3372 (ppc_emit_bit_not): New function.
3373 (ppc_emit_equal): New function.
3374 (ppc_emit_less_signed): New function.
3375 (ppc_emit_less_unsigned): New function.
3376 (ppc_emit_ref): New function.
3377 (ppc_emit_const): New function.
3378 (ppc_emit_reg): New function.
3379 (ppc_emit_pop): New function.
3380 (ppc_emit_stack_flush): New function.
3381 (ppc_emit_swap): New function.
3382 (ppc_emit_stack_adjust): New function.
3383 (ppc_emit_call): New function.
3384 (ppc_emit_int_call_1): New function.
3385 (ppc_emit_void_call_2): New function.
3386 (ppc_emit_if_goto): New function.
3387 (ppc_emit_goto): New function.
3388 (ppc_emit_eq_goto): New function.
3389 (ppc_emit_ne_goto): New function.
3390 (ppc_emit_lt_goto): New function.
3391 (ppc_emit_le_goto): New function.
3392 (ppc_emit_gt_goto): New function.
3393 (ppc_emit_ge_goto): New function.
3394 (ppc_write_goto_address): New function.
3395 (ppc_emit_ops_impl): New static variable.
3396 (ppc64v1_emit_prologue): New function.
3397 (ppc64v2_emit_prologue): New function.
3398 (ppc64_emit_epilogue): New function.
3399 (ppc64_emit_add): New function.
3400 (ppc64_emit_sub): New function.
3401 (ppc64_emit_mul): New function.
3402 (ppc64_emit_lsh): New function.
3403 (ppc64_emit_rsh_signed): New function.
3404 (ppc64_emit_rsh_unsigned): New function.
3405 (ppc64_emit_ext): New function.
3406 (ppc64_emit_zero_ext): New function.
3407 (ppc64_emit_log_not): New function.
3408 (ppc64_emit_bit_and): New function.
3409 (ppc64_emit_bit_or): New function.
3410 (ppc64_emit_bit_xor): New function.
3411 (ppc64_emit_bit_not): New function.
3412 (ppc64_emit_equal): New function.
3413 (ppc64_emit_less_signed): New function.
3414 (ppc64_emit_less_unsigned): New function.
3415 (ppc64_emit_ref): New function.
3416 (ppc64_emit_const): New function.
3417 (ppc64v1_emit_reg): New function.
3418 (ppc64v2_emit_reg): New function.
3419 (ppc64_emit_pop): New function.
3420 (ppc64_emit_stack_flush): New function.
3421 (ppc64_emit_swap): New function.
3422 (ppc64v1_emit_call): New function.
3423 (ppc64v2_emit_call): New function.
3424 (ppc64v1_emit_int_call_1): New function.
3425 (ppc64v2_emit_int_call_1): New function.
3426 (ppc64v1_emit_void_call_2): New function.
3427 (ppc64v2_emit_void_call_2): New function.
3428 (ppc64_emit_if_goto): New function.
3429 (ppc64_emit_eq_goto): New function.
3430 (ppc64_emit_ne_goto): New function.
3431 (ppc64_emit_lt_goto): New function.
3432 (ppc64_emit_le_goto): New function.
3433 (ppc64_emit_gt_goto): New function.
3434 (ppc64_emit_ge_goto): New function.
3435 (ppc64v1_emit_ops_impl): New static variable.
3436 (ppc64v2_emit_ops_impl): New static variable.
3437 (ppc_emit_ops): New function.
3438 (linux_low_target): Wire in ppc_emit_ops.
3439
3440 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3441 Marcin Kościelnicki <koriakin@0x04.net>
3442
3443 PR/17221
3444 * Makefile.in: Add powerpc-*-ipa.o
3445 * configure.srv: Add ipa_obj for powerpc*-linux.
3446 * linux-ppc-ipa.c: New file.
3447 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3448 includes.
3449 (PPC_FIELD): New macro.
3450 (PPC_SEXT): New macro.
3451 (PPC_OP6): New macro.
3452 (PPC_BO): New macro.
3453 (PPC_LI): New macro.
3454 (PPC_BD): New macro.
3455 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3456 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3457 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3458 (ppc_get_thread_area): New function.
3459 (is_elfv2_inferior): New function.
3460 (gen_ds_form): New function.
3461 (GEN_STD): New macro.
3462 (GEN_STDU): New macro.
3463 (GEN_LD): New macro.
3464 (GEN_LDU): New macro.
3465 (gen_d_form): New function.
3466 (GEN_ADDI): New macro.
3467 (GEN_ADDIS): New macro.
3468 (GEN_LI): New macro.
3469 (GEN_LIS): New macro.
3470 (GEN_ORI): New macro.
3471 (GEN_ORIS): New macro.
3472 (GEN_LWZ): New macro.
3473 (GEN_STW): New macro.
3474 (GEN_STWU): New macro.
3475 (gen_xfx_form): New function.
3476 (GEN_MFSPR): New macro.
3477 (GEN_MTSPR): New macro.
3478 (GEN_MFCR): New macro.
3479 (GEN_MTCR): New macro.
3480 (GEN_SYNC): New macro.
3481 (GEN_LWSYNC): New macro.
3482 (gen_x_form): New function.
3483 (GEN_OR): New macro.
3484 (GEN_MR): New macro.
3485 (GEN_LWARX): New macro.
3486 (GEN_STWCX): New macro.
3487 (GEN_CMPW): New macro.
3488 (gen_md_form): New function.
3489 (GEN_RLDICL): New macro.
3490 (GEN_RLDICR): New macro.
3491 (gen_i_form): New function.
3492 (GEN_B): New macro.
3493 (GEN_BL): New macro.
3494 (gen_b_form): New function.
3495 (GEN_BNE): New macro.
3496 (GEN_LOAD): New macro.
3497 (GEN_STORE): New macro.
3498 (gen_limm): New function.
3499 (gen_atomic_xchg): New function.
3500 (gen_call): New function.
3501 (ppc_relocate_instruction): New function.
3502 (ppc_install_fast_tracepoint_jump_pad): New function.
3503 (ppc_get_min_fast_tracepoint_insn_len): New function.
3504 (ppc_get_ipa_tdesc_idx): New function.
3505 (the_low_target): Wire in the new functions.
3506 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3507 tdescs.
3508 * linux-ppc-tdesc.h: New file.
3509
3510 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3511
3512 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3513 (alloc_jump_pad_buffer): New function.
3514 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3515 (alloc_jump_pad_buffer): New function.
3516 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3517 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3518 (alloc_jump_pad_buffer): New function.
3519 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3520 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3521 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3522 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3523
3524 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3525
3526 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3527 * linux-amd64-ipa.c: Likewise.
3528 * linux-i386-ipa.c: Likewise.
3529 * linux-s390-ipa.c: Likewise.
3530 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3531 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3532 set_trace_state_variable_value_ptr.
3533 (struct ipa_sym_addresses): Likewise.
3534 (symbol_list): Likewise.
3535 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3536 accessing gdb_collect directly.
3537 (gdb_collect_ptr_type): New typedef.
3538 (get_raw_reg_ptr_type): New typedef.
3539 (get_trace_state_variable_value_ptr_type): New typedef.
3540 (set_trace_state_variable_value_ptr_type): New typedef.
3541 (gdb_collect_ptr): New global.
3542 (get_raw_reg_ptr): New global.
3543 (get_trace_state_variable_value_ptr): New global.
3544 (set_trace_state_variable_value_ptr): New global.
3545 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3546 accessing get_raw_reg directly.
3547 (get_get_tsv_func_addr): Likewise for
3548 get_trace_state_variable_value_ptr.
3549 (get_set_tsv_func_addr): Likewise for
3550 set_trace_state_variable_value_ptr.
3551 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3552
3553 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3554
3555 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3556
3557 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3558
3559 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3560 packets.
3561 (relocate_instruction): Remove own_buf.
3562 * server.c (own_buf): Make global.
3563 (handle_v_requests): Make global.
3564 * server.h (own_buf): New declaration.
3565 (handle_v_requests): New prototype.
3566
3567 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3568
3569 PR 18377
3570 * linux-s390-low.c (add_insns): New function.
3571 (s390_emit_prologue): New function.
3572 (s390_emit_epilogue): New function.
3573 (s390_emit_add): New function.
3574 (s390_emit_sub): New function.
3575 (s390_emit_mul): New function.
3576 (s390_emit_lsh): New function.
3577 (s390_emit_rsh_signed): New function.
3578 (s390_emit_rsh_unsigned): New function.
3579 (s390_emit_ext): New function.
3580 (s390_emit_log_not): New function.
3581 (s390_emit_bit_and): New function.
3582 (s390_emit_bit_or): New function.
3583 (s390_emit_bit_xor): New function.
3584 (s390_emit_bit_not): New function.
3585 (s390_emit_equal): New function.
3586 (s390_emit_less_signed): New function.
3587 (s390_emit_less_unsigned): New function.
3588 (s390_emit_ref): New function.
3589 (s390_emit_if_goto): New function.
3590 (s390_emit_goto): New function.
3591 (s390_write_goto_address): New function.
3592 (s390_emit_litpool): New function.
3593 (s390_emit_const): New function.
3594 (s390_emit_call): New function.
3595 (s390_emit_reg): New function.
3596 (s390_emit_pop): New function.
3597 (s390_emit_stack_flush): New function.
3598 (s390_emit_zero_ext): New function.
3599 (s390_emit_swap): New function.
3600 (s390_emit_stack_adjust): New function.
3601 (s390_emit_set_r2): New function.
3602 (s390_emit_int_call_1): New function.
3603 (s390_emit_void_call_2): New function.
3604 (s390_emit_eq_goto): New function.
3605 (s390_emit_ne_goto): New function.
3606 (s390_emit_lt_goto): New function.
3607 (s390_emit_le_goto): New function.
3608 (s390_emit_gt_goto): New function.
3609 (s390_emit_ge_goto): New function.
3610 (s390x_emit_prologue): New function.
3611 (s390x_emit_epilogue): New function.
3612 (s390x_emit_add): New function.
3613 (s390x_emit_sub): New function.
3614 (s390x_emit_mul): New function.
3615 (s390x_emit_lsh): New function.
3616 (s390x_emit_rsh_signed): New function.
3617 (s390x_emit_rsh_unsigned): New function.
3618 (s390x_emit_ext): New function.
3619 (s390x_emit_log_not): New function.
3620 (s390x_emit_bit_and): New function.
3621 (s390x_emit_bit_or): New function.
3622 (s390x_emit_bit_xor): New function.
3623 (s390x_emit_bit_not): New function.
3624 (s390x_emit_equal): New function.
3625 (s390x_emit_less_signed): New function.
3626 (s390x_emit_less_unsigned): New function.
3627 (s390x_emit_ref): New function.
3628 (s390x_emit_if_goto): New function.
3629 (s390x_emit_const): New function.
3630 (s390x_emit_call): New function.
3631 (s390x_emit_reg): New function.
3632 (s390x_emit_pop): New function.
3633 (s390x_emit_stack_flush): New function.
3634 (s390x_emit_zero_ext): New function.
3635 (s390x_emit_swap): New function.
3636 (s390x_emit_stack_adjust): New function.
3637 (s390x_emit_int_call_1): New function.
3638 (s390x_emit_void_call_2): New function.
3639 (s390x_emit_eq_goto): New function.
3640 (s390x_emit_ne_goto): New function.
3641 (s390x_emit_lt_goto): New function.
3642 (s390x_emit_le_goto): New function.
3643 (s390x_emit_gt_goto): New function.
3644 (s390x_emit_ge_goto): New function.
3645 (s390_emit_ops): New function.
3646 (struct linux_target_ops): Fill in emit_ops hook.
3647
3648 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3649
3650 PR 18377
3651 * Makefile.in: Add s390 IPA files.
3652 * configure.srv: Build IPA for s390.
3653 * linux-s390-ipa.c: New file.
3654 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
3655 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
3656 (tdesc_s390_linux32): Likewise.
3657 (init_registers_s390_linux32v1): Likewise.
3658 (tdesc_s390_linux32v1): Likewise.
3659 (init_registers_s390_linux32v2): Likewise.
3660 (tdesc_s390_linux32v2): Likewise.
3661 (init_registers_s390_linux64): Likewise.
3662 (tdesc_s390_linux64): Likewise.
3663 (init_registers_s390_linux64v1): Likewise.
3664 (tdesc_s390_linux64v1): Likewise.
3665 (init_registers_s390_linux64v2): Likewise.
3666 (tdesc_s390_linux64v2): Likewise.
3667 (init_registers_s390_te_linux64): Likewise.
3668 (tdesc_s390_te_linux64): Likewise.
3669 (init_registers_s390_vx_linux64): Likewise.
3670 (tdesc_s390_vx_linux64): Likewise.
3671 (init_registers_s390_tevx_linux64): Likewise.
3672 (tdesc_s390_tevx_linux64): Likewise.
3673 (init_registers_s390x_linux64): Likewise.
3674 (tdesc_s390x_linux64): Likewise.
3675 (init_registers_s390x_linux64v1): Likewise.
3676 (tdesc_s390x_linux64v1): Likewise.
3677 (init_registers_s390x_linux64v2): Likewise.
3678 (tdesc_s390x_linux64v2): Likewise.
3679 (init_registers_s390x_te_linux64): Likewise.
3680 (tdesc_s390x_te_linux64): Likewise.
3681 (init_registers_s390x_vx_linux64): Likewise.
3682 (tdesc_s390x_vx_linux64): Likewise.
3683 (init_registers_s390x_tevx_linux64): Likewise.
3684 (tdesc_s390x_tevx_linux64): Likewise.
3685 (have_hwcap_s390_vx): New static variable.
3686 (s390_arch_setup): Fill have_hwcap_s390_vx.
3687 (s390_get_thread_area): New function.
3688 (s390_ft_entry_gpr_esa): New const.
3689 (s390_ft_entry_gpr_zarch): New const.
3690 (s390_ft_entry_misc): New const.
3691 (s390_ft_entry_fr): New const.
3692 (s390_ft_entry_vr): New const.
3693 (s390_ft_main_31): New const.
3694 (s390_ft_main_64): New const.
3695 (s390_ft_exit_fr): New const.
3696 (s390_ft_exit_vr): New const.
3697 (s390_ft_exit_misc): New const.
3698 (s390_ft_exit_gpr_esa): New const.
3699 (s390_ft_exit_gpr_zarch): New const.
3700 (append_insns): New function.
3701 (s390_relocate_instruction): New function.
3702 (s390_install_fast_tracepoint_jump_pad): New function.
3703 (s390_get_min_fast_tracepoint_insn_len): New function.
3704 (s390_get_ipa_tdesc_idx): New function.
3705 (struct linux_target_ops): Wire in the above functions.
3706 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
3707 * linux-s390-tdesc.h: New file.
3708
3709 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3710
3711 * linux-s390-low.c (s390_supports_tracepoints): New function.
3712 (struct linux_target_ops): Fill supports_tracepoints hook.
3713
3714 2016-03-18 Yao Qi <yao.qi@linaro.org>
3715
3716 * linux-low.c (lwp_signal_can_be_delivered): New function.
3717 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
3718
3719 2016-03-18 Yao Qi <yao.qi@linaro.org>
3720
3721 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
3722 0 if signal is enqueued. Remove 'signal' from one debugging
3723 message. Move one debugging message to some lines below.
3724 Remove code setting 'signal' to 0.
3725
3726 2016-03-18 Yao Qi <yao.qi@linaro.org>
3727
3728 * linux-low.c (linux_low_filter_event): Remove redundant
3729 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
3730
3731 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
3732
3733 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
3734 (struct linux_target_ops): Wire in the above.
3735
3736 2016-03-03 Yao Qi <yao.qi@linaro.org>
3737
3738 * linux-low.c: Update comments to start_step_over.
3739
3740 2016-03-03 Yao Qi <yao.qi@linaro.org>
3741
3742 PR server/19736
3743 * linux-low.c (handle_extended_wait): Set child suspended
3744 if event_lwp->bp_reinsert isn't zero.
3745
3746 2016-03-02 Yao Qi <yao.qi@linaro.org>
3747
3748 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
3749 enqueue_pending_signal.
3750
3751 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
3752
3753 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
3754 is actually loaded.
3755
3756 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3757
3758 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
3759 (s390_regmap_3264) [!__s390x__]: New global.
3760 (s390_collect_ptrace_register): Skip map entries containing -1.
3761 (s390_supply_ptrace_register): Ditto.
3762 (s390_fill_gprs_high): New function.
3763 (s390_store_gprs_high): New function.
3764 (s390_regsets): Add NT_S390_HIGH_GPRS.
3765 (s390_get_hwcap): Enable on 31-bit.
3766 (have_hwcap_s390_high_gprs): Enable on 31-bit.
3767 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
3768 Detect NT_S390_HIGH_GPRS.
3769 (s390_usrregs_info_3264): Enable on 31-bit.
3770 (s390_regs_info): Enable regs_info_3264 on 31-bit.
3771 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
3772
3773 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
3774
3775 PR gdb/13808
3776 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
3777 * configure.srv: Ditto.
3778 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
3779 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
3780 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
3781 (init_registers_amd64_linux): Remove prototype.
3782 (tdesc_amd64_linux): Remove declaration.
3783 (get_ipa_tdesc): New function.
3784 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3785 initialize remaining tdescs.
3786 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
3787 (init_registers_i386_linux): Remove prototype.
3788 (tdesc_i386_linux): Remove declaration.
3789 (get_ipa_tdesc): New function.
3790 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
3791 initialize remaining tdescs.
3792 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
3793 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
3794 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
3795 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
3796 (x86_get_ipa_tdesc_idx): New function.
3797 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
3798 * linux-x86-tdesc.h: New file.
3799 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
3800 (target_get_ipa_tdesc_idx): New macro.
3801 * tracepoint.c (ipa_tdesc_idx): New macro.
3802 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
3803 (symbol_list): Add ipa_tdesc_idx.
3804 (cmd_qtstart): Write ipa_tdesc_idx in the target.
3805 (ipa_tdesc): Remove.
3806 (ipa_tdesc_idx): New variable.
3807 (get_context_regcache): Use get_ipa_tdesc.
3808 (gdb_collect): Ditto.
3809 (gdb_probe): Ditto.
3810 * tracepoint.h (get_ipa_tdesc): New prototype.
3811 (ipa_tdesc): Remove.
3812
3813 2016-02-24 Pedro Alves <palves@redhat.com>
3814
3815 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
3816 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
3817 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
3818 Factor out common code between the USE_SIGTRAP_SIGINFO and
3819 !USE_SIGTRAP_SIGINFO blocks.
3820 (linux_low_filter_event): Call save_stop_reason instead of
3821 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
3822 Update comments.
3823 (linux_wait_1): Update comments.
3824
3825 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
3826
3827 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
3828 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
3829 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
3830 ppc_insert_point, ppc_remove_point.
3831
3832 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
3833
3834 * linux-s390-low.c (s390_supports_z_point_type): New function.
3835 (struct linux_target_ops): Wire s390_supports_z_point_type in.
3836
3837 2016-02-16 Yao Qi <yao.qi@linaro.org>
3838
3839 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
3840 PC. Get pc from regcache_read_pc.
3841
3842 2016-02-12 Yao Qi <yao.qi@linaro.org>
3843
3844 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
3845 or linux_get_pc_32bit.
3846 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
3847
3848 2016-02-12 Yao Qi <yao.qi@linaro.org>
3849
3850 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
3851 arm_linux_get_next_pcs_fixup.
3852
3853 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
3854
3855 * tracepoint.c (x_tracepoint_action_download): Change
3856 write_inferior_data_ptr to write_inferior_data_pointer.
3857 (cmd_qtstart): Likewise.
3858 (write_inferior_data_ptr): Remove.
3859 (download_agent_expr): Change write_inferior_data_ptr to
3860 write_inferior_data_pointer.
3861 (download_tracepoint_1): Likewise.
3862 (download_tracepoint): Likewise.
3863 (download_trace_state_variables): Likewise.
3864
3865 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
3866 Marcin Kościelnicki <koriakin@0x04.net>
3867
3868 * tracepoint.c (struct tracepoint_action_ops): Remove.
3869 (struct tracepoint_action): Remove ops.
3870 (m_tracepoint_action_download, r_tracepoint_action_download)
3871 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
3872 size and offset accordingly.
3873 (m_tracepoint_action_ops, r_tracepoint_action_ops)
3874 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
3875 (tracepoint_action_send, tracepoint_action_download): New functions.
3876 Helpers for trace action handlers.
3877 (add_tracepoint_action): Remove setup actions ops.
3878 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
3879
3880 2016-02-10 Yao Qi <yao.qi@linaro.org>
3881
3882 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
3883
3884 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3885
3886 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
3887 to AC_OUTPUT.
3888 * configure: Regenerate.
3889
3890 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
3891
3892 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
3893 void * to gdb_byte *.
3894 * linux-low.c (siginfo_fixup): Likewise.
3895 (linux_xfer_siginfo): Likewise.
3896 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
3897 Likewise.
3898 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
3899
3900 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
3901
3902 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
3903 to srv_tgtobj.
3904 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
3905 to srv_tgtobj.
3906 * linux-x86-low.c [__x86_64__]: Include
3907 "nat/amd64-linux-siginfo.h".
3908 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
3909 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
3910 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
3911 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
3912 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
3913 (cpt_si_fd, si_timerid, si_overrun): Move from
3914 nat/amd64-linux-siginfo.c.
3915 * Makefile.in (amd64-linux-siginfo.o:): New rule.
3916
3917 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
3918
3919 * server.c (skip_to_semicolon): Remove.
3920 (process_point_options): Use strchrnul instead of
3921 skip_to_semicolon.
3922
3923 2016-01-26 Yao Qi <yao.qi@linaro.org>
3924
3925 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
3926 * linux-low.c (install_software_single_step_breakpoints): Don't
3927 call regcache_read_pc.
3928 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
3929 argument pc.
3930
3931 2016-01-26 Yao Qi <yao.qi@linaro.org>
3932
3933 * linux-low.c (install_software_single_step_breakpoints): Call
3934 regcache_read_pc instead of get_pc.
3935
3936 2016-01-26 Yao Qi <yao.qi@linaro.org>
3937
3938 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
3939 (unblock_async_io): Rename to ...
3940 (block_unblock_async_io): ... it. New function.
3941 (enable_async_io): Don't install SIGIO handler. Unblock it
3942 instead.
3943 (disable_async_io): Don't ignore SIGIO. Block it instead.
3944 (initialize_async_io): Install SIGIO handler. Don't call
3945 unblock_async_io.
3946
3947 2016-01-26 Yao Qi <yao.qi@linaro.org>
3948
3949 * remote-utils.c (getpkt): If the buffer isn't empty, and the
3950 first character is '\003', call *the_target->request_interrupt.
3951
3952 2016-01-25 Yao Qi <yao.qi@linaro.org>
3953
3954 * remote-utils.c (new_thread_notify): Remove.
3955 (dead_thread_notify): Likewise.
3956 * remote-utils.h (new_thread_notify): Remove declaration.
3957 (dead_thread_notify): Likewise.
3958
3959 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
3960
3961 * gdb.trace/pending.exp: Fix expected message on continue.
3962
3963 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
3964
3965 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
3966 it works properly on big-endian machines where sizeof (CORE_ADDR)
3967 != sizeof (void *).
3968
3969 2016-01-21 Pedro Alves <palves@redhat.com>
3970
3971 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
3972 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
3973 * configure: Regenerate.
3974
3975 2016-01-21 Yao Qi <yao.qi@linaro.org>
3976
3977 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
3978 is_thumb and set it according to CPSR saved on the stack.
3979 (get_next_pcs_syscall_next_pc): Pass is_thumb to
3980 arm_sigreturn_next_pc.
3981
3982 2016-01-18 Yao Qi <yao.qi@linaro.org>
3983
3984 * linux-low.c (linux_set_pc_64bit): New function.
3985 (linux_get_pc_64bit): New function.
3986 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
3987 Declare.
3988 * linux-sparc-low.c (debug_threads): Remove declaration.
3989 (sparc_get_pc): Remove.
3990 (the_low_target): Use linux_get_pc_64bit instead of
3991 sparc_get_pc.
3992 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
3993 (the_low_target): Use linux_get_pc_64bit and
3994 linux_set_pc_64bit.
3995
3996 2016-01-18 Yao Qi <yao.qi@linaro.org>
3997
3998 * linux-arm-low.c (debug_threads): Remove declaration.
3999 (arm_get_pc, arm_set_pc): Remove.
4000 (the_low_target): Use linux_get_pc_32bit and
4001 linux_set_pc_32bit.
4002 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4003 (the_low_target): Use linux_get_pc_32bit and
4004 linux_set_pc_32bit.
4005 * linux-cris-low.c (debug_threads): Remove declaration.
4006 (cris_get_pc, cris_set_pc,): Remove.
4007 (the_low_target): Use linux_get_pc_32bit and
4008 linux_set_pc_32bit.
4009 * linux-crisv32-low.c (debug_threads): Remove declaration.
4010 (cris_get_pc, cris_set_pc): Remove.
4011 (the_low_target): Use linux_get_pc_32bit and
4012 linux_set_pc_32bit.
4013 * linux-low.c: Include inttypes.h.
4014 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4015 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4016 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4017 (the_low_target): Use linux_get_pc_32bit and
4018 linux_set_pc_32bit.
4019 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4020 (the_low_target): Use linux_get_pc_32bit and
4021 linux_set_pc_32bit.
4022 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4023 (the_low_target): Use linux_get_pc_32bit and
4024 linux_set_pc_32bit.
4025 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4026 (the_low_target): Use linux_get_pc_32bit and
4027 linux_set_pc_32bit.
4028 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4029 (the_low_target): Use linux_get_pc_32bit and
4030 linux_set_pc_32bit.
4031
4032 2016-01-18 Gary Benson <gbenson@redhat.com>
4033
4034 * configure.ac (AC_FUNC_FORK): New check.
4035 * config.in: Regenerate.
4036 * configure: Likewise.
4037
4038 2016-01-14 Yao Qi <yao.qi@linaro.org>
4039
4040 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4041 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4042 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4043 arm_get_next_pcs_ctor.
4044
4045 2016-01-12 Josh Stone <jistone@redhat.com>
4046 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4047
4048 * inferiors.h: Include "gdb_vecs.h".
4049 (struct process_info): Add syscalls_to_catch.
4050 * inferiors.c (remove_process): Free syscalls_to_catch.
4051 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4052 syscall_return stops.
4053 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4054 * server.c (handle_general_set): Handle QCatchSyscalls.
4055 (handle_query): Report support for QCatchSyscalls.
4056 * target.h (struct target_ops): Add supports_catch_syscall.
4057 (target_supports_catch_syscall): New macro.
4058 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4059 (struct lwp_info): Add syscall_state.
4060 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4061 Maintain syscall_state and syscalls_to_catch across exec.
4062 (get_syscall_trapinfo): New function, proxy to the_low_target.
4063 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4064 (linux_low_filter_event): Toggle syscall_state entry/return for
4065 syscall traps, and set it ignored for all others.
4066 (gdb_catching_syscalls_p): New function.
4067 (gdb_catch_this_syscall_p): New function.
4068 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4069 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4070 (linux_supports_catch_syscall): New function.
4071 (linux_target_ops): Install it.
4072 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4073 (the_low_target): Install it.
4074
4075 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4076
4077 * acinclude.m4: Include new ../warning.m4 file.
4078 * configure: Regenerated.
4079 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4080
4081 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4082
4083 * ax.c (is_goto_target): Mark static.
4084 * linux-low.c (register_addr): Likewise.
4085 (linux_fetch_registers, linux_store_registers): Likewise.
4086 * mem-break.c (any_persistent_commands): Fix old prototype.
4087 (add_commands_to_breakpoint): Mark static.
4088 * regcache.c (find_register_by_name): Delete unused func.
4089 * remote-utils.c (hex_or_minus_one): Mark static.
4090 * server.c (monitor_show_help): Mark static.
4091 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4092 handle_v_requests): Likewise.
4093
4094 2016-01-12 Pedro Alves <palves@redhat.com>
4095
4096 Remove use of the registered trademark symbol throughout.
4097
4098 2016-01-08 Yao Qi <yao.qi@linaro.org>
4099
4100 * remote-utils.c (getpkt): If c is '\003', call target hook
4101 request_interrupt.
4102
4103 2016-01-06 Yao Qi <yao.qi@linaro.org>
4104
4105 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4106 linux-aarch32-low.c.
4107 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4108 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4109 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4110 (thumb2_breakpoint): Declare.
4111 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4112 linux-aarch32-low.h.
4113 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4114 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4115 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4116
4117 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4118
4119 * gdbreplay.c (gdbreplay_version): Change copyright year in
4120 version message.
4121 * server.c (gdbserver_version): Likewise.
4122
4123 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4124
4125 * server.c (crc32_table): Delete.
4126 (crc32): Use libiberty's xcrc32 function.
4127
4128 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4129
4130 * lynx-low.c (lynx_delete_thread_callback): New function.
4131 (lynx_mourn): Properly delete our process and all of its
4132 threads. Remove call to clear_inferiors.
4133
4134 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4135
4136 * target.c (thread_search_callback): Add check that
4137 the thread_stopped target callback is not NULL before
4138 calling it.
4139
4140 2015-12-21 Yao Qi <yao.qi@linaro.org>
4141
4142 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4143 arm breakpoint.
4144
4145 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4146
4147 * server.c (handle_query): Call target_supports_software_single_step.
4148
4149 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4150
4151 * linux-low.c (single_step): New function.
4152 (linux_resume_one_lwp_throw): Call single_step.
4153 (start_step_over): Likewise.
4154
4155 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4156
4157 * Makefile.in (SFILES): Append arch/arm-linux.c,
4158 arch/arm-get-next-pcs.c.
4159 (arm-linux.o): New rule.
4160 (arm-get-next-pcs.o): New rule.
4161 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4162 arm-linux.o.
4163 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4164 to linux-aarch32-low.c.
4165 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4166 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4167 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4168 (thumb2_breakpoint_len): Likewise.
4169 (arm_is_thumb_mode): Make non-static.
4170 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4171 from linux-aarch32-low.c.
4172 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4173 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4174 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4175 (thumb2_breakpoint_len): Likewise.
4176 (arm_is_thumb_mode): New declaration.
4177 * linux-arm-low.c: Include arch/arm-linux.h
4178 aarch/arm-get-next-pcs.h, sys/syscall.h.
4179 (get_next_pcs_ops): New struct.
4180 (get_next_pcs_addr_bits_remove): New function.
4181 (get_next_pcs_is_thumb): New function.
4182 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4183 (arm_sigreturn_next_pc): Likewise.
4184 (get_next_pcs_syscall_next_pc): Likewise.
4185 (arm_gdbserver_get_next_pcs): Likewise.
4186 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4187 Initialize.
4188 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4189 * server.h: Include gdb_vecs.h.
4190
4191 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4192
4193 * Makefile.in (SFILES): Append common/common-regcache.c.
4194 (OBS): Append common-regcache.o.
4195 (common-regcache.o): New rule.
4196 * regcache.c (init_register_cache): Initialize cache to
4197 REG_UNAVAILABLE.
4198 (regcache_raw_read_unsigned): New function.
4199 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4200 register_status enum.
4201
4202 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4203
4204 * linux-aarch64-low.c (the_low_targets): Rename
4205 breakpoint_reinsert_addr to get_next_pcs.
4206 * linux-arm-low.c (the_low_targets): Likewise.
4207 * linux-bfin-low.c (the_low_targets): Likewise.
4208 * linux-cris-low.c (the_low_targets): Likewise.
4209 * linux-crisv32-low.c (the_low_targets): Likewise.
4210 * linux-low.c (can_software_single_step): Likewise.
4211 (install_software_single_step_breakpoints): New function.
4212 (start_step_over): Use install_software_single_step_breakpoints.
4213 * linux-low.h: New CORE_ADDR vector.
4214 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4215 get_next_pcs.
4216 * linux-mips-low.c (the_low_targets): Likewise.
4217 * linux-nios2-low.c (the_low_targets): Likewise.
4218 * linux-sparc-low.c (the_low_targets): Likewise.
4219
4220 2015-12-17 Pedro Alves <palves@redhat.com>
4221
4222 * linux-low.c (linux_kill_one_lwp): Remove references to
4223 LinuxThreads.
4224 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4225 to 'kill'.
4226 (linux_init_signals): Delete.
4227 (initialize_low): Adjust.
4228 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4229
4230 2015-12-16 Pedro Alves <palves@redhat.com>
4231
4232 * configure.ac (compiler warning flags): When testing a
4233 -Wno-foo option, check whether -Wfoo works instead.
4234 * configure: Regenerate.
4235
4236 2015-12-11 Don Breazeal <donb@codesourcery.com>
4237
4238 * server.c (process_serial_event): Don't exit from gdbserver
4239 in remote mode if there are still active inferiors.
4240
4241 2015-12-11 Yao Qi <yao.qi@linaro.org>
4242
4243 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4244 arm_breakpoint_at if the process is 32-bit.
4245
4246 2015-12-11 Yao Qi <yao.qi@linaro.org>
4247
4248 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4249 arm breakpoint.
4250
4251 2015-12-07 Yao Qi <yao.qi@linaro.org>
4252
4253 * configure.srv: Append arm.o to srv_tgtobj for
4254 aarch64*-*-linux* target.
4255 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4256 from linux-arm-low.c.
4257 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4258 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4259 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4260 (thumb2_breakpoint_len): Likewise.
4261 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4262 (arm_breakpoint_kinds): Likewise.
4263 (arm_breakpoint_kind_from_pc): Likewise.
4264 (arm_sw_breakpoint_from_kind): Likewise.
4265 (arm_breakpoint_kind_from_current_state): Likewise.
4266 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4267 (arm_sw_breakpoint_from_kind): Declare.
4268 (arm_breakpoint_kind_from_current_state): Declare.
4269 (arm_breakpoint_at): Declare.
4270 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4271 arm_sw_breakpoint_from_kind if process is 32-bit.
4272 (aarch64_breakpoint_kind_from_pc): New function.
4273 (aarch64_breakpoint_kind_from_current_state): New function.
4274 (the_low_target): Initialize fields breakpoint_kind_from_pc
4275 and breakpoint_kind_from_current_state.
4276 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4277 linux-aarch32-low.c.
4278 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4279 (arm_breakpoint, arm_breakpoint_len): Likewise.
4280 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4281 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4282 (arm_is_thumb_mode): Likewise.
4283 (arm_breakpoint_at): Likewise.
4284 (arm_breakpoint_kind_from_pc): Likewise.
4285 (arm_sw_breakpoint_from_kind): Likewise.
4286 (arm_breakpoint_kind_from_current_state): Likewise.
4287
4288 Revert:
4289 2015-08-04 Yao Qi <yao.qi@linaro.org>
4290
4291 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4292 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4293 * server.c (extended_protocol): Remove "static".
4294 * server.h (extended_protocol): Declare it.
4295
4296 2015-12-04 Josh Stone <jistone@redhat.com>
4297
4298 * target.h (struct target_ops) <arch_setup>: Rename to ...
4299 (struct target_ops) <post_create_inferior>: ... this.
4300 (target_arch_setup): Rename to ...
4301 (target_post_create_inferior): ... this, calling post_create_inferior.
4302 * server.c (start_inferior): Update target_arch_setup calls to
4303 target_post_create_inferior.
4304 * linux-low.c (linux_low_ptrace_options): Forward declare.
4305 (linux_arch_setup): Update its comment for general use.
4306 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4307 (struct linux_target_ops): Use linux_post_create_inferior.
4308 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4309 to post_create_inferior.
4310 * nto-low.c (struct nto_target_ops): Likewise.
4311 * spu-low.c (struct spu_target_ops): Likewise.
4312 * win32-low.c (struct win32_target_ops): Likewise.
4313
4314 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4315
4316 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4317
4318 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4319
4320 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4321 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4322 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4323 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4324 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4325 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4326 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4327 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4328 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4329 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4330 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4331 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4332
4333 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4334
4335 * linux-low.c (linux_look_up_symbols): Don't call
4336 linux_supports_traceclone.
4337 * linux-low.h (thread_db_init): Remove use_events argument.
4338 * thread-db.c (thread_db_use_event): Remove global variable.
4339 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4340 (struct thread_db) <td_create_bp>: Remove field.
4341 (thread_db_create_event): Remove function.
4342 (thread_db_enable_reporting): Likewise.
4343 (find_one_thread): Don't check for thread_db_use_events.
4344 (attach_thread): Likewise.
4345 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4346 (try_thread_db_load_1): Don't check for thread_db_use_events.
4347 (thread_db_init): Remove use_events argument and thread events
4348 handling.
4349 (remove_thread_event_breakpoints): Remove function.
4350 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4351
4352 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4353
4354 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4355 New function.
4356 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4357 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4358 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4359 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4360 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4361 Initialize.
4362 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4363 New function.
4364 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4365 * linux-low.c (can_hardware_single_step): Use
4366 supports_hardware_single_step.
4367 (can_software_single_step): New function.
4368 (start_step_over): Call can_software_single_step.
4369 (linux_supports_hardware_single_step): New function.
4370 (struct target_ops) <supports_software_single_step>: Initialize.
4371 * linux-low.h (struct linux_target_ops)
4372 <supports_hardware_single_step>: Initialize.
4373 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4374 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4375 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4376 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4377 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4378 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4379 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4380 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4381 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4382 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4383 Initialize.
4384 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4385 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4386 Initialize.
4387 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4388 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4389 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4390 New function.
4391 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4392 * target.h (struct target_ops): <supports_software_single_step>:
4393 New field.
4394 (target_supports_software_single_step): New macro.
4395
4396 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4397
4398 * linux-low.c (linux_wait_1): Fix pc advance condition.
4399 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4400 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4401
4402 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4403
4404 * linux-arm-low.c (arm_is_thumb_mode): New function.
4405 (arm_breakpoint_at): Use arm_is_thumb_mode.
4406 (arm_breakpoint_kind_from_current_state): New function.
4407 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4408 Initialize.
4409 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4410 (linux_breakpoint_kind_from_current_state): New function.
4411 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4412 * linux-low.h (struct linux_target_ops)
4413 <breakpoint_kind_from_current_state>: New field.
4414 * target.h (struct target_ops): Likewise.
4415 (target_breakpoint_kind_from_current_state): New macro.
4416
4417 2015-11-30 Pedro Alves <palves@redhat.com>
4418
4419 * linux-low.c (linux_resume): Wake up the event loop before
4420 returning.
4421
4422 2015-11-30 Pedro Alves <palves@redhat.com>
4423
4424 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4425 check.
4426 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4427 to -1.
4428 * target.c (struct thread_search): New structure.
4429 (thread_search_callback): New function.
4430 (prev_general_thread): New global.
4431 (prepare_to_access_memory, done_accessing_memory): New functions.
4432 * target.h (prepare_to_access_memory, done_accessing_memory):
4433 Replace macros with function declarations.
4434
4435 2015-11-30 Pedro Alves <palves@redhat.com>
4436
4437 PR 14618
4438 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4439 report TARGET_WAITKIND_NO_RESUMED.
4440 * remote-utils.c (prepare_resume_reply): Handle
4441 TARGET_WAITKIND_NO_RESUMED.
4442 * server.c (report_no_resumed): New global.
4443 (handle_query) <qSupported>: Handle "no-resumed+". Report
4444 "no-resumed+" support.
4445 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4446 return error if the client doesn't support no-resumed events.
4447 (push_stop_notification): New function.
4448 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4449 events if the client supports them.
4450
4451 2015-11-30 Pedro Alves <palves@redhat.com>
4452
4453 * linux-low.c (thread_still_has_status_pending_p): Don't check
4454 vCont;t here.
4455 (lwp_resumed): New function.
4456 (status_pending_p_callback): Return early if the LWP is not
4457 supposed to be resumed.
4458
4459 2015-11-30 Pedro Alves <palves@redhat.com>
4460
4461 * linux-low.c (handle_extended_wait): Assert that the LWP's
4462 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4463 thread create events, leave the new child's status pending.
4464 (linux_low_filter_event): If GDB wants to hear about thread exit
4465 events, leave the LWP marked dead and don't delete it.
4466 (linux_wait_for_event_filtered): Don't check for thread exit.
4467 (filter_exit_event): New function.
4468 (linux_wait_1): Use it, when returning an exit event.
4469 (linux_resume_one_lwp_throw): Assert that the LWP's
4470 waitstatus is TARGET_WAITKIND_IGNORE.
4471 * remote-utils.c (prepare_resume_reply): Handle
4472 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4473 * server.c (report_thread_events): New global.
4474 (handle_general_set): Handle QThreadEvents.
4475 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4476 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4477 TARGET_WAITKIND_THREAD_EXITED.
4478 * server.h (report_thread_events): Declare.
4479
4480 2015-11-30 Pedro Alves <palves@redhat.com>
4481
4482 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4483 the thread's last_resume_kind was resume_stop.
4484
4485 2015-11-30 Pedro Alves <palves@redhat.com>
4486
4487 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4488 before returning.
4489
4490 2015-11-30 Pedro Alves <palves@redhat.com>
4491
4492 * server.c (handle_v_requests): Handle vCtrlC.
4493
4494 2015-11-30 Pedro Alves <palves@redhat.com>
4495
4496 * gdbthread.h (find_any_thread_of_pid): Declare.
4497 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4498 functions.
4499 * server.c (handle_query): If current_thread is NULL, look for
4500 another thread of the selected process.
4501
4502 2015-11-26 Daniel Colascione <dancol@dancol.org>
4503 Simon Marchi <simon.marchi@ericsson.com>
4504
4505 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4506 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4507 name in reply.
4508 * target.h (struct target_ops) <thread_name>: New field.
4509 (target_thread_name): New macro.
4510
4511 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4512
4513 * regcache.h (regcache_invalidate_pid): Add declaration.
4514 * regcache.c (regcache_invalidate_pid): New function, extracted
4515 from regcache_invalidate.
4516 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4517 Add trivial documentation comment.
4518 * lynx-low.c: Use regcache_invalidate_pid instead of
4519 regcache_invalidate.
4520
4521 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4522
4523 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4524 and Elf64_auxv_t if the target is Android.
4525
4526 2015-11-22 Doug Evans <xdje42@gmail.com>
4527
4528 * target.h: #include <sys/types.h>.
4529
4530 2015-11-19 Pedro Alves <palves@redhat.com>
4531
4532 * linux-low.c (linux_process_qsupported): Change prototype.
4533 Adjust.
4534 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4535 Change prototype.
4536 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4537 and adjust to loop over all features.
4538 * server.c (handle_query) <qSupported>: Adjust to call
4539 target_process_qsupported once, passing it a vector of unprocessed
4540 features.
4541 * target.h (struct target_ops) <process_qsupported>: Change
4542 prototype.
4543 (target_process_qsupported): Adjust.
4544
4545 2015-11-19 Pedro Alves <palves@redhat.com>
4546
4547 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4548 mode.
4549 * configure: Regenerate.
4550
4551 2015-11-19 Pedro Alves <palves@redhat.com>
4552
4553 * configure: Regenerate.
4554
4555 2015-11-19 Yao Qi <yao.qi@linaro.org>
4556
4557 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4558 type to uint32_t.
4559
4560 2015-11-19 Yao Qi <yao.qi@linaro.org>
4561
4562 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4563 (struct aarch64_operand): Move enum out.
4564
4565 2015-11-19 Yao Qi <yao.qi@linaro.org>
4566
4567 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
4568 struct user_fpsimd_state *.
4569 (aarch64_store_fpregset): Likewise.
4570
4571 2015-11-19 Yao Qi <yao.qi@linaro.org>
4572
4573 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
4574 struct user_pt_regs *.
4575 (aarch64_store_gregset): Likewise.
4576
4577 2015-11-18 Pedro Alves <palves@redhat.com>
4578
4579 * Makefile.in (all_object_files): Add $IPA_OBJS.
4580
4581 2015-11-17 Pedro Alves <palves@redhat.com>
4582
4583 * win32-low.c (win32_resume): Use gdb_signal_from_host,
4584 GDB_SIGNAL_0 and gdb_signal_to_string.
4585
4586 2015-11-17 Pedro Alves <palves@redhat.com>
4587
4588 * win32-low.c (handle_output_debug_string): Remove parameter.
4589 (win32_kill): Remove our_status local and adjust call to
4590 handle_output_debug_string.
4591 (get_child_debug_event): Adjust call to
4592 handle_output_debug_string.
4593
4594 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4595
4596 * linux-mips-low.c (mips_fill_gregset): Add cast.
4597 (mips_store_gregset): Likewise.
4598 (mips_fill_fpregset): Likewise.
4599 (mips_store_fpregset): Likewise.
4600
4601 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4602
4603 * linux-mips-low.c (mips_add_watchpoint): Rename private to
4604 priv.
4605
4606 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4607
4608 * linux-mips-low.c (mips_linux_new_thread): Change type of
4609 watch_type to enum target_hw_bp_type.
4610
4611 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4612
4613 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
4614 Change return type to arm_hwbp_type.
4615
4616 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4617
4618 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
4619 (arm_store_gregset): Likewise.
4620 * linux-arm-low.c (arm_get_hwcap): Likewise.
4621 (arm_read_description): Likewise.
4622
4623 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4624
4625 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
4626
4627 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4628
4629 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
4630 (ppc_fill_vsxregset): Likewise.
4631 (ppc_store_vsxregset): Likewise.
4632 (ppc_fill_vrregset): Likewise.
4633 (ppc_store_vrregset): Likewise.
4634 (ppc_fill_evrregset): Likewise.
4635 (ppc_store_evrregset): Likewise.
4636
4637 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
4638
4639 * linux-ppc-low.c (ppc_usrregs_info): Remove
4640 forward-declaration.
4641 (ppc_arch_setup): Move lower in file.
4642
4643 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
4644
4645 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
4646 (ps_pdwrite): Likewise.
4647
4648 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
4649
4650 * linux-arm-low.c (arm_new_thread): Move pointer dereference
4651 to after assert checks.
4652
4653 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
4654
4655 * proc-service.c (ps_pdread): Add/adjust casts.
4656 (ps_pdwrite): Add/adjust casts.
4657
4658 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4659
4660 * server.c (handle_search_memory_1): Cast return value of
4661 memmem.
4662
4663 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
4664
4665 * server.c (write_qxfer_response): Change type of data to
4666 gdb_byte *.
4667
4668 2015-10-29 Pedro Alves <palves@redhat.com>
4669
4670 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
4671
4672 2015-10-29 Pedro Alves <palves@redhat.com>
4673
4674 * tracepoint.c (clear_installed_tracepoints): Add casts.
4675
4676 2015-10-29 Pedro Alves <palves@redhat.com>
4677
4678 * server.c (handle_v_cont, process_serial_event): Add enum
4679 gdb_signal casts to signal parsing code.
4680
4681 2015-10-29 Pedro Alves <palves@redhat.com>
4682
4683 * linux-low.h (NULL_REGSET): Define.
4684 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4685 * linux-arm-low.c (arm_regsets): Likewise.
4686 * linux-crisv32-low.c (cris_regsets): Likewise.
4687 * linux-m68k-low.c (m68k_regsets): Likewise.
4688 * linux-mips-low.c (mips_regsets): Likewise.
4689 * linux-nios2-low.c (nios2_regsets): Likewise.
4690 * linux-ppc-low.c (ppc_regsets): Likewise.
4691 * linux-s390-low.c (s390_regsets): Likewise.
4692 * linux-sh-low.c (sh_regsets): Likewise.
4693 * linux-sparc-low.c (sparc_regsets): Likewise.
4694 * linux-tic6x-low.c (tic6x_regsets): Likewise.
4695 * linux-tile-low.c (tile_regsets): Likewise.
4696 * linux-x86-low.c (x86_regsets): Likewise.
4697 * linux-xtensa-low.c (xtensa_regsets): Likewise.
4698
4699 2015-10-29 Pedro Alves <palves@redhat.com>
4700
4701 * linux-low.h (NULL_REGSET): Define.
4702 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
4703 * linux-arm-low.c (arm_regsets): Likewise.
4704 * linux-crisv32-low.c (cris_regsets): Likewise.
4705 * linux-m68k-low.c (m68k_regsets): Likewise.
4706 * linux-mips-low.c (mips_regsets): Likewise.
4707 * linux-nios2-low.c (nios2_regsets): Likewise.
4708 * linux-ppc-low.c (ppc_regsets): Likewise.
4709 * linux-s390-low.c (s390_regsets): Likewise.
4710 * linux-sh-low.c (sh_regsets): Likewise.
4711 * linux-sparc-low.c (sparc_regsets): Likewise.
4712 * linux-tic6x-low.c (tic6x_regsets): Likewise.
4713 * linux-tile-low.c (tile_regsets): Likewise.
4714 * linux-x86-low.c (x86_regsets): Likewise.
4715 * linux-xtensa-low.c (xtensa_regsets): Likewise.
4716
4717 2015-10-26 Doug Evans <dje@google.com>
4718
4719 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
4720
4721 2015-10-26 Doug Evans <dje@google.com>
4722
4723 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
4724
4725 2015-10-26 Doug Evans <dje@google.com>
4726
4727 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
4728 for debug_printf.
4729 (attach_thread, find_new_threads_callback): Ditto.
4730
4731 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4732
4733 * mem-break.h (set_breakpoint_data): Remove.
4734
4735 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4736
4737 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
4738 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4739 (initialize_low): Remove set_breakpoint_data call.
4740 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
4741 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
4742 (initialize_low): Remove set_breakpoint_data call.
4743 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
4744 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
4745 (initialize_low): Remove set_breakpoint_data call.
4746
4747 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
4748
4749 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
4750 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
4751 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
4752 * target.h (target_breakpoint_kind_from_pc): New macro.
4753
4754 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
4755
4756 * linux-low.c (default_breakpoint_kind_from_pc): New function.
4757 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
4758 the default breakpoint kind.
4759
4760 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4761
4762 * linux-arm-low.c (arm_supports_z_point_type): Add software
4763 breakpoint support.
4764
4765 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4766
4767 * linux-arm-low.c: Refactor breakpoint definitions.
4768 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
4769 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
4770
4771 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4772
4773 * Makefile.in: Add arm.c/o.
4774 * configure.srv: Likewise.
4775 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
4776 (arm_breakpoint_kind_from_pc): New function.
4777 (arm_sw_breakpoint_from_kind): Return proper kind.
4778 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
4779
4780 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4781
4782 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
4783 removal.
4784 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
4785 (struct raw_breakpoint) <size>: Remove.
4786 (struct raw_breakpoint) <kind>: Add.
4787 (bp_size): New function.
4788 (bp_opcode): Likewise.
4789 (find_raw_breakpoint_at): Adjust for kind.
4790 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
4791 (remove_memory_breakpoint): Adjust for kind call bp_size.
4792 (set_raw_breakpoint_at): Adjust for kind.
4793 (set_breakpoint): Likewise.
4794 (set_breakpoint_at): Call breakpoint_kind_from_pc.
4795 (delete_raw_breakpoint): Adjust for kind.
4796 (delete_breakpoint): Likewise.
4797 (find_gdb_breakpoint): Likewise.
4798 (set_gdb_breakpoint_1): Likewise.
4799 (set_gdb_breakpoint): Likewise.
4800 (delete_gdb_breakpoint_1): Likewise.
4801 (delete_gdb_breakpoint): Likewise.
4802 (uninsert_raw_breakpoint): Likewise.
4803 (reinsert_raw_breakpoint): Likewise.
4804 (set_breakpoint_data): Remove.
4805 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
4806 (check_mem_read): Adjust for kind call bp_size.
4807 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
4808 (clone_one_breakpoint): Adjust for kind.
4809 * mem-break.h (set_gdb_breakpoint): Likewise.
4810 (delete_gdb_breakpoint): Likewise.
4811 * server.c (process_serial_event): Likewise.
4812
4813 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4814
4815 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
4816 (struct linux_target_ops) <breakpoint>: Remove.
4817 (struct linux_target_ops) <breakpoint_len>: Remove.
4818 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4819 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4820 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
4821 (arm_sw_breakpoint_from_kind): New function.
4822 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
4823 (struct linux_target_ops) <breakpoint>: Remove.
4824 (struct linux_target_ops) <breakpoint_len>: Remove.
4825 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4826 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4827 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
4828 (struct linux_target_ops) <breakpoint>: Remove.
4829 (struct linux_target_ops) <breakpoint_len>: Remove.
4830 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4831 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4832 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
4833 (struct linux_target_ops) <breakpoint>: Remove.
4834 (struct linux_target_ops) <breakpoint_len>: Remove.
4835 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4836 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4837 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
4838 and sw_breakpoint_from_kind to increment the pc.
4839 (linux_breakpoint_kind_from_pc): New function.
4840 (linux_sw_breakpoint_from_kind): New function.
4841 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
4842 (initialize_low): Call breakpoint_kind_from_pc and
4843 sw_breakpoint_from_kind to replace breakpoint_data/len.
4844 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
4845 New field.
4846 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
4847 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
4848 (struct linux_target_ops) <breakpoint>: Remove.
4849 (struct linux_target_ops) <breakpoint_len>: Remove.
4850 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4851 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4852 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
4853 (struct linux_target_ops) <breakpoint>: Remove.
4854 (struct linux_target_ops) <breakpoint_len>: Remove.
4855 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4856 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4857 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
4858 (struct linux_target_ops) <breakpoint>: Remove.
4859 (struct linux_target_ops) <breakpoint_len>: Remove.
4860 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4861 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4862 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
4863 (struct linux_target_ops) <breakpoint>: Remove.
4864 (struct linux_target_ops) <breakpoint_len>: Remove.
4865 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4866 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4867 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
4868 (struct linux_target_ops) <breakpoint>: Remove.
4869 (struct linux_target_ops) <breakpoint_len>: Remove.
4870 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4871 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4872 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
4873 (struct linux_target_ops) <breakpoint>: Remove.
4874 (struct linux_target_ops) <breakpoint_len>: Remove.
4875 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4876 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4877 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
4878 (struct linux_target_ops) <breakpoint>: Remove.
4879 (struct linux_target_ops) <breakpoint_len>: Remove.
4880 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4881 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4882 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
4883 (struct linux_target_ops) <breakpoint>: Remove.
4884 (struct linux_target_ops) <breakpoint_len>: Remove.
4885 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4886 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4887 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
4888 (struct linux_target_ops) <breakpoint>: Remove.
4889 (struct linux_target_ops) <breakpoint_len>: Remove.
4890 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4891 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4892 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
4893 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
4894 (struct linux_target_ops) <breakpoint>: Remove.
4895 (struct linux_target_ops) <breakpoint_len>: Remove.
4896 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4897 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4898 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
4899 (struct linux_target_ops) <breakpoint>: Remove.
4900 (struct linux_target_ops) <breakpoint_len>: Remove.
4901 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
4902 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
4903
4904 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
4905
4906 * linux-cris-low.c (cris_get_pc): Remove void arg.
4907
4908 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4909
4910 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
4911 variable name.
4912
4913 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
4914
4915 * inferiors.c (thread_pid_matches_callback): New function.
4916 (find_thread_process): New function.
4917 (remove_thread): Reset current_thread.
4918 (remove_process): Assert threads have been removed first.
4919
4920 2015-10-15 Yao Qi <yao.qi@linaro.org>
4921
4922 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
4923 if it is 3.
4924 (aarch64_remove_point): Likewise.
4925 * regcache.c (regcache_register_size): New function.
4926
4927 2015-10-12 Yao Qi <yao.qi@linaro.org>
4928
4929 * linux-aarch64-low.c: Update all callers as emit_load_store
4930 is renamed to aarch64_emit_load_store.
4931
4932 2015-10-12 Yao Qi <yao.qi@linaro.org>
4933
4934 * linux-aarch64-low.c: Update all callers of function renaming
4935 from emit_insn to aarch64_emit_insn.
4936
4937 2015-10-12 Yao Qi <yao.qi@linaro.org>
4938
4939 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
4940 arch/aarch64-insn.h.
4941 (struct aarch64_memory_operand): Likewise.
4942 (ENCODE): Likewise.
4943 (emit_insn): Move to arch/aarch64-insn.c.
4944 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
4945 (emit_load_store): Move to arch/aarch64-insn.c.
4946 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
4947 (can_encode_int32): Remove.
4948
4949 2015-10-12 Yao Qi <yao.qi@linaro.org>
4950
4951 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
4952 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
4953 (aarch64_relocate_instruction): Likewise.
4954 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
4955 (struct aarch64_insn_visitor): Likewise.
4956
4957 2015-10-12 Yao Qi <yao.qi@linaro.org>
4958
4959 * linux-aarch64-low.c (struct aarch64_insn_data): New.
4960 (struct aarch64_insn_visitor): New.
4961 (struct aarch64_insn_relocation_data): New.
4962 (aarch64_ftrace_insn_reloc_b): New function.
4963 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
4964 (aarch64_ftrace_insn_reloc_cb): Likewise.
4965 (aarch64_ftrace_insn_reloc_tb): Likewise.
4966 (aarch64_ftrace_insn_reloc_adr): Likewise.
4967 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
4968 (aarch64_ftrace_insn_reloc_others): Likewise.
4969 (visitor): New.
4970 (aarch64_relocate_instruction): Use visitor.
4971
4972 2015-10-12 Yao Qi <yao.qi@linaro.org>
4973
4974 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
4975 int. Add argument buf.
4976 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
4977 aarch64_relocate_instruction.
4978
4979 2015-10-12 Yao Qi <yao.qi@linaro.org>
4980
4981 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
4982 argument insn. Remove local variable insn. Don't call
4983 target_read_uint32.
4984 (aarch64_install_fast_tracepoint_jump_pad): Call
4985 target_read_uint32.
4986
4987 2015-09-30 Yao Qi <yao.qi@linaro.org>
4988
4989 * linux-aarch64-low.c (emit_movk): Shorten a long line.
4990 (emit_load_store_pair): Likewise.
4991
4992 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
4993
4994 * dll.c (match_dll): Add cast(s).
4995 (unloaded_dll): Likewise.
4996 * linux-low.c (second_thread_of_pid_p): Likewise.
4997 (delete_lwp_callback): Likewise.
4998 (count_events_callback): Likewise.
4999 (select_event_lwp_callback): Likewise.
5000 (linux_set_resume_request): Likewise.
5001 * server.c (accumulate_file_name_length): Likewise.
5002 (emit_dll_description): Likewise.
5003 (handle_qxfer_threads_worker): Likewise.
5004 (visit_actioned_threads): Likewise.
5005 * thread-db.c (any_thread_of): Likewise.
5006 * tracepoint.c (same_process_p): Likewise.
5007 (match_blocktype): Likewise.
5008 (build_traceframe_info_xml): Likewise.
5009
5010 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5011
5012 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5013 assignment.
5014 (gdb_unparse_agent_expr): Likewise.
5015 * hostio.c (require_data): Likewise.
5016 (handle_pread): Likewise.
5017 * linux-low.c (disable_regset): Likewise.
5018 (fetch_register): Likewise.
5019 (store_register): Likewise.
5020 (get_dynamic): Likewise.
5021 (linux_qxfer_libraries_svr4): Likewise.
5022 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5023 (set_fast_tracepoint_jump): Likewise.
5024 (uninsert_fast_tracepoint_jumps_at): Likewise.
5025 (reinsert_fast_tracepoint_jumps_at): Likewise.
5026 (validate_inserted_breakpoint): Likewise.
5027 (clone_agent_expr): Likewise.
5028 * regcache.c (init_register_cache): Likewise.
5029 * remote-utils.c (putpkt_binary_1): Likewise.
5030 (decode_M_packet): Likewise.
5031 (decode_X_packet): Likewise.
5032 (look_up_one_symbol): Likewise.
5033 (relocate_instruction): Likewise.
5034 (monitor_output): Likewise.
5035 * server.c (handle_search_memory): Likewise.
5036 (handle_qxfer_exec_file): Likewise.
5037 (handle_qxfer_libraries): Likewise.
5038 (handle_qxfer): Likewise.
5039 (handle_query): Likewise.
5040 (handle_v_cont): Likewise.
5041 (handle_v_run): Likewise.
5042 (captured_main): Likewise.
5043 * target.c (write_inferior_memory): Likewise.
5044 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5045 * tracepoint.c (init_trace_buffer): Likewise.
5046 (add_tracepoint_action): Likewise.
5047 (add_traceframe): Likewise.
5048 (add_traceframe_block): Likewise.
5049 (cmd_qtdpsrc): Likewise.
5050 (cmd_qtdv): Likewise.
5051 (cmd_qtstatus): Likewise.
5052 (response_source): Likewise.
5053 (response_tsv): Likewise.
5054 (cmd_qtnotes): Likewise.
5055 (gdb_collect): Likewise.
5056 (initialize_tracepoint): Likewise.
5057
5058 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5059
5060 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5061 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5062 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5063 <NOP>: New.
5064 (enum aarch64_condition_codes): New enum.
5065 (w0): New static global.
5066 (fp): Likewise.
5067 (lr): Likewise.
5068 (struct aarch64_memory_operand) <type>: New
5069 MEMORY_OPERAND_POSTINDEX type.
5070 (postindex_memory_operand): New helper function.
5071 (emit_ret): New function.
5072 (emit_load_store_pair): New function, factored out of emit_stp
5073 with support for MEMORY_OPERAND_POSTINDEX.
5074 (emit_stp): Rewrite using emit_load_store_pair.
5075 (emit_ldp): New function.
5076 (emit_load_store): Likewise.
5077 (emit_ldr): Mention post-index instruction in comment.
5078 (emit_ldrh): New function.
5079 (emit_ldrb): New function.
5080 (emit_ldrsw): Mention post-index instruction in comment.
5081 (emit_str): Likewise.
5082 (emit_subs): New function.
5083 (emit_cmp): Likewise.
5084 (emit_and): Likewise.
5085 (emit_orr): Likewise.
5086 (emit_orn): Likewise.
5087 (emit_eor): Likewise.
5088 (emit_mvn): Likewise.
5089 (emit_lslv): Likewise.
5090 (emit_lsrv): Likewise.
5091 (emit_asrv): Likewise.
5092 (emit_mul): Likewise.
5093 (emit_sbfm): Likewise.
5094 (emit_sbfx): Likewise.
5095 (emit_ubfm): Likewise.
5096 (emit_ubfx): Likewise.
5097 (emit_csinc): Likewise.
5098 (emit_cset): Likewise.
5099 (emit_nop): Likewise.
5100 (emit_ops_insns): New helper function.
5101 (emit_pop): Likewise.
5102 (emit_push): Likewise.
5103 (aarch64_emit_prologue): New function.
5104 (aarch64_emit_epilogue): Likewise.
5105 (aarch64_emit_add): Likewise.
5106 (aarch64_emit_sub): Likewise.
5107 (aarch64_emit_mul): Likewise.
5108 (aarch64_emit_lsh): Likewise.
5109 (aarch64_emit_rsh_signed): Likewise.
5110 (aarch64_emit_rsh_unsigned): Likewise.
5111 (aarch64_emit_ext): Likewise.
5112 (aarch64_emit_log_not): Likewise.
5113 (aarch64_emit_bit_and): Likewise.
5114 (aarch64_emit_bit_or): Likewise.
5115 (aarch64_emit_bit_xor): Likewise.
5116 (aarch64_emit_bit_not): Likewise.
5117 (aarch64_emit_equal): Likewise.
5118 (aarch64_emit_less_signed): Likewise.
5119 (aarch64_emit_less_unsigned): Likewise.
5120 (aarch64_emit_ref): Likewise.
5121 (aarch64_emit_if_goto): Likewise.
5122 (aarch64_emit_goto): Likewise.
5123 (aarch64_write_goto_address): Likewise.
5124 (aarch64_emit_const): Likewise.
5125 (aarch64_emit_call): Likewise.
5126 (aarch64_emit_reg): Likewise.
5127 (aarch64_emit_pop): Likewise.
5128 (aarch64_emit_stack_flush): Likewise.
5129 (aarch64_emit_zero_ext): Likewise.
5130 (aarch64_emit_swap): Likewise.
5131 (aarch64_emit_stack_adjust): Likewise.
5132 (aarch64_emit_int_call_1): Likewise.
5133 (aarch64_emit_void_call_2): Likewise.
5134 (aarch64_emit_eq_goto): Likewise.
5135 (aarch64_emit_ne_goto): Likewise.
5136 (aarch64_emit_lt_goto): Likewise.
5137 (aarch64_emit_le_goto): Likewise.
5138 (aarch64_emit_gt_goto): Likewise.
5139 (aarch64_emit_ge_got): Likewise.
5140 (aarch64_emit_ops_impl): New static global variable.
5141 (aarch64_emit_ops): New target function, return
5142 &aarch64_emit_ops_impl.
5143 (struct linux_target_ops): Install it.
5144
5145 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5146
5147 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5148 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5149 aarch64-ipa.o.
5150 * linux-aarch64-ipa.c: New file.
5151 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5152 and endian.h.
5153 (aarch64_get_thread_area): New target method.
5154 (extract_signed_bitfield): New helper function.
5155 (aarch64_decode_ldr_literal): New function.
5156 (enum aarch64_opcodes): New enum.
5157 (struct aarch64_register): New struct.
5158 (struct aarch64_operand): New struct.
5159 (x0): New static global.
5160 (x1): Likewise.
5161 (x2): Likewise.
5162 (x3): Likewise.
5163 (x4): Likewise.
5164 (w2): Likewise.
5165 (ip0): Likewise.
5166 (sp): Likewise.
5167 (xzr): Likewise.
5168 (aarch64_register): New helper function.
5169 (register_operand): Likewise.
5170 (immediate_operand): Likewise.
5171 (struct aarch64_memory_operand): New struct.
5172 (offset_memory_operand): New helper function.
5173 (preindex_memory_operand): Likewise.
5174 (enum aarch64_system_control_registers): New enum.
5175 (ENCODE): New macro.
5176 (emit_insn): New helper function.
5177 (emit_b): New function.
5178 (emit_bcond): Likewise.
5179 (emit_cb): Likewise.
5180 (emit_tb): Likewise.
5181 (emit_blr): Likewise.
5182 (emit_stp): Likewise.
5183 (emit_ldp_q_offset): Likewise.
5184 (emit_stp_q_offset): Likewise.
5185 (emit_load_store): Likewise.
5186 (emit_ldr): Likewise.
5187 (emit_ldrsw): Likewise.
5188 (emit_str): Likewise.
5189 (emit_ldaxr): Likewise.
5190 (emit_stxr): Likewise.
5191 (emit_stlr): Likewise.
5192 (emit_data_processing_reg): Likewise.
5193 (emit_data_processing): Likewise.
5194 (emit_add): Likewise.
5195 (emit_sub): Likewise.
5196 (emit_mov): Likewise.
5197 (emit_movk): Likewise.
5198 (emit_mov_addr): Likewise.
5199 (emit_mrs): Likewise.
5200 (emit_msr): Likewise.
5201 (emit_sevl): Likewise.
5202 (emit_wfe): Likewise.
5203 (append_insns): Likewise.
5204 (can_encode_int32_in): New helper function.
5205 (aarch64_relocate_instruction): New function.
5206 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5207 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5208 (struct linux_target_ops): Install aarch64_get_thread_area,
5209 aarch64_install_fast_tracepoint_jump_pad and
5210 aarch64_get_min_fast_tracepoint_insn_len.
5211
5212 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5213
5214 * Makefile.in (aarch64-insn.o): New rule.
5215 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5216
5217 2015-09-21 Yao Qi <yao.qi@linaro.org>
5218
5219 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5220
5221 2015-09-21 Yao Qi <yao.qi@linaro.org>
5222
5223 * tracepoint.c (max_jump_pad_size): Remove.
5224
5225 2015-09-18 Yao Qi <yao.qi@linaro.org>
5226
5227 * linux-aarch64-low.c: Don't include sys/uio.h.
5228 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5229
5230 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5231
5232 * tracepoint.c (eval_result_type): Change prototype.
5233 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5234
5235 2015-09-15 Pedro Alves <palves@redhat.com>
5236
5237 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5238 Check whether to report exec events instead of checking whether
5239 multiprocess is enabled.
5240
5241 2015-09-15 Pedro Alves <palves@redhat.com>
5242
5243 PR remote/18965
5244 * remote-utils.c (prepare_resume_reply): Merge
5245 TARGET_WAITKIND_VFORK_DONE switch case with the
5246 TARGET_WAITKIND_FORKED case.
5247
5248 2015-09-15 Yao Qi <yao.qi@linaro.org>
5249
5250 * server.c (handle_query): Check string comparison using
5251 "else if" instead of "if".
5252
5253 2015-09-15 Yao Qi <yao.qi@linaro.org>
5254
5255 * server.c (vCont_supported): New global variable.
5256 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5257 matches. Append ";vContSupported+" to own_buf.
5258 (handle_v_requests): Append ";s;S" to own_buf if target supports
5259 hardware single step or vCont_supported is false.
5260 (capture_main): Set vCont_supported to zero.
5261
5262 2015-09-15 Yao Qi <yao.qi@linaro.org>
5263
5264 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5265 it to ...
5266 (linux_supports_hardware_single_step): ... New function.
5267 (linux_target_ops): Update.
5268 * lynx-low.c (lynx_target_ops): Set field
5269 supports_hardware_single_step to target_can_do_hardware_single_step.
5270 * nto-low.c (nto_target_ops): Likewise.
5271 * spu-low.c (spu_target_ops): Likewise.
5272 * win32-low.c (win32_target_ops): Likewise.
5273 * target.c (target_can_do_hardware_single_step): New function.
5274 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5275 Remove. <supports_hardware_single_step>: New field.
5276 (target_supports_conditional_breakpoints): Remove.
5277 (target_supports_hardware_single_step): New macro.
5278 (target_can_do_hardware_single_step): Declare.
5279 * server.c (handle_query): Use target_supports_hardware_single_step
5280 instead of target_supports_conditional_breakpoints.
5281
5282 2015-09-15 Yao Qi <yao.qi@linaro.org>
5283
5284 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5285 function.
5286 (struct linux_target_ops the_low_target): Install
5287 aarch64_linux_siginfo_fixup.
5288
5289 2015-09-11 Don Breazeal <donb@codesourcery.com>
5290 Luis Machado <lgustavo@codesourcery.com>
5291
5292 * linux-low.c (linux_mourn): Static declaration.
5293 (linux_arch_setup): Move in front of
5294 handle_extended_wait.
5295 (linux_arch_setup_thread): New function.
5296 (handle_extended_wait): Handle exec events. Call
5297 linux_arch_setup_thread. Make event_lwp argument a
5298 pointer-to-a-pointer.
5299 (check_zombie_leaders): Do not check stopped threads.
5300 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5301 (linux_low_filter_event): Add lwp and thread for exec'ing
5302 non-leader thread if leader thread has been deleted.
5303 Refactor code into linux_arch_setup_thread and call it.
5304 Pass child lwp pointer by reference to handle_extended_wait.
5305 (linux_wait_for_event_filtered): Update comment.
5306 (linux_wait_1): Prevent clobbering exec event status.
5307 (linux_supports_exec_events): New function.
5308 (linux_target_ops) <supports_exec_events>: Initialize new member.
5309 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5310 new member.
5311 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5312 * server.c (report_exec_events): New global variable.
5313 (handle_query): Handle qSupported query for exec-events feature.
5314 (captured_main): Initialize report_exec_events.
5315 * server.h (report_exec_events): Declare new global variable.
5316 * target.h (struct target_ops) <supports_exec_events>: New
5317 member.
5318 (target_supports_exec_events): New macro.
5319 * win32-low.c (win32_target_ops) <supports_exec_events>:
5320 Initialize new member.
5321
5322 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5323
5324 * linux-low.c (linux_low_enable_btrace): Remove.
5325 (linux_target_ops): Replace linux_low_enable_btrace with
5326 linux_enable_btrace.
5327
5328 2015-09-03 Yao Qi <yao.qi@linaro.org>
5329
5330 * linux-aarch64-low.c (aarch64_insert_point): Call
5331 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5332 returns true.
5333
5334 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5335
5336 * linux-low.c (check_stopped_by_breakpoint): Use
5337 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5338
5339 2015-08-27 Pedro Alves <palves@redhat.com>
5340
5341 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5342
5343 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5344
5345 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5346 the XNEW-family equivalent.
5347 (compile_bytecodes): Likewise.
5348 * dll.c (loaded_dll): Likewise.
5349 * event-loop.c (append_callback_event): Likewise.
5350 (create_file_handler): Likewise.
5351 (create_file_event): Likewise.
5352 * hostio.c (handle_open): Likewise.
5353 * inferiors.c (add_thread): Likewise.
5354 (add_process): Likewise.
5355 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5356 * linux-arm-low.c (arm_new_process): Likewise.
5357 (arm_new_thread): Likewise.
5358 * linux-low.c (add_to_pid_list): Likewise.
5359 (linux_add_process): Likewise.
5360 (handle_extended_wait): Likewise.
5361 (add_lwp): Likewise.
5362 (enqueue_one_deferred_signal): Likewise.
5363 (enqueue_pending_signal): Likewise.
5364 (linux_resume_one_lwp_throw): Likewise.
5365 (linux_resume_one_thread): Likewise.
5366 (linux_read_memory): Likewise.
5367 (linux_write_memory): Likewise.
5368 * linux-mips-low.c (mips_linux_new_process): Likewise.
5369 (mips_linux_new_thread): Likewise.
5370 (mips_add_watchpoint): Likewise.
5371 * linux-x86-low.c (initialize_low_arch): Likewise.
5372 * lynx-low.c (lynx_add_process): Likewise.
5373 * mem-break.c (set_raw_breakpoint_at): Likewise.
5374 (set_breakpoint): Likewise.
5375 (add_condition_to_breakpoint): Likewise.
5376 (add_commands_to_breakpoint): Likewise.
5377 (clone_agent_expr): Likewise.
5378 (clone_one_breakpoint): Likewise.
5379 * regcache.c (new_register_cache): Likewise.
5380 * remote-utils.c (look_up_one_symbol): Likewise.
5381 * server.c (queue_stop_reply): Likewise.
5382 (start_inferior): Likewise.
5383 (queue_stop_reply_callback): Likewise.
5384 (handle_target_event): Likewise.
5385 * spu-low.c (fetch_ppc_memory): Likewise.
5386 (store_ppc_memory): Likewise.
5387 * target.c (set_target_ops): Likewise.
5388 * thread-db.c (thread_db_load_search): Likewise.
5389 (try_thread_db_load_1): Likewise.
5390 * tracepoint.c (add_tracepoint): Likewise.
5391 (add_tracepoint_action): Likewise.
5392 (create_trace_state_variable): Likewise.
5393 (cmd_qtdpsrc): Likewise.
5394 (cmd_qtro): Likewise.
5395 (add_while_stepping_state): Likewise.
5396 * win32-low.c (child_add_thread): Likewise.
5397 (get_image_name): Likewise.
5398
5399 2015-08-25 Yao Qi <yao.qi@linaro.org>
5400
5401 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5402
5403 2015-08-25 Yao Qi <yao.qi@linaro.org>
5404
5405 * Makefile.in (aarch64-linux.o): New rule.
5406 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5407 srv_tgtobj.
5408 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5409 (aarch64_init_debug_reg_state): Make it extern.
5410 (aarch64_linux_prepare_to_resume): Remove.
5411
5412 2015-08-25 Yao Qi <yao.qi@linaro.org>
5413
5414 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5415 lwp_arch_private_info and ptid_of_lwp.
5416
5417 2015-08-25 Yao Qi <yao.qi@linaro.org>
5418
5419 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5420 Find proc_info by find_process_pid. All callers updated.
5421
5422 2015-08-25 Yao Qi <yao.qi@linaro.org>
5423
5424 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5425 Remove.
5426 (debug_reg_change_callback): Remove.
5427 (aarch64_notify_debug_reg_change): Remove.
5428
5429 2015-08-25 Yao Qi <yao.qi@linaro.org>
5430
5431 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5432 Call current_lwp_ptid.
5433
5434 2015-08-25 Yao Qi <yao.qi@linaro.org>
5435
5436 * linux-aarch64-low.c (debug_reg_change_callback): Use
5437 debug_printf.
5438
5439 2015-08-25 Yao Qi <yao.qi@linaro.org>
5440
5441 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5442
5443 2015-08-25 Yao Qi <yao.qi@linaro.org>
5444
5445 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5446
5447 2015-08-25 Yao Qi <yao.qi@linaro.org>
5448
5449 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5450 the code.
5451
5452 2015-08-25 Yao Qi <yao.qi@linaro.org>
5453
5454 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5455 Remove.
5456 (debug_reg_change_callback): Remove argument entry and add argument
5457 lwp. Remove local variable thread. Don't print thread id in the
5458 debugging output. Don't check whether pid of thread equals to pid.
5459 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5460 iterate_over_lwps instead find_inferior.
5461
5462 2015-08-24 Pedro Alves <palves@redhat.com>
5463
5464 * inferiors.c (get_first_process): New function.
5465 * inferiors.h (get_first_process): New declaration.
5466 * remote-utils.c (read_ptid): Default to the first process in the
5467 list, instead of to the current thread's process.
5468
5469 2015-08-24 Pedro Alves <palves@redhat.com>
5470
5471 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5472 * event-loop.c: Likewise.
5473 * remote-utils.c: Likewise.
5474 * tracepoint.c: Likewise.
5475
5476 2015-08-24 Pedro Alves <palves@redhat.com>
5477
5478 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5479 ptid_get_lwp.
5480
5481 2015-08-21 Pedro Alves <palves@redhat.com>
5482
5483 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5484 instead of literal 1.
5485
5486 2015-08-21 Pedro Alves <palves@redhat.com>
5487
5488 * tdesc.c (default_description): Explicitly zero-initialize.
5489
5490 2015-08-21 Pedro Alves <palves@redhat.com>
5491
5492 PR gdb/18749
5493 * inferiors.c (remove_thread): Discard any pending stop reply for
5494 this thread.
5495 * server.c (remove_all_on_match_pid): Rename to ...
5496 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5497 instead of a pid.
5498 (discard_queued_stop_replies): Change parameter to a ptid. Now
5499 extern.
5500 (handle_v_kill, kill_inferior_callback, captured_main)
5501 (process_serial_event): Adjust.
5502 * server.h (discard_queued_stop_replies): Declare.
5503
5504 2015-08-21 Pedro Alves <palves@redhat.com>
5505
5506 * linux-low.c (wait_for_sigstop): Always switch to no thread
5507 selected if the previously current thread dies.
5508 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5509 process instead of the current thread's.
5510 * remote-utils.c (input_interrupt): Don't check if there's no
5511 current thread.
5512 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5513 current thread to the general thread fails, error out.
5514 (handle_qxfer_auxv, handle_qxfer_libraries)
5515 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5516 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5517 (handle_query): Check if there's a thread selected instead of
5518 checking whether there's any thread in the thread list.
5519 (handle_qxfer_threads, handle_qxfer_btrace)
5520 (handle_qxfer_btrace_conf): Don't error out early if there's no
5521 thread in the thread list.
5522 (handle_v_cont, myresume): Don't set the current thread to the
5523 continue thread.
5524 (process_serial_event) <Hg handling>: Also set thread_id if the
5525 previous general thread is still alive.
5526 (process_serial_event) <g/G handling>: If setting the current
5527 thread to the general thread fails, error out.
5528 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5529 thread's lwp instead of the current thread's.
5530 * target.c (set_desired_thread): If the desired thread was not
5531 found, leave the current thread pointing to NULL. Return an int
5532 (boolean) indicating success.
5533 * target.h (set_desired_thread): Change return type to int.
5534
5535 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5536
5537 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5538 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5539 #includes.
5540 (ps_get_thread_area): New function.
5541
5542 2015-08-19 Gary Benson <gbenson@redhat.com>
5543
5544 * hostio.c (handle_pread): Do not attempt to read more data
5545 than hostio_reply_with_data can fit in a packet.
5546
5547 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5548
5549 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5550
5551 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5552
5553 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5554
5555 2015-08-06 Pedro Alves <palves@redhat.com>
5556
5557 * tracepoint.c (expr_eval_result): Now an int.
5558
5559 2015-08-06 Pedro Alves <palves@redhat.com>
5560
5561 * gdbthread.h (struct regcache): Forward declare.
5562 (struct thread_info) <regcache_data>: Now a struct regcache
5563 pointer.
5564 * inferiors.c (inferior_regcache_data)
5565 (set_inferior_regcache_data): Now work with struct regcache
5566 pointers.
5567 * inferiors.h (struct regcache): Forward declare.
5568 (inferior_regcache_data, set_inferior_regcache_data): Now work
5569 with struct regcache pointers.
5570 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
5571 (free_register_cache_thread): Remove struct regcache pointer
5572 casts.
5573
5574 2015-08-06 Pedro Alves <palves@redhat.com>
5575
5576 * server.c (captured_main): On error, print the exception message
5577 to stderr, and if run_once is set, throw a quit.
5578
5579 2015-08-06 Pedro Alves <palves@redhat.com>
5580
5581 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
5582 the current thread.
5583
5584 2015-08-06 Pedro Alves <palves@redhat.com>
5585
5586 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
5587 reading beyond the passed in buffer length.
5588
5589 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
5590
5591 * tracepoint.c (symbol_list) <required>: Remove.
5592
5593 2015-08-06 Pedro Alves <palves@redhat.com>
5594
5595 * linux-low.c (handle_extended_wait): Set the fork child's suspend
5596 count if stopping and suspending threads.
5597 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
5598 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
5599 (linux_detach): Complete an ongoing step-over.
5600 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
5601 throughout.
5602 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
5603 (linux_wait_1): If passing a signal to the inferior after
5604 finishing a step-over, unsuspend and re-resume all lwps. If we
5605 see a single-step event but the thread should be continuing, don't
5606 pass the trap to gdb.
5607 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
5608 internal_error instead of gdb_assert.
5609 (enqueue_pending_signal): New function.
5610 (check_ptrace_stopped_lwp_gone): Add debug output.
5611 (start_step_over): Use internal_error instead of gdb_assert.
5612 (complete_ongoing_step_over): New function.
5613 (linux_resume_one_thread): Don't resume a suspended thread.
5614 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
5615 it stepping.
5616
5617 2015-08-06 Pedro Alves <palves@redhat.com>
5618
5619 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
5620 (linux_thread_alive): Use lwp_is_marked_dead.
5621 (extended_event_reported): Delete.
5622 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
5623 instead of extended_event_reported.
5624 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
5625 as well.
5626 (lwp_is_marked_dead): New function.
5627 (lwp_running): Use lwp_is_marked_dead.
5628 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
5629 comment.
5630
5631 2015-08-06 Pedro Alves <palves@redhat.com>
5632
5633 * linux-low.c (linux_wait_1): Move fork event output out of the
5634 !report_to_gdb check. Pass event_child->waitstatus to
5635 target_waitstatus_to_string instead of ourstatus.
5636
5637 2015-08-04 Yao Qi <yao.qi@linaro.org>
5638
5639 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
5640 if current_thread is 32 bit.
5641
5642 2015-08-04 Yao Qi <yao.qi@linaro.org>
5643
5644 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5645 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5646 * server.c (extended_protocol): Remove "static".
5647 * server.h (extended_protocol): Declare it.
5648
5649 2015-08-04 Yao Qi <yao.qi@linaro.org>
5650
5651 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
5652 both aarch64 and aarch32.
5653 (aarch64_set_pc): Likewise.
5654
5655 2015-08-04 Yao Qi <yao.qi@linaro.org>
5656
5657 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
5658 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
5659 arm-with-neon.xml to srv_xmlfiles.
5660 * linux-aarch64-low.c: Include linux-aarch32-low.h.
5661 (is_64bit_tdesc): New function.
5662 (aarch64_linux_read_description): New function.
5663 (aarch64_arch_setup): Call aarch64_linux_read_description.
5664 (regs_info): Rename to regs_info_aarch64.
5665 (aarch64_regs_info): Return right regs_info.
5666 (initialize_low_arch): Call initialize_low_arch_aarch32.
5667
5668 2015-08-04 Yao Qi <yao.qi@linaro.org>
5669
5670 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
5671 * linux-aarch32-low.c: New file.
5672 * linux-aarch32-low.h: New file.
5673 * linux-arm-low.c (arm_fill_gregset): Move it to
5674 linux-aarch32-low.c.
5675 (arm_store_gregset): Likewise.
5676 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
5677 (arm_store_vfpregset): Call arm_store_vfpregset_num.
5678 (arm_arch_setup): Check if PTRACE_GETREGSET works.
5679 (regs_info): Rename to regs_info_arm.
5680 (arm_regs_info): Return regs_info_aarch32 if
5681 have_ptrace_getregset is 1 and target description is
5682 arm_with_neon or arm_with_vfpv3.
5683 (initialize_low_arch): Don't call init_registers_arm_with_neon.
5684 Call initialize_low_arch_aarch32 instead.
5685
5686 2015-08-04 Yao Qi <yao.qi@linaro.org>
5687
5688 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
5689 * linux-low.c: ... here.
5690 * linux-low.h (have_ptrace_getregset): Declare it.
5691
5692 2015-08-04 Pedro Alves <palves@redhat.com>
5693
5694 * thread-db.c (struct thread_db): Use new typedefs.
5695 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
5696 CHK calls.
5697 (disable_thread_event_reporting): Cast result of dlsym to
5698 destination function pointer type.
5699 (thread_db_mourn): Use td_ta_delete_ftype.
5700
5701 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
5702
5703 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
5704 arch variant.
5705 (CDX_BREAKPOINT): Define for R2.
5706 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
5707 (the_low_target): Add comments.
5708
5709 2015-07-30 Yao Qi <yao.qi@linaro.org>
5710
5711 * linux-arm-low.c (arm_hwcap): Remove it.
5712 (arm_read_description): New local variable arm_hwcap. Don't
5713 set arm_hwcap to zero.
5714
5715 2015-07-30 Yao Qi <yao.qi@linaro.org>
5716
5717 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
5718 Use regcache->tdesc instead.
5719 (arm_store_wmmxregset): Likewise.
5720 (arm_fill_vfpregset): Likewise.
5721 (arm_store_vfpregset): Likewise.
5722
5723 2015-07-30 Yao Qi <yao.qi@linaro.org>
5724
5725 * linux-arm-low.c: Include arch/arm.h.
5726 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
5727 (arm_store_gregset): Likewise.
5728
5729 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
5730
5731 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
5732 ptrace's 4th parameter.
5733
5734 2015-07-27 Yao Qi <yao.qi@linaro.org>
5735
5736 * configure.srv (case aarch64*-*-linux*): Don't set
5737 srv_linux_usrregs.
5738
5739 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
5740
5741 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
5742 sys/ptrace.h.
5743 * linux-arm-low.c: Likewise.
5744 * linux-cris-low.c: Likewise.
5745 * linux-crisv32-low.c: Likewise.
5746 * linux-low.c: Likewise.
5747 * linux-m68k-low.c: Likewise.
5748 * linux-mips-low.c: Likewise.
5749 * linux-nios2-low.c: Likewise.
5750 * linux-s390-low.c: Likewise.
5751 * linux-sparc-low.c: Likewise.
5752 * linux-tic6x-low.c: Likewise.
5753 * linux-tile-low.c: Likewise.
5754 * linux-x86-low.c: Likewise.
5755
5756 2015-07-24 Pedro Alves <palves@redhat.com>
5757
5758 * config.in: Regenerate.
5759 * configure: Regenerate.
5760
5761 2015-07-24 Pedro Alves <palves@redhat.com>
5762
5763 * acinclude.m4: Include ../ptrace.m4.
5764 * configure.ac: Call GDB_AC_PTRACE.
5765 * config.in, configure: Regenerate.
5766
5767 2015-07-24 Yao Qi <yao.qi@linaro.org>
5768
5769 * linux-low.c (linux_create_inferior): Remove setting to
5770 proc->priv->new_inferior.
5771 (linux_attach): Likewise.
5772 (linux_low_filter_event): Likewise.
5773 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
5774
5775 2015-07-24 Yao Qi <yao.qi@linaro.org>
5776
5777 * linux-low.c (linux_arch_setup): New function.
5778 (linux_low_filter_event): If proc->tdesc is NULL and
5779 proc->attached is true, call the_low_target.arch_setup.
5780 Otherwise, keep status pending, and return.
5781 (linux_resume_one_lwp_throw): Don't call get_pc if
5782 thread->while_stepping isn't NULL. Don't call
5783 get_thread_regcache if proc->tdesc is NULL.
5784 (need_step_over_p): Return 0 if proc->tdesc is NULL.
5785 (linux_target_ops): Install arch_setup.
5786 * server.c (start_inferior): Call the_target->arch_setup.
5787 * target.h (struct target_ops) <arch_setup>: New field.
5788 (target_arch_setup): New marco.
5789 * lynx-low.c (lynx_target_ops): Update.
5790 * nto-low.c (nto_target_ops): Update.
5791 * spu-low.c (spu_target_ops): Update.
5792 * win32-low.c (win32_target_ops): Update.
5793
5794 2015-07-24 Yao Qi <yao.qi@linaro.org>
5795
5796 * linux-low.c (linux_add_process): Don't set
5797 proc->priv->new_inferior.
5798 (linux_create_inferior): Set proc->priv->new_inferior to 1.
5799 (linux_attach): Likewise.
5800
5801 2015-07-24 Yao Qi <yao.qi@linaro.org>
5802
5803 * server.c (start_inferior): Code refactor.
5804
5805 2015-07-24 Yao Qi <yao.qi@linaro.org>
5806
5807 * server.c (process_serial_event): Set general_thread.
5808
5809 2015-07-21 Yao Qi <yao.qi@linaro.org>
5810
5811 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
5812 aarch64_linux_get_debug_reg_capacity.
5813
5814 2015-07-17 Yao Qi <yao.qi@linaro.org>
5815
5816 * Makefile.in (aarch64-linux-hw-point.o): New rule.
5817 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
5818 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
5819 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
5820 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
5821 (AARCH64_HWP_ALIGNMENT): Likewise.
5822 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
5823 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
5824 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
5825 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
5826 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
5827 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
5828 (struct aarch64_debug_reg_state): Likewise.
5829 (struct arch_lwp_info): Likewise.
5830 (aarch64_align_watchpoint): Likewise.
5831 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
5832 (aarch64_watchpoint_length): Likewise.
5833 (aarch64_point_encode_ctrl_reg): Likewise
5834 (aarch64_point_is_aligned): Likewise.
5835 (aarch64_align_watchpoint): Likewise.
5836 (aarch64_linux_set_debug_regs):
5837 (aarch64_dr_state_insert_one_point): Likewise.
5838 (aarch64_dr_state_remove_one_point): Likewise.
5839 (aarch64_handle_breakpoint): Likewise.
5840 (aarch64_handle_aligned_watchpoint): Likewise.
5841 (aarch64_handle_unaligned_watchpoint): Likewise.
5842 (aarch64_handle_watchpoint): Likewise.
5843
5844 2015-07-17 Yao Qi <yao.qi@linaro.org>
5845
5846 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
5847 and don't aarch64_get_debug_reg_state. All callers update.
5848 (aarch64_handle_aligned_watchpoint): Likewise.
5849 (aarch64_handle_unaligned_watchpoint): Likewise.
5850 (aarch64_handle_watchpoint): Likewise.
5851 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
5852 (aarch64_remove_point): Likewise.
5853
5854 2015-07-17 Yao Qi <yao.qi@linaro.org>
5855
5856 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
5857 debug_printf.
5858 (aarch64_handle_unaligned_watchpoint): Likewise.
5859
5860 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5861
5862 Revert the previous 3 commits:
5863 Move gdb_regex* to common/
5864 Move linux_find_memory_regions_full & co.
5865 gdbserver build-id attribute generator
5866
5867 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5868 Jan Kratochvil <jan.kratochvil@redhat.com>
5869
5870 gdbserver build-id attribute generator.
5871 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
5872 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
5873 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
5874 (find_phdr): New.
5875 (get_dynamic): Use find_pdhr to traverse program headers.
5876 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
5877 (compare_mapping_entry_range, struct find_memory_region_callback_data)
5878 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
5879 (get_hex_build_id): New.
5880 (linux_qxfer_libraries_svr4): Add optional build-id attribute
5881 to reply XML document.
5882
5883 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5884 Jan Kratochvil <jan.kratochvil@redhat.com>
5885
5886 * target.c: Include target/target-utils.h and fcntl.h.
5887 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
5888 (target_fileio_read_stralloc): New functions.
5889
5890 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
5891
5892 * Makefile.in (OBS): Add gdb_regex.o.
5893 (gdb_regex.o): New.
5894 * config.in: Rebuilt.
5895 * configure: Rebuilt.
5896
5897 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
5898 Jan Kratochvil <jan.kratochvil@redhat.com>
5899
5900 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
5901 * Makefile.in (OBS): Add target-utils.o.
5902 (linux-maps.o, target-utils.o): New.
5903 * configure.srv (srv_linux_obj): Add linux-maps.o.
5904
5905 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
5906
5907 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
5908 function, return 1.
5909 (the_low_target): Install it.
5910
5911 2015-07-14 Pedro Alves <palves@redhat.com>
5912
5913 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
5914 Instead, ignore ECHILD, and throw an error for other errnos.
5915
5916 2015-07-10 Pedro Alves <palves@redhat.com>
5917
5918 * event-loop.c (struct callback_event) <data>: Change type to
5919 gdb_client_data instance instead of gdb_client_data pointer.
5920 (append_callback_event): Adjust.
5921
5922 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
5923
5924 * linux-aarch64-low.c: Add comments for each linux_target_ops
5925 method. Remove comments already covered in target_ops and
5926 linux_target_ops definitions.
5927 (the_low_target): Add comments for each unimplemented method.
5928
5929 2015-07-09 Yao Qi <yao.qi@linaro.org>
5930
5931 * linux-aarch64-low.c (aarch64_regmap): Remove.
5932 (aarch64_usrregs_info): Remove.
5933 (regs_info): Set field usrregs to NULL.
5934
5935 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
5936
5937 * linux-low.c: Include "rsp-low.h"
5938 (linux_low_encode_pt_config, linux_low_encode_raw): New.
5939 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
5940 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
5941 (handle_btrace_enable_pt): New.
5942 (handle_btrace_general_set): Support "pt".
5943 (handle_btrace_conf_general_set): Support "pt:size".
5944
5945 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5946
5947 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
5948 Z_PACKET_SW_BP.
5949
5950 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
5951
5952 * linux-aarch64-low.c: Remove comment about endianness.
5953 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
5954 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
5955 memcmp.
5956
5957 2015-06-24 Gary Benson <gbenson@redhat.com>
5958
5959 * linux-i386-ipa.c (stdint.h): Do not include.
5960 * lynx-i386-low.c (stdint.h): Likewise.
5961 * lynx-ppc-low.c (stdint.h): Likewise.
5962 * mem-break.c (stdint.h): Likewise.
5963 * thread-db.c (stdint.h): Likewise.
5964 * tracepoint.c (stdint.h): Likewise.
5965 * win32-low.c (stdint.h): Likewise.
5966
5967 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
5968
5969 * server.c (write_qxfer_response): Update call to
5970 remote_escape_output.
5971
5972 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
5973 Jan Kratochvil <jan.kratochvil@redhat.com>
5974
5975 Merge multiple hex conversions.
5976 * gdbreplay.c (tohex): Rename to 'fromhex'.
5977 (logchar): Use fromhex.
5978
5979 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
5980
5981 * server.c (handle_qxfer_libraries): Set `version' attribute for
5982 <library-list>.
5983
5984 2015-06-10 Gary Benson <gbenson@redhat.com>
5985
5986 * target.h (struct target_ops) <multifs_open>: New field.
5987 <multifs_unlink>: Likewise.
5988 <multifs_readlink>: Likewise.
5989 * linux-low.c (nat/linux-namespaces.h): New include.
5990 (linux_target_ops): Initialize the_target->multifs_open,
5991 the_target->multifs_unlink and the_target->multifs_readlink.
5992 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
5993 * hostio.c (hostio_fs_pid): New static variable.
5994 (hostio_handle_new_gdb_connection): New function.
5995 (handle_setfs): Likewise.
5996 (handle_open): Use the_target->multifs_open as appropriate.
5997 (handle_unlink): Use the_target->multifs_unlink as appropriate.
5998 (handle_readlink): Use the_target->multifs_readlink as
5999 appropriate.
6000 (handle_vFile): Handle vFile:setfs packets.
6001 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6002 after target_handle_new_gdb_connection.
6003
6004 2015-06-10 Gary Benson <gbenson@redhat.com>
6005
6006 * configure.ac (AC_CHECK_FUNCS): Add setns.
6007 * config.in: Regenerate.
6008 * configure: Likewise.
6009 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6010 (linux-namespaces.o): New rule.
6011 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6012
6013 2015-06-09 Gary Benson <gbenson@redhat.com>
6014
6015 * hostio.c (handle_open): Process mode argument with
6016 fileio_to_host_mode.
6017
6018 2015-06-01 Yao Qi <yao.qi@linaro.org>
6019
6020 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6021 * linux-x86-low.c: Likewise.
6022
6023 2015-05-28 Don Breazeal <donb@codesourcery.com>
6024
6025 * linux-low.c (handle_extended_wait): Initialize
6026 thread_info.last_resume_kind for new fork children.
6027
6028 2015-05-15 Pedro Alves <palves@redhat.com>
6029
6030 * target.h (target_handle_new_gdb_connection): Rewrite using if
6031 wrapped in do/while.
6032
6033 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6034
6035 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6036 * configure, config.in: Regenerate.
6037 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6038 Declare typedef.
6039
6040 2015-05-12 Don Breazeal <donb@codesourcery.com>
6041
6042 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6043 PTRACE_EVENT_VFORK_DONE.
6044 (linux_low_ptrace_options, extended_event_reported): Add vfork
6045 events.
6046 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6047 and "vforkdone" for RSP 'T' Stop Reply Packet.
6048 * server.h (report_vfork_events): Declare
6049 global variable.
6050
6051 2015-05-12 Don Breazeal <donb@codesourcery.com>
6052
6053 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6054 (the_low_target) <new_fork>: Initialize new member.
6055 * linux-arm-low.c (arm_new_fork): New function.
6056 (the_low_target) <new_fork>: Initialize new member.
6057 * linux-low.c (handle_extended_wait): Call new target function
6058 new_fork.
6059 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6060 * linux-mips-low.c (mips_add_watchpoint): New function
6061 extracted from mips_insert_point.
6062 (the_low_target) <new_fork>: Initialize new member.
6063 (mips_linux_new_fork): New function.
6064 (mips_insert_point): Call mips_add_watchpoint.
6065 * linux-x86-low.c (x86_linux_new_fork): New function.
6066 (the_low_target) <new_fork>: Initialize new member.
6067
6068 2015-05-12 Don Breazeal <donb@codesourcery.com>
6069
6070 * linux-low.c (handle_extended_wait): Implement return value,
6071 rename argument 'event_child' to 'event_lwp', handle
6072 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6073 (linux_low_ptrace_options): New function.
6074 (linux_low_filter_event): Call linux_low_ptrace_options,
6075 use different argument fo linux_enable_event_reporting,
6076 use return value from handle_extended_wait.
6077 (extended_event_reported): New function.
6078 (linux_wait_1): Call extended_event_reported and set
6079 status to report fork events.
6080 (linux_write_memory): Add pid to debug message.
6081 (reset_lwp_ptrace_options_callback): New function.
6082 (linux_handle_new_gdb_connection): New function.
6083 (linux_target_ops): Initialize new structure member.
6084 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6085 * lynx-low.c: Initialize new structure member.
6086 * remote-utils.c (prepare_resume_reply): Implement stop reason
6087 "fork" for "T" stop message.
6088 * server.c (handle_query): Call handle_new_gdb_connection.
6089 * server.h (report_fork_events): Declare global flag.
6090 * target.h (struct target_ops) <handle_new_gdb_connection>:
6091 New member.
6092 (target_handle_new_gdb_connection): New macro.
6093 * win32-low.c: Initialize new structure member.
6094
6095 2015-05-12 Don Breazeal <donb@codesourcery.com>
6096
6097 * mem-break.c (APPEND_TO_LIST): Define macro.
6098 (clone_agent_expr): New function.
6099 (clone_one_breakpoint): New function.
6100 (clone_all_breakpoints): New function.
6101 * mem-break.h: Declare new functions.
6102
6103 2015-05-12 Don Breazeal <donb@codesourcery.com>
6104
6105 * linux-low.c (linux_supports_fork_events): New function.
6106 (linux_supports_vfork_events): New function.
6107 (linux_target_ops): Initialize new structure members.
6108 (initialize_low): Call linux_check_ptrace_features.
6109 * lynx-low.c (lynx_target_ops): Initialize new structure
6110 members.
6111 * server.c (report_fork_events, report_vfork_events):
6112 New global flags.
6113 (handle_query): Add new features to qSupported packet and
6114 response.
6115 (captured_main): Initialize new global variables.
6116 * target.h (struct target_ops) <supports_fork_events>:
6117 New member.
6118 <supports_vfork_events>: New member.
6119 (target_supports_fork_events): New macro.
6120 (target_supports_vfork_events): New macro.
6121 * win32-low.c (win32_target_ops): Initialize new structure
6122 members.
6123
6124 2015-05-12 Gary Benson <gbenson@redhat.com>
6125
6126 * server.c (handle_qxfer_exec_file): Use current process
6127 if annex is empty.
6128
6129 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6130
6131 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6132 Remove HAVE_PTRACE_GETREGS conditionals.
6133 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6134 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6135
6136 2015-05-08 Yao Qi <yao.qi@linaro.org>
6137
6138 * linux-low.c (linux_supports_conditional_breakpoints): New
6139 function.
6140 (linux_target_ops): Install new target method.
6141 * lynx-low.c (lynx_target_ops): Install NULL hook for
6142 supports_conditional_breakpoints.
6143 * nto-low.c (nto_target_ops): Likewise.
6144 * spu-low.c (spu_target_ops): Likewise.
6145 * win32-low.c (win32_target_ops): Likewise.
6146 * server.c (handle_query): Check
6147 target_supports_conditional_breakpoints.
6148 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6149 New field.
6150 (target_supports_conditional_breakpoints): New macro.
6151
6152 2015-05-06 Pedro Alves <palves@redhat.com>
6153
6154 PR server/18081
6155 * server.c (start_inferior): If the process exits, mourn it.
6156
6157 2015-04-21 Gary Benson <gbenson@redhat.com>
6158
6159 * hostio.c (fileio_open_flags_to_host): Factored out to
6160 fileio_to_host_openflags in common/fileio.c. Single use
6161 updated.
6162
6163 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6164
6165 * linux-xtensa-low.c (xtensa_fill_gregset)
6166 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6167 XCHAL_HAVE_LOOP.
6168
6169 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6170
6171 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6172 (regs_info): Replace usrregs pointer with NULL.
6173
6174 2015-04-17 Gary Benson <gbenson@redhat.com>
6175
6176 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6177 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6178 * server.c (handle_qxfer_exec_file): New function.
6179 (qxfer_packets): Add exec-file entry.
6180 (handle_query): Report qXfer:exec-file:read as supported packet.
6181
6182 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6183
6184 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6185
6186 2015-04-09 Gary Benson <gbenson@redhat.com>
6187
6188 * hostio-errno.c (errno_to_fileio_error): Remove function.
6189 Update caller to use remote_fileio_to_fio_error.
6190
6191 2015-04-09 Yao Qi <yao.qi@linaro.org>
6192
6193 * linux-low.c (linux_insert_point): Call
6194 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6195 (linux_remove_point): Call remove_memory_breakpoint if type is
6196 raw_bkpt_type_sw.
6197 * linux-x86-low.c (x86_insert_point): Don't call
6198 insert_memory_breakpoint.
6199 (x86_remove_point): Don't call remove_memory_breakpoint.
6200
6201 2015-04-01 Pedro Alves <palves@redhat.com>
6202 Cleber Rosa <crosa@redhat.com>
6203
6204 * server.c (gdbserver_usage): Reorganize and extend the usage
6205 message.
6206
6207 2015-03-24 Pedro Alves <palves@redhat.com>
6208
6209 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6210 output. Also dump TRAP_TRACE.
6211 (linux_low_filter_event): In debug output, distinguish a
6212 resume_stop SIGSTOP from a delayed SIGSTOP.
6213
6214 2015-03-24 Gary Benson <gbenson@redhat.com>
6215
6216 * linux-x86-low.c (x86_linux_new_thread): Moved to
6217 nat/x86-linux.c.
6218 (x86_linux_prepare_to_resume): Likewise.
6219
6220 2015-03-24 Gary Benson <gbenson@redhat.com>
6221
6222 * Makefile.in (x86-linux-dregs.o): New rule.
6223 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6224 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6225 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6226 (x86_linux_dr_get): Likewise.
6227 (x86_linux_dr_set): Likewise.
6228 (update_debug_registers_callback): Likewise.
6229 (x86_linux_dr_set_addr): Likewise.
6230 (x86_linux_dr_get_addr): Likewise.
6231 (x86_linux_dr_set_control): Likewise.
6232 (x86_linux_dr_get_control): Likewise.
6233 (x86_linux_dr_get_status): Likewise.
6234 (x86_linux_update_debug_registers): Likewise.
6235
6236 2015-03-24 Gary Benson <gbenson@redhat.com>
6237
6238 * linux-x86-low.c (x86_linux_update_debug_registers):
6239 New function, factored out from...
6240 (x86_linux_prepare_to_resume): ...this.
6241
6242 2015-03-24 Gary Benson <gbenson@redhat.com>
6243
6244 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6245 (x86_linux_dr_set): Likewise.
6246 (update_debug_registers_callback): Likewise.
6247 (x86_linux_dr_set_addr): Likewise.
6248 (x86_linux_dr_get_addr): Likewise.
6249 (x86_linux_dr_set_control): Likewise.
6250 (x86_linux_dr_get_control): Likewise.
6251 (x86_linux_dr_get_status): Likewise.
6252 (x86_linux_prepare_to_resume): Likewise.
6253
6254 2015-03-24 Gary Benson <gbenson@redhat.com>
6255
6256 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6257 Use perror_with_name. Pass string through gettext.
6258 (x86_linux_dr_set): Likewise.
6259
6260 2015-03-24 Gary Benson <gbenson@redhat.com>
6261
6262 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6263 (x86_linux_dr_set_addr): ...this.
6264 (x86_dr_low_get_addr): Rename to...
6265 (x86_linux_dr_get_addr): ...this.
6266 (x86_dr_low_set_control): Rename to...
6267 (x86_linux_dr_set_control): ...this.
6268 (x86_dr_low_get_control): Rename to...
6269 (x86_linux_dr_get_control): ...this.
6270 (x86_dr_low_get_status): Rename to...
6271 (x86_linux_dr_get_status): ...this.
6272 (x86_dr_low): Update with new function names.
6273
6274 2015-03-24 Gary Benson <gbenson@redhat.com>
6275
6276 * Makefile.in (x86-linux.o): New rule.
6277 * configure.srv: Add x86-linux.o to relevant targets.
6278 * linux-low.c (lwp_set_arch_private_info): New function.
6279 (lwp_arch_private_info): Likewise.
6280 * linux-x86-low.c: Include nat/x86-linux.h.
6281 (arch_lwp_info): Removed structure.
6282 (update_debug_registers_callback):
6283 Use lwp_set_debug_registers_changed.
6284 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6285 and lwp_set_debug_registers_changed.
6286 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6287
6288 2015-03-24 Gary Benson <gbenson@redhat.com>
6289
6290 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6291 * linux-arm-low.c (arm_new_thread): Likewise.
6292 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6293 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6294 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6295 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6296
6297 2015-03-24 Gary Benson <gbenson@redhat.com>
6298
6299 * linux-low.c (ptid_of_lwp): New function.
6300 (lwp_is_stopped): Likewise.
6301 (lwp_stop_reason): Likewise.
6302 * linux-x86-low.c (update_debug_registers_callback):
6303 Use lwp_is_stopped.
6304 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6305 lwp_stop_reason.
6306
6307 2015-03-24 Gary Benson <gbenson@redhat.com>
6308
6309 * linux-low.h (linux_stop_lwp): Remove declaration.
6310
6311 2015-03-24 Gary Benson <gbenson@redhat.com>
6312
6313 * linux-low.h: Include nat/linux-nat.h.
6314 * linux-low.c (iterate_over_lwps_args): New structure.
6315 (iterate_over_lwps_filter): New function.
6316 (iterate_over_lwps): Likewise.
6317 * linux-x86-low.c (update_debug_registers_callback):
6318 Update signature to what iterate_over_lwps expects.
6319 Remove PID check that iterate_over_lwps now performs.
6320 (x86_dr_low_set_addr): Use iterate_over_lwps.
6321 (x86_dr_low_set_control): Likewise.
6322
6323 2015-03-24 Gary Benson <gbenson@redhat.com>
6324
6325 * linux-x86-low.c (x86_debug_reg_state): New function.
6326 (x86_linux_prepare_to_resume): Use the above.
6327
6328 2015-03-24 Gary Benson <gbenson@redhat.com>
6329
6330 * linux-low.c (current_lwp_ptid): New function.
6331 * linux-x86-low.c: Include nat/linux-nat.h.
6332 (x86_dr_low_get_addr): Use current_lwp_ptid.
6333 (x86_dr_low_get_control): Likewise.
6334 (x86_dr_low_get_status): Likewise.
6335
6336 2015-03-20 Pedro Alves <palves@redhat.com>
6337
6338 * tracepoint.c (cmd_qtstatus): Make "str" const.
6339
6340 2015-03-20 Pedro Alves <palves@redhat.com>
6341
6342 * server.c (handle_general_set): Make "req_str" const.
6343
6344 2015-03-19 Pedro Alves <palves@redhat.com>
6345
6346 * linux-low.c (linux_resume_one_lwp): Rename to ...
6347 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6348 instead call perror_with_name.
6349 (check_ptrace_stopped_lwp_gone): New function.
6350 (linux_resume_one_lwp): Reimplement as wrapper around
6351 linux_resume_one_lwp_throw that swallows errors if the LWP is
6352 gone.
6353
6354 2015-03-19 Pedro Alves <palves@redhat.com>
6355
6356 * linux-low.c (count_events_callback, select_event_lwp_callback):
6357 No longer check whether the thread has resume_stop as last resume
6358 kind.
6359
6360 2015-03-19 Pedro Alves <palves@redhat.com>
6361
6362 * linux-low.c (count_events_callback, select_event_lwp_callback):
6363 Use the lwp's status_pending_p field, not the thread's.
6364
6365 2015-03-19 Pedro Alves <palves@redhat.com>
6366
6367 * linux-low.c (select_event_lwp_callback): Update comments to
6368 no longer mention SIGTRAP.
6369
6370 2015-03-18 Gary Benson <gbenson@redhat.com>
6371
6372 * server.c (handle_query): Do not report vFile:fstat as supported.
6373
6374 2015-03-11 Gary Benson <gbenson@redhat.com>
6375
6376 * hostio.c (sys/types.h): New include.
6377 (sys/stat.h): Likewise.
6378 (common-remote-fileio.h): Likewise.
6379 (handle_fstat): New function.
6380 (handle_vFile): Handle vFile:fstat packets.
6381
6382 2015-03-11 Gary Benson <gbenson@redhat.com>
6383
6384 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6385 struct stat.st_blocks and struct stat.st_blksize.
6386 * configure: Regenerate.
6387 * config.in: Likewise.
6388 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6389 (OBS): Add common-remote-fileio.o.
6390 (common-remote-fileio.o): New rule.
6391
6392 2015-03-09 Pedro Alves <palves@redhat.com>
6393
6394 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6395 'struct sockaddr' pointer in 'accept' call.
6396
6397 2015-03-09 Pedro Alves <palves@redhat.com>
6398
6399 Revert:
6400 2015-03-07 Pedro Alves <palves@redhat.com>
6401 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6402 or <winsock2.h> here. Instead include "gdb_socket.h".
6403 (remote_open): Use union gdb_sockaddr_u.
6404 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6405 or <winsock2.h> here. Instead include "gdb_socket.h".
6406 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6407 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6408 or <sys/un.h>.
6409 (init_named_socket, gdb_agent_helper_thread): Use union
6410 gdb_sockaddr_u.
6411
6412 2015-03-07 Pedro Alves <palves@redhat.com>
6413
6414 * configure.ac (build_warnings): Move
6415 -Wdeclaration-after-statement to the C-specific set.
6416 * configure: Regenerate.
6417
6418 2015-03-07 Pedro Alves <palves@redhat.com>
6419
6420 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6421 or <winsock2.h> here. Instead include "gdb_socket.h".
6422 (remote_open): Use union gdb_sockaddr_u.
6423 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6424 or <winsock2.h> here. Instead include "gdb_socket.h".
6425 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6426 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6427 or <sys/un.h>.
6428 (init_named_socket, gdb_agent_helper_thread): Use union
6429 gdb_sockaddr_u.
6430
6431 2015-03-07 Pedro Alves <palves@redhat.com>
6432
6433 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6434 instead.
6435
6436 2015-03-06 Yao Qi <yao.qi@linaro.org>
6437
6438 * linux-aarch64-low.c (aarch64_insert_point): Use
6439 show_debug_regs as a boolean.
6440 (aarch64_remove_point): Likewise.
6441
6442 2015-03-05 Pedro Alves <palves@redhat.com>
6443
6444 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6445 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6446 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6447 * nto-low.c (nto_target_ops): Likewise.
6448 * spu-low.c (spu_target_ops): Likewise.
6449 * win32-low.c (win32_target_ops): Likewise.
6450
6451 2015-03-04 Pedro Alves <palves@redhat.com>
6452
6453 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6454 Decide whether a breakpoint triggered based on the SIGTRAP's
6455 siginfo.si_code.
6456 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6457 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6458 (linux_low_filter_event): Check for breakpoints before checking
6459 watchpoints.
6460 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6461 siginfo.si_code.
6462 (linux_stopped_by_sw_breakpoint)
6463 (linux_supports_stopped_by_sw_breakpoint)
6464 (linux_stopped_by_hw_breakpoint)
6465 (linux_supports_stopped_by_hw_breakpoint): New functions.
6466 (linux_target_ops): Install new target methods.
6467
6468 2015-03-04 Pedro Alves <palves@redhat.com>
6469
6470 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6471 * server.c (swbreak_feature, hwbreak_feature): New globals.
6472 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6473 (captured_main): Clear swbreak_feature and hwbreak_feature.
6474 * server.h (swbreak_feature, hwbreak_feature): Declare.
6475 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6476 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6477 supports_stopped_by_hw_breakpoint>: New fields.
6478 (target_supports_stopped_by_sw_breakpoint)
6479 (target_stopped_by_sw_breakpoint)
6480 (target_supports_stopped_by_hw_breakpoint)
6481 (target_stopped_by_hw_breakpoint): Declare.
6482
6483 2015-03-04 Pedro Alves <palves@redhat.com>
6484
6485 enum lwp_stop_reason -> enum target_stop_reason
6486 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6487 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6488 (linux_wait_1, stuck_in_jump_pad_callback)
6489 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6490 (linux_stopped_by_watchpoint):
6491 * linux-low.h (enum lwp_stop_reason): Delete.
6492 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6493 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6494
6495 2015-03-04 Yao Qi <yao.qi@linaro.org>
6496
6497 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6498
6499 2015-03-03 Gary Benson <gbenson@redhat.com>
6500
6501 * hostio.c (handle_vFile): Fix prefix lengths.
6502
6503 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6504
6505 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6506 ptr_bits.
6507
6508 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6509
6510 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6511 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6512 (clean): Add "rm -f" for above C files.
6513 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6514 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6515 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6516 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6517 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6518 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6519 (init_registers_s390x_vx_linux64)
6520 (init_registers_s390x_tevx_linux64)
6521 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6522 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6523 declarations.
6524 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6525 (s390_store_vxrs_high): New functions.
6526 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6527 NT_S390_VXRS_HIGH.
6528 (s390_arch_setup): Add logic for selecting one of the new target
6529 descriptions. Activate the new vector regsets if applicable.
6530 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6531 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6532 and init_registers_s390x_tevx_linux64.
6533
6534 2015-03-01 Pedro Alves <palves@redhat.com>
6535
6536 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6537 parameter.
6538
6539 2015-02-27 Pedro Alves <palves@redhat.com>
6540
6541 * linux-x86-low.c (u_debugreg_offset): New function.
6542 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6543
6544 2015-02-27 Pedro Alves <palves@redhat.com>
6545
6546 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6547 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6548 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6549 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6550 (ps_lsetfpregs, ps_getpid)
6551 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6552 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6553 (ps_lsetxregs, ps_plog): Declare.
6554
6555 2015-02-27 Pedro Alves <palves@redhat.com>
6556
6557 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6558 IP_AGENT_EXPORT_FUNC.
6559 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6560 IP_AGENT_EXPORT_FUNC.
6561 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6562 (IP_AGENT_EXPORT): Delete.
6563 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6564 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6565 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6566 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
6567 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
6568 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
6569 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
6570 (traceframe_read_count, traceframe_write_count)
6571 (traceframes_created, trace_state_variables, get_raw_reg)
6572 (get_trace_state_variable_value, set_trace_state_variable_value)
6573 (ust_loaded, helper_thread_id, cmd_buf): Use
6574 IPA_SYM_EXPORTED_NAME.
6575 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
6576 (tracepoints) Use IP_AGENT_EXPORT_VAR.
6577 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
6578 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6579 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
6580 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
6581 EXTERN_C_PUSH/EXTERN_C_POP.
6582 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
6583 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
6584 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6585 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
6586 (traceframe_write_count, traceframe_read_count)
6587 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
6588 (about_to_request_buffer_space, get_trace_state_variable_value)
6589 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
6590 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
6591 EXTERN_C_PUSH/EXTERN_C_POP.
6592 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
6593 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
6594 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
6595 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
6596 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6597 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6598 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
6599 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
6600 Define.
6601 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
6602 (IP_AGENT_EXPORT_VAR_DECL): Define.
6603 (tracing): Declare.
6604 (gdb_agent_get_raw_reg): Declare.
6605
6606 2015-02-27 Tom Tromey <tromey@redhat.com>
6607 Pedro Alves <palves@redhat.com>
6608
6609 Rename symbols whose names are reserved C++ keywords throughout.
6610
6611 2015-02-27 Pedro Alves <palves@redhat.com>
6612
6613 * Makefile.in (COMPILER): New, get it from autoconf.
6614 (CXX): Get from autoconf instead.
6615 (COMPILE.pre): Use COMPILER.
6616 (CC-LD): Rename to ...
6617 (CC_LD): ... this. Use COMPILER.
6618 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
6619 (CXX_FOR_TARGET): Default to g++ instead of gcc.
6620 * acinclude.m4: Include build-with-cxx.m4.
6621 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
6622 Disable -Werror by default if building in C++ mode.
6623 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
6624 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
6625 the C++ compiler. Save/restore CXXFLAGS too.
6626 * configure: Regenerate.
6627
6628 2015-02-27 Pedro Alves <palves@redhat.com>
6629
6630 * acinclude.m4: Include libiberty.m4.
6631 * configure.ac: Call libiberty_INIT.
6632 * config.in, configure: Regenerate.
6633
6634 2015-02-26 Pedro Alves <palves@redhat.com>
6635
6636 * linux-low.c (linux_wait_1): When incrementing the PC past a
6637 program breakpoint always use the_low_target.breakpoint_len as
6638 increment, rather than the maximum between that and
6639 the_low_target.decr_pc_after_break.
6640
6641 2015-02-23 Pedro Alves <palves@redhat.com>
6642
6643 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
6644 thread was doing a step-over; always adjust the PC if
6645 we stepped over a permanent breakpoint.
6646 (linux_wait_1): If we stepped over breakpoint that was on top of a
6647 permanent breakpoint, manually advance the PC past it.
6648
6649 2015-02-23 Pedro Alves <palves@redhat.com>
6650
6651 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
6652 modes.
6653 (x86_fill_gregset, x86_store_gregset): Use it when handling
6654 $orig_eax.
6655
6656 2015-02-20 Pedro Alves <palves@redhat.com>
6657
6658 * thread-db.c: Include "nat/linux-procfs.h".
6659 (thread_db_init): Skip listing new threads if the kernel supports
6660 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
6661
6662 2015-02-20 Pedro Alves <palves@redhat.com>
6663
6664 * linux-low.c (status_pending_p_callback): Use ptid_match.
6665
6666 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
6667
6668 PR breakpoints/16812
6669 * linux-low.c (wstatus_maybe_breakpoint): Remove.
6670 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
6671 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
6672
6673 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
6674
6675 PR breakpoints/15956
6676 * tracepoint.c (cmd_qtinit): Add check for current_thread.
6677
6678 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6679
6680 * linux-low.c (linux_low_btrace_conf): Print size.
6681 * server.c (handle_btrace_conf_general_set): New.
6682 (hanle_general_set): Call handle_btrace_conf_general_set.
6683 (handle_query): Report Qbtrace-conf:bts:size as supported.
6684
6685 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6686
6687 * linux-low.c (linux_low_enable_btrace): Update parameters.
6688 (linux_low_btrace_conf): New.
6689 (linux_target_ops)<to_btrace_conf>: Initialize.
6690 * server.c (current_btrace_conf): New.
6691 (handle_btrace_enable): Rename to ...
6692 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
6693 to target_enable_btrace. Update comment. Update users.
6694 (handle_qxfer_btrace_conf): New.
6695 (qxfer_packets): Add btrace-conf entry.
6696 (handle_query): Report qXfer:btrace-conf:read as supported packet.
6697 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
6698 (target_ops)<read_btrace_conf>: New.
6699 (target_enable_btrace): Update parameters.
6700 (target_read_btrace_conf): New.
6701
6702 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6703
6704 * server.c (handle_btrace_general_set): Remove call to
6705 target_supports_btrace.
6706 (supported_btrace_packets): New.
6707 (handle_query): Call supported_btrace_packets.
6708 * target.h: include btrace-common.h.
6709 (btrace_target_info): Removed.
6710 (supports_btrace, target_supports_btrace): Update parameters.
6711
6712 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
6713
6714 * Makefile.in (SFILES): Add common/btrace-common.c.
6715 (OBS): Add common/btrace-common.o.
6716 (btrace-common.o): Add build rules.
6717 * linux-low: Include btrace-common.h.
6718 (linux_low_read_btrace): Use struct btrace_data. Call
6719 btrace_data_init and btrace_data_fini.
6720
6721 2015-02-06 Pedro Alves <palves@redhat.com>
6722
6723 * thread-db.c (find_new_threads_callback): Add debug output.
6724
6725 2015-02-04 Pedro Alves <palves@redhat.com>
6726
6727 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
6728 (resume_stopped_resumed_lwps): New function.
6729 (linux_wait_for_event_filtered): Use it.
6730
6731 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6732
6733 * Makefile.in (SFILES): Add linux-personality.c.
6734 (linux-personality.o): New rule.
6735 * configure.srv (srv_linux_obj): Add linux-personality.o to the
6736 list of objects to be built.
6737 * linux-low.c: Include nat/linux-personality.h.
6738 (linux_create_inferior): Remove code to disable address space
6739 randomization (moved to ../nat/linux-personality.c). Create
6740 cleanup to disable address space randomization.
6741
6742 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
6743
6744 * Makefile.in (posix-strerror.o): New rule.
6745 (mingw-strerror.o): Likewise.
6746 * configure: Regenerated.
6747 * configure.ac: Source file ../common/common.host. Initialize new
6748 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
6749
6750 2015-01-14 Yao Qi <yao@codesourcery.com>
6751
6752 * Makefile.in (SFILES): Add nat/ppc-linux.c.
6753 (ppc-linux.o): New rule.
6754 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
6755 * configure.ac: AC_CHECK_FUNCS(getauxval).
6756 * config.in: Re-generated.
6757 * configure: Re-generated.
6758 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
6759 ppc64_64bit_inferior_p
6760
6761 2015-01-14 Yao Qi <yao@codesourcery.com>
6762
6763 * linux-ppc-low.c: Include "nat/ppc-linux.h".
6764 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
6765 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
6766 (PT_ORIG_R3, PT_TRAP): Likewise.
6767 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
6768 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
6769 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
6770
6771 2015-01-10 Joel Brobecker <brobecker@adacore.com>
6772
6773 * i387-fp.c (i387_cache_to_xsave): In look over
6774 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
6775 zmmh_low_space field by use of zmmh_high_space.
6776
6777 2015-01-09 Pedro Alves <palves@redhat.com>
6778
6779 * linux-low.c (step_over_bkpt): Move higher up in the file.
6780 (handle_extended_wait): Don't store the stop_pc here.
6781 (get_stop_pc): Adjust comments and rename to ...
6782 (check_stopped_by_breakpoint): ... this. Record whether the LWP
6783 stopped for a software breakpoint or hardware breakpoint.
6784 (thread_still_has_status_pending_p): New function.
6785 (status_pending_p_callback): Use
6786 thread_still_has_status_pending_p. If the event is no longer
6787 interesting, resume the LWP.
6788 (handle_tracepoints): Add assert.
6789 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
6790 (wstatus_maybe_breakpoint): New function.
6791 (cancel_breakpoint): Delete function.
6792 (check_stopped_by_watchpoint): New function, factored out from
6793 linux_low_filter_event.
6794 (lp_status_maybe_breakpoint): Delete function.
6795 (linux_low_filter_event): Remove filter_ptid argument.
6796 Leave thread group exits pending here. Store the LWP's stop PC.
6797 Always leave events pending.
6798 (linux_wait_for_event_filtered): Pull all events out of the
6799 kernel, and leave them all pending.
6800 (count_events_callback, select_event_lwp_callback): Consider all
6801 events.
6802 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
6803 (select_event_lwp): Only give preference to the stepping LWP in
6804 all-stop mode. Adjust comments.
6805 (ignore_event): New function.
6806 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
6807 references to cancel_breakpoints. Adjust to renames. Also give
6808 equal priority to all LWPs that have had events in non-stop mode.
6809 If reporting a software breakpoint event, unadjust the LWP's PC.
6810 (linux_wait): If linux_wait_1 returned an ignored event, retry.
6811 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
6812 Adjust.
6813 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
6814 (resume_status_pending_p): Use thread_still_has_status_pending_p.
6815 (linux_stopped_by_watchpoint): Adjust.
6816 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
6817 * linux-low.h (enum lwp_stop_reason): New.
6818 (struct lwp_info) <stop_pc>: Adjust comment.
6819 <stopped_by_watchpoint>: Delete field.
6820 <stop_reason>: New field.
6821 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6822 * mem-break.c (software_breakpoint_inserted_here)
6823 (hardware_breakpoint_inserted_here): New function.
6824 * mem-break.h (software_breakpoint_inserted_here)
6825 (hardware_breakpoint_inserted_here): Declare.
6826 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
6827 (cancel_breakpoints): Delete.
6828 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
6829 (upload_fast_traceframes): Remove references to
6830 cancel_breakpoints.
6831
6832 2015-01-09 Pedro Alves <palves@redhat.com>
6833
6834 * thread-db.c (find_new_threads_callback): Ignore thread if the
6835 kernel thread ID is -1.
6836
6837 2015-01-09 Pedro Alves <palves@redhat.com>
6838
6839 * linux-low.c (linux_attach_fail_reason_string): Move to
6840 nat/linux-ptrace.c, and rename.
6841 (linux_attach_lwp): Update comment.
6842 (attach_proc_task_lwp_callback): New function.
6843 (linux_attach): Adjust to rename and use
6844 linux_proc_attach_tgid_threads.
6845 (linux_attach_fail_reason_string): Delete declaration.
6846
6847 2015-01-01 Joel Brobecker <brobecker@adacore.com>
6848
6849 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
6850 * server.c (gdbserver_version): Likewise.
6851
6852 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
6853
6854 * remote-utils.c: Include ctype.h.
6855 (input_interrupt): Explicitly handle the case when the char
6856 received is the NUL byte. Improve the printing of non-ASCII
6857 characters.
6858
6859 2014-12-16 Joel Brobecker <brobecker@adacore.com>
6860
6861 * linux-low.c (linux_low_filter_event): Update call to
6862 linux_enable_event_reporting following the addition of
6863 a new parameter to that function.
6864
6865 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
6866
6867 PR server/17457
6868 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
6869 (AARCH64_FPCR_REGNO): Likewise.
6870 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
6871 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
6872 (aarch64_store_fpregset): Likewise.
6873
6874 2014-12-15 Joel Brobecker <brobecker@adacore.com>
6875
6876 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
6877 Remove FIXME comment about assumption about N.
6878
6879 2014-12-13 Joel Brobecker <brobecker@adacore.com>
6880
6881 * configure.ac: If large-file support is disabled in GDBserver,
6882 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
6883 * configure: Regenerate.
6884
6885 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6886
6887 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
6888 warning upon ENODATA from ptrace.
6889 * linux-s390-low.c (s390_store_tdb): New.
6890 (s390_regsets): Add regset for NT_S390_TDB.
6891
6892 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6893
6894 * linux-low.c (regsets_store_inferior_registers): Skip regsets
6895 without a fill_function.
6896 * linux-s390-low.c (s390_fill_last_break): Remove.
6897 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
6898 (s390_arch_setup): Use regset's size instead of fill_function for
6899 loop end condition.
6900
6901 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6902
6903 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
6904 the regset's store function when ptrace returned an error.
6905 * regcache.c (get_thread_regcache): Invalidate register cache
6906 before fetching inferior's registers.
6907
6908 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
6909
6910 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
6911 while-loop as for-loop.
6912 (regsets_store_inferior_registers): Likewise.
6913
6914 2014-11-28 Yao Qi <yao@codesourcery.com>
6915
6916 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
6917 * config.in, configure: Re-generate.
6918 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
6919 is defined.
6920
6921 2014-11-21 Yao Qi <yao@codesourcery.com>
6922
6923 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
6924 (AC_CHECK_HEADERS): Remove malloc.h.
6925 * configure: Re-generated.
6926 * config.in: Re-generated.
6927 * server.h: Don't include alloca.h and malloc.h.
6928 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
6929 Don't include malloc.h.
6930
6931 2014-11-17 Joel Brobecker <brobecker@adacore.com>
6932
6933 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
6934 corresponding ERRNO check in same block.
6935
6936 2014-11-12 Pedro Alves <palves@redhat.com>
6937
6938 * server.c (cont_thread): Update comment.
6939 (start_inferior, attach_inferior): No longer clear cont_thread.
6940 (handle_v_cont): No longer set cont_thread.
6941 (captured_main): Clear cont_thread each time a GDB connects.
6942
6943 2014-11-12 Pedro Alves <palves@redhat.com>
6944
6945 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
6946 thread, and don't resume all threads if the Hc thread has exited.
6947
6948 2014-11-12 Pedro Alves <palves@redhat.com>
6949
6950 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
6951 the process group instead of to a specific LWP.
6952
6953 2014-10-15 Pedro Alves <palves@redhat.com>
6954
6955 PR server/17487
6956 * win32-arm-low.c (arm_set_thread_context): Remove current_event
6957 parameter.
6958 (arm_set_thread_context): Delete.
6959 (the_low_target): Adjust.
6960 * win32-i386-low.c (debug_registers_changed)
6961 (debug_registers_used): Delete.
6962 (update_debug_registers_callback): New function.
6963 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
6964 needing to update their debug registers.
6965 (win32_get_current_dr): New function.
6966 (x86_dr_low_get_addr, x86_dr_low_get_control)
6967 (x86_dr_low_get_status): Fetch the debug register from the thread
6968 record's context.
6969 (i386_initial_stuff): Adjust.
6970 (i386_get_thread_context): Remove current_event parameter. Don't
6971 clear debug_registers_changed nor copy DR values to
6972 debug_reg_state.
6973 (i386_set_thread_context): Delete.
6974 (i386_prepare_to_resume): New function.
6975 (i386_thread_added): Mark the thread as needing to update irs
6976 debug registers.
6977 (the_low_target): Remove i386_set_thread_context and install
6978 i386_prepare_to_resume.
6979 * win32-low.c (win32_get_thread_context): Adjust.
6980 (win32_set_thread_context): Use SetThreadContext
6981 directly.
6982 (win32_prepare_to_resume): New function.
6983 (win32_require_context): New function, factored out from ...
6984 (thread_rec): ... this.
6985 (continue_one_thread): Call win32_prepare_to_resume on each thread
6986 we're about to continue.
6987 (win32_resume): Call win32_prepare_to_resume on the event thread.
6988 * win32-low.h (struct win32_thread_info)
6989 <debug_registers_changed>: New field.
6990 (struct win32_target_ops): Change prototype of set_thread_context,
6991 delete set_thread_context and add prepare_to_resume.
6992 (win32_require_context): New declaration.
6993
6994 2014-10-08 Gary Benson <gbenson@redhat.com>
6995
6996 * server.h: Do not include common-exceptions.h.
6997
6998 2014-10-08 Gary Benson <gbenson@redhat.com>
6999
7000 * server.h: Do not include cleanups.h.
7001
7002 2014-09-30 James Hogan <james.hogan@imgtec.com>
7003
7004 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7005 mips64-dsp-linux.c.
7006
7007 2014-09-23 Yao Qi <yao@codesourcery.com>
7008
7009 * linux-low.c (lp_status_maybe_breakpoint): New function.
7010 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7011 (count_events_callback): Likewise.
7012 (select_event_lwp_callback): Likewise.
7013 (cancel_breakpoints_callback): Likewise.
7014
7015 2014-09-19 Don Breazeal <donb@codesourcery.com>
7016
7017 * linux-low.c (handle_extended_wait): Call
7018 linux_ptrace_get_extended_event.
7019 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7020 linux_is_extended_waitstatus.
7021
7022 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7023
7024 * Makefile.in (CPPFLAGS): Define.
7025 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7026 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7027
7028 2014-09-16 Gary Benson <gbenson@redhat.com>
7029
7030 * inferiors.h (current_inferior): Renamed as...
7031 (current_thread): New variable. All uses updated.
7032 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7033 (maybe_move_out_of_jump_pad): Likewise.
7034 (cancel_breakpoint): Likewise.
7035 (linux_low_filter_event): Likewise.
7036 (wait_for_sigstop): Likewise.
7037 (linux_resume_one_lwp): Likewise.
7038 (need_step_over_p): Likewise.
7039 (start_step_over): Likewise.
7040 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7041 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7042 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7043 and save_inferior as saved_thread.
7044 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7045 saved_thread.
7046 (regcache_invalidate_thread): Likewise.
7047 * remote-utils.c (prepare_resume_reply): Likewise.
7048 * thread-db.c (thread_db_get_tls_address): Likewise.
7049 (disable_thread_event_reporting): Likewise.
7050 (remove_thread_event_breakpoints): Likewise.
7051 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7052 as saved_thread.
7053 * target.h (set_desired_inferior): Renamed as...
7054 (set_desired_thread): New declaration. All uses updated.
7055 * server.c (myresume): Updated comment to reference thread instead
7056 of inferior.
7057 (handle_serial_event): Likewise.
7058 (handle_target_event): Likewise.
7059
7060 2014-09-12 Tom Tromey <tromey@redhat.com>
7061 Gary Benson <gbenson@redhat.com>
7062
7063 * regcache.h: Include common-regcache.h.
7064 (regcache_read_pc): Don't declare.
7065 * regcache.c (get_thread_regcache_for_ptid): New function.
7066
7067 2014-09-11 Tom Tromey <tromey@redhat.com>
7068 Gary Benson <gbenson@redhat.com>
7069
7070 * symbol.c: New file.
7071 * Makefile.in (SFILES): Add symbol.c.
7072 (OBS): Add symbol.o.
7073
7074 2014-09-11 Gary Benson <gbenson@redhat.com>
7075
7076 * target.c (target_stop_ptid, target_continue_ptid): New
7077 functions.
7078
7079 2014-09-11 Tom Tromey <tromey@redhat.com>
7080 Gary Benson <gbenson@redhat.com>
7081
7082 * target.h: Include target/target.h.
7083 * target.c (target_read_memory, target_read_uint32)
7084 (target_write_memory): New functions.
7085
7086 2014-09-11 Gary Benson <gbenson@redhat.com>
7087
7088 * server.h (debug_hw_points): Don't declare.
7089 * server.c (debug_hw_points): Don't define. Replace all uses
7090 with show_debug_regs.
7091 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7092 all uses with show_debug_regs.
7093
7094 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7095
7096 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7097 endianness into account.
7098 (ppc_supply_ptrace_register): Likewise.
7099
7100 2014-09-03 James Hogan <james.hogan@imgtec.com>
7101
7102 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7103 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7104
7105 2014-09-03 Gary Benson <gbenson@redhat.com>
7106
7107 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7108 ALL_DEBUG_ADDRESS_REGISTERS.
7109
7110 2014-09-02 Gary Benson <gbenson@redhat.com>
7111
7112 * i386-low.h: Renamed as...
7113 * x86-low.h: New file. All type, function and variable name
7114 prefixes changed from "i386_" to "x86_". All references updated.
7115 * i386-low.c: Renamed as...
7116 * x86-low.c: New file. All type, function and variable name
7117 prefixes changed from "i386_" to "x86_". All references updated.
7118
7119 2014-09-02 Gary Benson <gbenson@redhat.com>
7120
7121 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7122 (x86_linux_new_thread): Likewise.
7123
7124 2014-08-29 Gary Benson <gbenson@redhat.com>
7125
7126 * server.h (setjmp.h): Do not include.
7127 (toplevel): Do not declare.
7128 (common-exceptions.h): Include.
7129 (cleanups.h): Likewise.
7130 * server.c (toplevel): Do not define.
7131 (exit_code): New static global.
7132 (detach_or_kill_for_exit_cleanup): New function.
7133 (main): New function. Original main renamed to...
7134 (captured_main): New function.
7135 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7136
7137 2014-08-29 Gary Benson <gbenson@redhat.com>
7138
7139 * Makefile.in (SFILES): Add common/common-exceptions.c.
7140 (OBS): Add common-exceptions.o.
7141 (common-exceptions.o): New rule.
7142 * utils.c (prepare_to_throw_exception): New function.
7143
7144 2014-08-29 Gary Benson <gbenson@redhat.com>
7145
7146 * config.in: Regenerate.
7147 * configure: Likewise.
7148
7149 2014-08-29 Gary Benson <gbenson@redhat.com>
7150
7151 * Makefile.in (SFILES): Add common/cleanups.c.
7152 (OBS): cleanups.o.
7153 (cleanups.o): New rule.
7154
7155 2014-08-29 Gary Benson <gbenson@redhat.com>
7156
7157 * utils.c (internal_vwarning): New function.
7158
7159 2014-08-28 Gary Benson <gbenson@redhat.com>
7160
7161 * utils.h (fatal): Remove declaration.
7162 * utils.c (fatal): Remove function.
7163
7164 2014-08-28 Gary Benson <gbenson@redhat.com>
7165
7166 * tracepoint.c (gdb_agent_init): Replace fatal with
7167 perror_with_name.
7168 (initialize_tracepoint): Likewise.
7169
7170 2014-08-28 Gary Benson <gbenson@redhat.com>
7171
7172 * remote-utils.c (remote_prepare): Replace fatal with error.
7173
7174 2014-08-28 Gary Benson <gbenson@redhat.com>
7175
7176 * linux-low.c (linux_async): Replace fatal with warning.
7177 Tidy up and return.
7178 (linux_start_non_stop): Return -1 if linux_async failed.
7179
7180 2014-08-28 Gary Benson <gbenson@redhat.com>
7181
7182 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7183 gdb_assert.
7184 (i386_dr_low_get_addr): Remove vague comment.
7185 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7186 gdb_assert.
7187
7188 2014-08-28 Gary Benson <gbenson@redhat.com>
7189
7190 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7191 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7192 internal_error.
7193 (linux_resume_one_lwp): Likewise.
7194 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7195 gdb_assert.
7196 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7197 with internal_error.
7198 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7199 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7200 (find_register_by_name): Replace fatal with internal_error.
7201 (find_regno): Likewise.
7202 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7203 * thread-db.c (thread_db_create_event): Likewise.
7204 (thread_db_load_search): Likewise.
7205 (try_thread_db_load_1): Likewise.
7206 * tracepoint.c (get_jump_space_head): Replace fatal with
7207 internal_error.
7208 (claim_trampoline_space): Likewise.
7209 (have_fast_tracepoint_trampoline_buffer): Likewise.
7210 (cmd_qtstart): Likewise.
7211 (stop_tracing): Likewise.
7212 (fast_tracepoint_collecting): Likewise.
7213 (target_malloc): Likewise.
7214 (download_tracepoint): Likewise.
7215 (download_trace_state_variables): Replace check with gdb_assert.
7216 (upload_fast_traceframes): Replace fatal with internal_error.
7217
7218 2014-08-19 Tom Tromey <tromey@redhat.com>
7219 Gary Benson <gbenson@redhat.com>
7220
7221 * Makefile.in (SFILES): Add common/common-debug.c.
7222 (OBS): Add common-debug.o.
7223 (common-debug.o): New rule.
7224 * debug.h (debug_printf): Don't declare.
7225 * debug.c (debug_printf): Renamed and rewritten as...
7226 (debug_vprintf): New function.
7227
7228 2014-08-19 Gary Benson <gbenson@redhat.com>
7229
7230 * utils.h: Do not include print-utils.h.
7231
7232 2014-08-19 Tom Tromey <tromey@redhat.com>
7233 Gary Benson <gbenson@redhat.com>
7234
7235 * server.h: Add static assertion.
7236 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7237
7238 2014-08-19 Tom Tromey <tromey@redhat.com>
7239 Gary Benson <gbenson@redhat.com>
7240
7241 * Makefile.in (SFILES): Add common/errors.c.
7242 (OBS): Add errors.o.
7243 (IPA_OBS): Add errors-ipa.o.
7244 (errors.o): New rule.
7245 (errors-ipa.o): Likewise.
7246 * utils.h (perror_with_name, error, warning): Don't declare.
7247 * utils.c (warning): Renamed and rewritten as...
7248 (vwarning): New function.
7249 (error): Renamed and rewritten as...
7250 (verror): New function.
7251 (internal_error): Renamed and rewritten as...
7252 (internal_verror): New function.
7253
7254 2014-08-07 Gary Benson <gbenson@redhat.com>
7255
7256 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7257 * configure: Regenerate.
7258 * config.in: Likewise.
7259 * server.h: Do not include errno.h.
7260 * event-loop.c: Likewise.
7261 * hostio-errno.c: Likewise.
7262 * linux-low.c: Likewise.
7263 * remote-utils.c: Likewise.
7264 * spu-low.c: Likewise.
7265 * utils.c: Likewise.
7266 * gdbreplay.c: Unconditionally include errno.h.
7267
7268 2014-08-07 Gary Benson <gbenson@redhat.com>
7269
7270 * server.h: Do not include string.h.
7271 * event-loop.c: Likewise.
7272 * linux-low.c: Likewise.
7273 * regcache.c: Likewise.
7274 * remote-utils.c: Likewise.
7275 * spu-low.c: Likewise.
7276 * utils.c: Likewise.
7277
7278 2014-08-07 Gary Benson <gbenson@redhat.com>
7279
7280 * server.h: Do not include gdb_assert.h.
7281
7282 2014-08-07 Gary Benson <gbenson@redhat.com>
7283
7284 * server.h: Do not include common-utils.h.
7285
7286 2014-08-07 Gary Benson <gbenson@redhat.com>
7287
7288 * server.h: Do not include ptid.h.
7289 * notif.h: Likewise.
7290
7291 2014-08-07 Gary Benson <gbenson@redhat.com>
7292
7293 * server.h: Do not include gdb_locale.h.
7294
7295 2014-08-07 Gary Benson <gbenson@redhat.com>
7296
7297 * server.h: Do not include gdb/signals.h.
7298 * win32-low.c: Likewise.
7299
7300 2014-08-07 Gary Benson <gbenson@redhat.com>
7301
7302 * server.h: Do not include pathmax.h.
7303
7304 2014-08-07 Gary Benson <gbenson@redhat.com>
7305
7306 * server.h: Do not include libiberty.h.
7307 * linux-bfin-low.c: Likewise.
7308
7309 2014-08-07 Gary Benson <gbenson@redhat.com>
7310
7311 * server.h: Do not include ansidecl.h.
7312
7313 2014-08-07 Gary Benson <gbenson@redhat.com>
7314
7315 * linux-x86-low.c: Do not include stddef.h.
7316 * lynx-ppc-low.c: Likewise.
7317 * tracepoint.c: Likewise.
7318
7319 2014-08-07 Gary Benson <gbenson@redhat.com>
7320
7321 * server.h: Do not include stdarg.h.
7322 * nto-low.c: Likewise.
7323
7324 2014-08-07 Gary Benson <gbenson@redhat.com>
7325
7326 * server.h: Do not include stdlib.h.
7327 * inferiors.c: Likewise.
7328 * linux-low.c: Likewise.
7329 * regcache.c: Likewise.
7330 * spu-low.c: Likewise.
7331 * tracepoint.c: Likewise.
7332 * utils.c: Likewise.
7333
7334 2014-08-07 Gary Benson <gbenson@redhat.com>
7335
7336 * server.h: Do not include stdio.h.
7337 * linux-low.c: Likewise.
7338 * remote-utils.c: Likewise.
7339 * spu-low.c: Likewise.
7340 * utils.c: Likewise.
7341 * wincecompat.c: Likewise.
7342
7343 2014-08-06 Gary Benson <gbenson@redhat.com>
7344
7345 * regcache.c (init_register_cache): Move conditionals inside if.
7346
7347 2014-08-06 Gary Benson <gbenson@redhat.com>
7348
7349 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7350
7351 2014-07-31 Gary Benson <gbenson@redhat.com>
7352
7353 * ax.h: Do not include server.h.
7354 * gdbthread.h: Likewise.
7355 * lynx-low.h: Likewise.
7356 * notif.h: Likewise.
7357
7358 2014-07-30 Gary Benson <gbenson@redhat.com>
7359
7360 * server.h: Include common-defs.h.
7361 Do not include config.h or build-gnulib-gdbserver/config.h.
7362
7363 2014-07-30 Gary Benson <gbenson@redhat.com>
7364
7365 * hostio-errno.c: Move server.h to top of includes list.
7366 * inferiors.c: Likewise.
7367 * linux-x86-low.c: Likewise.
7368 * notif.c: Include server.h.
7369
7370 2014-07-24 Tom Tromey <tromey@redhat.com>
7371 Gary Benson <gbenson@redhat.com>
7372
7373 * server.h (CORE_ADDR): Now unsigned.
7374
7375 2014-07-16 Pedro Alves <palves@redhat.com>
7376
7377 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7378
7379 2014-07-15 Pedro Alves <palves@redhat.com>
7380
7381 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7382 copy.
7383
7384 2014-07-11 Pedro Alves <palves@redhat.com>
7385
7386 * linux-low.c (kill_wait_lwp): New function, based on
7387 kill_one_lwp_callback, but use my_waitpid directly.
7388 (kill_one_lwp_callback, linux_kill): Use it.
7389
7390 2014-06-23 Pedro Alves <palves@redhat.com>
7391
7392 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7393 before setting DR0..DR3.
7394
7395 2014-06-20 Gary Benson <gbenson@redhat.com>
7396
7397 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7398 * configure: Regenerated.
7399 * config.in: Likewise.
7400
7401 2014-06-20 Gary Benson <gbenson@redhat.com>
7402
7403 * Makefile.in (SFILES): Update locations for files moved
7404 from common to nat.
7405 (object file files): Reordered.
7406
7407 2014-06-20 Gary Benson <gbenson@redhat.com>
7408
7409 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7410 (i386_dr_low_set_addr): Likewise.
7411 (i386_dr_low_get_addr): Likewise.
7412 (i386_dr_low_can_set_control): Likewise.
7413 (i386_dr_low_set_control): Likewise.
7414 (i386_dr_low_get_control): Likewise.
7415 (i386_dr_low_get_status): Likewise.
7416 (i386_get_debug_register_length): Likewise.
7417 * linux-x86-low.c (i386_dr_low_set_addr):
7418 Changed signature. Made static.
7419 (i386_dr_low_get_addr): Likewise.
7420 (i386_dr_low_set_control): Likewise.
7421 (i386_dr_low_get_control): Likewise.
7422 (i386_dr_low_get_status): Likewise.
7423 (i386_dr_low): New global variable.
7424 * win32-i386-low.c (i386_dr_low_set_addr):
7425 Changed signature. Made static.
7426 (i386_dr_low_get_addr): Likewise.
7427 (i386_dr_low_set_control): Likewise.
7428 (i386_dr_low_get_control): Likewise.
7429 (i386_dr_low_get_status): Likewise.
7430 (i386_dr_low): New global variable.
7431
7432 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7433
7434 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7435 * Makefile.in (AR, AR_FLAGS): Define.
7436 * configure: Regenerate.
7437
7438 2014-06-19 Gary Benson <gbenson@redhat.com>
7439
7440 * Makefile.in (i386-dregs.o): New rule.
7441 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7442 * i386-low.c (target.h): Remove include.
7443 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7444 (DR_CONTROL_SHIFT): Likewise.
7445 (DR_CONTROL_SIZE): Likewise.
7446 (DR_RW_EXECUTE): Likewise.
7447 (DR_RW_WRITE): Likewise.
7448 (DR_RW_READ): Likewise.
7449 (DR_RW_IORW): Likewise.
7450 (DR_LEN_1): Likewise.
7451 (DR_LEN_2): Likewise.
7452 (DR_LEN_4): Likewise.
7453 (DR_LEN_8): Likewise.
7454 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7455 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7456 (DR_ENABLE_SIZE): Likewise.
7457 (DR_LOCAL_SLOWDOWN): Likewise.
7458 (DR_GLOBAL_SLOWDOWN): Likewise.
7459 (DR_CONTROL_RESERVED): Likewise.
7460 (I386_DR_CONTROL_MASK): Likewise.
7461 (I386_DR_VACANT): Likewise.
7462 (I386_DR_LOCAL_ENABLE): Likewise.
7463 (I386_DR_GLOBAL_ENABLE): Likewise.
7464 (I386_DR_DISABLE): Likewise.
7465 (I386_DR_SET_RW_LEN): Likewise.
7466 (I386_DR_GET_RW_LEN): Likewise.
7467 (I386_DR_WATCH_HIT): Likewise.
7468 (i386_wp_op_t): Likewise.
7469 (i386_show_dr): Likewise.
7470 (i386_length_and_rw_bits): Likewise.
7471 (i386_insert_aligned_watchpoint): Likewise.
7472 (i386_remove_aligned_watchpoint): Likewise.
7473 (i386_handle_nonaligned_watchpoint): Likewise.
7474 i386_update_inferior_debug_regs(): Likewise.
7475 (i386_dr_insert_watchpoint): Likewise.
7476 (i386_dr_remove_watchpoint): Likewise.
7477 (i386_dr_region_ok_for_watchpoint): Likewise.
7478 (i386_dr_stopped_data_address): Likewise.
7479 (i386_dr_stopped_by_watchpoint): Likewise.
7480
7481 2014-06-19 Gary Benson <gbenson@redhat.com>
7482
7483 * i386-low.c (i386_dr_show): Renamed to
7484 i386_show_dr and made static. All uses updated.
7485 (i386_dr_length_and_rw_bits): Renamed to
7486 i386_length_and_rw_bits and made static.
7487 All uses updated.
7488 (i386_dr_insert_aligned_watchpoint): Renamed to
7489 i386_insert_aligned_watchpoint and made static.
7490 All uses updated.
7491 (i386_dr_remove_aligned_watchpoint): Renamed to
7492 i386_remove_aligned_watchpoint and made static.
7493 All uses updated.
7494 (i386_dr_update_inferior_debug_regs): Renamed to
7495 i386_update_inferior_debug_regs and made static.
7496 All uses updated.
7497
7498 2014-06-18 Gary Benson <gbenson@redhat.com>
7499
7500 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7501 (i386_dr_low_can_set_control): Likewise.
7502 (i386_get_debug_register_length): Likewise.
7503 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7504 (i386_dr_low_can_set_control): Likewise.
7505 (i386_get_debug_register_length): Likewise.
7506
7507 2014-06-17 Gary Benson <gbenson@redhat.com>
7508
7509 * i386-low.h (i386-dregs.h): New include.
7510 (DR_FIRSTADDR): Now in i386-dregs.h.
7511 (DR_LASTADDR): Likewise.
7512 (DR_NADDR): Likewise.
7513 (DR_STATUS): Likewise.
7514 (DR_CONTROL): Likewise.
7515 (i386_debug_reg_state): Likewise.
7516 (i386_dr_insert_watchpoint): Likewise.
7517 (i386_dr_remove_watchpoint): Likewise.
7518 (i386_dr_region_ok_for_watchpoint): Likewise.
7519 (i386_dr_stopped_data_address): Likewise.
7520 (i386_dr_stopped_by_watchpoint): Likewise.
7521 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7522
7523 2014-06-18 Gary Benson <gbenson@redhat.com>
7524
7525 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7526 i386_dr_insert_watchpoint.
7527 (i386_low_remove_watchpoint): Renamed to
7528 i386_dr_remove_watchpoint.
7529 (i386_low_region_ok_for_watchpoint): Renamed to
7530 i386_dr_region_ok_for_watchpoint.
7531 (i386_low_stopped_data_address): Renamed to
7532 i386_dr_stopped_data_address.
7533 (i386_low_stopped_by_watchpoint): Renamed to
7534 i386_dr_stopped_by_watchpoint.
7535 * i386-low.c (i386_show_dr): Renamed to
7536 i386_dr_show and made nonstatic. All uses updated.
7537 (i386_length_and_rw_bits): Renamed to
7538 i386_dr_length_and_rw_bits and made nonstatic.
7539 All uses updated.
7540 (i386_insert_aligned_watchpoint): Renamed to
7541 i386_dr_insert_aligned_watchpoint and made nonstatic.
7542 All uses updated.
7543 (i386_remove_aligned_watchpoint): Renamed to
7544 i386_dr_remove_aligned_watchpoint and made nonstatic.
7545 All uses updated.
7546 (i386_update_inferior_debug_regs): Renamed to
7547 i386_dr_update_inferior_debug_regs and made nonstatic.
7548 All uses updated.
7549 (i386_low_insert_watchpoint): Renamed to
7550 i386_dr_insert_watchpoint. All uses updated.
7551 (i386_low_remove_watchpoint): Renamed to
7552 i386_dr_remove_watchpoint. All uses updated.
7553 (i386_low_region_ok_for_watchpoint): Renamed to
7554 i386_dr_region_ok_for_watchpoint. All uses updated.
7555 (i386_low_stopped_data_address): Renamed to
7556 i386_dr_stopped_data_address. All uses updated.
7557 (i386_low_stopped_by_watchpoint): Renamed to
7558 i386_dr_stopped_by_watchpoint. All uses updated.
7559
7560 2014-06-18 Gary Benson <gbenson@redhat.com>
7561
7562 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7563 (i386_dr_low_can_set_control): Likewise.
7564 (i386_insert_aligned_watchpoint): New check.
7565
7566 2014-06-18 Gary Benson <gbenson@redhat.com>
7567
7568 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
7569 Renamed to state.
7570
7571 2014-06-18 Gary Benson <gbenson@redhat.com>
7572
7573 * i386-low.c (i386_length_and_rw_bits): Use internal_error
7574 instead of fatal and error.
7575 (i386_handle_nonaligned_watchpoint): Likewise.
7576
7577 2014-06-18 Gary Benson <gbenson@redhat.com>
7578
7579 * i386-low.c (i386_get_debug_register_length): New macro.
7580 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
7581 (i386_show_dr): Use debug_printf instead of fprintf. Use
7582 phex to format values.
7583
7584 2014-06-18 Gary Benson <gbenson@redhat.com>
7585
7586 * i386-low.h: Comment changes.
7587 * i386-low.c: Likewise.
7588
7589 2014-06-18 Gary Benson <gbenson@redhat.com>
7590
7591 * i386-low.c: Whitespace changes.
7592
7593 2014-06-12 Tom Tromey <tromey@redhat.com>
7594
7595 * utils.c (freeargv): Remove.
7596
7597 2014-06-12 Tom Tromey <tromey@redhat.com>
7598
7599 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
7600 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
7601 (parse_debug_format_options): Likewise.
7602 (gdbserver_usage): Likewise.
7603 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
7604 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
7605 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
7606 against libiberty.
7607 ($(LIBGNU)): Depend on libiberty.
7608 (all-lib): Recurse into all subdirs.
7609 (install-only): Invoke "install" target in subdirs.
7610 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
7611 targets.
7612 * configure: Rebuild.
7613 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
7614 for vasprintf, vsnprintf, or gettimeofday.
7615 * configure.srv: Don't add safe-ctype.o or lbasename.o to
7616 srv_tgtobj.
7617
7618 2014-06-05 Joel Brobecker <brobecker@adacore.com>
7619
7620 * development.sh: Delete.
7621 * Makefile.in (config.status): Adjust dependency on development.sh.
7622 * configure.ac: Adjust development.sh source call.
7623 * configure: Regenerate.
7624
7625 2014-06-02 Pedro Alves <palves@redhat.com>
7626
7627 * ax.c (gdb_free_agent_expr): New function.
7628 * ax.h (gdb_free_agent_expr): New declaration.
7629 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
7630 list.
7631 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
7632 static.
7633 (clear_breakpoint_conditions_and_commands): New function.
7634 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
7635 (clear_breakpoint_conditions_and_commands): New declaration.
7636
7637 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
7638
7639 * linux-aarch64-low.c (asm/ptrace.h): Include.
7640
7641 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
7642
7643 Fix TLS access for -static -pthread.
7644 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
7645 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
7646 (thread_db_load_search, try_thread_db_load_1): Initialize it.
7647
7648 2014-05-20 Pedro Alves <palves@redhat.com>
7649
7650 * linux-aarch64-low.c (aarch64_insert_point)
7651 (aarch64_remove_point): No longer check whether the type is
7652 supported here. Adjust to new interface.
7653 (the_low_target): Install aarch64_supports_z_point_type as
7654 supports_z_point_type method.
7655 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
7656 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
7657 instead of a Z packet char. Adjust.
7658 (arm_supports_z_point_type): New function.
7659 (arm_insert_point, arm_remove_point): Adjust to new interface.
7660 (the_low_target): Install arm_supports_z_point_type.
7661 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
7662 (cris_insert_point, cris_remove_point): Adjust to new interface.
7663 Don't check whether the type is supported here.
7664 (the_low_target): Install cris_supports_z_point_type.
7665 * linux-low.c (linux_supports_z_point_type): New function.
7666 (linux_insert_point, linux_remove_point): Adjust to new interface.
7667 * linux-low.h (struct linux_target_ops) <insert_point,
7668 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
7669 raw_breakpoint pointer parameter.
7670 <supports_z_point_type>: New method.
7671 * linux-mips-low.c (mips_supports_z_point_type): New function.
7672 (mips_insert_point, mips_remove_point): Adjust to new interface.
7673 Use mips_supports_z_point_type.
7674 (the_low_target): Install mips_supports_z_point_type.
7675 * linux-ppc-low.c (the_low_target): Install NULL as
7676 supports_z_point_type method.
7677 * linux-s390-low.c (the_low_target): Install NULL as
7678 supports_z_point_type method.
7679 * linux-sparc-low.c (the_low_target): Install NULL as
7680 supports_z_point_type method.
7681 * linux-x86-low.c (x86_supports_z_point_type): New function.
7682 (x86_insert_point): Adjust to new insert_point interface. Use
7683 insert_memory_breakpoint. Adjust to new
7684 i386_low_insert_watchpoint interface.
7685 (x86_remove_point): Adjust to remove_point interface. Use
7686 remove_memory_breakpoint. Adjust to new
7687 i386_low_remove_watchpoint interface.
7688 (the_low_target): Install x86_supports_z_point_type.
7689 * lynx-low.c (lynx_target_ops): Install NULL as
7690 supports_z_point_type callback.
7691 * nto-low.c (nto_supports_z_point_type): New.
7692 (nto_insert_point, nto_remove_point): Adjust to new interface.
7693 (nto_target_ops): Install nto_supports_z_point_type.
7694 * mem-break.c: Adjust intro comment.
7695 (struct raw_breakpoint) <raw_type, size>: New fields.
7696 <inserted>: Update comment.
7697 <shlib_disabled>: Delete field.
7698 (enum bkpt_type) <gdb_breakpoint>: Delete value.
7699 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
7700 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
7701 (raw_bkpt_type_to_target_hw_bp_type): New function.
7702 (find_enabled_raw_code_breakpoint_at): New function.
7703 (find_raw_breakpoint_at): New type and size parameters. Use them.
7704 (insert_memory_breakpoint): New function, based off
7705 set_raw_breakpoint_at.
7706 (remove_memory_breakpoint): New function.
7707 (set_raw_breakpoint_at): Reimplement.
7708 (set_breakpoint): New, based on set_breakpoint_at.
7709 (set_breakpoint_at): Reimplement.
7710 (delete_raw_breakpoint): Go through the_target->remove_point
7711 instead of assuming memory breakpoints.
7712 (find_gdb_breakpoint_at): Delete.
7713 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
7714 (find_gdb_breakpoint): New function.
7715 (set_gdb_breakpoint_at): Delete.
7716 (z_type_supported): New function.
7717 (set_gdb_breakpoint_1): New function, loosely based off
7718 set_gdb_breakpoint_at.
7719 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
7720 (delete_gdb_breakpoint_at): Delete.
7721 (delete_gdb_breakpoint_1): New function, loosely based off
7722 delete_gdb_breakpoint_at.
7723 (delete_gdb_breakpoint): New function.
7724 (clear_gdb_breakpoint_conditions): Rename to ...
7725 (clear_breakpoint_conditions): ... this. Don't handle a NULL
7726 breakpoint.
7727 (add_condition_to_breakpoint): Make static.
7728 (add_breakpoint_condition): Take a struct breakpoint pointer
7729 instead of an address. Adjust.
7730 (gdb_condition_true_at_breakpoint): Rename to ...
7731 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
7732 z_type parameter.
7733 (gdb_condition_true_at_breakpoint): Reimplement.
7734 (add_breakpoint_commands): Take a struct breakpoint pointer
7735 instead of an address. Adjust.
7736 (gdb_no_commands_at_breakpoint): Rename to ...
7737 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
7738 parameter. Return true if no breakpoint was found. Change debug
7739 output.
7740 (gdb_no_commands_at_breakpoint): Reimplement.
7741 (run_breakpoint_commands): Rename to ...
7742 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
7743 and change return type to boolean.
7744 (run_breakpoint_commands): New function.
7745 (gdb_breakpoint_here): Also check for Z1 breakpoints.
7746 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
7747 breakpoint. Go through the_target->remove_point instead of
7748 assuming memory breakpoint.
7749 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
7750 software and hardware breakpoints.
7751 (reinsert_raw_breakpoint): Go through the_target->insert_point
7752 instead of assuming memory breakpoint.
7753 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
7754 software and hardware breakpoints.
7755 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
7756 Check both software and hardware breakpoints.
7757 (validate_inserted_breakpoint): Assert the breakpoint is a
7758 software breakpoint. Set the inserted flag to -1 instead of
7759 setting shlib_disabled.
7760 (delete_disabled_breakpoints): Adjust.
7761 (validate_breakpoints): Only validate software breakpoints.
7762 Adjust to inserted flag change.
7763 (check_mem_read, check_mem_write): Skip breakpoint types other
7764 than software breakpoints. Adjust to inserted flag change.
7765 * mem-break.h (enum raw_bkpt_type): New enum.
7766 (raw_breakpoint, struct process_info): Forward declare.
7767 (Z_packet_to_target_hw_bp_type): Delete declaration.
7768 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
7769 (set_gdb_breakpoint, delete_gdb_breakpoint)
7770 (clear_breakpoint_conditions): New declarations.
7771 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
7772 (breakpoint_inserted_here): Update comment.
7773 (add_breakpoint_condition, add_breakpoint_commands): Replace
7774 address parameter with a breakpoint pointer parameter.
7775 (gdb_breakpoint_here): Update comment.
7776 (delete_gdb_breakpoint_at): Delete.
7777 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
7778 * server.c (process_point_options): Take a struct breakpoint
7779 pointer instead of an address. Adjust.
7780 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
7781 delete_gdb_breakpoint.
7782 * spu-low.c (spu_target_ops): Install NULL as
7783 supports_z_point_type method.
7784 * target.h: Include mem-break.h.
7785 (struct target_ops) <prepare_to_access_memory>: Update comment.
7786 <supports_z_point_type>: New field.
7787 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7788 instead of a char. Also take a raw breakpoint pointer.
7789 * win32-arm-low.c (the_low_target): Install NULL as
7790 supports_z_point_type.
7791 * win32-i386-low.c (i386_supports_z_point_type): New function.
7792 (i386_insert_point, i386_remove_point): Adjust to new interface.
7793 (the_low_target): Install i386_supports_z_point_type.
7794 * win32-low.c (win32_supports_z_point_type): New function.
7795 (win32_insert_point, win32_remove_point): Adjust to new interface.
7796 (win32_target_ops): Install win32_supports_z_point_type.
7797 * win32-low.h (struct win32_target_ops):
7798 <supports_z_point_type>: New method.
7799 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
7800 instead of a char. Also take a raw breakpoint pointer.
7801
7802 2014-05-20 Pedro Alves <palves@redhat.com>
7803
7804 * mem-break.h: Include break-common.h.
7805 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7806 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
7807 (Z_packet_to_target_hw_bp_type): New declaration.
7808 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
7809 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
7810 (Z_PACKET_ACCESS_WP): Delete macros.
7811 (Z_packet_to_hw_type): Delete function.
7812 * i386-low.h: Don't include break-common.h here.
7813 (Z_packet_to_hw_type): Delete declaration.
7814 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
7815 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7816 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
7817 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
7818 * linux-aarch64-low.c: Don't include break-common.h here.
7819 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
7820 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
7821 (Z_packet_to_target_hw_bp_type): Delete function.
7822 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
7823 function.
7824 (mips_insert_point, mips_remove_point): Use
7825 Z_packet_to_target_hw_bp_type.
7826
7827 2014-05-20 Pedro Alves <palves@redhat.com>
7828
7829 * linux-aarch64-low.c: Include break-common.h.
7830 (enum target_point_type): Delete.
7831 (Z_packet_to_point_type): Rename to ...
7832 (Z_packet_to_target_hw_bp_type): ... this, and return a
7833 target_hw_bp_type instead.
7834 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
7835 instead of an enum target_point_type.
7836 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
7837 breakpoint type.
7838 (aarch64_dr_state_insert_one_point)
7839 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
7840 (aarch64_handle_aligned_watchpoint)
7841 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
7842 Take an enum target_hw_bp_type instead of an enum
7843 target_point_type.
7844 (aarch64_supports_z_point_type): New function.
7845 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
7846 use Z_packet_to_target_hw_bp_type.
7847
7848 2014-05-20 Joel Brobecker <brobecker@adacore.com>
7849
7850 * configure.ac: Only use -Werror by default when DEVELOPMENT
7851 is true.
7852 * configure: Regenerate.
7853
7854 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
7855
7856 Fix gdbserver qGetTLSAddr for x86_64 -m32.
7857 * linux-x86-low.c (X86_64_USER_REGS): New.
7858 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
7859
7860 2014-04-28 Yao Qi <yao@codesourcery.com>
7861
7862 * Makefile.in (i386-avx512.c): Fix the typo of generated file
7863 name.
7864
7865 2014-04-25 Pedro Alves <palves@redhat.com>
7866
7867 PR server/16255
7868 * linux-low.c (linux_attach_fail_reason_string): New function.
7869 (linux_attach_lwp): Delete.
7870 (linux_attach_lwp_1): Rename to ...
7871 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
7872 argument. Remove "initial" parameter. Return int instead of
7873 void. Don't error or warn here.
7874 (linux_attach): Adjust to call linux_attach_lwp. Call error on
7875 failure to attach to the tgid. Call warning when failing to
7876 attach to an lwp.
7877 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
7878 argument. Remove "initial" parameter. Return int instead of
7879 void. Don't error or warn here.
7880 (linux_attach_fail_reason_string): New declaration.
7881 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
7882 interface change. Use linux_attach_fail_reason_string.
7883
7884 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
7885 Walfred Tedeschi <walfred.tedeschi@intel.com>
7886
7887 * Makefile.in: Added rules to handle new files
7888 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
7889 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
7890 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
7891 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
7892 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
7893 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
7894 x32-avx512-linux.o.
7895 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
7896 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
7897 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
7898 i386/x32-avx512.xml.
7899 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
7900 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
7901 i386/x32-avx512-linux.xml.
7902 * i387-fp.c (num_avx512_k_registers): New constant for number
7903 of K registers.
7904 (num_avx512_zmmh_low_registers): New constant for number of
7905 lower ZMM registers (0-15).
7906 (num_avx512_zmmh_high_registers): New constant for number of
7907 higher ZMM registers (16-31).
7908 (num_avx512_ymmh_registers): New contant for number of higher
7909 YMM registers (ymm16-31 added by avx521 on x86_64).
7910 (num_avx512_xmm_registers): New constant for number of higher
7911 XMM registers (xmm16-31 added by AVX512 on x86_64).
7912 (struct i387_xsave): Add space for AVX512 registers.
7913 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
7914 Add code to handle AVX512 registers.
7915 (i387_xsave_to_cache): Add code to handle AVX512 registers.
7916 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
7917 prototypei from generated file.
7918 (tdesc_amd64_avx512_linux): Likewise.
7919 (init_registers_x32_avx512_linux): Likewise.
7920 (tdesc_x32_avx512_linux): Likewise.
7921 (init_registers_i386_avx512_linux): Likewise.
7922 (tdesc_i386_avx512_linux): Likewise.
7923 (x86_64_regmap): Add AVX512 registers.
7924 (x86_linux_read_description): Add code to handle AVX512 XSTATE
7925 mask.
7926 (initialize_low_arch): Add code to initialize AVX512 registers.
7927
7928 2014-04-23 Pedro Alves <palves@redhat.com>
7929
7930 * mem-break.c (find_gdb_breakpoint_at): Make static.
7931 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
7932
7933 2014-04-23 Pedro Alves <palves@redhat.com>
7934
7935 * i386-low.c: Don't include break-common.h here.
7936 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7937 prototype to take target_hw_bp_type as argument instead of a Z
7938 packet char.
7939 * i386-low.h: Include break-common.h here.
7940 (Z_packet_to_hw_type): Declare.
7941 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
7942 prototypes.
7943 * linux-x86-low.c (x86_insert_point): Convert the packet number to
7944 a target_hw_bp_type before calling i386_low_insert_watchpoint.
7945 (x86_remove_point): Convert the packet number to a
7946 target_hw_bp_type before calling i386_low_remove_watchpoint.
7947 * win32-i386-low.c (i386_insert_point): Convert the packet number
7948 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
7949 (i386_remove_point): Convert the packet number to a
7950 target_hw_bp_type before calling i386_low_remove_watchpoint.
7951
7952 2014-04-23 Pedro Alves <palves@redhat.com>
7953
7954 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
7955
7956 2014-04-10 Pedro Alves <palves@redhat.com>
7957
7958 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
7959 Check if the condition or command is NULL before checking if the
7960 breakpoint is known. On success, return true.
7961 * mem-break.h (add_breakpoint_condition): Document return.
7962 (add_breakpoint_commands): Add describing comment.
7963 * server.c (skip_to_semicolon): New function.
7964 (process_point_options): Use it.
7965
7966 2014-04-09 Pedro Alves <palves@redhat.com>
7967
7968 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
7969 to lwpid_of.
7970
7971 2014-02-27 Pedro Alves <palves@redhat.com>
7972
7973 PR 12702
7974 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
7975 macros.
7976 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
7977 output.
7978 (last_thread_of_process_p): Take a PID argument instead of a
7979 thread pointer.
7980 (linux_wait_for_lwp): Delete.
7981 (num_lwps, check_zombie_leaders, not_stopped_callback): New
7982 functions.
7983 (linux_low_filter_event): New function, party factored out from
7984 linux_wait_for_event.
7985 (linux_wait_for_event): Rename to ...
7986 (linux_wait_for_event_filtered): ... this. Add new filter ptid
7987 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
7988 sigsuspend. Check for zombie leaders.
7989 (linux_wait_for_event): Reimplement as wrapper around
7990 linux_wait_for_event_filtered.
7991 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
7992 a normal or signal exit is seen, it's the whole process exiting.
7993 (wait_for_sigstop): No longer a for_each_inferior callback.
7994 Rewrite on top of linux_wait_for_event_filtered.
7995 (stop_all_lwps): Call wait_for_sigstop directly.
7996 * server.c (resume, handle_target_event): Handle
7997 TARGET_WAITKIND_NO_RESUMED.
7998
7999 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8000
8001 * win32-low.c (psapi_get_dll_name,
8002 * win32_CreateToolhelp32Snapshot): Delete.
8003 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8004 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8005 Delete.
8006 (handle_load_dll): Add function description.
8007 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8008
8009 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8010
8011 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8012 Add comment.
8013 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8014 base address when calling win32_add_one_solib.
8015 (handle_load_dll): Delete local variable load_addr.
8016 Remove 0x1000 offset applied to DLL base address when calling
8017 win32_add_one_solib.
8018 (handle_unload_dll): Add comment.
8019
8020 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8021
8022 * win32-low.c (win32_add_all_dlls): Renames
8023 win32_ensure_ntdll_loaded. Rewrite function documentation.
8024 Adjust implementation to always load all DLLs.
8025 Add 0x1000 offset to DLL base address when calling
8026 win32_add_one_solib.
8027 (child_initialization_done): New static global.
8028 (do_initial_child_stuff): Set child_initialization_done to
8029 zero during child initialization, and 1 after. Replace call
8030 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8031 Add comment.
8032 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8033 (handle_unload_dll): Add function documentation.
8034 (get_child_debug_event): Ignore load and unload DLL events
8035 during child initialization.
8036
8037 2014-02-20 Doug Evans <dje@google.com>
8038
8039 Remove global all_lwps.
8040 * inferiors.h (ptid_of): Move here from linux-low.h.
8041 (pid_of, lwpid_of): Ditto.
8042 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8043 parameter is a struct thread_info * now.
8044 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8045 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8046 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8047 directly.
8048 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8049 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8050 * linux-arm-low.c (update_registers_callback): Update, "entry"
8051 parameter is a struct thread_info * now.
8052 Fetch lwpid from current_inferior directly.
8053 (arm_insert_point): Pass &all_threads to find_inferior instead of
8054 &all_lwps.
8055 (arm_remove_point): Ditto.
8056 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8057 (arm_prepare_to_resume): Fetch pid from thread.
8058 (arm_read_description): Fetch lwpid from current_inferior directly.
8059 * linux-low.c (all_lwps): Delete.
8060 (delete_lwp): Delete call to remove_inferior.
8061 (handle_extended_wait): Fetch lwpid from thread.
8062 (add_lwp): Don't set lwp->entry.id. Remove call to
8063 add_inferior_to_list.
8064 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8065 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8066 (kill_one_lwp_callback): Ditto.
8067 (linux_kill): Don't dereference NULL pointer.
8068 Fetch ptid,lwpid from thread.
8069 (get_detach_signal): Fetch ptid from thread.
8070 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8071 Simplify call to regcache_invalidate_thread.
8072 (delete_lwp_callback): Update, "entry" parameter is a
8073 struct thread_info * now. Fetch pid from thread.
8074 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8075 (status_pending_p_callback): Update, "entry" parameter is a
8076 struct thread_info * now. Fetch ptid from thread.
8077 (find_lwp_pid): Update, "entry" parameter is a
8078 struct thread_info * now.
8079 (linux_wait_for_lwp): Fetch pid from thread.
8080 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8081 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8082 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8083 (dequeue_one_deferred_signal): Ditto.
8084 (cancel_breakpoint): Fetch ptid from current_inferior.
8085 (linux_wait_for_event): Pass &all_threads to find_inferior,
8086 not &all_lwps. Fetch ptid, lwpid from thread.
8087 (count_events_callback): Update, "entry" parameter is a
8088 struct thread_info * now.
8089 (select_singlestep_lwp_callback): Ditto.
8090 (select_event_lwp_callback): Ditto.
8091 (cancel_breakpoints_callback): Ditto.
8092 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8093 not &all_lwps.
8094 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8095 (unsuspend_one_lwp): Update, "entry" parameter is a
8096 struct thread_info * now.
8097 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8098 not &all_lwps.
8099 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8100 Fetch lwpid from thread, not lwp.
8101 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8102 Pass &all_threads to find_inferior, not &all_lwps.
8103 (send_sigstop): Fetch lwpid from thread, not lwp.
8104 (send_sigstop_callback): Update, "entry" parameter is a
8105 struct thread_info * now.
8106 (suspend_and_send_sigstop_callback): Ditto.
8107 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8108 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8109 struct thread_info * now.
8110 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8111 from thread, lwp.
8112 (lwp_running): Update, "entry" parameter is a
8113 struct thread_info * now.
8114 (stop_all_lwps): Fetch ptid from thread.
8115 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8116 (linux_resume_one_lwp): Fetch lwpid from thread.
8117 (linux_set_resume_request): Update, "entry" parameter is a
8118 struct thread_info * now. Fetch pid, lwpid from thread.
8119 (resume_status_pending_p): Update, "entry" parameter is a
8120 struct thread_info * now.
8121 (need_step_over_p): Ditto. Fetch lwpid from thread.
8122 (start_step_over): Fetch lwpid from thread.
8123 (linux_resume_one_thread): Update, "entry" parameter is a
8124 struct thread_info * now. Fetch lwpid from thread.
8125 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8126 (proceed_one_lwp): Update, "entry" parameter is a
8127 struct thread_info * now. Fetch lwpid from thread.
8128 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8129 struct thread_info * now.
8130 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8131 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8132 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8133 directly.
8134 (regsets_store_inferior_registers): Ditto.
8135 (fetch_register, store_register): Ditto.
8136 (linux_read_memory, linux_write_memory): Ditto.
8137 (linux_request_interrupt): Ditto.
8138 (linux_read_auxv): Ditto.
8139 (linux_xfer_siginfo): Ditto.
8140 (linux_qxfer_spu): Ditto.
8141 (linux_qxfer_libraries_svr4): Ditto.
8142 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8143 moved to inferiors.h.
8144 (get_lwp): Delete.
8145 (get_thread_lwp): Update.
8146 (struct lwp_info): Delete member "entry". Simplify comment for
8147 member "thread".
8148 (all_lwps): Delete.
8149 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8150 current_inferior directly.
8151 (update_watch_registers_callback): Update, "entry" parameter is a
8152 struct thread_info * now. Fetch pid from thread.
8153 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8154 (mips_insert_point): Fetch lwpid from current_inferior.
8155 Pass &all_threads to find_inferior, not &all_lwps.
8156 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8157 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8158 directly.
8159 (mips_stopped_data_address): Ditto.
8160 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8161 directly.
8162 * linux-tile-low.c (tile_arch_setup): Ditto.
8163 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8164 (update_debug_registers_callback): Update, "entry" parameter is a
8165 struct thread_info * now. Fetch pid from thread.
8166 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8167 Pass &all_threads to find_inferior, not &all_lwps.
8168 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8169 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8170 Pass &all_threads to find_inferior, not &all_lwps.
8171 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8172 (i386_dr_low_get_status): Ditto.
8173 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8174 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8175 (x86_linux_read_description): Ditto.
8176 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8177
8178 2014-02-20 Doug Evans <dje@google.com>
8179
8180 * inferiors.c (get_first_inferior): Fix buglet.
8181
8182 2014-02-19 Doug Evans <dje@google.com>
8183
8184 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8185 * inferiors.c (add_thread): Change result type to struct thread_info *.
8186 All callers updated.
8187 (add_lwp): Call add_thread here instead of in callers.
8188 All callers updated.
8189 * linux-low.h (get_lwp_thread): Rewrite.
8190 (struct lwp_info): New member "thread".
8191
8192 2014-02-19 Doug Evans <dje@google.com>
8193
8194 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8195 All callers updated.
8196
8197 2014-02-19 Doug Evans <dje@google.com>
8198
8199 * inferiors.c (add_thread): Fix whitespace.
8200
8201 2014-02-19 Doug Evans <dje@google.com>
8202
8203 * dll.c (clear_dlls): Replace accessing list implemention details
8204 with API function.
8205 * gdbthread.h (get_first_thread): Declare.
8206 * inferiors.c (for_each_inferior_with_data): New function.
8207 (get_first_thread): New function.
8208 (find_thread_ptid): Simplify.
8209 (get_first_inferior): New function.
8210 (clear_list): Delete.
8211 (one_inferior_p): New function.
8212 (clear_inferior_list): New function.
8213 (clear_inferiors): Update.
8214 * inferiors.h (for_each_inferior_with_data): Declare.
8215 (clear_inferior_list): Declare.
8216 (one_inferior_p): Declare.
8217 (get_first_inferior): Declare.
8218 * linux-low.c (linux_wait_for_event): Replace accessing list
8219 implemention details with API function.
8220 * server.c (target_running): Ditto.
8221 (accumulate_file_name_length): New function.
8222 (emit_dll_description): New function.
8223 (handle_qxfer_libraries): Replace accessing list implemention
8224 details with API function.
8225 (handle_qxfer_threads_worker): New function.
8226 (handle_qxfer_threads_proper): Replace accessing list implemention
8227 details with API function.
8228 (handle_query): Ditto.
8229 (visit_actioned_threads_callback_ftype): New typedef.
8230 (visit_actioned_threads_data): New struct.
8231 (visit_actioned_threads): Rewrite to be find_inferior callback.
8232 (resume): Call find_inferior.
8233 (handle_status): Replace accessing list implemention
8234 details with API function.
8235 (process_serial_event): Replace accessing list implemention details
8236 with API function.
8237 * target.c (set_desired_inferior): Replace accessing list implemention
8238 details with API function.
8239 * tracepoint.c (same_process_p): New function.
8240 (gdb_agent_about_to_close): Replace accessing list implemention
8241 details with API function.
8242 * win32-low.c (child_delete_thread): Replace accessing list
8243 implemention details with API function.
8244 (match_dll_by_basename): New function.
8245 (dll_is_loaded_by_basename): New function.
8246 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8247 details call to dll_is_loaded_by_basename.
8248
8249 2014-02-19 Doug Evans <dje@google.com>
8250
8251 * dll.h (struct dll_info): Add comment.
8252 * gdbthread.h (struct thread_info): Add comment.
8253 (current_ptid): Simplify.
8254 * inferiors.c (add_process): Update.
8255 (remove_process): Update.
8256 * inferiors.h (struct process_info): Rename member "head" to "entry".
8257 * linux-low.c (delete_lwp): Update.
8258 (add_lwp): Update.
8259 (last_thread_of_process_p): Update.
8260 (kill_one_lwp_callback, linux_kill): Update.
8261 (status_pending_p_callback): Update.
8262 (wait_for_sigstop): Update. Simplify read of ptid.
8263 (start_step_over): Update.
8264 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8265 (get_lwp_thread): Update.
8266 (struct lwp_info): Rename member "head" to "entry".
8267 * regcache.h (inferior_list_entry): Delete.
8268 * server.c (kill_inferior_callback): Update.
8269 (detach_or_kill_inferior_callback): Update.
8270 (print_started_pid): Update.
8271 (print_attached_pid): Update.
8272 (process_serial_event): Simplify read of ptid.
8273 * thread-db.c (thread_db_create_event): Update.
8274 (thread_db_get_tls_address): Update.
8275 * win32-low.c (current_inferior_ptid): Simplify.
8276
8277 2014-02-19 Tom Tromey <tromey@redhat.com>
8278
8279 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8280 argument.
8281 (target_supports_btrace): Update.
8282
8283 2014-02-14 Yao Qi <yao@codesourcery.com>
8284
8285 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8286 (rsp-low-ipa.o): New target.
8287
8288 2014-02-12 Tom Tromey <tromey@redhat.com>
8289
8290 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8291 convert_ascii_to_int.
8292 * regcache.c (registers_to_string): Likewise.
8293 * remote-utils.c (decode_M_packet): Likewise.
8294 * server.c (process_serial_event): Likewise.
8295
8296 2014-02-12 Tom Tromey <tromey@redhat.com>
8297
8298 * server.c (handle_query, handle_v_run): Use hex2bin, not
8299 unhexify.
8300 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8301
8302 2014-02-12 Tom Tromey <tromey@redhat.com>
8303
8304 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8305 convert_int_to_ascii.
8306 * regcache.c (registers_to_string, collect_register_as_string):
8307 Likewise.
8308 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8309 Likewise.
8310 * server.c (process_serial_event): Likewise.
8311 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8312 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8313
8314 2014-02-12 Tom Tromey <tromey@redhat.com>
8315
8316 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8317 bin2hex, not hexify.
8318 * tracepoint.c (cmd_qtstatus): Likewise.
8319
8320 2014-02-12 Tom Tromey <tromey@redhat.com>
8321
8322 * remote-utils.c (monitor_output): Pass explicit length to
8323 hexify.
8324
8325 2014-02-12 Tom Tromey <tromey@redhat.com>
8326
8327 * tracepoint.c: Include rsp-low.h.
8328 * server.c: Include rsp-low.h.
8329 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8330 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8331 declare.
8332 * remote-utils.c: Include rsp-low.h.
8333 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8334 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8335 (convert_int_to_ascii, convert_ascii_to_int): Move to
8336 common/rsp-low.c.
8337 * regcache.c: Include rsp-low.h.
8338 * ax.c: Include rsp-low.h.
8339 * Makefile.in (SFILES): Add common/rsp-low.c.
8340 (OBS): Add rsp-low.o.
8341 (rsp-low.o): New target.
8342
8343 2014-02-12 Tom Tromey <tromey@redhat.com>
8344
8345 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8346 Include print-utils.h.
8347 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8348 (plongest, thirty_two, phex_nz): Remove.
8349 * Makefile.in (SFILES): Add common/print-utils.c.
8350 (OBS): Add print-utils.o.
8351 (print-utils-ipa.o): New target.
8352 (print-utils.o): New target.
8353 (IPA_OBJS): Add print-utils-ipa.o.
8354
8355 2014-02-06 Tom Tromey <tromey@redhat.com>
8356
8357 * Makefile.in (SFILES): Fix indentation.
8358
8359 2014-02-05 Doug Evans <dje@google.com>
8360
8361 * linux-low.c (linux_wait_for_event): Improve comment.
8362 (linux_wait_1): Keep current_inferior in sync with event_child.
8363
8364 2014-01-22 Doug Evans <dje@google.com>
8365
8366 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8367
8368 2014-01-22 Doug Evans <dje@google.com>
8369
8370 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8371 * configure: Regenerate.
8372 * config.in: Regenerate.
8373 * Makefile.in (SFILES): Add debug.c.
8374 (OBS): Add debug.o.
8375 * debug.c: New file.
8376 * debug.h: New file.
8377 * linux-aarch64-low.c (*): Update all debugging printfs to use
8378 debug_printf instead of fprintf.
8379 * linux-arm-low.c (*): Ditto.
8380 * linux-cris-low.c (*): Ditto.
8381 * linux-crisv32-low.c (*): Ditto.
8382 * linux-m32r-low.c (*): Ditto.
8383 * linux-sparc-low.c (*): Ditto.
8384 * linux-x86.c (*): Ditto.
8385 * linux-low.c (*): Ditto.
8386 (linux_wait_1): Add calls to debug_enter, debug_exit.
8387 (linux_wait): Remove redundant debugging printf.
8388 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8389 (linux_resume, unstop_all_lwps): Ditto.
8390 * mem-break.c (*): Update all debugging printfs to use
8391 debug_printf instead of fprintf.
8392 * remote-utils.c (*): Ditto.
8393 * thread-db.c (*): Ditto.
8394 * server.c #include <ctype.h>, "gdb_vecs.h".
8395 (debug_threads): Moved to debug.c.
8396 (*): Update all debugging printfs to use debug_printf instead of
8397 fprintf.
8398 (start_inferior): Replace call to fflush with call to debug_flush.
8399 (monitor_show_help): Mention set debug-format.
8400 (parse_debug_format_options): New function.
8401 (handle_monitor_command): Handle "monitor set debug-format".
8402 (gdbserver_usage): Mention --debug-format.
8403 (main): Parse --debug-format.
8404 * server.h (debug_threads): Declaration moved to debug.h.
8405 #include "debug.h".
8406 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8407 trace_debug_1 that uses debug_printf.
8408 (tracepoint_look_up_symbols): Update all debugging printfs to use
8409 debug_printf instead of fprintf.
8410
8411 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8412
8413 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8414 sys/ptrace.h.
8415
8416 2014-01-17 Pedro Alves <palves@redhat.com>
8417
8418 PR build/16445
8419 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8420 defined after including gdb_proc_service.h.
8421
8422 2014-01-16 Doug Evans <dje@google.com>
8423
8424 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8425 (match_dll): Use it.
8426
8427 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8428
8429 * target.h (target_ops) <read_btrace>: Change parameters and
8430 return type to allow error reporting.
8431 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8432 trace reading errors on.
8433 * linux-low.c (linux_low_read_btrace): Pass trace reading
8434 errors on.
8435 (linux_low_disable_btrace): New.
8436
8437 2014-01-15 Doug Evans <dje@google.com>
8438
8439 * inferiors.c (thread_id_to_gdb_id): Delete.
8440 * inferiors.h (thread_id_to_gdb_id): Delete.
8441
8442 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8443
8444 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8445 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8446 versions.
8447
8448 2014-01-08 Pedro Alves <palves@redhat.com>
8449
8450 * server.c (handle_status): Don't discard previous queued stop
8451 replies or thread's pending status here.
8452 (main) <disconnection>: Do it here instead.
8453
8454 2014-01-08 Pedro Alves <palves@redhat.com>
8455
8456 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8457 * server.c (visit_actioned_threads, handle_pending_status): New
8458 function.
8459 (handle_v_cont): Factor out parts to ...
8460 (resume): ... this new function. If in all-stop, and a thread
8461 being resumed has a pending status, report it without actually
8462 resuming.
8463 (myresume): Adjust to use the new 'resume' function.
8464 (clear_pending_status_callback, set_pending_status_callback)
8465 (find_status_pending_thread_callback): New functions.
8466 (handle_status): Handle the case of multiple threads having
8467 interesting statuses to report. Report threads' real last signal
8468 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8469 with an interesting thread to report the status for, instead of
8470 always reporting the status of the first thread.
8471
8472 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8473
8474 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8475 * gdbreplay.c (gdbreplay_version): Likewise.
8476
8477 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8478
8479 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8480 iov.iov_len with the real length in use.
8481
8482 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8483
8484 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8485 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8486 for all targets that use win32-low.c.
8487 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8488 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8489
8490 2013-12-13 Pedro Alves <palves@redhat.com>
8491
8492 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8493 if equal to TARGET_WAITKIND_LOADED.
8494 * win32-low.c (cached_status): New static global.
8495 (win32_wait): Add declaration.
8496 (do_initial_child_stuff): Flush all initial pending debug events
8497 up to the initial breakpoint.
8498 (win32_wait): If CACHED_STATUS was set, return that instead
8499 of doing a real wait. Remove the code resuming the execution
8500 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8501 during the initial phase. Also remove the code changing
8502 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8503 TARGET_WAITKIND_STOPPED.
8504
8505 2013-12-11 Yao Qi <yao@codesourcery.com>
8506
8507 * notif.c (handle_notif_ack): Return 0 if no notification
8508 matches.
8509
8510 2013-11-20 Doug Evans <dje@google.com>
8511
8512 * linux-low.c (linux_set_resume_request): Fix comment.
8513
8514 2013-11-20 Doug Evans <dje@google.com>
8515
8516 * linux-low.c (resume_status_pending_p): Tweak comment.
8517
8518 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8519
8520 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8521 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8522 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8523 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8524 (srv_amd64_regobj): Add amd64-mpx.o.
8525 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8526 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8527 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8528 * i387-fp.c (num_pl_bnd_register) Added constant.
8529 (num_pl_bnd_cfg_registers) Added constant.
8530 (struct i387_xsave) Added reserved area and MPX fields.
8531 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8532 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8533 function.
8534 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8535 (init_registers_amd64_mpx_linux): Declare new function.
8536 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8537 (x86_64_regmap): Add MPX registers.
8538 (x86_linux_read_description): Add MPX case.
8539 (initialize_low_arch): Initialize MPX targets.
8540
8541 2013-11-18 Tom Tromey <tromey@redhat.com>
8542
8543 * configure: Rebuild.
8544 * configure.ac: Don't check for stdlib.h.
8545 * gdbreplay.c: Unconditionally include stdlib.h.
8546
8547 2013-11-18 Tom Tromey <tromey@redhat.com>
8548
8549 * config.in: Rebuild.
8550 * configure: Rebuild.
8551 * configure.ac: Don't use AC_HEADER_DIRENT.
8552
8553 2013-11-18 Tom Tromey <tromey@redhat.com>
8554
8555 * server.h: Don't check HAVE_STRING_H.
8556 * gdbreplay.c: Don't check HAVE_STRING_H.
8557 * configure: Rebuild.
8558
8559 2013-11-18 Tom Tromey <tromey@redhat.com>
8560
8561 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8562 LIBGNU.
8563
8564 2013-11-08 Tom Tromey <tromey@redhat.com>
8565
8566 * configure, config.in: Rebuild.
8567 * configure.ac: Remove unused configury.
8568
8569 2013-11-08 Tom Tromey <tromey@redhat.com>
8570
8571 * acinclude.m4: Include common.m4, codeset.m4.
8572 * configure, config.in: Rebuild.
8573 * configure.ac: Use GDB_AC_COMMON.
8574
8575 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
8576
8577 * linux-s390-low.c (HWCAP_S390_TE): New define.
8578 (s390_arch_setup): Consider the TE field in the HWCAP for
8579 determining 'have_regset_tdb'.
8580
8581 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
8582
8583 PR gdb/16014
8584 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
8585 call to sizeof.
8586
8587 2013-10-02 Pedro Alves <palves@redhat.com>
8588
8589 * server.c (process_serial_event): Don't output "GDBserver
8590 exiting" if GDB is connected through stdio.
8591 * target.c (mywait): Likewise, be silent if GDB is connected
8592 through stdio.
8593
8594 2013-10-01 Joel Brobecker <brobecker@adacore.com>
8595
8596 * lynx-low.c (lynx_add_threads_after_attach): New function.
8597 (lynx_attach): Remove call to add_thread. Add call to
8598 lynx_add_threads_after_attach instead.
8599
8600 2013-09-28 Mike Frysinger <vapier@gentoo.org>
8601
8602 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
8603 * config.in, configure: Regenerated.
8604
8605 2013-09-18 Yao Qi <yao@codesourcery.com>
8606
8607 PR server/15959
8608 * server.c (start_inferior): Clear 'resume_info'.
8609
8610 2013-09-16 Jiong Wang <jiwang@tilera.com>
8611
8612 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
8613 for each register.
8614
8615 2013-09-16 Jiong Wang <jiwang@tilera.com>
8616
8617 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
8618 linux-tile-low.o to srv_tgtobj.
8619
8620 2013-09-16 Will Newton <will.newton@linaro.org>
8621
8622 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
8623 out regs.
8624
8625 2013-09-06 Pedro Alves <palves@redhat.com>
8626
8627 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
8628 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
8629 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
8630 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
8631 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
8632 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
8633
8634 2013-09-06 Pedro Alves <palves@redhat.com>
8635
8636 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
8637 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
8638
8639 2013-09-06 Pedro Alves <palves@redhat.com>
8640
8641 * linux-amd64-ipa.c: Include tracepoint.h.
8642 * linux-i386-ipa.c: Include tracepoint.h.
8643
8644 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8645
8646 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
8647 (ps_get_thread_area): New function.
8648
8649 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
8650
8651 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
8652 (initialize_low_arch): Call init_registers_crisv32 rather than
8653 init_register_crisv32.
8654
8655 2013-09-05 Pedro Alves <palves@redhat.com>
8656
8657 * server.h (handle_vFile, hostio_last_error_from_errno): Move
8658 to ...
8659 * hostio.h: ... this new file.
8660 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
8661 win32-low.c: Include hostio.h.
8662
8663 2013-09-05 Pedro Alves <palves@redhat.com>
8664
8665 * server.h (gdb_client_data, handler_func, callback_handler_func)
8666 (delete_file_handler, add_file_handler, append_callback_event)
8667 (delete_callback_event, start_event_loop, initialize_event_loop):
8668 Move to event-loop.h and include it.
8669 * event-loop.h: New file.
8670
8671 2013-09-05 Pedro Alves <palves@redhat.com>
8672
8673 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
8674 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
8675 (loaded_dll, unloaded_dll): Move to ...
8676 * dll.h: ... this new file.
8677 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
8678
8679 2013-09-05 Pedro Alves <palves@redhat.com>
8680
8681 * server.h (current_process, get_thread_process, all_processes)
8682 (add_inferior_to_list, for_each_inferior, current_inferior)
8683 (remove_inferior, add_process, remove_process, find_process_pid)
8684 (have_started_inferiors_p, have_attached_inferiors_p)
8685 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
8686 (clear_inferiors, find_inferior, find_inferior_id)
8687 (inferior_target_data, set_inferior_target_data)
8688 (inferior_regcache_data, set_inferior_regcache_data): Move to
8689 inferiors.h, and include it.
8690 * inferiors.h: New file.
8691
8692 2013-09-05 Pedro Alves <palves@redhat.com>
8693
8694 * server.h (struct emit_ops, current_insn_ptr, emit_error):
8695 Move ...
8696 * ax.h: ... here.
8697
8698 2013-09-05 Pedro Alves <palves@redhat.com>
8699
8700 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
8701 tracepoint.h.
8702 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
8703 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
8704 (handle_tracepoint_general_set, handle_tracepoint_query)
8705 (tracepoint_finished_step, tracepoint_was_hit)
8706 (release_while_stepping_state_list, current_traceframe)
8707 (in_readonly_region, traceframe_read_mem)
8708 (fetch_traceframe_registers, traceframe_read_sdata)
8709 (traceframe_read_info, struct fast_tpoint_collect_status)
8710 (fast_tracepoint_collecting, force_unlock_trace_buffer)
8711 (handle_tracepoit_bkpts, initialize_low_tracepoint)
8712 (supply_fast_tracepoint_registers)
8713 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
8714 (ipa_tdesc, claim_trampoline_space)
8715 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
8716 (agent_mem_read, agent_get_trace_state_variable_value)
8717 (agent_set_trace_state_variable_value, agent_tsv_read)
8718 (agent_mem_read_string, get_raw_reg_func_addr)
8719 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
8720 * tracepoint.h: ... this new file.
8721
8722 2013-09-05 Pedro Alves <palves@redhat.com>
8723
8724 * server.h (perror_with_name, error, fatal, warning, paddress)
8725 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
8726 include it.
8727 * utils.h: New file.
8728
8729 2013-09-05 Pedro Alves <palves@redhat.com>
8730
8731 * server.h (remote_debug, noack_mode, transport_is_reliable)
8732 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
8733 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
8734 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
8735 (write_enn, initialize_async_io, enable_async_io)
8736 (disable_async_io, check_remote_input_interrupt_request)
8737 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
8738 (dead_thread_notify, prepare_resume_reply)
8739 (decode_address_to_semicolon, decode_address, decode_m_packet)
8740 (decode_M_packet, decode_X_packet, decode_xfer_write)
8741 (decode_search_memory_packet, unhexify, hexify)
8742 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
8743 (look_up_one_symbol, relocate_instruction)
8744 (monitor_output): Move to remote-utils.h, and include it.
8745 * remote-utils.h: New file.
8746
8747 2013-09-05 Pedro Alves <palves@redhat.com>
8748
8749 * server.h (_): Delete.
8750
8751 2013-09-02 Pedro Alves <palves@redhat.com>
8752
8753 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
8754 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
8755 allocated.
8756 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
8757
8758 2013-09-02 Pierre Muller <muller@sourceware.org>
8759
8760 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
8761 or WriteProcessMemory complete successfully and handle
8762 ERROR_PARTIAL_COPY error.
8763
8764 2013-09-02 Pedro Alves <palves@redhat.com>
8765
8766 * server.c (gdb_read_memory): Return -1 on traceframe memory read
8767 error instead of EIO.
8768
8769 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
8770
8771 PR server/15604
8772 * linux-low.c: Include filestuff.h.
8773 (linux_create_inferior) <pid == 0>: Call close_most_fds.
8774 * lynx-low.c: Include filestuff.h.
8775 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
8776 * server.c: Include filestuff.h.
8777 (main): Call notice_open_fds.
8778 * spu-low.c: Include filestuff.h.
8779 (spu_create_inferior) <pid == 0>: Call close_most_fds.
8780
8781 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
8782
8783 * Makefile.in: Explain why ../target and ../nat are not
8784 listed as include file search paths.
8785 (linux-waitpid.o): New object file rule.
8786 * configure.srv (srv_native_linux_obj): New variable.
8787 Replace all occurrences of linux native object files with
8788 $srv_native_linux_obj.
8789 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
8790 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
8791 (linux_enable_event_reporting): Remove declaration.
8792 (my_waitpid): Moved to common/linux-waitpid.c.
8793 (linux_wait_for_event): Pass ptid when calling
8794 linux_enable_event_reporting.
8795 (linux_supports_tracefork_flag): Remove.
8796 (linux_enable_event_reporting): Likewise.
8797 (linux_tracefork_grandchild): Remove.
8798 (STACK_SIZE): Moved to common/linux-ptrace.c.
8799 (linux_tracefork_child): Remove.
8800 (linux_test_for_tracefork): Remove.
8801 (linux_look_up_symbols): Call linux_supports_traceclone.
8802 (initialize_low): Remove call to linux_test_for_tracefork.
8803 * linux-low.h (PTRACE_TYPE_ARG3): Move to
8804 common/linux-ptrace.h.
8805 (PTRACE_TYPE_ARG4): Likewise.
8806 Include linux-ptrace.h.
8807
8808 2013-08-21 Pedro Alves <palves@redhat.com>
8809
8810 * config.in: Renegerate.
8811
8812 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
8813
8814 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
8815 (SFILES): Remove $(srcdir)/common/target-common.c and
8816 add $(srcdir)/target/waitstatus.c.
8817 (OBS): Remove target-common.o and add waitstatus.o.
8818 (server_h): Remove $(srcdir)/../common/target-common.h and
8819 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
8820 and $(srcdir)/../target/waitstatus.h.
8821 (target-common.o): Remove.
8822 (waitstatus.o): New target object file.
8823 * target.h: Do not include target-common.h and
8824 include target/resume.h, target/wait.h and
8825 target/waitstatus.h.
8826
8827 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
8828
8829 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8830 to PTRACE_TYPE_ARG3.
8831 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
8832 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
8833 PTRACE_TYPE_ARG4.
8834 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
8835 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
8836
8837 2013-07-27 Jie Zhang <jie@codesourcery.com>
8838 Daniel Jacobowitz <dan@codesourcery.com>
8839 Yao Qi <yao@codesourcery.com>
8840
8841 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
8842 (mips-linux-watch.o): New rule.
8843 (mips_linux_watch_h): New variable.
8844 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
8845 srv_tgtobj.
8846 * linux-mips-low.c: Include mips-linux-watch.h.
8847 (struct arch_process_info, struct arch_lwp_info): New.
8848 (update_watch_registers_callback): New function.
8849 (mips_linux_new_process, mips_linux_new_thread) New functions.
8850 (mips_linux_prepare_to_resume, mips_insert_point): New
8851 functions.
8852 (mips_remove_point, mips_stopped_by_watchpoint): New
8853 functions.
8854 (rsp_bp_type_to_target_hw_bp_type): New function.
8855 (mips_stopped_data_address): New function.
8856 (the_low_target): Add watchpoint support functions.
8857
8858 2013-07-27 Yao Qi <yao@codesourcery.com>
8859
8860 * i386-low.c: Include break-common.h.
8861 (enum target_hw_bp_type): Remove.
8862
8863 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
8864
8865 * Makefile.in (SFILES): /common/target-common.c.
8866 (OBS): Add target-common.o.
8867 (server_h): Add $(srcdir)/../common/target-common.h.
8868 (target-common.o): New target.
8869 * server.c (queue_stop_reply_callback): Free
8870 status string after use.
8871 * target.c (target_waitstatus_to_string): Remove.
8872 * target.h: Include target-common.h.
8873 (resume_kind): Likewise.
8874 (target_waitkind): Likewise.
8875 (target_waitstatus): Likewise.
8876 (TARGET_WNOHANG): Likewise.
8877
8878 2013-07-04 Yao Qi <yao@codesourcery.com>
8879
8880 * Makefile.in (host_alias): Use @host_noncanonical@.
8881 (target_alias): Use @target_noncanonical@.
8882 * configure.ac: Use ACX_NONCANONICAL_TARGET and
8883 ACX_NONCANONICAL_HOST.
8884 * configure: Regenerated.
8885
8886 Revert:
8887 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8888
8889 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8890 * configure: Rebuild.
8891 * Makefile.in (version_host, version_target): Get from configure.
8892 (version.c): Use $(version_host) and $(version_target).
8893
8894 2013-07-03 Pedro Alves <palves@redhat.com>
8895
8896 * Makefile.in (config.status): Depend on development.sh.
8897 * acinclude.m4: Include libmcheck.m4.
8898 * configure: Regenerate.
8899
8900 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8901
8902 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
8903 attribute inside the parentheses.
8904 (winapi_DebugSetProcessKillOnExit): Ditto.
8905 (winapi_DebugBreakProcess): Ditto.
8906 (winapi_GenerateConsoleCtrlEvent): Ditto.
8907
8908 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
8909
8910 * notif.h (notif_event): Add a dummy member to avoid compiler
8911 errors.
8912
8913 2013-07-01 Pedro Alves <palves@redhat.com>
8914
8915 * hostio.c (HOSTIO_PATH_MAX): Define.
8916 (require_filename, handle_open, handle_unlink, handle_readlink):
8917 Use it.
8918
8919 2013-07-01 Pedro Alves <palves@redhat.com>
8920
8921 * server.h: Include "pathmax.h".
8922 * linux-low.c: Don't include sys/param.h.
8923 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
8924 MAXPATHLEN.
8925 * win32-low.c: Don't include sys/param.h.
8926 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
8927
8928 2013-07-01 Pedro Alves <palves@redhat.com>
8929
8930 * event-loop.c: Don't check HAVE_UNISTD_H before including
8931 <unistd.h>.
8932 * gdbreplay.c: Likewise.
8933 * remote-utils.c: Likewise.
8934 * server.c: Likewise.
8935 * configure.ac: Don't check for unistd.h.
8936 * configure: Regenerate.
8937
8938 2013-06-28 Tom Tromey <tromey@redhat.com>
8939
8940 * Makefile.in (version.c): Use version.in, not
8941 common/version.in.
8942
8943 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
8944
8945 * configure.ac (version_host, version_target): Set and AC_SUBST them.
8946 * configure: Rebuild.
8947 * Makefile.in (version_host, version_target): Get from configure.
8948 (version.c): Use $(version_host) and $(version_target).
8949
8950 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8951
8952 Fix trace-status to output user name without trailing colon.
8953 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
8954
8955 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
8956
8957 Fix trace-status to output proper start-time and stop-time.
8958 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
8959 output start time and stop time in hex as gdb expects.
8960
8961 2013-06-26 Pedro Alves <pedro@codesourcery.com>
8962
8963 * tracepoint.c (build_traceframe_info_xml): Output trace state
8964 variables present in the trace buffer.
8965
8966 2013-06-24 Tom Tromey <tromey@redhat.com>
8967
8968 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
8969 create-version.sh.
8970 (version.o): Remove.
8971 * gdbreplay.c: Include version.h.
8972 (version, host_name): Don't declare.
8973 * server.h: Include version.h.
8974 (version, host_name): Don't declare.
8975
8976 2013-06-12 Pedro Alves <palves@redhat.com>
8977
8978 * linux-x86-low.c (linux_is_elf64): Delete global.
8979 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
8980 with local linux_pid_exe_is_elf_64_file use.
8981
8982 2013-06-11 Pedro Alves <palves@redhat.com>
8983
8984 * linux-low.c (regset_disabled, disable_regset): New functions.
8985 (regsets_fetch_inferior_registers)
8986 (regsets_store_inferior_registers): Use them.
8987 (initialize_regsets_info); Don't allocate the disabled_regsets
8988 array here.
8989 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
8990 comment.
8991
8992 2013-06-11 Pedro Alves <palves@redhat.com>
8993
8994 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
8995 xmalloc.
8996
8997 2013-06-11 Pedro Alves <palves@redhat.com>
8998
8999 * linux-x86-low.c (initialize_low_arch): Call
9000 init_registers_x32_avx_linux.
9001
9002 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9003
9004 Fix compatibility with Android Bionic.
9005 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9006 it is not empty.
9007
9008 2013-06-07 Pedro Alves <palves@redhat.com>
9009
9010 PR server/14823
9011 * Makefile.in (OBS): Add tdesc.o.
9012 (IPA_OBJS): Add tdesc-ipa.o.
9013 (tdesc-ipa.o): New rule.
9014 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9015 interface.
9016 * linux-low.c (new_inferior): Delete.
9017 (disabled_regsets, num_regsets): Delete.
9018 (linux_add_process): Adjust to set the new per-process
9019 new_inferior flag.
9020 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9021 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9022 was a stop. When calling arch_setup, switch the current inferior
9023 to the thread that got an event.
9024 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9025 (regsets_fetch_inferior_registers)
9026 (regsets_store_inferior_registers): New regsets_info parameter.
9027 Adjust to use it.
9028 (linux_register_in_regsets): New regs_info parameter. Adjust to
9029 use it.
9030 (register_addr, fetch_register, store_register): New usrregs_info
9031 parameter. Adjust to use it.
9032 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9033 parameter regs_info. Adjust to use it.
9034 (linux_fetch_registers): Get the current inferior's regs_info, and
9035 adjust to use it.
9036 (linux_store_registers): Ditto.
9037 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9038 (initialize_low): Don't initialize the target_regsets here. Call
9039 initialize_low_arch.
9040 * linux-low.h (target_regsets): Delete declaration.
9041 (struct regsets_info): New.
9042 (struct usrregs_info): New.
9043 (struct regs_info): New.
9044 (struct process_info_private) <new_inferior>: New field.
9045 (struct linux_target_ops): Delete the num_regs, regmap, and
9046 regset_bitmap fields. New field regs_info.
9047 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9048 * i387-fp.c (num_xmm_registers): Delete.
9049 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9050 calls to new interface.
9051 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9052 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9053 Infer the number of xmm registers from the regcache's target
9054 description.
9055 * i387-fp.h (num_xmm_registers): Delete.
9056 * inferiors.c (add_thread): Don't install the thread's regcache
9057 here.
9058 * proc-service.c (gregset_info): Fetch the current inferior's
9059 regs_info. Adjust to use it.
9060 * regcache.c: Include tdesc.h.
9061 (register_bytes, reg_defs, num_registers)
9062 (gdbserver_expedite_regs): Delete.
9063 (get_thread_regcache): If the thread doesn't have a regcache yet,
9064 create one, instead of aborting gdbserver.
9065 (regcache_invalidate_one): Rename to ...
9066 (regcache_invalidate_thread): ... this.
9067 (regcache_invalidate_one): New.
9068 (regcache_invalidate): Only invalidate registers of the current
9069 process.
9070 (init_register_cache): Add target_desc parameter, and use it.
9071 (new_register_cache): Ditto. Assert the target description has a
9072 non zero registers_size.
9073 (regcache_cpy): Add assertions. Adjust.
9074 (realloc_register_cache, set_register_cache): Delete.
9075 (registers_to_string, registers_from_string): Adjust.
9076 (find_register_by_name, find_regno, find_register_by_number)
9077 (register_cache_size): Add target_desc parameter, and use it.
9078 (free_register_cache_thread, free_register_cache_thread_one)
9079 (regcache_release, register_cache_size): New.
9080 (register_size): Add target_desc parameter, and use it.
9081 (register_data, supply_register, supply_register_zeroed)
9082 (supply_regblock, supply_register_by_name, collect_register)
9083 (collect_register_as_string, collect_register_by_name): Adjust.
9084 * regcache.h (struct target_desc): Forward declare.
9085 (struct regcache) <tdesc>: New field.
9086 (init_register_cache, new_register_cache): Add target_desc
9087 parameter.
9088 (regcache_invalidate_thread): Declare.
9089 (regcache_invalidate_one): Delete declaration.
9090 (regcache_release): Declare.
9091 (find_register_by_number, register_cache_size, register_size)
9092 (find_regno): Add target_desc parameter.
9093 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9094 declarations.
9095 * remote-utils.c: Include tdesc.h.
9096 (outreg, prepare_resume_reply): Adjust.
9097 * server.c: Include tdesc.h.
9098 (gdbserver_xmltarget): Delete declaration.
9099 (get_features_xml, process_serial_event): Adjust.
9100 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9101 declare.
9102 (struct process_info) <tdesc>: New field.
9103 (ipa_tdesc): Declare.
9104 * tdesc.c: New file.
9105 * tdesc.h: New file.
9106 * tracepoint.c: Include tdesc.h.
9107 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9108 (get_context_regcache): Adjust to pass ipa_tdesc down.
9109 (do_action_at_tracepoint): Adjust to get the register cache size
9110 from the context regcache's description.
9111 (traceframe_walk_blocks): Adjust to get the register cache size
9112 from the current trace frame's description.
9113 (traceframe_get_pc): Adjust to get current trace frame's
9114 description and pass it down.
9115 (gdb_collect): Adjust to get the register cache size from the
9116 IPA's description.
9117 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9118 (gdbserver_xmltarget): Delete.
9119 (initialize_low_tracepoint): Set the ipa's target description.
9120 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9121 (initialize_low_tracepoint): Set the ipa's target description.
9122 * linux-x86-low.c: Include tdesc.h.
9123 [__x86_64__] (is_64bit_tdesc): New.
9124 (ps_get_thread_area, x86_get_thread_area): Use it.
9125 (i386_cannot_store_register): Rename to ...
9126 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9127 (i386_cannot_fetch_register): Rename to ...
9128 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9129 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9130 to new interface.
9131 (target_regsets): Rename to ...
9132 (x86_regsets): ... this.
9133 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9134 interface.
9135 (x86_siginfo_fixup): Use is_64bit_tdesc.
9136 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9137 (tdesc_x32_avx_linux, tdesc_x32_linux)
9138 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9139 Declare.
9140 (x86_linux_update_xmltarget): Delete.
9141 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9142 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9143 (AMD64_LINUX_USER64_CS): New.
9144 (x86_linux_read_description): New, based on
9145 x86_linux_update_xmltarget.
9146 (same_process_callback): New.
9147 (x86_arch_setup_process_callback): New.
9148 (x86_linux_update_xmltarget): New.
9149 (x86_regsets_info): New.
9150 (amd64_linux_regs_info): New.
9151 (i386_linux_usrregs_info): New.
9152 (i386_linux_regs_info): New.
9153 (x86_linux_regs_info): New.
9154 (x86_arch_setup): Reimplement.
9155 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9156 (x86_emit_ops): Ditto.
9157 (the_low_target): Adjust. Install x86_linux_regs_info,
9158 x86_cannot_fetch_register, and x86_cannot_store_register.
9159 (initialize_low_arch): New.
9160 * linux-ia64-low.c (tdesc_ia64): Declare.
9161 (ia64_fetch_register): Adjust.
9162 (ia64_usrregs_info, regs_info): New globals.
9163 (ia64_regs_info): New function.
9164 (the_low_target): Adjust.
9165 (initialize_low_arch): New function.
9166 * linux-sparc-low.c (tdesc_sparc64): Declare.
9167 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9168 Adjust.
9169 (sparc_arch_setup): New function.
9170 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9171 (the_low_target): Adjust.
9172 (initialize_low_arch): New function.
9173 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9174 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9175 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9176 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9177 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9178 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9179 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9180 (tdesc_powerpc_isa205_vsx64l): Declare.
9181 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9182 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9183 (ppc_set_pc, ppc_get_hwcap): Adjust.
9184 (ppc_usrregs_info): Forward declare.
9185 (!__powerpc64__) ppc_regmap_adjusted: New global.
9186 (ppc_arch_setup): Adjust to the current process'es target
9187 description.
9188 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9189 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9190 (ppc_store_evrregset): Adjust.
9191 (target_regsets): Rename to ...
9192 (ppc_regsets): ... this, and make static.
9193 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9194 (ppc_regs_info): New function.
9195 (the_low_target): Adjust.
9196 (initialize_low_arch): New function.
9197 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9198 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9199 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9200 (tdesc_s390x_linux64v2): Declare.
9201 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9202 (s390_fill_gregset, s390_store_last_break): Adjust.
9203 (target_regsets): Rename to ...
9204 (s390_regsets): ... this, and make static.
9205 (s390_get_pc, s390_set_pc): Adjust.
9206 (s390_get_hwcap): New target_desc parameter, and use it.
9207 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9208 (s390_arch_setup): Adjust to set the current process'es target
9209 description. Don't adjust the regmap.
9210 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9211 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9212 (regs_info_3264): New globals.
9213 (s390_regs_info): New function.
9214 (the_low_target): Adjust.
9215 (initialize_low_arch): New function.
9216 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9217 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9218 [__mips64] (init_registers_mips_linux)
9219 (init_registers_mips_dsp_linux): Delete defines.
9220 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9221 (have_dsp): New global.
9222 (mips_read_description): New, based on mips_arch_setup.
9223 (mips_arch_setup): Reimplement.
9224 (get_usrregs_info): New function.
9225 (mips_cannot_fetch_register, mips_cannot_store_register)
9226 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9227 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9228 (target_regsets): Rename to ...
9229 (mips_regsets): ... this, and make static.
9230 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9231 (dsp_regs_info, regs_info): New globals.
9232 (mips_regs_info): New function.
9233 (the_low_target): Adjust.
9234 (initialize_low_arch): New function.
9235 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9236 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9237 Declare.
9238 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9239 (arm_read_description): New, with bits factored from
9240 arm_arch_setup.
9241 (arm_arch_setup): Reimplement.
9242 (target_regsets): Rename to ...
9243 (arm_regsets): ... this, and make static.
9244 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9245 (arm_regs_info): New function.
9246 (the_low_target): Adjust.
9247 (initialize_low_arch): New function.
9248 * linux-m68k-low.c (tdesc_m68k): Declare.
9249 (target_regsets): Rename to ...
9250 (m68k_regsets): ... this, and make static.
9251 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9252 (m68k_regs_info): New function.
9253 (m68k_arch_setup): New function.
9254 (the_low_target): Adjust.
9255 (initialize_low_arch): New function.
9256 * linux-sh-low.c (tdesc_sharch): Declare.
9257 (target_regsets): Rename to ...
9258 (sh_regsets): ... this, and make static.
9259 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9260 (sh_regs_info, sh_arch_setup): New functions.
9261 (the_low_target): Adjust.
9262 (initialize_low_arch): New function.
9263 * linux-bfin-low.c (tdesc_bfin): Declare.
9264 (bfin_arch_setup): New function.
9265 (bfin_usrregs_info, regs_info): New globals.
9266 (bfin_regs_info): New function.
9267 (the_low_target): Adjust.
9268 (initialize_low_arch): New function.
9269 * linux-cris-low.c (tdesc_cris): Declare.
9270 (cris_arch_setup): New function.
9271 (cris_usrregs_info, regs_info): New globals.
9272 (cris_regs_info): New function.
9273 (the_low_target): Adjust.
9274 (initialize_low_arch): New function.
9275 * linux-cris-low.c (tdesc_crisv32): Declare.
9276 (cris_arch_setup): New function.
9277 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9278 (cris_regs_info): New function.
9279 (the_low_target): Adjust.
9280 (initialize_low_arch): New function.
9281 * linux-m32r-low.c (tdesc_m32r): Declare.
9282 (m32r_arch_setup): New function.
9283 (m32r_usrregs_info, regs_info): New globals.
9284 (m32r_regs_info): Adjust.
9285 (initialize_low_arch): New function.
9286 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9287 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9288 (tic6x_usrregs_info): Forward declare.
9289 (tic6x_read_description): New function, based on ...
9290 (tic6x_arch_setup): ... this. Reimplement.
9291 (target_regsets): Rename to ...
9292 (tic6x_regsets): ... this, and make static.
9293 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9294 (tic6x_regs_info): New function.
9295 (the_low_target): Adjust.
9296 (initialize_low_arch): New function.
9297 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9298 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9299 (target_regsets): Rename to ...
9300 (xtensa_regsets): ... this, and make static.
9301 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9302 globals.
9303 (xtensa_arch_setup, xtensa_regs_info): New functions.
9304 (the_low_target): Adjust.
9305 (initialize_low_arch): New function.
9306 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9307 (nios2_arch_setup): Set the current process'es tdesc.
9308 (target_regsets): Rename to ...
9309 (nios2_regsets): ... this.
9310 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9311 (nios2_regs_info): New function.
9312 (the_low_target): Adjust.
9313 (initialize_low_arch): New function.
9314 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9315 (aarch64_arch_setup): Set the current process'es tdesc.
9316 (target_regsets): Rename to ...
9317 (aarch64_regsets): ... this.
9318 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9319 (aarch64_regs_info): New function.
9320 (the_low_target): Adjust.
9321 (initialize_low_arch): New function.
9322 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9323 globals.
9324 (target_regsets): Rename to ...
9325 (tile_regsets): ... this.
9326 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9327 (tile_regs_info): New function.
9328 (tile_arch_setup): Set the current process'es tdesc.
9329 (the_low_target): Adjust.
9330 (initialize_low_arch): New function.
9331 * spu-low.c (tdesc_spu): Declare.
9332 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9333 * win32-arm-low.c (tdesc_arm): Declare.
9334 (arm_arch_setup): New function.
9335 (the_low_target): Install arm_arch_setup instead of
9336 init_registers_arm.
9337 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9338 (init_windows_x86): Rename to ...
9339 (i386_arch_setup): ... this. Set `win32_tdesc'.
9340 (the_low_target): Adjust.
9341 * win32-low.c (win32_tdesc): New global.
9342 (child_add_thread): Don't create the thread cache here.
9343 (do_initial_child_stuff): Set the new process'es tdesc.
9344 * win32-low.h (struct target_desc): Forward declare.
9345 (win32_tdesc): Declare.
9346 * lynx-i386-low.c (tdesc_i386): Declare global.
9347 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9348 * lynx-low.c (lynx_tdesc): New global.
9349 (lynx_add_process): Set the new process'es tdesc.
9350 * lynx-low.h (struct target_desc): Forward declare.
9351 (lynx_tdesc): Declare global.
9352 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9353 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9354 * nto-low.c (nto_tdesc): New global.
9355 (do_attach): Set the new process'es tdesc.
9356 * nto-low.h (struct target_desc): Forward declare.
9357 (nto_tdesc): Declare.
9358 * nto-x86-low.c (tdesc_i386): Declare.
9359 (nto_x86_arch_setup): Set `nto_tdesc'.
9360
9361 2013-06-04 Gary Benson <gbenson@redhat.com>
9362
9363 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9364 to qSupported response when appropriate.
9365 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9366 with nonzero-length annex.
9367 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9368 arguments supplied in annex.
9369
9370 2013-05-31 Doug Evans <dje@google.com>
9371
9372 PR server/15594
9373 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9374 64 bits in 64-cross-32 environment.
9375
9376 2013-05-28 Pedro Alves <palves@redhat.com>
9377
9378 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9379 (aarch64-without-fpu.c): Delete rule.
9380 * configure.srv (aarch64*-*-linux*): Remove references to
9381 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9382 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9383 declaration.
9384
9385 2013-05-24 Pedro Alves <palves@redhat.com>
9386
9387 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9388 instead of strchr/decode_address. Error if the range isn't split
9389 with a ','. Don't assume there's be a ':' in the action.
9390
9391 2013-05-23 Yao Qi <yao@codesourcery.com>
9392 Pedro Alves <palves@redhat.com>
9393
9394 * linux-low.c (lwp_in_step_range): New function.
9395 (linux_wait_1): If the thread was range stepping and stopped
9396 outside the stepping range, report the stop to GDB. Otherwise,
9397 continue stepping. Add range stepping debug output.
9398 (linux_set_resume_request): Copy the step range from the resume
9399 request to the lwp.
9400 (linux_supports_range_stepping): New.
9401 (linux_target_ops) <supports_range_stepping>: Set to
9402 linux_supports_range_stepping.
9403 * linux-low.h (struct linux_target_ops)
9404 <supports_range_stepping>: New field.
9405 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9406 * linux-x86-low.c (x86_supports_range_stepping): New.
9407 (the_low_target) <supports_range_stepping>: Set to
9408 x86_supports_range_stepping.
9409 * server.c (handle_v_cont): Handle 'r' action.
9410 (handle_v_requests): Append ";r" if the target supports range
9411 stepping.
9412 * target.h (struct thread_resume) <step_range_start,
9413 step_range_end>: New fields.
9414 (struct target_ops) <supports_range_stepping>:
9415 New field.
9416 (target_supports_range_stepping): New macro.
9417
9418 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9419
9420 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9421 confusion in comment.
9422
9423 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9424
9425 * lynx-low.c (struct process_info_private): New type.
9426 (lynx_add_process): New function.
9427 (lynx_create_inferior, lynx_attach): Replace calls to
9428 add_process by calls to lynx_add_process.
9429 (lynx_resume): If PTID is null, then try using
9430 current_process()->private->last_wait_event_ptid.
9431 Add comments.
9432 (lynx_clear_inferiors): Delete. The contents of that function
9433 has been inlined in lynx_mourn;
9434 (lynx_wait_1): Save the ptid in the process's private data.
9435 (lynx_mourn): Free the process' private data. Replace call
9436 to lynx_clear_inferiors by call to clear_inferiors.
9437
9438 2013-05-17 Yao Qi <yao@codesourcery.com>
9439
9440 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9441 the right place.
9442
9443 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9444
9445 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9446 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9447 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9448 PT_TEXT_END_ADDR guards. Update comments.
9449 (linux_target_op) <read_offsets>: Conditionally define to
9450 linux_read_offsets if the target is UCLIBC and if it defines
9451 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9452
9453 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9454 Andrew Jenner <andrew@codesourcery.com>
9455
9456 * Makefile.in (SFILES): Add linux-nios2-low.c.
9457 (clean): Add action to delete nios2-linux.c.
9458 (nios2-linux.c): New rule.
9459 * configure.srv: Add nios2*-*-linux*.
9460 * linux-nios2-low.c: New.
9461
9462 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9463
9464 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9465
9466 2013-04-25 Hui Zhu <hui@codesourcery.com>
9467
9468 PR gdb/15186
9469 * ax.c (ax_printf): Add fflush.
9470
9471 2013-04-22 Tom Tromey <tromey@redhat.com>
9472
9473 * Makefile.in (SFILES): Add filestuff.c.
9474 (OBS): Add filestuff.o.
9475 (filestuff.o): New target.
9476 * config.in, configure: Rebuild.
9477 * configure.ac: Check for fdwalk, pipe2.
9478
9479 2013-04-17 Pedro Alves <palves@redhat.com>
9480
9481 * configure.ac (USE_THREAD_DB): Delete variable.
9482 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9483 Don't AC_SUBST USE_THREAD_DB.
9484 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9485 * config.in, configure: Regenerate.
9486
9487 2013-04-16 Pedro Alves <palves@redhat.com>
9488
9489 * linux-low.h (struct lwp_info) <thread_known>: Move under
9490 the USE_THREAD_DB #ifdef.
9491
9492 2013-04-16 Pedro Alves <palves@redhat.com>
9493
9494 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9495 (linux-low.o): Delete rule.
9496 * linux-low.h: Always include "gdb_thread_db.h" instead of
9497 conditionally including thread_db.h.
9498 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9499 HAVE_THREAD_DB_H.
9500
9501 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9502
9503 * Makefile.in (install-only): Fix make install regression.
9504
9505 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9506
9507 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9508 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9509 installation.
9510 * gdbserver.1: Remove.
9511
9512 2013-03-22 Pedro Alves <palves@redhat.com>
9513
9514 * linux-low.c (handle_extended_wait): Don't call
9515 linux_enable_event_reporting.
9516
9517 2013-03-15 Tony Theodore <tonyt@logyst.com>
9518
9519 PR build/9098:
9520 * Makefile.in (SHELL): Use @SHELL@.
9521
9522 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9523
9524 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9525 compiler warning.
9526
9527 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9528
9529 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9530 Remove extraneous NULL element.
9531
9532 2013-03-13 Yao Qi <yao@codesourcery.com>
9533
9534 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9535 'V' block in trace frame.
9536
9537 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9538
9539 * target.h (struct target_ops): Add btrace ops.
9540 (target_supports_btrace): New macro.
9541 (target_enable_btrace): New macro.
9542 (target_disable_btrace): New macro.
9543 (target_read_btrace): New macro.
9544 * gdbthread.h (struct thread_info): Add btrace field.
9545 * server.c: Include btrace-common.h.
9546 (handle_btrace_general_set): New function.
9547 (handle_btrace_enable): New function.
9548 (handle_btrace_disable): New function.
9549 (handle_general_set): Call handle_btrace_general_set.
9550 (handle_qxfer_btrace): New function.
9551 (struct qxfer qxfer_packets[]): Add btrace entry.
9552 * inferiors.c (remove_thread): Disable btrace.
9553 * linux-low: Include linux-btrace.h.
9554 (linux_low_enable_btrace): New function.
9555 (linux_low_read_btrace): New function.
9556 (linux_target_ops): Add btrace ops.
9557 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9558 Add srv_linux_btrace=yes.
9559 (x86_64-*-linux*): Add linux-btrace.o.
9560 Add srv_linux_btrace=yes.
9561 * configure.ac: Define HAVE_LINUX_BTRACE.
9562 * config.in: Regenerated.
9563 * configure: Regenerated.
9564
9565 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9566
9567 * server.c (handle_qxfer): Preserve error message if -3 is
9568 returned.
9569 (qxfer): Document the -3 return value.
9570
9571 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9572
9573 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
9574 (linux_btrace_h): New variable.
9575 (linux-btrace.o): New rule.
9576
9577 2013-03-08 Stan Shebs <stan@codesourcery.com>
9578 Hafiz Abid Qadeer <abidh@codesourcery.com>
9579
9580 * tracepoint.c (trace_buffer_size): New global.
9581 (DEFAULT_TRACE_BUFFER_SIZE): New define.
9582 (init_trace_buffer): Change to one-argument function. Allocate
9583 trace buffer memory.
9584 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
9585 handle QTBuffer:size packet.
9586 (cmd_bigqtbuffer_size): New function.
9587 (initialize_tracepoint): Call init_trace_buffer with
9588 DEFAULT_TRACE_BUFFER_SIZE.
9589 * server.c (handle_query): Add QTBuffer:size in the
9590 supported packets.
9591
9592 2013-03-07 Yao Qi <yao@codesourcery.com>
9593
9594 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
9595 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
9596 of -1.
9597 (cmd_qtsp): Adjust condition. Do post increment.
9598 Set cur_action and cur_step_action back to 0.
9599
9600 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
9601
9602 PR server/15236
9603 * linux-low.c (linux_write_memory): Return early success if LEN is
9604 zero.
9605
9606 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
9607
9608 * configure.srv: Add x86_64-*-cygwin* as target.
9609
9610 2013-02-28 Tom Tromey <tromey@redhat.com>
9611
9612 * configure.ac: Invoke AC_SYS_LARGEFILE.
9613 * configure, config.in: Rebuild.
9614
9615 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
9616
9617 * win32-low.c: Throughout, fix format strings and casts of
9618 printf-like functions to avoid type related warnings on all
9619 platforms.
9620 (get_child_debug_event): Print dwDebugEventCode as hex since
9621 that's how it's usually documented.
9622
9623 2013-02-28 Yao Qi <yao@codesourcery.com>
9624
9625 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
9626 pulongest.
9627
9628 2013-02-27 Jiong Wang <jiwang@tilera.com>
9629
9630 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
9631 (reg-tilegx32.c): New rule.
9632 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
9633 * linux-tile-low.c (tile_arch_setup): New function. Invoke
9634 different register info initializer according to elf class.
9635 (init_registers_tilgx32): New function. The tilegx32 register info
9636 initializer.
9637 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
9638 (tile_store_gregset): Likewise.
9639
9640 2013-02-27 Yao Qi <yao@codesourcery.com>
9641
9642 * server.c (process_point_options): Print debug message when
9643 debug_threads is true.
9644
9645 2013-02-26 Yao Qi <yao@codesourcery.com>
9646
9647 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
9648
9649 2013-02-19 Pedro Alves <palves@redhat.com>
9650 Kai Tietz <ktietz@redhat.com>
9651
9652 PR gdb/15161
9653
9654 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
9655 instead of strtoul to extract address from packet.
9656 (process_serial_event) <'z'>: Likewise.
9657
9658 2013-02-18 Yao Qi <yao@codesourcery.com>
9659
9660 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
9661
9662 2013-02-14 Pedro Alves <palves@redhat.com>
9663
9664 Plug memory leak.
9665
9666 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
9667 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
9668
9669 2013-02-14 Pedro Alves <palves@redhat.com>
9670
9671 * tracepoint.c (cmd_qtdpsrc): Use savestring.
9672
9673 2013-02-14 Pedro Alves <palves@redhat.com>
9674
9675 * tracepoint.c (save_string): Delete.
9676 (add_tracepoint_action): Use savestring instead of save_string.
9677
9678 2013-02-12 Pedro Alves <palves@redhat.com>
9679
9680 * linux-xtensa-low.c: Ditto.
9681 * xtensa-xtregs.c: Ditto.
9682
9683 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
9684
9685 * thread-db.c (thread_db_get_tls_address): NULL pointer check
9686 thread_db.
9687
9688 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
9689
9690 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
9691 aarch64_num_wp_regs and aarch64_num_bp_regs to
9692 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
9693
9694 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
9695
9696 * linux-aarch64-low.c (ps_get_thread_area): Replace
9697 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
9698
9699 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
9700 Marcus Shawcroft <marcus.shawcroft@arm.com>
9701 Nigel Stephens <nigel.stephens@arm.com>
9702 Yufeng Zhang <yufeng.zhang@arm.com>
9703
9704 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
9705 (aarch64.c, aarch64-without-fpu.c): New targets.
9706 * configure.srv (aarch64*-*-linux*): New.
9707 * linux-aarch64-low.c: New file.
9708
9709 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
9710
9711 * linux-low.c (handle_extended_wait, linux_create_inferior)
9712 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
9713 (dequeue_one_deferred_signal, linux_resume_one_thread)
9714 (fetch_register, linux_write_memory, linux_enable_event_reporting)
9715 (linux_tracefork_grandchild, linux_test_for_tracefork)
9716 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
9717 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
9718 where the argument is 0.
9719
9720 2013-01-25 Yao Qi <yao@codesourcery.com>
9721
9722 * event-loop.c: Include "queue.h".
9723 (gdb_event_p): New typedef.
9724 (struct gdb_event) <next_event>: Remove.
9725 (event_queue): Change to QUEUE(gdb_event_p).
9726 (async_queue_event): Remove.
9727 (gdb_event_xfree): New.
9728 (initialize_event_loop): New.
9729 (process_event): Use API from QUEUE.
9730 (wait_for_event): Likewise.
9731 * server.c (main): Call initialize_event_loop.
9732 * server.h (initialize_event_loop): Declare.
9733
9734 2013-01-18 Yao Qi <yao@codesourcery.com>
9735
9736 * ax.h (struct eval_agent_expr_context): New.
9737 (gdb_eval_agent_expr): Update declaration.
9738 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
9739 TFRAME. Add new argument CTX.
9740 * server.h (struct eval_agent_expr_context): Declare.
9741 (agent_mem_read, agent_tsv_read): Update declaration.
9742 (agent_mem_read_string): Likewise.
9743 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
9744 (add_traceframe_block): Add new argument TPOINT.
9745 Increase TPOINT->traceframe_usage.
9746 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
9747 eval_tracepoint_agent_expr.
9748 (condition_true_at_tracepoint): Likewise.
9749 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
9750 (agent_mem_read_string, agent_tsv_read): Likewise.
9751
9752 2013-01-16 Yao Qi <yao@codesourcery.com>
9753
9754 * linux-low.c (linux_resume_one_lwp): Don't check
9755 'lwp->bp_reinsert != 0'.
9756
9757 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9758 Pedro Alves <palves@redhat.com>
9759
9760 * lynx-low.c (ptrace_request_to_str): Define a temporary
9761 macro and use it to simplify this function's implementation.
9762
9763 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9764
9765 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
9766 sets errno.
9767
9768 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9769
9770 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
9771
9772 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9773
9774 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
9775
9776 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9777
9778 * lynx-low.c (lynx_resume): Use the resume_info parameter
9779 to determine the ptid for the lynx_ptrace call, unless
9780 it is equal to minus_one_ptid, in which case we use the
9781 ptid of the current_inferior.
9782 (lynx_wait_1): After having received a thread create/exit
9783 event, resume the inferior's execution using the signaling
9784 thread's ptid, rather than the old ptid.
9785
9786 2013-01-07 Joel Brobecker <brobecker@adacore.com>
9787
9788 * lynx-low.c (lynx_resume): Delete variable ret.
9789
9790 2013-01-01 Joel Brobecker <brobecker@adacore.com>
9791
9792 * gdbreplay.c (gdbreplay_version): Update copyright year.
9793 * server.c (gdbserver_version): Likewise.
9794
9795 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9796
9797 * lynx-low.c (lynx_wait_1): Add debug trace before adding
9798 new thread.
9799
9800 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9801
9802 * lynx-low.c (ptrace_request_to_str): Add handling for
9803 PTRACE_GETTRACESIG.
9804
9805 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9806
9807 * lynx-low.c (lynx_attach): Delete variable new_process.
9808
9809 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9810
9811 * lynx-low.c (lynx_create_inferior): Delete variable
9812 new_process.
9813
9814 2012-12-17 Joel Brobecker <brobecker@adacore.com>
9815
9816 * lynx-low.c (ptrace_request_to_str): Do not handle
9817 PTRACE_GETTHREADLIST if this macro does not exist.
9818
9819 2012-12-15 Yao Qi <yao@codesourcery.com>
9820
9821 * Makefile.in (OBS): Add notif.o.
9822 * notif.c, notif.h: New.
9823 * server.c: Include "notif.h".
9824 (struct vstop_notif) <next>: Remove.
9825 <base>: New field.
9826 (queue_stop_reply): Update.
9827 (push_event, send_next_stop_reply): Remove.
9828 (discard_queued_stop_replies): Update.
9829 (notif_stop): New variable.
9830 (handle_v_stopped): Remove.
9831 (handle_v_requests): Don't call handle_v_stopped. Call
9832 handle_ack_notif instead.
9833 (queue_stop_reply_callback): Call notif_event_enque instead
9834 of queue_stop_reply.
9835 (handle_status): Don't call send_next_stop_reply, call
9836 notif_write_event instead.
9837 (kill_inferior_callback): Likewise.
9838 (detach_or_kill_inferior_callback): Likewise.
9839 (main): Call initialize_notif.
9840 (process_serial_event): Call QUEUE_is_empty.
9841 (handle_target_event): Call notif_push instead of push event.
9842 * server.h (push_event): Remove declaration.
9843
9844 2012-12-10 Tom Tromey <tromey@redhat.com>
9845
9846 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
9847 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
9848 macros.
9849 (.c.o): Rewrite.
9850 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
9851 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
9852 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
9853 (amd64-linux-ipa.o, ax.o): Rewrite.
9854 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
9855 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
9856 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
9857 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
9858 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
9859 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
9860 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
9861 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
9862 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
9863 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
9864 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
9865 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
9866 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
9867 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
9868 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
9869 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
9870 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
9871 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
9872 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
9873 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
9874 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
9875 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
9876 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
9877 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
9878 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
9879 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
9880 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
9881 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
9882 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
9883 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
9884 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
9885 (reg-tilegx.o): Remove.
9886 (all_object_files): New macro.
9887 Include .deps files.
9888 * aclocal.m4, configure: Rebuild.
9889 * acinclude.m4: Include depstand.m4, lead-dot.m4.
9890 * configure.ac: Invoke ZW_CREATE_DEPDIR,
9891 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
9892
9893 2012-12-05 Tom Tromey <tromey@redhat.com>
9894
9895 PR gdb/14917:
9896 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
9897
9898 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
9899
9900 * configure.ac: Check for linux/perf_event.h.
9901 * config.in: Regenerated.
9902 * configure: Regenerated.
9903
9904 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
9905
9906 * hostio.c (handle_readlink): Decrease buffer size
9907 parameter passed to readlink by one byte.
9908
9909 2012-11-26 Yao Qi <yao@codesourcery.com>
9910
9911 * configure.ac (build_warnings): Append '-Wempty-body'.
9912 * configure: Regenerated.
9913 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
9914 body.
9915
9916 2012-11-15 Pierre Muller <muller@sourceware.org>
9917
9918 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
9919 * config.in: Regenerate.
9920 * configure: Regenerate.
9921 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
9922 Use "gdb_wait.h" header instead of <sys/wait.h> header.
9923 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9924 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
9925 header.
9926 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
9927 instead of <sys/wait.h> header.
9928 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
9929
9930 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
9931
9932 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
9933 (various make rules): Remove -DGDBSERVER
9934
9935 2012-11-09 Yao Qi <yao@codesourcery.com>
9936
9937 * spu-low.c (current_ptid): Move it to ..
9938 * gdbthread.h: ... here. New.
9939 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
9940 * server.c (myresume, process_serial_event): Likewise.
9941 * thread-db.c (thread_db_find_new_threads): Likewise.
9942 * tracepoint.c (run_inferior_command): Likewise.
9943
9944 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
9945
9946 * server.c (handle_search_memory_1): Include access length in
9947 warning message.
9948
9949 2012-09-05 Michael Brandt <michael.brandt@axis.com>
9950
9951 * linux-crisv32-low.c: Fix compile errors.
9952
9953 2012-09-04 Yao Qi <yao@codesourcery.com>
9954
9955 * tracepoint.c (cmd_qtsv): Adjust debug message.
9956 Don't check CUR_TPOINT.
9957
9958 2012-08-28 Yao Qi <yao@codesourcery.com>
9959
9960 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
9961 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
9962 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
9963 Remove declarations of xmalloc, xreallloc, xstrdup and
9964 freeargv.
9965 * Makefile.in (libiberty_h): New.
9966 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
9967 (linux-bfin-low.o): Append dependency 'libiberty.h'.
9968
9969 2012-08-23 Yao Qi <yao@codesourcery.com>
9970
9971 * server.h: Remove declaration of 'xsnprintf'.
9972
9973 2012-08-22 Keith Seitz <keiths@redhat.com>
9974
9975 * server.h: Include build-gnulib-gbserver/config.h.
9976 * gdbreplay.c: Likewise.
9977
9978 2012-08-08 Doug Evans <dje@google.com>
9979
9980 * Makefile.in (SFILES): Add gdb_vecs.c.
9981 (OBS): Add gdb_vecs.o.
9982 (gdb_vecs_h, host_defs_h): New variables.
9983 (thread-db.o): Add $(gdb_vecs_h) dependency.
9984 (gdb_vecs.o): New rule.
9985 * thread-db.c: #include "gdb_vecs.h".
9986 (thread_db_load_search): Use a vector to iterate over path elements.
9987 Handle text appearing after "$pdir".
9988
9989 * configure.ac: Add check for strstr.
9990 * config.in: Regenerate.
9991 * configure: Regenerate.
9992
9993 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
9994
9995 * hostio.c (handle_pread): If pread fails, fall back to attempting
9996 lseek/read.
9997 (handle_pwrite): Likewise for pwrite.
9998
9999 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10000
10001 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10002 between unsupported TYPE and unimplementable ADDR/LEN combination.
10003 (arm_insert_point): Act on new return value.
10004
10005 2012-07-31 Pedro Alves <palves@redhat.com>
10006
10007 * server.c (process_point_options): Only skip tokens if we find
10008 one that is unrecognized. Don't treat 'X' specially while
10009 skipping unrecognized tokens.
10010
10011 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10012
10013 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10014 to 4-byte-align HW breakpoint addresses for Thumb.
10015
10016 2012-07-27 Yao Qi <yao@codesourcery.com>
10017
10018 PR remote/14161.
10019
10020 * server.h: Declare gdb_agent_about_to_close.
10021 * target.c (kill_inferior): Include "agent.h".
10022 New. Send command 'kill'.
10023 * target.h (kill_inferior): Removed macro.
10024 * tracepoint.c (gdb_agent_about_to_close): New.
10025 (gdb_agent_helper_thread): Handle command 'close'.
10026 Wait endlessly until the inferior stops.
10027 Install gdb_agent_remove_socket to atexit hook.
10028 (agent_socket_name): New static variable.
10029 (gdb_agent_socket_init): Replace local variable 'name' with
10030 'agent_socket_name'.
10031 (gdb_agent_remove_socket): New.
10032
10033 2012-07-27 Yao Qi <yao@codesourcery.com>
10034
10035 * server.c (process_point_options): Stop at 'X' when parsing.
10036
10037 2012-07-19 Michael Eager <eager@eagercon.com>
10038
10039 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10040 to hw_execute.
10041 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10042 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10043 hardware breakpoint.
10044
10045 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10046
10047 * gdbserver/linux-low.c (initialize_low): Call
10048 linux_ptrace_init_warnings.
10049
10050 2012-07-02 Doug Evans <dje@google.com>
10051
10052 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10053 pointer to int.
10054
10055 2012-07-02 Stan Shebs <stan@codesourcery.com>
10056
10057 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10058 (ax.o): Add it to build rule.
10059 (ax-ipa.o): Ditto.
10060 (OBS): Add format.o.
10061 (IPA_OBS): Add format.o.
10062 * server.c (handle_query): Claim support for breakpoint commands.
10063 (process_point_options): Add command case.
10064 (process_serial_event): Leave running if there are printfs in
10065 effect.
10066 * mem-break.h (any_persistent_commands): Declare.
10067 (add_breakpoint_commands): Declare.
10068 (gdb_no_commands_at_breakpoint): Declare.
10069 (run_breakpoint_commands): Declare.
10070 * mem-break.c (struct point_command_list): New struct.
10071 (struct breakpoint): New field command_list.
10072 (any_persistent_commands): New function.
10073 (add_commands_to_breakpoint): New function.
10074 (add_breakpoint_commands): New function.
10075 (gdb_no_commands_at_breakpoint): New function.
10076 (run_breakpoint_commands): New function.
10077 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10078 locally.
10079 * ax.c: Include format.h.
10080 (ax_printf): New function.
10081 (gdb_eval_agent_expr): Add printf opcode.
10082
10083 2012-06-13 Yao Qi <yao@codesourcery.com>
10084
10085 * server.c (start_inferior): Remove duplicated writes to fields
10086 'last_resume_kind' and 'last_status' of 'current_inferior'.
10087
10088 2012-06-12 Yao Qi <yao@codesourcery.com>
10089 Pedro Alves <palves@redhat.com>
10090
10091 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10092 comment.
10093 * server.c (handle_v_cont): Extend comment.
10094
10095 2012-06-11 Yao Qi <yao@codesourcery.com>
10096
10097 * linux-low.c (linux_attach): Add 'static'.
10098
10099 2012-06-06 Yao Qi <yao@codesourcery.com>
10100
10101 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10102
10103 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10104
10105 Fix gcc -flto compilation warning.
10106 * server.c (main): Make variable multi_mode and attach volatile.
10107
10108 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10109
10110 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10111 if the platform doesn't know about it.
10112
10113 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10114
10115 * Makefile.in (SFILES): Add linux-tile-low.c.
10116 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10117 * configure.srv: Handle tilegx-*-linux*.
10118 * linux-tile-low.c: New file.
10119
10120 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10121
10122 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10123
10124 2012-05-24 Pedro Alves <palves@redhat.com>
10125
10126 PR gdb/7205
10127
10128 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10129
10130 2012-05-24 Pedro Alves <palves@redhat.com>
10131
10132 PR gdb/7205
10133
10134 Replace target_signal with gdb_signal throughout.
10135
10136 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10137
10138 * linux-low.c (linux_store_registers): Avoid the copying sequence
10139 when no data has been retrieved by ptrace.
10140
10141 2012-05-22 Will Deacon <will.deacon@arm.com>
10142
10143 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10144 Include asm/ptrace.h.
10145 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10146 already defined.
10147
10148 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10149
10150 * linux-low.c (linux_store_registers): Don't re-retrieve data
10151 with ptrace that has already been obtained from /proc. Always
10152 copy any data retrieved with ptrace to the buffer supplied.
10153
10154 2012-05-11 Yao Qi <yao@codesourcery.com>
10155 Pedro Alves <palves@redhat.com>
10156
10157 * linux-low.c (enum stopping_threads_kind): New.
10158 (stopping_threads): Change type to `enum stopping_threads_kind'.
10159 (handle_extended_wait): If stopping and suspending threads, leave
10160 the new_lwp suspended too.
10161 (linux_wait_for_event): Adjust.
10162 (stop_all_lwps): Set `stopping_threads' to
10163 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10164 whether we're suspending threads or just stopping them. Assert no
10165 recursion happens.
10166
10167 2012-04-29 Yao Qi <yao@codesourcery.com>
10168
10169 * server.h: Move some code to ...
10170 * gdbthread.h: ... here. New.
10171 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10172 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10173 (nto-low.o, win32-low.o): Likewise.
10174 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10175 * regcache.c, remote-utils.c, server.c: Likewise.
10176 * target.c, tracepoint.c, win32-low.c: Likewise.
10177
10178 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10179
10180 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10181 (PTRACE_ARG4_TYPE): Likewise.
10182 (PTRACE_XFER_TYPE): Likewise.
10183 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10184 ptrace to PTRACE_ARG3_TYPE.
10185 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10186 (PTRACE_ARG4_TYPE): Likewise.
10187 (PTRACE_XFER_TYPE): Likewise.
10188 (linux_detach_one_lwp): Cast fourth argument of
10189 ptrace to long then PTRACE_ARG4_TYPE.
10190 (regsets_fetch_inferior_registers): Cast third argument of
10191 ptrace to long then PTRACE_ARG3_TYPE.
10192 (regsets_store_inferior_registers): Likewise.
10193
10194 2012-04-20 Pedro Alves <palves@redhat.com>
10195
10196 * configure: Regenerate.
10197
10198 2012-04-19 Pedro Alves <palves@redhat.com>
10199
10200 * Makefile.in (GNULIB_BUILDDIR): New.
10201 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10202 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10203 (all, install-only, uninstall, clean-info, all-lib, clean): No
10204 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10205 (maintainer-clean realclean distclean): Use subdir_do.
10206 (subdir_do): New.
10207 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10208 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10209 * acinclude.m4: Include acx_configure_dir.m4.
10210 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10211 calls. Call AC_PROG_RANLIB. Configure gnulib using
10212 ACX_CONFIGURE_DIR.
10213 (GNULIB): New.
10214 (GNULIB_STDINT_H): Adjust.
10215 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10216 * gdbreplay.c: Include build-gnulib/config.h.
10217 * server.h: Likewise.
10218 * aclocal.m4: Regenerate.
10219 * config.in: Regenerate.
10220 * configure: Regenerate.
10221
10222 2012-04-19 Pedro Alves <palves@redhat.com>
10223
10224 * Makefile.in (LIBGNU, INCGNU): Adjust.
10225 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10226 (all, install-only, uninstall, clean-info, all-lib, clean)
10227 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10228 * configure.ac: Adjust AC_OUTPUT output.
10229 * aclocal.m4: Regenerate.
10230 * configure: Regenerate.
10231
10232 2012-04-19 Pedro Alves <palves@redhat.com>
10233
10234 * Makefile.in (generated_files): New.
10235 (server_h): Remove the explicit dependency on config.h, and depend
10236 on $generated_files.
10237
10238 2012-04-19 Pedro Alves <palves@redhat.com>
10239
10240 * Makefile.in (INCGNU): Add -Ignulib.
10241
10242 2012-04-19 Pedro Alves <palves@redhat.com>
10243
10244 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10245 (INCGNU): ... this, and spell out -I here.
10246 (GNULIB_LIB): Rename to ...
10247 (LIBGNU): ... this.
10248 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10249
10250 2012-04-19 Pedro Alves <palves@redhat.com>
10251
10252 * config.in: Regenerate.
10253
10254 2012-04-19 Pedro Alves <palves@redhat.com>
10255
10256 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10257 * server.h (memmem): Remove declaration.
10258 * config.in: Regenerate.
10259 * configure: Regenerate.
10260
10261 2012-04-19 Yao Qi <yao@codesourcery.com>
10262
10263 * Makefile.in (SFILES): Add common/vec.c.
10264 (OBS): Add vec.o.
10265 (vec.o): New rule.
10266
10267 2012-04-19 Yao Qi <yao@codesourcery.com>
10268
10269 * remote-utils.c (prepare_resume_reply): Replace with macro
10270 target_core_of_thread.
10271 * server.c (handle_qxfer_threads_proper): Likewise.
10272 * target.h (traget_core_of_thread): New macro.
10273
10274 2012-04-18 Pedro Alves <palves@redhat.com>
10275
10276 * aclocal.m4: Regenerate.
10277 * configure: Regenerate.
10278
10279 2012-04-16 Yao Qi <yao@codesourcery.com>
10280
10281 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10282 duplicated on address.
10283
10284 2012-04-16 Yao Qi <yao@codesourcery.com>
10285
10286 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10287 (struct tracepoint_action_ops) <send>: New field.
10288 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10289 (agent_expr_send, x_tracepoint_action_send): New.
10290 (l_tracepoint_action_send): New.
10291 (cmd_qtdp): Download and install tracepoint
10292 according to `use_agent'.
10293 (run_inferior_command): Add one more parameter `len'.
10294 Update callers.
10295 (tracepoint_send_agent): New.
10296 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10297
10298 2012-04-16 Yao Qi <yao@codesourcery.com>
10299
10300 * tracepoint.c (download_tracepoints): Moved to ...
10301 (cmd_qtstart): ... here.
10302
10303 2012-04-14 Yao Qi <yao@codesourcery.com>
10304
10305 * tracepoint.c: Include inttypes.h.
10306 (struct collect_memory_action): Use sized types.
10307 (struct tracepoint): Likewise.
10308 (cmd_qtdp, stop_tracing): Update print specifiers.
10309 (cmd_qtp, response_tracepoint): Likewise.
10310 (collect_data_at_tracepoint): Likewise.
10311 (collect_data_at_step): Likewise.
10312
10313 2012-04-14 Yao Qi <yao@codesourcery.com>
10314
10315 Import gnulib module inttypes.
10316 * aclocal.m4, config.in, configure: Regenerated.
10317
10318 2012-04-14 Yao Qi <yao@codesourcery.com>
10319
10320 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10321 Makefile and config.status at last.
10322
10323 2012-04-13 Yao Qi <yao@codesourcery.com>
10324
10325 * tracepoint.c: Include stdint.h unconditionally.
10326
10327 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10328
10329 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10330 on BFD_HAVE_SYS_PROCFS_TYPE.
10331 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10332 * configure: Regenerate.
10333 * config.in: Likewise.
10334
10335 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10336
10337 * Makefile.in (clean): Also remove x32.c x32-linux.c
10338 x32-avx.c x32-avx-linux.c.
10339 (x32.o): New target.
10340 (x32.c): Likewise.
10341 (x32-linux.o): Likewise.
10342 (x32-linux.c): Likewise.
10343 (x32-avx.o): Likewise.
10344 (x32-avx.c): Likewise.
10345 (x32-avx-linux.o): Likewise.
10346 (x32-avx-linux.c): Likewise.
10347
10348 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10349 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10350 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10351 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10352 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10353 i386/x32-avx-linux.xml.
10354
10355 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10356 (init_registers_x32_avx_linux): Likwise.
10357 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10358 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10359
10360 2012-04-13 Pedro Alves <palves@redhat.com>
10361
10362 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10363 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10364 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10365 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10366 the sub-make.
10367
10368 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10369
10370 * linux-x86-low.c (compat_x32_clock_t): New.
10371 (compat_x32_siginfo_t): Likewise.
10372 (compat_x32_siginfo_from_siginfo): Likewise.
10373 (siginfo_from_compat_x32_siginfo): Likewise.
10374 (linux_is_elf64): Likewise.
10375 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10376 and siginfo_from_compat_x32_siginfo for x32.
10377 (x86_arch_setup): Set linux_is_elf64.
10378
10379 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10380
10381 PR gdb/13969
10382 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10383 e_machine field.
10384 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10385 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10386 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10387 compatible with process.
10388
10389 2012-04-12 Yao Qi <yao@codesourcery.com>
10390
10391 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10392 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10393 (install-only, install-info, clean): Handle sub dir gnulib.
10394 (all-lib, am--refresh): New targets.
10395 (memmem.o): Remove target.
10396 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10397 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10398 (AC_REPLACE_FUNCS): Remove memmem.
10399 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10400 (AC_OUTPUT): Generate Makefile in gnulib/.
10401 * aclocal.m4, config.in, configure: Regenerated.
10402
10403 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10404
10405 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10406
10407 2012-04-05 Pedro Alves <palves@redhat.com>
10408
10409 -Werror=strict-aliasing
10410
10411 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10412 pointer.
10413
10414 2012-04-04 Pedro Alves <palves@redhat.com>
10415
10416 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10417 (sparc_store_gregset_from_stack, sparc_store_gregset)
10418 (sparc_breakpoint_at): Fix formatting.
10419
10420 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10421
10422 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10423 are available.
10424 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10425 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10426 * config.in: Regenerate.
10427 * configure: Likewise.
10428
10429 2012-03-29 Pedro Alves <palves@redhat.com>
10430
10431 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10432 Correct ptrace arguments.
10433
10434 2012-03-28 Pedro Alves <palves@redhat.com>
10435
10436 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10437 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10438 (IA64_FR1_REGNUM): New defines.
10439 (ia64_fetch_register): New.
10440 (the_low_target): Install it.
10441 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10442 field.
10443 * linux-low.c (linux_fetch_registers): Try the
10444 the_low_target.fetch_register hook first.
10445
10446 * linux-arm-low.c (the_low_target): Adjust.
10447 * linux-bfin-low.c (the_low_target): Adjust.
10448 * linux-cris-low.c (the_low_target): Adjust.
10449 * linux-crisv32-low.c (the_low_target): Adjust.
10450 * linux-m32r-low.c (the_low_target): Adjust.
10451 * linux-m68k-low.c (the_low_target): Adjust.
10452 * linux-mips-low.c (the_low_target): Adjust.
10453 * linux-ppc-low.c (the_low_target): Adjust.
10454 * linux-s390-low.c (the_low_target): Adjust.
10455 * linux-sh-low.c (the_low_target): Adjust.
10456 * linux-sparc-low.c (the_low_target): Adjust.
10457 * linux-tic6x-low.c (the_low_target): Adjust.
10458 * linux-x86-low.c (the_low_target): Adjust.
10459 * linux-xtensa-low.c (the_low_target): Adjust.
10460
10461 2012-03-26 Pedro Alves <palves@redhat.com>
10462
10463 * server.c (handle_qxfer_libraries): Don't bail early if
10464 the_target->qxfer_libraries_svr4 is not NULL.
10465
10466 2012-03-26 Pedro Alves <palves@redhat.com>
10467
10468 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10469
10470 2012-03-23 Pedro Alves <palves@redhat.com>
10471
10472 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10473 "library-list-svr4" element's start tag when the the DSO list is
10474 empty.
10475
10476 2012-03-23 Pedro Alves <palves@redhat.com>
10477
10478 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10479 a variable whose type size is the same as the inferior's pointer
10480 size.
10481
10482 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10483
10484 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10485 struct siginfo.
10486 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10487 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10488 * linux-low.h: Include <signal.h>.
10489 (struct siginfo): Remove forward declaration.
10490 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10491 struct siginfo.
10492
10493 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10494
10495 * .gitignore: Ignore more files.
10496
10497 2012-03-19 Pedro Alves <palves@redhat.com>
10498 Jan Kratochvil <jan.kratochvil@redhat.com>
10499
10500 * server.c (cont_thread, general_thread): Add describing comments.
10501 (start_inferior): Clear `cont_thread'.
10502 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10503 of a process.
10504
10505 2012-03-15 Yao Qi <yao@codesourcery.com>
10506
10507 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10508 handling to ...
10509 (cmd_qtdp): ... here.
10510
10511 2012-03-15 Yao Qi <yao@codesourcery.com>
10512
10513 * tracepoint.c (struct tracepoint_action_ops): New.
10514 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10515 (m_tracepoint_action_download): New.
10516 (r_tracepoint_action_download): New.
10517 (x_tracepoint_action_download): New.
10518 (l_tracepoint_action_download): New.
10519 (add_tracepoint_action): Install `action->ops' according type.
10520 (download_tracepoint_1): Move code `download' function pointer
10521 of various tracepoint_action_ops.
10522
10523 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10524
10525 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10526 linux_ptrace_attach_warnings.
10527
10528 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10529
10530 * Makefile.in (linux-ptrace.o): New.
10531 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10532 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10533 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10534 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10535 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10536 of these targets.
10537 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10538
10539 2012-03-08 Yao Qi <yao@codesourcery.com>
10540 Pedro Alves <palves@redhat.com>
10541
10542 Fix PR server/13392.
10543 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10544 offset of JMP insn.
10545 * tracepoint.c (remove_tracepoint): New.
10546 (cmd_qtdp): Call remove_tracepoint when failed to install.
10547
10548 2012-03-07 Pedro Alves <palves@redhat.com>
10549
10550 * linux-low.c (get_detach_signal): New.
10551 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10552 Pass on pending signals to PTRACE_DETACH. Check the result of the
10553 ptrace call.
10554 * server.c (program_signals, program_signals_p): New.
10555 (handle_general_set): Handle QProgramSignals.
10556 * server.h (program_signals, program_signals_p): Declare.
10557
10558 2012-03-05 Pedro Alves <palves@redhat.com>
10559 Jan Kratochvil <jan.kratochvil@redhat.com>
10560
10561 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10562 New comment why.
10563
10564 2012-03-03 Yao Qi <yao@codesourcery.com>
10565
10566 * tracepoint.c (tracepoint_look_up_symbols): Update call to
10567 agent_look_up_symbols.
10568
10569 2012-03-03 Yao Qi <yao@codesourcery.com>
10570
10571 * Makefile.in (linux-low.o): Keep dependence on agent.h.
10572 (linux-x86-low.o): Likewise.
10573 * server.h: Remove in_process_agent_loaded.
10574 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
10575 common/agent.c.
10576 Update callers.
10577
10578 2012-03-03 Yao Qi <yao@codesourcery.com>
10579
10580 * tracepoint.c (gdb_agent_capability): New global.
10581 (in_process_agent_loaded_ust): Renamed to
10582 `in_process_agent_supports_ust'.
10583 Update callers.
10584 (in_process_agent_supports_ust): Call agent_capability_check.
10585 (clear_installed_tracepoints): Assert that agent supports
10586 agent.
10587
10588 2012-03-03 Yao Qi <yao@codesourcery.com>
10589
10590 * linux-low.c (linux_supports_agent): New.
10591 (linux_target_ops): Initialize field `supports_agent' with
10592 linux_supports_agent.
10593 * target.h (struct target_ops) <supports_agent>: New.
10594 (target_supports_agent): New macro.
10595 * server.c (handle_general_set): Handle packet 'QAgent'.
10596 (handle_query): Send `QAgent+'.
10597 * Makefile.in (server.o): Depends on agent.h.
10598
10599 2012-03-03 Yao Qi <yao@codesourcery.com>
10600
10601 * Makefile.in (OBS): Add agent.o.
10602 Add new rule for agent.o.
10603 Track dependence of tracepoint.c on agent.h.
10604 * tracepoint.c (run_inferior_command_1):
10605 (run_inferior_command): Call agent_run_command.
10606 (gdb_ust_connect_sync_socket): Deleted. Move it to
10607 common/agent.c.
10608 (resume_thread, stop_thread): Likewise.
10609 (gdb_ust_socket_init): Renamed to ...
10610 (gdb_agent_socket_init): ... New.
10611 (gdb_ust_thread): Renamed to ...
10612 (gdb_agent_helper_thread): ... New.
10613 (gdb_ust_init): Move some code to ...
10614 (gdb_agent_init): ... here. New.
10615 [HAVE_UST]: Call gdb_ust_init.
10616 (initialize_tracepoint_ftlib): Call gdb_agent_init.
10617 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
10618 * config.in, configure: Regenerated.
10619
10620 2012-03-02 Pedro Alves <palves@redhat.com>
10621
10622 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
10623 * linux-low.c (struct simple_pid_list): New.
10624 (stopped_pids): New a struct simple_pid_list pointer.
10625 (add_to_pid_list, pull_pid_from_list): New.
10626 (handle_extended_wait): Don't assume the first signal new children
10627 report is SIGSTOP. Adjust call to pull_pid_from_list.
10628 (linux_wait_for_lwp): Adjust.
10629
10630 2012-03-02 Yao Qi <yao@codesourcery.com>
10631
10632 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
10633 debug log.
10634
10635 2012-03-02 Yao Qi <yao@codesourcery.com>
10636
10637 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
10638 `stop_pc' and `tpoint'. Update caller.
10639
10640 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
10641
10642 * linux-low.h (linux_target_ops): Add regset_bitmap member.
10643 * linux-low.c (use_linux_regsets): New macro.
10644 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
10645 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
10646 (linux_register_in_regsets): New function.
10647 (usr_fetch_inferior_registers): Skip registers covered by
10648 regsets.
10649 (usr_store_inferior_registers): Likewise.
10650 (usr_fetch_inferior_registers): New macro.
10651 (usr_store_inferior_registers): Likewise.
10652 (linux_fetch_registers): Handle mixed regset/non-regset targets.
10653 (linux_store_registers): Likewise.
10654 * linux-mips-low.c (init_registers_mips_dsp_linux): New
10655 prototype.
10656 (init_registers_mips64_dsp_linux): Likewise.
10657 (init_registers_mips_linux): New macro.
10658 (init_registers_mips_dsp_linux): Likewise.
10659 (mips_dsp_num_regs): Likewise.
10660 (DSP_BASE, DSP_CONTROL): New fallback macros.
10661 (mips_base_regs): New macro.
10662 (mips_regmap): Use it. Fix the size.
10663 (mips_dsp_regmap): New variable.
10664 (mips_dsp_regset_bitmap): Likewise.
10665 (mips_arch_setup): New function.
10666 (mips_cannot_fetch_register): Use the_low_target.regmap rather
10667 than mips_regmap.
10668 (mips_cannot_store_register): Likewise.
10669 (the_low_target): Update .arch_setup, .num_regs and .regmap
10670 initializers. Add .regset_bitmap initializer.
10671 * linux-arm-low.c (the_low_target): Add .regset_bitmap
10672 initializer.
10673 * linux-bfin-low.c (the_low_target): Likewise.
10674 * linux-cris-low.c (the_low_target): Likewise.
10675 * linux-crisv32-low.c (the_low_target): Likewise.
10676 * linux-ia64-low.c (the_low_target): Likewise.
10677 * linux-m32r-low.c (the_low_target): Likewise.
10678 * linux-m68k-low.c (the_low_target): Likewise.
10679 * linux-ppc-low.c (the_low_target): Likewise.
10680 * linux-s390-low.c (the_low_target): Likewise.
10681 * linux-sh-low.c (the_low_target): Likewise.
10682 * linux-sparc-low.c (the_low_target): Likewise.
10683 * linux-tic6x-low.c (the_low_target): Likewise.
10684 * linux-x86-low.c (the_low_target): Likewise.
10685 * linux-xtensa-low.c (the_low_target): Likewise.
10686 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
10687 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
10688 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
10689 srv_xmlfiles.
10690 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
10691 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
10692
10693 2012-02-29 Yao Qi <yao@codesourcery.com>
10694 Pedro Alves <palves@redhat.com>
10695
10696 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
10697 `step_over_finished' is true.
10698
10699 2012-02-27 Pedro Alves <palves@redhat.com>
10700
10701 * linux-low.c (pid_is_stopped): Delete, moved to common/.
10702 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
10703
10704 2012-02-27 Pedro Alves <palves@redhat.com>
10705
10706 PR server/9684
10707 * linux-low.c (pid_is_stopped): New.
10708 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
10709
10710 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
10711
10712 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
10713 of conditions.
10714
10715 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
10716
10717 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
10718
10719 2012-02-24 Luis Machado <lgustavo@codesourcery>
10720
10721 * server.c (handle_query): Advertise support for target-side
10722 breakpoint condition evaluation.
10723 (process_point_options): New function.
10724 (process_serial_event): When inserting a breakpoint, check for
10725 a target-side condition that should be evaluated.
10726
10727 * mem-break.c: Include regcache.h and ax.h.
10728 (point_cond_list_t): New data structure.
10729 (breakpoint) <cond_list>: New field.
10730 (find_gdb_breakpoint_at): Make non-static.
10731 (delete_gdb_breakpoint_at): Clear any target-side
10732 conditions.
10733 (clear_gdb_breakpoint_conditions): New function.
10734 (add_condition_to_breakpoint): Likewise.
10735 (add_breakpoint_condition): Likewise.
10736 (gdb_condition_true_at_breakpoint): Likewise.
10737 (gdb_breakpoint_here): Return result directly instead
10738 of going through a local variable.
10739
10740 * mem-break.h (find_gdb_breakpoint_at): New prototype.
10741 (clear_gdb_breakpoint_conditions): Likewise.
10742 (add_breakpoint_condition): Likewise.
10743 (gdb_condition_true_at_breakpoint): Likewise.
10744
10745 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
10746 (need_step_over_p): Take target-side breakpoint condition into
10747 consideration.
10748
10749 2012-02-24 Luis Machado <lgustavo@codesourcery>
10750
10751 * server.h: Include tracepoint.h.
10752 (agent_mem_read, agent_get_trace_state_variable_value,
10753 agent_set_trace_state_variable_value,
10754 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
10755 get_set_tsv_func_addr): New prototypes.
10756
10757 * ax.h: New include file.
10758 * ax.c: New source file.
10759
10760 * tracepoint.c: Include ax.h.
10761 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
10762 agent_expr, eval_result_type): Move to ax.h.
10763 (parse_agent_expr): Rename to ...
10764 (gdb_parse_agent_expr): ... this, make it non-static and move
10765 to ax.h.
10766 (unparse_agent_expr) Rename to ...
10767 (gdb_unparse_agent_expr): ... this, make it non-static and move
10768 to ax.h.
10769 (eval_agent_expr): Rename to ...
10770 (eval_tracepoint_agent_expr): ... this.
10771 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
10772 forward declarations.
10773 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
10774 (agent_get_trace_state_variable_value): New function.
10775 (agent_set_trace_state_variable_value): New function.
10776 (cmd_qtdp): Call gdb_parse_agent_expr (...).
10777 (response_tracepoint): Call gdb_unparse_agent_expr (...).
10778 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
10779 (condition_true_at_tracepoint): Likewise.
10780 (parse_agent_expr): Rename to ...
10781 (gdb_parse_agent_expr): ... this and move to ax.c.
10782 (unparse_agent_expr): Rename to ...
10783 (gdb_unparse_agent_expr): ... this and move to ax.c.
10784 (gdb_agent_op_name): Move to ax.c.
10785 (eval_agent_expr): Rename to ...
10786 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
10787 and move to ax.c.
10788 (eval_tracepoint_agent_expr): New function.
10789 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
10790 non-static.
10791 (current_insn_ptr, emit_error, struct bytecode_address): Move to
10792 ax.c.
10793 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
10794 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
10795 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
10796 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
10797 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
10798 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
10799 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
10800 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
10801 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
10802 (compile_bytecodes): Remove forward declaration.
10803 (is_goto_target): Move to ax.c.
10804 (compile_bytecodes): Move to ax.c and call
10805 agent_get_trace_state_variable_value (...) and
10806 agent_set_trace_state_variable_value (...).
10807
10808 * Makefile.in: Update ax.c and IPA dependencies.
10809
10810 2012-02-24 Pedro Alves <palves@redhat.com>
10811
10812 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
10813 (cmd_bigqtbuffer_circular): ... this. Only handle
10814 'QTBuffer:circular:'.
10815 (handle_tracepoint_general_set): Adjust.
10816
10817 2012-02-16 Yao Qi <yao@codesourcery.com>
10818
10819 * inferiors.c: Move code to ...
10820 * dll.c: .... here. New.
10821 * server.h: Declare clear_dlls.
10822 * Makefile.in (SFILES): Add dll.c.
10823 (OBS): Add dll.o
10824 (dll.o): New rule.
10825
10826 2012-02-11 Yao Qi <yao@codesourcery.com>
10827
10828 * server.c: (handle_monitor_command): Add a new parameter
10829 `own_buf'.
10830 (handle_query): Update caller.
10831
10832 2012-02-09 Joel Brobecker <brobecker@adacore.com>
10833
10834 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
10835 * configure, config.in: Regenerate.
10836 * hostio.c: Provide an alternate implementation if HAVE_READLINK
10837 is not defined.
10838
10839 2012-02-02 Pedro Alves <palves@redhat.com>
10840
10841 Try SIGKILL first, then PTRACE_KILL.
10842 * linux-low.c (linux_kill_one_lwp): New.
10843 (linux_kill_one_lwp): Rename to ...
10844 (kill_one_lwp_callback): ... this. Use the new
10845 linux_kill_one_lwp.
10846
10847 2012-02-02 Pedro Alves <palves@redhat.com>
10848
10849 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
10850 inferior.
10851
10852 2012-01-27 Pedro Alves <palves@redhat.com>
10853
10854 * linux-low.c (linux_child_pid_to_exec_file): Delete.
10855 (elf_64_file_p): Make static.
10856 (linux_pid_exe_is_elf_64_file): New.
10857 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
10858 Delete declarations.
10859 (linux_pid_exe_is_elf_64_file): Declare.
10860 * linux-x86-low.c (x86_arch_setup): Use
10861 linux_pid_exe_is_elf_64_file.
10862
10863 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
10864
10865 * linux-low.c (linux_wait_for_event_1): Rename to ...
10866 (linux_wait_for_event): ... here and merge it with former
10867 linux_wait_for_event - new variable wait_ptid, use it.
10868 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
10869
10870 2012-01-23 Pedro Alves <palves@redhat.com>
10871
10872 * server.c (main): Avoid yet another case of infinite loop while
10873 detaching/killing after a longjmp.
10874
10875 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
10876
10877 Code cleanup.
10878 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
10879
10880 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
10881
10882 * hostio.c (handle_readlink): New function.
10883 (handle_vFile): Call it to handle "vFile:readlink" packets.
10884
10885 2012-01-20 Pedro Alves <palves@redhat.com>
10886 Ulrich Weigand <ulrich.weigand@linaro.org>
10887
10888 * server.c (handle_v_requests): Only support vAttach and vRun to
10889 start multiple processes when in extended protocol mode.
10890
10891 2012-01-17 Pedro Alves <palves@redhat.com>
10892
10893 * tracepoint.c (initialize_tracepoint): Use mmap instead of
10894 memalign plus mprotect to allocate the scratch buffer.
10895
10896 2012-01-13 Pedro Alves <palves@redhat.com>
10897
10898 * server.c (attach_inferior): Clear `cont_thread'.
10899
10900 2012-01-13 Pedro Alves <palves@redhat.com>
10901
10902 * server.c (main): Avoid infinite loop while detaching/killing
10903 after a longjmp.
10904
10905 2012-01-09 Doug Evans <dje@google.com>
10906
10907 * server.c (start_inferior): Set last_ptid in --wrapper case.
10908
10909 2012-01-06 Yao Qi <yao@codesourcery.com>
10910
10911 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
10912 defined.
10913 [IN_PROCESS_AGENT] (debug_agent): New global variable.
10914
10915 2012-01-04 Yao Qi <yao@codesourcery.com>
10916
10917 * tracepoint.c (cmd_qtdp): Print debug message
10918 for static tracepoint.
10919
10920 2012-01-04 Yao Qi <yao@codesourcery.com>
10921
10922 * tracepoint.c (trace_vdebug): Differentiate debug message
10923 between gdbserver and IPA.
10924
10925 2012-01-03 Yao Qi <yao@codesourcery.com>
10926
10927 * tracepoint.c (tracepoint_was_hit): Don't collect for
10928 static tracepoint.
10929
10930 2012-01-02 Joel Brobecker <brobecker@adacore.com>
10931
10932 * terminal.h: Reformat copyright header.
10933
10934 2012-01-02 Joel Brobecker <brobecker@adacore.com>
10935
10936 * server.c (gdbserver_version): Update copyright year.
10937 * gdbreplay.c (gdbreplay_version): Likewise.
10938
10939 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
10940
10941 * linux-low.c (linux_create_inferior): Put empty if clause for write.
10942
10943 Revert:
10944 2011-12-18 Hui Zhu <teawater@gmail.com>
10945 * linux-low.c (linux_create_inferior): Save return value to ret.
10946
10947 2011-12-18 Hui Zhu <teawater@gmail.com>
10948
10949 * linux-low.c (linux_create_inferior): Save return value to ret.
10950
10951 2011-12-16 Doug Evans <dje@google.com>
10952
10953 * linux-low.c (linux_create_inferior): If stdio connection,
10954 redirect stdin from /dev/null, stdout to stderr.
10955 * remote-utils.c (remote_is_stdio): New static global.
10956 (remote_connection_is_stdio): New function.
10957 (remote_prepare): Handle stdio connection.
10958 (remote_open): Ditto.
10959 (remote_close): Don't close stdin for stdio connections.
10960 (read_prim,write_prim): New functions. Replace all calls to
10961 read/write to these.
10962 * server.c (main): Watch for "-" argument. Move call to
10963 remote_prepare before start_inferior.
10964 * server.h (STDIO_CONNECTION_NAME): New macro.
10965 (remote_connection_is_stdio): Declare.
10966
10967 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
10968 in debugging output.
10969
10970 2011-12-15 Yao Qi <yao@codesourcery.com>
10971
10972 * tracepoint.c: Include sys/syscall.h.
10973 (gdb_ust_thread): Remove preprocessor conditional.
10974
10975 2011-12-14 Pedro Alves <pedro@codesourcery.com>
10976
10977 * linux-low.c (linux_detach_one_lwp): Call
10978 the_low_target.prepare_to_resume before detaching.
10979
10980 2011-12-14 Yao Qi <yao@codesourcery.com>
10981
10982 * tracepoint.c (gdb_ust_thread): Don't ignore return value
10983 of write.
10984
10985 2011-12-14 Yao Qi <yao@codesourcery.com>
10986
10987 * i386-low.c (i386_low_stopped_data_address): Initialize local
10988 variable `control'.
10989
10990 2011-12-13 Pedro Alves <pedro@codesourcery.com>
10991
10992 PR remote/13492
10993
10994 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
10995 DR_CONTROL unless necessary. Extend comments.
10996 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
10997 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
10998
10999 2011-12-13 Yao Qi <yao@codesourcery.com>
11000
11001 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11002 macros.
11003 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11004
11005 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11006
11007 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11008 Print new debug message for such case.
11009
11010 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11011
11012 Fix overlapping memcpy.
11013 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11014 the read_inferior_memory transfer.
11015 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11016 write_inferior_memory transfer.
11017 (set_fast_tracepoint_jump): New variable buf. Use it for the
11018 read_inferior_memory and write_inferior_memory transfers.
11019 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11020 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11021 Use it for the write_inferior_memory transfer.
11022 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11023 buffers.
11024
11025 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11026
11027 * linux-low.c (fetch_register, store_register): Make code
11028 consistent, fix formatting.
11029
11030 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11031
11032 * linux-low.c (usr_store_inferior_registers): Factor out code
11033 to handle individual registers into...
11034 (store_register): ... this new function.
11035
11036 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11037
11038 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11039 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11040 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11041 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11042 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11043 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11044 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11045 (srv_xmlfiles): Add new XML files.
11046
11047 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11048 and <sys/uio.h>.
11049 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11050 (init_registers_s390_linux32v1): Add prototype.
11051 (init_registers_s390_linux32v2): Likewise.
11052 (init_registers_s390_linux64v1): Likewise.
11053 (init_registers_s390_linux64v2): Likewise.
11054 (init_registers_s390x_linux64v1): Likewise.
11055 (init_registers_s390x_linux64v2): Likewise.
11056 (s390_num_regs): Increment to 52.
11057 (s390_regmap): Add orig_r2 register.
11058 (s390_num_regs_3264): Increment to 68.
11059 (s390_regmap_3264): Add orig_r2 register.
11060 (s390_collect_ptrace_register): Handle orig_r2 register.
11061 (s390_supply_ptrace_register): Likewise.
11062 (s390_fill_last_break): New function.
11063 (s390_store_last_break): Likewise.
11064 (s390_fill_system_call): New function.
11065 (s390_store_system_call): Likewise.
11066 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11067 register sets.
11068 (s390_check_regset): New function.
11069 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11070 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11071 Update target_regsets for available register sets.
11072
11073 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11074 Jan Kratochvil <jan.kratochvil@redhat.com>
11075
11076 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11077 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11078 New.
11079 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11080 * linux-low.h (struct process_info_private): New member r_debug.
11081 * server.c (handle_qxfer_libraries): Call
11082 the_target->qxfer_libraries_svr4.
11083 (handle_qxfer_libraries_svr4): New function.
11084 (qxfer_packets): New entry "libraries-svr4".
11085 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11086 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11087 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11088 PACKET_qXfer_libraries_svr4.
11089
11090 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11091
11092 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11093 PSW address/mask between 8-byte and 16-byte formats.
11094 (s390_supply_ptrace_register): Likewise.
11095 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11096 basic addressing mode bit.
11097
11098 2011-11-24 Stan Shebs <stan@codesourcery.com>
11099
11100 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11101
11102 2011-11-17 Stan Shebs <stan@codesourcery.com>
11103
11104 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11105 (tracing_start_time): New global.
11106 (tracing_stop_time): New global.
11107 (tracing_user_name): New global.
11108 (tracing_notes): New global.
11109 (tracing_stop_note): New global.
11110 (cmd_qtstart): Set traceframe_usage, start_time.
11111 (stop_tracing): Set stop_time.
11112 (cmd_qtstatus): Report additional status.
11113 (cmd_qtp): New function.
11114 (handle_tracepoint_query): Call it.
11115 (cmd_qtnotes): New function.
11116 (handle_tracepoint_general_set): Call it.
11117 (get_timestamp): Rename from tsv_get_timestamp.
11118
11119 2011-11-14 Stan Shebs <stan@codesourcery.com>
11120 Kwok Cheung Yeung <kcy@codesourcery.com>
11121
11122 * linux-x86-low.c (small_jump_insn): New.
11123 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11124 trampoline and error message, build a trampoline and issue a small
11125 jump instruction to it.
11126 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11127 trampoline and error message.
11128 (x86_get_min_fast_tracepoint_insn_len): New.
11129 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11130 * linux-low.h (struct linux_target_ops): Add arguments to
11131 install_fast_tracepoint_jump_pad operation, add new operation.
11132 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11133 arguments.
11134 (linux_get_min_fast_tracepoint_insn_len): New function.
11135 (linux_target_op): Add new operation.
11136 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11137 (gdb_trampoline_buffer_end): Ditto.
11138 (gdb_trampoline_buffer_error): Ditto.
11139 (struct ipa_sym_addresses): Add fields for new IPA variables.
11140 (symbol_list): Add entries for new IPA variables.
11141 (struct tracepoint): Add fields to hold the address range of the
11142 trampoline used by the tracepoint.
11143 (trampoline_buffer_head): New static variable.
11144 (trampoline_buffer_tail): Ditto.
11145 (claim_trampoline_space): New function.
11146 (have_fast_tracepoint_trampoline_buffer): New function.
11147 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11148 structure.
11149 (install_fast_tracepoint): Ditto, also add error buffer argument.
11150 (cmd_qtminftpilen): New function.
11151 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11152 (fast_tracepoint_from_trampoline_address): New function.
11153 (fast_tracepoint_collecting): Handle trampoline as part of jump
11154 pad space.
11155 (set_trampoline_buffer_space): New function.
11156 (initialize_tracepoint): Initialize new IPA variables.
11157 * target.h (struct target_ops): Add arguments to
11158 install_fast_tracepoint_jump_pad operation, add new
11159 get_min_fast_tracepoint_insn_len operation.
11160 (target_get_min_fast_tracepoint_insn_len): New.
11161 (install_fast_tracepoint_jump_pad): Add arguments.
11162 * server.h (IPA_BUFSIZ): Define.
11163 * linux-i386-ipa.c: Include extra header files.
11164 (initialize_fast_tracepoint_trampoline_buffer): New function.
11165 (initialize_low_tracepoint): Call it.
11166 * server.h (set_trampoline_buffer_space): Declare.
11167 (claim_trampoline_space): Ditto.
11168 (have_fast_tracepoint_trampoline_buffer): Ditto.
11169
11170 2011-11-14 Yao Qi <yao@codesourcery.com>
11171
11172 * server.c (handle_query): Handle InstallInTrace for qSupported.
11173 * tracepoint.c (add_tracepoint): Sort list.
11174 (install_tracepoint, download_tracepoint): New.
11175 (cmd_qtdp): Call them to install and download tracepoints.
11176 (sort_tracepoints): Removed.
11177 (cmd_qtstart): Update.
11178
11179 2011-11-14 Yao Qi <yao@codesourcery.com>
11180
11181 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11182 * mem-break.h: Declare.
11183 * tracepoint.c (cmd_qtstart): Move some code to ...
11184 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11185 New.
11186 (download_tracepoints): Move some code to ...
11187 (download_tracepoint_1): ... here. New.
11188
11189 2011-11-08 Yao Qi <yao@codesourcery.com>
11190
11191 * remote-utils.c (relocate_instruction): A comment fix.
11192
11193 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11194
11195 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11196 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11197 dr_status_mirror and dr_control_mirror from debug_reg_state.
11198 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11199 (i386_initial_stuff): Remove use of deleted globals.
11200 (i386_get_thread_context, i386_set_thread_context,
11201 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11202 from debug_reg_state.
11203
11204 2011-11-05 Yao Qi <yao@codesourcery.com>
11205
11206 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11207 address as TPOINT's.
11208
11209 2011-11-02 Stan Shebs <stan@codesourcery.com>
11210
11211 * tracepoint.c (agent_mem_read_string): New function.
11212 (eval_agent_expr): Call it for tracenz.
11213 * server.c (handle_query): Report support for tracenz.
11214
11215 2011-11-02 Yao Qi <yao@codesourcery.com>
11216
11217 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11218
11219 2011-11-02 Yao Qi <yao@codesourcery.com>
11220
11221 * target.h: Fix a typo in comment.
11222
11223 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11224
11225 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11226 clobber the breakpoints' shadows with fast tracepoint jumps.
11227 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11228 * target.c (write_inferior_memory): Also pass MYADDR down to
11229 check_mem_write.
11230
11231 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11232
11233 * configure.ac: Check support for personality routine.
11234 * configure: Regenerate.
11235 * config.in: Likewise.
11236 * linux-low.c: Include <sys/personality.h>.
11237 Define ADDR_NO_RANDOMIZE if necessary.
11238 (linux_create_inferior): Disable address space randomization when
11239 forking inferior, if requested.
11240 (linux_supports_disable_randomization): New function.
11241 (linux_target_ops): Install it.
11242 * server.h (disable_randomization): Declare.
11243 * server.c (disable_randomization): New global variable.
11244 (handle_general_set): Handle QDisableRandomization.
11245 (handle_query): Likewise for qSupported.
11246 (main): Support --disable-randomization and --no-disable-randomization
11247 command line arguments.
11248 * target.h (struct target_ops): Add supports_disable_randomization.
11249 (target_supports_disable_randomization): New macro.
11250
11251 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11252
11253 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11254 ifdef check.
11255 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11256 [!PT_GETDSBT] (target_loadmap): New definition.
11257 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11258 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11259 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11260 and PT_GETDSBT to LINUX_LOADMAP.
11261 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11262 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11263
11264 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11265
11266 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11267 (arm_linux_hwbp_cap): New static variable.
11268 (arm_linux_get_hwbp_cap): Replace by ...
11269 (arm_linux_init_hwbp_cap): ... this new function.
11270 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11271 (arm_linux_get_hw_watchpoint_count): Likewise.
11272 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11273 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11274 (arm_prepare_to_resume): Use perror_with_name instead of error.
11275
11276 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11277
11278 * linux-arm-low.c: Include <signal.h>.
11279 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11280 (struct arm_linux_hwbp_cap): New data type.
11281 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11282 (struct arm_linux_hw_breakpoint): New data type.
11283 (MAX_BPTS, MAX_WPTS): Define.
11284 (struct arch_process_info, struct arch_lwp_info): New data types.
11285 (arm_linux_get_hwbp_cap): New function.
11286 (arm_linux_get_hw_breakpoint_count): Likewise.
11287 (arm_linux_get_hw_watchpoint_count): Likewise.
11288 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11289 (arm_hwbp_control_initialize): Likewise.
11290 (arm_hwbp_control_is_enabled): Likewise.
11291 (arm_hwbp_control_is_initialized): Likewise.
11292 (arm_hwbp_control_disable): Likewise.
11293 (arm_linux_hw_breakpoint_equal): Likewise.
11294 (arm_linux_hw_point_initialize): Likewise.
11295 (struct update_registers_data): New data structure.
11296 (update_registers_callback: New function.
11297 (arm_insert_point): Likewise.
11298 (arm_remove_point): Likewise.
11299 (arm_stopped_by_watchpoint): Likewise.
11300 (arm_stopped_data_address): Likewise.
11301 (arm_new_process): Likewise.
11302 (arm_new_thread): Likewise.
11303 (arm_prepare_to_resume): Likewise.
11304 (the_low_target): Register arm_insert_point, arm_remove_point,
11305 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11306 arm_new_thread, and arm_prepare_to_resume.
11307
11308 2011-09-15 Stan Shebs <stan@codesourcery.com>
11309
11310 * server.h (struct emit_ops): Add compare-goto fields.
11311 * tracepoint.c (gdb_agent_op_sizes): New table.
11312 (emit_eq_goto): New function.
11313 (emit_ne_goto): New function.
11314 (emit_lt_goto): New function.
11315 (emit_le_goto): New function.
11316 (emit_gt_goto): New function.
11317 (emit_ge_goto): New function.
11318 (is_goto_target): New function.
11319 (compile_bytecodes): Recognize special cases of compare-goto
11320 combinations and call specialized emitters for them.
11321 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11322 (amd64_emit_ne_goto): New function.
11323 (amd64_emit_lt_goto): New function.
11324 (amd64_emit_le_goto): New function.
11325 (amd64_emit_gt_goto): New function.
11326 (amd64_emit_ge_goto): New function.
11327 (amd64_emit_ops): Add the new functions.
11328 (i386_emit_eq_goto): New function.
11329 (i386_emit_ne_goto): New function.
11330 (i386_emit_lt_goto): New function.
11331 (i386_emit_le_goto): New function.
11332 (i386_emit_gt_goto): New function.
11333 (i386_emit_ge_goto): New function.
11334 (i386_emit_ops): Add the new functions.
11335
11336 2011-09-08 Stan Shebs <stan@codesourcery.com>
11337
11338 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11339 (i386_emit_epilogue): Restore %ebx.
11340
11341 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11342
11343 * server.c (step_thread): Remove definition.
11344 (process_serial_event): Don't handle Hs.
11345 * server.h (step_thread): Remove declaration.
11346 * target.c (set_desired_inferior): Remove use of step_thread.
11347
11348 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11349
11350 * linux-low.c: Include linux-procfs.h.
11351 (linux_attach_lwp_1): Update comments.
11352 (linux_attach): Scan for existing threads when attaching to a
11353 process that is the tgid.
11354 * Makefile.in: Update dependencies.
11355
11356 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11357
11358 * configure.srv: Add linux-procfs.o dependencies.
11359
11360 2011-08-14 Yao Qi <yao@codesourcery.com>
11361
11362 * target.h (struct target_ops): Fix indent.
11363 * win32-low.c (win32_target_ops): Fix comment.
11364
11365 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11366 Yao Qi <yao@codesourcery.com>
11367
11368 * Makefile.in (clean): Remove tic6x-*.c files.
11369 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11370 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11371 (tic6x-c64xp-linux.c): Likewise.
11372 * configure.srv: Add support for tic6x-*-uclinux.
11373 * linux-tic6x-low.c: New.
11374 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11375
11376 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11377 Yao Qi <yao@codesourcery.com>
11378
11379 * target.h (struct target_ops): Add read_loadmap.
11380 * linux-low.c (struct target_loadseg): New type.
11381 (struct target_loadmap): New type.
11382 (linux_read_loadmap): New function.
11383 (linux_target_ops): Add linux_read_loadmap.
11384 * server.c (handle_query): Support qXfer:fdpic:read packet.
11385 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11386 to NULL.
11387
11388 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11389
11390 * win32-low.c: Include <stdint.h>.
11391
11392 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11393
11394 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11395 to the inferior here.
11396 (i386_remove_aligned_watchpoint): Ditto.
11397 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11398 fit part of the watchpoint in the debug registers.
11399 (i386_update_inferior_debug_regs): New.
11400 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11401 registers, and only update the inferior on success.
11402 (i386_low_remove_watchpoint): Ditto.
11403
11404 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11405
11406 * linux-low.c (compare_ints, unique, list_threads, show_process,
11407 linux_core_of_thread): Delete.
11408 (linux_target_ops): Change linux_core_of_thread to
11409 linux_common_core_of_thread.
11410 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11411 * utils.c (malloc_failure): Change type of argument.
11412 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11413 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11414 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11415 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11416 (IPA_OBJS): Add common-utils-ipa.o.
11417 (ptid_h, linux_osdata_h): New macros.
11418 (server_h): Add common/common-utils.h, common/xml-utils.h,
11419 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11420 common/ptid.h.
11421 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11422 ptid.o, buffer.o): New rules.
11423 (linux-low.o): Add common/linux-osdata.h as a dependency.
11424 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11425 * configure.ac: Add AC_HEADER_DIRENT check.
11426 * config.in: Regenerate.
11427 * configure: Regenerate.
11428 * remote-utils.c (xml_escape_text): Delete.
11429 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11430 buffer_xml_printf): Move to common/buffer.c.
11431 * server.c (main): Remove call to initialize_inferiors.
11432 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11433 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11434 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11435 internal_error, gdb_assert, gdb_assert_fail): Delete.
11436 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11437 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11438 common/buffer.h.
11439 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11440 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11441 initialize_inferiors): Delete.
11442
11443 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11444
11445 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11446 symbol error.
11447
11448 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11449
11450 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11451 assertion.
11452 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11453
11454 2011-05-26 Yao Qi <yao@codesourcery.com>
11455
11456 * Makefile.in (thread-db.o): Track dependence to
11457 common/gdb_thread_db.h.
11458 * thread-db.c: include gdb_thread_db.h from right place.
11459
11460 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11461
11462 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11463 __FILE__ and __LINE__ to internal_error.
11464
11465 2011-05-13 Doug Evans <dje@google.com>
11466
11467 * thread-db.c (try_thread_db_load_from_sdir): New function.
11468 (try_thread_db_load_from_dir): New function.
11469 (thread_db_load_search): Handle $sdir, ignore $pdir.
11470 Remove trying of system directories if search of
11471 libthread-db-search-path fails, that is now done via $sdir.
11472
11473 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11474
11475 * server.c (handle_query): Add EnableDisableTracepoints to the list
11476 of supported features.
11477 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11478 tracepoints.
11479 (cmd_qtenable_disable): New.
11480 (cmd_qtstart): Install tracepoints even if disabled.
11481 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11482 receiving a QTEnable or QTDisable packet.
11483 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11484 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11485 tracepoints.
11486 (gdb_probe): Skip data collection if static tracepoint is disabled.
11487
11488 2011-05-10 Doug Evans <dje@google.com>
11489
11490 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11491
11492 2011-05-04 Doug Evans <dje@google.com>
11493
11494 * linux-low.c (linux_join): Skip process lookup.
11495 * spu-low.c (spu_join): Ditto.
11496 * server.c (join_inferiors_callback): Delete.
11497 (process_serial_event): For 'D' packet (detach) call join_inferior
11498 directly.
11499
11500 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11501
11502 * README: Don't mention xscale*-*-linux*.
11503 * configure.srv (xscale*-*-linux*): Don't handle target.
11504
11505 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11506
11507 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11508 casting pointers.
11509 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11510 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11511 (i386_emit_void_call_2): Likewise.
11512
11513 2011-04-26 Yao Qi <yao@codesourcery.com>
11514
11515 * linux-low.c: Move common macros to linux-ptrace.h.
11516 Include linux-ptrace.h.
11517 * Makefile.in (linux_ptrace_h): New.
11518 (linux-low.o): Depends on linux-ptrace.h.
11519
11520 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11521
11522 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11523 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11524 (remote_prepare): New function with most of the TCP code from ...
11525 (remote_open): ... here. Detect PORT here unconditionally. Move also
11526 setting transport_is_reliable.
11527 * server.c (run_once): New variable.
11528 (gdbserver_usage): Document it.
11529 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11530 the first run if RUN_ONCE.
11531 * server.h (run_once, remote_prepare): New declarations.
11532
11533 2011-04-19 Tom Tromey <tromey@redhat.com>
11534
11535 * win32-low.c (handle_load_dll): Remove duplicate "the".
11536
11537 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11538
11539 Remove support for old Cygwin 1.5 versions.
11540 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11541 function to avoid warning.
11542 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11543 warning.
11544
11545 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11546
11547 * gdbserver/server.h (Macro _): Define it if not available.
11548
11549 2011-03-14 Michael Snyder <msnyder@vmware.com>
11550
11551 * hostio.c (handle_close): Remove unnecessary null test.
11552
11553 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11554
11555 * Makefile.in (maintainer-clean realclean distclean): Remove
11556 "make ... subdir_do" command.
11557
11558 2011-03-10 Michael Snyder <msnyder@vmware.com>
11559
11560 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11561
11562 * server.c (handle_v_run): Free alloced buffer on early return.
11563
11564 2011-03-09 Yao Qi <yao@codesourcery.com>
11565
11566 Revert:
11567 2011-03-04 Yao Qi <yao@codesourcery.com>
11568
11569 * Makefile.in: Remove GNU make feature --directory.
11570
11571 2011-03-05 Yao Qi <yao@codesourcery.com>
11572
11573 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11574 (subdir_do): New make target. Copied from gdb/Makefile.
11575 (maintainer-clean, realclean, distclean, clean): Call corresponding
11576 make targets in common/Makefile.
11577
11578 2011-02-11 Yao Qi <yao@codesourcery.com>
11579
11580 * configure.ac: Call AC_PROG_RANLIB.
11581 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11582 * configure: Regenerate.
11583
11584 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
11585
11586 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
11587
11588 2011-03-06 Yao Qi <yao@codesourcery.com>
11589
11590 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
11591
11592 2011-03-05 Yao Qi <yao@codesourcery.com>
11593
11594 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
11595 (subdir_do): New make target. Copied from gdb/Makefile.
11596 (maintainer-clean, realclean, distclean, clean): Call corresponding
11597 make targets in common/Makefile.
11598
11599 2011-03-04 Yao Qi <yao@codesourcery.com>
11600
11601 * Makefile.in: Remove GNU make feature --directory.
11602
11603 2011-03-04 Michael Snyder <msnyder@vmware.com>
11604
11605 * server.c (queue_stop_reply): Call xmalloc not malloc.
11606
11607 2011-03-02 Michael Snyder <msnyder@vmware.com>
11608
11609 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
11610
11611 2011-02-28 Michael Snyder <msnyder@vmware.com>
11612
11613 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
11614 (cmd_qtframe): Ditto.
11615 (cmd_qtbuffer): Ditto.
11616 (cmd_bigqtbuffer): Ditto.
11617
11618 * utils.c (decimal2str): Initialize 'width' to nine, then
11619 don't mess with it.
11620
11621 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
11622
11623 * hostio.c (require_data): Free *data, not data.
11624
11625 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11626
11627 * hostio.c (require_data): Use free, not xfree.
11628
11629 2011-02-27 Michael Snyder <msnyder@vmware.com>
11630
11631 * server.c (handle_query): Discard unused value.
11632
11633 * hostio.c (require_data): Free malloc memory before returning
11634 error.
11635
11636 2011-02-26 Michael Snyder <msnyder@vmware.com>
11637
11638 * linux-low.c (list_threads): Call closedir for dirent.
11639
11640 2011-02-27 Michael Snyder <msnyder@vmware.com>
11641
11642 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
11643 a case statement falls through.
11644
11645 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
11646
11647 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
11648 in comparison.
11649
11650 2011-02-26 Michael Snyder <msnyder@vmware.com>
11651
11652 * utils.c (decimal2str): Eliminate dead code and dead param.
11653 (pulongest): Drop dead param from call to decimal2str.
11654 (plongest): Ditto.
11655
11656 2011-02-24 Joel Brobecker <brobecker@adacore.com>
11657
11658 Revert the following patch (not approved yet):
11659 2011-02-21 Hui Zhu <teawater@gmail.com>
11660 * tracepoint.c (tp_printf): New function.
11661 (eval_agent_expr): Handle gdb_agent_op_printf.
11662
11663 2011-02-21 Hui Zhu <teawater@gmail.com>
11664
11665 * tracepoint.c (tp_printf): New function.
11666 (eval_agent_expr): Handle gdb_agent_op_printf.
11667
11668 2011-02-18 Tom Tromey <tromey@redhat.com>
11669
11670 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
11671 (tracepoint.o): Likewise.
11672 * tracepoint.c (enum gdb_agent_op): Use ax.def.
11673 (gdb_agent_op_names): Likewise.
11674
11675 2011-02-18 Tom Tromey <tromey@redhat.com>
11676
11677 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
11678 gdb_agent_op_rot>: New constants.
11679 (gdb_agent_op_names): Add pick and roll.
11680 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
11681 cases.
11682
11683 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
11684
11685 * aclocal.m4: Regenerated with aclocal-1.11.1.
11686
11687 2011-02-14 Pedro Alves <pedro@codesourcery.com>
11688
11689 * server.c (handle_qxfer_traceframe_info): New.
11690 (qxfer_packets): Register "traceframe-info".
11691 (handle_query): Report support for qXfer:traceframe-info:read+.
11692 * tracepoint.c (match_blocktype): New.
11693 (traceframe_find_block_type): Rename to ...
11694 (traceframe_walk_blocks): ... this. Add callback filter argument,
11695 and use it.
11696 (traceframe_find_block_type): New, reimplemented on top of
11697 traceframe_walk_blocks.
11698 (build_traceframe_info_xml): New.
11699 (traceframe_read_info): New.
11700 * server.h (traceframe_read_info): Declare.
11701
11702 2011-02-11 Yao Qi <yao@codesourcery.com>
11703
11704 * configure.ac: Call AC_PROG_RANLIB.
11705 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
11706 * configure: Regenerate.
11707
11708 2011-02-07 Pedro Alves <pedro@codesourcery.com>
11709
11710 * server.c (gdb_read_memory): Change return semantics to allow
11711 partial transfers.
11712 (handle_search_memory_1): Adjust.
11713 (process_serial_event) <'m' packet>: Handle partial transfers.
11714 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
11715
11716 2011-01-28 Pedro Alves <pedro@codesourcery.com>
11717
11718 * regcache.c (init_register_cache): Initialize
11719 regcache->register_status.
11720 (free_register_cache): Release regcache->register_status.
11721 (regcache_cpy): Copy register_status.
11722 (registers_to_string): Print 'x's for unavailable registers.
11723 (supply_register): Mark the register's status valid or
11724 unavailable, depending on whether a buffer was passed in or not.
11725 (supply_register_zeroed): New.
11726 (supply_regblock): Mark the registers' status valid or
11727 unavailable, depending on whether a buffer was passed in or not.
11728 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
11729 (struct regcache): New `register_status' field.
11730 (supply_register_zeroed): Declare.
11731 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
11732 supply_register_zeroed, rather than passing a NULL buffer to
11733 supply_register.
11734 * tracepoint.c (fetch_traceframe_registers): Update comment.
11735
11736 2011-01-28 Pedro Alves <pedro@codesourcery.com>
11737
11738 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
11739 buffer explicit.
11740
11741 2011-01-25 Pedro Alves <pedro@codesourcery.com>
11742
11743 * server.h (decode_xfer_write): Change prototype.
11744 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
11745 and don't extract the annex here.
11746 * server.c (decode_xfer_read): Remove `annex' parameter,
11747 and don't extract the annex here.
11748 (decode_xfer): New.
11749 (struct qxfer): New.
11750 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
11751 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
11752 (handle_qxfer_statictrace): New functions, abstracted out from
11753 handle_query, and made to use the struct qxfer interface.
11754 (handle_threads_qxfer_proper): Rename to ...
11755 (handle_qxfer_threads_proper): ... this.
11756 (handle_threads_qxfer): Rename to ...
11757 (handle_qxfer_threads): ... this. Adjust.
11758 (qxfer_packets): New array.
11759 (handle_qxfer): New function.
11760 (handle_query): Use handle_qxfer.
11761
11762 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
11763
11764 * gdbreplay.c: Shorten lines of >= 80 columns.
11765 * linux-low.c: Ditto.
11766 * linux-ppc-low.c: Ditto.
11767 * linux-s390-low.c: Ditto.
11768 * linux-sparc-low.c: Ditto.
11769 * linux-x86-low.c: Ditto.
11770 * linux-xtensa-low.c: Ditto.
11771 * mem-break.c: Ditto.
11772 * nto-low.c: Ditto.
11773 * regcache.h: Ditto.
11774 * remote-utils.c: Ditto.
11775 * server.c: Ditto.
11776 * server.h: Ditto.
11777 * thread-db.c: Ditto.
11778 * tracepoint.c: Ditto.
11779 * utils.c: Ditto.
11780 * win32-low.h: Ditto.
11781
11782 2011-01-05 Joel Brobecker <brobecker@adacore.com>
11783
11784 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
11785 update.
11786
11787 2011-01-01 Joel Brobecker <brobecker@adacore.com>
11788
11789 * server.c (gdbserver_version): Update copyright year in version
11790 output.
11791 * gdbreplay.c (gdbreplay_version): Ditto.
11792
11793 2010-12-29 Jie Zhang <jie.zhang@analog.com>
11794
11795 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
11796 * linux-bfin-low.c: New file.
11797 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
11798 PT_DATA_ADDR for BFIN targets.
11799 * Makefile.in (SFILES): Add linux-bfin-low.c.
11800 (clean): Remove reg-bfin.c.
11801 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
11802 * README: Mention supported Blackfin targets.
11803
11804 2010-12-23 Mike Frysinger <vapier@gentoo.org>
11805
11806 * .gitignore: New file.
11807
11808 2010-11-16 Mike Frysinger <vapier@gentoo.org>
11809
11810 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
11811
11812 2010-10-22 Jie Zhang <jie@codesourcery.com>
11813
11814 * Makefile.in: Add FLAGS_TO_PASS variable.
11815 (install): Remove dependency of install-only and recursively
11816 invoke make for install-only.
11817
11818 2010-10-04 Doug Evans <dje@google.com>
11819
11820 * Makefile.in (uninstall): Use $(DESTDIR).
11821
11822 2010-09-24 Pedro Alves <pedro@codesourcery.com>
11823
11824 PR gdb/11842
11825
11826 * linux-x86-low.c (compat_siginfo_from_siginfo)
11827 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
11828 si_code is < 0. Check for si_code == SI_TIMER before checking for
11829 si_code < 0.
11830
11831 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11832
11833 * lynx-i386-low.c: New file.
11834 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
11835
11836 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11837
11838 * lynx-low.c (ptrace_request_to_str): Remove handling for
11839 request values that have been removed in LynxOS 5.x.
11840
11841 2010-09-13 Joel Brobecker <brobecker@adacore.com>
11842
11843 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
11844 <ptrace.h>
11845
11846 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
11847
11848 * configure.ac: Add --enable-inprocess-agent option.
11849 * configure: Rebuilt.
11850
11851 2010-09-06 Yao Qi <yao@codesourcery.com>
11852
11853 * linux-low.c (linux_kill): Remove unused variable.
11854 (linux_stabilize_threads): Likewise.
11855 * server.c (start_inferior): Likewise.
11856 (queue_stop_reply_callback): Likewise.
11857 * tracepoint.c (do_action_at_tracepoint): Likewise.
11858
11859 2010-09-06 Yao Qi <yao@codesourcery.com>
11860
11861 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
11862 on return.
11863
11864 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11865
11866 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
11867
11868 2010-09-06 Pedro Alves <pedro@codesourcery.com>
11869
11870 * Makefile.in (install-only): Replace $IPA_DEPFILES with
11871 "$(IPA_DEPFILES)".
11872
11873 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11874
11875 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
11876 gdbserver/lynx-ppc-low.c: New files.
11877 * Makefile.in (lynx_low_h): New variable.
11878 (lynx-low.o, lynx-ppc-low.o): New rules.
11879 * configure.ac: On LynxOS, link with -lnetinet.
11880 * configure.srv: Add handling of powerpc-*-lynxos* targets.
11881 * configure: regenerate.
11882
11883 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11884
11885 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
11886 * configure.ac: Add check for vasprintf and vsnprintf.
11887 * configure, config.in: Regenerate.
11888 * server.h (vasprintf, vsnprintf): Add conditional declarations.
11889
11890 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11891
11892 * gdbreplay.c: Move include of alloca.h up, next to include of
11893 malloc.h.
11894 * server.h: Add include of malloc.h.
11895 * mem-break.c: Remove include of malloc.h.
11896 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
11897
11898 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11899
11900 * Makefile.in (memmem.o): Build with -Wno-error.
11901
11902 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11903
11904 * utils.c (xsnprintf): Make non-static.
11905 * server.h: Add xsnprintf declaration.
11906 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
11907 replace calls to snprintf by calls to xsnprintf throughout.
11908
11909 2010-09-01 Joel Brobecker <brobecker@adacore.com>
11910
11911 * configure.ac: Add configure check for alloca.
11912 * configure, config.in: Regenerate.
11913 * server.h: Include alloca.h if it exists.
11914 * gdbreplay.c: Include alloca.h if it exists.
11915
11916 2010-08-28 Pedro Alves <pedro@codesourcery.com>
11917
11918 * linux-low.c (__SIGRTMIN): Define if not already defined.
11919 (linux_create_inferior): Check for __ANDROID__ rather than
11920 __SIGRTMIN.
11921 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
11922 are already deferred.
11923 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
11924 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
11925 stopped and already has a pending signal to report.
11926 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
11927 a pending signal to report or is moving out of a jump pad.
11928 (linux_init_signals): Check for __ANDROID__ rather than
11929 __SIGRTMIN.
11930
11931 2010-08-28 Pedro Alves <pedro@codesourcery.com>
11932
11933 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
11934 debug_threads check. Avoid a linear search when not doing debug
11935 output.
11936
11937 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11938
11939 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
11940 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
11941 (struct file_handler) <fd>: Change type to gdb_fildes_t.
11942 (process_event): Change local fd's type to gdb_fildes_t.
11943 (create_file_handler): Adjust prototype.
11944 (delete_file_handler): Adjust prototype.
11945 (handle_file_event): Adjust prototype. Use pfildes.
11946 (create_file_event): Adjsut prototype.
11947 * remote-utils.c (remote_desc, listen_desc): Change type to
11948 gdb_fildes_t.
11949 * server.h: New gdb_fildes_t typedef.
11950 [USE_WIN32API]: Include winsock2.h.
11951 (delete_file_handler, add_file_handler): Adjust prototypes.
11952 (pfildes): Declare.
11953 * utils.c (pfildes): New.
11954
11955 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11956
11957 * configure.ac (build_warnings): Add -Wno-char-subscripts.
11958 * configure: Regenerate.
11959
11960 2010-08-27 Pedro Alves <pedro@codesourcery.com>
11961
11962 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
11963 (linux_done_accessing_memory): ... this.
11964 (linux_target_ops): Adjust.
11965 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
11966 * nto-low.c (nto_target_ops): Adjust comment.
11967 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
11968 * spu-low.c (spu_target_ops): Adjust comment.
11969 * target.h (target_ops): Rename unprepare_to_access_memory field
11970 to done_accessing_memory.
11971 (unprepare_to_access_memory): Rename to ...
11972 (done_accessing_memory): ... this.
11973
11974 2010-08-26 Pedro Alves <pedro@codesourcery.com>
11975
11976 * linux-low.c (linux_prepare_to_access_memory): New.
11977 (linux_unprepare_to_access_memory): New.
11978 (linux_target_ops): Install them.
11979 * server.c (read_memory): Rename to ...
11980 (gdb_read_memory): ... this. Use
11981 prepare_to_access_memory/prepare_to_access_memory.
11982 (write_memory): Rename to ...
11983 (gdb_write_memory): ... this. Use
11984 prepare_to_access_memory/prepare_to_access_memory.
11985 (handle_search_memory_1): Adjust.
11986 (process_serial_event): Adjust.
11987 * target.h (struct target_ops): New fields
11988 prepare_to_access_memory and unprepare_to_access_memory.
11989 (prepare_to_access_memory, unprepare_to_access_memory): New.
11990 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
11991 prepare_to_access_memory/prepare_to_access_memory.
11992 * nto-low.c (nto_target_ops): Adjust.
11993 * spu-low.c (spu_target_ops): Adjust.
11994 * win32-low.c (win32_target_ops): Adjust.
11995
11996 2010-08-26 Pedro Alves <pedro@codesourcery.com>
11997
11998 * Makefile.in (WARN_CFLAGS): Get it from configure.
11999 (WERROR_CFLAGS): New.
12000 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12001 * configure.ac: Introduce --enable-werror, which adds -Werror to
12002 the compiler command line. Enabled by default. Disable with
12003 --disable-werror. Add -Wdeclaration-after-statement
12004 Wpointer-arith and -Wformat-nonliteral to warning flags.
12005 * configure: Regenerate.
12006
12007 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12008
12009 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12010
12011 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12012
12013 * gdbreplay.c (remote_error): New.
12014 (gdbchar): New.
12015 (expect): Use gdbchar. Check for error reading from GDB.
12016 Clarify sync error output.
12017 (play): Check for errors writing to GDB.
12018 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12019 * remote-utils.c (getpkt): Check for errors writing to the remote
12020 descriptor.
12021
12022 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12023
12024 * linux-low.c (linux_wait_1): Move non-debugging code out of
12025 `debug_threads' control.
12026
12027 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12028
12029 * linux-low.c (linux_wait_1): Don't set last_status here.
12030 * server.c (push_event, queue_stop_reply_callback): Assert we're
12031 not pushing a TARGET_WAITKIND_IGNORE event.
12032 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12033 (myresume, handle_target_event): Set the thread's last_resume_kind
12034 and last_status from the target returned status.
12035
12036 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12037
12038 PR threads/10729
12039
12040 * linux-x86-low.c (update_debug_registers_callback): New.
12041 (i386_dr_low_set_addr): Use it.
12042 (i386_dr_low_get_addr): New.
12043 (i386_dr_low_set_control): Use update_debug_registers_callback.
12044 (i386_dr_low_get_control): New.
12045 (i386_dr_low_get_status): Adjust.
12046 * linux-low.c (linux_stop_lwp): New.
12047 * linux-low.h (linux_stop_lwp): Declare.
12048
12049 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12050 argument instead of a i386_debug_reg_state.
12051 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12052 a i386_debug_reg_state.
12053 (i386_insert_aligned_watchpoint): Adjust.
12054 (i386_remove_aligned_watchpoint): Adjust.
12055 (i386_low_stopped_data_address): Read the debug registers from the
12056 inferior instead of from the mirrors.
12057 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12058 (i386_dr_low_get_addr): Declare.
12059 (i386_dr_low_get_control): Declare.
12060 (i386_dr_low_get_status): Change prototype.
12061
12062 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12063 (i386_dr_low_get_addr): New.
12064 (i386_dr_low_get_control): New.
12065 (i386_dr_low_get_status): Adjust prototype. Return
12066 dr_status_mirror.
12067 (i386_initial_stuff): Clear dr_status_mirror and
12068 dr_control_mirror.
12069 (i386_get_thread_context): Adjust.
12070 (i386_set_thread_context): Adjust.
12071 (i386_thread_added): Adjust.
12072
12073 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12074
12075 * linux-low.h (linux_thread_area): Delete declaration.
12076
12077 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12078
12079 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12080 after its termination.
12081
12082 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12083
12084 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12085 (gdb_wants_all_stopped): Delete.
12086 (linux_wait_1): Don't call them.
12087 * server.c (handle_v_cont): Tag all threads as want-stopped.
12088 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12089 stopped as "client-wants-stopped".
12090
12091 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12092
12093 * Makefile.in (signals_h): New.
12094 (server_h): Depend on it.
12095 (server.o): Don't depend on $(signals_def).
12096 (signals.o): Depend on $(signals_def).
12097
12098 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12099
12100 * Makefile.in (signals_def): New.
12101 (server_h): Append include/gdb/signals.h and signals_def.
12102 (server.o): Append signals_def.
12103
12104 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12105
12106 * server.c (handle_target_event): Use target_signal_to_host for
12107 resume_info.sig initialization.
12108 * target.h (struct thread_resume) <sig>: New comment.
12109
12110 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12111
12112 * server.c (handle_query): strcpy() the returned string from paddress()
12113 instead of sprintf().
12114 * utils.c (paddress): Return phex_nz().
12115
12116 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12117
12118 * server.c (handle_v_cont): Call mourn_inferior if process
12119 just exited.
12120 (myresume): Likewise.
12121
12122 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12123
12124 Static tracepoints, and integration with UST.
12125
12126 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12127 * mem-break.c (uninsert_all_breakpoints)
12128 (reinsert_all_breakpoints): New.
12129 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12130 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12131 (gdb_agent_ust_loaded, helper_thread_id)
12132 (gdb_agent_helper_thread_id): New macros.
12133 (struct ipa_sym_addresses): Add addr_ust_loaded,
12134 addr_helper_thread_id, addr_cmd_buf.
12135 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12136 (in_process_agent_loaded_ust): New.
12137 (write_e_ust_not_loaded): New.
12138 (maybe_write_ipa_ust_not_loaded): New.
12139 (struct collect_static_trace_data_action): New.
12140 (enum tracepoint_type) <static_tracepoint>: New.
12141 (struct tracepoint) <handle>: Mention static tracepoints.
12142 (struct static_tracepoint_ctx): New.
12143 (CMD_BUF_SIZE): New.
12144 (add_tracepoint_action): Handle static tracepoint actions.
12145 (unprobe_marker_at): New.
12146 (clear_installed_tracepoints): Handle static tracepoints.
12147 (cmd_qtdp): Handle static tracepoints.
12148 (probe_marker_at): New.
12149 (cmd_qtstart): Handle static tracepoints.
12150 (response_tracepoint): Handle static tracepoints.
12151 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12152 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12153 (get_context_regcache): Handle static tracepoints.
12154 (do_action_at_tracepoint): Handle static tracepoint actions.
12155 (traceframe_find_block_type): Handle static trace data blocks.
12156 (traceframe_read_sdata): New.
12157 (download_tracepoints): Download static tracepoint actions.
12158 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12159 (GDB_PROBE_NAME): New.
12160 (ust_ops): New.
12161 (GET_UST_SYM): New.
12162 (USTF): New.
12163 (dlsym_ust): New.
12164 (ust_marker_to_static_tracepoint): New.
12165 (gdb_probe): New.
12166 (collect_ust_data_at_tracepoint): New.
12167 (gdb_ust_probe): New.
12168 (UNIX_PATH_MAX, SOCK_DIR): New.
12169 (gdb_ust_connect_sync_socket): New.
12170 (resume_thread, stop_thread): New.
12171 (run_inferior_command): New.
12172 (init_named_socket): New.
12173 (gdb_ust_socket_init): New.
12174 (cstr_to_hexstr): New.
12175 (next_st): New.
12176 (first_marker, next_marker): New.
12177 (response_ust_marker): New.
12178 (cmd_qtfstm, cmd_qtsstm): New.
12179 (unprobe_marker_at, probe_marker_at): New.
12180 (cmd_qtstmat, gdb_ust_thread): New.
12181 (gdb_ust_init): New.
12182 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12183 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12184 (ST_REGENTRY): New.
12185 (x86_64_st_collect_regmap): New.
12186 (X86_64_NUM_ST_COLLECT_GREGS): New.
12187 (AMD64_RIP_REGNUM): New.
12188 (supply_static_tracepoint_registers): New.
12189 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12190 (ST_REGENTRY): New.
12191 (i386_st_collect_regmap): New.
12192 (i386_NUM_ST_COLLECT_GREGS): New.
12193 (supply_static_tracepoint_registers): New.
12194 * server.c (handle_query): Handle qXfer:statictrace:read.
12195 <qSupported>: Report support for StaticTracepoints, and
12196 qXfer:statictrace:read features.
12197 * server.h (traceframe_read_sdata)
12198 (supply_static_tracepoint_registers): Declare.
12199 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12200 (unpack_varlen_hex): Include in IPA build.
12201 * Makefile.in (ustlibs, ustinc): New.
12202 (IPA_OBJS): Add remote-utils-ipa.o.
12203 ($(IPA_LIB)): Link -ldl and -lpthread.
12204 (UST_CFLAGS): New.
12205 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12206 * config.in, configure: Regenerate.
12207
12208 2010-06-20 Ian Lance Taylor <iant@google.com>
12209 Pedro Alves <pedro@codesourcery.com>
12210
12211 * linux-x86-low.c (always_true): Delete.
12212 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12213 trying to fool the compiler with always_true.
12214
12215 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12216
12217 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12218 conditions in gdbserver.
12219
12220 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12221
12222 * spu-low.c (spu_read_memory): Wrap around local store limit.
12223 (spu_write_memory): Likewise.
12224
12225 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12226
12227 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12228 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12229 LONGEST uses.
12230 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12231 uses.
12232 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12233 uses with LONGEST uses.
12234
12235 2010-06-14 Stan Shebs <stan@codesourcery.com>
12236 Pedro Alves <pedro@codesourcery.com>
12237
12238 Bytecode compiler.
12239
12240 * linux-x86-low.c: Include limits.h.
12241 (add_insns): New.
12242 (always_true): New.
12243 (EMIT_ASM): New.
12244 (EMIT_ASM32): New.
12245 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12246 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12247 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12248 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12249 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12250 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12251 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12252 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12253 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12254 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12255 (amd64_emit_void_call_2): New.
12256 (amd64_emit_ops): New.
12257 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12258 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12259 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12260 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12261 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12262 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12263 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12264 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12265 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12266 (i386_emit_stack_adjust, i386_emit_int_call_1)
12267 (i386_emit_void_call_2): New.
12268 (i386_emit_ops): New.
12269 (x86_emit_ops): New.
12270 (the_low_target): Install x86_emit_ops.
12271 * server.h (struct emit_ops): New.
12272 (get_raw_reg_func_addr): Declare.
12273 (current_insn_ptr, emit_error): Declare.
12274 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12275 (set_trace_state_variable_value): New defines.
12276 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12277 addr_get_trace_state_variable_value and
12278 addr_set_trace_state_variable_value.
12279 (symbol_list): New fields for get_raw_reg,
12280 get_trace_state_variable_value and set_trace_state_variable_value.
12281 (condfn): New typedef.
12282 (struct tracepoint): New field `compiled_cond'.
12283 (do_action_at_tracepoint): Clear compiled_cond.
12284 (get_trace_state_variable_value, set_trace_state_variable_value):
12285 Export in the IPA.
12286 (condition_true_at_tracepoint): If there's a compiled condition,
12287 run that.
12288 (current_insn_ptr, emit_error): New globals.
12289 (struct bytecode_address): New.
12290 (get_raw_reg_func_addr): New.
12291 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12292 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12293 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12294 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12295 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12296 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12297 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12298 (compile_tracepoint_condition, compile_bytecodes): New.
12299 * target.h (emit_ops): Forward declare.
12300 (struct target_ops): New field emit_ops.
12301 (target_emit_ops): New.
12302 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12303 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12304 * linux-low.c (linux_emit_ops): New.
12305 (linux_target_ops): Install it.
12306 * linux-low.h (struct linux_target_ops): New field emit_ops.
12307
12308 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12309
12310 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12311 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12312
12313 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12314 Stan Shebs <stan@codesourcery.com>
12315
12316 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12317 (all): Depend on $(extra_libraries).
12318 (install-only): Install the IPA.
12319 (IPA_OBJS, IPA_LIB): New.
12320 (clean): Remove the IPA lib.
12321 (IPAGENT_CFLAGS): New.
12322 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12323 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12324 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12325 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12326 * configure.ac: Check for atomic builtins support in the compiler.
12327 (IPA_DEPFILES, extra_libraries): Define.
12328 * configure.srv (ipa_obj): Add description.
12329 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12330 (i[34567]86-*-linux*): Set ipa_obj.
12331 (x86_64-*-linux*): Set ipa_obj.
12332 * linux-low.c (stabilizing_threads): New.
12333 (supports_fast_tracepoints): New.
12334 (linux_detach): Stabilize threads before detaching.
12335 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12336 the lwp is either not stabilizing, or is moving out of a jump pad.
12337 (linux_fast_tracepoint_collecting): New.
12338 (maybe_move_out_of_jump_pad): New.
12339 (enqueue_one_deferred_signal): New.
12340 (dequeue_one_deferred_signal): New.
12341 (linux_wait_for_event_1): If moving out of a jump pad, defer
12342 pending signals to later.
12343 (linux_stabilize_threads): New.
12344 (linux_wait_1): Check if threads need moving out of jump pads, and
12345 do it if so.
12346 (stuck_in_jump_pad_callback): New.
12347 (move_out_of_jump_pad_callback): New.
12348 (lwp_running): New.
12349 (linux_resume_one_lwp): Handle moving out of jump pads.
12350 (linux_set_resume_request): Dequeue deferred signals.
12351 (need_step_over_p): Also step over fast tracepoint jumps.
12352 (start_step_over): Also uninsert fast tracepoint jumps.
12353 (finish_step_over): Also reinsert fast tracepoint jumps.
12354 (linux_install_fast_tracepoint_jump): New.
12355 (linux_target_ops): Install linux_stabilize_threads and
12356 linux_install_fast_tracepoint_jump_pad.
12357 * linux-low.h (linux_target_ops) <get_thread_area,
12358 install_fast_tracepoint_jump_pad>: New fields.
12359 (struct lwp_info) <collecting_fast_tracepoint,
12360 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12361 (linux_get_thread_area): Declare.
12362 * linux-x86-low.c (jump_insn): New.
12363 (x86_get_thread_area): New.
12364 (append_insns): New.
12365 (push_opcode): New.
12366 (amd64_install_fast_tracepoint_jump_pad): New.
12367 (i386_install_fast_tracepoint_jump_pad): New.
12368 (x86_install_fast_tracepoint_jump_pad): New.
12369 (the_low_target): Install x86_get_thread_area and
12370 x86_install_fast_tracepoint_jump_pad.
12371 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12372 (struct fast_tracepoint_jump): New.
12373 (fast_tracepoint_jump_insn): New.
12374 (fast_tracepoint_jump_shadow): New.
12375 (find_fast_tracepoint_jump_at): New.
12376 (fast_tracepoint_jump_here): New.
12377 (delete_fast_tracepoint_jump): New.
12378 (set_fast_tracepoint_jump): New.
12379 (uninsert_fast_tracepoint_jumps_at): New.
12380 (reinsert_fast_tracepoint_jumps_at): New.
12381 (set_breakpoint_at): Use write_inferior_memory.
12382 (uninsert_raw_breakpoint): Use write_inferior_memory.
12383 (check_mem_read): Mask out fast tracepoint jumps.
12384 (check_mem_write): Mask out fast tracepoint jumps.
12385 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12386 (set_fast_tracepoint_jump): Declare.
12387 (delete_fast_tracepoint_jump)
12388 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12389 (reinsert_fast_tracepoint_jumps_at): Declare.
12390 * regcache.c: Don't compile many functions when building the
12391 in-process agent library.
12392 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12393 the register buffer in the heap.
12394 (free_register_cache): If the register buffer isn't owned by the
12395 regcache, don't free it.
12396 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12397 pre-existing register caches.
12398 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12399 type.
12400 (convert_ascii_to_int): : Constify `from' parameter type.
12401 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12402 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12403 the needed buffer in-place.
12404 (relocate_instruction): New.
12405 * server.c (handle_query) <qSymbols>: If the target supports
12406 tracepoints, give it a chance of looking up symbols. Report
12407 support for fast tracepoints.
12408 (handle_status): Stabilize threads.
12409 (process_serial_event): Adjust.
12410 * server.h (struct fast_tracepoint_jump): Forward declare.
12411 (struct process_info) <fast_tracepoint_jumps>: New field.
12412 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12413 (decode_X_packet, decode_M_packet): Adjust.
12414 (relocate_instruction): Declare.
12415 (in_process_agent_loaded): Declare.
12416 (tracepoint_look_up_symbols): Declare.
12417 (struct fast_tpoint_collect_status): Declare.
12418 (fast_tracepoint_collecting): Declare.
12419 (force_unlock_trace_buffer): Declare.
12420 (handle_tracepoint_bkpts): Declare.
12421 (initialize_low_tracepoint)
12422 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12423 * target.h (struct target_ops) <stabilize_threads,
12424 install_fast_tracepoint_jump_pad>: New fields.
12425 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12426 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12427 [HAVE_STDINT_H]: Include stdint.h.
12428 (trace_debug_1): Rename to ...
12429 (trace_vdebug): ... this.
12430 (trace_debug): Rename to ...
12431 (trace_debug_1): ... this. Add `level' parameter.
12432 (trace_debug): New.
12433 (ATTR_USED, ATTR_NOINLINE): New.
12434 (IP_AGENT_EXPORT): New.
12435 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12436 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12437 (about_to_request_buffer_space, trace_buffer_is_full)
12438 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12439 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12440 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12441 (traceframe_write_count, traceframes_created)
12442 (trace_state_variables)
12443 New renaming defines.
12444 (struct ipa_sym_addresses): New.
12445 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12446 (symbol_list): New.
12447 (ipa_sym_addrs): New.
12448 (all_tracepoint_symbols_looked_up): New.
12449 (in_process_agent_loaded): New.
12450 (write_e_ipa_not_loaded): New.
12451 (maybe_write_ipa_not_loaded): New.
12452 (tracepoint_look_up_symbols): New.
12453 (debug_threads) [IN_PROCESS_AGENT]: New.
12454 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12455 (UNKNOWN_SIDE_EFFECTS): New.
12456 (stop_tracing): New.
12457 (flush_trace_buffer): New.
12458 (stop_tracing_bkpt): New.
12459 (flush_trace_buffer_bkpt): New.
12460 (read_inferior_integer): New.
12461 (read_inferior_uinteger): New.
12462 (read_inferior_data_pointer): New.
12463 (write_inferior_data_pointer): New.
12464 (write_inferior_integer): New.
12465 (write_inferior_uinteger): New.
12466 (struct collect_static_trace_data_action): Delete.
12467 (enum tracepoint_type): New.
12468 (struct tracepoint) <type>: New field `type'.
12469 <actions_str, step_actions, step_actions_str>: Only include in
12470 GDBserver.
12471 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12472 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12473 (tracepoints): Use IP_AGENT_EXPORT.
12474 (last_tracepoint): Don't include in the IPA.
12475 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12476 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12477 (alloced_trace_state_variables): New.
12478 (trace_state_variables): Use IP_AGENT_EXPORT.
12479 (traceframe_t): Delete unused variable.
12480 (circular_trace_buffer): Don't include in the IPA.
12481 (trace_buffer_start): Delete.
12482 (struct trace_buffer_control): New.
12483 (trace_buffer_free): Delete.
12484 (struct ipa_trace_buffer_control): New.
12485 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12486 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12487 New.
12488 (trace_buffer_ctrl): New.
12489 (TRACE_BUFFER_CTRL_CURR): New.
12490 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12491 Reimplement as macros.
12492 (trace_buffer_wrap): Delete.
12493 (traceframe_write_count, traceframe_read_count)
12494 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12495 (struct tracepoint_hit_ctx) <type>: New field.
12496 (struct fast_tracepoint_ctx): New.
12497 (memory_barrier): New.
12498 (cmpxchg): New.
12499 (record_tracepoint_error): Update atomically in the IPA.
12500 (clear_inferior_trace_buffer): New.
12501 (about_to_request_buffer_space): New.
12502 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12503 updating the same buffer.
12504 (add_tracepoint): Default the tracepoint's type to trap
12505 tracepoint, and orig_size to -1.
12506 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12507 internal variables.
12508 (create_trace_state_variable): New parameter `gdb'. Handle it.
12509 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12510 (cmd_qtdp): Handle fast tracepoints.
12511 (cmd_qtdv): Adjust.
12512 (max_jump_pad_size): New.
12513 (gdb_jump_pad_head): New.
12514 (get_jump_space_head): New.
12515 (claim_jump_space): New.
12516 (sort_tracepoints): New.
12517 (MAX_JUMP_SIZE): New.
12518 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12519 IPA.
12520 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12521 support. Upload fast traceframes, and delete internal IPA
12522 breakpoints.
12523 (stop_tracing_handler): New.
12524 (flush_trace_buffer_handler): New.
12525 (cmd_qtstop): Upload fast tracepoints.
12526 (response_tracepoint): Handle fast tracepoints.
12527 (tracepoint_finished_step): Upload fast traceframes. Set the
12528 tracepoint hit context's tracepoint type.
12529 (handle_tracepoint_bkpts): New.
12530 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12531 type. Add comment about fast tracepoints.
12532 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12533 non-existing action_str field.
12534 (get_context_regcache): Handle fast tracepoints.
12535 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12536 to the regcache.
12537 (fast_tracepoint_from_jump_pad_address): New.
12538 (fast_tracepoint_from_ipa_tpoint_address): New.
12539 (collecting_t): New.
12540 (force_unlock_trace_buffer): New.
12541 (fast_tracepoint_collecting): New.
12542 (collecting): New.
12543 (gdb_collect): New.
12544 (write_inferior_data_ptr): New.
12545 (target_tp_heap): New.
12546 (target_malloc): New.
12547 (download_agent_expr): New.
12548 (UALIGN): New.
12549 (download_tracepoints): New.
12550 (download_trace_state_variables): New.
12551 (upload_fast_traceframes): New.
12552 (IPA_FIRST_TRACEFRAME): New.
12553 (IPA_NEXT_TRACEFRAME_1): New.
12554 (IPA_NEXT_TRACEFRAME): New.
12555 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12556 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12557 (gdb_jump_pad_buffer_end): New.
12558 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12559 (initialize_tracepoint): Adjust.
12560 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12561 buffer. Initialize the low module.
12562 * utils.c (PREFIX, TOOLNAME): New.
12563 (malloc_failure): Use PREFIX.
12564 (error): In the IPA, an error causes an exit.
12565 (fatal, warning): Use PREFIX.
12566 (internal_error): Use TOOLNAME.
12567 (NUMCELLS): Increase to 10.
12568 * configure, config.in: Regenerate.
12569
12570 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12571
12572 * server.c (handle_query) <qSupported>: Do two passes over the
12573 qSupported string to avoid nesting strtok.
12574
12575 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12576
12577 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
12578 (CDEPS): New.
12579 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
12580 -Wl,--dynamic-list.
12581 * configure: Regenerate.
12582 * proc-service.list: New.
12583
12584 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12585
12586 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
12587 New comment.
12588
12589 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
12590
12591 * gdbreplay.c (remote_open): Check error return from socket() call by
12592 its equality to -1 not by it being negative.
12593 * remote-utils.c (remote_open): Likewise.
12594
12595 2010-05-23 Pedro Alves <pedro@codesourcery.com>
12596
12597 * config.h: Regenerate.
12598
12599 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12600
12601 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
12602 doesn't provide PTRACE_GET_THREAD_AREA.
12603
12604 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
12605
12606 * linux-m68k-low.c: Include <asm/ptrace.h>
12607 (ps_get_thread_area): Implement.
12608
12609 2010-05-03 Doug Evans <dje@google.com>
12610
12611 * event-loop.c (struct callback_event): New struct.
12612 (callback_list): New global.
12613 (append_callback_event, delete_callback_event): New functions.
12614 (process_callback): New function.
12615 (start_event_loop): Call it.
12616 * remote-utils.c (NOT_SCHEDULED): Define.
12617 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
12618 moved out of readchar.
12619 (readchar): Rewrite. Call reschedule before returning.
12620 (reset_readchar): New function.
12621 (remote_close): Call it.
12622 (process_remaining, reschedule): New functions.
12623 * server.h (callback_handler_func): New typedef.
12624 (append_callback_event, delete_callback_event): Declare.
12625
12626 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12627
12628 * proc-service.c (ps_pglobal_lookup): Use
12629 thread_db_look_up_one_symbol.
12630 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
12631 parameter. Use it instead of all_symbols_looked_up.
12632 * server.h (struct process_info) <all_symbols_looked_up>: Delete
12633 field.
12634 (all_symbols_looked_up): Don't declare.
12635 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
12636 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
12637 field.
12638 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
12639 Set all_symbols_looked_up here.
12640 (thread_db_look_up_one_symbol): New.
12641 (thread_db_get_tls_address): Adjust.
12642 (thread_db_load_search, try_thread_db_load_1): Always allocate the
12643 thread_db object on the heap, and tentatively set it in the
12644 process structure.
12645 (thread_db_init): Don't set all_symbols_looked_up here.
12646 * linux-low.h (thread_db_look_up_one_symbol): Declare.
12647
12648 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12649
12650 * linux-low.c (linux_kill, linux_detach): Adjust.
12651 (status_pending_p_callback): Remove redundant statement. Check
12652 for !TARGET_WAITIKIND_IGNORE, instead of
12653 TARGET_WAITKIND_STOPPED.
12654 (handle_tracepoints): Make sure LWP is locked. Adjust.
12655 (linux_wait_for_event_1): Adjust.
12656 (linux_cancel_breakpoints): New.
12657 (unsuspend_one_lwp): New.
12658 (unsuspend_all_lwps): New.
12659 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
12660 (send_sigstop_callback): Change return type to int, add new
12661 `except' parameter and handle it.
12662 (suspend_and_send_sigstop_callback): New.
12663 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
12664 pass them down. If SUSPEND, also increment the lwp's suspend
12665 count.
12666 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
12667 (need_step_over_p): Don't consider suspended LWPs.
12668 (start_step_over): Adjust.
12669 (proceed_one_lwp): Change return type to int, add new `except'
12670 parameter and handle it.
12671 (unsuspend_and_proceed_one_lwp): New.
12672 (proceed_all_lwps): Use find_inferior instead of
12673 for_each_inferior.
12674 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
12675 also decrement the suspend count of LWPs. Pass `except' down,
12676 instead of hacking its suspend count.
12677 (linux_pause_all): Add `freeze' parameter. Adjust.
12678 (linux_unpause_all): New.
12679 (linux_target_ops): Install linux_unpause_all.
12680 * server.c (handle_status): Adjust.
12681 * target.h (struct target_ops): New fields `unpause_all' and
12682 `cancel_breakpoints'. Add new parameter to `pause_all'.
12683 (pause_all): Add new `freeze' parameter.
12684 (unpause_all): New.
12685 (cancel_breakpoints): New.
12686 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
12687 cancel breakpoints.
12688 (cmd_qtstart): Pause threads.
12689 (stop_tracing): Pause threads, and cancel breakpoints.
12690 * win32-low.c (win32_target_ops): Adjust.
12691
12692 2010-05-03 Pedro Alves <pedro@codesourcery.com>
12693
12694 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
12695 the inferior right away from here...
12696 (linux_wait_1): ... to here, and adjust to check the thread's
12697 last_resume_kind instead of the lwp's step or stop_expected flags.
12698
12699 2010-05-02 Pedro Alves <pedro@codesourcery.com>
12700
12701 * README: Use consistent `GDB' and `GDBserver' spellings.
12702
12703 2010-05-02 Pedro Alves <pedro@codesourcery.com>
12704
12705 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
12706 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
12707 (linux_detach_one_lwp): Assume the lwp is stopped.
12708 (any_thread_of): Delete.
12709 (linux_detach): Stop all lwps here. Don't blindly delete all
12710 breakpoints.
12711 (delete_lwp_callback): New.
12712 (linux_mourn): Delete all lwps of the process that is gone.
12713 (linux_wait_1): Don't delete the last lwp of the process here.
12714 * mem-break.h (mark_breakpoints_out): Declare.
12715 * mem-break.c (mark_breakpoints_out): New.
12716 (free_all_breakpoints): Use it.
12717 * server.c (handle_target_event): If the process is gone, mark
12718 breakpoints out.
12719 * thread-db.c (struct thread_db) <create_bp>: New field.
12720 (thread_db_enable_reporting): Fix prototype. Store a thread event
12721 breakpoint reference in the thread_db struct.
12722 (thread_db_load_search): Clear the thread_db object.
12723 (try_thread_db_load_1): Ditto.
12724 (switch_to_process): New.
12725 (disable_thread_event_reporting): Use it.
12726 (remove_thread_event_breakpoints): New.
12727 (thread_db_detach, thread_db_mourn): Use it.
12728
12729 2010-05-01 Pedro Alves <pedro@codesourcery.com>
12730
12731 * linux-low.c (linux_enable_event_reporting): New.
12732 (linux_wait_for_event_1, handle_extended_wait): Use it.
12733
12734 2010-04-30 Pedro Alves <pedro@codesourcery.com>
12735
12736 * linux-low.c (linux_kill_one_lwp, linux_kill)
12737 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
12738 (send_sigstop): Take an lwp_info as parameter instead. Queue a
12739 SIGSTOP even if the LWP is stopped.
12740 (send_sigstop_callback): New.
12741 (stop_all_lwps): Use send_sigstop_callback instead.
12742 (linux_resume_one_thread): Adjust.
12743 (proceed_one_lwp): Still proceed an LWP that the client has
12744 requested to stop, if we haven't reported it as stopped yet. Make
12745 sure that LWPs the client want stopped, have a pending SIGSTOP.
12746
12747 2010-04-26 Doug Evans <dje@google.com>
12748
12749 * server.c (handle_general_set): Make static.
12750
12751 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
12752 Print received char after testing for error/eof instead of before.
12753 (input_interrupt): Tweak comment.
12754
12755 2010-04-23 Doug Evans <dje@google.com>
12756
12757 * server.c (start_inferior): Print inferior argv if --debug.
12758
12759 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
12760
12761 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
12762 * nto-x86-low.c: Include server.h
12763
12764 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
12765
12766 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
12767 be consistent with other sources of this directory.
12768 (init_registers_amd64): Correct name of source file of this function
12769 in the comment.
12770
12771 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12772
12773 * configure.srv (x86_64-*-mingw*): New configuration for Windows
12774 64-bit executables.
12775
12776 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12777
12778 * win32-i386-low.c: Add 64-bit support.
12779 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
12780 (init_registers_amd64): Declare.
12781 (mappings): Add 64-bit version of array.
12782 (init_windows_x86): New function.
12783 (the_low_target): Change init_arch field to init_windows_x86.
12784
12785 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12786
12787 * win32-low.c: Adapt to support also 64-bit architecture.
12788 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
12789 (get_image_name): Use SIZE_T type for local variable `done'.
12790 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
12791 (toolhelp_get_dll_name): Idem.
12792 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
12793 Use uintptr_t typecast to avoid warning.
12794 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
12795 (handle_exception): Use phex_nz to avoid warning.
12796 (win32_wait): Remove unused local variable `process'.
12797
12798 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
12799
12800 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
12801 `amd64-avx.o'.
12802
12803 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
12804
12805 * configure.ac: Use `ws2_32' library for srv_mingw.
12806 * configure: Regenerate.
12807 * gdbreplay.c: Include winsock2.h instead of winsock.h.
12808 * remote-utils.c: Likewise.
12809
12810 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
12811
12812 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
12813 if __x86_64__ is defined.
12814
12815 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12816
12817 * configure: Regenerate.
12818
12819 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
12820
12821 * server.c (handle_query): Handle 'qGetTIBAddr' query.
12822 * target.h (target_ops): New get_tib_address field.
12823 * win32-low.h (win32_thread_info): Add thread_local_base field.
12824 * win32-low.c (child_add_thread): Add tlb argument.
12825 Set thread_local_base field to TLB.
12826 (get_child_debug_event): Adapt to child_add_thread change.
12827 (win32_get_tib_address): New function.
12828 (win32_target_ops): Set get_tib_address field to
12829 win32_get_tib_address.
12830 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
12831
12832 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12833
12834 * linux-low.c (linux_mourn): Also remove the process.
12835 * server.c (handle_target_event): Don't remove the process here.
12836 * nto-low.c (nto_mourn): New.
12837 (nto_target_ops): Install it.
12838 * spu-low.c (spu_mourn): New.
12839 (spu_target_ops): Install it.
12840 * win32-low.c (win32_mourn): New.
12841 (win32_target_ops): Install it.
12842
12843 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12844
12845 * server.h (buffer_xml_printf): Remove redundant `;'.
12846
12847 2010-04-12 Pedro Alves <pedro@codesourcery.com>
12848
12849 * regcache.c (set_register_cache): Invalidate regcaches before
12850 changing the register cache layout.
12851 (regcache_invalidate_one): Allow a NULL regcache.
12852 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
12853 regcaches before changing the register cache layout or the target
12854 regsets.
12855
12856 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
12857
12858 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
12859 variable warning on Linux/x86-64.
12860
12861 2010-04-11 Pedro Alves <pedro@codesourcery.com>
12862
12863 GDBserver disconnected tracing support.
12864
12865 * linux-low.c (linux_remove_process): Delete.
12866 (add_lwp): Don't set last_resume_kind here.
12867 (linux_kill): Use `mourn'.
12868 (linux_detach): Use `thread_db_detach', and `mourn'.
12869 (linux_mourn): New.
12870 (linux_attach_lwp_1): Adjust comment.
12871 (linux_attach): last_resume_kind moved the thread_info; adjust.
12872 (status_pending_p_callback): Adjust.
12873 (linux_wait_for_event_1): Adjust.
12874 (count_events_callback, select_singlestep_lwp_callback)
12875 (select_event_lwp_callback, cancel_breakpoints_callback)
12876 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
12877 (proceed_one_lwp): Adjust.
12878 (linux_async): Add debug output.
12879 (linux_thread_stopped): New.
12880 (linux_pause_all): New.
12881 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
12882 linux_pause_all.
12883 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
12884 (thread_db_free): Delete declaration.
12885 (thread_db_detach, thread_db_mourn): Declare.
12886 * thread-db.c (thread_db_init): Use thread_db_mourn.
12887 (thread_db_free): Delete, split in two.
12888 (disable_thread_event_reporting): New.
12889 (thread_db_detach): New.
12890 (thread_db_mourn): New.
12891
12892 * server.h (struct thread_info) <last_resume_kind>: New field.
12893 <attached>: Add comment.
12894 <gdb_detached>: New field.
12895 (handler_func): Change return type to int.
12896 (handle_serial_event, handle_target_event): Ditto.
12897 (gdb_connected): Declare.
12898 (tracing): Delete.
12899 (disconnected_tracing): Declare.
12900 (stop_tracing): Declare.
12901
12902 * server.c (handle_query) <qSupported>: Report support for
12903 disconnected tracing.
12904 (queue_stop_reply_callback): Account for running threads.
12905 (gdb_wants_thread_stopped): New.
12906 (gdb_wants_all_threads_stopped): New.
12907 (gdb_reattached_process): New.
12908 (handle_status): Clear the `gdb_detached' flag of all processes.
12909 In all-stop, stop all threads.
12910 (main): Be sure to leave tfind mode. Handle disconnected tracing.
12911 (process_serial_event): If the remote connection breaks, or if an
12912 exit was forced with "monitor exit", force an event loop exit.
12913 Handle disconnected tracing on detach.
12914 (handle_serial_event): Adjust.
12915 (handle_target_event): If GDB isn't connected, forward events back
12916 to the inferior, unless the last process exited, in which case,
12917 exit gdbserver. Adjust interface.
12918
12919 * remote-utils.c (remote_open): Don't block in accept. Instead
12920 register an event loop source on the listen socket file
12921 descriptor. Refactor bits into ...
12922 (listen_desc): ... this new global.
12923 (gdb_connected): ... this new function.
12924 (enable_async_notification): ... this new function.
12925 (handle_accept_event): ... this new function.
12926 (remote_close): Clear remote_desc.
12927
12928 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
12929
12930 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
12931 New fields.
12932 (mourn_inferior): Define.
12933 (target_process_qsupported): Avoid the dangling else problem.
12934 (thread_stopped): Define.
12935 (pause_all): Define.
12936 (target_waitstatus_to_string): Declare.
12937 * target.c (target_waitstatus_to_string): New.
12938
12939 * tracepoint.c (tracing): Make extern.
12940 (disconnected_tracing): New.
12941 (stop_tracing): Make extern. Handle tracing stops due to GDB
12942 disconnecting.
12943 (cmd_qtdisconnected): New.
12944 (cmd_qtstatus): Report disconnected tracing status in trace reply.
12945 (handle_tracepoint_general_set): Handle QTDisconnected.
12946
12947 * event-loop.c (event_handler_func): Change return type to int.
12948 (process_event): Bail out if the event handler wants the event
12949 loop to stop.
12950 (handle_file_event): Ditto.
12951 (start_event_loop): Bail out if the event handler wants the event
12952 loop to stop.
12953
12954 * nto-low.c (nto_target_ops): Adjust.
12955 * spu-low.c (spu_wait): Don't remove the process here.
12956 (spu_target_ops): Adjust.
12957 * win32-low.c (win32_wait): Don't remove the process here.
12958 (win32_target_ops): Adjust.
12959
12960 2010-04-11 Pedro Alves <pedro@codesourcery.com>
12961
12962 * regcache.c (realloc_register_cache): Invalidate inferior's
12963 regcache before recreating it.
12964
12965 2010-04-09 Pedro Alves <pedro@codesourcery.com>
12966
12967 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
12968
12969 2010-04-09 Stan Shebs <stan@codesourcery.com>
12970 Pedro Alves <pedro@codesourcery.com>
12971
12972 * server.h (LONGEST): New.
12973 (struct thread_info) <while_stepping>: New field.
12974 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
12975 Declare.
12976 (initialize_tracepoint, handle_tracepoint_general_set)
12977 (handle_tracepoint_query, tracepoint_finished_step)
12978 (tracepoint_was_hit, release_while_stepping_state_list):
12979 (current_traceframe): Declare.
12980 * server.c (handle_general_set): Handle tracepoint packets.
12981 (read_memory): New.
12982 (write_memory): New.
12983 (handle_search_memory_1): Use read_memory.
12984 (handle_query): Report support for conditional tracepoints, trace
12985 state variables, and tracepoint sources. Handle tracepoint
12986 queries.
12987 (main): Initialize the tracepoints module.
12988 (process_serial_event): Handle traceframe reads/writes.
12989
12990 * linux-low.c (handle_tracepoints): New.
12991 (linux_wait_1): Call it.
12992 (linux_resume_one_lwp): Handle while-stepping.
12993 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
12994 (linux_target_ops): Install them.
12995 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
12996 New field.
12997 * linux-x86-low.c (x86_supports_tracepoints): New.
12998 (the_low_target). Install it.
12999
13000 * mem-break.h (delete_breakpoint): Declare.
13001 * mem-break.c (delete_breakpoint): Make external.
13002
13003 * target.h (struct target_ops): Add `supports_tracepoints',
13004 `read_pc', and `write_pc' fields.
13005 (target_supports_tracepoints): Define.
13006 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13007 (phex_nz): New.
13008
13009 * regcache.h (struct regcache) <registers_owned>: New field.
13010 (init_register_cache, regcache_cpy): Declare.
13011 (regcache_read_pc, regcache_write_pc): Declare.
13012 (register_cache_size): Declare.
13013 (supply_regblock): Declare.
13014 * regcache.c (init_register_cache): New.
13015 (new_register_cache): Use it.
13016 (regcache_cpy): New.
13017 (register_cache_size): New.
13018 (supply_regblock): New.
13019 (regcache_read_pc, regcache_write_pc): New.
13020
13021 * tracepoint.c: New.
13022
13023 * Makefile.in (OBS): Add tracepoint.o.
13024 (tracepoint.o): New rule.
13025
13026 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13027
13028 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13029 (i386-mmx.o): New.
13030 (i386-mmx.c): Likewise.
13031 (i386-mmx-linux.o): Likewise.
13032 (i386-mmx-linux.c): Likewise.
13033
13034 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13035 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13036 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13037 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13038
13039 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13040 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13041 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13042
13043 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13044
13045 * Makefile.in (clean): Updated.
13046 (i386-avx.o): New.
13047 (i386-avx.c): Likewise.
13048 (i386-avx-linux.o): Likewise.
13049 (i386-avx-linux.c): Likewise.
13050 (amd64-avx.o): Likewise.
13051 (amd64-avx.c): Likewise.
13052 (amd64-avx-linux.o): Likewise.
13053 (amd64-avx-linux.c): Likewise.
13054
13055 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13056 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13057 (srv_amd64_regobj): Add amd64-avx.o.
13058 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13059 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13060 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13061 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13062 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13063 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13064 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13065
13066 * i387-fp.c: Include "i386-xstate.h".
13067 (i387_xsave): New.
13068 (i387_cache_to_xsave): Likewise.
13069 (i387_xsave_to_cache): Likewise.
13070 (x86_xcr0): Likewise.
13071
13072 * i387-fp.h (i387_cache_to_xsave): Likewise.
13073 (i387_xsave_to_cache): Likewise.
13074 (x86_xcr0): Likewise.
13075
13076 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13077 * linux-crisv32-low.c (target_regsets): Likewise.
13078 * linux-m68k-low.c (target_regsets): Likewise.
13079 * linux-mips-low.c (target_regsets): Likewise.
13080 * linux-ppc-low.c (target_regsets): Likewise.
13081 * linux-s390-low.c (target_regsets): Likewise.
13082 * linux-sh-low.c (target_regsets): Likewise.
13083 * linux-sparc-low.c (target_regsets): Likewise.
13084 * linux-xtensa-low.c (target_regsets): Likewise.
13085
13086 * linux-low.c: Include <sys/uio.h>.
13087 (regsets_fetch_inferior_registers): Support nt_type.
13088 (regsets_store_inferior_registers): Likewise.
13089 (linux_process_qsupported): New.
13090 (linux_target_ops): Add linux_process_qsupported.
13091
13092 * linux-low.h (regset_info): Add nt_type.
13093 (linux_target_ops): Add process_qsupported.
13094
13095 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13096 and <sys/uio.h>.
13097 (init_registers_i386_avx_linux): New.
13098 (init_registers_amd64_avx_linux): Likewise.
13099 (xmltarget_i386_linux_no_xml): Likewise.
13100 (xmltarget_amd64_linux_no_xml): Likewise.
13101 (PTRACE_GETREGSET): Likewise.
13102 (PTRACE_SETREGSET): Likewise.
13103 (x86_fill_xstateregset): Likewise.
13104 (x86_store_xstateregset): Likewise.
13105 (use_xml): Likewise.
13106 (x86_linux_update_xmltarget): Likewise.
13107 (x86_linux_process_qsupported): Likewise.
13108 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13109 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13110 init_registers_i386_linux here. Call
13111 x86_linux_update_xmltarget.
13112 (the_low_target): Add x86_linux_process_qsupported.
13113
13114 * server.c (handle_query): Call target_process_qsupported.
13115
13116 * target.h (target_ops): Add process_qsupported.
13117 (target_process_qsupported): New.
13118
13119 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13120
13121 * inferiors.c (add_thread): Set last_status kind to
13122 TARGET_WAITKIND_IGNORE.
13123 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13124 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13125 (linux_wait_1): Move `thread' local definition to block that uses
13126 it. Don't NULL initialize `event_child'.
13127 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13128 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13129 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13130
13131 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13132
13133 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13134 an extended waitstatus, or by a watchpoint.
13135 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13136 thread was stepping or has been stopped by a watchpoint.
13137
13138 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13139
13140 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13141 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13142 of another, then delete the previous, and validate all
13143 breakpoints.
13144 (validate_inserted_breakpoint): New.
13145 (delete_disabled_breakpoints): New.
13146 (validate_breakpoints): New.
13147 (check_mem_read): Validate breakpoints before trusting their
13148 shadow. Delete disabled breakpoints.
13149 (check_mem_write): Validate breakpoints before trusting they
13150 should be inserted. Delete disabled breakpoints.
13151 * mem-break.h (validate_breakpoints):
13152 * server.c (handle_query): Validate breakpoints when we see a
13153 qSymbol query.
13154
13155 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13156
13157 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13158 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13159 if we could tell there's a GDB breakpoint at stop_pc.
13160 (need_step_over_p): Don't do a step over if we find a GDB
13161 breakpoint at the resume PC.
13162
13163 * mem-break.c (struct raw_breakpoint): New.
13164 (enum bkpt_type): New type `gdb_breakpoint'.
13165 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13166 fields. New field `raw'.
13167 (find_raw_breakpoint_at): New.
13168 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13169 breakpoint instead.
13170 (set_breakpoint_at): Adjust.
13171 (delete_raw_breakpoint): New.
13172 (release_breakpoint): New.
13173 (delete_breakpoint): Rename to...
13174 (delete_breakpoint_1): ... this. Add proc parameter. Use
13175 release_breakpoint. Return ENOENT.
13176 (delete_breakpoint): Reimplement.
13177 (find_breakpoint_at): Delete.
13178 (find_gdb_breakpoint_at): New.
13179 (delete_breakpoint_at): Delete.
13180 (set_gdb_breakpoint_at): New.
13181 (delete_gdb_breakpoint_at): New.
13182 (gdb_breakpoint_here): New.
13183 (set_reinsert_breakpoint): Use release_breakpoint.
13184 (uninsert_breakpoint): Rename to ...
13185 (uninsert_raw_breakpoint): ... this.
13186 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13187 (reinsert_raw_breakpoint): Change parameter type to
13188 raw_breakpoint.
13189 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13190 instead.
13191 (check_breakpoints): Adjust. Use release_breakpoint.
13192 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13193 (breakpoint_inserted_here): Ditto.
13194 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13195 Don't trust the breakpoint's shadow if it is not inserted.
13196 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13197 (delete_all_breakpoints): Adjust.
13198 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13199 use delete_breakpoint_1.
13200
13201 * mem-break.h (breakpoints_supported): Delete declaration.
13202 (set_gdb_breakpoint_at): Declare.
13203 (gdb_breakpoint_here): Declare.
13204 (delete_breakpoint_at): Delete.
13205 (delete_gdb_breakpoint_at): Declare.
13206
13207 * server.h (struct raw_breakpoint): Forward declare.
13208 (struct process_info): New field `raw_breakpoints'.
13209
13210 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13211 breakpoints.
13212
13213 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13214
13215 * linux-low.c (status_pending_p_callback): Fix comment.
13216 (linux_wait_for_event_1): Move most of the internal breakpoint
13217 handling from here...
13218 (linux_wait_1): ... to here.
13219 (count_events_callback): New.
13220 (select_singlestep_lwp_callback): New.
13221 (select_event_lwp_callback): New.
13222 (cancel_breakpoints_callback): New.
13223 (select_event_lwp): New.
13224 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13225 priority to all LWPs that have had events that should be reported
13226 to the client. Cancel breakpoints when about to reporting the
13227 event to the client, not while stopping lwps. No longer cancel
13228 finished single-steps here.
13229 (cancel_finished_single_step): Delete.
13230 (cancel_finished_single_steps): Delete.
13231
13232 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13233
13234 * mem-break.c (enum bkpt_type): New.
13235 (struct breakpoint): New field `type'.
13236 (set_breakpoint_at): Change return type to struct breakpoint
13237 pointer. Set type to `other_breakpoint' by default.
13238 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13239 in the breakpoint list.
13240 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13241 (reinsert_breakpoint): Rename to ...
13242 (reinsert_raw_breakpoint): ... this.
13243 (reinsert_breakpoints_at): Adjust.
13244 * mem-break.h (struct breakpoint): Declare.
13245 (set_breakpoint_at): Change return type to struct breakpoint
13246 pointer.
13247
13248 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13249
13250 * server.c (handle_query): Assign, not compare.
13251
13252 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13253
13254 Teach linux gdbserver to step-over-breakpoints.
13255
13256 * linux-low.c (can_hardware_single_step): New.
13257 (supports_breakpoints): New.
13258 (handle_extended_wait): If stopping threads, read the stop pc of
13259 the new cloned LWP.
13260 (get_pc): New.
13261 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13262 low target doesn't support retrieving the PC.
13263 (add_lwp): Set last_resume_kind to resume_continue.
13264 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13265 (linux_attach): Don't clear stop_expected. Set the lwp's
13266 last_resume_kind to resume_stop.
13267 (linux_detach_one_lwp): Don't check for removed breakpoints.
13268 (check_removed_breakpoint): Delete.
13269 (status_pending_p): Rename to ...
13270 (status_pending_p_callback): ... this. Don't check for removed
13271 breakpoints. Don't consider threads that are stopped from GDB's
13272 perspective.
13273 (linux_wait_for_lwp): Always read the stop_pc here.
13274 (cancel_breakpoint): New.
13275 (step_over_bkpt): New global.
13276 (linux_wait_for_event_1): Implement stepping over breakpoints.
13277 (gdb_wants_lwp_stopped): New.
13278 (gdb_wants_all_stopped): New.
13279 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13280 single-step traps here. Store the thread's last reported target
13281 wait status.
13282 (send_sigstop): Don't clear stop_expected. Always set it,
13283 instead.
13284 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13285 (cancel_finished_single_step): New.
13286 (cancel_finished_single_steps): New.
13287 (wait_for_sigstop): Don't cancel finished single-step traps here.
13288 (linux_resume_one_lwp): Don't check for removed breakpoints.
13289 Don't set `step' on non-hardware step archs.
13290 (linux_set_resume_request): Ignore resume_stop requests if already
13291 stopping or stopped. Set the lwp's last_resume_kind.
13292 (resume_status_pending_p): Don't check for removed breakpoints.
13293 (need_step_over_p): New.
13294 (start_step_over): New.
13295 (finish_step_over): New.
13296 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13297 requests. Clear the thread's last reported target waitstatus.
13298 Don't use the `suspended' flag. Don't consider pending breakpoints.
13299 (linux_resume): Start a step-over if necessary.
13300 (proceed_one_lwp): New.
13301 (proceed_all_lwps): New.
13302 (unstop_all_lwps): New.
13303 * linux-low.h (struct lwp_info): Rewrite comment for the
13304 `suspended' flag. Add the `stop_pc' field. Delete the
13305 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13306 Add `'last_resume_kind' and `need_step_over' fields.
13307 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13308 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13309 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13310 (set_raw_breakpoint_at): New.
13311 (set_breakpoint_at): Rewrite to use it.
13312 (reinsert_breakpoint_handler): Delete.
13313 (set_reinsert_breakpoint): New.
13314 (reinsert_breakpoint_by_bp): Delete.
13315 (delete_reinsert_breakpoints): New.
13316 (uninsert_breakpoint): Rewrite.
13317 (uninsert_breakpoints_at): New.
13318 (reinsert_breakpoint): Rewrite.
13319 (reinsert_breakpoints_at): New.
13320 (check_breakpoints): Rewrite.
13321 (breakpoint_here): New.
13322 (breakpoint_inserted_here): New.
13323 (check_mem_read): Adjust.
13324 * mem-break.h (breakpoints_supported, breakpoint_here)
13325 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13326 (reinsert_breakpoint_by_bp): Delete declaration.
13327 (delete_reinsert_breakpoints): Declare.
13328 (reinsert_breakpoint): Delete declaration.
13329 (reinsert_breakpoints_at): Declare.
13330 (uninsert_breakpoint): Delete declaration.
13331 (uninsert_breakpoints_at): Declare.
13332 (check_breakpoints): Adjust prototype.
13333 * server.h: Adjust include order.
13334 (struct thread_info): Declare here. Add a `last_status' field.
13335
13336 2010-03-23 Michael Snyder <msnyder@vmware.com>
13337
13338 * server.c (crc32): New function.
13339 (handle_query): Add handling for 'qCRC:' request.
13340
13341 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13342
13343 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13344 lwp had been stopped by a watchpoint.
13345
13346 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13347
13348 * server.h (internal_error): Declare.
13349 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13350 * utils.c (internal_error): New function.
13351
13352 2010-03-15 Andreas Schwab <schwab@redhat.com>
13353
13354 * configure.srv: Fix typo setting srv_regobj.
13355
13356 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13357
13358 * linux-low.c (fetch_register): Avoid passing a non string literal
13359 format to `error'.
13360 (usr_store_inferior_registers): Ditto.
13361
13362 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13363
13364 * linux-low.c (linux_write_memory): Bail out early if peeking
13365 memory failed.
13366
13367 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13368
13369 * linux-low.h (struct lwp_info): New fields
13370 `stopped_by_watchpoint' and `stopped_data_address'.
13371 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13372 here, and cache them in the lwp object.
13373 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13374 directly.
13375 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13376 field.
13377 (linux_stopped_by_watchpoint): Rewrite.
13378 (linux_stopped_data_address): Rewrite.
13379
13380 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13381
13382 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13383 switching the current inferior, not before.
13384
13385 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13386
13387 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13388 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13389 i386-linux.c and amd64-linux.c.
13390 (reg-i386.o): Removed.
13391 (reg-i386.c): Likewise.
13392 (reg-i386-linux.o): Likewise.
13393 (reg-i386-linux.c): Likewise.
13394 (reg-x86-64.o): Likewise.
13395 (reg-x86-64.c): Likewise.
13396 (reg-x86-64-linux.o): Likewise.
13397 (reg-x86-64-linux.c): Likewise.
13398 (i386.o): New.
13399 (i386.c): Likewise.
13400 (i386-linux.o): Likewise.
13401 (i386-linux.c): Likewise.
13402 (amd64.o): Likewise.
13403 (amd64.c): Likewise.
13404 (amd64-linux.o): Likewise.
13405 (amd64-linux.c): Likewise.
13406
13407 * configure.srv (srv_i386_regobj): New.
13408 (srv_i386_linux_regobj): Likewise.
13409 (srv_amd64_regobj): Likewise.
13410 (srv_amd64_linux_regobj): Likewise.
13411 (srv_i386_32bit_xmlfiles): Likewise.
13412 (srv_i386_64bit_xmlfiles): Likewise.
13413 (srv_i386_xmlfiles): Likewise.
13414 (srv_amd64_xmlfiles): Likewise.
13415 (srv_i386_linux_xmlfiles): Likewise.
13416 (srv_amd64_linux_xmlfiles): Likewise.
13417 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13418 srv_xmlfiles to $srv_i386_xmlfiles.
13419 (i[34567]86-*-mingw32ce*): Likewise.
13420 (i[34567]86-*-mingw*): Likewise.
13421 (i[34567]86-*-nto*): Likewise.
13422 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13423 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13424 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13425 (x86_64-*-linux*): Likewise.
13426
13427 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13428 (init_registers_amd64_linux): New.
13429 (x86_arch_setup): Replace init_registers_x86_64_linux with
13430 init_registers_amd64_linux.
13431
13432 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13433
13434 * configure.ac: Check for libdl. If it is not available link against
13435 static libthread_db.
13436 * configure: Regenerate.
13437
13438 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13439
13440 PR9605
13441
13442 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13443 handing a read watchpoint.
13444 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13445
13446 2010-02-12 Doug Evans <dje@google.com>
13447
13448 * linux-low.c (linux_supports_tracefork_flag): Document.
13449 (linux_look_up_symbols): Add comment.
13450
13451 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13452
13453 * regcache.c (supply_register): Clear regcache if buf is NULL.
13454
13455 2010-02-02 Nicolas Roche <roche@sourceware.org>
13456 Joel Brobecker <brobecker@adacore.com>
13457
13458 * inferiors.c (find_inferior): Add function documentation.
13459 (unloaded_dll): Handle the case where the unloaded dll has not
13460 been previously registered in the dll list.
13461
13462 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13463
13464 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13465 (thumb2_breakpoint): New.
13466 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13467
13468 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13469
13470 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13471 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13472 breakpoints.
13473
13474 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13475
13476 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13477
13478 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13479
13480 * linux-s390-low.c (s390_collect_ptrace_register)
13481 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13482
13483 2010-01-21 Doug Evans <dje@google.com>
13484
13485 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13486 (PTRACE_ARG4_TYPE): New macro.
13487 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13488 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13489 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13490 (usr_store_inferior_registers): Ditto.
13491 (linux_read_memory, linux_write_memory): Ditto.
13492 (linux_test_for_tracefork): Ditto.
13493
13494 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13495 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13496
13497 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13498
13499 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13500 target.
13501
13502 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13503
13504 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13505 prototype to take a regcache. Adjust.
13506
13507 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13508
13509 * regcache.h (struct thread_info): Forward declare.
13510 (struct regcache): New.
13511 (new_register_cache): Adjust prototype.
13512 (get_thread_regcache): Declare.
13513 (free_register_cache): Adjust prototype.
13514 (registers_to_string, registers_from_string): Ditto.
13515 (supply_register, supply_register_by_name, collect_register)
13516 (collect_register_as_string, collect_register_by_name): Ditto.
13517 * regcache.c (struct inferior_regcache_data): Delete.
13518 (get_regcache): Rename to ...
13519 (get_thread_regcache): ... this. Adjust. Switch inferior before
13520 fetching registers.
13521 (regcache_invalidate_one): Adjust.
13522 (regcache_invalidate): Fix prototype.
13523 (new_register_cache): Return the new register cache.
13524 (free_register_cache): Change prototype.
13525 (realloc_register_cache): Adjust.
13526 (registers_to_string): Change prototype to take a regcache. Adjust.
13527 (registers_from_string): Ditto.
13528 (register_data): Ditto.
13529 (supply_register): Ditto.
13530 (supply_register_by_name): Ditto.
13531 (collect_register): Ditto.
13532 (collect_register_as_string): Ditto.
13533 (collect_register_by_name): Ditto.
13534 * server.c (process_serial_event): Adjust.
13535 * linux-low.h (regset_fill_func, regset_store_func): Change
13536 prototype.
13537 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13538 Change prototype.
13539 * linux-low.c (get_stop_pc): Adjust.
13540 (check_removed_breakpoint): Adjust.
13541 (linux_wait_for_event): Adjust.
13542 (linux_resume_one_lwp): Adjust.
13543 (fetch_register): Add regcache parameter. Adjust.
13544 (usr_store_inferior_registers): Ditto.
13545 (regsets_fetch_inferior_registers): Ditto.
13546 (regsets_store_inferior_registers): Ditto.
13547 (linux_fetch_registers, linux_store_registers): Ditto.
13548 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13549 regcache. Adjust.
13550 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13551 Ditto.
13552 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13553 prototype to take a regcache.
13554 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13555 * remote-utils.c (convert_ascii_to_int, outreg)
13556 (prepare_resume_reply): Change prototype to take a regcache.
13557 Adjust.
13558 * target.h (struct target_ops) <fetch_registers, store_registers>:
13559 Change prototype to take a regcache.
13560 (fetch_inferior_registers, store_inferior_registers): Change
13561 prototype to take a regcache. Adjust.
13562 * proc-service.c (ps_lgetregs): Adjust.
13563 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13564 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13565 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13566 take a regcache. Adjust.
13567 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
13568 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
13569 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
13570 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
13571 * linux-cris-low.c (cris_get_pc, cris_set_pc)
13572 (cris_cannot_fetch_register):
13573 (cris_breakpoint_at): Change prototype to take a regcache.
13574 Adjust.
13575 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
13576 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
13577 to take a regcache. Adjust.
13578 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
13579 Adjust.
13580 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
13581 take a regcache. Adjust.
13582 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
13583 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
13584 (m68k_set_pc): Change prototype to take a regcache. Adjust.
13585 * linux-mips-low.c (mips_get_pc):
13586 (mips_set_pc): Change prototype to take a regcache. Adjust.
13587 (mips_reinsert_addr): Adjust.
13588 (mips_collect_register): Change prototype to take a regcache.
13589 Adjust.
13590 (mips_supply_register):
13591 (mips_collect_register_32bit, mips_supply_register_32bit)
13592 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
13593 (mips_store_fpregset): Ditto.
13594 * linux-ppc-low.c (ppc_supply_ptrace_register)
13595 (ppc_supply_ptrace_register): Ditto.
13596 (parse_spufs_run): Adjust.
13597 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
13598 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
13599 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
13600 take a regcache. Adjust.
13601 * linux-s390-low.c (s390_collect_ptrace_register)
13602 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
13603 (s390_set_pc): Change prototype to take a regcache. Adjust.
13604 (s390_arch_setup): Adjust.
13605 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
13606 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
13607 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
13608 (sparc_fill_gregset, sparc_store_gregset_from_stack)
13609 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
13610 regcache. Adjust.
13611 (sparc_breakpoint_at): Adjust.
13612 * linux-xtensa-low.c (xtensa_fill_gregset):
13613 (xtensa_store_gregset):
13614 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
13615 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
13616 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
13617 prototype to take a regcache. Adjust.
13618 * win32-arm-low.c (arm_fetch_inferior_register)
13619 (arm_store_inferior_register): Change prototype to take a
13620 regcache. Adjust.
13621 * win32-i386-low.c (i386_fetch_inferior_register)
13622 (i386_store_inferior_register): Change prototype to take a
13623 regcache. Adjust.
13624 * win32-low.c (child_fetch_inferior_registers)
13625 (child_store_inferior_registers): Change prototype to take a
13626 regcache. Adjust.
13627 (win32_wait): Adjust.
13628 (win32_fetch_inferior_registers): Change prototype to take a
13629 regcache. Adjust.
13630 (win32_store_inferior_registers): Adjust.
13631 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
13632 store_inferior_register>: Change prototype to take a regcache.
13633
13634 2010-01-20 Doug Evans <dje@google.com>
13635
13636 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
13637 #ifdef.
13638 (linux_wait_for_event1, linux_init_signals): Ditto.
13639 (W_STOPCODE): Provide definition if missing.
13640
13641 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
13642
13643 * linux-low.c (linux_core_of_thread): New.
13644 (compare_ints, show_process, list_threads): New.
13645 (linux_qxfer_osdata): Report threads and cores.
13646 (linux_target_op): Register linux_core_of_thread.
13647 * remote-utils.c (prepare_resume_reply): Report the core.
13648 (buffer_xml_printf): Support %d specifier.
13649 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
13650 New.
13651 (handle_query): Handle qXfer:threads. Announce availability
13652 thereof.
13653 * target.h (struct target_ops): New field core_of_thread.
13654
13655 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
13656
13657 * Makefile.in (clean): Remove new generated files.
13658 (reg-s390.o, reg-s390.c): Remove rules.
13659 (reg-s390x.o, reg-s390x.c): Likewise.
13660 (s390-linux32.o, s390-linux32.c): Add rules.
13661 (s390-linux64.o, s390-linux64.c): Likewise.
13662 (s390x-linux64.o, s390x-linux64.c): Likewise.
13663 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
13664 * linux-s390-low.c: Include <elf.h>.
13665 (HWCAP_S390_HIGH_GPRS): Define if undefined.
13666 (init_registers_s390): Remove prototype.
13667 (init_registers_s390x): Likewise.
13668 (init_registers_s390_linux32): Add prototype.
13669 (init_registers_s390_linux64): Likewise.
13670 (init_registers_s390x_linux64): Likewise.
13671 (s390_num_regs_3264): New define.
13672 (s390_regmap_3264): New global variable.
13673 (s390_cannot_fetch_register): Remove obsolete check.
13674 (s390_cannot_store_register): Likewise.
13675 (s390_collect_ptrace_register): Handle upper/lower register halves.
13676 (s390_supply_ptrace_register): Likewise.
13677 (s390_fill_gregset): Update to register number changes.
13678 (s390_get_hwcap): New routine.
13679 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
13680 Install appropriate regmap and register set.
13681
13682 2010-01-01 Joel Brobecker <brobecker@adacore.com>
13683
13684 * server.c (gdbserver_version): Update copyright year to 2010.
13685 * gdbreplay.c (gdbreplay_version): Likewise.
13686
13687 2009-12-28 Doug Evans <dje@google.com>
13688
13689 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
13690 elf/external.h. Include <elf.h> instead but only if necessary.
13691
13692 2009-12-28 Pedro Alves <pedro@codesourcery.com>
13693
13694 * linux-low.c (linux_remove_process): Remove `detaching'
13695 parameter. Don't release/detach from thread_db here.
13696 (linux_kill): Release/detach from thread_db here, ...
13697 (linux_detach): ... and here, before actually detaching.
13698 (linux_wait_1): ... and here, when a process exits.
13699 * thread-db.c (any_thread_of): New.
13700 (thread_db_free): Switch the current inferior to a thread of the
13701 passed in process.
13702
13703 2009-12-21 Doug Evans <dje@google.com>
13704
13705 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
13706
13707 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
13708 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
13709 warning ifndef __NR_tkill. Move setting of errno there too.
13710 Delete unnecessary resetting of errno after syscall.
13711 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
13712
13713 * configure.ac: Check for dladdr.
13714 * config.in: Regenerate.
13715 * configure: Regenerate.
13716 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
13717 (try_thread_db_load): Update.
13718
13719 * linux-low.c (my_waitpid): Delete unnecessary prototype.
13720
13721 2009-12-18 Doug Evans <dje@google.com>
13722
13723 * event-loop.c: Include unistd.h if it exists.
13724
13725 * linux-low.c (my_waitpid): Move definition away from being in
13726 between linux_tracefork_child/linux_test_for_tracefork.
13727
13728 * gdb_proc_service.h (psaddr_t): Fix type.
13729 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
13730 signature to match glibc.
13731
13732 2009-12-16 Doug Evans <dje@google.com>
13733
13734 * linux-low.c (linux_read_memory): Fix argument to read.
13735
13736 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13737
13738 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
13739 events, don't leave current_inferior pointing at null.
13740
13741 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13742
13743 * win32-low.c (LOG): Delete.
13744 (OUTMSG): Output to stderr.
13745 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
13746 on compile time LOG macro.
13747 (win32_wait): Fix debug output.
13748
13749 2009-11-26 Pedro Alves <pedro@codesourcery.com>
13750
13751 * win32-low.c (win32_add_one_solib): If the dll name is
13752 "ntdll.dll", prepend the system directory to the dll path.
13753
13754 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
13755
13756 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
13757
13758 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
13759 Vladimir Prus <vladimir@codesourcery.com>
13760
13761 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
13762 * configure.ac: Check for __mcoldfire__ and set
13763 gdb_cv_m68k_is_coldfire.
13764 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
13765 reg-cf.o and reg-m68k.o.
13766 * configure: Regenerated.
13767
13768 2009-11-16 Pedro Alves <pedro@codesourcery.com>
13769
13770 * linux-low.c (linux_remove_process): Add `detaching' parameter.
13771 Pass it to thread_db_free.
13772 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
13773 proper `detaching' argument to linux_remove_process.
13774 * linux-low.h (thread_db_free): Add `detaching' parameter.
13775 * thread-db.c (thread_db_init): Pass false as `detaching' argument
13776 to thread_db_free.
13777 (thread_db_free): Add `detaching' parameter. Only
13778 call td_ta_clear_event if detaching from process.
13779
13780 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
13781
13782 * thread-db.c (thread_db_free): Fix typo.
13783
13784 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
13785
13786 PR gdb/10838
13787 * thread-db.c (thread_db_free): Call td_ta_clear_event.
13788
13789 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
13790
13791 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
13792 with an i686 compiler.
13793 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
13794 needed.
13795 * configure: Rebuilt.
13796
13797 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
13798
13799 PR gdb/10783
13800
13801 * server.c (handle_search_memory_1): Correct read_addr initialization
13802 in loop for searching subsequent chunks.
13803
13804 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
13805
13806 * configure.ac: New --with-libthread-db option.
13807 * thread-db.c: Allow direct dependence on libthread_db.
13808 (thread_db_free): Adjust.
13809 * config.in: Regenerate.
13810 * configure: Likewise.
13811
13812 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
13813
13814 PR gdb/10757
13815 * thread-db.c (attach_thread): New function.
13816 (maybe_attach_thread): Return success/failure.
13817 (find_new_threads_callback): Adjust.
13818 (thread_db_find_new_threads): Loop until no new threads.
13819
13820 2009-10-13 Pedro Alves <pedro@codesourcery.com>
13821
13822 * proc-service.c (ps_lgetregs): Formatting.
13823
13824 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
13825
13826 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
13827 * configure.ac: Adjust.
13828 * linux-low.h (struct process_info_private): Move members to struct
13829 thread_db.
13830 (thread_db_free, thread_db_handle_monitor_command): New prototype.
13831 * linux-low.c (linux_remove_process): Adjust.
13832 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
13833 * server.c (handle_query): Move code ...
13834 (handle_monitor_command): ... here. New function.
13835 * target.h (struct target_ops): New member.
13836 * thread-db.c (struct thread_db): New.
13837 (libthread_db_search_path): New variable.
13838 (thread_db_create_event, thread_db_enable_reporting)
13839 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
13840 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
13841 (try_thread_db_load_1, dladdr_to_soname): New functions.
13842 (try_thread_db_load, thread_db_load_search): New functions.
13843 (thread_db_init): Search for libthread_db.
13844 (thread_db_free): New function.
13845 (thread_db_handle_monitor_command): Likewise.
13846 * config.in: Regenerate.
13847 * configure: Regenerate.
13848
13849 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
13850
13851 * spu-low.c (spu_kill): Wait for inferior to terminate.
13852 Call clear_inferiors.
13853 (spu_detach): Call clear_inferiors.
13854
13855 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13856
13857 * aclocal.m4: Regenerate.
13858 * config.in: Likewise.
13859 * configure: Likewise.
13860
13861 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13862
13863 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
13864 (parse_spufs_run): New function.
13865 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
13866 (ppc_breakpoint_at): Handle SPU breakpoints.
13867
13868 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13869
13870 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
13871 (SPUFS_MAGIC): Define.
13872 (spu_enumerate_spu_ids): New function.
13873 (linux_qxfer_spu): New function.
13874 (linux_target_ops): Install linux_qxfer_spu.
13875
13876 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
13877
13878 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
13879 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
13880 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
13881 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
13882 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
13883 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
13884 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
13885 (init_registers_powerpc_cell32l): Add prototype.
13886 (init_registers_powerpc_cell64l): Likewise.
13887 (ppc_arch_setup): Detect Cell/B.E. architecture.
13888
13889 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
13890
13891 * Makefile.in (datarootdir): New variable.
13892
13893 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13894
13895 * linux-low.c (linux_write_memory): Update debugging output.
13896 * Makefile.in (clean): Add new descriptions.
13897 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
13898 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
13899 * configure.srv: Add new files for arm*-*-linux*.
13900 * linux-arm-low.c: Add new declarations.
13901 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
13902 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
13903 (HWCAP_VFPv3D16): New.
13904 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
13905 instead of __IWMMXT__.
13906 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
13907 (arm_arch_setup): New.
13908 (target_regsets): Remove #ifdef. Add VFP regset.
13909 (the_low_target): Use arm_arch_setup.
13910
13911 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
13912
13913 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
13914 the main thread again.
13915
13916 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
13917
13918 Adding Neutrino gdbserver.
13919 * configure: Regenerated.
13920 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
13921 * configure.srv (i[34567]86-*-nto*): New target.
13922 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
13923 * remote-utils.c [__QNX__]: Include sys/iomgr.h
13924 (nto_comctrl) [__QNX__]: New function.
13925 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
13926
13927 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
13928
13929 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
13930 srv_tgtobj.
13931
13932 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
13933 Pedro Alves <pedro@codesourcery.com>
13934
13935 * win32-i386-low.c (i386_get_thread_context): Handle systems that
13936 don't support CONTEXT_EXTENDED_REGISTERS.
13937 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
13938 (the_low_target): Install them.
13939 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
13940 failing with ERROR_PIPE_NOT_CONNECTED.
13941
13942 2009-06-30 Doug Evans <dje@google.com>
13943 Pierre Muller <muller@ics.u-strasbg.fr>
13944
13945 Add h/w watchpoint support to x86-linux, win32-i386.
13946 * Makefile.in (SFILES): Add i386-low.c
13947 (i386_low_h): Define.
13948 (i386-low.o): Add dependencies.
13949 (linux-x86-low.o): Add i386-low.h dependency.
13950 (win32-i386-low.o): Ditto.
13951 * i386-low.c: New file.
13952 * i386-low.h: New file.
13953 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
13954 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
13955 * linux-low.c (linux_add_process): Initialize arch_private.
13956 (linux_remove_process): Free arch_private.
13957 (add_lwp): Initialize arch_private.
13958 (delete_lwp): Free arch_private.
13959 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
13960 provided.
13961 * linux-low.h (process_info_private): New member arch_private.
13962 (lwp_info): New member arch_private.
13963 (linux_target_ops): New members new_process, new_thread,
13964 prepare_to_resume.
13965 (ptid_of): New macro.
13966 * linux-x86-low.c: Include stddef.h, i386-low.h.
13967 (arch_process_info): New struct.
13968 (arch_lwp_info): New struct.
13969 (x86_linux_dr_get, x86_linux_dr_set): New functions.
13970 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
13971 (i386_dr_low_get_status): New function.
13972 (x86_insert_point, x86_remove_point): New functions.
13973 (x86_stopped_by_watchpoint): New function.
13974 (x86_stopped_data_address): New function.
13975 (x86_linux_new_process, x86_linux_new_thread): New functions.
13976 (x86_linux_prepare_to_resume): New function.
13977 (the_low_target): Add entries for insert_point, remove_point,
13978 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
13979 prepare_to_resume.
13980 * server.c (debug_hw_points): New global.
13981 (monitor_show_help): Document set debug-hw-points.
13982 (handle_query): Process "set debug-hw-points".
13983 * server.h (debug_hw_points): Declare.
13984 (paddress): Declare.
13985 * utils.c (NUMCELLS, CELLSIZE): New macros.
13986 (get_sell, xsnprintf, paddress): New functions.
13987 * win32-arm-low.c (the_low_target): Add entries for insert_point,
13988 remove_point, stopped_by_watchpoint, stopped_data_address.
13989 * win32-i386-low.c: Include i386-low.h.
13990 (debug_reg_state): Replaces dr.
13991 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
13992 (i386_dr_low_get_status): New function.
13993 (i386_insert_point, i386_remove_point): New functions.
13994 (i386_stopped_by_watchpoint): New function.
13995 (i386_stopped_data_address): New function.
13996 (i386_initial_stuff): Update.
13997 (get_thread_context,set_thread_context,i386_thread_added): Update.
13998 (the_low_target): Add entries for insert_point,
13999 remove_point, stopped_by_watchpoint, stopped_data_address.
14000 * win32-low.c (win32_insert_watchpoint): New function.
14001 (win32_remove_watchpoint): New function.
14002 (win32_stopped_by_watchpoint): New function.
14003 (win32_stopped_data_address): New function.
14004 (win32_target_ops): Add entries for insert_watchpoint,
14005 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14006 * win32-low.h (win32_target_ops): New members insert_point,
14007 remove_point, stopped_by_watchpoint, stopped_data_address.
14008
14009 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14010
14011 * server.c (process_serial_event): Re-return unsupported, not
14012 error, if the type isn't recognized. Re-allow supporting only
14013 insert or remove packets. Also call require_running for
14014 breakpoints. Add missing break statement to default case. Tidy.
14015 * target.h (struct target_ops): Rename insert_watchpoint to
14016 insert_point, and remove_watchpoint to remove_point.
14017
14018 * linux-low.h (struct linux_target_ops): Likewise.
14019 * linux-low.c (linux_insert_watchpoint): Rename to ...
14020 (linux_insert_point): ... this. Adjust.
14021 (linux_remove_watchpoint): Rename to ...
14022 (linux_remove_point): ... this. Adjust.
14023 (linux_target_ops): Adjust.
14024 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14025 (cris_insert_point): ... this.
14026 (cris_remove_watchpoint): Rename to ...
14027 (cris_remove_point): ... this.
14028 (the_low_target): Adjust.
14029
14030 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14031
14032 * server.c (handle_v_kill): Pass signal_pid to
14033 kill_inferior if multi_process is zero.
14034
14035 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14036
14037 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14038 * target.h (target_ops): Comment for *_watchpoint to make it clear
14039 the functions can get types '0' and '1'.
14040
14041 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14042
14043 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14044 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14045 * regcache.c (get_regcache): Likewise.
14046 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14047 * win32-low.c (child_fetch_inferior_registers): Remove check for
14048 regno 0.
14049
14050 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14051 Pedro Alves <pedro@codesourcery.com>
14052
14053 * target.h (struct target_ops) <supports_multi_process>: New
14054 callback.
14055 (target_supports_multi_process): New.
14056 * server.c (handle_query): Even if GDB reports support, only
14057 enable multi-process if the target also supports it. Report
14058 multi-process support only if the target backend supports it.
14059 * linux-low.c (linux_supports_multi_process): New function.
14060 (linux_target_ops): Install it as target_supports_multi_process
14061 callback.
14062
14063 2009-05-24 Doug Evans <dje@google.com>
14064
14065 Global renaming of find_thread_pid to find_thread_ptid.
14066 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14067 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14068 All callers updated.
14069
14070 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14071 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14072 directly.
14073
14074 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14075 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14076 (linux_resume_one_lwp): Ditto.
14077
14078 2009-05-23 Doug Evans <dje@google.com>
14079
14080 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14081 from struct inferior_list_entry * to struct lwp_info *.
14082 All callers updated.
14083
14084 2009-05-13 Doug Evans <dje@google.com>
14085
14086 * linux-x86-low.c: Don't include assert.h.
14087 (x86_siginfo_fixup): Use fatal, not assert.
14088 (x86_arch_setup): Fix comment.
14089
14090 2009-05-12 Doug Evans <dje@google.com>
14091
14092 Biarch support for i386/amd64 gdbserver.
14093 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14094 Add linux-x86-low.c.
14095 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14096 (linux-x86-low.o): Add.
14097 * linux-x86-64-low.c: Delete.
14098 * linux-i386-low.c: Delete.
14099 * linux-x86-low.c: New file.
14100 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14101 linux-x86-low.o.
14102 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14103 linux-x86-low.o.
14104 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14105 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14106 (linux_child_pid_to_exec_file): New function.
14107 (elf_64_header_p, elf_64_file_p): New functions.
14108 (siginfo_fixup): New function.
14109 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14110 give target a chance to convert layout.
14111 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14112 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14113
14114 2009-05-07 Doug Evans <dje@google.com>
14115
14116 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14117 (regsets_store_inferior_registers): Ditto.
14118
14119 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14120
14121 PR server/10048
14122
14123 * linux-low.c (must_set_ptrace_flags): Delete.
14124 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14125 of the global.
14126 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14127 `lwp->must_set_ptrace_flags' instead.
14128 (linux_wait_for_event_1): Set ptrace options here.
14129 (linux_wait_1): ... not here.
14130
14131 2009-04-30 Doug Evans <dje@google.com>
14132
14133 * inferiors.c (started_inferior_callback): New function.
14134 (attached_inferior_callback): New function.
14135 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14136 * server.c (print_started_pid, print_attached_pid): New functions.
14137 (detach_or_kill_for_exit): New function.
14138 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14139 * server.h (have_started_inferiors_p): Declare.
14140 (have_attached_inferiors_p): Declare.
14141
14142 * inferiors.c (remove_process): Fix memory leak, free process.
14143 * linux-low.c (linux_remove_process): New function.
14144 (linux_kill): Call it instead of remove_process.
14145 (linux_detach, linux_wait_1): Ditto.
14146
14147 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14148
14149 * configure.srv: Add x86 Windows CE target.
14150
14151 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14152
14153 * inferiors.c (get_thread_process): Make global.
14154 * server.h (get_thread_process): Add prototype.
14155 * thread-db.c (find_one_thread): Use get_thread_process
14156 instead of current_process.
14157 (thread_db_get_tls_address): Do not crash if called when
14158 thread layer is not yet initialized.
14159
14160 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14161
14162 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14163 * spu-low.c (current_tid): Rename to ...
14164 (current_ptid): ... this.
14165 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14166 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14167 ptid_get_lwp (current_ptid) instead of current_tid.
14168 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14169 instead of current_tid. Use find_process_pid to verify pid
14170 argument is valid. Pass proper argument to remove_process.
14171 (spu_thread_alive): Compare current_ptid instead of current_tid.
14172 (spu_resume): Likewise.
14173
14174 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14175
14176 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14177 variable.
14178
14179 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14180
14181 Implement the multiprocess extensions, and add linux multiprocess
14182 support.
14183
14184 * server.h (ULONGEST): Declare.
14185 (struct ptid, ptid_t): New.
14186 (minus_one_ptid, null_ptid): Declare.
14187 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14188 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14189 (struct inferior_list_entry): Change `id' type from unsigned from
14190 to ptid_t.
14191 (struct sym_cache, struct breakpoint, struct
14192 process_info_private): Forward declare.
14193 (struct process_info): Declare.
14194 (current_process): Declare.
14195 (all_processes): Declare.
14196 (initialize_inferiors): Declare.
14197 (add_thread): Adjust to use ptid_t.
14198 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14199 (add_process, remove_process, find_thread_pid): Declare.
14200 (find_inferior_id): Adjust to use ptid_t.
14201 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14202 (multi_process): Declare.
14203 (push_event): Adjust to use ptid_t.
14204 (read_ptid, write_ptid): Declare.
14205 (prepare_resume_reply): Adjust to use ptid_t.
14206 (clear_symbol_cache): Declare.
14207 * inferiors.c (all_processes): New.
14208 (null_ptid, minus_one_ptid): New.
14209 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14210 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14211 (add_thread): Change unsigned long to ptid. Remove gdb_id
14212 parameter. Adjust.
14213 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14214 (gdb_id_to_thread): Rename to ...
14215 (find_thread_pid): ... this. Change unsigned long to ptid.
14216 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14217 (loaded_dll, pull_pid_from_list): Adjust.
14218 (add_process, remove_process, find_process_pid)
14219 (get_thread_process, current_process, initialize_inferiors): New.
14220 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14221 (struct target_waitstatus) <related_pid>: Ditto.
14222 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14223 return type to int.
14224 (struct target_ops) <join>: Add `pid' argument.
14225 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14226 (struct target_ops) <wait>: Add `ptid' field. Change return type
14227 to ptid.
14228 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14229 (mywait): Add `ptid' argument. Change return type to ptid_t.
14230 (target_pid_to_str): Declare.
14231 * target.c (set_desired_inferior): Adjust to use ptids.
14232 (mywait): Add new `ptid' argument. Adjust.
14233 (target_pid_to_str): New.
14234 * mem-break.h (free_all_breakpoints): Declare.
14235 * mem-break.c (breakpoints): Delelete.
14236 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14237 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14238 to use per-process breakpoint list.
14239 (free_all_breakpoints): New.
14240 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14241 (symbol_cache, all_symbols_looked_up): Delete.
14242 (hexchars): New.
14243 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14244 read_ptid): New.
14245 (prepare_resume_reply): Change ptid argument's type from unsigned
14246 long to ptid_t. Adjust. Implement W;process and X;process.
14247 (free_sym_cache, clear_symbol_cache): New.
14248 (look_up_one_symbol): Adjust to per-process symbol cache. *
14249 * server.c (cont_thread, general_thread, step_thread): Change type
14250 to ptid_t.
14251 (attached): Delete.
14252 (multi_process): New.
14253 (last_ptid): Change type to ptid_t.
14254 (struct vstop_notif) <ptid>: Change type to ptid_t.
14255 (queue_stop_reply, push_event): Change `ptid' argument's type to
14256 ptid_t.
14257 (discard_queued_stop_replies): Add `pid' argument.
14258 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14259 changes. Don't reference the `attached' global.
14260 (attach_inferior): Adjust to mywait interface changes.
14261 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14262 features. Handle and report "multiprocess+". Handle
14263 "qAttached:PID".
14264 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14265 changes.
14266 (handle_v_kill): New.
14267 (handle_v_stopped): Adjust to use target_pid_to_str.
14268 (handle_v_requests): Allow multiple attaches and runs when
14269 multiprocess extensions are in effect. Handle "vKill".
14270 (myresume): Adjust to use ptids.
14271 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14272 (handle_status): Adjust to discard_queued_stop_replies interface
14273 change.
14274 (first_thread_of, kill_inferior_callback)
14275 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14276 (main): Call initialize_inferiors. Adjust to use ptids, killing
14277 and detaching from all inferiors. Handle multiprocess packet
14278 variants.
14279 * linux-low.h: Include gdb_proc_service.h.
14280 (struct process_info_private): New.
14281 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14282 <lwpid_of>: Use ptid_get_lwp.
14283 (get_lwp_thread): Adjust.
14284 (struct lwp_info): Add `dead' member.
14285 (find_lwp_pid): Declare.
14286 * linux-low.c (thread_db_active): Delete.
14287 (new_inferior): Adjust comment.
14288 (inferior_pid): Delete.
14289 (linux_add_process): New.
14290 (handle_extended_wait): Adjust.
14291 (add_lwp): Change unsigned long to ptid.
14292 (linux_create_inferior): Add process to processes table. Adjust
14293 to use ptids. Don't set new_inferior here.
14294 (linux_attach_lwp): Rename to ...
14295 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14296 it. Adjust to use ptids.
14297 (linux_attach_lwp): New.
14298 (linux_attach): Add process to processes table. Don't set
14299 new_inferior here.
14300 (struct counter): New.
14301 (second_thread_of_pid_p, last_thread_of_process_p): New.
14302 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14303 multiple processes.
14304 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14305 processes. Remove process from process table.
14306 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14307 to multiple processes.
14308 (any_thread_of): New.
14309 (linux_detach): Add `pid' argument, and handle it. Remove process
14310 from processes table.
14311 (linux_join): Add `pid' argument. Handle it.
14312 (linux_thread_alive): Change unsighed long argument to ptid_t.
14313 Consider dead lwps as not being alive.
14314 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14315 threads we're not interested in.
14316 (same_lwp, find_lwp_pid): New.
14317 (linux_wait_for_lwp): Change `pid' argument's type from int to
14318 ptid_t. Adjust.
14319 (linux_wait_for_event): Rename to ...
14320 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14321 from int to ptid_t. Adjust.
14322 (linux_wait_for_event): New.
14323 (linux_wait_1): Add `ptid' argument. Change return type to
14324 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14325 that exit from the process table.
14326 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14327 Adjust.
14328 (mark_lwp_dead): New.
14329 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14330 stopping all threads, mark its main lwp as dead.
14331 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14332 ptids.
14333 (fetch_register, usr_store_inferior_registers)
14334 (regsets_fetch_inferior_registers)
14335 (regsets_store_inferior_registers, linux_read_memory)
14336 (linux_write_memory): Inline `inferior_pid'.
14337 (linux_look_up_symbols): Adjust to use per-process
14338 `thread_db_active'.
14339 (linux_request_interrupt): Adjust to use ptids.
14340 (linux_read_auxv): Inline `inferior_pid'.
14341 (initialize_low): Don't reference thread_db_active.
14342 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14343 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14344 (ps_getpid): Return the pid of the current inferior.
14345 * thread-db.c (proc_handle, thread_agent): Delete.
14346 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14347 per-process data.
14348 (find_one_thread): Change argument type to ptid_t. Adjust to
14349 per-process data.
14350 (maybe_attach_thread): Adjust to per-process data and ptids.
14351 (thread_db_find_new_threads): Ditto.
14352 (thread_db_init): Ditto.
14353 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14354 processes table. Adjust to use ptids.
14355 (spu_kill, spu_detach): Adjust interface. Remove process from
14356 processes table.
14357 (spu_join, spu_thread_alive): Adjust interface.
14358 (spu_wait): Adjust interface. Remove process from processes
14359 table. Adjust to use ptids.
14360 * win32-low.c (current_inferior_tid): Delete.
14361 (current_inferior_ptid): New.
14362 (debug_event_ptid): New.
14363 (thread_rec): Take a ptid. Adjust.
14364 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14365 (child_delete_thread): Ditto.
14366 (do_initial_child_stuff): Add `attached' argument. Add process to
14367 processes table.
14368 (child_fetch_inferior_registers, child_store_inferior_registers):
14369 Adjust.
14370 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14371 (win32_attach): Pass 1 to do_initial_child_stuff.
14372 (win32_kill): Adjust interface. Remove process from processes
14373 table.
14374 (win32_detach): Ditto.
14375 (win32_join): Adjust interface.
14376 (win32_thread_alive): Take a ptid.
14377 (win32_resume): Adjust to use ptids.
14378 (get_child_debug_event): Ditto.
14379 (win32_wait): Adjust interface. Remove exiting process from
14380 processes table.
14381
14382 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14383
14384 Non-stop mode support.
14385
14386 * server.h (non_stop): Declare.
14387 (gdb_client_data, handler_func): Declare.
14388 (delete_file_handler, add_file_handler, start_event_loop):
14389 Declare.
14390 (handle_serial_event, handle_target_event, push_event)
14391 (putpkt_notif): Declare.
14392 * target.h (enum resume_kind): New.
14393 (struct thread_resume): Replace `step' field by `kind' field.
14394 (TARGET_WNOHANG): Define.
14395 (struct target_ops) <wait>: Add `options' argument.
14396 <supports_non_stop, async, start_non_stop>: New fields.
14397 (target_supports_non_stop, target_async): New.
14398 (start_non_stop): Declare.
14399 (mywait): Add `options' argument.
14400 * target.c (mywait): Add `options' argument. Print child exit
14401 notifications here.
14402 (start_non_stop): New.
14403 * server.c (non_stop, own_buf, mem_buf): New globals.
14404 (struct vstop_notif): New.
14405 (notif_queue): New global.
14406 (queue_stop_reply, push_event, discard_queued_stop_replies)
14407 (send_next_stop_reply): New.
14408 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14409 interface changes.
14410 (attach_inferior): In non-stop mode, don't wait for the target
14411 here.
14412 (handle_general_set): Handle QNonStop.
14413 (handle_query): When handling qC, return the current general
14414 thread, instead of the first thread of the list.
14415 (handle_query): If the backend supports non-stop mode, include
14416 QNonStop+ in the qSupported query response.
14417 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14418 and non-stop mode.
14419 (handle_v_attach, handle_v_run): Handle non-stop mode.
14420 (handle_v_stopped): New.
14421 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14422 (myresume): Adjust to use resume_kind. Handle non-stop.
14423 (queue_stop_reply_callback): New.
14424 (handle_status): Handle non-stop mode.
14425 (main): Clear non_stop flag on reconnection. Use the event-loop.
14426 Refactor serial protocol handling from here ...
14427 (process_serial_event): ... to this new function. When GDB
14428 selects any thread, select one here. In non-stop mode, wait until
14429 GDB acks all pending events before exiting.
14430 (handle_serial_event, handle_target_event): New.
14431 * remote-utils.c (remote_open): Install remote_desc in the event
14432 loop.
14433 (remote_close): Remove remote_desc from the event loop.
14434 (putpkt_binary): Rename to...
14435 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14436 (putpkt_binary): New as wrapper around putpkt_binary_1.
14437 (putpkt_notif): New.
14438 (prepare_resume_reply): In non-stop mode, don't change the
14439 general_thread.
14440 * event-loop.c: New.
14441 * Makefile.in (OBJ): Add event-loop.o.
14442 (event-loop.o): New rule.
14443
14444 * linux-low.h (pid_of): Moved here.
14445 (lwpid_of): New.
14446 (get_lwp_thread): Use lwpid_of.
14447 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14448 * linux-low.c (pid_of): Delete.
14449 (inferior_pid): Use lwpid_of.
14450 (linux_event_pipe): New.
14451 (target_is_async_p): New.
14452 (delete_lwp): New.
14453 (handle_extended_wait): Use lwpid_of.
14454 (add_lwp): Don't set lwpid field.
14455 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14456 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14457 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14458 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14459 first. Adjust to linux_wait_for_event interface changes. Use
14460 lwpid_of.
14461 (linux_detach): Don't delete the main lwp here.
14462 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14463 (status_pending_p): Don't consider explicitly suspended lwps.
14464 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14465 pointer. Add OPTIONS argument. Change return type to int. Use
14466 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14467 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14468 pointer. Add status pointer argument. Return a pid instead of a
14469 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14470 changes. In non-stop mode, don't switch to a random thread.
14471 (linux_wait): Rename to...
14472 (linux_wait_1): ... this. Add target_options argument, and handle
14473 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14474 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14475 clean exit and signal exit code. Don't stop all threads in
14476 non-stop mode. In all-stop mode, only stop all threads when
14477 reporting a stop to GDB. Handle explicit thread stop requests.
14478 (async_file_flush, async_file_mark): New.
14479 (linux_wait): New.
14480 (send_sigstop): Use lwpid_of.
14481 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14482 interface changes. In non-stop mode, don't switch to a random
14483 thread.
14484 (linux_resume_one_lwp): Use lwpid_of.
14485 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14486 (linux_resume_one_thread): ... this. Handle resume_stop. In
14487 non-stop mode, don't look for pending flag in all threads.
14488 (resume_status_pending_p): Don't consider explicitly suspended
14489 threads.
14490 (my_waitpid): Reimplement. Emulate __WALL.
14491 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14492 Use lwpid_of.
14493 (sigchld_handler, linux_supports_non_stop, linux_async)
14494 (linux_start_non_stop): New.
14495 (linux_target_ops): Register linux_supports_non_stop, linux_async
14496 and linux_start_non_stop.
14497 (initialize_low): Install SIGCHLD handler.
14498 * thread-db.c (thread_db_create_event, find_one_thread)
14499 (thread_db_get_tls_address): Use lwpid_of.
14500 * win32-low.c (win32_detach): Adjust to use resume_kind.
14501 (win32_wait): Add `options' argument.
14502 * spu-low.c (spu_resume): Adjust to use resume_kind.
14503 (spu_wait): Add `options' argument.
14504
14505 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14506
14507 Decouple target code from remote protocol.
14508
14509 * target.h (enum target_waitkind): New.
14510 (struct target_waitstatus): New.
14511 (struct target_ops) <wait>: Return an unsigned long. Take a
14512 target_waitstatus pointer instead of a char pointer.
14513 (mywait): Likewise.
14514 * target.c (mywait): Change prototype to return an unsigned long.
14515 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14516 * server.h (thread_from_wait, old_thread_from_wait): Delete
14517 declarations.
14518 (prepare_resume_reply): Change prototype to take a
14519 target_waitstatus.
14520 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14521 (last_status, last_ptid): New.
14522 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14523 pid instead of a signal.
14524 (attach_inferior): Remove "status" and "signal" parameters.
14525 Adjust.
14526 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14527 not as an address.
14528 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14529 (handle_v_requests, myresume): Remove "status" and "signal"
14530 parameters. Adjust.
14531 (handle_status): New.
14532 (main): Delete local `status'. Adjust.
14533 * remote-utils.c: Include target.h.
14534 (prepare_resume_reply): Change prototype to take a
14535 target_waitstatus. Adjust.
14536
14537 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14538 interface.
14539 * spu-low.c (spu_wait): Adjust.
14540 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14541 Delete.
14542 (win32_wait): Adjust.
14543
14544 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14545
14546 * target.h (struct thread_resume): Delete leave_stopped member.
14547 (struct target_ops): Add a `n' argument to the `resume' callback.
14548 * server.c (start_inferior): Adjust.
14549 (handle_v_cont, myresume): Adjust.
14550 * linux-low.c (check_removed_breakpoint): Adjust to resume
14551 interface change, and to removed leave_stopped field.
14552 (resume_ptr): Delete.
14553 (struct thread_resume_array): New.
14554 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14555 resume interface change.
14556 (linux_continue_one_thread, linux_queue_one_thread)
14557 (resume_status_pending_p): Check if the resume field is NULL
14558 instead of checking the leave_stopped member.
14559 (linux_resume): Adjust to the target resume interface change.
14560 * spu-low.c (spu_resume): Adjust to the target resume interface
14561 change.
14562 * win32-low.c (win32_detach, win32_resume): Ditto.
14563
14564 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14565
14566 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
14567 flag.
14568 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
14569 pending.
14570 (linux_continue_one_thread): Only preserve the stepping flag if
14571 there's a pending breakpoint.
14572
14573 2009-03-31 Pedro Alves <pedro@codesourcery.com>
14574
14575 * server.c (main): After the inferior having exited, call
14576 remote_close before exiting gdbserver.
14577
14578 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
14579
14580 Fix size of FPSCR in Power 7 processors.
14581 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
14582 (PPC_FEATURE_HAS_DFP): New #define.
14583 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
14584 size of the FPSCR.
14585
14586 2009-03-23 Pedro Alves <pedro@codesourcery.com>
14587
14588 * server.c (handle_query) Whitespace and formatting.
14589
14590 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14591
14592 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
14593 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
14594 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
14595 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
14596 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
14597 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
14598 Makefile.in, configure.ac: Fix whitespace throughout.
14599 * configure: Regenerate.
14600
14601 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14602
14603 * inferiors.c (find_inferior): Make it safe for the callback
14604 function to delete the currently iterated inferior.
14605
14606 2009-03-22 Pedro Alves <pedro@codesourcery.com>
14607
14608 * Makefile.in (linuw_low_h): Move higher.
14609 (thread-db.o): Depend on $(linux_low_h).
14610
14611 2009-03-17 Pedro Alves <pedro@codesourcery.com>
14612
14613 Rename "process" to "lwp" throughout.
14614
14615 * linux-low.c (all_processes): Rename to...
14616 (all_lwps): ... this.
14617 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
14618 (add_process): Rename to ...
14619 (add_lwp): ... this. Adjust.
14620 (linux_create_inferior): Adjust.
14621 (linux_attach_lwp): Adjust.
14622 (linux_attach): Adjust.
14623 (linux_kill_one_process): Rename to ...
14624 (linux_kill_one_lwp): ... this. Adjust.
14625 (linux_kill): Adjust.
14626 (linux_detach_one_process): Rename to ...
14627 (linux_detach_one_lwp): ... this. Adjust.
14628 (linux_detach): Adjust.
14629 (check_removed_breakpoint): Adjust.
14630 (status_pending_p): Adjust.
14631 (linux_wait_for_process): Rename to ...
14632 (linux_wait_for_lwp): ... this. Adjust.
14633 (linux_wait_for_event): Adjust.
14634 (send_sigstop): Adjust.
14635 (wait_for_sigstop): Adjust.
14636 (stop_all_processes): Rename to ...
14637 (stop_all_lwps): ... this.
14638 (linux_resume_one_process): Rename to ...
14639 (linux_resume_one_lwp): ... this. Adjust.
14640 (linux_set_resume_request, linux_continue_one_thread)
14641 (linux_queue_one_thread, resume_status_pending_p)
14642 (usr_store_inferior_registers, regsets_store_inferior_registers)
14643 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14644 Adjust.
14645 * linux-low.h (get_process): Rename to ...
14646 (get_lwp): ... this. Adjust.
14647 (get_thread_process): Rename to ...
14648 (get_thread_lwp): ... this. Adjust.
14649 (get_process_thread): Rename to ...
14650 (get_lwp_thread): ... this. Adjust.
14651 (struct process_info): Rename to ...
14652 (struct lwp_info): ... this.
14653 (all_processes): Rename to ...
14654 (all_lwps): ... this.
14655 * proc-service.c (ps_lgetregs): Adjust.
14656 * thread-db.c (thread_db_create_event, find_one_thread)
14657 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
14658
14659 2009-03-14 Pedro Alves <pedro@codesourcery.com>
14660
14661 * server.c (handle_query): Handle "qAttached".
14662
14663 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
14664
14665 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
14666 GPLv3, update license URL.
14667
14668 2009-03-01 Doug Evans <dje@google.com>
14669
14670 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
14671 (server_h): Add gdb_signals.h.
14672 (signals.o): Update.
14673 * server.h (target_signal_from_host,target_signal_to_host_p)
14674 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
14675
14676 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
14677
14678 * remote-utils.c (getpkt): Also generate remote-debug
14679 information if noack_mode is set.
14680
14681 2009-02-06 Pedro Alves <pedro@codesourcery.com>
14682
14683 * server.c (handle_query): Report qXfer:siginfo:read and
14684 qXfer:siginfo:write as supported and handle them.
14685 * target.h (struct target_ops) <qxfer_siginfo>: New field.
14686 * linux-low.c (linux_xfer_siginfo): New.
14687 (linux_target_ops): Set it.
14688
14689 2009-01-26 Pedro Alves <pedro@codesourcery.com>
14690
14691 * server.c (gdbserver_usage): Mention --remote-debug.
14692 (main): Accept '--remote-debug' switch.
14693
14694 2009-01-18 Doug Evans <dje@google.com>
14695
14696 * regcache.c (new_register_cache): No need to check result of xcalloc.
14697 * server.c (handle_search_memory): Back out calls to xmalloc,
14698 result is checked and error is returned to user upon failure.
14699 (handle_query): Ditto. Add more checks for result of malloc.
14700 (handle_v_cont): Check result of malloc, report error back to
14701 user upon failure.
14702 (handle_v_run): Ditto. Call freeargv.
14703 * server.h (freeargv): Declare.
14704 * utils.c (freeargv): New fn.
14705
14706 2009-01-15 Doug Evans <dje@google.com>
14707
14708 * gdbreplay.c (perror_with_name): Make arg const char *.
14709 * server.h (target_signal_to_name): Make return type const char *.
14710 * thread-db.c (thread_db_err_str): Make return type const char *.
14711 * utils.c (perror_with_name): Make arg const char *.
14712
14713 2009-01-14 Pedro Alves <pedro@codesourcery.com>
14714
14715 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
14716 when handling a EXIT_PROCESS_DEBUG_EVENT.
14717
14718 2009-01-06 Joel Brobecker <brobecker@adacore.com>
14719
14720 * gdbreplay.c (gdbreplay_version): Update copyright year.
14721 * server.c (gdbserver_version): Likewise.
14722
14723 2009-01-05 Doug Evans <dje@google.com>
14724
14725 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
14726 (handle_extended_wait): Improve comment.
14727
14728 2008-12-13 Doug Evans <dje@google.com>
14729
14730 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
14731 * server.h (ATTR_MALLOC): New macro.
14732 (xmalloc,xcalloc,xstrdup): Declare.
14733 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
14734 * inferiors.c: Ditto.
14735 * linux-low.c: Ditto.
14736 * mem-break.c: Ditto.
14737 * regcache.c: Ditto.
14738 * remote-utils.c: Ditto.
14739 * server.c: Ditto.
14740 * target.c: Ditto.
14741 * win32-low.c: Ditto.
14742
14743 2008-12-12 Doug Evans <dje@google.com>
14744
14745 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
14746 in debugging printf.
14747
14748 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
14749
14750 2008-12-09 Doug Evans <dje@google.com>
14751
14752 * linux-low.h (struct process_info): Delete member tid, unused.
14753 * thread-db.c (find_one_thread): Update.
14754 (maybe_attach_thread): Update.
14755
14756 2008-12-02 Pedro Alves <pedro@codesourcery.com>
14757
14758 * target.h (struct target_ops): Add qxfer_osdata member.
14759 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
14760 and dirent.h.
14761 (linux_qxfer_osdata): New functions.
14762 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
14763 callback.
14764 * server.c (handle_query): Handle "qXfer:osdata:read:".
14765 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
14766 (buffer_xml_printf): New functions.
14767 * server.h (struct buffer): New.
14768 (buffer_grow_str, buffer_grow_str0): New macros.
14769 (buffer_grow, buffer_free, buffer_init, buffer_finish)
14770 (buffer_xml_printf): Declare.
14771
14772 2008-11-24 Doug Evans <dje@google.com>
14773
14774 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
14775
14776 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
14777
14778 * server.c (handle_v_run): Always use the supplied argument list.
14779
14780 2008-11-19 Bob Wilson <bob.wilson@acm.org>
14781
14782 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
14783 (xtensa_regmap_table): Add entry for scompare1.
14784
14785 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
14786
14787 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
14788 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
14789 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
14790 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
14791 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
14792 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
14793 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
14794 XML target descriptions.
14795 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
14796 when inferior is running on an ISA 2.05 or later processor. Add
14797 special case to return offset for full 64-bit slot of FPSCR when
14798 in 32-bits.
14799
14800 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
14801
14802 * Makefile.in (SFILES, clean): Added sparc64 files.
14803 (reg-sparc64.o, reg-sparc64.c): New.
14804 * configure.srv (sparc*-*-linux*): New configuration.
14805 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
14806 syscall arguments for SPARC.
14807 (regsets_store_inferior_registers): Likewise.
14808 * linux-sparc-low.c: New file.
14809
14810 2008-10-21 Doug Evans <dje@google.com>
14811
14812 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
14813 (READLINE_DIR,READLINE_DEP): Delete.
14814 (INTERNAL_CFLAGS): Update.
14815 (LINTFLAGS): Update.
14816
14817 2008-10-10 Pedro Alves <pedro@codesourcery.com>
14818
14819 * server.c (handle_v_run): If GDB didn't specify an argv, use the
14820 whole argv from the last run, not just argv[0].
14821
14822 2008-09-08 Pedro Alves <pedro@codesourcery.com>
14823
14824 * regcache.c (new_register_cache): Return NULL if the register
14825 cache size isn't known yet.
14826 (free_register_cache): Avoid dereferencing a NULL regcache.
14827
14828 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
14829
14830 * configure.srv: Merge MIPS and MIPS64.
14831
14832 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
14833
14834 * Makefile.in (uninstall): Apply $(EXEEXT) too.
14835
14836 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
14837
14838 * Makefile.in: Add required vsx dependencies.
14839
14840 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
14841 Declare init_registers_powerpc_vsx32l.
14842 Declare init_registers_powerpc_vsx64l.
14843 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
14844 (ppc_arch_setup): Check for VSX in hwcap.
14845 (ppc_fill_vsxregset): New function.
14846 (ppc_store_vsxregset): New function.
14847 Add new VSX entry in regset_info target_regsets.
14848
14849 * configure.srv: Add new VSX dependencies.
14850
14851 2008-08-12 Pedro Alves <pedro@codesourcery.com>
14852
14853 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
14854 (remote_open): Set or clear transport_is_reliable.
14855 (putpkt_binary): Don't expect acks in noack mode.
14856 (getpkt): Don't send ack/nac in noack mode.
14857 * server.c (handle_general_set): Handle QStartNoAckMode.
14858 (handle_query): If connected by tcp pass QStartNoAckMode+ in
14859 qSupported.
14860 (main): Reset noack_mode on every connection.
14861 * server.h (noack_mode): Declare.
14862
14863 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14864
14865 * Makefile.in (GDBREPLAY_OBS): New variable.
14866 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
14867
14868 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
14869 Daniel Jacobowitz <dan@codesourcery.com>
14870
14871 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
14872 (usr_store_inferior_registers): Likewise.
14873 (regsets_store_inferior_registers): Likewise.
14874
14875 2008-07-31 Rolf Jansen <rj@surtec.com>
14876 Pedro Alves <pedro@codesourcery.com>
14877
14878 * configure.ac: Check for memmem declaration.
14879 * server.c [HAVE_MALLOC_H]: Include malloc.h.
14880 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
14881 (disable_packet_qfThreadInfo): Unconditionally compile.
14882 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
14883 * configure, config.in: Regenerate.
14884
14885 2008-07-28 Doug Kwan <dougkwan@google.com>
14886
14887 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
14888 (linux_write_memory): Remove declaration of errno.
14889
14890 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
14891
14892 * linux-low.c (handle_extended_wait): Do not use "status"
14893 variable uninitialized.
14894
14895 2008-07-07 Pedro Alves <pedro@codesourcery.com>
14896
14897 * server.c (handle_v_attach): Inhibit reporting dll changes.
14898
14899 2008-06-27 Pedro Alves <pedro@codesourcery.com>
14900
14901 * remote-utils.c (prepare_resume_reply): If requested, don't
14902 output "thread:TID" in the T stop reply.
14903
14904 * server.c (disable_packet_vCont, disable_packet_Tthread)
14905 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
14906 (handle_query): If requested, disable support for qC, qfThreadInfo
14907 and qsThreadInfo.
14908 (handle_v_requests): If requested, disable support for vCont.
14909 (gdbserver_show_disableable): New.
14910 (main): Handle --disable-packet and --disable-packet=LIST.
14911
14912 * server.h (disable_packet_vCont, disable_packet_Tthread)
14913 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
14914
14915 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
14916
14917 * server.c (gdbserver_usage): Mention --version.
14918
14919 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
14920
14921 * Makefile.in (gdbreplay.o): New rule.
14922
14923 2008-06-06 Joseph Myers <joseph@codesourcery.com>
14924
14925 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
14926 message, not gdbserver.
14927
14928 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
14929 Nathan Sidwell <nathan@codesourcery.com>
14930 Joseph Myers <joseph@codesourcery.com>
14931
14932 * acinclude.m4: Include ../../config/acx.m4.
14933 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
14934 * configure, config.in: Regenerate.
14935 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
14936 * server.c (gdbserver_version): Print PKGVERSION.
14937 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
14938 (main): Adjust gdbserver_usage calls.
14939 * gdbreplay.c (version, host_name): Add declarations.
14940 (gdbreplay_version, gdbreplay_usage): New.
14941 (main): Accept --version and --help options.
14942
14943 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
14944
14945 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
14946 (arm_breakpoint_at): Handle Thumb.
14947 (the_low_target): Add comment.
14948
14949 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
14950
14951 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
14952
14953 2008-05-09 Doug Evans <dje@google.com>
14954
14955 * server.h (decode_search_memory_packet): Declare.
14956 * remote-utils.c (decode_search_memory_packet): New fn.
14957 * server.c (handle_search_memory_1): New fn.
14958 (handle_search_memory): New fn.
14959 (handle_query): Process qSearch:memory packets.
14960
14961 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
14962
14963 * regcache.c (registers_length): Remove.
14964 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
14965 full register packet.
14966 * regcache.h (registers_length): Remove prototype.
14967 * server.h (PBUFSIZ): Define to 16384.
14968
14969 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
14970
14971 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
14972 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
14973 powerpc-64l.o, and powerpc-altivec64l.o.
14974 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
14975 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
14976 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
14977 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
14978 rs6000/power-linux.xml, and rs6000/power64-linux.xml
14979 to srv_xmlfiles.
14980
14981 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
14982 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
14983 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
14984 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
14985 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
14986 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
14987 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
14988 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
14989 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
14990 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
14991 (clean): Update.
14992
14993 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
14994 (init_registers_powerpc_32l): ... this new prototype.
14995 (init_registers_powerpc_32): Remove, replace by ...
14996 (init_registers_powerpc_altivec32l): ... this new prototype.
14997 (init_registers_powerpc_e500): Remove, replace by ...
14998 (init_registers_powerpc_e500l): ... this new prototype.
14999 (init_registers_ppc64): Remove, replace by ...
15000 (init_registers_powerpc_64l): ... this new prototype.
15001 (init_registers_powerpc_64): Remove, replace by ...
15002 (init_registers_powerpc_altivec64l): ... this new prototype.
15003 (ppc_num_regs): Set to 73.
15004 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15005 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15006 (ppc_cannot_store_register): Handle orig_r3 and trap.
15007 (ppc_arch_setup): Update init_registers_... calls.
15008 (ppc_fill_gregset): Handle orig_r3 and trap.
15009
15010 * inferiors.c (clear_inferiors): Reset current_inferior.
15011
15012 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15013
15014 * acinclude.m4: Add override.m4.
15015 * configure: Regenerate.
15016
15017 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15018
15019 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15020 initial call to init_register_ppc64.
15021
15022 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15023
15024 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15025 single powerpc*-*-linux* case.
15026 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15027
15028 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15029
15030 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15031 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15032 from reg_xmlfiles.
15033 * linux-ppc-low.c: Include <elf.h>.
15034 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15035 (ppc_hwcap): New global variable.
15036 (ppc_regmap): Remove __SPE__ #ifdef sections.
15037 (ppc_regmap_e500): New global variable.
15038 (ppc_cannot_store_register): Update __SPE__ special case.
15039 (ppc_get_hwcap): New function.
15040 (ppc_arch_setup): Use it to determine whether inferior supports
15041 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15042 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15043 Do not access registers if target does not support AltiVec.
15044 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15045 Do not access registers if target does not support SPE.
15046 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15047
15048 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15049
15050 * linux-low.c (disabled_regsets, num_regsets): New.
15051 (use_regsets_p): Delete.
15052 (linux_wait_for_process): Clear disabled_regsets.
15053 (regsets_fetch_inferior_registers): Check and set it.
15054 (regsets_store_inferior_registers): Likewise.
15055 (linux_fetch_registers, linux_store_registers): Do not use
15056 use_regsets_p.
15057 (initialize_low): Allocate disabled_regsets.
15058
15059 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15060
15061 * Makefile.in (LIBOBJS): New.
15062 (OBS): Use LIBOBJS.
15063 (memmem.o): New rule.
15064 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15065 * configure: Regenerated.
15066
15067 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15068
15069 * server.c (handle_query): Never return "unsupported" for
15070 qXfer:features:read queries.
15071
15072 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15073
15074 * server.c (get_features_xml): Fix inverted condition.
15075 (handle_query): Always support qXfer:feature:read.
15076
15077 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15078
15079 * server.c (wrapper_argv): New.
15080 (start_inferior): Handle wrapper_argv. If set, expect an extra
15081 trap.
15082 (gdbserver_usage): Document --wrapper.
15083 (main): Parse --wrapper.
15084
15085 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15086
15087 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15088 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15089 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15090 (ppc_set_pc): Likewise.
15091 (ppc_arch_setup): New function.
15092 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15093 of collect_register.
15094 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15095
15096 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15097
15098 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15099 instead of linux-ppc64-low.o.
15100 * linux-ppc64-low.c: Remove file.
15101 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15102 (linux-ppc64-low.o): Remove rule.
15103
15104 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15105 (init_registers_powerpc_64): Likewise.
15106 (ppc_regmap): Conditionally define depending on __powerpc64__.
15107 (ppc_cannot_store_register): Do not special-case "fpscr" when
15108 compiled on __powerpc64__.
15109 (ppc_collect_ptrace_register): New function.
15110 (ppc_supply_ptrace_register): New function.
15111 (ppc_breakpoint): Change type to "unsigned int".
15112 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15113 (the_low_target): Conditionally provide initializers for the
15114 arch_setup member depending on __powerpc64__. Install
15115 collect_ptrace_register and supply_ptrace_register members.
15116
15117 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15118
15119 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15120 * server.c (gdbserver_xmltarget): Define.
15121 (get_features_xml): Use it to replace "target.xml" and arch_string.
15122
15123 * configure.srv: Remove srv_xmltarget. Add XML files that were
15124 mentioned there to srv_xmlfiles instead. Remove conditional tests
15125 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15126 srv_xmlfiles and srv_regobj to include all possible choices.
15127 * configure.ac (srv_xmltarget): Remove.
15128 (srv_xmlfiles): Do not add "target.xml".
15129 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15130 checks for supplementary target information.
15131 * configure: Regenerate.
15132 * Makefile.in (XML_TARGET): Remove.
15133 (target.xml): Remove rule.
15134 (clean): Do not clean up target.xml.
15135 (.PRECIOUS): Do not mention target.xml.
15136
15137 * target.h (struct target_ops): Remove arch_string member.
15138 * linux-low.c (linux_arch_string): Remove.
15139 (linux_target_ops): Remove arch_string initializer.
15140 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15141 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15142 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15143 * spu-low.c (spu_arch_string): Remove.
15144 (spu_target_ops): Remove arch_string initializer.
15145 * win32-low.c (win32_arch_string): Remove.
15146 (win32_target_ops): Remove arch_string initializer.
15147 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15148 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15149 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15150
15151 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15152
15153 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15154 by collect_ptrace_register and supply_ptrace_register hooks.
15155 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15156 instead of checking for the_low_target.left_pad_xfer.
15157 (usr_store_inferior_registers): Use collect_ptrace_register callback
15158 instead of checking for the_low_target.left_pad_xfer.
15159
15160 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15161 (s390_supply_ptrace_register): Likewise.
15162 (s390_fill_gregset): Call s390_collect_ptrace_register.
15163 (the_low_target): Update.
15164
15165 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15166 (ppc_supply_ptrace_register): Likewise.
15167 (the_low_target): Update.
15168
15169 * linux-i386-low.c (the_low_target): Update.
15170 * linux-x86-64-low.c (the_low_target): Update.
15171
15172 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15173
15174 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15175 reg-s390.o and reg-s390x.o.
15176
15177 * linux-low.c (new_inferior): New global variable.
15178 (linux_create_inferior, linux_attach): Set it.
15179 (linux_wait_for_process): Call the_low_target.arch_setup after the
15180 target has stopped for the first time.
15181 (initialize_low): Do not call the_low_target.arch_setup.
15182
15183 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15184 (s390_set_pc): Likewise.
15185 (s390_arch_setup): New function.
15186 (the_low_target): Use s390_arch_setup as arch_setup routine.
15187
15188 * regcache.c (realloc_register_cache): New function.
15189 (set_register_cache): Call it for each existing regcache.
15190
15191 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15192
15193 * server.h (init_registers): Remove prototype.
15194
15195 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15196 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15197 instead of init_registers ().
15198 * linux-arm-low.c (init_registers_arm): Add prototype.
15199 (init_registers_arm_with_iwmmxt): Likewise.
15200 (the_low_target): Add initializer for arch_setup field.
15201 * linux-cris-low.c (init_registers_cris): Add prototype.
15202 (the_low_target): Add initializer for arch_setup field.
15203 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15204 (the_low_target): Add initializer for arch_setup field.
15205 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15206 (the_low_target): Add initializer for arch_setup field.
15207 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15208 (the_low_target): Add initializer for arch_setup field.
15209 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15210 (the_low_target): Add initializer for arch_setup field.
15211 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15212 (the_low_target): Add initializer for arch_setup field.
15213 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15214 (init_registers_mips64_linux): Likewise.
15215 (the_low_target): Add initializer for arch_setup field.
15216 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15217 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15218 (the_low_target): Add initializer for arch_setup field.
15219 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15220 (init_registers_powerpc_64): Likewise.
15221 (the_low_target): Add initializer for arch_setup field.
15222 * linux-s390-low.c (init_registers_s390): Add prototype.
15223 (init_registers_s390x): Likewise.
15224 (the_low_target): Add initializer for arch_setup field.
15225 * linux-sh-low.c (init_registers_sh): Add prototype.
15226 (the_low_target): Add initializer for arch_setup field.
15227 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15228 (the_low_target): Add initializer for arch_setup field.
15229 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15230 (the_low_target): Add initializer for arch_setup field.
15231
15232 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15233 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15234 instead of init_registers ().
15235 * win32-arm-low.c (init_registers_arm): Add prototype.
15236 (the_low_target): Add initializer for arch_setup field.
15237 * win32-i386-low.c (init_registers_i386): Add prototype.
15238 (the_low_target): Add initializer for arch_setup field.
15239
15240 * spu-low.c (init_registers_spu): Add prototype.
15241 (initialize_low): Call initialie_registers_spu () instead of
15242 initialize_registers ().
15243
15244 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15245
15246 * server.c (handle_v_requests): When handling the vRun and vAttach
15247 packets, if already debugging a process, don't kill it. Return an
15248 error instead.
15249
15250 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15251
15252 * server.c (handle_query): Correct length check.
15253
15254 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15255
15256 * win32-low.c (do_initial_child_stuff): Add process handle
15257 parameter. Set current_process_handle and current_process_id from the
15258 parameters. Clear globals.
15259 (win32_create_inferior): Don't set current_process_handle and
15260 current_process_id here. Instead pass them on the call to
15261 do_initial_child_stuff.
15262 (win32_attach): Likewise.
15263 (win32_clear_inferiors): New.
15264 (win32_kill): Don't close the current process handle or the
15265 current thread handle here. Instead call win32_clear_inferiors.
15266 (win32_detach): Don't open a new handle to the process. Call
15267 win32_clear_inferiors.
15268 (win32_join): Don't rely on current_process_handle; open a new
15269 handle using the process id.
15270 (win32_wait): Call win32_clear_inferiors when the inferior process
15271 has exited.
15272
15273 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15274
15275 * server.c (monitor_show_help): Add "exit".
15276
15277 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15278
15279 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15280 (clean): Add reg-xtensa.c.
15281 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15282 * configure.srv (xtensa*-*-linux*) New target.
15283 * linux-xtensa-low.c: New.
15284 * xtensa-xtregs.c: New.
15285
15286 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15287
15288 * hostio.c: Don't include errno.h.
15289 (errno_to_fileio_errno): Move to hostio-errno.
15290 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15291 error number outputting to the target->hostio_last_error callback.
15292 (hostio_packet_error): Use FILEIO_EINVAL directly.
15293 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15294 calls to hostio_error.
15295 * hostio-errno.c: New.
15296 * server.h (hostio_last_error_from_errno): Declare.
15297 * target.h (target_ops): Add hostio_last_error member.
15298 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15299 as hostio_last_error handler.
15300 * spu-low.c (spu_target_ops): Likewise.
15301 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15302 (wince_hostio_last_error): New functions.
15303 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15304 as hostio_last_error handler.
15305 (win32_target_ops) [!_WIN32_WCE]: Register
15306 hostio_last_error_from_errno as hostio_last_error handler.
15307 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15308 (hostio-errno.o): New rule.
15309 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15310 * configure.srv (srv_hostio_err_objs): New variable. Default to
15311 hostio-errno.o.
15312 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15313 * configure: Regenerate.
15314
15315 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15316
15317 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15318 (linux_kill, linux_detach): Clean up the process list.
15319 * remote-utils.c (remote_open): Improve port number parsing.
15320 (putpkt_binary, input_interrupt): Only send interrupts if the target
15321 is running.
15322 * server.c (extended_protocol): Make static.
15323 (attached): Define earlier.
15324 (exit_requested, response_needed, program_argv): New variables.
15325 (target_running): New.
15326 (start_inferior): Clear attached here.
15327 (attach_inferior): Set attached here.
15328 (require_running): Define.
15329 (handle_query): Use require_running and target_running. Implement
15330 "monitor exit".
15331 (handle_v_attach, handle_v_run): New.
15332 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15333 (gdbserver_usage): Update.
15334 (main): Redo argument parsing. Handle --debug and --multi. Handle
15335 --attach along with other options or after the port. Save
15336 program_argv. Support no initial program. Resynchronize
15337 communication with GDB after an error. Handle "monitor exit".
15338 Use require_running and target_running. Always allow the extended
15339 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15340 restart in extended mode.
15341 * README: Refer to the GDB manual. Update --attach usage.
15342
15343 2007-12-20 Andreas Schwab <schwab@suse.de>
15344
15345 * linux-low.c (STACK_SIZE): Define.
15346 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15347 (linux_test_for_tracefork): Likewise.
15348
15349 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15350
15351 * linux-low.c (linux_wait_for_event): Update messages. Do not
15352 reinsert auto-delete breakpoints.
15353 * mem-break.c (struct breakpoint): Change return type of handler to
15354 int.
15355 (set_breakpoint_at): Update handler type.
15356 (reinsert_breakpoint_handler): Return 1 instead of calling
15357 delete_breakpoint.
15358 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15359 setting a new one.
15360 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15361 * mem-break.h (set_breakpoint_at): Update handler type.
15362 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15363 * win32-low.c (auto_delete_breakpoint): New.
15364 (get_child_debug_event): Use it.
15365
15366 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15367
15368 * configure.ac: Check for pread and pwrite.
15369 * hostio.c (handle_pread): Fall back to lseek and read.
15370 (handle_pwrite): Fall back to lseek and write.
15371 * config.in, configure: Regenerated.
15372
15373 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15374
15375 * server.c (myresume): Add own_buf argument.
15376 (main): Update calls.
15377
15378 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15379
15380 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15381 * remote-utils.c (remote_open): Do not call disable_async_io.
15382 (block_async_io): Delete.
15383 (unblock_async_io): Make static.
15384 (initialize_async_io): New.
15385 * server.c (handle_v_cont): Handle async I/O here.
15386 (myresume): Likewise. Move other common resume tasks here...
15387 (main): ... from here. Call initialize_async_io. Disable async
15388 I/O before the main loop.
15389 * server.h (initialize_async_io): Declare.
15390 (block_async_io, unblock_async_io): Delete prototypes.
15391 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15392
15393 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15394
15395 * remote-utils.c (readchar): Allow binary data in received messages.
15396
15397 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15398
15399 * win32-low.c (attaching): New global.
15400 (win32_create_inferior): Clear the `attaching' global.
15401 (win32_attach): Set the `attaching' global.
15402 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15403 attaching. Only set a breakpoint at the entry point if not
15404 attaching.
15405
15406 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15407
15408 * server.c (main): Don't report dll events on the initial
15409 connection on attaches.
15410
15411 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15412
15413 * server.c (main): Relax numerical bases supported for the pid of
15414 the --attach command line argument.
15415
15416 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15417
15418 * win32-low.c (win32_attach): Call OpenProcess before
15419 DebugActiveProcess, not after. Add last error output to error
15420 call.
15421
15422 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15423
15424 * win32-low.c (win32_get_thread_context)
15425 (win32_set_thread_context): New functions.
15426 (thread_rec): Use win32_get_thread_context.
15427 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15428 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15429 field.
15430
15431 2007-12-03 Leo Zayas
15432 Pedro Alves <pedro_alves@portugalmail.pt>
15433
15434 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15435 global variables.
15436 (child_add_thread): Minor cleanup.
15437 (child_continue): Resume artificially suspended threads before
15438 calling ContinueDebugEvent.
15439 (suspend_one_thread): New.
15440 (fake_breakpoint_event): New.
15441 (get_child_debug_event): Change return type to int. Check here if
15442 gdb sent an interrupt request. If a soft interrupt was requested,
15443 fake a breakpoint event. Return 0 if there is no event to handle,
15444 and 1 otherwise.
15445 (win32_wait): Don't check here if gdb sent an interrupt request.
15446 Ensure there is a valid event to handle.
15447 (win32_request_interrupt): Add soft interruption method as last
15448 resort.
15449
15450 2007-12-03 Leo Zayas
15451 Pedro Alves <pedro_alves@portugalmail.pt>
15452
15453 * win32-low.h (win32_thread_info): Add descriptions to the
15454 structure members. Replace `suspend_count' counter by a
15455 `suspended' flag.
15456 * win32-low.c (thread_rec): Update condition of when to get the
15457 context from the inferior. Rely on ContextFlags being set if it
15458 has already been retrieved. Only suspend the inferior thread if
15459 we haven't already. Warn if that fails.
15460 (continue_one_thread): s/suspend_count/suspended/. Only call
15461 ResumeThread once. Warn if that fails.
15462
15463 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15464
15465 * win32-low.c (win32_wait): Don't read from the inferior when it
15466 has already exited.
15467
15468 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15469
15470 * Makefile.in (win32_low_h): New variable.
15471 (win32-low.o): Add dependency on $(win32_low_h).
15472 (win32-arm-low.o, win32-i386-low.o): New rules.
15473
15474 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15475
15476 * hostio.c: Correct copyright year.
15477
15478 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15479
15480 * Makefile.in (OBS): Add hostio.o.
15481 (hostio.o): New rule.
15482 * server.h (handle_vFile): Declare.
15483 * hostio.c: New file.
15484 * server.c (handle_v_requests): Take packet_len and new_packet_len
15485 for binary packets. Call handle_vFile.
15486 (main): Update call to handle_v_requests.
15487
15488 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15489
15490 * linux-low.c: Include <sched.h>.
15491
15492 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15493
15494 * linux-low.c (linux_tracefork_grandchild): New.
15495 (linux_tracefork_child): Use clone.
15496 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15497
15498 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15499
15500 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15501
15502 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15503
15504 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15505
15506 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15507
15508 * inferiors.c (change_inferior_id): Delete.
15509 (add_pid_to_list, pull_pid_from_list): New.
15510 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15511 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15512 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15513 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15514 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15515 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15516 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15517 (using_threads): Always set to 1.
15518 (handle_extended_wait): New.
15519 (add_process): Do not set TID.
15520 (linux_create_inferior): Set must_set_ptrace_flags.
15521 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15522 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15523 (linux_thread_alive): Rename TID argument to LWPID.
15524 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15525 (linux_wait_for_event): Do not use TID or check using_threads. Update
15526 call to dead_thread_notify. Call handle_extended_wait.
15527 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15528 (send_sigstop): Delete sigstop_sent.
15529 (wait_for_sigstop): Avoid TID.
15530 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15531 (linux_test_for_tracefork): New.
15532 (linux_lookup_signals): Use thread_db_active and
15533 linux_supports_tracefork_flag.
15534 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15535 * linux-low.h (get_process_thread): Avoid TID.
15536 (struct process_ifo): Move thread_known and tid to the end. Remove
15537 sigstop_sent.
15538 (linux_attach_lwp, thread_db_init): Update prototypes.
15539 * server.h (change_inferior_id): Delete prototype.
15540 (add_pid_to_list, pull_pid_from_list): New prototypes.
15541 * thread-db.c (thread_db_use_events): New.
15542 (find_first_thread): Rename to...
15543 (find_one_thread): ...this. Update callers and messages. Do not
15544 call fatal. Check thread_db_use_events. Do not call
15545 change_inferior_id or new_thread_notify.
15546 (maybe_attach_thread): Update. Do not call new_thread_notify.
15547 (thread_db_init): Set thread_db_use_events. Check use_events.
15548 * utils.c (fatal, warning): Correct message prefix.
15549
15550 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15551
15552 * Makefile.in (clean): Remove new files.
15553 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15554 (powerpc-64.o, powerpc-64.c): New rules.
15555 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15556 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15557 with SPE.
15558 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15559 SPE targets.
15560 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15561 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15562 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15563 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15564 (target_regsets): Add AltiVec and SPE register sets.
15565 * configure.ac: Check for AltiVec and SPE.
15566 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
15567 (ppc_fill_vrregset, ppc_store_vrregset): New.
15568 (target_regsets): Add AltiVec register set.
15569 * configure: Regenerated.
15570
15571 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
15572
15573 * linux-low.c (O_LARGEFILE): Define.
15574 (linux_read_memory): Use /proc/PID/mem.
15575 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
15576 * configure, config.in: Regenerated.
15577
15578 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15579
15580 * linux-low.c (linux_wait_for_event): Do not pass signals while
15581 single-stepping.
15582
15583 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15584
15585 * win32-low.c (create_process): New.
15586 (win32_create_inferior): Use create_process instead of
15587 CreateProcess. If create_process failed retry appending an ".exe"
15588 suffix. Store the GetLastError result immediatelly after
15589 create_process calls and use it on the call to error.
15590
15591 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
15592
15593 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
15594
15595 2007-08-23 Joel Brobecker <brobecker@adacore.com>
15596
15597 * configure.ac: Switch license to GPLv3.
15598
15599 2007-08-01 Michael Snyder <msnyder@access-company.com>
15600
15601 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
15602
15603 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
15604
15605 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
15606 typedef.
15607 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
15608 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
15609 CloseToolhelp32Snapshot.
15610 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
15611 CloseToolhelp32Snapshot.
15612
15613 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
15614
15615 * server.c (main): Check for inferior exit before main loop.
15616
15617 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
15618
15619 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
15620 instead of on tmp_desc.
15621
15622 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
15623 Daniel Jacobowitz <dan@codesourcery.com>
15624
15625 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
15626 (add_thread): Minor cleanups.
15627 (clear_inferiors): Move lower in the file. Clear the DLL
15628 list.
15629 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
15630 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
15631 (xml_escape_text): New.
15632 * server.c (handle_query): Handle qXfer:libraries:read. Report it
15633 for qSupported.
15634 (handle_v_cont): Report errors.
15635 (gdbserver_version): Update.
15636 (main): Correct size of own_buf. Do not report initial DLL events.
15637 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
15638 (unloaded_dll, xml_escape_text): New.
15639 * win32-low.c (enum target_waitkind): Update comments.
15640 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
15641 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
15642 (win32_EnumProcessModules, win32_GetModuleInformation)
15643 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
15644 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
15645 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
15646 (win32_Module32First, win32_Module32Next, load_toolhelp)
15647 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
15648 (get_child_debug_event): Handle DLL events.
15649 (win32_wait): Likewise.
15650
15651 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
15652
15653 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
15654 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
15655
15656 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15657
15658 * win32-low.c (handle_output_debug_string): Ignore event if not
15659 waiting.
15660
15661 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
15662
15663 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
15664
15665 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
15666
15667 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
15668
15669 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
15670
15671 * inferiors.c (change_inferior_id): Add comment.
15672 * linux-low.c (check_removed_breakpoint): Add an early
15673 prototype. Improve debug output.
15674 (linux_attach): Doc update.
15675 (linux_detach_one_process, linux_detach): Clean up before releasing
15676 each process.
15677 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
15678 * linux-low.h (struct process_info): Doc improvement.
15679 * mem-break.c (delete_all_breakpoints): New.
15680 * mem-break.h (delete_all_breakpoints): New prototype.
15681 * thread-db.c (find_first_thread): New.
15682 (thread_db_create_event): Call it instead of
15683 thread_db_find_new_threads. Clean up unused variables.
15684 (maybe_attach_thread): Remove first thread handling.
15685 (thread_db_find_new_threads): Use find_first_thread.
15686 (thread_db_get_tls_address): Likewise.
15687
15688 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
15689
15690 * thread-db.c (thread_db_find_new_threads): Add prototype.
15691 (thread_db_create_event): Check for the main thread before adding
15692 a new thread.
15693 (maybe_attach_thread): Only enable event reporting if TID == 0.
15694 (thread_db_get_tls_address): Check for new threads.
15695
15696 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
15697
15698 * linux-low.c (linux_create_inferior): Try execv before execvp.
15699 * spu-low.c (spu_create_inferior): Likewise.
15700
15701 2007-06-13 Mike Frysinger <vapier@gentoo.org>
15702
15703 * linux-low.c (linux_create_inferior): Change execv to execvp.
15704 * spu-low.c (spu_create_inferior): Likewies.
15705
15706 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
15707
15708 * Makefile.in (clean): Clean new files instead of deleted ones.
15709 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
15710 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
15711 rules.
15712 * configure.srv: Specify XML files and new regformats for MIPS and
15713 MIPS64 GNU/Linux.
15714 * linux-mips-low.c (mips_num_regs): Set to only used registers.
15715 (mips_regmap): Do not fetch $0. Remove unused registers. Add
15716 an entry for the restart register.
15717 (mips_cannot_fetch_register, mips_cannot_store_register)
15718 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
15719 register names to match the XML descriptions.
15720 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
15721 restart register instead of $0.
15722
15723 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15724 Markus Deuling <deuling@de.ibm.com>
15725
15726 * remote-utils.c (decode_xfer_write): New function.
15727 * server.h (decode_xfer_write): Add prototype.
15728 * server.c (handle_query): Add PACKET_LEN argument. Support
15729 qXfer:spu:read and qXfer:spu:write packets.
15730 (main): Pass packet_len to handle_query.
15731 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
15732 * target.h (target_ops): Add qxfer_spu.
15733
15734 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
15735
15736 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
15737 accessing non-seekable spufs files.
15738
15739 2007-05-16 Markus Deuling <deuling@de.ibm.com>
15740
15741 * server.c (handle_query): Add reply for qC packet.
15742
15743 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15744 Leo Zayas <lerele@champenstudios@com>
15745
15746 * server.h (check_remote_input_interrupt_request): New function.
15747 * remote_utils.c (INVALID_DESCRIPTOR): New define.
15748 (remote_desc): Initialize with INVALID_DESCRIPTOR.
15749 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
15750 (check_remote_input_interrupt_request): New function.
15751 * server.h (check_remote_input_interrupt_request): Declare.
15752 * win32-low.c (winapi_DebugBreakProcess,
15753 winapi_GenerateConsoleCtrlEvent): New typedefs.
15754 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
15755 to 250 ms.
15756 (win32_wait): Check for remote interrupt request
15757 with check_remote_input_interrupt_request.
15758 (win32_request_interrupt): New function.
15759 (win32_target_op): Set request_interrupt to win32_request_interrupt.
15760
15761 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15762
15763 * win32-low.c (debug_registers_changed,
15764 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
15765 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
15766 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
15767 (thread_rec): Get context using the low target.
15768 (child_add_thread): Call thread_added on the low target,
15769 which does the same thing.
15770 (regptr): Delete.
15771 (do_initial_child_stuff): Remove debug registers references.
15772 Set context using the low target. Resume threads after
15773 setting the contexts.
15774 (child_continue): Remove dead variable. Remove debug
15775 registers references.
15776 (child_fetch_inferior_registers): Go through the low target.
15777 (do_child_store_inferior_registers): Remove.
15778 (child_store_inferior_registers): Go through the low target.
15779 (win32_resume): Remove debug registers references.
15780 Set context using the low target.
15781 (handle_exception): Change return type to void. Don't record
15782 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
15783 first chance exception.
15784 (get_child_debug_event): Change return type to void. Remove
15785 goto loop. Always return after waiting for debug event.
15786 (win32_wait): Convert to switch statement. Handle spurious
15787 events.
15788
15789 * win32-i386-low.c (debug_registers_changed,
15790 debug_registers_used): New.
15791 (initial_stuff): Rename to ...
15792 (i386_initial_stuff): ... this. Clear debug registers
15793 state variables.
15794 (store_debug_registers): Delete.
15795 (i386_get_thread_context): New.
15796 (load_debug_registers): Delete.
15797 (i386_set_thread_context): New.
15798 (i386_thread_added): New.
15799 (single_step): Rename to ...
15800 (i386_single_step): ... this.
15801 (do_fetch_inferior_registers): Rename to ...
15802 (i386_fetch_inferior_register): ... this.
15803 (i386_store_inferior_register): New.
15804 (the_low_target): Adapt to new interface.
15805
15806 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
15807 (arm_get_thread_context): New.
15808 (arm_set_thread_context): New.
15809 (regptr): New.
15810 (do_fetch_inferior_registers): Rename to ...
15811 (arm_fetch_inferior_register): ... this.
15812 (arm_store_inferior_register): New.
15813 (arm_wince_breakpoint): Reimplement as unsigned long.
15814 (arm_wince_breakpoint_len): Define.
15815 (the_low_target): Adapt to new interface.
15816
15817 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
15818 load_debug_registers. Add get_thread_context, set_thread_context,
15819 thread_added and store_inferior_register. Rename
15820 fetch_inferior_registers to fetch_inferior_register.
15821 (regptr): Remove declaration.
15822
15823 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15824
15825 * linux-low.c (linux_detach): Change return type to int. Return 0.
15826 * spu-low.c (spu_detach): Likewise.
15827
15828 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15829
15830 * target.h (target_ops): Change return type of detach to int.
15831 Add join.
15832 (join_inferior): New.
15833 * server.c (main): Don't skip detach support on mingw32.
15834 If the inferior doesn't support detaching return error.
15835 Call join_inferior instead of using waitpid.
15836 * linux-low.c (linux_join): New.
15837 (linux_target_op): Add linux_join.
15838 * spu-low.c (spu_join): New.
15839 (spu_target_ops): Add spu_join.
15840 * win32-low.c (win32_detach): Adapt to new interface.
15841 Reopen current_process_handle before detaching. Issue a child
15842 resume before detaching.
15843 (win32_join): New.
15844 (win32_target_op): Add win32_join.
15845
15846 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15847
15848 * win32-low.c (win32-attach): Fix return value.
15849 * target.h (target_ops): Describe ATTACH return values.
15850
15851 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15852
15853 * win32-low.c (GETPROCADDRESS): Define.
15854 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
15855 (winapi_DebugSetProcessKillOnExit): Likewise.
15856 (win32_create_inferior): Force usage of ansi CreateProcessA.
15857 (win32_attach): Use GETPROCADDRESS.
15858 (win32_detach): Likewise.
15859
15860 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
15861
15862 * win32-low.c (win32_wait): Don't use WSTOPSIG.
15863
15864 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
15865
15866 * win32-low.c: Commit leftover changes from 2007-03-29.
15867
15868 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15869
15870 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
15871 fields short instead of int. Add explicit padding.
15872 (i387_cache_to_fsave): Remove unnecessary casts.
15873 (i387_fsave_to_cache): Doc fix.
15874 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
15875
15876 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
15877
15878 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
15879 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
15880
15881 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15882
15883 * configure.srv (arm*-*-mingw32ce*): Move near the other
15884 arm targets.
15885
15886 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
15887
15888 * configure.ac: Add errno checking.
15889 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
15890 sys/file.h and malloc.h.
15891 (AC_CHECK_DECLS): Add perror.
15892 (srv_mingwce): Handle.
15893 * configure.srv (i[34567]86-*-cygwin*): Add
15894 win32-i386-low.o to srv_tgtobj.
15895 (i[34567]86-*-mingw*): Likewise.
15896 (arm*-*-mingw32ce*): Add case.
15897 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15898 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
15899 [__MINGW32CE__] (strerror): New function.
15900 [__MINGW32CE__] (errno): Define to GetLastError.
15901 [__MINGW32CE__] (COUNTOF): New macro.
15902 (remote_open): Remove extra close call.
15903 * mem-break.c (delete_breakpoint_at): New function.
15904 * mem-break.h (delete_breakpoint_at): Declare.
15905 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
15906 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
15907 [USE_WIN32API] (read, write): Add char* casts.
15908 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
15909 * server.h: Include wincecompat.h on Windows CE.
15910 [HAVE_ERRNO_H]: Check.
15911 (perror): Declare if not declared.
15912 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
15913 (perror_with_name): Remove errno declaration.
15914 * wincecompat.h: New.
15915 * wincecompat.c: New.
15916 * win32-low.h: New.
15917 * win32-arm-low.c: New.
15918 * win32-i386-low.c: New.
15919 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
15920 (OUTMSG2): Make it safe.
15921 (_T): New macro.
15922 (COUNTOF): New macro.
15923 (NUM_REGS): Get it from the low target.
15924 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
15925 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
15926 (thread_rec): Let low target handle debug registers.
15927 (child_add_thread): Likewise.
15928 (child_init_thread_list): Likewise.
15929 (continue_one_thread): Likewise.
15930 (regptr): New.
15931 (do_child_fetch_inferior_registers): Move to ...
15932 * win32-i386-low.c: ... here, and rename to ...
15933 (do_fetch_inferior_registers): ... this.
15934 * win32-low.c (child_fetch_inferior_registers):
15935 Go through the low target.
15936 (do_child_store_inferior_registers): Use regptr.
15937 (strwinerror): New function.
15938 (win32_create_inferior): Handle Windows CE.
15939 Use strwinerror instead of strerror on Windows error
15940 codes. Add program to the error output.
15941 Don't close the main thread handle on Windows CE.
15942 (win32_attach): Use coredll.dll on Windows CE.
15943 (win32_kill): Close current process and current
15944 thread handles.
15945 (win32_detach): Use coredll.dll on Windows CE.
15946 (win32_resume): Let low target handle debug registers, and
15947 step request.
15948 (handle_exception): Add/Remove initial breakpoint. Avoid
15949 non-existant WSTOPSIG on Windows CE.
15950 (win32_read_inferior_memory): Cast to remove warning.
15951 (win32_arch_string): Go through the low target.
15952 (initialize_low): Call set_breakpoint_data with the low
15953 target's breakpoint.
15954 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
15955 FOP_REGNUM, mappings): Move to ...
15956 * win32-i386-low.c: ... here.
15957 * win32-low.c (win32_thread_info): Move to ...
15958 * win32-low.h: ... here.
15959 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
15960 win32-arm-low.c and wincecompat.c.
15961 (all:): Add $EXEEXT.
15962 (install-only:): Likewise.
15963 (gdbserver:): Likewise.
15964 (gdbreplay:): Likewise.
15965 * config.in: Regenerate.
15966 * configure: Regenerate.
15967
15968 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15969
15970 * win32-low.c: Rename typedef thread_info to
15971 win32_thread_info throughout.
15972
15973 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
15974
15975 * win32-i386-low.c: Rename to ...
15976 * win32-low.c: ... this.
15977 * configure.srv: Replace win32-i386-low.o with win32-low.o.
15978 * Makefile.in: Likewise.
15979
15980 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
15981
15982 * remote-utils.c (monitor_output): Constify msg parameter.
15983 * server.h (monitor_output): Likewise.
15984 * win32-i386-low.c (handle_output_debug_string): New.
15985 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
15986 handle_output_debug_string.
15987 (get_child_debug_event): Likewise.
15988
15989 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
15990
15991 * server.c (main): Correct strtoul check.
15992
15993 2007-03-27 Jon Ringle <jon@ringle.org>
15994
15995 * linux-low.c: Check __ARCH_HAS_MMU__ also.
15996
15997 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
15998
15999 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16000
16001 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16002
16003 * terminal.h: Check HAVE_SGTTY_H.
16004
16005 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16006
16007 * remote-utils.c (remote_open): Print out the assigned port number.
16008
16009 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16010
16011 * remote-utils.c (monitor_output): New function.
16012 * server.c (debug_threads): Define here.
16013 (monitor_show_help): New function.
16014 (handle_query): Handle qRcmd.
16015 (main): Do not handle 'd' packet.
16016 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16017 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16018 of debug_threads.
16019
16020 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16021
16022 * Makefile.in (EXEEXT): New.
16023 (clean): Use $(EXEEXT).
16024
16025 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16026
16027 * target.h (target_ops): Rename send_signal to request_interrupt,
16028 and remove enum target_signal parameter.
16029 * linux-low.c (linux_request_interrupt): Rename from
16030 linux_send_signal, and always send SIGINT.
16031 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16032 and always send SIGINT.
16033 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16034 of send_signal.
16035 (input_interrupt): Likewise.
16036
16037 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16038
16039 * server.c (get_features_xml): Check if target implemented
16040 arch_string.
16041 * win32-i386-low.c (win32_arch_string): New.
16042 (win32_target_ops): Add win32_arch_string as arch_string member.
16043
16044 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16045
16046 * spu-low.c (spu_arch_string): New.
16047 (spu_target_ops): Add spu_arch_string.
16048
16049 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16050
16051 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16052 * configure.ac: Do not check for terminal.h.
16053 * configure, config.in: Regenerated.
16054
16055 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16056
16057 * Makefile.in (OBS): Add $(XML_BUILTIN).
16058 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16059 (clean): Update.
16060 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16061 (arm-with-iwmmxt.c): New.
16062 * config.in, configure: Regenerate.
16063 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16064 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16065 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16066 (arm*-*-linux*): Add iWMMXt and regset support.
16067 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16068 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16069 (arm_store_wmmxregset, target_regsets): New.
16070 * server.c (get_features_xml): Take annex argument. Check builtin
16071 XML documents.
16072 (handle_query): Handle multiple annexes.
16073
16074 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16075
16076 * remote-utils.c [USE_WIN32API] (read, write): Define.
16077 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16078 write.
16079
16080 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16081
16082 * linux-i386-low.c (the_low_target): Set arch_string.
16083 * linux-x86-64-low.c (the_low_target): Likewise.
16084 * linux-low.c (linux_arch_string): New.
16085 (linux_target_ops): Add it.
16086 * linux-low.h (struct linux_target_ops): Add arch_string.
16087 * server.c (write_qxfer_response): Use const void * for DATA.
16088 (get_features_xml): New.
16089 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16090 * target.h (struct target_ops): Add arch_string method.
16091
16092 2007-01-03 Denis Pilat <denis.pilat@st.com>
16093 Daniel Jacobowitz <dan@codesourcery.com>
16094
16095 * linux-low.c (linux_kill): Handle being called with no threads.
16096 * win32-i386-low.c (win32_kill): Likewise.
16097 (get_child_debug_event): Clear current_process_handle.
16098
16099 2006-12-30 Denis PILAT <denis.pilat@st.com>
16100 Daniel Jacobowitz <dan@codesourcery.com>
16101
16102 * remote-utils.c (remote_open): Check the type of specified
16103 serial port devices before opening them.
16104 * server.c (main): Kill the inferior if an error occurs during
16105 the first remote_open.
16106
16107 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16108
16109 * README: Update supported targets.
16110
16111 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16112
16113 * Makefile.in (clean): Remove reg-mips64.c.
16114 (reg-mips64.c, reg-mips64.o): New rules.
16115 * configure.srv: Handle mips64. Include regset support for mips.
16116 * linux-mips-low.c (union mips_register): New.
16117 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16118 (mips_breakpoint, mips_breakpoint_at): Use int.
16119 (mips_collect_register, mips_supply_register)
16120 (mips_collect_register_32bit, mips_supply_register_32bit)
16121 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16122 (mips_store_fpregset, target_regsets): New.
16123 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16124
16125 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16126
16127 * configure.srv: Add target "spu*-*-*".
16128 * Makefile.in (clean): Remove reg-spu.c.
16129 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16130 * spu-low.c: New file.
16131
16132 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16133
16134 * configure.ac: Correct td_thr_tls_get_addr test.
16135 * configure: Regenerated.
16136
16137 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16138
16139 * linux-low.c (linux_wait_for_event): Reformat. Use the
16140 pass_signals array.
16141 * remote-utils.c (decode_address_to_semicolon): New.
16142 * server.c (pass_signals, handle_general_set): New.
16143 (handle_query): Mention QPassSignals for qSupported.
16144 (main): Call handle_general_set.
16145 * server.h (pass_signals, decode_address_to_semicolon): New.
16146
16147 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16148
16149 * server.c (handle_query): Correct error handling for read_auxv.
16150
16151 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16152
16153 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16154 and srv_linux_thread_db to yes.
16155 * linux-s390-low.c (s390_fill_gregset): New function.
16156 (target_regsets): Define data structure.
16157
16158 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16159
16160 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16161 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16162 * config.in, configure: Regenerated.
16163 * inferiors.c (gdb_id_to_thread): New function.
16164 (gdb_id_to_thread_id): Use it.
16165 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16166 * linux-low.h (struct process_info): Add th member.
16167 (thread_db_get_tls_address): New prototype.
16168 * remote-utils.c (decode_address): Make non-static.
16169 * server.c (handle_query): Handle qGetTLSAddr.
16170 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16171 * target.h (struct target_ops): Add get_tls_address.
16172 * thread-db.c (maybe_attach_thread): Save the thread handle.
16173 (thread_db_get_tls_address): New.
16174
16175 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16176
16177 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16178 (linux_resume_one_process): Take a siginfo_t *. Update all
16179 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16180 (struct pending_signals): Add a siginfo_t.
16181 (linux_wait_for_process): Always set last_status.
16182 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16183 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16184 * linux-low.h (struct process_info): Add last_status.
16185
16186 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16187
16188 * remote-utils.c (try_rle): New function.
16189 (putpkt_binary): Use it.
16190
16191 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16192
16193 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16194 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16195 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16196 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16197 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16198 point registers.
16199
16200 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16201
16202 * server.c (terminal_fd): New variable.
16203 (old_foreground_pgrp): Likewise.
16204 (restore_old_foreground_pgrp): New function.
16205 (start_inferior): Record the terminal file descriptor in terminal_fd
16206 and its original foreground group in old_foreground_pgrp. Register
16207 restore_old_foreground_pgrp with atexit().
16208
16209 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16210
16211 * server.c (handle_query): Correct qPart to qXfer.
16212
16213 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16214
16215 * configure.ac: Check for more headers which are missing on
16216 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16217 * configure.srv: Add Cygwin and mingw32.
16218 * remote-utils.c: Don't include headers unconditionally which
16219 are missing on mingw32. Include <winsock.h> for mingw32.
16220 (remote_open): Adjust for mingw32 support. Flush
16221 standard error after writing to it.
16222 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16223 (unblock_async_io, enable_async_io, disable_async_io)
16224 (readchar, getpkt): Update for Winsock support.
16225 (prepare_resume_reply): Expect a protocol signal number.
16226 * server.c: Disable <sys/wait.h> on mingw32.
16227 (start_inferior): Adjust for mingw32 support. Flush
16228 standard error after writing to it.
16229 (attach_inferior): Likewise. Use protocol signal
16230 numbers.
16231 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16232 and names.
16233 * win32-i386-low.c: New file.
16234 * Makefile.in (XM_CLIBS): Set.
16235 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16236 (win32-i386-low.o): New dependency rule.
16237 * linux-low.c (linux_wait): Use target signal numbers.
16238 * target.h (struct target_ops): Doc fix.
16239 * server.h (target_signal_to_name): New prototype.
16240 * gdbreplay.c: Don't include headers unconditionally which
16241 are missing on mingw32. Include <winsock.h> for mingw32.
16242 (remote_close, remote_open): Adjust for Winsock support.
16243 * configure, config.in: Regenerated.
16244
16245 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16246
16247 * server.c (decode_xfer_read, write_qxfer_response): New.
16248 (handle_query): Take a packet length argument. Handle
16249 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16250 the qSupported response.
16251 (main): Update call to handle_query.
16252
16253 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16254
16255 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16256 (putpkt_binary): Renamed from putpkt and adjusted for binary
16257 data.
16258 (putpkt): New wrapper for putpkt_binary.
16259 (readchar): Don't mask off the high bit.
16260 (decode_X_packet): New function.
16261 * server.c (main): Call putpkt_binary if a handler sets the packet
16262 length. Save the length of the incoming packet. Handle 'X'.
16263 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16264
16265 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16266
16267 * server.c (handle_query): Handle qSupported.
16268
16269 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16270
16271 * remote-utils.c (all_symbols_looked_up): New variable.
16272 (look_up_one_symbol): Check it.
16273 * server.h (look_up_one_symbol): New declaration.
16274 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16275
16276 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16277
16278 * Makefile.in (linux-arm-low.o): Update dependencies.
16279 * linux-arm-low.c: Include "gdb_proc_service.h".
16280 (PTRACE_GET_THREAD_AREA): Define.
16281 (ps_get_thread_area): New function.
16282
16283 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16284
16285 * configure.srv (m68k*-*-uclinux*): New target.
16286 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16287 (linux_resume_one_process): Remove extraneous cast.
16288 (linux_read_offsets): New.
16289 (linux_target_op): Add linux_read_offsets on mmuless systems.
16290 * server.c (handle_query): Add qOffsets logic.
16291 * target.h (struct target_ops): Add read_offsets.
16292
16293 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16294
16295 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16296 (PTRACE_GET_THREAD_AREA): Define.
16297 (ps_get_thread_area): New function.
16298 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16299 (linux-x86-64-low.o): Update.
16300
16301 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16302
16303 * configure.ac: Remove checks for prfpregset_t.
16304 * gdb_proc_service.h: New file.
16305 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16306 new "gdb_proc_service.h".
16307 * proc-service.c: Likewise.
16308 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16309 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16310 * Makefile.in (gdb_proc_service_h): Updated.
16311 * configure, config.in: Regenerated.
16312
16313 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16314
16315 * remote-utils.c (prepare_resume_reply): Move declaration
16316 of gdb_id_from_wait to the top of the block.
16317
16318 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16319
16320 * linux-low.c (regsets_store_inferior_registers): Read the regset
16321 from the target before filling it.
16322
16323 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16324
16325 * server.c (attach_inferior): Return SIGTRAP for a successful
16326 attach.
16327
16328 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16329
16330 * Makefile.in (OBS): Add version.o.
16331 (STAGESTUFF): Delete.
16332 (version.o): Add dependencies.
16333 (version.c): Replace rule.
16334 (clean): Remove version.c.
16335 * server.c (gdbserver_version): New.
16336 (gdbserver_usage): Use printf.
16337 (main): Handle --version and --help.
16338 * server.h (version, host_name): Add declarations.
16339
16340 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16341
16342 * linux-arm-low.c:
16343 * linux-arm-low.c:
16344 * inferiors.c:
16345 * i387-fp.h:
16346 * i387-fp.c:
16347 * gdbreplay.c:
16348 * regcache.c:
16349 * proc-service.c:
16350 * mem-break.h:
16351 * mem-break.c:
16352 * linux-x86-64-low.c:
16353 * linux-sh-low.c:
16354 * linux-s390-low.c:
16355 * linux-ppc64-low.c:
16356 * linux-ppc-low.c:
16357 * linux-mips-low.c:
16358 * linux-m68k-low.c:
16359 * linux-m32r-low.c:
16360 * linux-low.h:
16361 * linux-low.c:
16362 * linux-ia64-low.c:
16363 * linux-i386-low.c:
16364 * linux-crisv32-low.c:
16365 * thread-db.c:
16366 * terminal.h:
16367 * target.h:
16368 * target.c:
16369 * server.h:
16370 * server.c:
16371 * remote-utils.c:
16372 * regcache.h:
16373 * utils.c:
16374 * Makefile.in:
16375 * configure.ac:
16376 * gdbserver.1: Add (C) after Copyright. Update the FSF
16377 address.
16378
16379 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16380
16381 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16382 (arm_breakpoint_at): Recognize both breakpoints.
16383 (the_low_target): Use the correct breakpoint instruction.
16384
16385 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16386
16387 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16388 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16389 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16390 (the_low_target): Update.
16391
16392 2005-10-25 Andreas Schwab <schwab@suse.de>
16393
16394 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16395
16396 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16397 (ia64_num_regs): Reduce to 462.
16398
16399 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16400
16401 * acinclude.m4: Correct quoting.
16402 * aclocal.m4: Regenerated.
16403
16404 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16405 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16406 (thread_db_init): Call thread_db_err_str.
16407 * configure.ac: Check for TD_VERSION.
16408 * config.in, configure: Regenerated.
16409
16410 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16411
16412 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16413
16414 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16415
16416 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16417 is not available. Define HAVE_PTRACE_GETREGS if it is.
16418 * config.in, configure: Regenerated.
16419 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16420 * linux-i386-low.c, linux-m68k-low.c: Update to use
16421 HAVE_PTRACE_GETREGS.
16422 * linux-low.c (regsets_fetch_inferior_registers)
16423 (regsets_store_inferior_registers): Only return 0 if we processed
16424 GENERAL_REGS.
16425 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16426 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16427
16428 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16429
16430 * inferiors.c (struct thread_info): Add gdb_id.
16431 (add_thread): Add gdb_id argument.
16432 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16433 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16434 calls to add_thread.
16435 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16436 * server.c (handle_query): Use thread_to_gdb_id.
16437 (handle_v_cont, main): Use gdb_id_to_thread_id.
16438 * server.h (add_thread): Update prototype.
16439 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16440 prototypes.
16441
16442 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16443
16444 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16445 left-padded registers.
16446 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16447 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16448
16449 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16450
16451 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16452 * configure: Regenerate.
16453 * config.in: Regenerate.
16454 * server.h (NEED_DECLARATION_STRERROR):
16455 Replace with !HAVE_DECL_STRERROR.
16456
16457 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16458
16459 * linux-low.c (linux_wait, linux_send_signal): Don't test
16460 an unsigned long variable for > 0 if it could be MAX_ULONG.
16461 * server.c (myresume): Likewise.
16462 * target.c (set_desired_inferior): Likewise.
16463
16464 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16465
16466 * configure.ac: Simplify and improve check for socklen_t.
16467 * configure, config.in: Regenerate.
16468
16469 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16470
16471 * acconfig.h: Remove.
16472 * configure.ac: Add a test for socklen_t. Use three-argument
16473 AC_DEFINE throughout.
16474 * config.in: Regenerated using autoheader 2.59.
16475 * configure: Regenerated.
16476
16477 * gdbreplay.c (socklen_t): Provide a default.
16478 (remote_open): Use socklen_t.
16479 * remote-utils.c (socklen_t): Provide a default.
16480 (remote_open): Use socklen_t.
16481 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16482 unsigned char.
16483
16484 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16485 char for buffers.
16486 * linux-low.c (linux_read_memory, linux_write_memory)
16487 (linux_read_auxv): Likewise.
16488 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16489 (check_mem_write): Likewise.
16490 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16491 Likewise.
16492 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16493 (registers_from_string, register_data): Likewise.
16494 * server.c (handle_query, main): Likewise.
16495 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16496 (decode_M_packet): Likewise.
16497 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16498 * target.h (struct target_ops): Update read_memory, write_memory,
16499 and read_auxv.
16500 (read_inferior_memory, write_inferior_memory): Update.
16501 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16502 to unsigned char *.
16503 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16504 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16505 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16506 linux-s390-low.c, linux-sh-low.c: Update for changes in
16507 read_inferior_memory and the_low_target->breakpoint.
16508
16509 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16510
16511 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16512 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16513 * configure.srv: Add powerpc64-*-linux*.
16514 * linux-ppc64-low.c: New file.
16515
16516 2005-05-23 Orjan Friberg <orjanf@axis.com>
16517
16518 * linux-cris-low.c: New file with support for CRIS.
16519 * linux-crisv32-low.c: Ditto for CRISv32.
16520 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16521 (clean): Add reg-cris.c and reg-crisv32.c.
16522 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16523 reg-crisv32.o, and reg-crisv32.c to make rules.
16524 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16525 recognized targets.
16526
16527 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16528
16529 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16530 of sizeof (PTRACE_XFER_TYPE).
16531 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16532
16533 2005-05-12 Orjan Friberg <orjanf@axis.com>
16534
16535 * target.h (struct target_ops): Add insert_watchpoint,
16536 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16537 pointers for hardware watchpoint support.
16538 * linux-low.h (struct linux_target_ops): Ditto.
16539 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16540 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16541 to linux_target_ops.
16542 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16543 reply packet.
16544 * server.c (main): Recognize 'Z' and 'z' packets.
16545
16546 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16547
16548 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16549 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16550 (the_low_target): Add new members.
16551
16552 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16553
16554 * proc-service.c (ps_lgetregs): Search all_processes instead of
16555 all_threads.
16556
16557 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16558
16559 * server.c (start_inferior): Change return type to int.
16560 (attach_inferior): Change sigptr to int *.
16561 (handle_v_cont, handle_v_requests): Change signal to int *.
16562 (main): Change signal to int.
16563
16564 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16565
16566 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
16567 * configure.srv: Add m32r*-*-linux*.
16568 * linux-m32r-low.c: New file.
16569
16570 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
16571
16572 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
16573
16574 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16575
16576 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
16577 Take unsigned long arguments for PIDs.
16578 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
16579 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
16580 (wait_for_sigstop, linux_resume_one_process)
16581 (regsets_fetch_inferior_registers, linux_send_signal)
16582 (linux_read_auxv): Likewise. Update the types of variables holding
16583 PIDs. Update format string specifiers.
16584 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
16585 * remote-utils.c (prepare_resume_reply): Likewise.
16586 * server.c (cont_thread, general_thread, step_thread)
16587 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
16588 unsigned long.
16589 (handle_query): Update format specifiers.
16590 (handle_v_cont, main): Use strtoul for thread IDs.
16591 * server.h (struct inferior_list_entry): Use unsigned long for ID.
16592 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
16593 (general_thread, step_thread, thread_from_wait)
16594 (old_thread_from_wait): Update.
16595 * target.h (struct thread_resume): Use unsigned long for THREAD.
16596 (struct target_ops): Use unsigned long for arguments to attach and
16597 thread_alive.
16598
16599 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
16600
16601 * acinclude.m4: Include bfd/bfd.m4 directly.
16602 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
16603 <agriffis@toolchain.org>.
16604 * aclocal.m4, configure: Regenerated.
16605
16606 2005-01-07 Andrew Cagney <cagney@gnu.org>
16607
16608 * configure.ac: Rename configure.in, require autoconf 2.59.
16609 * configure: Re-generate.
16610
16611 2004-12-08 Daniel Jacobowitz <dan@debian.org>
16612
16613 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
16614 LIBS when finished.
16615 * aclocal.m4: Regenerated.
16616 * configure: Regenerated.
16617
16618 2004-11-21 Andreas Schwab <schwab@suse.de>
16619
16620 * linux-m68k-low.c (m68k_num_gregs): Define.
16621 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
16622 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
16623 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
16624 (m68k_breakpoint_at): New. Add to the_low_target.
16625
16626 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
16627 srv_linux_thread_db to yes.
16628
16629 2004-10-20 Joel Brobecker <brobecker@gnat.com>
16630
16631 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
16632 (ARCH_SET_FS): Likewise.
16633 (ARCH_GET_FS): Likewise.
16634 (ARCH_GET_GS): Likewise.
16635
16636 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16637
16638 * linux-i386-low.c (ps_get_thread_area): New.
16639 * linux-x86-64-low.c (ps_get_thread_area): New.
16640 * linux-low.c: Include <sys/syscall.h>.
16641 (linux_kill_one_process): Don't kill the first thread here.
16642 (linux_kill): Kill the first thread here.
16643 (kill_lwp): New function.
16644 (send_sigstop, linux_send_signal): Use it.
16645 * proc-service.c: Clean up #ifdefs.
16646 (fpregset_info): Delete.
16647 (ps_lgetregs): Update and enable implementation.
16648 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
16649 implementations.
16650 * remote-utils.c (struct sym_cache, symbol_cache): New.
16651 (input_interrupt): Print a clearer message.
16652 (async_io_enabled): New variable.
16653 (enable_async_io, disable_async_io): Use it. Update comments.
16654 (look_up_one_symbol): Use the symbol cache.
16655 * thread-db.c (thread_db_look_up_symbols): New function.
16656 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
16657
16658 2004-10-16 Daniel Jacobowitz <dan@debian.org>
16659
16660 * configure.in: Test for -rdynamic.
16661 * configure: Regenerated.
16662 * Makefile (INTERNAL_LDFLAGS): New.
16663 (gdbserver, gdbreplay): Use it.
16664
16665 2004-09-02 Andrew Cagney <cagney@gnu.org>
16666
16667 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
16668
16669 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
16670
16671 * linux-low.c (linux_wait): Clear all_processes list also.
16672
16673 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16674
16675 * linux-low.c: Include <errno.h>. Remove extern declaration of
16676 errno.
16677
16678 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
16679
16680 * gdbreplay.c, server.h, utils.c: Update copyright years.
16681
16682 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16683
16684 * server.c (main): Print child status or termination signal from
16685 variable 'signal', not 'sig'.
16686
16687 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
16688
16689 * linux-low.c (linux_read_memory): Change return type to
16690 int. Check for and return error from ptrace().
16691 * target.c (read_inferior_memory): Change return type to int. Pass
16692 back return status from the_target->read_memory().
16693 * target.h (struct target_ops): Adapt *read_memory() prototype.
16694 Update comment.
16695 (read_inferior_memory): Adapt prototype.
16696 * server.c (main): Return an error packet if
16697 read_inferior_memory() returns an error.
16698
16699 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
16700
16701 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
16702 Unify with other clean targets.
16703
16704 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16705
16706 * server.c (handle_v_cont): Call set_desired_inferior.
16707
16708 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16709
16710 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
16711
16712 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16713
16714 * linux-low.c (linux_wait): Unblock async I/O.
16715 (linux_resume): Block and enable async I/O.
16716 * remote-utils.c (block_async_io, unblock_async_io): New functions.
16717 * server.h (block_async_io, unblock_async_io): Add prototypes.
16718
16719 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16720
16721 * remote-utils.c (remote_open): Print a status notice after
16722 opening a TCP port.
16723 * server.c (attach_inferior): Print a status notice after
16724 attaching.
16725
16726 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
16727
16728 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
16729
16730 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
16731
16732 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
16733 error packet.
16734 * server.c, target.h: Update copyright years.
16735
16736 2004-02-25 Roland McGrath <roland@redhat.com>
16737
16738 * target.h (struct target_ops): New member `read_auxv'.
16739 * server.c (handle_query): Handle qPart:auxv:read: query using that.
16740 * linux-low.c (linux_read_auxv): New function.
16741 (linux_target_ops): Initialize `read_auxv' member to that.
16742
16743 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
16744
16745 Committed by Jim Blandy <jimb@redhat.com>.
16746
16747 * linux-s390-low.c (s390_num_regs): Update.
16748 (s390_regmap): Remove control registers. Use __s390x__ predefine
16749 instead of GPR_SIZE to distiguish s390 and s390x targets.
16750
16751 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
16752
16753 * linux-low.c: Update copyright year.
16754 (check_removed_breakpoint): Clear pending_is_breakpoint.
16755 (linux_set_resume_request, linux_queue_one_thread)
16756 (resume_status_pending_p): New functions.
16757 (linux_continue_one_thread): Use process->resume.
16758 (linux_resume): Only resume threads if there are no pending events.
16759 * linux-low.h (struct process_info): Add resume request
16760 pointer.
16761
16762 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
16763
16764 * regcache.c (new_register_cache): Clear the allocated register
16765 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
16766
16767 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
16768
16769 * linux-low.c (linux_resume): Take a struct thread_resume *
16770 argument.
16771 (linux_wait): Update call.
16772 (resume_ptr): New static variable.
16773 (linux_continue_one_thread): Renamed from
16774 linux_continue_one_process. Use resume_ptr.
16775 (linux_resume): Use linux_continue_one_thread.
16776 * server.c (handle_v_cont, handle_v_requests): New functions.
16777 (myresume): New function.
16778 (main): Handle 'v' case.
16779 * target.h (struct thread_resume): New type.
16780 (struct target_ops): Change argument of "resume" to struct
16781 thread_resume *.
16782 (myresume): Delete macro.
16783
16784 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
16785
16786 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
16787 (uninstall): Support DESTDIR.
16788
16789 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
16790
16791 * configure.srv: Add xscale*linux copy of arm*linux entry.
16792
16793 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
16794
16795 * linux-arm-low.c (arm_reinsert_addr): New function.
16796 (the_low_target): Add arm_reinsert_addr.
16797
16798 2003-07-08 Mark Kettenis <kettenis@gnu.org>
16799
16800 * mem-break.c: Remove whitespace at end of file.
16801
16802 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
16803
16804 * configure.in: Check whether we need to prototype strerror.
16805 * server.h: Optionally prototype strerror.
16806 * gdbreplay.c (perror_with_name): Use strerror.
16807 * linux-low.c (linux_attach_lwp): Use strerror.
16808 * utils.c (perror_with_name): Use strerror.
16809 * config.in, configure: Regenerated.
16810
16811 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
16812
16813 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
16814 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
16815
16816 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
16817
16818 * Makefile.in (SFILES): Update.
16819 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
16820 low-sun3.c: Remove files.
16821
16822 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
16823
16824 * linux-low.c: Move comment to linux_thread_alive where it belonged.
16825 (linux_detach_one_process, linux_detach): New functions.
16826 (linux_target_ops): Add linux_detach.
16827 * server.c (main): Handle 'D' packet.
16828 * target.h (struct target_ops): Add "detach" member.
16829 (detach_inferior): Define.
16830
16831 2003-06-13 Mark Kettenis <kettenis@gnu.org>
16832
16833 From Kelley Cook <kelleycook@wideopenwest.com>:
16834 * configure.srv: Accept i[34567]86 variants.
16835
16836 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
16837
16838 * linux-low.c (linux_wait_for_event): Correct comment typos.
16839 (linux_resume_one_process): Call check_removed_breakpoint.
16840 (linux_send_signal): New function.
16841 (linux_target_ops): Add linux_send_signal.
16842 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
16843 of kill.
16844 * target.h (struct target_ops): Add send_signal.
16845
16846 2003-05-29 Jim Blandy <jimb@redhat.com>
16847
16848 * linux-low.c (usr_store_inferior_registers): Transfer buf in
16849 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
16850 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
16851 away part of the register's value.
16852
16853 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
16854
16855 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
16856 (linux_wait_for_event, linux_init_signals): Likewise.
16857
16858 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
16859
16860 * configure.in: Check for stdlib.h.
16861 * configure: Regenerated.
16862 * config.in: Regenerated.
16863
16864 2003-01-04 Andreas Schwab <schwab@suse.de>
16865
16866 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
16867
16868 2003-01-02 Andrew Cagney <ac131313@redhat.com>
16869
16870 * Makefile.in: Remove obsolete code.
16871
16872 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
16873
16874 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
16875 defined(PT_FPR0_HI).
16876
16877 2002-11-17 Stuart Hughes <seh@zee2.com>
16878
16879 * linux-arm-low.c (arm_num_regs): Increase.
16880 (arm_regmap): Include status register.
16881
16882 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
16883
16884 * linux-low.c (register_addr): Remove incorrect -1 check.
16885
16886 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
16887
16888 * linux-low.c (linux_create_inferior): Call setpgid. Return
16889 the new PID.
16890 (unstopped_p, linux_signal_pid): Remove.
16891 (linux_target_ops): Remove linux_signal_pid.
16892 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
16893 global instead of target method.
16894 * target.h (struct target_ops): Remove signal_pid. Update comment
16895 for create_inferior.
16896 * server.c (signal_pid): New variable.
16897 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
16898 gdbserver. Set the child to be the foreground process group.
16899 (attach_inferior): Set signal_pid.
16900
16901 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
16902
16903 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
16904
16905 2002-08-20 Jim Blandy <jimb@redhat.com>
16906
16907 * Makefile.in (LDFLAGS): Allow the configure script to establish a
16908 default for this.
16909
16910 2002-08-01 Andrew Cagney <cagney@redhat.com>
16911
16912 * Makefile.in: Make chill references obsolete.
16913
16914 2002-07-24 Kevin Buettner <kevinb@redhat.com>
16915
16916 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
16917 * configure: Regenerate.
16918 * config.in: Regenerate.
16919
16920 2002-07-09 David O'Brien <obrien@FreeBSD.org>
16921
16922 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
16923 (perror_with_name, remote_close, remote_open, expect, play): Static.
16924
16925 2002-07-04 Michal Ludvig <mludvig@suse.cz>
16926
16927 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
16928 byte offsets instead of an array of indexes.
16929 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
16930
16931 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
16932
16933 * regcache.c: Add comment.
16934
16935 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
16936
16937 * thread-db.c: New file.
16938 * proc-service.c: New file.
16939 * acinclude.m4: New file.
16940 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
16941 proc-service.o, and thread-db.o.
16942 (linux-low.o): Add USE_THREAD_DB.
16943 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
16944 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
16945 * aclocal.m4: Regenerated.
16946 * config.in: Regenerated.
16947 * configure: Regenerated.
16948 * configure.in: Check for proc_service.h, sys/procfs.h,
16949 thread_db.h, and linux/elf.h headrs.
16950 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
16951 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
16952 Check for -lthread_db and thread support.
16953 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
16954 PowerPC, and SuperH.
16955 * i387-fp.c: Constify arguments.
16956 * i387-fp.h: Likewise.
16957 * inferiors.c: (struct thread_info): Renamed from
16958 `struct inferior_info'. Remove PID member. Use generic inferior
16959 list header. All uses updated.
16960 (inferiors, signal_pid): Removed.
16961 (all_threads): New variable.
16962 (get_thread): Define.
16963 (add_inferior_to_list): New function.
16964 (for_each_inferior): New function.
16965 (change_inferior_id): New function.
16966 (add_inferior): Removed.
16967 (remove_inferior): New function.
16968 (add_thread): New function.
16969 (free_one_thread): New function.
16970 (remove_thread): New function.
16971 (clear_inferiors): Use for_each_inferior and free_one_thread.
16972 (find_inferior): New function.
16973 (find_inferior_id): New function.
16974 (inferior_target_data): Update argument type.
16975 (set_inferior_target_data): Likewise.
16976 (inferior_regcache_data): Likewise.
16977 (set_inferior_regcache_data): Likewise.
16978 * linux-low.c (linux_bp_reinsert): Remove.
16979 (all_processes, stopping_threads, using_thrads)
16980 (struct pending_signals, debug_threads, pid_of): New.
16981 (inferior_pid): Replace with macro.
16982 (struct inferior_linux_data): Remove.
16983 (get_stop_pc, add_process): New functions.
16984 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
16985 Use add_process and add_thread.
16986 (linux_attach_lwp): New function, based on old linux_attach. Use
16987 add_process and add_thread. Set stop_expected for new threads.
16988 (linux_attach): New function.
16989 (linux_kill_one_process): New function.
16990 (linux_kill): Kill all LWPs.
16991 (linux_thread_alive): Use find_inferior_id.
16992 (check_removed_breakpoints, status_pending_p): New functions.
16993 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
16994 Update. Use WNOHANG. Wait for cloned processes also. Update process
16995 struct for the found process.
16996 (linux_wait_for_event): New function.
16997 (linux_wait): Use it. Support LWPs.
16998 (send_sigstop, wait_for_sigstop, stop_all_processes)
16999 (linux_resume_one_process, linux_continue_one_process): New functions.
17000 (linux_resume): Support LWPs.
17001 (REGISTER_RAW_SIZE): Remove.
17002 (fetch_register): Use register_size instead. Call supply_register.
17003 (usr_store_inferior_registers): Likewise. Call collect_register.
17004 Fix recursive case.
17005 (regsets_fetch_inferior_registers): Improve error message.
17006 (regsets_store_inferior_registers): Add debugging.
17007 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17008 (unstopped_p, linux_signal_pid): New functions.
17009 (linux_target_ops): Add linux_signal_pid.
17010 (linux_init_signals): New function.
17011 (initialize_low): Call it. Initialize using_threads.
17012 * regcache.c (inferior_regcache_data): Add valid
17013 flag.
17014 (get_regcache): Fetch registers lazily. Add fetch argument
17015 and update all callers.
17016 (regcache_invalidate_one, regcache_invalidate): New
17017 functions.
17018 (new_register_cache): Renamed from create_register_cache.
17019 Return the new regcache.
17020 (free_register_cache): Change argument to a void *.
17021 (registers_to_string, registers_from_string): Call get_regcache
17022 with fetch flag set.
17023 (register_data): Make static. Pass fetch flag to get_regcache.
17024 (supply_register): Call get_regcache with fetch flag clear.
17025 (collect_register): Call get_regcache with fetch flag set.
17026 (collect_register_as_string): New function.
17027 * regcache.h: Update.
17028 * remote-utils.c (putpkt): Flush after debug output and use
17029 stderr.
17030 Handle input interrupts while waiting for an ACK.
17031 (input_interrupt): Use signal_pid method.
17032 (getpkt): Flush after debug output and use stderr.
17033 (outreg): Use collect_register_as_string.
17034 (new_thread_notify, dead_thread_notify): New functions.
17035 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17036 and general_thread.
17037 (look_up_one_symbol): Flush after debug output.
17038 * server.c (step_thread, server_waiting): New variables.
17039 (start_inferior): Don't use signal_pid. Update call to mywait.
17040 (attach_inferior): Update call to mywait.
17041 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17042 (main): Don't fetch/store registers explicitly. Use
17043 set_desired_inferior. Support proposed ``Hs'' packet. Update
17044 calls to mywait.
17045 * server.h: Update.
17046 (struct inferior_list, struct_inferior_list_entry): New.
17047 * target.c (set_desired_inferior): New.
17048 (write_inferior_memory): Constify.
17049 (mywait): New function.
17050 * target.h: Update.
17051 (struct target_ops): New signal_pid method.
17052 (mywait): Removed macro, added prototype.
17053
17054 * linux-low.h (regset_func): Removed.
17055 (regset_fill_func, regset_store_func): New.
17056 (enum regset_type): New.
17057 (struct regset_info): Add type field. Use new operation types.
17058 (struct linux_target_ops): stop_pc renamed to get_pc.
17059 Add decr_pc_after_break and breakpoint_at.
17060 (get_process, get_thread_proess, get_process_thread)
17061 (strut process_info, all_processes, linux_attach_lwp)
17062 (thread_db_init): New.
17063
17064 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17065 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17066 (the_low_target): Add new members.
17067 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17068 (i386_store_fpxregset): Constify.
17069 (target_regsets): Add new kind identifier.
17070 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17071 (i386_set_pc): Add debugging.
17072 (i386_breakpoint_at): New function.
17073 (the_low_target): Add new members.
17074 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17075 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17076 (mips_breakpoint_at): New.
17077 (the_low_target): Add new members.
17078 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17079 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17080 (the_low_target): Add new members.
17081 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17082 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17083 (the_low_target): Add new members.
17084 * linux-x86-64-low.c (target_regsets): Add new kind
17085 identifier.
17086
17087 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17088
17089 From Martin Pool <mbp@samba.org>:
17090 * server.c (gdbserver_usage): New function.
17091 (main): Call it.
17092
17093 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17094
17095 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17096 stop_at -> stop_pc.
17097
17098 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17099
17100 * Makefile.in: Remove obsolete code.
17101
17102 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17103
17104 * linux-low.c (regsets_fetch_inferior_registers),
17105 (regsets_store_inferior_registers): Removed cast to int from
17106 ptrace() calls.
17107 * regcache.h: Added declaration of struct inferior_info.
17108
17109 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17110
17111 * inferiors.c (struct inferior_info): Add regcache_data.
17112 (add_inferior): Call create_register_cache.
17113 (clear_inferiors): Call free_register_cache.
17114 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17115 * regcache.c (struct inferior_regcache_data): New.
17116 (registers): Remove.
17117 (get_regcache): New function.
17118 (create_register_cache, free_register_cache): New functions.
17119 (set_register_cache): Don't initialize the register cache here.
17120 (registers_to_string, registers_from_string, register_data): Call
17121 get_regcache.
17122 * regcache.h: Add prototypes.
17123 * server.h: Likewise.
17124
17125 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17126
17127 * mem-break.c: New file.
17128 * mem-break.h: New file.
17129 * Makefile.in: Add mem-break.o rule; update server.h
17130 dependencies.
17131 * inferiors.c (struct inferior_info): Add target_data
17132 member.
17133 (clear_inferiors): Free target_data member if set.
17134 (inferior_target_data, set_inferior_target_data): New functions.
17135 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17136 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17137 * linux-low.c (linux_bp_reinsert): New variable.
17138 (struct inferior_linux_data): New.
17139 (linux_create_inferior): Use set_inferior_target_data.
17140 (linux_attach): Likewise. Call add_inferior.
17141 (linux_wait_for_one_inferior): New function.
17142 (linux_wait): Call it.
17143 (linux_write_memory): Add const.
17144 (initialize_low): Call set_breakpoint_data.
17145 * linux-low.h (struct linux_target_ops): Add breakpoint
17146 handling members.
17147 * server.c (attach_inferior): Remove extra add_inferior
17148 call.
17149 * server.h: Include mem-break.h. Update inferior.c
17150 prototypes.
17151 * target.c (read_inferior_memory)
17152 (write_inferior_memory): New functions.
17153 * target.h (read_inferior_memory)
17154 (write_inferior_memory): Change macros to prototypes.
17155 (struct target_ops): Update comments. Add const to write_memory
17156 definition.
17157
17158 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17159
17160 * linux-low.c (usr_store_inferior_registers): Support
17161 registers which are allowed to fail to store.
17162 * linux-low.h (linux_target_ops): Likewise.
17163 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17164 (ppc_cannot_store_register): FPSCR may not be storable.
17165
17166 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17167
17168 * server.h: Include <string.h> if HAVE_STRING_H.
17169 * ChangeLog: Correct paths in last ChangeLog entry.
17170
17171 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17172
17173 * linux-low.h: Remove obsolete prototypes.
17174 (struct linux_target_ops): New.
17175 (extern the_low_target): New.
17176 * linux-low.c (num_regs, regmap): Remove declarations.
17177 (register_addr): Use the_low_target explicitly.
17178 (fetch_register): Likewise.
17179 (usr_fetch_inferior_registers): Likewise.
17180 (usr_store_inferior_registers): Likewise.
17181 * linux-arm-low.c (num_regs): Remove.
17182 (arm_num_regs): Define.
17183 (arm_regmap): Renamed from regmap, made static.
17184 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17185 made static.
17186 (arm_cannot_store_register): Renamed from cannot_store_register,
17187 made static.
17188 (the_low_target): New.
17189 * linux-i386-low.c (num_regs): Remove.
17190 (i386_num_regs): Define.
17191 (i386_regmap): Renamed from regmap, made static.
17192 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17193 made static.
17194 (i386_cannot_store_register): Renamed from cannot_store_register,
17195 made static.
17196 (the_low_target): New.
17197 * linux-ia64-low.c (num_regs): Remove.
17198 (ia64_num_regs): Define.
17199 (ia64_regmap): Renamed from regmap, made static.
17200 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17201 made static.
17202 (ia64_cannot_store_register): Renamed from cannot_store_register,
17203 made static.
17204 (the_low_target): New.
17205 * linux-m68k-low.c (num_regs): Remove.
17206 (m68k_num_regs): Define.
17207 (m68k_regmap): Renamed from regmap, made static.
17208 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17209 made static.
17210 (m68k_cannot_store_register): Renamed from cannot_store_register,
17211 made static.
17212 (the_low_target): New.
17213 * linux-mips-low.c (num_regs): Remove.
17214 (mips_num_regs): Define.
17215 (mips_regmap): Renamed from regmap, made static.
17216 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17217 made static.
17218 (mips_cannot_store_register): Renamed from cannot_store_register,
17219 made static.
17220 (the_low_target): New.
17221 * linux-ppc-low.c (num_regs): Remove.
17222 (ppc_num_regs): Define.
17223 (ppc_regmap): Renamed from regmap, made static.
17224 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17225 made static.
17226 (ppc_cannot_store_register): Renamed from cannot_store_register,
17227 made static.
17228 (the_low_target): New.
17229 * linux-s390-low.c (num_regs): Remove.
17230 (s390_num_regs): Define.
17231 (s390_regmap): Renamed from regmap, made static.
17232 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17233 made static.
17234 (s390_cannot_store_register): Renamed from cannot_store_register,
17235 made static.
17236 (the_low_target): New.
17237 * linux-sh-low.c (num_regs): Remove.
17238 (sh_num_regs): Define.
17239 (sh_regmap): Renamed from regmap, made static.
17240 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17241 made static.
17242 (sh_cannot_store_register): Renamed from cannot_store_register,
17243 made static.
17244 (the_low_target): New.
17245 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17246 (the_low_target): New.
17247
17248 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17249
17250 * Makefile.in: Add stamp-h target.
17251 * configure.in: Create stamp-h.
17252 * configure: Regenerated.
17253
17254 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17255
17256 * inferiors.c: New file.
17257 * target.c: New file.
17258 * target.h: New file.
17259 * Makefile.in: Add target.o and inferiors.o. Update
17260 dependencies.
17261 * linux-low.c (inferior_pid): New static variable,
17262 moved from server.c.
17263 (linux_create_inferior): Renamed from create_inferior.
17264 Call add_inferior. Return 0 on success instead of a PID.
17265 (linux_attach): Renamed from myattach.
17266 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17267 (linux_thread_alive): Renamed from mythread_alive.
17268 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17269 child dies.
17270 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17271 (regsets_store_inferior_registers): Correct error message.
17272 Add missing ``return 0''.
17273 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17274 (linux_store_registers): Renamed from store_inferior_registers.
17275 (linux_read_memory): Renamed from read_inferior_memory.
17276 (linux_write_memory): Renamed from write_inferior_memory.
17277 (linux_target_ops): New structure.
17278 (initialize_low): Call set_target_ops ().
17279 * remote-utils.c (unhexify): New function.
17280 (hexify): New function.
17281 (input_interrupt): Send signals to ``signal_pid''.
17282 * server.c (inferior_pid): Remove.
17283 (start_inferior): Update create_inferior call.
17284 (attach_inferior): Call add_inferior.
17285 (handle_query): New function.
17286 (main): Call handle_query for `q' packets.
17287 * server.h: Include "target.h". Remove obsolete prototypes.
17288 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17289
17290 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17291
17292 * Makefile.in: Add WARN_CFLAGS. Update configury
17293 dependencies.
17294 * configure.in: Check for <string.h>
17295 * configure: Regenerate.
17296 * config.in: Regenerate.
17297 * gdbreplay.c: Include needed system headers.
17298 (remote_open): Remove strchr prototype.
17299 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17300 * regcache.c (supply_register): Change buf argument to const void *.
17301 (supply_register_by_name): Likewise.
17302 (collect_register): Change buf argument to void *.
17303 (collect_register_by_name): Likewise.
17304 * regcache.h: Add missing prototypes.
17305 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17306 * server.c (handle_query): New function.
17307 (attached): New static variable, moved out of main.
17308 (main): Quiet longjmp clobber warnings.
17309 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17310 * utils.c (error): Remove NORETURN.
17311 (fatal): Likewise.
This page took 0.423597 seconds and 5 git commands to generate.