1 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
3 Turn process_stratum_target's kill op into a method of
6 * target.h (struct process_stratum_target): Remove the target op.
7 (class process_target): Add the target op.
9 Update the derived classes and callers below.
11 * target.cc (kill_inferior): Update.
12 * linux-low.cc (linux_target_ops): Update.
13 (linux_kill): Turn into ...
14 (linux_process_target::kill): ... this.
15 * linux-low.h (class linux_process_target): Update.
16 * lynx-low.cc (lynx_target_ops): Update.
17 (lynx_kill): Turn into ...
18 (lynx_process_target::kill): ... this.
19 * lynx-low.h (class lynx_process_target): Update.
20 * nto-low.cc (nto_target_ops): Update.
21 (nto_kill): Turn into ...
22 (nto_process_target::kill): ... this.
23 * nto-low.h (class nto_process_target): Update.
24 * win32-low.cc (win32_target_ops): Update.
25 (win32_kill): Turn into ...
26 (win32_process_target::kill): ... this.
27 * win32-low.h (class win32_process_target): Update.
29 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
31 Turn process_stratum_target's attach op into a method of
34 * target.h (struct process_stratum_target): Remove the target op.
35 (class process_target): Add the target op.
36 (myattach): Update the macro.
38 Update the derived classes and callers below.
40 * linux-low.cc (linux_target_ops): Update.
41 (linux_attach): Turn into ...
42 (linux_process_target::attach): ... this.
43 * linux-low.h (class linux_process_target): Update.
44 * lynx-low.cc (lynx_target_ops): Update.
45 (lynx_attach): Turn into ...
46 (lynx_process_target::attach): ... this.
47 * lynx-low.h (class lynx_process_target): Update.
48 * nto-low.cc (nto_target_ops): Update.
49 (nto_attach): Turn into ...
50 (nto_process_target::attach): ... this.
51 * nto-low.h (class nto_process_target): Update.
52 * win32-low.cc (win32_target_ops): Update.
53 (win32_attach): Turn into ...
54 (win32_process_target::attach): ... this.
55 * win32-low.h (class win32_process_target): Update.
57 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
59 Turn process_stratum_target's post_create_inferior op into a method
62 * target.h (struct process_stratum_target): Remove the target op.
63 (class process_target): Add the target op.
64 (target_post_create_inferior): Update the macro.
65 * target.cc (process_target::post_create_inferior): Define.
67 Update the derived classes and callers below.
69 * linux-low.cc (linux_target_ops): Update.
70 (linux_post_create_inferior): Turn into ...
71 (linux_process_target::post_create_inferior): ... this.
72 * linux-low.h (class linux_process_target): Update.
73 * lynx-low.cc (lynx_target_ops): Update.
74 * nto-low.cc (nto_target_ops): Update.
75 * win32-low.cc (win32_target_ops): Update.
77 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
79 Turn process_stratum_target's create_inferior op into a method of
82 * target.h (struct process_stratum_target): Remove the target op.
83 (class process_target): Add the target op.
84 (create_inferior): Rename the macro to ...
85 (target_create_inferior): ... this.
87 Update the derived classes and callers below.
89 * server.cc (handle_v_run): Update.
90 (captured_main): Update.
91 (process_serial_event): Update.
92 * linux-low.cc (linux_target_ops): Update.
93 (linux_create_inferior): Turn into ...
94 (linux_process_target::create_inferior): ... this.
95 * linux-low.h (class linux_process_target): Update.
96 * lynx-low.cc (lynx_target_ops): Update.
97 (lynx_create_inferior): Turn into ...
98 (lynx_process_target::create_inferior): ... this.
99 * lynx-low.h (class lynx_process_target): Update.
100 * nto-low.cc (nto_target_ops): Update.
101 (nto_create_inferior): Turn into ...
102 (nto_process_target::create_inferior): ... this.
103 * nto-low.h (class nto_process_target): Update.
104 * win32-low.cc (win32_target_ops): Update.
105 (win32_create_inferior): Turn into ...
106 (win32_process_target::create_inferior): ... this.
107 * win32-low.h (class win32_process_target): Update.
109 2020-02-20 Tankut Baris Aktemur <tankut.baris.aktemur@intel.com>
111 * target.h (class process_target): New class definition.
112 (struct process_stratum_target) <pt>: New field with type
114 * linux-low.h (class linux_process_target): Define as a derived
115 class of 'process_target'.
116 * linux-low.cc (linux_target_ops): Add a linux_process_target*
118 * lynx-low.h (class lynx_process_target): Define as a derived
119 class of 'process_target'.
120 * lynx-low.cc (lynx_target_ops): Add a lynx_process_target*
122 * nto-low.h (class nto_process_target): Define as a derived
123 class of 'process_target'.
124 * nto-low.cc (nto_target_ops): Add an nto_process_target*
126 * win32-low.h (class win32_process_target): Define as a derived
127 class of 'process_target'.
128 * win32-low.cc (win32_target_ops): Add a win32_process_target*
131 2020-02-19 Andrew Burgess <andrew.burgess@embecosm.com>
133 * configure: Regenerate.
135 2020-02-19 Maciej W. Rozycki <macro@wdc.com>
136 Andrew Burgess <andrew.burgess@embecosm.com>
138 * linux-riscv-low.cc: New file.
139 * Makefile.in (SFILES): Add linux-riscv-low.cc, arch/riscv.c,
140 and nat/riscv-linux-tdesc.c.
141 * configure.srv <riscv*-*-linux*> (srv_tgtobj)
142 (srv_linux_regsets, srv_linux_usrregs, srv_linux_thread_db):
145 2020-02-14 Tom Tromey <tom@tromey.com>
147 * acinclude.m4: Don't include acx_configure_dir.m4.
148 * Makefile.in (LIBIBERTY_BUILDDIR, GNULIB_BUILDDIR): Update.
149 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): Remove.
150 (all, install-only, uninstall, clean-info, clean)
151 (maintainer-clean): Don't recurse.
152 (subdir_do, all-lib): Remove.
153 ($(LIBGNU) $(LIBIBERTY) $(GNULIB_H)): Remove rule.
155 (generated_files): Update.
156 ($(GNULIB_BUILDDIR)/Makefile): Remove rule.
157 * configure: Rebuild.
158 * configure.ac: Don't configure gnulib or libiberty.
161 2020-02-14 Eli Zaretskii <eliz@gnu.org>
163 * win32-low.c (create_process): Prepend PROGRAM to ARGS when
164 preparing the command line for CreateProcess.
165 (win32_create_inferior): Reflect the program name in debugging
166 output that shows the process and its command line.
168 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
170 * Makefile.in: Rename source files from .c to .cc.
171 * %.c: Rename to %.cc.
172 * configure.ac: Rename server.c to server.cc.
173 * configure: Re-generate.
175 2020-02-13 Simon Marchi <simon.marchi@efficios.com>
177 * Makefile.in: Rename gdbsupport source files from .c to .cc.
179 2020-02-12 Hannes Domani <ssbssa@yahoo.de>
181 * win32-low.c (win32_create_inferior): Set signal_pid.
183 2020-02-12 Maciej W. Rozycki <macro@wdc.com>
184 Pedro Alves <palves@redhat.com>
186 Skip building gdbserver in a cross-configuration.
187 * configure.srv: Set $gdbserver_host depending on whether $target
188 is $host. Use $gdbserver_host instead of $host.
190 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
192 * configure: Re-generate.
194 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
196 * configure: Re-generate.
198 2020-02-11 Simon Marchi <simon.marchi@efficios.com>
200 * acinclude.m4: Update warning.m4 path.
202 2020-02-09 Hannes Domani <ssbssa@yahoo.de>
204 * win32-low.c (win32_clear_inferiors): Reset siginfo_er.
205 (handle_exception): Set siginfo_er.
206 (win32_xfer_siginfo): New function.
208 2020-02-07 Tom Tromey <tom@tromey.com>
209 Pedro Alves <palves@redhat.com>
211 * README: Update build documentation.
212 * configure.srv: Set UNSUPPORTED if host is unsupported. Check
214 * configure.ac: Update paths.
215 * configure: Rebuild.
216 * acinclude.m4: Update paths.
217 * Makefile.in: Update include paths.
218 (depcomp, INCLUDE_DIR, INCGNU, INCSUPPORT, INCLUDE_CFLAGS)
219 (SFILES, XML_DIR, n, $(GNULIB_BUILDDIR)/Makefile, config.status)
220 (version-generated.c, stamp-xml, regdat_sh, arch/%-ipa.o)
221 (gdbsupport/%-ipa.o, %-ipa.o, arch/%.o, gdbsupport/%.o, %.o)
222 (%-generated.c): Update paths.
223 * Move entire directory from ../gdb/gdbserver.
225 2020-01-29 Maciej W. Rozycki <macro@wdc.com>
227 * configure.srv <i[34567]86-*-mingw*>: Fix whitespace damage.
229 2020-01-29 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
231 * configure.srv (powerpc*-*-linux*): Use srv_tgtobj in second
232 assignment instead of srv_linux_obj.
234 2020-01-28 Hannes Domani <ssbssa@yahoo.de>
236 * server.c (handle_qxfer_libraries): Write segment-address with
239 2020-01-24 Hannes Domani <ssbssa@yahoo.de>
241 * Makefile.in (install-strip): New target.
242 (install_sh, INSTALL_STRIP_PROGRAM, STRIP): New variables.
243 * aclocal.m4: Regenerate.
244 * configure: Regenerate.
245 * configure.ac: Add AM_PROG_INSTALL_STRIP.
247 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
249 * Makefile.in (SFILES): Adjust paths to point to real files.
250 (OBS): Move waitstatus.o to target/waitstatus.o.
251 (TAGS): Transform paths appropriately.
253 (nat/%.o): ... this pattern rule.
255 (target/%.o): ... this pattern rule.
256 * configure.srv: Adjust paths throughout to include nat/ prefix
257 with the revant files.
258 * configure.ac: Add `nat' and `target' to CONFIG_SRC_SUBDIR.
259 * configure: Regenerate.
261 2020-01-24 Maciej W. Rozycki <macro@wdc.com>
263 * Makefile.in (TAGS): Remove config files from the recipe.
265 2020-01-14 Tom Tromey <tom@tromey.com>
267 * configure: Rebuild.
268 * configure.ac: Remove any checks that were added to common.m4.
269 * acinclude.m4: Include lib-ld.m4, lib-prefix.m4, and
272 2020-01-14 Tom Tromey <tom@tromey.com>
274 * server.h: Include config.h.
275 * gdbreplay.c: Include config.h.
276 * configure: Rebuild.
277 * configure.ac: Don't source common.host.
278 * acinclude.m4: Update path.
279 * Makefile.in (INCSUPPORT): New variable.
280 (INCLUDE_CFLAGS): Add INCSUPPORT.
281 (SFILES): Update paths.
282 (version-generated.c): Update path to create-version.sh.
283 (gdbsupport/%-ipa.o, gdbsupport/%.o): Update paths.
285 2020-01-14 Tom Tromey <tom@tromey.com>
287 * configure.ac (LIBS): Use WIN32APILIBS.
288 (USE_WIN32API): Don't define.
289 * configure: Rebuild.
291 2020-01-14 Tom Tromey <tom@tromey.com>
293 * configure: Rebuild.
295 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
297 * Makefile.in (%-generated.c): Remove rule for files from
300 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
302 * configure: Re-generate.
304 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
306 * tracepoint.h (IP_AGENT_EXPORT_FUNC) [!IN_PROCESS_AGENT]:
308 * tracepoint.c (stop_tracing, flush_trace_buffer,
309 about_to_request_buffer_space, get_trace_state_variable_value,
310 set_trace_state_variable_value, gdb_collect): Add declaration.
312 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
314 * linux-x86-low.c (x86_linux_regs_info, amd64_emit_eq_goto,
315 amd64_emit_ne_goto, amd64_emit_lt_goto, amd64_emit_le_goto,
316 amd64_emit_gt_goto, amd64_emit_ge_goto, amd64_emit_ge_goto,
317 i386_emit_eq_goto, i386_emit_ne_goto, i386_emit_lt_goto,
318 i386_emit_le_goto, i386_emit_gt_goto, i386_emit_ge_goto): Make
321 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
323 * inferiors.c: Include gdbsupport/common-inferior.h.
325 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
327 * hostio-errno.c: Include hostio.h.
329 2020-01-13 Simon Marchi <simon.marchi@efficios.com>
331 * Makefile.in (%-generated.c): Make $(regdat_sh) a regular
334 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
336 * linux-arm-tdesc.c: Include linux-arm-tdesc.h.
337 * linux-arm-tdesc.h: Include arch/arm.h.
339 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
341 * linux-aarch64-low.c (aarch64_write_goto_address): Make static.
343 2020-01-12 Simon Marchi <simon.marchi@polymtl.ca>
345 * linux-aarch32-tdesc.c: Include linux-aarch32-tdesc.h.
346 * linux-aarch64-tdesc.c: Include linux-aarch64-tdesc.h.
348 2020-01-10 Pedro Alves <palves@redhat.com>
350 * fork-child.c (post_fork_inferior): Pass target down to
352 * inferiors.c (switch_to_thread): Add process_stratum_target
354 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
355 * nto-low.c (nto_target_ops): Now a process_stratum_target.
356 * linux-low.c (linux_target_ops): Now a process_stratum_target.
357 * remote-utils.c (prepare_resume_reply): Pass the target to
359 * target.c (the_target): Now a process_stratum_target.
360 (done_accessing_memory): Pass the target to switch_to_thread.
361 (set_target_ops): Ajust to use process_stratum_target.
362 * target.h (struct target_ops): Rename to ...
363 (struct process_stratum_target): ... this.
364 (the_target, set_target_ops): Adjust.
365 (prepare_to_access_memory): Adjust comment.
366 * win32-low.c (child_xfer_memory): Adjust to use
367 process_stratum_target.
368 (win32_target_ops): Now a process_stratum_target.
370 2020-01-06 Eli Zaretskii <eliz@gnu.org>
371 Pedro Alves <palves@redhat.com>
373 * win32-low.c (get_child_debug_event): Extract the fatal exception
374 from the exit status and convert to the equivalent Posix signal
376 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
377 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
379 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
381 * Makefile.in: Use INSTALL_PROGRAM_ENV.
383 2020-01-01 Joel Brobecker <brobecker@adacore.com>
385 * server.c (gdbserver_version): Change copyright year to 2020.
386 * gdbreplay.c (gdbreplay_version): Likewise.
388 2019-12-19 Christian Biesinger <cbiesinger@google.com>
390 * configure: Regenerate.
391 * configure.ac: Quote variable arguments of test.
393 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
395 * Makefile.in: Fix build with GNU Make 3.81
397 2019-12-16 Tom Tromey <tromey@adacore.com>
399 * server.c (get_exec_file): Constify result.
401 2019-12-10 Christian Biesinger <cbiesinger@google.com>
403 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
404 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
405 * config.in: Regenerate.
406 * configure: Regenerate.
407 * configure.ac: Don't check for strerror.
408 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
409 Call safe_strerror instead of strerror.
410 * server.h (strerror): Remove this now-unnecessary declaration.
411 * tracepoint.c (init_named_socket): Call safe_strerror instead of
413 (gdb_agent_helper_thread): Likewise.
414 * utils.c (perror_with_name): Likewise.
416 2019-11-26 Tom Tromey <tom@tromey.com>
418 * configure, config.in: Rebuild.
420 2019-11-26 Tom Tromey <tom@tromey.com>
422 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
423 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
425 * configure, config.in: Rebuild.
427 2019-11-26 Tom Tromey <tom@tromey.com>
429 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
430 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
431 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
432 * acinclude.m4: Include ax_pthread.m4.
433 * config.in, configure: Rebuild.
435 2019-11-26 Christian Biesinger <cbiesinger@google.com>
437 * debug.c (debug_set_output): Call safe_strerror instead of
439 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
440 (linux_kill_one_lwp): Likewise.
441 (linux_detach_one_lwp): Likewise.
442 (linux_wait_for_event_filtered): Likewise.
443 (store_register): Likewise.
444 * lynx-low.c (lynx_attach): Likewise.
445 * mem-break.c (insert_memory_breakpoint): Likewise.
446 (remove_memory_breakpoint): Likewise.
447 (delete_fast_tracepoint_jump): Likewise.
448 (set_fast_tracepoint_jump): Likewise.
449 (uninsert_fast_tracepoint_jumps_at): Likewise.
450 (reinsert_fast_tracepoint_jumps_at): Likewise.
451 * nto-low.c (nto_xfer_memory): Likewise.
452 (nto_resume): Likewise.
454 2019-11-20 Luis Machado <luis.machado@linaro.org>
456 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
457 instead of register count.
458 * tdesc.c (tdesc_contains_feature): New function.
459 * tdesc.h (tdesc_contains_feature): New prototype.
461 2019-11-15 Christian Biesinger <cbiesinger@google.com>
463 * Makefile.in: Add safe-strerror.c.
464 * configure: Regenerate.
465 * configure.ac: Don't source common.host.
467 2019-11-15 Christian Biesinger <cbiesinger@google.com>
469 * config.in: Regenerate.
470 * configure: Regenerate.
472 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
474 * ax.c (ax_printf): Handle size_t_arg.
476 2019-11-06 Christian Biesinger <cbiesinger@google.com>
478 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
479 * mi/mi-main.c (output_cores): Likewise.
480 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
481 (linux_xfer_osdata_modules): Likewise.
482 * remote.c (register_remote_support_xml): Likewise.
483 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
484 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
486 2019-11-01 Christian Biesinger <cbiesinger@google.com>
488 * configure: Regenerate.
489 * configure.ac: Remove check for strerror_r.
491 2019-10-31 Christian Biesinger <cbiesinger@google.com>
493 * config.in: Regenerate.
494 * configure: Regenerate.
495 * configure.ac: Also check for strerror_r.
497 2019-10-31 Christian Biesinger <cbiesinger@google.com>
499 * ax.h (debug_agent): Remove duplicate declaration.
501 2019-10-26 Tom de Vries <tdevries@suse.de>
503 * linux-aarch64-low.c: Fix typos in comments.
504 * linux-arm-low.c: Same.
506 * linux-ppc-low.c: Same.
507 * proc-service.c: Same.
510 * tracepoint.c: Same.
513 2019-10-25 Tom Tromey <tromey@adacore.com>
515 * utils.c (xstrdup): Remove.
517 2019-10-23 Tom Tromey <tom@tromey.com>
519 * configure, config.in: Rebuild.
521 2019-10-23 Tom Tromey <tom@tromey.com>
523 * configure: Rebuild.
524 * acinclude.m4: Use m4_include, not sinclude.
526 2019-10-17 Tom Tromey <tromey@adacore.com>
528 * configure: Rebuild.
529 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
530 in AC_CONFIG_FILES invocation.
531 * Makefile.in (stamp-h, Makefile): Use new-style config.status
534 2019-10-16 Christian Biesinger <cbiesinger@google.com>
536 * server.c: Include xml-builtin.h.
537 (get_xml_features): Don't declare xml_builtins here.
539 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
541 * Makefile.in: Remove references to vec-ipa.o.
543 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
545 * Makefile.in: Remove references to vec.c.
547 2019-10-02 Christian Biesinger <cbiesinger@google.com>
549 * server.c (server_waiting): Change to bool.
550 (extended_protocol): Likewise.
551 (response_needed): Likewise.
552 (exit_requested): Likewise.
553 (run_once): Likewise.
554 (report_no_resumed): Likewise.
555 (non_stop): Likewise.
556 (disable_packet_vCont): Likewise.
557 (disable_packet_Tthread): Likewise.
558 (disable_packet_qC): Likewise.
559 (disable_packet_qfThreadInfo): Likewise.
560 (handle_general_set): Update.
561 (handle_detach): Update.
562 (handle_monitor_command): Update.
563 (handle_query): Update.
564 (captured_main): Update.
565 (process_serial_event): Update.
566 * server.h (server_waiting): Change to bool.
567 (disable_packet_vCont): Likewise.
568 (disable_packet_Tthread): Likewise.
569 (disable_packet_qC): Likewise.
570 (disable_packet_qfThreadInfo): Likewise.
571 (run_once): Likewise.
572 (non_stop): Likewise.
573 * target.c (target_stop_and_wait): Update.
575 2019-10-02 Tom Tromey <tromey@adacore.com>
577 * Makefile.in (SFILES): Add common-inferior.c.
578 (OBS): Add common-inferior.o.
579 * server.c (startup_with_shell): Don't define.
581 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
583 * linux-low.c (linux_low_read_btrace): Update for change to
586 2019-09-20 Christian Biesinger <cbiesinger@google.com>
588 * debug.c (debug_threads): Remove comment in favor of the header.
589 * debug.h (using_threads): Add declaration.
590 (debug_threads): Add comment.
591 * linux-aarch64-low.c: Include debug.h and remove declaration of
593 * nto-low.c: Likewise.
594 * remote-utils.c: Likewise.
595 * thread-db.c: Likewise.
597 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
599 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
600 and powerpc-cell64l-ipa.o.
601 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
602 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
603 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
606 * spu-low.c: Remove file.
608 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
609 (parse_spufs_run): Remove.
610 (ppc_get_pc): Remove Cell/B.E. support.
611 (ppc_set_pc): Likewise.
612 (ppc_breakpoint_at): Likewise.
613 (ppc_arch_setup): Likewise.
614 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
615 tdesc_powerpc_cell32l.
616 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
617 or init_registers_powerpc_cell32l.
618 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
619 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
620 or init_registers_powerpc_cell32l.
621 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
622 (init_registers_powerpc_cell32l): Remove prototype.
623 (init_registers_powerpc_cell64l): Likewise.
625 * target.h (struct target_ops): Remove qxfer_spu member.
626 * server.c (handle_qxfer_spu): Remove.
627 (qxfer_packets): Remove entry for "spu".
628 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
629 * linux-low.c (SPUFS_MAGIC): Remove.
630 (spu_enumerate_spu_ids): Remove.
631 (linux_qxfer_spu): Remove.
632 (linux_target_ops): Remove qxfer_spu member.
633 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
634 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
635 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
637 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
639 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
640 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
641 * config.in: Regenerate.
642 * configure: Regenerate.
644 2019-08-15 Tom Tromey <tromey@adacore.com>
646 * target.c (target_write_memory): Use gdb::byte_vector.
648 2019-08-15 Tom Tromey <tromey@adacore.com>
650 * tracepoint.c (write_inferior_data_pointer)
651 (write_inferior_integer, write_inferior_int8)
652 (write_inferior_uinteger, m_tracepoint_action_download)
653 (r_tracepoint_action_download, x_tracepoint_action_download)
654 (l_tracepoint_action_download, clear_inferior_trace_buffer)
655 (download_agent_expr, download_tracepoint_1)
656 (download_trace_state_variables, upload_fast_traceframes): Update.
657 * server.c (gdb_write_memory): Update.
658 * remote-utils.c (relocate_instruction): Update.
659 * proc-service.c (ps_pdwrite): Update.
660 * mem-break.c (remove_memory_breakpoint)
661 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
662 (uninsert_fast_tracepoint_jumps_at)
663 (reinsert_fast_tracepoint_jumps_at): Update.
664 * linux-x86-low.c (append_insns)
665 (i386_install_fast_tracepoint_jump_pad)
666 (amd64_write_goto_address, i386_write_goto_address): Update.
667 * linux-s390-low.c (append_insns, s390_write_goto_address):
669 * linux-ppc-low.c (ppc_relocate_instruction)
670 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
671 (ppc_write_goto_address): Update.
672 * linux-aarch64-low.c (append_insns): Update.
673 * target.h (struct target_ops): Update.
674 (write_inferior_memory): Don't declare.
675 * target.c (target_write_memory): Rename from
676 write_inferior_memory. Remove old target_write_memory.
678 2019-08-15 Tom Tromey <tromey@adacore.com>
680 * target.c (write_inferior_memory): Use std::vector.
682 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
685 * configure.ac: Drop enable-libmcheck support.
686 * configure, config.in: Rebuild.
687 * acinclude.m4: Don't include it.
689 2019-07-19 Alan Hayward <alan.hayward@arm.com>
691 * configure.srv: Remove Arm xml files.
693 2019-07-19 Alan Hayward <alan.hayward@arm.com>
695 * configure.srv: Add new files. Remove xml generated files.
696 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
698 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
699 * linux-aarch32-tdesc.c: New file.
700 * linux-aarch32-tdesc.h: New file.
701 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
702 * linux-arm-low.c (init_registers_arm, tdesc_arm)
703 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
704 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
705 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
706 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
707 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
708 (arm_read_description): Call arm_linux_read_description.
709 (initialize_low_arch): Don't init registers.
710 * linux-arm-tdesc.c: New file.
711 * linux-arm-tdesc.h: New file.
713 2019-07-10 Alan Hayward <alan.hayward@arm.com>
715 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
716 Move counter inside for.
717 (arm_read_description): Check ptrace earlier.
718 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
720 2019-07-09 Tom Tromey <tom@tromey.com>
722 * configure: Rebuild.
723 * configure.ac: Change common to gdbsupport.
724 * acinclude.m4: Change common to gdbsupport.
725 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
726 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
727 common to gdbsupport.
728 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
729 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
730 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
731 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
732 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
733 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
734 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
735 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
736 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
737 common to gdbsupport.
739 2019-07-04 Alan Hayward <alan.hayward@arm.com>
741 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
743 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
745 2019-07-04 Alan Hayward <alan.hayward@arm.com>
747 * configure.srv: Remove legacy xml.
748 * linux-aarch64-low.c (initialize_low_arch): Remove
749 initialize_low_tdesc call.
750 * linux-aarch64-tdesc-selftest.c: Remove file.
751 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
752 * linux-x86-low.c (initialize_low_arch): Remove
753 initialize_low_tdesc call.
754 * linux-x86-tdesc-selftest.c: Remove file.
755 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
757 2019-06-20 Tom de Vries <tdevries@suse.de>
759 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
760 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
762 2019-06-19 Tom de Vries <tdevries@suse.de>
764 * debug.h (debug_write): Change return type to ssize_t.
765 * debug.c (debug_write): Same.
767 2019-06-14 Tom Tromey <tom@tromey.com>
769 * configure.ac: Use new path to gnulib.
770 * configure: Rebuild.
771 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
774 2019-06-11 Tom Tromey <tom@tromey.com>
776 * Makefile.in (SFILES): Add alloc.c.
778 (IPA_OBJS): Add alloc-ipa.o.
779 (alloc-ipa.o): New target.
780 (%.o: ../%.c): New pattern rule.
782 2019-06-10 Tom Tromey <tromey@adacore.com>
784 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
785 end warning with a newline.
786 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
788 * thread-db.c (attach_thread): Don't end warning with a newline.
789 (thread_db_notice_clone): Likewise.
790 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
792 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
793 end warning with a newline.
795 2019-06-04 Pedro Alves <palves@redhat.com>
797 * server.c (captured_main): Use make_unique_xstrdup.
799 2019-06-02 Tom Tromey <tom@tromey.com>
801 * gdbreplay.c (fromhex): Remove.
802 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
804 2019-05-29 Tom Tromey <tromey@adacore.com>
806 * configure: Rebuild.
808 2019-05-06 Kevin Buettner <kevinb@redhat.com>
810 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
811 sign extension code on 32-bit builds.
813 2019-05-03 Eli Zaretskii <eliz@gnu.org>
816 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
818 2019-04-19 Tom Tromey <tom@tromey.com>
820 * server.c (struct vstop_notif): Derive from notif_event.
822 (queue_stop_reply): Update.
823 (remove_all_on_match_ptid): Change type. Rewrite.
824 (discard_queued_stop_replies): Rewrite.
825 (in_queued_stop_replies_ptid): Change type.
826 (in_queued_stop_replies): Rewrite.
827 (notif_stop): Update.
828 (queue_stop_reply_callback): Update.
829 (captured_main): Don't call initialize_notif.
830 (push_stop_notification): Update.
831 * notif.c (notif_write_event, handle_notif_ack)
832 (notif_event_enque, notif_push): Update.
833 (notif_event_xfree, initialize_notif): Remove.
834 * notif.h (struct notif_event): Include <list>, not
836 (struct notif_server) <queue>: Now a std::list.
837 (notif_event_p): Remove typedef.
838 (initialize_notif): Don't declare.
839 (struct notif_event): Add virtual destructor.
841 2019-04-17 Alan Hayward <alan.hayward@arm.com>
843 * ax.c (ax_vdebug): Call debug_printf.
844 * debug.c (debug_write): New function.
845 * debug.h (debug_write): New declaration.
846 * linux-low.c (sigchld_handler): Call debug_write.
848 2019-04-17 Alan Hayward <alan.hayward@arm.com>
850 * debug.c (debug_set_output): New function.
851 (debug_vprintf): Send output to debug_file.
852 (debug_flush): Likewise.
853 * debug.h (debug_set_output): New declaration.
854 * server.c (handle_monitor_command): Add debug-file option.
855 (captured_main): Likewise.
857 2019-04-17 Alan Hayward <alan.hayward@arm.com>
859 * debug.c (remote_debug): Add definition.
860 * debug.h (remote_debug): Add declaration.
861 * hostio.c (remote_debug): Remove declaration.
862 * remote-utils.c (struct ui_file): Likewise.
863 (remote_debug): Likewise.
864 * remote-utils.h (remote_debug): Likewise,
865 * server.c (remote_debug): Remove definition.
867 2019-04-10 Kevin Buettner <kevinb@redhat.com>
869 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
870 when using a 64-bit gdbserver.
872 2019-04-09 Tom Tromey <tromey@adacore.com>
874 * linux-low.c (select_event_lwp): Use find_thread_in_random.
876 2019-04-08 Tom Tromey <tom@tromey.com>
878 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
880 (linux_resume_one_lwp): Likewise.
882 2019-04-08 Tom Tromey <tom@tromey.com>
884 * gdbreplay.c: Update.
885 * linux-low.c: Update.
888 2019-04-08 Tom Tromey <tom@tromey.com>
890 * server.c: Use C++ exception handling.
891 * linux-low.c: Use C++ exception handling.
892 * gdbreplay.c: Use C++ exception handling.
894 2019-04-08 Tom Tromey <tom@tromey.com>
896 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
897 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
898 (captured_main, main): Update.
899 * gdbreplay.c (main): Update.
901 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
903 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
904 value in argument pointer, return 1 if the entry is found and 0
905 otherwise. Move comment.
906 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
907 * linux-low.h (linux_get_auxv): Declare.
908 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
910 2019-04-05 Tom Tromey <tromey@adacore.com>
912 * server.c (gdbserver_usage): Use upper-case for metasyntactic
915 2019-03-28 Alan Hayward <alan.hayward@arm.com>
917 * linux-low.c (AT_HWCAP2): Add define if not already included.
919 2019-03-26 Alan Hayward <alan.hayward@arm.com>
921 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
922 (aarch64_arch_setup): Call linux_get_hwcap.
923 * linux-arm-low.c (arm_get_hwcap): Remove function.
924 (arm_read_description): Call linux_get_hwcap.
925 * linux-low.c (linux_get_auxv): New function.
926 (linux_get_hwcap): Likewise.
927 (linux_get_hwcap2): Likewise.
928 * linux-low.h (linux_get_hwcap): New declaration.
929 (linux_get_hwcap2): Likewise.
930 * linux-ppc-low.c (ppc_get_auxv): Remove function.
931 (ppc_arch_setup): Call linux_get_hwcap.
932 * linux-s390-low.c (s390_get_hwcap): Remove function.
933 (s390_arch_setup): Call linux_get_hwcap.
935 2019-03-22 Alan Hayward <alan.hayward@arm.com>
936 Jiong Wang <jiong.wang@arm.com>
938 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
939 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
941 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
943 2019-03-22 Alan Hayward <alan.hayward@arm.com>
944 Jiong Wang <jiong.wang@arm.com>
946 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
947 (aarch64_get_hwcap): New function.
948 (aarch64_arch_setup): Read APIA hwcap.
950 2019-03-22 Alan Hayward <alan.hayward@arm.com>
951 Jiong Wang <jiong.wang@arm.com>
953 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
954 (initialize_low_tracepoint): Likewise.
955 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
956 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
957 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
958 (aarch64_linux_read_description): Likewise.
959 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
961 2019-03-12 John Baldwin <jhb@FreeBSD.org>
963 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
964 i386_create_target_description for 'segments' parameter.
965 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
966 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
967 * win32-i386-low.c (i386_arch_setup): Likewise.
969 2019-03-12 Tom Tromey <tromey@adacore.com>
971 * linux-low.c (iterate_over_lwps): Update.
973 2019-03-06 Tom Tromey <tom@tromey.com>
975 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
976 (captured_main): Use SCOPE_EXIT.
978 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
980 * configure.srv: Use '$enable_unittest' instead of '$development'
981 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
984 2019-02-27 Tom Tromey <tromey@adacore.com>
986 * gdbreplay.c (logchar): Handle \r\n.
988 2019-02-07 Alan Hayward <alan.hayward@arm.com>
990 * linux-low.c (linux_attach): Add process before lwp.
991 * server.c (attach_inferior): Check if already attached.
993 2019-02-07 Tom Tromey <tom@tromey.com>
995 * x86-tdesc.h: Rename include guard.
996 * x86-low.h: Add include guard.
997 * wincecompat.h: Rename include guard.
998 * win32-low.h: Add include guard.
999 * utils.h: Rename include guard.
1000 * tracepoint.h: Rename include guard.
1001 * tdesc.h: Rename include guard.
1002 * target.h: Rename include guard.
1003 * server.h: Rename include guard.
1004 * remote-utils.h: Rename include guard.
1005 * regcache.h: Rename include guard.
1006 * nto-low.h: Rename include guard.
1007 * notif.h: Add include guard.
1008 * mem-break.h: Rename include guard.
1009 * lynx-low.h: Add include guard.
1010 * linux-x86-tdesc.h: Add include guard.
1011 * linux-s390-tdesc.h: Add include guard.
1012 * linux-ppc-tdesc-init.h: Add include guard.
1013 * linux-low.h: Add include guard.
1014 * linux-aarch64-tdesc.h: Add include guard.
1015 * linux-aarch32-low.h: Add include guard.
1016 * inferiors.h: Rename include guard.
1017 * i387-fp.h: Rename include guard.
1018 * hostio.h: Rename include guard.
1019 * gdbthread.h: Rename include guard.
1020 * gdb_proc_service.h: Rename include guard.
1021 * event-loop.h: Rename include guard.
1022 * dll.h: Rename include guard.
1023 * debug.h: Rename include guard.
1024 * ax.h: Rename include guard.
1026 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
1029 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
1030 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
1032 2019-01-25 Tom Tromey <tom@tromey.com>
1034 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
1036 2019-01-25 Tom Tromey <tom@tromey.com>
1038 * win32-low.c: Fix common/ includes.
1039 * win32-i386-low.c: Fix common/ includes.
1040 * tracepoint.c: Fix common/ includes.
1041 * thread-db.c: Fix common/ includes.
1042 * target.h: Fix common/ includes.
1043 * symbol.c: Fix common/ includes.
1044 * spu-low.c: Fix common/ includes.
1045 * server.h: Fix common/ includes.
1046 * server.c: Fix common/ includes.
1047 * remote-utils.c: Fix common/ includes.
1048 * regcache.h: Fix common/ includes.
1049 * regcache.c: Fix common/ includes.
1050 * nto-x86-low.c: Fix common/ includes.
1051 * notif.h: Fix common/ includes.
1052 * mem-break.h: Fix common/ includes.
1053 * lynx-low.c: Fix common/ includes.
1054 * lynx-i386-low.c: Fix common/ includes.
1055 * linux-x86-tdesc-selftest.c: Fix common/ includes.
1056 * linux-x86-low.c: Fix common/ includes.
1057 * linux-low.c: Fix common/ includes.
1058 * inferiors.h: Fix common/ includes.
1059 * i387-fp.c: Fix common/ includes.
1060 * hostio.c: Fix common/ includes.
1061 * hostio-errno.c: Fix common/ includes.
1062 * gdbthread.h: Fix common/ includes.
1063 * gdbreplay.c: Fix common/ includes.
1064 * fork-child.c: Fix common/ includes.
1065 * event-loop.c: Fix common/ includes.
1067 (enum gdb_agent_op): Fix common/ includes.
1069 2019-01-21 Tom Tromey <tom@tromey.com>
1071 * tracepoint.c: Fix includes.
1072 * remote-utils.c: Fix includes.
1073 * linux-x86-low.c: Fix includes.
1075 2019-01-01 Joel Brobecker <brobecker@adacore.com>
1077 * gdbreplay.c (gdbreplay_version): Update copyright year in
1079 * server.c (gdbserver_version): Likewise.
1081 2018-12-05 Alan Hayward <alan.hayward@arm.com>
1083 * linux-low.c (add_lwp): Switch ordering.
1085 2018-11-29 Tom Tromey <tom@tromey.com>
1087 * win32-low.c (win32_join): Take pid, not process.
1088 * target.h (struct target_ops) <join>: Change argument type.
1089 (join_inferior): Change argument name.
1090 * spu-low.c (spu_join): Take pid, not process.
1091 * server.c (handle_detach): Preserve pid before destroying
1093 * lynx-low.c (lynx_join): Take pid, not process.
1094 * linux-low.c (linux_join): Take pid, not process.
1096 2018-11-23 Alan Hayward <alan.hayward@arm.com>
1098 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
1099 (aarch64_cannot_fetch_register): Likewise.
1100 (struct linux_target_ops): Update references.
1102 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1104 * linux-ppc-low.c: Include nat/linux-ptrace.h.
1106 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1108 * configure.srv (ipa_ppc_linux_regobj): Add
1109 powerpc-isa207-htm-vsx32l-ipa.o and
1110 powerpc-isa207-htm-vsx64l-ipa.o.
1111 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
1112 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
1113 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
1114 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
1115 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
1116 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
1117 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
1118 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
1119 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1120 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
1121 (init_registers_powerpc_isa207_htm_vsx32l)
1122 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
1123 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
1124 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
1125 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
1126 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
1127 (ppc_store_tm_ctarregset): New functions.
1128 (ppc_regsets): Add entries for HTM regsets.
1129 (ppc_arch_setup): Set htm in features struct when needed. Set
1130 sizes for the HTM regsets.
1131 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
1132 (initialize_low_arch): Call
1133 init_registers_powerpc_isa207_htm_vsx32l and
1134 init_registers_powerpc_isa207_htm_vsx64l.
1135 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
1136 PPC_TDESC_ISA207_HTM_VSX.
1137 (initialize_low_tracepoint): Call
1138 init_registers_powerpc_isa207_htm_vsx32l and
1139 init_registers_powerpc_isa207_htm_vsx64l.
1141 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1143 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
1144 rs6000/power-linux-pmu.xml to srv_xmlfiles.
1145 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
1146 (ppc_store_pmuregset): New functions.
1147 (ppc_regsets): Add entries for ebb and pmu regsets.
1148 (ppc_arch_setup): Set isa207 in features struct if the ebb and
1149 pmu regsets are available. Set sizes for these regsets.
1151 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1153 * configure.srv (ipa_ppc_linux_regobj): Add
1154 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
1155 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
1156 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
1157 rs6000/powerpc-isa207-vsx32l.xml, and
1158 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
1159 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1160 <PPC_TDESC_ISA207_VSX>: New enum value.
1161 (init_registers_powerpc_isa207_vsx32l): Declare.
1162 (init_registers_powerpc_isa207_vsx64l): Declare.
1163 * linux-ppc-low.c (ppc_fill_tarregset): New function.
1164 (ppc_store_tarregset): New function.
1165 (ppc_regsets): Add entry for the TAR regset.
1166 (ppc_arch_setup): Set isa207 in features struct when needed. Set
1167 size for the TAR regsets.
1168 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
1169 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
1170 and init_registers_powerpc_isa207_vsx64l.
1171 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
1172 (initialize_low_tracepoint): Call
1173 init_registers_powerpc_isa207_vsx32l and
1174 init_registers_powerpc_isa207_vsx64l.
1176 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
1177 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1179 * configure.srv (ipa_ppc_linux_regobj): Add
1180 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
1181 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
1182 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
1183 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
1184 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
1185 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
1186 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
1187 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
1188 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
1189 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
1190 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
1191 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
1192 (ppc_hwcap): Add comment.
1193 (ppc_hwcap2): New global.
1194 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
1195 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
1196 (ppc_regsets): Add entries for the DSCR and PPR regsets.
1197 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
1198 when needed. Set sizes for the the DSCR and PPR regsets.
1199 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
1200 (initialize_low_arch): Call
1201 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
1202 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
1203 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
1204 PPC_TDESC_ISA205_PPR_DSCR_VSX.
1205 (initialize_low_tracepoint): Call
1206 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
1207 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
1209 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
1211 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
1213 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
1214 Simon Marchi <simark@simark.ca>
1216 * acinclude.m4: Include "../selftest.m4".
1217 * configure: Regenerate.
1218 * configure.ac: Use "GDB_AC_SELFTEST".
1219 * configure.srv: Use "$enable_unittests" instead of
1220 "$development" when checking whether unit tests have been
1222 * server.c (captured_main): Update message informing that
1223 selftests have been disabled.
1225 2018-10-04 Tom Tromey <tom@tromey.com>
1227 * configure: Rebuild.
1229 2018-10-04 Tom Tromey <tom@tromey.com>
1231 * server.c (handle_status): Rename inner "thread".
1232 (process_serial_event): Declare "res" in 'm' case.
1233 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
1234 (iterate_over_lwps): Rename inner "thread".
1235 (linux_qxfer_libraries_svr4): Rename inner "len".
1236 * gdbthread.h (find_thread_in_random): Rename inner "thread".
1238 2018-10-01 Gary Benson <gbenson@redhat.com>
1240 * gdb_proc_service.h: Moved common code to
1241 common/gdb_proc_service.h.
1243 2018-10-01 Gary Benson <gbenson@redhat.com>
1245 * gdb_proc_service.h: Synchronize comments and whitespace with
1246 GDB's version of this file.
1248 2018-09-25 Tom Tromey <tom@tromey.com>
1250 * configure: Rebuild.
1251 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
1253 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
1255 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
1256 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
1257 ($(IPA_LIB)): Sort IPA_OBJS.
1259 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
1261 * Makefile.in: Remove references to $(ADD_DEPS).
1263 2018-09-16 Tom Tromey <tom@tromey.com>
1265 * remote-utils.c (remote_open): Use GNU style for metasyntactic
1267 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
1270 2018-09-05 Tom Tromey <tom@tromey.com>
1272 * configure: Rebuild.
1274 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
1277 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
1279 2018-08-27 Tom Tromey <tom@tromey.com>
1282 * configure: Rebuild.
1284 2018-08-27 Tom Tromey <tom@tromey.com>
1286 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
1287 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
1288 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
1289 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
1290 (s390x_emit_stack_adjust): Add casts to unsigned char.
1292 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
1296 * server.h (struct client_state) <disable_randomization>:
1299 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
1301 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
1303 (mips_supply_ptrace_register): Likewise.
1305 2018-07-22 Tom Tromey <tom@tromey.com>
1307 * configure: Rebuild.
1309 2018-07-22 Tom Tromey <tom@tromey.com>
1311 * win32-low.c (win32_create_inferior): Remove unused variables.
1312 * gdbreplay.c (remote_open): Remove unused variable.
1313 * remote-utils.c (remote_prepare): Remove unused variable.
1314 * x86-tdesc.h (X86_TDESC_H): Define.
1315 (amd64_expedite_regs): Define conditionally.
1316 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
1317 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
1318 * remote-utils.c (readchar): Remove unused variable.
1320 2018-07-13 Pedro Alves <palves@redhat.com>
1322 * linux-low.c (linux_kill): Change parameter to process_info
1323 pointer instead of pid. Adjust.
1324 * lynx-low.c (lynx_kill): Likewise.
1325 * nto-low.c (nto_kill): Likewise.
1326 * spu-low.c (spu_kill): Likewise.
1327 * win32-low.c (win32_kill): Likewise.
1328 * server.c (handle_v_kill, kill_inferior_callback)
1329 (detach_or_kill_for_exit): Adjust.
1330 * target.c (kill_inferior): Change parameter to process_info
1331 pointer instead of pid. Adjust.
1332 * target.h (struct target_ops) <kill>: Change parameter to
1333 process_info pointer instead of pid. Adjust all implementations
1335 (kill_inferior): Likewise.
1337 2018-07-13 Pedro Alves <palves@redhat.com>
1339 * linux-low.c (linux_detach, linux_join): Change parameter to
1340 process_info pointer instead of pid. Adjust.
1341 * lynx-low.c (lynx_detach, lynx_join): Likewise.
1342 * nto-low.c (nto_detach): Likewise.
1343 * spu-low.c (spu_detach, spu_join): Likewise.
1344 * win32-low.c (win32_detach, win32_join): Likewise.
1345 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
1346 * target.h (struct target_ops) <detach, join>: Change parameter to
1347 process_info pointer instead of pid. Adjust all implementations
1349 (detach_inferior, join_inferior): Rename 'pid' parameter to
1352 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1353 Jan Kratochvil <jan.kratochvil@redhat.com>
1354 Paul Fertser <fercerpav@gmail.com>
1355 Tsutomu Seki <sekiriki@gmail.com>
1357 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
1358 (OBS): Add 'common/netstuff.o'.
1359 (GDBREPLAY_OBS): Likewise.
1360 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
1361 (remote_open): Implement support for IPv6
1363 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
1365 (handle_accept_event): Accept connections from IPv6 sources.
1366 (remote_prepare): Handle IPv6-style hostnames; implement
1367 support for IPv6 connections.
1368 (remote_open): Implement support for printing connections from
1371 2018-07-11 Pedro Alves <palves@redhat.com>
1374 * mem-break.c (any_persistent_commands): Add process_info
1375 parameter and use it instead of relying on the current process.
1376 Change return type to bool.
1377 * mem-break.h (any_persistent_commands): Add process_info
1378 parameter and change return type to bool.
1379 * server.c (handle_detach): Remove require_running_or_return call.
1380 Look up the process_info for the process we're about to detach.
1381 If not found, return back error to GDB. Adjust
1382 any_persistent_commands call to pass down a process pointer.
1384 2018-07-11 Pedro Alves <palves@redhat.com>
1386 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
1387 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
1388 instead of collect_register_by_name.
1389 * regcache.c (regcache_raw_get_unsigned_by_name): New.
1390 * regcache.h (regcache_raw_get_unsigned_by_name): New.
1392 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1393 Pedro Alves <palves@redhat.com>
1395 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
1397 2018-07-03 Tom Tromey <tom@tromey.com>
1399 * linux-low.c: Update.
1400 * lynx-low.c: Update.
1401 * mem-break.c: Update.
1402 * nto-low.c: Update.
1403 * remote-utils.c: Update.
1405 * spu-low.c: Update.
1407 * win32-low.c: Update.
1409 2018-07-03 Tom Tromey <tom@tromey.com>
1413 2018-07-03 Tom Tromey <tom@tromey.com>
1415 * linux-low.c: Update.
1417 2018-07-03 Tom Tromey <tom@tromey.com>
1421 2018-07-03 Tom Tromey <tom@tromey.com>
1423 * linux-low.c: Update.
1424 * linux-mips-low.c: Update.
1425 * lynx-low.c: Update.
1426 * nto-low.c: Update.
1427 * remote-utils.c: Update.
1429 * spu-low.c: Update.
1431 * thread-db.c: Update.
1433 2018-07-03 Tom Tromey <tom@tromey.com>
1435 * linux-low.c: Update.
1436 * linux-mips-low.c: Update.
1437 * lynx-low.c: Update.
1438 * mem-break.c: Update.
1439 * nto-low.c: Update.
1440 * remote-utils.c: Update.
1442 * spu-low.c: Update.
1444 * tracepoint.c: Update.
1446 2018-07-03 Tom Tromey <tom@tromey.com>
1448 * linux-low.c: Update.
1449 * linux-ppc-low.c: Update.
1450 * linux-x86-low.c: Update.
1451 * proc-service.c: Update.
1453 * spu-low.c: Update.
1454 * thread-db.c: Update.
1455 * win32-low.c: Update.
1457 2018-07-03 Tom Tromey <tom@tromey.com>
1459 * linux-low.c: Update.
1460 * lynx-low.c: Update.
1461 * nto-low.c: Update.
1462 * remote-utils.c: Update.
1463 * spu-low.c: Update.
1464 * thread-db.c: Update.
1465 * win32-low.c: Update.
1467 2018-06-29 Joel Brobecker <brobecker@adacore.com>
1469 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
1470 parameter in call to 'amd64_create_target_description'.
1472 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
1474 * x86-tdesc.h: Remove executable permission flag.
1476 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1478 * configure.ac: Remove AC_PREREQ, add missing quoting.
1479 * configure: Re-generate.
1480 * config.in: Re-generate.
1481 * aclocal.m4: Re-generate.
1483 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
1485 * tracepoint.h (current_traceframe): Remove declaration.
1487 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1489 * linux-aarch64-low.c (is_sve_tdesc): New function.
1490 (aarch64_sve_regs_copy_to_regcache): Likewise.
1491 (aarch64_sve_regs_copy_from_regcache): Likewise.
1492 (aarch64_regs_info): Add SVE checks.
1493 (initialize_low_arch): Initialize SVE.
1495 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1497 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
1499 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1501 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
1502 (initialize_low_tracepoint): Likewise
1503 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
1504 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
1506 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
1508 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
1510 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1512 * server.h (PBUFSIZ): Increase size
1514 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1516 * regcache.c (regcache::raw_compare): New function.
1517 * regcache.h (regcache::raw_compare): New declaration.
1519 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1521 * regcache.c (new_register_cache): Use new.
1522 (free_register_cache): Use delete.
1523 (register_data): Use const.
1524 (supply_register): Move body inside regcache.
1525 (regcache::raw_supply): New override function.
1526 (collect_register): Move body inside regcache.
1527 (regcache::raw_collect): New override function.
1528 (regcache::get_register_status): New override function.
1529 * regcache.h (struct regcache): Inherit from reg_buffer_common.
1531 2018-06-09 Tom Tromey <tom@tromey.com>
1533 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
1535 (event_queue): Use std::queue.
1536 (gdb_event_xfree): Remove.
1537 (initialize_event_loop, process_event, wait_for_event): Update.
1539 2018-06-08 Stan Cox <scox@redhat.com>
1541 * win32-low.c (win32_create_inferior): last_ptid and last_status
1542 moved to client_state.
1544 2018-06-08 Pedro Alves <palves@redhat.com>
1546 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
1547 common/common-exceptions.o, common/common-utils.o,
1548 common/errors.o, common/print-utils.o and utils.o.
1549 * gdbreplay.c: Include "common-defs.h" instead of the two
1550 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
1551 string.h or alloca.h.
1552 (perror_with_name): Delete.
1553 (remote_open): Use xstrdup instead of strdup.
1554 (main): Rename to ...
1555 (captured_main): ... this.
1558 2018-06-08 Tom Tromey <tom@tromey.com>
1560 * linux-low.c (linux_low_read_btrace): Update.
1562 2018-06-04 Stan Cox <scox@redhat.com>
1564 * server.h (struct client_state): New.
1565 * server.c (cont_thread, general_thread, multi_process)
1566 (report_fork_events, report_vfork_events, report_exec_events)
1567 (report_thread_events, swbreak_feature, hwbreak_feature)
1568 (vCont_supported, disable_randomization, pass_signals)
1569 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
1570 Moved to client_state.
1571 * remote-utils.c (remote_debug, noack_mode)
1572 (transport_is_reliable): Moved to client_state.
1573 * tracepoint.c (current_traceframe): Moved to client_state.
1576 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
1577 linux-low.c, remote-utils.h, target.c: Use client_state.
1579 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1581 * configure.srv: Add new c/h file.
1583 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1585 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1588 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1590 * gdb.arch/mips-fpregset-core.exp: New test.
1591 * gdb.arch/mips-fpregset-core.c: New test source.
1593 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1596 * hostio.c (require_int): Do not report overflow for integers
1597 between 0xfffffff and 0x7fffffff.
1599 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1601 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1602 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1603 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1605 (the_low_target): Wire them.
1607 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1609 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1610 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1611 mode. Call collect_register_by_name with vscr using
1612 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1613 (ppc_store_vrregset): Add and set vscr_offset variable as in
1614 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1617 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1619 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1620 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1621 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1623 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1625 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1626 (ppc_store_vsxregset): Likewise.
1627 (ppc_fill_vrregset): Likewise.
1628 (ppc_store_vrregset): Likewise.
1629 (ppc_fill_evrregset): Likewise.
1630 (ppc_store_evrregset): Likewise.
1631 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1632 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1635 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1637 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1638 wordsize of the inferior. Call ppc_linux_target_wordsize.
1640 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1642 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1643 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1644 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1645 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1646 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1647 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1648 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1649 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1650 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1651 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1652 (tdesc_powerpc_e500l): Remove.
1653 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1654 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1655 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1656 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1658 (ppc_arch_setup): Remove target description matching code. Fill a
1659 ppc_linux_features struct and call ppc_linux_match_description
1662 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1664 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1665 width of the requested register exceeds the width of the
1667 (mips_cannot_store_register): Likewise.
1669 2018-05-21 Maciej W. Rozycki <macro@mips.com>
1671 * linux-mips-low.c (mips_fetch_register): New function. Update
1673 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1674 (the_low_target): Wire `mips_fetch_register'.
1676 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1678 * lynx-i386-low.c (LYNXOS_178): New macro.
1679 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1680 the layout on LynxOS-178.
1681 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1682 handle floating point registers that are not supported by
1685 2018-05-10 Tom Tromey <tom@tromey.com>
1687 * configure: Rebuild.
1689 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1692 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1693 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1694 Use it to set the expedite_regs field in the given tdesc.
1695 * x86-tdesc.h: New file.
1696 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1697 Adjust following the addition of the new expedite_regs parameter
1698 to init_target_desc.
1699 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1700 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1701 (i386_linux_read_description, amd64_linux_read_description):
1702 Adjust following the addition of the new expedite_regs parameter
1703 to init_target_desc.
1704 * lynx-i386-low.c: #include "x86-tdesc.h".
1705 (lynx_i386_arch_setup): Adjust following the addition of the new
1706 expedite_regs parameter to init_target_desc.
1707 * nto-x86-low.c: #include "x86-tdesc.h".
1708 (nto_x86_arch_setup): Adjust following the addition of the new
1709 expedite_regs parameter to init_target_desc.
1710 * win32-i386-low.c: #include "x86-tdesc.h".
1711 (i386_arch_setup): Adjust following the addition of the new
1712 expedite_regs parameter to init_target_desc.
1714 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1717 * win32-low.c (win32_create_inferior): Add call to my_wait
1718 setting last_status global.
1720 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1723 * win32-low.c (create_process): Only call gdb_tilde_expand if
1724 inferior_cwd is not NULL.
1726 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1728 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1729 registers to the cache if their values have changed.
1730 (i387_xsave_to_cache): Provide default values for x87 control
1731 registers when these features are available, but disabled.
1732 * regcache.c (supply_register_by_name_zeroed): New function.
1733 * regcache.h (supply_register_by_name_zeroed): Declare new
1736 2018-05-07 Tom Tromey <tom@tromey.com>
1738 * configure: Rebuild.
1740 2018-05-04 Tom Tromey <tom@tromey.com>
1742 * configure: Rebuild.
1744 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1745 Pedro Alves <palves@redhat.com>
1747 * linux-aarch64-low.c (aarch64_stopped_data_address):
1750 2018-04-27 Tom Tromey <tom@tromey.com>
1752 * configure: Rebuild.
1754 2018-04-23 Tom Tromey <tom@tromey.com>
1756 * configure: Rebuild.
1758 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1760 * Makefile.in (depcomp): Add "..".
1761 (all_deps_files): New and use it.
1763 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1765 * configure.srv (aarch64*-*-linux*): Don't include xml.
1766 (i[34567]86-*-cygwin*): Likewise.
1767 (i[34567]86-*-linux*): Likewise.
1768 (i[34567]86-*-lynxos*): Likewise.
1769 (i[34567]86-*-mingw32ce*): Likewise.
1770 (i[34567]86-*-mingw*): Likewise.
1771 (i[34567]86-*-nto*): Likewise.
1772 (tic6x-*-uclinux): Likewise.
1773 (x86_64-*-linux*): Likewise.
1774 (x86_64-*-mingw*): Likewise.
1775 (x86_64-*-cygwin*): Likewise.
1777 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1779 * tdesc.c: Remove xml parameter.
1781 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1783 * server.c (get_features_xml): Remove cast.
1784 * tdesc.c (void target_desc::accept): Fill in function.
1785 (tdesc_get_features_xml): Remove old xml creation.
1786 (print_xml_feature::visit_pre): Add xml vistor.
1787 * tdesc.h (struct target_desc): Make xmltarget mutable.
1788 (tdesc_get_features_xml): Remove declaration.
1790 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1792 * tdesc.c (tdesc_architecture_name): Add new function.
1793 (tdesc_osabi_name): Likewise.
1794 (tdesc_get_features_xml): Use new functions.
1796 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1798 * tdesc.c (tdesc_create_flags): Remove.
1799 (tdesc_add_flag): Likewise.
1800 (tdesc_named_type): Likewise.
1801 (tdesc_create_union): Likewise.
1802 (tdesc_create_struct): Likewise.
1803 (tdesc_create_vector): Likewise.
1804 (tdesc_add_bitfield): Likewise.
1805 (tdesc_add_field): Likewise.
1806 (tdesc_set_struct_size): Likewise.
1808 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1810 * tdesc.c (~target_desc): Remove implictly deleted items.
1811 (init_target_desc): Iterate all features.
1812 (tdesc_get_features_xml): Use vector.
1813 (tdesc_create_feature): Create feature.
1814 * tdesc.h (tdesc_feature) Remove
1815 (target_desc): Add features.
1817 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1819 * Makefile.in: Add common/tdesc.c
1820 * tdesc.c (init_target_desc): init all reg_defs from register
1822 (tdesc_create_reg): Create tdesc_reg.
1823 * tdesc.h (tdesc_feature): Add register vector.
1825 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1827 * tdesc.h (struct target_desc) <features>: Change type to
1828 std::vector<std::string>.
1829 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1831 (tdesc_get_features_xml): Likewise.
1832 (tdesc_create_feature): Likewise.
1834 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1836 * regcache.c (find_register_by_number): Return a ref.
1837 (find_regno): Use references.
1838 (register_size): Likewise.
1839 (register_data): Likewise.
1840 * tdesc.c (target_desc::~target_desc): Remove free calls.
1841 (target_desc::operator==): Use std::vector compare.
1842 (init_target_desc): Use reference.
1843 (tdesc_create_reg): Use reg constructors.
1844 * tdesc.h (struct target_desc): Replace pointer with object.
1846 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1848 * regcache.c (find_register_by_number): Make static.
1849 (find_regno): Use find_register_by_number
1850 * regcache.h (struct reg): Remove declaration.
1852 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1854 * tdesc.c (target_desc::~target_desc): Move to here.
1855 (target_desc::operator==): Likewise.
1856 * tdesc.h (target_desc::~target_desc): Move from here.
1857 (target_desc::operator==): Likewise.
1859 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1861 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1863 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1865 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1867 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1868 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1869 and init_registers_s390_gs_linux64.
1871 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1873 * linux-s390-low.c (s390_fill_gs): Remove function.
1874 (s390_fill_gsbc): Remove function.
1875 (s390_regsets): Set fill functions for the guarded storage regsets
1878 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1880 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1881 the word size. Add comment.
1882 (s390_get_wordsize): New function.
1883 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1884 pswm with it. Instead, use s390_get_wordsize to determine the
1885 word size first and derive the correct tdesc from that directly.
1887 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1889 * Makefile.in: Include silent-rules.mk.
1890 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1891 (COMPILE): Add ECHO_CXX.
1892 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1893 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1894 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1895 (version-generated.c): Add ECHO_GEN.
1896 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1897 (IPAGENT_COMPILE): Add ECHO_CXX.
1898 (%-generated.c): Add ECHO_REGDAT.
1900 2018-03-14 Tom Tromey <tom@tromey.com>
1903 * ax.c (ax_printf): Special case for NULL.
1905 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1907 * linux-low.c (linux_qxfer_libraries_svr4): Use
1908 xml_escape_text_append.
1910 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1912 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1914 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1916 * server.c (handle_general_set): Remove unnecessary xstrdup.
1918 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1920 * server.c (parse_debug_format_options): Adjust to
1921 delim_string_to_char_ptr_vec changes.
1922 * thread-db.c (thread_db_load_search): Adjust to
1923 dirnames_to_char_ptr_vec changes.
1925 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1927 * target.h (target_enable_btrace, target_disable_btrace)
1928 (target_read_btrace, target_read_btrace_conf): Turn macro into
1929 inline function. Throw error if target method is not defined.
1930 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1931 check for btrace target method. Be prepared to handle exceptions
1932 from btrace target methods.
1934 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1936 * server.c (captured_main): Change order of error message printed
1937 when the current working directory cannot be found.
1939 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1941 * server.c: Include "filenames.h" and "pathstuff.h".
1942 (program_name): Delete variable.
1943 (program_path): New anonymous class.
1944 (get_exec_wrapper): Use "program_path" instead of
1946 (handle_v_run): Likewise.
1947 (captured_main): Likewise.
1948 (process_serial_event): Likewise.
1950 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1952 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1953 (OBJS): Add "pathstuff.o".
1954 * server.c (current_directory): New global variable.
1955 (captured_main): Initialize "current_directory".
1957 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1959 * tdesc.c: Use common/tdesc.h.
1960 * tdesc.h: Likewise.
1962 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1963 Simon Marchi <simon.marchi@ericsson.com>
1965 * Makefile.in: Switch order of make rules.
1967 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1969 * Makefile.in: Add common directory in build.
1970 * configure.ac: Add common reference.
1971 * configure: Regenerate.
1973 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1975 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1976 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1977 * spu-low.c (spu_target_ops): Likewise.
1978 * win32-low.c (win32_target_ops): Likewise.
1979 * server.c (supported_btrace_packets): Report packets unconditionally.
1980 * target.h (target_ops) <supports_btrace>: Remove.
1981 (target_supports_btrace): Remove.
1983 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1985 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1986 (handle_btrace_disable): Change return type to void. Use exceptions
1988 (handle_btrace_general_set): Catch exception and copy message to
1991 2018-02-08 Tom Tromey <tom@tromey.com>
1993 * linux-low.c (install_software_single_step_breakpoints): Use
1994 make_scoped_restore.
1995 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1996 (do_restore_current_thread_cleanup): Remove.
1997 * gdbthread.h (make_cleanup_restore_current_thread): Don't
2000 2018-02-08 Tom Tromey <tom@tromey.com>
2002 * mem-break.c (set_raw_breakpoint_at): Use
2003 gdb::unique_xmalloc_ptr.
2005 2018-01-30 Pedro Alves <palves@redhat.com>
2008 * target.c (target_terminal::terminal_state): Rename to ...
2009 (target_terminal::m_terminal_state): ... this.
2011 2018-01-19 James Clarke <jrtc27@jrtc27.com>
2013 * linux-low.c (handle_extended_wait): Surround call to
2014 thread_db_notice_clone with #ifdef USE_THREAD_DB.
2016 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
2018 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
2019 linux_ptrace_attach_fail_reason_string now returning an
2021 (linux_attach): Likewise.
2022 * thread-db.c (attach_thread): Likewise.
2024 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
2027 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
2028 checking for fs_base/gs_base fields in struct user_regs_struct.
2029 * configure: Regenerate.
2031 2018-01-16 Yao Qi <yao.qi@linaro.org>
2034 * linux-low.c (fetch_register): Call supply_register instead of
2037 2018-01-08 Yao Qi <yao.qi@linaro.org>
2038 Simon Marchi <simon.marchi@ericsson.com>
2040 * Makefile.in (OBS): Remove selftest.o.
2041 * configure.ac: Set srv_selftest_objs if $development is true.
2042 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
2043 * configure: Re-generated.
2044 * server.c (captured_main): Wrap variable selftest_filter with
2047 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
2049 * server.c (parse_debug_format_options): Return std::string.
2050 (handle_monitor_command, captured_main): Adjust.
2052 2018-01-05 Pedro Alves <palves@redhat.com>
2055 * server.c (captured_main): Pass quiet=false to
2056 save_original_signals_state.
2058 2018-01-01 Joel Brobecker <brobecker@adacore.com>
2060 * gdbreplay.c (gdbreplay_version): Update copyright year in
2062 * server.c (gdbserver_version): Likewise.
2064 2017-12-08 Tom Tromey <tom@tromey.com>
2066 * ax.c (ax_printf): Update.
2068 2017-12-07 Yao Qi <yao.qi@linaro.org>
2070 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
2071 aarch64_linux_read_description.
2072 * linux-amd64-ipa.c (idx2mask): New array.
2073 (get_ipa_tdesc): Move idx2mask out.
2074 (initialize_low_tracepoint): Initialize target descriptions.
2075 * linux-i386-ipa.c (idx2mask): New array.
2076 (get_ipa_tdesc): Move idx2mask out.
2077 (initialize_low_tracepoint): Initialize target descriptions.
2079 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
2081 * tdesc.c (struct tdesc_type): Change return type.
2082 (tdesc_add_flag): Change parameter type.
2083 (tdesc_add_bitfield): Likewise.
2084 (tdesc_add_field): Likewise.
2085 (tdesc_set_struct_size): Likewise.
2087 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
2089 * regcache.c (registers_to_string): Remove unused variable.
2091 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2093 * inferiors.c (for_each_inferior_with_data): Remove.
2094 * inferiors.h (for_each_inferior_with_data): Remove.
2095 * server.c (handle_qxfer_threads_worker): Change parameter type.
2096 (handle_qxfer_threads_proper): Use for_each_thread.
2098 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2100 * inferiors.c (for_each_inferior): Remove.
2101 (clear_inferiors): Use for_each_thread.
2102 * inferiors.h (for_each_inferior): Remove.
2103 * linux-low.c (linux_wait_for_event_filtered): Use
2105 (linux_stabilize_threads): Likewise.
2106 * regcache.c (regcache_release): Likewise.
2107 * server.c (gdb_wants_all_threads_stopped): Likewise.
2108 (clear_pending_status_callback): Remove.
2109 (handle_status): Use for_each_thread.
2110 (captured_main): Likewise.
2111 * win32-low.c (child_init_thread_list): Likewise.
2112 (win32_clear_inferiors): Likewise.
2113 (fake_breakpoint_event): Likewise.
2115 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2117 * inferiors.h (find_inferior): Remove.
2118 * inferiors.c (find_inferior): Remove.
2120 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2122 * linux-low.c (resume_status_pending_p): Update comment.
2123 (need_step_over_p): Update comment.
2125 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2127 * linux-low.c (proceed_one_lwp): Return void, change parameter
2129 (unsuspend_and_proceed_one_lwp): Likewise.
2130 (proceed_all_lwps): Use for_each_thread.
2131 (unstop_all_lwps): Likewise.
2133 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2135 * linux-low.c (linux_resume_one_thread): Return void, take
2137 (linux_resume): Use for_each_thread.
2139 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2141 * linux-low.c (send_sigstop_callback): Return void, change
2142 parameter type. Rename to...
2143 (send_sigstop): ... this.
2144 (suspend_and_send_sigstop_callback): Return void, change parameter
2146 (suspend_and_send_sigstop): ... this.
2147 (stop_all_lwps): Use for_each_thread.
2149 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2151 * linux-low.c (lwp_running): Return bool, remove unused
2153 (linux_stabilize_threads): Use find_thread.
2155 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2157 * linux-low.c (select_singlestep_lwp_callback): Remove.
2158 (count_events_callback): Remove.
2159 (select_event_lwp_callback): Remove.
2160 (select_event_lwp): Use find_thread/for_each_thread.
2162 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2164 * linux-low.c (not_stopped_callback): Return bool, take filter
2166 (linux_wait_for_event_filtered): Use find_thread.
2167 (linux_wait_1): Likewise.
2169 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2171 * linux-low.c (same_lwp): Remove.
2172 (find_lwp_pid): Use find_thread.
2174 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2176 * linux-low.c (delete_lwp_callback): Remove.
2177 (linux_mourn): Use for_each_thread.
2179 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2181 * linux-low.c (linux_detach_lwp_callback): Return void, remove
2182 args parameter, don't check for pid.
2183 (linux_detach): Use for_each_thread.
2185 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2187 * linux-low.c (struct counter): Remove.
2188 (second_thread_of_pid_p): Remove.
2189 (last_thread_of_process_p): Use find_thread.
2191 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2193 * inferiors.c (find_inferior_in_random): Remove.
2194 * inferiors.h (find_inferior_in_random): Remove.
2195 * linux-low.c (status_pending_p_callback): Return bool, accept
2196 parameter ptid directly.
2197 (linux_wait_for_event_filtered): Use find_thread_in_random.
2198 (linux_wait_1): Likewise.
2200 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2202 * inferiors.c (find_inferior_id): Remove.
2203 (find_thread_ptid): Move implemention from find_inferior_id to
2205 * inferiors.h (find_inferior_id): Remove.
2206 * server.c (handle_status): Use find_thread_ptid.
2207 (process_serial_event): Likewise.
2208 * thread-db.c (find_one_thread): Likewise.
2209 (thread_db_thread_handle): Likewise.
2210 * win32-low.c (thread_rec): Likewise.
2211 (child_delete_thread): Likewise.
2212 (win32_thread_alive): Likewise.
2213 (get_child_debug_event): Likewise.
2215 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2217 * linux-mips-low.c (update_watch_registers_callback): Return
2218 void, remove pid_p parameter, don't check for pid.
2219 (mips_insert_point, mips_remove_point): Use for_each_thread.
2221 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2223 * lynx.low (lynx_delete_thread_callback): Remove.
2224 (lynx_mourn): Use for_each_thread.
2226 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
2228 * regcache.c (regcache_invalidate_one): Remove.
2229 (regcache_invalidate_pid): use for_each_thread.
2231 2017-11-26 Tom Tromey <tom@tromey.com>
2233 * linux-low.c (linux_create_inferior): Update.
2235 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
2237 * spu-low.c (spu_create_inferior): Fix typo in argument name.
2239 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2241 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
2242 * linux-aarch64-low.c (initialize_low_arch): Call init func.
2243 * linux-aarch64-tdesc-selftest.c: New file.
2244 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
2246 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2248 * configure.srv: Add new file.
2249 * linux-aarch64-low.c (initialize_low_arch): Call init func.
2250 * linux-aarch64-tdesc-selftest.c: New file.
2251 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
2253 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2255 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
2256 * linux-aarch64-low.c (initialize_low_arch): Remove init.
2257 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
2259 2017-11-24 Alan Hayward <alan.hayward@arm.com>
2261 * configure.srv: Add new files.
2262 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
2263 aarch64_linux_read_description.
2264 * linux-aarch64-low.c (aarch64_linux_read_description):
2265 Merge with aarch64_arch_setup.
2266 (aarch64_arch_setup): Call aarch64_linux_read_description.
2267 * linux-aarch64-tdesc.c: New file.
2268 * linux-aarch64-tdesc.h: New file.
2270 2017-11-24 Yao Qi <yao.qi@linaro.org>
2272 * configure.srv: Set $srv_regobj for tic6x-linux.
2273 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
2274 (tic6x_read_description): Move some code to tic6x_arch_setup.
2275 (tic6x_tdesc_test): New function.
2276 (initialize_low_arch): Call selftests::register_test.
2278 2017-11-22 Yao Qi <yao.qi@linaro.org>
2280 * remote-utils.c (prepare_resume_reply): Use memcpy.
2282 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2284 * linux-low.c (kill_one_lwp_callback): Return void, take
2285 argument directly, don't filter on pid.
2286 (linux_kill): Use for_each_thread.
2288 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2290 * linux-low.c (need_step_over_p): Return bool, remove dummy
2292 (linux_resume, proceed_all_lwps): Use find_thread.
2294 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2296 * linux-low.c (resume_status_pending_p): Return bool, remove
2298 (linux_resume): Use find_thread.
2300 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2302 * linux-low.c (struct thread_resume_array): Remove.
2303 (linux_set_resume_request): Return void, take arguments
2305 (linux_resume): Use for_each_thread.
2307 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2309 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
2310 return bool, remove data argument.
2311 (linux_stabilize_threads): Use find_thread.
2313 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2315 * linux-low.c (unsuspend_one_lwp): Remove.
2316 (unsuspend_all_lwps): Use for_each_thread, inline code from
2319 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2321 * gdbthread.h (find_thread): Add overload with ptid_t filter.
2322 * linux-low.c (struct iterate_over_lwps_args): Remove.
2323 (iterate_over_lwps_filter): Remove.
2324 (iterate_over_lwps): Use find_thread.
2326 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2328 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
2329 (linux_handle_new_gdb_connection): Use for_each_thread, inline
2330 code from reset_lwp_ptrace_options_callback.
2332 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2334 * linux-arm-low.c (struct update_registers_data): Remove.
2335 (update_registers_callback): Return void, take arguments
2336 directly, don't check thread's pid.
2337 (arm_insert_point, arm_remove_point): Use for_each_thread.
2339 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2341 * win32-low.c (continue_one_thread): Return void, take argument
2343 (child_continue): Use for_each_thread.
2345 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2347 * win32-i386-low.c (update_debug_registers_callback): Rename
2349 (update_debug_registers): ... this, return void, remove pid_p arg.
2350 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
2352 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2354 * inferiors.h (struct process_info): Add constructor, initialize
2356 <syscalls_to_catch>: Change type to std::vector<int>.
2357 * inferiors.c (add_process): Allocate process_info with new.
2358 (remove_process): Free process_info with delete.
2359 * linux-low.c (handle_extended_wait): Adjust.
2360 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
2361 * server.c (handle_general_set): Adjust.
2363 2017-11-16 Pedro Alves <palves@redhat.com>
2365 * remote-utils.c (remote_close): Block SIGIO signals instead of
2366 uninstalling the SIGIO handler.
2368 2017-11-16 Alan Hayward <alan.hayward@arm.com>
2370 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
2372 2017-11-16 Yao Qi <yao.qi@linaro.org>
2374 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
2375 (tic6x_store_gregset): Likewise.
2376 (tic6x_usrregs_info): Move it up.
2378 2017-11-15 Alan Hayward <alan.hayward@arm.com>
2380 * Makefile.in: Update arch rules.
2381 * configure.srv: Explicitly mark arch/ files.
2383 2017-11-13 Andreas Schwab <schwab@suse.de>
2385 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
2387 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2389 2017-11-06 Pedro Alves <palves@redhat.com>
2391 * config.in, configure: Regenerate.
2393 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2395 * target.c (struct thread_search): Remove.
2396 (thread_search_callback): Remove.
2397 (prepare_to_access_memory): Use for_each_thread instead of
2398 find_inferior. Inline code from thread_search_callback.
2400 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2402 * server.c (struct visit_actioned_threads_data): Remove.
2403 (visit_actioned_threads): Change prototype to take arguments
2405 (resume): Use find_thread instead of find_inferior.
2407 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2409 * server.c (queue_stop_reply_callback): Change prototype, return
2411 (find_status_pending_thread_callback): Remove.
2412 (handle_status): Replace find_inferior with find_thread and
2415 2017-10-25 Alan Hayward <alan.hayward@arm.com>
2417 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
2419 (aarch64_store_gregset): Likewise.
2420 (aarch64_fill_fpregset): Likewise.
2421 (aarch64_store_fpregset): Likewise.
2423 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2425 * gdbthread.h (find_thread, for_each_thread): New functions.
2426 * inferiors.c (thread_of_pid): Remove.
2427 (find_any_thread_of_pid): Use find_thread.
2428 * linux-low.c (num_lwps): Use for_each_thread.
2430 2017-10-17 Yao Qi <yao.qi@linaro.org>
2432 * Makefile.in: Remove one rule.
2433 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
2435 2017-10-17 Yao Qi <yao.qi@linaro.org>
2437 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
2438 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
2440 2017-10-17 Yao Qi <yao.qi@linaro.org>
2442 * configure.srv: Rename arm.o with arch/arm.o.
2444 2017-10-17 Yao Qi <yao.qi@linaro.org>
2446 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
2447 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
2448 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
2449 (arch-i386.o, arch-amd64.o): Remove rules.
2450 (arch/%.o): New rule.
2451 Update POSTCOMPILE and COMPILE.pre.
2452 * configure.ac: Invoke AC_CONFIG_COMMANDS.
2453 * configure: Re-generated.
2454 * configure.srv: Replace arch-i386.o with arch/i386.o.
2455 Replace arch-amd64.o with arch/amd64.o.
2457 2017-10-16 Yao Qi <yao.qi@linaro.org>
2459 * configure: Regenerated.
2461 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2463 * inferiors.h: (struct inferior_list): Remove.
2464 (struct inferior_list_entry); Remove.
2465 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
2466 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
2467 get_first_inferior): Remove.
2468 (for_each_inferior, for_each_inferior_with_data, find_inferior,
2469 find_inferior_id, find_inferior_in_random): Change signature.
2470 * inferiors.c (all_threads): Change type to
2471 std::list<thread_info *>.
2472 (get_thread): Remove macro.
2473 (find_inferior, find_inferior_id): Change signature, implement
2475 (find_inferior_in_random): Change signature, implement using
2476 find_thread_in_random.
2477 (for_each_inferior, for_each_inferior_with_data): Change
2478 signature, implement using for_each_thread.
2479 (add_inferior_to_list, remove_inferior): Remove.
2480 (add_thread, get_first_thread, thread_of_pid,
2481 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
2482 (get_first_inferior, one_inferior_p, clear_inferior_list):
2484 (clear_inferiors, get_thread_process): Update.
2485 * gdbthread.h: Include <list>.
2486 (struct thread_info) <entry>: Remove field.
2488 (all_threads): Change type to std::list<thread_info *>.
2489 (get_first_inferior): Add doc.
2490 (find_thread, for_each_thread, find_thread_in_random): New
2492 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
2493 * linux-arm-low.c (update_registers_callback): Update.
2494 * linux-low.c (second_thread_of_pid_p): Update.
2495 (kill_one_lwp_callback, linux_detach_lwp_callback,
2496 delete_lwp_callback, status_pending_p_callback, same_lwp,
2497 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
2498 iterate_over_lwps, not_stopped_callback,
2499 resume_stopped_resumed_lwps, count_events_callback,
2500 select_singlestep_lwp_callback, select_event_lwp_callback,
2501 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
2502 suspend_and_send_sigstop_callback, wait_for_sigstop,
2503 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
2504 lwp_running, linux_set_resume_request, resume_status_pending_p,
2505 need_step_over_p, start_step_over, linux_resume_one_thread,
2506 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
2507 reset_lwp_ptrace_options_callback): Update.
2508 * linux-mips-low.c (update_watch_registers_callback): Update.
2509 * regcache.c (regcache_invalidate_one, regcache_invalidate):
2511 (free_register_cache_thread_one): Remove.
2512 (regcache_release): Update.
2513 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
2514 handle_qxfer_threads_worker): Update.
2515 (handle_query): Update, use list iterator.
2516 (visit_actioned_threads, handle_pending_status,
2517 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
2518 clear_pending_status_callback, set_pending_status_callback,
2519 find_status_pending_thread_callback, handle_status,
2520 process_serial_event): Update.
2521 * target.c (thread_search_callback): Update.
2522 * thread-db.c (thread_db_get_tls_address): Update.
2523 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
2525 * win32-i386-low.c (update_debug_registers_callback): Update.
2526 * win32-low.c (delete_thread_info, child_delete_thread,
2527 continue_one_thread, suspend_one_thread,
2528 get_child_debug_event): Adjust.
2530 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2532 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
2533 * inferiors.h: Include <list>.
2534 (struct process_info) <entry>: Remove field.
2536 (pid_of): Change macro to function.
2537 (ptid_of, lwpid_of): Remove macro.
2538 (all_processes): Change type to std::list<process_info *>.
2539 (ALL_PROCESSES): Remove macro.
2540 (for_each_process, find_process): New function.
2541 * inferiors.c (all_processes): Change type to
2542 std::list<process_info *>.
2543 (find_thread_process): Adjust.
2544 (add_process): Likewise.
2545 (remove_process): Likewise.
2546 (find_process_pid): Likewise.
2547 (get_first_process): Likewise.
2548 (started_inferior_callback): Remove.
2549 (have_started_inferiors_p): Adjust.
2550 (attached_inferior_callback): Remove.
2551 (have_attached_inferiors_p): Adjust.
2552 * linux-low.c (check_zombie_leaders): Likewise.
2553 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
2554 (x86_linux_update_xmltarget): Adjust.
2555 * server.c (handle_query): Likewise.
2556 (gdb_reattached_process): Remove.
2557 (handle_status): Adjust.
2558 (kill_inferior_callback): Likewise.
2559 (detach_or_kill_inferior): Remove.
2560 (print_started_pid): Likewise.
2561 (print_attached_pid): Likewise.
2562 (detach_or_kill_for_exit): Update.
2563 (process_serial_event): Likewise.
2564 * linux-arm-low.c (arm_new_fork): Likewise.
2566 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2568 * dll.h: Include <list>.
2569 (struct dll_info): Add constructor.
2570 <entry>: Remove field.
2571 (all_dlls): Change type to std::list<dll_info>.
2572 * dll.c: Include <algorithm>.
2573 (get_dll): Remove macro.
2574 (all_dlls): Change type to std::list<dll_info *>.
2575 (free_one_dll): Remove.
2576 (match_dll): Likewise.
2577 (loaded_dll): Adjust.
2578 (unloaded_dll): Adjust to all_dlls type change, use
2579 std::find_if. Inline code from match_dll.
2580 (clear_dlls): Adjust to all_dlls type change.
2581 * server.c (emit_dll_description): Remove.
2582 (handle_qxfer_libraries): Adjust to all_dlls type change,
2583 integrate emit_dll_description's functionality.
2585 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2587 * linux-low.h (struct linux_target_ops) <delete_process>: New
2589 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2590 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2591 (struct linux_target_ops): Add delete_process callback.
2592 * linux-arm-low.c (arm_delete_process): New.
2593 (struct linux_target_ops): Add delete_process callback.
2594 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2595 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2596 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2597 * linux-mips-low.c (mips_linux_delete_process): New.
2598 (struct linux_target_ops): Add delete_process callback.
2599 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2600 * linux-s390-low.c (struct linux_target_ops): Likewise.
2601 * linux-sh-low.c (struct linux_target_ops): Likewise.
2602 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2603 * linux-tile-low.c (struct linux_target_ops): Likewise.
2604 * linux-x86-low.c (x86_linux_delete_process): New.
2605 (struct linux_target_ops): Add delete_process callback.
2606 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2608 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2610 * linux-aarch64-low.c (the_low_target): Add thread delete
2612 * linux-arm-low.c (arm_delete_thread): New function.
2613 (the_low_target): Add thread delete callback.
2614 * linux-bfin-low.c (the_low_target): Likewise.
2615 * linux-crisv32-low.c (the_low_target): Likewise.
2616 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2618 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2620 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2621 * linux-mips-low.c (mips_linux_delete_thread): New function.
2622 (the_low_target): Add thread delete callback.
2623 * linux-ppc-low.c (the_low_target): Likewise.
2624 * linux-s390-low.c (the_low_target): Likewise.
2625 * linux-sh-low.c (the_low_target): Likewise.
2626 * linux-tic6x-low.c (the_low_target): Likewise.
2627 * linux-tile-low.c (the_low_target): Likewise.
2628 * linux-x86-low.c (the_low_target): Likewise.
2629 * linux-xtensa-low.c (the_low_target): Likewise.
2631 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2633 * win32-low.c: Include "common-inferior.h".
2635 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2637 * inferiors.c (set_inferior_cwd): New function.
2638 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2639 (handle_query): Inform that QSetWorkingDir is supported.
2640 * win32-low.c (create_process): Pass the inferior's cwd to
2643 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2645 * inferiors.c (current_inferior_cwd): New global variable.
2646 (get_inferior_cwd): New function.
2647 * inferiors.h (struct process_info) <cwd>: New field.
2649 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2651 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2652 (OBS): Add gdb_tilde_expand.o.
2654 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2656 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2657 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2659 2017-09-29 Pedro Alves <palves@redhat.com>
2661 * ax.c (gdb_parse_agent_expr): Constify.
2662 * ax.h (gdb_parse_agent_expr): Constify.
2663 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2665 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2666 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2667 * remote-utils.h (read_ptid): Constify.
2668 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2669 (process_point_options, process_serial_event): Constify.
2670 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2671 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2672 (cmd_qtbuffer): Constify.
2674 2017-09-29 Pedro Alves <palves@redhat.com>
2676 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2679 2017-09-29 Pedro Alves <palves@redhat.com>
2681 * linux-low.c (handle_extended_wait): Pass parent thread instead
2682 of process to thread_db_notice_clone.
2683 * linux-low.h (thread_db_notice_clone): Replace parent process
2684 parameter with parent thread parameter.
2685 * thread-db.c (find_one_thread): Add comment.
2686 (thread_db_notice_clone): Replace parent process parameter with
2687 parent thread parameter. Temporarily switch to the parent thread.
2689 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2691 * gdbthread.h: Include "common-gdbthread.h".
2692 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2693 "if" when validating the ptid.
2694 * remote-utils.c: Include "gdbthread.h".
2695 (prepare_resume_reply): Use "switch_to_thread".
2696 * target.c (done_accessing_memory): Likewise.
2698 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2700 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2701 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2702 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2703 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2704 s390x-gs-linux64-ipa.o to ipa_obj.
2705 * linux-s390-low.c (HWCAP_S390_GS): New define.
2706 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2708 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2709 (s390_arch_setup): Check for guarded-storage support and choose
2711 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2712 init_registers_s390x_gs_linux64.
2713 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2715 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2716 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2718 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2720 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2722 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2724 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2725 (thread_db_thread_handle): Declare.
2726 * linux-low.c (linux_target_ops): Initialize thread_handle.
2727 * server.c (handle_qxfer_threads_worker): Add support for
2729 * target.h (struct target_ops): Add new function pointer,
2731 (target_thread_handle): Define.
2732 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2734 (thread_db_thread_handle): New function.
2736 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2738 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2739 * linux-low.h (thread_db_notice_clone): Declare.
2740 * thread-db.c (thread_db_notice_clone): New function.
2742 2017-09-21 Pedro Alves <palves@redhat.com>
2744 * server.c (gdb_read_memory, handle_status, process_serial_event)
2745 (handle_serial_event, handle_target_event): Adjust to
2746 set_desired_thread prototype change.
2747 * target.c (set_desired_thread): Remove 'use_general' parameter
2749 * target.h (set_desired_thread): Remove 'use_general' parameter.
2751 2017-09-20 Tom Tromey <tom@tromey.com>
2753 * target.c (target_terminal::terminal_state): Define.
2754 (target_terminal::init): Rename from target_terminal_init.
2755 (target_terminal::inferior): Rename from
2756 target_terminal_inferior.
2757 (target_terminal::ours): Rename from target_terminal_ours.
2758 (target_terminal::ours_for_output, target_terminal::info): New.
2760 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2762 * server.c (accumulate_file_name_length): Remove.
2763 (emit_dll_description): Adjust to std::string change.
2764 (handle_qxfer_libraries): Use std::string to hold document.
2766 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2768 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2769 return type of xml_escape_text.
2770 * server.c (emit_dll_description): Likewise.
2772 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2774 * server.c (captured_main): Accept argument for --selftest.
2775 Update run_tests call.
2776 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2777 when registering selftests.
2779 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2781 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2782 instead of "VEC" for "target_desc.reg_defs".
2783 (regcache_cpy): Likewise.
2784 (registers_to_string): Likewise.
2785 (registers_from_string): Likewise.
2786 (find_regno): Likewise.
2787 (supply_regblock): Likewise.
2788 (regcache_raw_read_unsigned): Likewise.
2789 * tdesc.c (init_target_desc): Likewise.
2790 (tdesc_create_reg): Likewise.
2791 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2792 (struct target_desc) <reg_defs>: Convert to "std::vector".
2793 (target_desc): Do not initialize "reg_defs".
2794 (~target_desc): Update code to use "std::vector" instead of "VEC"
2795 for "target_desc.reg_defs".
2796 (operator==): Likewise.
2798 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2800 * inferiors.h (thread_to_gdb_id): Remove.
2801 * inferiors.c (thread_to_gdb_id): Remove.
2802 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2803 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2804 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2806 * nto-low.c (nto_fetch_registers, nto_store_registers,
2807 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2809 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2811 * inferiors.h (gdb_id_to_thread_id): Remove.
2812 * inferiors.c (gdb_id_to_thread_id): Remove.
2813 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2814 removal. Move pid declaration closer to where it's used.
2816 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2818 * server.c (handle_detach): New function.
2819 (process_serial_event): Move code out, call handle_detach.
2821 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2823 * server.c (require_running): Rename to ...
2824 (require_running_or_return): ... this ...
2825 (require_running_or_break): ... and this.
2826 (handle_query, process_serial_event): Adjust.
2828 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2830 * linux-low.c (linux_set_resume_request): Remove unused
2833 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2835 * server.c (first_thread_of): Remove.
2836 (process_serial_event): Replace usage of first_thread_of with
2837 find_any_thread_of_pid.
2838 * tracepoint.c (same_process_p): Remove.
2839 (gdb_agent_about_to_close): Replace usage of same_process_p with
2840 find_any_thread_of_pid.
2841 * linux-x86-low.c (same_process_callback): Remove.
2842 (x86_arch_setup_process_callback): Replace usage of
2843 same_process_callback with find_any_thread_of_pid.
2844 * thread-db.c (any_thread_of): Remove.
2845 (switch_to_process): Replace usage of any_thread_of with
2846 find_any_thread_of_pid.
2847 * inferiors.c (thread_pid_matches_callback): Remove.
2848 (find_thread_process): Adjust to use find_any_thread_of_pid.
2850 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2852 * regcache.c (get_thread_regcache): Guard calls to "memset"
2855 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2857 * linux-low.c (handle_extended_wait): Use
2858 "allocate_target_description" instead of "XNEW".
2859 * linux-x86-low.c (initialize_low_arch): Likewise.
2861 2017-09-05 Yao Qi <yao.qi@linaro.org>
2863 * configure.srv (srv_i386_regobj): Remove.
2864 (srv_amd64_regobj): Remove.
2865 (srv_regobj): Set it to "" for x86 non-linux targets.
2866 * linux-x86-tdesc.c (i386_linux_read_description):
2867 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2868 (init_registers_i386): Remove the declaration.
2869 (tdesc_i386): Remove the declaration.
2870 (lynx_i386_arch_setup): Call i386_create_target_description.
2871 * nto-x86-low.c: Likewise.
2872 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2873 [!__x86_64__]: include arch/i386.h.
2874 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2876 2017-09-05 Yao Qi <yao.qi@linaro.org>
2878 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2879 i386/amd64-XXX-linux from it.
2881 2017-09-05 Yao Qi <yao.qi@linaro.org>
2883 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2885 (ipa_amd64_linux_regobj): Remove.
2886 (ipa_x32_linux_regobj): Remove.
2888 2017-09-05 Yao Qi <yao.qi@linaro.org>
2890 * Makefile.in (arch-amd64.o): New rule.
2891 * configure.srv: Append arch-amd64.o.
2892 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2893 (get_ipa_tdesc): Call amd64_linux_read_description.
2894 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2895 and init_registers_amd64_XXX.
2896 * linux-x86-low.c (x86_linux_read_description): Call
2897 amd64_linux_read_description.
2898 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2899 (initialize_low_arch): Don't call init_registers_x32_XXX and
2900 init_registers_amd64_XXX.
2901 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2902 and tdesc_amd64_XXX.
2903 [__x86_64__] (amd64_tdesc_test): New function.
2904 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2905 and init_registers_amd64_XXX.
2906 * linux-x86-tdesc.c: Include arch/amd64.h.
2907 (xcr0_to_tdesc_idx): New function.
2908 (i386_linux_read_description): New function.
2909 (amd64_get_ipa_tdesc_idx): New function.
2910 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2911 (amd64_get_ipa_tdesc): Declare.
2913 2017-09-05 Yao Qi <yao.qi@linaro.org>
2915 * configure.srv (srv_i386_linux_xmlfiles): Remove
2916 i386/i386-XXX-linux.xml from it.
2918 2017-09-05 Yao Qi <yao.qi@linaro.org>
2920 * configure.srv: Set srv_i386_linux_regobj empty if $development
2922 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2923 initialize_low_tdesc.
2924 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2925 with #if initialize_low_tdesc.
2926 * linux-x86-tdesc-selftest.c: New file.
2927 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2929 2017-09-05 Yao Qi <yao.qi@linaro.org>
2931 * Makefile.in (arch-i386.o): New rule.
2932 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2933 (x86_64-*-linux*): Likewise.
2934 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2935 include arch/i386.h.
2936 (i386_linux_read_description): Remove code and call
2937 i386_create_target_description.
2938 * tdesc.c (allocate_target_description): New function.
2939 * tdesc.h (set_tdesc_architecture): Remove declaration.
2940 (set_tdesc_osabi): Likewise.
2942 2017-09-05 Yao Qi <yao.qi@linaro.org>
2944 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2945 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2946 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2948 * server.c (get_features_xml): Call tdesc_get_features_xml.
2949 * tdesc.c (set_tdesc_architecture): New function.
2950 (set_tdesc_osabi): New function.
2951 (tdesc_get_features_xml): New function.
2952 (tdesc_create_feature): Add an argument.
2953 * tdesc.h (struct target_desc) <features>: New field.
2954 <arch, osabi>: New field.
2955 (~target_desc): xfree features, arch, and osabi.
2956 (target_desc::oerator==): Don't compare .xmltarget.
2957 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2958 (set_tdesc_osabi): Likewise.
2959 (tdesc_get_features_xml): Likewise.
2961 2017-09-05 Yao Qi <yao.qi@linaro.org>
2963 * linux-x86-tdesc.c: Include selftest.h.
2964 (i386_tdesc_test): New function.
2965 (initialize_low_tdesc): Call selftests::register_test.
2966 * tdesc.h: Include regdef.h.
2967 (target_desc): Override operator == and !=.
2969 2017-09-05 Yao Qi <yao.qi@linaro.org>
2971 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2972 (ipa_obj): Likewise.
2973 * linux-i386-ipa.c: Include common/x86-xstate.h
2974 (get_ipa_tdesc): Call i386_linux_read_description.
2975 (initialize_low_tracepoint): Don't call init_registers_XXX
2976 functions, call initialize_low_tdesc instead.
2977 * linux-x86-low.c (x86_linux_read_description): Call
2978 i386_linux_read_description.
2979 (initialize_low_arch): Don't call init_registers_i386_XXX
2980 functions, call initialize_low_tdesc.
2981 * linux-x86-tdesc.c: New file.
2982 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2983 (i386_get_ipa_tdesc_idx): Declare.
2984 (i386_get_ipa_tdesc): Declare.
2985 (initialize_low_tdesc): Declare.
2987 2017-09-05 Yao Qi <yao.qi@linaro.org>
2989 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2992 2017-09-05 Yao Qi <yao.qi@linaro.org>
2994 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2995 * regcache.c (get_thread_regcache): Use VEC_length.
2996 (init_register_cache): Likewise.
2997 (regcache_cpy): Likewise.
2998 (registers_to_string): Iterate reg_defs via VEC_iterate.
2999 (find_regno): Likewise.
3000 (find_register_by_number): Use VEC_index.
3001 (register_size): Call find_register_by_number.
3002 (register_data): Call find_register_by_number.
3003 (supply_regblock): Use VEC_length.
3004 (regcache_raw_read_unsigned): Likewise.
3005 * tdesc.c (init_target_desc): Iterate reg_defs via
3007 (default_description): Update initializer.
3008 (copy_target_description): Don't update field num_registers.
3009 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
3010 <num_registers>: Remove.
3012 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
3014 * Makefile.in (.SECONDARY): Define target.
3016 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
3018 * linux-low.c (linux_wait_1): Adjust.
3019 * server.c (queue_stop_reply_callback): Adjust.
3021 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
3023 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
3024 QEnvironmentUnset and QEnvironmentReset packets.
3025 (handle_query): Inform remote that QEnvironmentHexEncoded,
3026 QEnvironmentUnset and QEnvironmentReset are supported.
3028 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
3030 * inferiors.h (inferior_target_data): Rename to ...
3031 (thread_target_data): ... this.
3032 (inferior_regcache_data): Rename to ...
3033 (thread_regcache_data): ... this.
3034 (set_inferior_regcache_data): Rename to ...
3035 (set_thread_regcache_data): ... this.
3036 * inferiors.c (inferior_target_data): Rename to ...
3037 (thread_target_data): ... this.
3038 (inferior_regcache_data): Rename to ...
3039 (thread_regcache_data): ... this.
3040 (set_inferior_regcache_data): Rename to ...
3041 (set_thread_regcache_data): ... this.
3042 (free_one_thread): Update.
3043 * linux-low.h (get_thread_lwp): Update.
3044 * regcache.c (get_thread_regcache): Update.
3045 (regcache_invalidate_thread): Update.
3046 (free_register_cache_thread): Update.
3047 * win32-i386-low.c (update_debug_registers_callback): Update.
3048 (win32_get_current_dr): Update.
3049 * win32-low.c (thread_rec): Update.
3050 (delete_thread_info): Update.
3051 (continue_one_thread): Update.
3052 (suspend_one_thread): Update.
3054 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
3056 * inferiors.c (set_inferior_target_data): Remove.
3057 * inferiors.h (set_inferior_target_data): Remove.
3059 2017-08-18 Yao Qi <yao.qi@linaro.org>
3061 * Makefile.in (OBS): Add selftest.o.
3062 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
3063 * configure, config.in: Re-generated.
3064 * server.c: Include common/sefltest.h.
3065 (captured_main): Handle option --selftest.
3067 2017-08-09 Yao Qi <yao.qi@linaro.org>
3069 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
3070 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
3071 i386-avx-mpx.o and i386-mmx.o.
3072 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
3073 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
3074 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
3075 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
3076 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
3077 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
3078 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
3079 i386/amd64-avx-mpx.xml.
3081 2017-08-09 Yao Qi <yao.qi@linaro.org>
3083 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
3084 and x32-avx-avx512.o.
3085 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
3086 i386/x32-avx-avx512.xml.
3088 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
3090 * tracepoint.h (enum class fast_tpoint_collect_result): New
3092 (fast_tracepoint_collecting): Change return type to
3093 fast_tpoint_collect_result.
3094 * tracepoint.c (fast_tracepoint_collecting): Likewise.
3095 * linux-low.h: Include tracepoint.h.
3096 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
3097 fast_tpoint_collect_result.
3098 * linux-low.c (handle_tracepoints): Adjust.
3099 (linux_fast_tracepoint_collecting): Change return type to
3100 fast_tpoint_collect_result.
3101 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
3102 linux_wait_1, stuck_in_jump_pad_callback,
3103 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
3104 proceed_one_lwp): Adjust to type change.
3106 2017-07-10 Yao Qi <yao.qi@linaro.org>
3108 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
3110 2017-06-29 Yao Qi <yao.qi@linaro.org>
3112 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
3114 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
3116 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
3118 * Makefile.in (IPA_OBJS): Sort and format one item per line.
3120 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
3122 * linux-low.c (linux_create_inferior): Adjust code to access the
3123 environment information via 'gdb_environ' class.
3124 * lynx-low.c (lynx_create_inferior): Likewise.
3125 * server.c (our_environ): Make it an instance of 'gdb_environ'.
3126 (get_environ): Return a pointer to 'our_environ'.
3127 (captured_main): Initialize 'our_environ'.
3128 * server.h (get_environ): Adjust prototype.
3129 * spu-low.c (spu_create_inferior): Adjust code to access the
3130 environment information via 'gdb_environ' class.
3132 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3134 * linux-low.c (linux_read_memory, linux_write_memory): Remove
3135 usage of "register" keyword.
3137 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3139 * configure: Re-generate.
3141 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3143 * configure: Re-generate.
3145 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
3147 * Makefile.in (COMPILE.pre): Add "-x c++".
3149 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
3151 * fork-child.c: Conditionally include <signal.h>.
3153 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3155 * server.c (handle_general_set): Handle new packet
3156 "QStartupWithShell".
3157 (handle_query): Add "QStartupWithShell" to the list of supported
3159 (gdbserver_usage): Add help text explaining the
3160 new "--startup-with-shell" and "--no-startup-with-shell" CLI
3162 (captured_main): Recognize and act upon the presence of the new
3165 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3166 Pedro Alves <palves@redhat.com>
3168 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
3169 * configure: Regenerate.
3170 * configure.srv (srv_linux_obj): Add "fork-child.o" and
3172 (i[34567]86-*-lynxos*): Likewise.
3173 (spu*-*-*): Likewise.
3174 * fork-child.c: New file.
3175 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
3177 (linux_ptrace_fun): New function.
3178 (linux_create_inferior): Adjust function prototype to reflect
3179 change on "target.h". Adjust function code to use
3181 (linux_request_interrupt): Delete "signal_pid".
3182 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
3183 (lynx_ptrace_fun): New function.
3184 (lynx_create_inferior): Adjust function prototype to reflect
3185 change on "target.h". Adjust function code to use
3187 * nto-low.c (nto_create_inferior): Adjust function prototype and
3188 code to reflect change on "target.h". Update comments.
3189 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
3190 "common-terminal.h" and "environ.h".
3191 (terminal_fd): Moved to fork-child.c.
3192 (old_foreground_pgrp): Likewise.
3193 (restore_old_foreground_pgrp): Likewise.
3194 (last_status): Make it global.
3195 (last_ptid): Likewise.
3196 (our_environ): New variable.
3197 (startup_with_shell): Likewise.
3198 (program_name): Likewise.
3199 (program_argv): Rename to...
3200 (program_args): ...this.
3201 (wrapper_argv): New variable.
3202 (start_inferior): Delete function.
3203 (get_exec_wrapper): New function.
3204 (get_exec_file): Likewise.
3205 (get_environ): Likewise.
3206 (prefork_hook): Likewise.
3207 (post_fork_inferior): Likewise.
3208 (postfork_hook): Likewise.
3209 (postfork_child_hook): Likewise.
3210 (handle_v_run): Update code to deal with arguments coming from the
3211 remote host. Update calls from "start_inferior" to
3213 (captured_main): Likewise. Initialize environment variable. Call
3215 * server.h (post_fork_inferior): New prototype.
3216 (get_environ): Likewise.
3217 (last_status): Declare.
3218 (last_ptid): Likewise.
3219 (signal_pid): Likewise.
3220 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
3221 (spu_ptrace_fun): New function.
3222 (spu_create_inferior): Adjust function prototype to reflect change
3223 on "target.h". Adjust function code to use "fork_inferior".
3224 * target.c (target_terminal_init): New function.
3225 (target_terminal_inferior): Likewise.
3226 (target_terminal_ours): Likewise.
3227 * target.h: Include <vector>.
3228 (struct target_ops) <create_inferior>: Update prototype.
3229 (create_inferior): Update macro.
3230 * utils.c (gdb_flush_out_err): New function.
3231 * win32-low.c (win32_create_inferior): Adjust function prototype
3232 and code to reflect change on "target.h".
3234 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3236 * inferiors.c (switch_to_thread): New function.
3238 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
3240 * Makefile.in (SFILE): Add "common/job-control.c".
3241 (OBS): Add "job-control.o".
3243 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
3245 * Makefile: Remove "@host_makefile_frag@".
3247 2017-05-05 Pedro Alves <palves@redhat.com>
3249 * configure: Regenerate.
3251 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
3253 * configure: Regenerate.
3255 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
3257 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
3258 software_single_step change of return type to
3259 std::vector<CORE_ADDR>.
3260 * linux-low.c (install_software_single_step_breakpoints):
3262 * linux-low.h (install_software_single_step_breakpoints):
3265 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
3267 * remote-utils.c: Include "gdb_termios.h" instead of
3269 * terminal.h: Delete file.
3271 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
3273 * server.c: Include <vector>.
3274 <program_argv, wrapper_argv>: Convert to std::vector.
3275 (start_inferior): Rewrite function to use C++.
3276 (handle_v_run): Likewise. Update code that calculates the argv
3277 based on the vRun packet; use C++.
3278 (captured_main): Likewise.
3280 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
3282 * server.c (handle_v_cont): Initialize thread_resume::thread
3285 2017-04-05 Pedro Alves <palves@redhat.com>
3287 * configure: Regenerate.
3289 2017-04-05 Pedro Alves <palves@redhat.com>
3291 * gdbreplay.c (sync_error): Constify.
3292 * linux-x86-low.c (push_opcode): Constify.
3294 2017-04-05 Pedro Alves <palves@redhat.com>
3296 * win32-low.c (get_child_debug_event)
3297 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
3298 Report TARGET_WAITKIND_SPURIOUS instead.
3300 2017-04-05 Pedro Alves <palves@redhat.com>
3302 * remote-utils.c (remote_prepare, remote_open): Constify.
3303 * remote-utils.h (remote_prepare, remote_open): Constify.
3304 * server.c (captured_main): Constify 'port' handling.
3306 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
3308 * Makefile.in (clean): Clear .deps.
3310 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
3312 * .gitignore: Remove generated files, replace with wildcard.
3313 * (clean): Replace removal of generated files with wildcard.
3314 (version.c): Replace with...
3315 (version-generated.c): ...this.
3316 (xml-builtin.c): Replace with...
3317 (xml-builtin-generated.c): ...this.
3318 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
3319 (%.c: *regformats*): Replace with...
3320 (%-generated.c: *regformats*): ...this.
3322 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
3324 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
3325 (xtensa_fill_gregset): Call collect_register_by_name for
3327 (xtensa_store_gregset): Call supply_register_by_name for
3330 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
3332 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
3333 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
3334 (xtensa_store_gregset): Call supply_register for all registers in
3335 a0_regnum..a0_regnum + C0_NREGS range.
3337 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3339 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
3340 (ax-ipa.o: ax.c): Remove.
3341 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
3342 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
3343 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
3344 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
3345 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
3347 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3349 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
3350 (print-utils-ipa.o: ../common/print-utils.c): Remove.
3351 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
3352 (errors-ipa.o: ../common/errors.c): Remove.
3353 (format-ipa.o: ../common/format.c): Remove.
3354 (common-utils-ipa.o: ../common/common-utils.c): Remove.
3356 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3358 * Makefile.in (%-ipa.o: %.c): New rule.
3359 (tracepoint-ipa.o: tracepoint.c): Remove.
3360 (utils-ipa.o: utils.c): Remove.
3361 (remote-utils-ipa.o: remote-utils.c): Remove.
3362 (regcache-ipa.o: regcache.c): Remove.
3363 (i386-linux-ipa.o: i386-linux.c): Remove.
3364 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
3365 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
3366 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
3367 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
3368 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
3369 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
3370 (amd64-linux-ipa.o: amd64-linux.c): Remove.
3371 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
3372 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
3373 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
3374 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
3375 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
3376 (aarch64-ipa.o: aarch64.c): Remove.
3377 (s390-linux32-ipa.o: s390-linux32.c): Remove.
3378 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
3379 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
3380 (s390-linux64-ipa.o: s390-linux64.c): Remove.
3381 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
3382 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
3383 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
3384 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
3385 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
3386 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
3387 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
3388 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
3389 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
3390 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
3391 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
3392 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
3393 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
3394 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
3395 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
3396 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
3397 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
3398 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
3399 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
3400 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
3401 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
3402 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
3403 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
3404 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
3405 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
3406 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
3407 (tdesc-ipa.o: tdesc.c): Remove.
3408 (x32-linux-ipa.o: x32-linux.c): Remove.
3409 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
3410 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
3412 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3414 * Makefile.in (%.o: ../arch/%.c): New rule.
3415 (arm.o: ../arch/arm.c): Remove.
3416 (arm-linux.o: ../arch/arm-linux.c): Remove.
3417 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
3418 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
3420 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3422 * Makefile.in (%.o: ../nat/%.c): New rule.
3423 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
3424 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
3425 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
3426 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
3427 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
3428 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
3429 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
3430 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
3431 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
3432 (linux-personality.o: ../nat/linux-personality.c): Remove.
3433 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
3434 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
3435 (x86-linux.o: ../nat/x86-linux.c): Remove.
3436 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
3437 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
3439 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3441 * Makefile.in (%.o: ../common/%.c): New rule.
3442 (signals.o: ../common/signals.c): Remove.
3443 (print-utils.o: ../common/print-utils.c): Remove.
3444 (rsp-low.o: ../common/rsp-low.c): Remove.
3445 (common-utils.o: ../common/common-utils.c): Remove.
3446 (posix-strerror.o: ../common/posix-strerror.c): Remove.
3447 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
3448 (vec.o: ../common/vec.c): Remove.
3449 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
3450 (xml-utils.o: ../common/xml-utils.c): Remove.
3451 (ptid.o: ../common/ptid.c): Remove.
3452 (buffer.o: ../common/buffer.c): Remove.
3453 (format.o: ../common/format.c): Remove.
3454 (filestuff.o: ../common/filestuff.c): Remove.
3455 (agent.o: ../common/agent.c): Remove.
3456 (errors.o: ../common/errors.c): Remove.
3457 (environ.o: ../common/environ.c): Remove.
3458 (common-debug.o: ../common/common-debug.c): Remove.
3459 (cleanups.o: ../common/cleanups.c): Remove.
3460 (common-exceptions.o: ../common/common-exceptions.c): Remove.
3461 (fileio.o: ../common/fileio.c): Remove.
3462 (common-regcache.o: ../common/common-regcache.c): Remove.
3463 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
3464 (new-op.o: ../common/new-op.c): Remove.
3465 (btrace-common.o: ../common/btrace-common.c): Remove.
3467 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3469 * Makefile.in (%.o: ../target/%.c): New rule.
3470 (waitstatus.o: ../target/waitstatus.c): Remove.
3472 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3475 (%.c: ../regformats/%.dat,
3476 (%.c: ../regformats/arm/%.dat,
3477 (%.c: ../regformats/i386/%.dat,
3478 (%.c: ../regformats/rs6000/%.dat): New rules.
3479 (aarch64.c): Remove.
3480 (reg-arm.c): Remove.
3481 (arm-with-iwmmxt.c): Remove.
3482 (arm-with-vfpv2.c): Remove.
3483 (arm-with-vfpv3.c): Remove.
3484 (arm-with-neon.c): Remove.
3485 (reg-bfin.c): Remove.
3486 (reg-cris.c): Remove.
3487 (reg-crisv32.c): Remove.
3489 (i386-linux.c): Remove.
3490 (i386-avx.c): Remove.
3491 (i386-avx-linux.c): Remove.
3492 (i386-avx-avx512.c): Remove.
3493 (i386-avx-avx512-linux.c): Remove.
3494 (i386-mpx.c): Remove.
3495 (i386-mpx-linux.c): Remove.
3496 (i386-avx-mpx-avx512-pku.c): Remove.
3497 (i386-avx-mpx-avx512-pku-linux.c): Remove.
3498 (i386-avx-mpx.c): Remove.
3499 (i386-avx-mpx-linux.c): Remove.
3500 (i386-mmx.c): Remove.
3501 (i386-mmx-linux.c): Remove.
3502 (reg-ia64.c): Remove.
3503 (reg-m32r.c): Remove.
3504 (reg-m68k.c): Remove.
3506 (mips-linux.c): Remove.
3507 (mips-dsp-linux.c): Remove.
3508 (mips64-linux.c): Remove.
3509 (mips64-dsp-linux.c): Remove.
3510 (nios2-linux.c): Remove.
3511 (powerpc-32.c): Remove.
3512 (powerpc-32l.c): Remove.
3513 (powerpc-altivec32l.c): Remove.
3514 (powerpc-cell32l.c): Remove.
3515 (powerpc-vsx32l.c): Remove.
3516 (powerpc-isa205-32l.c): Remove.
3517 (powerpc-isa205-altivec32l.c): Remove.
3518 (powerpc-isa205-vsx32l.c): Remove.
3519 (powerpc-e500l.c): Remove.
3520 (powerpc-64l.c): Remove.
3521 (powerpc-altivec64l.c): Remove.
3522 (powerpc-cell64l.c): Remove.
3523 (powerpc-vsx64l.c): Remove.
3524 (powerpc-isa205-64l.c): Remove.
3525 (powerpc-isa205-altivec64l.c): Remove.
3526 (powerpc-isa205-vsx64l.c): Remove.
3527 (s390-linux32.c): Remove.
3528 (s390-linux32v1.c): Remove.
3529 (s390-linux32v2.c): Remove.
3530 (s390-linux64.c): Remove.
3531 (s390-linux64v1.c): Remove.
3532 (s390-linux64v2.c): Remove.
3533 (s390-te-linux64.c): Remove.
3534 (s390-vx-linux64.c): Remove.
3535 (s390-tevx-linux64.c): Remove.
3536 (s390x-linux64.c): Remove.
3537 (s390x-linux64v1.c): Remove.
3538 (s390x-linux64v2.c): Remove.
3539 (s390x-te-linux64.c): Remove.
3540 (s390x-vx-linux64.c): Remove.
3541 (s390x-tevx-linux64.c): Remove.
3542 (tic6x-c64xp-linux.c): Remove.
3543 (tic6x-c64x-linux.c): Remove.
3544 (tic6x-c62x-linux.c): Remove.
3546 (reg-sparc64.c): Remove.
3547 (reg-spu.c): Remove.
3549 (amd64-linux.c): Remove.
3550 (amd64-avx.c): Remove.
3551 (amd64-avx-linux.c): Remove.
3552 (amd64-avx-avx512.c): Remove.
3553 (amd64-avx-avx512-linux.c): Remove.
3554 (amd64-mpx.c): Remove.
3555 (amd64-mpx-linux.c): Remove.
3556 (amd64-avx-mpx-avx512-pku.c): Remove.
3557 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
3558 (amd64-avx-mpx.c): Remove.
3559 (amd64-avx-mpx-linux.c): Remove.
3561 (x32-linux.c): Remove.
3562 (x32-avx.c): Remove.
3563 (x32-avx-linux.c): Remove.
3564 (x32-avx-avx512.c): Remove.
3565 (x32-avx-avx512-linux.c): Remove.
3566 (reg-xtensa.c): Remove.
3567 (reg-tilegx.c): Remove.
3568 (reg-tilegx32.c): Remove.
3570 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
3572 * Makefile.in (SFILES): Add "common/environ.c".
3573 (OBJS): Add "common/environ.h".
3575 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
3577 * configure.ac: Check if the fs_base and gs_base members of
3578 `struct user_regs_struct' exist.
3579 * config.in: Regenerated.
3580 * configure: Likewise.
3582 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
3584 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3586 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3587 (get_next_pcs_syscall_next_pc): Likewise.
3589 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
3591 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3592 * nto-x86-low.c: Likewise.
3594 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3596 * Makefile.in: Include disable-implicit-rules.mk.
3598 2016-11-23 Pedro Alves <palves@redhat.com>
3600 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3601 (debug_vprintf): Use std::chrono::steady_clock instead of
3602 gettimeofday. Use '.' instead of ':'.
3603 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3604 (get_timestamp): Use std::chrono::steady_clock instead of
3607 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3609 * Makefile.in: Fix whitespace formatting.
3611 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3613 * Makefile.in (SFILES, OBS): Flatten list and order
3616 2016-11-23 Pedro Alves <palves@redhat.com>
3618 * event-loop.c (handle_file_event): Use warning.
3619 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3620 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3623 2016-11-23 Pedro Alves <palves@redhat.com>
3625 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3627 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3628 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3629 debug_printf and debug_flush for debug output.
3630 * server.c (handle_general_set): Likewise.
3631 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3634 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3636 * Makefile.in (.c.o): Replace rule with ...
3637 (%.o: %.c): ... this one.
3639 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3641 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3642 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3644 * configure.ac: Remove checks for the make program.
3645 * configure: Re-generate.
3647 2016-10-28 Pedro Alves <palves@redhat.com>
3649 * Makefile.in (CXX_DIALECT): Get from configure.
3650 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3651 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3652 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3653 * config.in: Regenerate.
3654 * configure: Regenerate.
3656 2016-10-27 Yao Qi <yao.qi@linaro.org>
3658 * linux-low.c (linux_supports_range_stepping): Return true if
3659 can_software_single_step return true.
3661 2016-10-27 Yao Qi <yao.qi@linaro.org>
3663 * inferiors.c (find_inferior_in_random): New function.
3664 * inferiors.h (find_inferior_in_random): Declare.
3665 * linux-low.c (linux_wait_for_event_filtered): Call
3666 find_inferior_in_random instead of find_inferior.
3668 2016-10-27 Yao Qi <yao.qi@linaro.org>
3670 * linux-low.c (linux_wait_1): If single-step breakpoints are
3671 inserted, remove them.
3673 2016-10-26 Pedro Alves <palves@redhat.com>
3675 * linux-low.c (handle_extended_wait): Link parent/child fork
3677 (linux_wait_1): Unlink them.
3678 (linux_set_resume_request): Ignore resume requests for
3679 already-resumed and unhandled fork child threads.
3680 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3681 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3683 (handle_v_requests) <vCont>: Don't call require_running.
3684 * server.h (in_queued_stop_replies): New declaration.
3686 2016-10-24 Yao Qi <yao.qi@linaro.org>
3689 * linux-aarch64-low.c (append_insns): Cast the return value to
3692 2016-10-10 Yao Qi <yao.qi@linaro.org>
3694 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3696 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3698 * target.c (target_supports_multi_process): New function, moved
3700 * target.h (target_supports_multi_process): ... here. Remove
3703 2016-10-05 Tom Tromey <tom@tromey.com>
3706 * tracepoint.c (handle_tracepoint_bkpts): Check
3707 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3709 2016-10-05 Yao Qi <yao.qi@linaro.org>
3711 * configure.srv: Update the path of arm-*.xml files.
3713 2016-10-05 Terry Guo <terry.guo@arm.com>
3714 Yao Qi <yao.qi@linaro.org>
3716 * Makefile.in: Adjust the path of rules.
3717 * configure.srv: Update the path of xml files.
3718 * regformats/arm-with-iwmmxt.dat: Regenerated.
3719 * regformats/arm-with-neon.dat: Likewise.
3720 * regformats/arm-with-vfpv2.dat: Likewise.
3721 * regformats/arm-with-vfpv3.dat Likewise.
3723 2016-09-30 Yao Qi <yao.qi@linaro.org>
3726 * target.c (target_stop_and_wait): Don't call
3727 target_continue_no_signal, use resume_stop instead.
3729 2016-09-26 Yao Qi <yao.qi@linaro.org>
3731 * linux-low.c (linux_wait_1): Call debug_exit.
3733 2016-09-23 Pedro Alves <palves@redhat.com>
3735 * Makefile.in (SFILES): Add common/new-op.c.
3736 (OBS): Add common/new-op.o.
3737 (new-op.o): New rule.
3739 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3741 * .gitinore: Ignore more files.
3743 2016-09-21 Yao Qi <yao.qi@linaro.org>
3745 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3748 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3750 * server.c (start_inferior): Call target_mourn_inferior instead of
3751 mourn_inferior; pass ptid_t argument to it.
3753 (handle_target_event): Likewise.
3754 * target.c (target_mourn_inferior): New function.
3755 * target.h (mourn_inferior): Delete macro.
3757 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3759 * linux-low.c (lwp_is_stepping): New function.
3761 2016-09-06 Carl Love <cel@us.ibm.com>
3763 * server.c (start_inferior): Fixed comment, requested comment change
3764 didn't get updated correctly. Removed reference to ptrace () call as
3765 it is only true on Linux systems.
3767 2016-09-06 Carl Love <cel@us.ibm.com>
3769 * server.c (start_inferior): Do not call
3770 function target_post_create_inferior () if the
3771 inferior process has already exited.
3773 2016-09-05 Pedro Alves <palves@redhat.com>
3775 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3776 (COMPILE.pre, CC_LD): Use CXX directly.
3777 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3778 * acinclude.m4: Don't include build-with-cxx.m4.
3779 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3780 * configure: Regenerate.
3782 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3785 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3786 call writing data to own_buf.
3788 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3790 * target.c (mywait): Call target_wait instead of
3792 (target_wait): New function.
3794 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3796 * server.c (start_inferior): New variable 'ptid'. Replace calls
3797 to the_target->resume by target_continue{,_no_signal}, depending
3799 * target.c (target_stop_and_wait): Call target_continue_no_signal
3800 instead of the_target->resume.
3801 (target_continue): New function.
3803 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3805 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3807 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3810 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3812 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3813 * linux-arm-low.c (ps_get_thread_area): Likewise.
3814 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3815 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3816 * linux-mips-low.c (ps_get_thread_area): Likewise.
3817 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3818 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3819 * linux-x86-low.c (ps_get_thread_area): Likewise.
3820 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3822 2016-08-19 Pedro Alves <palves@redhat.com>
3824 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3826 2016-08-19 Pedro Alves <palves@redhat.com>
3828 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3829 comment. Use memcpy instead of casting through unsigned long.
3831 2016-08-19 Pedro Alves <palves@redhat.com>
3833 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3834 allocating around 0x80000000.
3836 2016-08-19 Pedro Alves <palves@redhat.com>
3839 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3840 (x32-avx512-linux-ipa.o): New rules.
3841 * configure.ac (x86_64-*-linux*): New x32 check.
3842 * configure.srv (ipa_x32_linux_regobj): New.
3843 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3844 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3846 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3848 * configure: Regenerate.
3850 2016-08-09 Pedro Alves <palves@redhat.com>
3853 * Makefile.in (OBS): Add signals-state-save-restore.o.
3854 (signals-state-save-restore.o): New rule.
3855 * config.in: Regenerate.
3856 * configure: Regenerate.
3857 * linux-low.c: Include "signals-state-save-restore.h".
3858 (linux_create_inferior): Call
3859 restore_original_signals_state.
3860 * server.c: Include "dispositions-save-restore.h".
3861 (captured_main): Call save_original_signals_state.
3863 2016-08-05 Pedro Alves <palves@redhat.com>
3865 * configure: Regenerate.
3867 2016-08-04 Yao Qi <yao.qi@linaro.org>
3869 * linux-low.c (regsets_fetch_inferior_registers): Check
3870 errno is ESRCH or not.
3872 2016-08-02 Yao Qi <yao.qi@linaro.org>
3874 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3875 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3876 (thread_db_load_search): Update.
3877 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3878 td_ta_set_event and td_ta_event_getmsg.
3880 2016-07-26 Pedro Alves <palves@redhat.com>
3883 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3884 of unsigned long for 64-bit registers and use uint32_t instead of
3885 unsigned int for 32-bit registers.
3887 2016-07-26 Pedro Alves <palves@redhat.com>
3889 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3892 2016-07-21 Tom Tromey <tom@tromey.com>
3894 * configure: Rebuild.
3896 2016-07-21 Yao Qi <yao.qi@linaro.org>
3898 * mem-break.c (find_gdb_breakpoint): Cast bp to
3899 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3901 2016-07-21 Yao Qi <yao.qi@linaro.org>
3903 * server.c (handle_v_requests): Support s and S actions
3904 if target_supports_software_single_step return true.
3906 2016-07-21 Yao Qi <yao.qi@linaro.org>
3908 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3909 is resume_step, call maybe_hw_step.
3910 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3912 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3914 (proceed_one_lwp): If resume request is resume_step, install
3915 reinsert breakpoints and call maybe_hw_step.
3917 2016-07-21 Yao Qi <yao.qi@linaro.org>
3919 * linux-low.c (proceed_one_lwp): Declare.
3920 (linux_resume_one_thread): Remove local variable 'step'.
3921 Lift code enqueue signal. Call proceed_one_lwp instead of
3922 linux_resume_one_lwp.
3924 2016-07-21 Yao Qi <yao.qi@linaro.org>
3926 * linux-low.c (linux_resume_one_thread): Call
3927 enqueue_pending_signal.
3929 2016-07-21 Yao Qi <yao.qi@linaro.org>
3931 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3932 * inferiors.c (do_restore_current_thread_cleanup): New function.
3933 (make_cleanup_restore_current_thread): Likewise.
3934 * linux-low.c (install_software_single_step_breakpoints): Call
3935 make_cleanup_restore_current_thread. Switch current_thread to
3938 2016-07-21 Yao Qi <yao.qi@linaro.org>
3940 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3941 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3942 (clone_one_breakpoint): Likewise.
3943 (delete_reinsert_breakpoints): Change parameter to thread.
3945 (has_reinsert_breakpoints): Likewise.
3946 (uninsert_reinsert_breakpoints): Likewise.
3947 (reinsert_reinsert_breakpoints): Likewise.
3948 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3949 (delete_reinsert_breakpoints): Likewise.
3950 (reinsert_reinsert_breakpoints): Likewise.
3951 (uninsert_reinsert_breakpoints): Likewise.
3952 (has_reinsert_breakpoints): Likewise.
3954 2016-07-21 Yao Qi <yao.qi@linaro.org>
3956 * inferiors.c (get_thread_process): Make parameter const.
3957 * inferiors.h (get_thread_process): Update declaration.
3958 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3959 Add new parameters child_thread and parent_thread. Callers
3961 * mem-break.h (clone_all_breakpoints): Update declaration.
3963 2016-07-21 Yao Qi <yao.qi@linaro.org>
3965 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3966 <command_list, handler>: Remove.
3967 (struct gdb_breakpoint): New.
3968 (struct other_breakpoint): New.
3969 (struct reinsert_breakpoint): New.
3970 (is_gdb_breakpoint): New function.
3971 (any_persistent_commands): Update command_list if
3972 is_gdb_breakpoint returns true.
3973 (set_breakpoint): Create breakpoints according to their types.
3974 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3975 (set_gdb_breakpoint_1): Likewise.
3976 (set_gdb_breakpoint): Likewise.
3977 (clear_breakpoint_conditions): Change parameter type to
3978 'struct gdb_breakpoint *'.
3979 (clear_breakpoint_commands): Likewise.
3980 (clear_breakpoint_conditions_and_commands): Likewise.
3981 (add_condition_to_breakpoint): Likewise.
3982 (add_breakpoint_condition): Likewise.
3983 (add_commands_to_breakpoint): Likewise.
3984 (check_breakpoints): Check other_breakpoint.
3985 (clone_one_breakpoint): Clone breakpopint according to its type.
3986 * mem-break.h (struct gdb_breakpoint): Declare.
3987 (set_gdb_breakpoint): Update declaration.
3988 (clear_breakpoint_conditions_and_commands): Likewise.
3989 (add_breakpoint_condition): Likewise.
3990 (add_breakpoint_commands): Likewise.
3991 * server.c (process_point_options): Change parameter type to
3992 'struct gdb_breakpoint *'.
3994 2016-07-21 Yao Qi <yao.qi@linaro.org>
3996 * mem-break.c (set_breakpoint_at): Rename it to ...
3997 (set_breakpoint_type_at): ... it.
3998 (set_breakpoint_at): Call set_breakpoint_type_at.
3999 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
4000 * mem-break.h (set_breakpoint_at): Update comments.
4002 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
4004 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
4006 (nios2_store_gregset): Likewise.
4008 2016-07-01 Pedro Alves <palves@redhat.com>
4009 Antoine Tremblay <antoine.tremblay@ericsson.com>
4011 * linux-low.c: Change interface to take the target lwp_info
4012 pointer directly and return void. Handle detaching from a zombie
4014 (linux_detach_lwp_callback): New function.
4015 (linux_detach): Detach from the leader thread after detaching from
4018 2016-06-28 Yao Qi <yao.qi@linaro.org>
4020 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
4021 for variable new_offset.
4022 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
4023 (aarch64_ftrace_insn_reloc_cb): Likewise.
4024 (aarch64_ftrace_insn_reloc_tb): Likewise.
4025 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
4026 PRIx64 instead of PRIx32.
4028 2016-06-28 Yao Qi <yao.qi@linaro.org>
4030 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
4031 (the_low_target): Install arm_get_syscall_trapinfo.
4033 2016-06-28 Yao Qi <yao.qi@linaro.org>
4035 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
4037 (the_low_target): Install aarch64_get_syscall_trapinfo.
4039 2016-06-28 Yao Qi <yao.qi@linaro.org>
4041 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
4043 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
4044 Remove parameter sysno.
4045 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
4048 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
4050 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
4051 (s390_emit_ne_goto): Likewise.
4052 (s390_emit_lt_goto): Likewise.
4053 (s390_emit_le_goto): Likewise.
4054 (s390_emit_gt_goto): Likewise.
4055 (s390_emit_ge_goto): Likewise.
4056 (s390x_emit_eq_goto): Likewise.
4057 (s390x_emit_ne_goto): Likewise.
4058 (s390x_emit_lt_goto): Likewise.
4059 (s390x_emit_le_goto): Likewise.
4060 (s390x_emit_gt_goto): Likewise.
4061 (s390x_emit_ge_goto): Likewise.
4062 (s390_emit_ops_impl): Mark variable static.
4063 (s390x_emit_ops): Likewise.
4065 2016-06-17 Yao Qi <yao.qi@linaro.org>
4067 * linux-low.c (handle_extended_wait): Call
4068 uninsert_reinsert_breakpoints for the parent process. Remove
4069 reinsert breakpoints from the child process. Reinsert them to
4070 the parent process when vfork is done.
4071 * mem-break.c (uninsert_reinsert_breakpoints): New function.
4072 (reinsert_reinsert_breakpoints): New function.
4073 * mem-break.h (uninsert_reinsert_breakpoints): Declare
4074 (reinsert_reinsert_breakpoints): Declare.
4076 2016-06-17 Yao Qi <yao.qi@linaro.org>
4078 * linux-low.c (handle_extended_wait): If the parent is doing
4079 step-over, remove the reinsert breakpoints from the forked child.
4081 2016-06-17 Yao Qi <yao.qi@linaro.org>
4083 * linux-low.c (unsuspend_all_lwps): Declare.
4084 (linux_low_filter_event): If thread exited, call finish_step_over.
4085 If step-over is finished, unsuspend other threads.
4087 2016-06-17 Yao Qi <yao.qi@linaro.org>
4089 * linux-low.c (linux_resume_one_lwp_throw): Assert
4090 has_reinsert_breakpoints returns false.
4091 * mem-break.c (delete_disabled_breakpoints): Assert
4092 bp type isn't reinsert_breakpoint.
4094 2016-06-17 Yao Qi <yao.qi@linaro.org>
4096 * linux-low.c (maybe_hw_step): New function.
4097 (linux_resume_one_lwp_throw): Call maybe_hw_step.
4098 (finish_step_over): Switch current_thread to lwp temporarily,
4099 and assert has_reinsert_breakpoints returns true.
4100 (proceed_one_lwp): Call maybe_hw_step.
4101 * mem-break.c (has_reinsert_breakpoints): New function.
4102 * mem-break.h (has_reinsert_breakpoints): Declare.
4104 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
4106 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
4108 2016-05-17 Yao Qi <yao.qi@linaro.org>
4110 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
4111 instead of find_inferior.
4113 2016-05-05 Yao Qi <yao.qi@linaro.org>
4115 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
4116 Initialize res to zero.
4118 2016-05-05 Yao Qi <yao.qi@linaro.org>
4120 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
4123 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
4125 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
4126 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
4127 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
4129 2016-04-28 Par Olsson <par.olsson@windriver.com>
4130 Simon Marchi <simon.marchi@ericsson.com>
4132 * tracepoint.c (write_inferior_int8): New function.
4133 (cmd_qtenable_disable): Write enable flag using
4134 write_inferior_int8.
4136 2016-04-25 Yao Qi <yao.qi@linaro.org>
4138 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
4139 (need_step_over_p): Return zero if the LWP has pending signals
4140 can be delivered on software single step target.
4142 2016-04-25 Yao Qi <yao.qi@linaro.org>
4144 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
4145 return instead of error.
4147 2016-04-22 Yao Qi <yao.qi@linaro.org>
4149 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
4152 2016-04-22 Yao Qi <yao.qi@linaro.org>
4154 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
4155 signal when stepping over breakpoint with software single
4158 2016-04-21 Pedro Alves <palves@redhat.com>
4160 * linux-s390-low.c (s390_collect_ptrace_register)
4161 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
4163 (s390_check_regset): Use void * instead of gdb_byte *.
4165 2016-04-20 Pedro Alves <palves@redhat.com>
4167 * configure: Renegerate.
4169 2016-04-20 Yao Qi <yao.qi@linaro.org>
4171 * linux-aarch32-low.c: Include "arch/arm-linux.h".
4172 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
4174 (arm_store_gregset): Likewise.
4176 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
4178 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
4179 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
4180 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
4181 (amd64-avx-mpx-linux.c): New rules.
4182 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
4183 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
4184 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
4185 (srv_amd64_regobj): Add amd64-avx-mpx.o.
4186 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
4187 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
4188 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
4189 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
4190 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
4191 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
4192 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
4193 * linux-x86-low.c (x86_linux_read_description): Add case for
4194 X86_XSTATE_AVX_MPX_MASK.
4195 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
4196 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
4197 init_registers_i386_avx_mpx_linux.
4198 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
4199 (initialize_low_tracepoint): Call
4200 init_registers_i386_avx_mpx_linux.
4201 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
4202 (initialize_low_tracepoint): Call
4203 init_registers_amd64_avx_mpx_linux.
4204 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
4205 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
4206 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
4209 2016-04-18 Pedro Alves <palves@redhat.com>
4211 * configure: Regenerate.
4213 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
4215 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
4216 (aarch64_emit_sub): Likewise.
4218 2016-04-12 Pedro Alves <palves@redhat.com>
4220 * utils.c (prepare_to_throw_exception): Delete.
4222 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
4224 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
4226 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
4228 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
4230 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
4232 * linux-aarch64-ipa.c: Add <elf.h> include.
4233 * linux-ppc-ipa.c: Add <elf.h> include.
4234 * linux-s390-ipa.c: Add <elf.h> include.
4236 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
4238 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
4239 (get_raw_reg_ptr): Likewise.
4240 (get_trace_state_variable_value_ptr): Likewise.
4241 (set_trace_state_variable_value_ptr): Likewise.
4242 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
4245 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
4246 Marcin Kościelnicki <koriakin@0x04.net>
4249 * linux-ppc-low.c (emit_insns): New function.
4250 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
4251 (ppc_emit_prologue): New function.
4252 (ppc_emit_epilogue): New function.
4253 (ppc_emit_add): New function.
4254 (ppc_emit_sub): New function.
4255 (ppc_emit_mul): New function.
4256 (ppc_emit_lsh): New function.
4257 (ppc_emit_rsh_signed): New function.
4258 (ppc_emit_rsh_unsigned): New function.
4259 (ppc_emit_ext): New function.
4260 (ppc_emit_zero_ext): New function.
4261 (ppc_emit_log_not): New function.
4262 (ppc_emit_bit_and): New function.
4263 (ppc_emit_bit_or): New function.
4264 (ppc_emit_bit_xor): New function.
4265 (ppc_emit_bit_not): New function.
4266 (ppc_emit_equal): New function.
4267 (ppc_emit_less_signed): New function.
4268 (ppc_emit_less_unsigned): New function.
4269 (ppc_emit_ref): New function.
4270 (ppc_emit_const): New function.
4271 (ppc_emit_reg): New function.
4272 (ppc_emit_pop): New function.
4273 (ppc_emit_stack_flush): New function.
4274 (ppc_emit_swap): New function.
4275 (ppc_emit_stack_adjust): New function.
4276 (ppc_emit_call): New function.
4277 (ppc_emit_int_call_1): New function.
4278 (ppc_emit_void_call_2): New function.
4279 (ppc_emit_if_goto): New function.
4280 (ppc_emit_goto): New function.
4281 (ppc_emit_eq_goto): New function.
4282 (ppc_emit_ne_goto): New function.
4283 (ppc_emit_lt_goto): New function.
4284 (ppc_emit_le_goto): New function.
4285 (ppc_emit_gt_goto): New function.
4286 (ppc_emit_ge_goto): New function.
4287 (ppc_write_goto_address): New function.
4288 (ppc_emit_ops_impl): New static variable.
4289 (ppc64v1_emit_prologue): New function.
4290 (ppc64v2_emit_prologue): New function.
4291 (ppc64_emit_epilogue): New function.
4292 (ppc64_emit_add): New function.
4293 (ppc64_emit_sub): New function.
4294 (ppc64_emit_mul): New function.
4295 (ppc64_emit_lsh): New function.
4296 (ppc64_emit_rsh_signed): New function.
4297 (ppc64_emit_rsh_unsigned): New function.
4298 (ppc64_emit_ext): New function.
4299 (ppc64_emit_zero_ext): New function.
4300 (ppc64_emit_log_not): New function.
4301 (ppc64_emit_bit_and): New function.
4302 (ppc64_emit_bit_or): New function.
4303 (ppc64_emit_bit_xor): New function.
4304 (ppc64_emit_bit_not): New function.
4305 (ppc64_emit_equal): New function.
4306 (ppc64_emit_less_signed): New function.
4307 (ppc64_emit_less_unsigned): New function.
4308 (ppc64_emit_ref): New function.
4309 (ppc64_emit_const): New function.
4310 (ppc64v1_emit_reg): New function.
4311 (ppc64v2_emit_reg): New function.
4312 (ppc64_emit_pop): New function.
4313 (ppc64_emit_stack_flush): New function.
4314 (ppc64_emit_swap): New function.
4315 (ppc64v1_emit_call): New function.
4316 (ppc64v2_emit_call): New function.
4317 (ppc64v1_emit_int_call_1): New function.
4318 (ppc64v2_emit_int_call_1): New function.
4319 (ppc64v1_emit_void_call_2): New function.
4320 (ppc64v2_emit_void_call_2): New function.
4321 (ppc64_emit_if_goto): New function.
4322 (ppc64_emit_eq_goto): New function.
4323 (ppc64_emit_ne_goto): New function.
4324 (ppc64_emit_lt_goto): New function.
4325 (ppc64_emit_le_goto): New function.
4326 (ppc64_emit_gt_goto): New function.
4327 (ppc64_emit_ge_goto): New function.
4328 (ppc64v1_emit_ops_impl): New static variable.
4329 (ppc64v2_emit_ops_impl): New static variable.
4330 (ppc_emit_ops): New function.
4331 (linux_low_target): Wire in ppc_emit_ops.
4333 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
4334 Marcin Kościelnicki <koriakin@0x04.net>
4337 * Makefile.in: Add powerpc-*-ipa.o
4338 * configure.srv: Add ipa_obj for powerpc*-linux.
4339 * linux-ppc-ipa.c: New file.
4340 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
4342 (PPC_FIELD): New macro.
4343 (PPC_SEXT): New macro.
4344 (PPC_OP6): New macro.
4345 (PPC_BO): New macro.
4346 (PPC_LI): New macro.
4347 (PPC_BD): New macro.
4348 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
4349 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
4350 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
4351 (ppc_get_thread_area): New function.
4352 (is_elfv2_inferior): New function.
4353 (gen_ds_form): New function.
4354 (GEN_STD): New macro.
4355 (GEN_STDU): New macro.
4356 (GEN_LD): New macro.
4357 (GEN_LDU): New macro.
4358 (gen_d_form): New function.
4359 (GEN_ADDI): New macro.
4360 (GEN_ADDIS): New macro.
4361 (GEN_LI): New macro.
4362 (GEN_LIS): New macro.
4363 (GEN_ORI): New macro.
4364 (GEN_ORIS): New macro.
4365 (GEN_LWZ): New macro.
4366 (GEN_STW): New macro.
4367 (GEN_STWU): New macro.
4368 (gen_xfx_form): New function.
4369 (GEN_MFSPR): New macro.
4370 (GEN_MTSPR): New macro.
4371 (GEN_MFCR): New macro.
4372 (GEN_MTCR): New macro.
4373 (GEN_SYNC): New macro.
4374 (GEN_LWSYNC): New macro.
4375 (gen_x_form): New function.
4376 (GEN_OR): New macro.
4377 (GEN_MR): New macro.
4378 (GEN_LWARX): New macro.
4379 (GEN_STWCX): New macro.
4380 (GEN_CMPW): New macro.
4381 (gen_md_form): New function.
4382 (GEN_RLDICL): New macro.
4383 (GEN_RLDICR): New macro.
4384 (gen_i_form): New function.
4386 (GEN_BL): New macro.
4387 (gen_b_form): New function.
4388 (GEN_BNE): New macro.
4389 (GEN_LOAD): New macro.
4390 (GEN_STORE): New macro.
4391 (gen_limm): New function.
4392 (gen_atomic_xchg): New function.
4393 (gen_call): New function.
4394 (ppc_relocate_instruction): New function.
4395 (ppc_install_fast_tracepoint_jump_pad): New function.
4396 (ppc_get_min_fast_tracepoint_insn_len): New function.
4397 (ppc_get_ipa_tdesc_idx): New function.
4398 (the_low_target): Wire in the new functions.
4399 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
4401 * linux-ppc-tdesc.h: New file.
4403 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
4405 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
4406 (alloc_jump_pad_buffer): New function.
4407 * linux-amd64-ipa.c: Add <sys/mman.h> include.
4408 (alloc_jump_pad_buffer): New function.
4409 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
4410 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
4411 (alloc_jump_pad_buffer): New function.
4412 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
4413 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
4414 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
4415 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
4417 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
4419 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
4420 * linux-amd64-ipa.c: Likewise.
4421 * linux-i386-ipa.c: Likewise.
4422 * linux-s390-ipa.c: Likewise.
4423 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
4424 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
4425 set_trace_state_variable_value_ptr.
4426 (struct ipa_sym_addresses): Likewise.
4427 (symbol_list): Likewise.
4428 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
4429 accessing gdb_collect directly.
4430 (gdb_collect_ptr_type): New typedef.
4431 (get_raw_reg_ptr_type): New typedef.
4432 (get_trace_state_variable_value_ptr_type): New typedef.
4433 (set_trace_state_variable_value_ptr_type): New typedef.
4434 (gdb_collect_ptr): New global.
4435 (get_raw_reg_ptr): New global.
4436 (get_trace_state_variable_value_ptr): New global.
4437 (set_trace_state_variable_value_ptr): New global.
4438 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
4439 accessing get_raw_reg directly.
4440 (get_get_tsv_func_addr): Likewise for
4441 get_trace_state_variable_value_ptr.
4442 (get_set_tsv_func_addr): Likewise for
4443 set_trace_state_variable_value_ptr.
4444 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
4446 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
4448 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
4450 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
4452 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
4454 (relocate_instruction): Remove own_buf.
4455 * server.c (own_buf): Make global.
4456 (handle_v_requests): Make global.
4457 * server.h (own_buf): New declaration.
4458 (handle_v_requests): New prototype.
4460 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4463 * linux-s390-low.c (add_insns): New function.
4464 (s390_emit_prologue): New function.
4465 (s390_emit_epilogue): New function.
4466 (s390_emit_add): New function.
4467 (s390_emit_sub): New function.
4468 (s390_emit_mul): New function.
4469 (s390_emit_lsh): New function.
4470 (s390_emit_rsh_signed): New function.
4471 (s390_emit_rsh_unsigned): New function.
4472 (s390_emit_ext): New function.
4473 (s390_emit_log_not): New function.
4474 (s390_emit_bit_and): New function.
4475 (s390_emit_bit_or): New function.
4476 (s390_emit_bit_xor): New function.
4477 (s390_emit_bit_not): New function.
4478 (s390_emit_equal): New function.
4479 (s390_emit_less_signed): New function.
4480 (s390_emit_less_unsigned): New function.
4481 (s390_emit_ref): New function.
4482 (s390_emit_if_goto): New function.
4483 (s390_emit_goto): New function.
4484 (s390_write_goto_address): New function.
4485 (s390_emit_litpool): New function.
4486 (s390_emit_const): New function.
4487 (s390_emit_call): New function.
4488 (s390_emit_reg): New function.
4489 (s390_emit_pop): New function.
4490 (s390_emit_stack_flush): New function.
4491 (s390_emit_zero_ext): New function.
4492 (s390_emit_swap): New function.
4493 (s390_emit_stack_adjust): New function.
4494 (s390_emit_set_r2): New function.
4495 (s390_emit_int_call_1): New function.
4496 (s390_emit_void_call_2): New function.
4497 (s390_emit_eq_goto): New function.
4498 (s390_emit_ne_goto): New function.
4499 (s390_emit_lt_goto): New function.
4500 (s390_emit_le_goto): New function.
4501 (s390_emit_gt_goto): New function.
4502 (s390_emit_ge_goto): New function.
4503 (s390x_emit_prologue): New function.
4504 (s390x_emit_epilogue): New function.
4505 (s390x_emit_add): New function.
4506 (s390x_emit_sub): New function.
4507 (s390x_emit_mul): New function.
4508 (s390x_emit_lsh): New function.
4509 (s390x_emit_rsh_signed): New function.
4510 (s390x_emit_rsh_unsigned): New function.
4511 (s390x_emit_ext): New function.
4512 (s390x_emit_log_not): New function.
4513 (s390x_emit_bit_and): New function.
4514 (s390x_emit_bit_or): New function.
4515 (s390x_emit_bit_xor): New function.
4516 (s390x_emit_bit_not): New function.
4517 (s390x_emit_equal): New function.
4518 (s390x_emit_less_signed): New function.
4519 (s390x_emit_less_unsigned): New function.
4520 (s390x_emit_ref): New function.
4521 (s390x_emit_if_goto): New function.
4522 (s390x_emit_const): New function.
4523 (s390x_emit_call): New function.
4524 (s390x_emit_reg): New function.
4525 (s390x_emit_pop): New function.
4526 (s390x_emit_stack_flush): New function.
4527 (s390x_emit_zero_ext): New function.
4528 (s390x_emit_swap): New function.
4529 (s390x_emit_stack_adjust): New function.
4530 (s390x_emit_int_call_1): New function.
4531 (s390x_emit_void_call_2): New function.
4532 (s390x_emit_eq_goto): New function.
4533 (s390x_emit_ne_goto): New function.
4534 (s390x_emit_lt_goto): New function.
4535 (s390x_emit_le_goto): New function.
4536 (s390x_emit_gt_goto): New function.
4537 (s390x_emit_ge_goto): New function.
4538 (s390_emit_ops): New function.
4539 (struct linux_target_ops): Fill in emit_ops hook.
4541 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4544 * Makefile.in: Add s390 IPA files.
4545 * configure.srv: Build IPA for s390.
4546 * linux-s390-ipa.c: New file.
4547 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
4548 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
4549 (tdesc_s390_linux32): Likewise.
4550 (init_registers_s390_linux32v1): Likewise.
4551 (tdesc_s390_linux32v1): Likewise.
4552 (init_registers_s390_linux32v2): Likewise.
4553 (tdesc_s390_linux32v2): Likewise.
4554 (init_registers_s390_linux64): Likewise.
4555 (tdesc_s390_linux64): Likewise.
4556 (init_registers_s390_linux64v1): Likewise.
4557 (tdesc_s390_linux64v1): Likewise.
4558 (init_registers_s390_linux64v2): Likewise.
4559 (tdesc_s390_linux64v2): Likewise.
4560 (init_registers_s390_te_linux64): Likewise.
4561 (tdesc_s390_te_linux64): Likewise.
4562 (init_registers_s390_vx_linux64): Likewise.
4563 (tdesc_s390_vx_linux64): Likewise.
4564 (init_registers_s390_tevx_linux64): Likewise.
4565 (tdesc_s390_tevx_linux64): Likewise.
4566 (init_registers_s390x_linux64): Likewise.
4567 (tdesc_s390x_linux64): Likewise.
4568 (init_registers_s390x_linux64v1): Likewise.
4569 (tdesc_s390x_linux64v1): Likewise.
4570 (init_registers_s390x_linux64v2): Likewise.
4571 (tdesc_s390x_linux64v2): Likewise.
4572 (init_registers_s390x_te_linux64): Likewise.
4573 (tdesc_s390x_te_linux64): Likewise.
4574 (init_registers_s390x_vx_linux64): Likewise.
4575 (tdesc_s390x_vx_linux64): Likewise.
4576 (init_registers_s390x_tevx_linux64): Likewise.
4577 (tdesc_s390x_tevx_linux64): Likewise.
4578 (have_hwcap_s390_vx): New static variable.
4579 (s390_arch_setup): Fill have_hwcap_s390_vx.
4580 (s390_get_thread_area): New function.
4581 (s390_ft_entry_gpr_esa): New const.
4582 (s390_ft_entry_gpr_zarch): New const.
4583 (s390_ft_entry_misc): New const.
4584 (s390_ft_entry_fr): New const.
4585 (s390_ft_entry_vr): New const.
4586 (s390_ft_main_31): New const.
4587 (s390_ft_main_64): New const.
4588 (s390_ft_exit_fr): New const.
4589 (s390_ft_exit_vr): New const.
4590 (s390_ft_exit_misc): New const.
4591 (s390_ft_exit_gpr_esa): New const.
4592 (s390_ft_exit_gpr_zarch): New const.
4593 (append_insns): New function.
4594 (s390_relocate_instruction): New function.
4595 (s390_install_fast_tracepoint_jump_pad): New function.
4596 (s390_get_min_fast_tracepoint_insn_len): New function.
4597 (s390_get_ipa_tdesc_idx): New function.
4598 (struct linux_target_ops): Wire in the above functions.
4599 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4600 * linux-s390-tdesc.h: New file.
4602 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4604 * linux-s390-low.c (s390_supports_tracepoints): New function.
4605 (struct linux_target_ops): Fill supports_tracepoints hook.
4607 2016-03-18 Yao Qi <yao.qi@linaro.org>
4609 * linux-low.c (lwp_signal_can_be_delivered): New function.
4610 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4612 2016-03-18 Yao Qi <yao.qi@linaro.org>
4614 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4615 0 if signal is enqueued. Remove 'signal' from one debugging
4616 message. Move one debugging message to some lines below.
4617 Remove code setting 'signal' to 0.
4619 2016-03-18 Yao Qi <yao.qi@linaro.org>
4621 * linux-low.c (linux_low_filter_event): Remove redundant
4622 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4624 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4626 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4627 (struct linux_target_ops): Wire in the above.
4629 2016-03-03 Yao Qi <yao.qi@linaro.org>
4631 * linux-low.c: Update comments to start_step_over.
4633 2016-03-03 Yao Qi <yao.qi@linaro.org>
4636 * linux-low.c (handle_extended_wait): Set child suspended
4637 if event_lwp->bp_reinsert isn't zero.
4639 2016-03-02 Yao Qi <yao.qi@linaro.org>
4641 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4642 enqueue_pending_signal.
4644 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4646 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4649 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4651 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4652 (s390_regmap_3264) [!__s390x__]: New global.
4653 (s390_collect_ptrace_register): Skip map entries containing -1.
4654 (s390_supply_ptrace_register): Ditto.
4655 (s390_fill_gprs_high): New function.
4656 (s390_store_gprs_high): New function.
4657 (s390_regsets): Add NT_S390_HIGH_GPRS.
4658 (s390_get_hwcap): Enable on 31-bit.
4659 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4660 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4661 Detect NT_S390_HIGH_GPRS.
4662 (s390_usrregs_info_3264): Enable on 31-bit.
4663 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4664 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4666 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4669 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4670 * configure.srv: Ditto.
4671 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4672 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4673 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4674 (init_registers_amd64_linux): Remove prototype.
4675 (tdesc_amd64_linux): Remove declaration.
4676 (get_ipa_tdesc): New function.
4677 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4678 initialize remaining tdescs.
4679 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4680 (init_registers_i386_linux): Remove prototype.
4681 (tdesc_i386_linux): Remove declaration.
4682 (get_ipa_tdesc): New function.
4683 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4684 initialize remaining tdescs.
4685 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4686 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4687 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4688 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4689 (x86_get_ipa_tdesc_idx): New function.
4690 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4691 * linux-x86-tdesc.h: New file.
4692 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4693 (target_get_ipa_tdesc_idx): New macro.
4694 * tracepoint.c (ipa_tdesc_idx): New macro.
4695 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4696 (symbol_list): Add ipa_tdesc_idx.
4697 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4698 (ipa_tdesc): Remove.
4699 (ipa_tdesc_idx): New variable.
4700 (get_context_regcache): Use get_ipa_tdesc.
4701 (gdb_collect): Ditto.
4703 * tracepoint.h (get_ipa_tdesc): New prototype.
4704 (ipa_tdesc): Remove.
4706 2016-02-24 Pedro Alves <palves@redhat.com>
4708 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4709 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4710 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4711 Factor out common code between the USE_SIGTRAP_SIGINFO and
4712 !USE_SIGTRAP_SIGINFO blocks.
4713 (linux_low_filter_event): Call save_stop_reason instead of
4714 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4716 (linux_wait_1): Update comments.
4718 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
4720 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4721 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4722 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4723 ppc_insert_point, ppc_remove_point.
4725 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4727 * linux-s390-low.c (s390_supports_z_point_type): New function.
4728 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4730 2016-02-16 Yao Qi <yao.qi@linaro.org>
4732 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4733 PC. Get pc from regcache_read_pc.
4735 2016-02-12 Yao Qi <yao.qi@linaro.org>
4737 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4738 or linux_get_pc_32bit.
4739 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4741 2016-02-12 Yao Qi <yao.qi@linaro.org>
4743 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4744 arm_linux_get_next_pcs_fixup.
4746 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4748 * tracepoint.c (x_tracepoint_action_download): Change
4749 write_inferior_data_ptr to write_inferior_data_pointer.
4750 (cmd_qtstart): Likewise.
4751 (write_inferior_data_ptr): Remove.
4752 (download_agent_expr): Change write_inferior_data_ptr to
4753 write_inferior_data_pointer.
4754 (download_tracepoint_1): Likewise.
4755 (download_tracepoint): Likewise.
4756 (download_trace_state_variables): Likewise.
4758 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
4759 Marcin Kościelnicki <koriakin@0x04.net>
4761 * tracepoint.c (struct tracepoint_action_ops): Remove.
4762 (struct tracepoint_action): Remove ops.
4763 (m_tracepoint_action_download, r_tracepoint_action_download)
4764 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4765 size and offset accordingly.
4766 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4767 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4768 (tracepoint_action_send, tracepoint_action_download): New functions.
4769 Helpers for trace action handlers.
4770 (add_tracepoint_action): Remove setup actions ops.
4771 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4773 2016-02-10 Yao Qi <yao.qi@linaro.org>
4775 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4777 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4779 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4781 * configure: Regenerate.
4783 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4785 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4786 void * to gdb_byte *.
4787 * linux-low.c (siginfo_fixup): Likewise.
4788 (linux_xfer_siginfo): Likewise.
4789 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4791 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4793 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4795 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4797 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4799 * linux-x86-low.c [__x86_64__]: Include
4800 "nat/amd64-linux-siginfo.h".
4801 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4802 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4803 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4804 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4805 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4806 (cpt_si_fd, si_timerid, si_overrun): Move from
4807 nat/amd64-linux-siginfo.c.
4808 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4810 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4812 * server.c (skip_to_semicolon): Remove.
4813 (process_point_options): Use strchrnul instead of
4816 2016-01-26 Yao Qi <yao.qi@linaro.org>
4818 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4819 * linux-low.c (install_software_single_step_breakpoints): Don't
4820 call regcache_read_pc.
4821 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4824 2016-01-26 Yao Qi <yao.qi@linaro.org>
4826 * linux-low.c (install_software_single_step_breakpoints): Call
4827 regcache_read_pc instead of get_pc.
4829 2016-01-26 Yao Qi <yao.qi@linaro.org>
4831 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4832 (unblock_async_io): Rename to ...
4833 (block_unblock_async_io): ... it. New function.
4834 (enable_async_io): Don't install SIGIO handler. Unblock it
4836 (disable_async_io): Don't ignore SIGIO. Block it instead.
4837 (initialize_async_io): Install SIGIO handler. Don't call
4840 2016-01-26 Yao Qi <yao.qi@linaro.org>
4842 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4843 first character is '\003', call *the_target->request_interrupt.
4845 2016-01-25 Yao Qi <yao.qi@linaro.org>
4847 * remote-utils.c (new_thread_notify): Remove.
4848 (dead_thread_notify): Likewise.
4849 * remote-utils.h (new_thread_notify): Remove declaration.
4850 (dead_thread_notify): Likewise.
4852 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4854 * gdb.trace/pending.exp: Fix expected message on continue.
4856 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4858 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4859 it works properly on big-endian machines where sizeof (CORE_ADDR)
4862 2016-01-21 Pedro Alves <palves@redhat.com>
4864 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4865 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4866 * configure: Regenerate.
4868 2016-01-21 Yao Qi <yao.qi@linaro.org>
4870 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4871 is_thumb and set it according to CPSR saved on the stack.
4872 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4873 arm_sigreturn_next_pc.
4875 2016-01-18 Yao Qi <yao.qi@linaro.org>
4877 * linux-low.c (linux_set_pc_64bit): New function.
4878 (linux_get_pc_64bit): New function.
4879 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4881 * linux-sparc-low.c (debug_threads): Remove declaration.
4882 (sparc_get_pc): Remove.
4883 (the_low_target): Use linux_get_pc_64bit instead of
4885 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4886 (the_low_target): Use linux_get_pc_64bit and
4889 2016-01-18 Yao Qi <yao.qi@linaro.org>
4891 * linux-arm-low.c (debug_threads): Remove declaration.
4892 (arm_get_pc, arm_set_pc): Remove.
4893 (the_low_target): Use linux_get_pc_32bit and
4895 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4896 (the_low_target): Use linux_get_pc_32bit and
4898 * linux-cris-low.c (debug_threads): Remove declaration.
4899 (cris_get_pc, cris_set_pc,): Remove.
4900 (the_low_target): Use linux_get_pc_32bit and
4902 * linux-crisv32-low.c (debug_threads): Remove declaration.
4903 (cris_get_pc, cris_set_pc): Remove.
4904 (the_low_target): Use linux_get_pc_32bit and
4906 * linux-low.c: Include inttypes.h.
4907 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4908 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4909 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4910 (the_low_target): Use linux_get_pc_32bit and
4912 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4913 (the_low_target): Use linux_get_pc_32bit and
4915 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4916 (the_low_target): Use linux_get_pc_32bit and
4918 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4919 (the_low_target): Use linux_get_pc_32bit and
4921 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4922 (the_low_target): Use linux_get_pc_32bit and
4925 2016-01-18 Gary Benson <gbenson@redhat.com>
4927 * configure.ac (AC_FUNC_FORK): New check.
4928 * config.in: Regenerate.
4929 * configure: Likewise.
4931 2016-01-14 Yao Qi <yao.qi@linaro.org>
4933 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4934 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4935 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4936 arm_get_next_pcs_ctor.
4938 2016-01-12 Josh Stone <jistone@redhat.com>
4939 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4941 * inferiors.h: Include "gdb_vecs.h".
4942 (struct process_info): Add syscalls_to_catch.
4943 * inferiors.c (remove_process): Free syscalls_to_catch.
4944 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4945 syscall_return stops.
4946 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4947 * server.c (handle_general_set): Handle QCatchSyscalls.
4948 (handle_query): Report support for QCatchSyscalls.
4949 * target.h (struct target_ops): Add supports_catch_syscall.
4950 (target_supports_catch_syscall): New macro.
4951 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4952 (struct lwp_info): Add syscall_state.
4953 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4954 Maintain syscall_state and syscalls_to_catch across exec.
4955 (get_syscall_trapinfo): New function, proxy to the_low_target.
4956 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4957 (linux_low_filter_event): Toggle syscall_state entry/return for
4958 syscall traps, and set it ignored for all others.
4959 (gdb_catching_syscalls_p): New function.
4960 (gdb_catch_this_syscall_p): New function.
4961 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4962 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4963 (linux_supports_catch_syscall): New function.
4964 (linux_target_ops): Install it.
4965 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4966 (the_low_target): Install it.
4968 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4970 * acinclude.m4: Include new ../warning.m4 file.
4971 * configure: Regenerated.
4972 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4974 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4976 * ax.c (is_goto_target): Mark static.
4977 * linux-low.c (register_addr): Likewise.
4978 (linux_fetch_registers, linux_store_registers): Likewise.
4979 * mem-break.c (any_persistent_commands): Fix old prototype.
4980 (add_commands_to_breakpoint): Mark static.
4981 * regcache.c (find_register_by_name): Delete unused func.
4982 * remote-utils.c (hex_or_minus_one): Mark static.
4983 * server.c (monitor_show_help): Mark static.
4984 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4985 handle_v_requests): Likewise.
4987 2016-01-12 Pedro Alves <palves@redhat.com>
4989 Remove use of the registered trademark symbol throughout.
4991 2016-01-08 Yao Qi <yao.qi@linaro.org>
4993 * remote-utils.c (getpkt): If c is '\003', call target hook
4996 2016-01-06 Yao Qi <yao.qi@linaro.org>
4998 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4999 linux-aarch32-low.c.
5000 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5001 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
5002 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5003 (thumb2_breakpoint): Declare.
5004 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
5005 linux-aarch32-low.h.
5006 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5007 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
5008 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5010 2016-01-01 Joel Brobecker <brobecker@adacore.com>
5012 * gdbreplay.c (gdbreplay_version): Change copyright year in
5014 * server.c (gdbserver_version): Likewise.
5016 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
5018 * server.c (crc32_table): Delete.
5019 (crc32): Use libiberty's xcrc32 function.
5021 2015-12-22 Joel Brobecker <brobecker@adacore.com>
5023 * lynx-low.c (lynx_delete_thread_callback): New function.
5024 (lynx_mourn): Properly delete our process and all of its
5025 threads. Remove call to clear_inferiors.
5027 2015-12-22 Joel Brobecker <brobecker@adacore.com>
5029 * target.c (thread_search_callback): Add check that
5030 the thread_stopped target callback is not NULL before
5033 2015-12-21 Yao Qi <yao.qi@linaro.org>
5035 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
5038 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5040 * server.c (handle_query): Call target_supports_software_single_step.
5042 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5044 * linux-low.c (single_step): New function.
5045 (linux_resume_one_lwp_throw): Call single_step.
5046 (start_step_over): Likewise.
5048 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5050 * Makefile.in (SFILES): Append arch/arm-linux.c,
5051 arch/arm-get-next-pcs.c.
5052 (arm-linux.o): New rule.
5053 (arm-get-next-pcs.o): New rule.
5054 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
5056 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
5057 to linux-aarch32-low.c.
5058 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5059 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5060 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5061 (thumb2_breakpoint_len): Likewise.
5062 (arm_is_thumb_mode): Make non-static.
5063 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
5064 from linux-aarch32-low.c.
5065 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5066 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5067 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5068 (thumb2_breakpoint_len): Likewise.
5069 (arm_is_thumb_mode): New declaration.
5070 * linux-arm-low.c: Include arch/arm-linux.h
5071 aarch/arm-get-next-pcs.h, sys/syscall.h.
5072 (get_next_pcs_ops): New struct.
5073 (get_next_pcs_addr_bits_remove): New function.
5074 (get_next_pcs_is_thumb): New function.
5075 (get_next_pcs_read_memory_unsigned_integer): Likewise.
5076 (arm_sigreturn_next_pc): Likewise.
5077 (get_next_pcs_syscall_next_pc): Likewise.
5078 (arm_gdbserver_get_next_pcs): Likewise.
5079 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
5081 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
5082 * server.h: Include gdb_vecs.h.
5084 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5086 * Makefile.in (SFILES): Append common/common-regcache.c.
5087 (OBS): Append common-regcache.o.
5088 (common-regcache.o): New rule.
5089 * regcache.c (init_register_cache): Initialize cache to
5091 (regcache_raw_read_unsigned): New function.
5092 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
5093 register_status enum.
5095 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
5097 * linux-aarch64-low.c (the_low_targets): Rename
5098 breakpoint_reinsert_addr to get_next_pcs.
5099 * linux-arm-low.c (the_low_targets): Likewise.
5100 * linux-bfin-low.c (the_low_targets): Likewise.
5101 * linux-cris-low.c (the_low_targets): Likewise.
5102 * linux-crisv32-low.c (the_low_targets): Likewise.
5103 * linux-low.c (can_software_single_step): Likewise.
5104 (install_software_single_step_breakpoints): New function.
5105 (start_step_over): Use install_software_single_step_breakpoints.
5106 * linux-low.h: New CORE_ADDR vector.
5107 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
5109 * linux-mips-low.c (the_low_targets): Likewise.
5110 * linux-nios2-low.c (the_low_targets): Likewise.
5111 * linux-sparc-low.c (the_low_targets): Likewise.
5113 2015-12-17 Pedro Alves <palves@redhat.com>
5115 * linux-low.c (linux_kill_one_lwp): Remove references to
5117 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
5119 (linux_init_signals): Delete.
5120 (initialize_low): Adjust.
5121 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
5123 2015-12-16 Pedro Alves <palves@redhat.com>
5125 * configure.ac (compiler warning flags): When testing a
5126 -Wno-foo option, check whether -Wfoo works instead.
5127 * configure: Regenerate.
5129 2015-12-11 Don Breazeal <donb@codesourcery.com>
5131 * server.c (process_serial_event): Don't exit from gdbserver
5132 in remote mode if there are still active inferiors.
5134 2015-12-11 Yao Qi <yao.qi@linaro.org>
5136 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
5137 arm_breakpoint_at if the process is 32-bit.
5139 2015-12-11 Yao Qi <yao.qi@linaro.org>
5141 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
5144 2015-12-07 Yao Qi <yao.qi@linaro.org>
5146 * configure.srv: Append arm.o to srv_tgtobj for
5147 aarch64*-*-linux* target.
5148 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
5149 from linux-arm-low.c.
5150 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
5151 (arm_breakpoint_len, thumb_breakpoint): Likewise.
5152 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
5153 (thumb2_breakpoint_len): Likewise.
5154 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
5155 (arm_breakpoint_kinds): Likewise.
5156 (arm_breakpoint_kind_from_pc): Likewise.
5157 (arm_sw_breakpoint_from_kind): Likewise.
5158 (arm_breakpoint_kind_from_current_state): Likewise.
5159 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
5160 (arm_sw_breakpoint_from_kind): Declare.
5161 (arm_breakpoint_kind_from_current_state): Declare.
5162 (arm_breakpoint_at): Declare.
5163 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
5164 arm_sw_breakpoint_from_kind if process is 32-bit.
5165 (aarch64_breakpoint_kind_from_pc): New function.
5166 (aarch64_breakpoint_kind_from_current_state): New function.
5167 (the_low_target): Initialize fields breakpoint_kind_from_pc
5168 and breakpoint_kind_from_current_state.
5169 * linux-arm-low.c (arm_breakpoint_kinds): Move to
5170 linux-aarch32-low.c.
5171 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
5172 (arm_breakpoint, arm_breakpoint_len): Likewise.
5173 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
5174 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
5175 (arm_is_thumb_mode): Likewise.
5176 (arm_breakpoint_at): Likewise.
5177 (arm_breakpoint_kind_from_pc): Likewise.
5178 (arm_sw_breakpoint_from_kind): Likewise.
5179 (arm_breakpoint_kind_from_current_state): Likewise.
5182 2015-08-04 Yao Qi <yao.qi@linaro.org>
5184 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
5185 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
5186 * server.c (extended_protocol): Remove "static".
5187 * server.h (extended_protocol): Declare it.
5189 2015-12-04 Josh Stone <jistone@redhat.com>
5191 * target.h (struct target_ops) <arch_setup>: Rename to ...
5192 (struct target_ops) <post_create_inferior>: ... this.
5193 (target_arch_setup): Rename to ...
5194 (target_post_create_inferior): ... this, calling post_create_inferior.
5195 * server.c (start_inferior): Update target_arch_setup calls to
5196 target_post_create_inferior.
5197 * linux-low.c (linux_low_ptrace_options): Forward declare.
5198 (linux_arch_setup): Update its comment for general use.
5199 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
5200 (struct linux_target_ops): Use linux_post_create_inferior.
5201 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
5202 to post_create_inferior.
5203 * nto-low.c (struct nto_target_ops): Likewise.
5204 * spu-low.c (struct spu_target_ops): Likewise.
5205 * win32-low.c (struct win32_target_ops): Likewise.
5207 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
5209 * linux-arm-low.c: Remove duplicate arch/arm.h include.
5211 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5213 * linux-arm-low.c (arm_reinsert_addr): Remove function.
5214 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
5215 * linux-cris-low.c (cris_reinsert_addr> Remove function.
5216 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5217 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
5218 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5219 * linux-mips-low.c (mips_reinsert_addr): Remove function.
5220 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5221 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
5222 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5223 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
5224 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
5226 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5228 * linux-low.c (linux_look_up_symbols): Don't call
5229 linux_supports_traceclone.
5230 * linux-low.h (thread_db_init): Remove use_events argument.
5231 * thread-db.c (thread_db_use_event): Remove global variable.
5232 (struct thread_db) <td_thr_event_enable_p>: Remove field.
5233 (struct thread_db) <td_create_bp>: Remove field.
5234 (thread_db_create_event): Remove function.
5235 (thread_db_enable_reporting): Likewise.
5236 (find_one_thread): Don't check for thread_db_use_events.
5237 (attach_thread): Likewise.
5238 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
5239 (try_thread_db_load_1): Don't check for thread_db_use_events.
5240 (thread_db_init): Remove use_events argument and thread events
5242 (remove_thread_event_breakpoints): Remove function.
5243 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
5245 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5247 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
5249 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5250 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
5251 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5252 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
5253 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
5255 * linux-crisv32-low.c (cris_supports_hardware_single_step):
5257 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5258 * linux-low.c (can_hardware_single_step): Use
5259 supports_hardware_single_step.
5260 (can_software_single_step): New function.
5261 (start_step_over): Call can_software_single_step.
5262 (linux_supports_hardware_single_step): New function.
5263 (struct target_ops) <supports_software_single_step>: Initialize.
5264 * linux-low.h (struct linux_target_ops)
5265 <supports_hardware_single_step>: Initialize.
5266 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
5267 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5268 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
5269 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
5270 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
5271 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5272 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
5273 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5274 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
5275 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
5277 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
5278 (struct linux_target_ops) <tile_supports_hardware_single_step>:
5280 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
5281 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5282 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
5284 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
5285 * target.h (struct target_ops): <supports_software_single_step>:
5287 (target_supports_software_single_step): New macro.
5289 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5291 * linux-low.c (linux_wait_1): Fix pc advance condition.
5292 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
5293 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
5295 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
5297 * linux-arm-low.c (arm_is_thumb_mode): New function.
5298 (arm_breakpoint_at): Use arm_is_thumb_mode.
5299 (arm_breakpoint_kind_from_current_state): New function.
5300 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
5302 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
5303 (linux_breakpoint_kind_from_current_state): New function.
5304 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
5305 * linux-low.h (struct linux_target_ops)
5306 <breakpoint_kind_from_current_state>: New field.
5307 * target.h (struct target_ops): Likewise.
5308 (target_breakpoint_kind_from_current_state): New macro.
5310 2015-11-30 Pedro Alves <palves@redhat.com>
5312 * linux-low.c (linux_resume): Wake up the event loop before
5315 2015-11-30 Pedro Alves <palves@redhat.com>
5317 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
5319 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
5321 * target.c (struct thread_search): New structure.
5322 (thread_search_callback): New function.
5323 (prev_general_thread): New global.
5324 (prepare_to_access_memory, done_accessing_memory): New functions.
5325 * target.h (prepare_to_access_memory, done_accessing_memory):
5326 Replace macros with function declarations.
5328 2015-11-30 Pedro Alves <palves@redhat.com>
5331 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
5332 report TARGET_WAITKIND_NO_RESUMED.
5333 * remote-utils.c (prepare_resume_reply): Handle
5334 TARGET_WAITKIND_NO_RESUMED.
5335 * server.c (report_no_resumed): New global.
5336 (handle_query) <qSupported>: Handle "no-resumed+". Report
5337 "no-resumed+" support.
5338 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
5339 return error if the client doesn't support no-resumed events.
5340 (push_stop_notification): New function.
5341 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
5342 events if the client supports them.
5344 2015-11-30 Pedro Alves <palves@redhat.com>
5346 * linux-low.c (thread_still_has_status_pending_p): Don't check
5348 (lwp_resumed): New function.
5349 (status_pending_p_callback): Return early if the LWP is not
5350 supposed to be resumed.
5352 2015-11-30 Pedro Alves <palves@redhat.com>
5354 * linux-low.c (handle_extended_wait): Assert that the LWP's
5355 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
5356 thread create events, leave the new child's status pending.
5357 (linux_low_filter_event): If GDB wants to hear about thread exit
5358 events, leave the LWP marked dead and don't delete it.
5359 (linux_wait_for_event_filtered): Don't check for thread exit.
5360 (filter_exit_event): New function.
5361 (linux_wait_1): Use it, when returning an exit event.
5362 (linux_resume_one_lwp_throw): Assert that the LWP's
5363 waitstatus is TARGET_WAITKIND_IGNORE.
5364 * remote-utils.c (prepare_resume_reply): Handle
5365 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
5366 * server.c (report_thread_events): New global.
5367 (handle_general_set): Handle QThreadEvents.
5368 (handle_query) <qSupported>: Handle and report QThreadEvents+;
5369 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
5370 TARGET_WAITKIND_THREAD_EXITED.
5371 * server.h (report_thread_events): Declare.
5373 2015-11-30 Pedro Alves <palves@redhat.com>
5375 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
5376 the thread's last_resume_kind was resume_stop.
5378 2015-11-30 Pedro Alves <palves@redhat.com>
5380 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
5383 2015-11-30 Pedro Alves <palves@redhat.com>
5385 * server.c (handle_v_requests): Handle vCtrlC.
5387 2015-11-30 Pedro Alves <palves@redhat.com>
5389 * gdbthread.h (find_any_thread_of_pid): Declare.
5390 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
5392 * server.c (handle_query): If current_thread is NULL, look for
5393 another thread of the selected process.
5395 2015-11-26 Daniel Colascione <dancol@dancol.org>
5396 Simon Marchi <simon.marchi@ericsson.com>
5398 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
5399 * server.c (handle_qxfer_threads_worker): Refactor to include thread
5401 * target.h (struct target_ops) <thread_name>: New field.
5402 (target_thread_name): New macro.
5404 2015-11-23 Joel Brobecker <brobecker@adacore.com>
5406 * regcache.h (regcache_invalidate_pid): Add declaration.
5407 * regcache.c (regcache_invalidate_pid): New function, extracted
5408 from regcache_invalidate.
5409 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
5410 Add trivial documentation comment.
5411 * lynx-low.c: Use regcache_invalidate_pid instead of
5412 regcache_invalidate.
5414 2015-11-23 Joel Brobecker <brobecker@adacore.com>
5416 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
5417 and Elf64_auxv_t if the target is Android.
5419 2015-11-22 Doug Evans <xdje42@gmail.com>
5421 * target.h: #include <sys/types.h>.
5423 2015-11-19 Pedro Alves <palves@redhat.com>
5425 * linux-low.c (linux_process_qsupported): Change prototype.
5427 * linux-low.h (struct linux_target_ops) <process_qsupported>:
5429 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
5430 and adjust to loop over all features.
5431 * server.c (handle_query) <qSupported>: Adjust to call
5432 target_process_qsupported once, passing it a vector of unprocessed
5434 * target.h (struct target_ops) <process_qsupported>: Change
5436 (target_process_qsupported): Adjust.
5438 2015-11-19 Pedro Alves <palves@redhat.com>
5440 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
5442 * configure: Regenerate.
5444 2015-11-19 Pedro Alves <palves@redhat.com>
5446 * configure: Regenerate.
5448 2015-11-19 Yao Qi <yao.qi@linaro.org>
5450 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
5453 2015-11-19 Yao Qi <yao.qi@linaro.org>
5455 * linux-aarch64-low.c (enum aarch64_operand_type): New.
5456 (struct aarch64_operand): Move enum out.
5458 2015-11-19 Yao Qi <yao.qi@linaro.org>
5460 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
5461 struct user_fpsimd_state *.
5462 (aarch64_store_fpregset): Likewise.
5464 2015-11-19 Yao Qi <yao.qi@linaro.org>
5466 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
5467 struct user_pt_regs *.
5468 (aarch64_store_gregset): Likewise.
5470 2015-11-18 Pedro Alves <palves@redhat.com>
5472 * Makefile.in (all_object_files): Add $IPA_OBJS.
5474 2015-11-17 Pedro Alves <palves@redhat.com>
5476 * win32-low.c (win32_resume): Use gdb_signal_from_host,
5477 GDB_SIGNAL_0 and gdb_signal_to_string.
5479 2015-11-17 Pedro Alves <palves@redhat.com>
5481 * win32-low.c (handle_output_debug_string): Remove parameter.
5482 (win32_kill): Remove our_status local and adjust call to
5483 handle_output_debug_string.
5484 (get_child_debug_event): Adjust call to
5485 handle_output_debug_string.
5487 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5489 * linux-mips-low.c (mips_fill_gregset): Add cast.
5490 (mips_store_gregset): Likewise.
5491 (mips_fill_fpregset): Likewise.
5492 (mips_store_fpregset): Likewise.
5494 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5496 * linux-mips-low.c (mips_add_watchpoint): Rename private to
5499 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5501 * linux-mips-low.c (mips_linux_new_thread): Change type of
5502 watch_type to enum target_hw_bp_type.
5504 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5506 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
5507 Change return type to arm_hwbp_type.
5509 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5511 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
5512 (arm_store_gregset): Likewise.
5513 * linux-arm-low.c (arm_get_hwcap): Likewise.
5514 (arm_read_description): Likewise.
5516 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5518 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
5520 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5522 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
5523 (ppc_fill_vsxregset): Likewise.
5524 (ppc_store_vsxregset): Likewise.
5525 (ppc_fill_vrregset): Likewise.
5526 (ppc_store_vrregset): Likewise.
5527 (ppc_fill_evrregset): Likewise.
5528 (ppc_store_evrregset): Likewise.
5530 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5532 * linux-ppc-low.c (ppc_usrregs_info): Remove
5533 forward-declaration.
5534 (ppc_arch_setup): Move lower in file.
5536 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
5538 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
5539 (ps_pdwrite): Likewise.
5541 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
5543 * linux-arm-low.c (arm_new_thread): Move pointer dereference
5544 to after assert checks.
5546 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
5548 * proc-service.c (ps_pdread): Add/adjust casts.
5549 (ps_pdwrite): Add/adjust casts.
5551 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5553 * server.c (handle_search_memory_1): Cast return value of
5556 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5558 * server.c (write_qxfer_response): Change type of data to
5561 2015-10-29 Pedro Alves <palves@redhat.com>
5563 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
5565 2015-10-29 Pedro Alves <palves@redhat.com>
5567 * tracepoint.c (clear_installed_tracepoints): Add casts.
5569 2015-10-29 Pedro Alves <palves@redhat.com>
5571 * server.c (handle_v_cont, process_serial_event): Add enum
5572 gdb_signal casts to signal parsing code.
5574 2015-10-29 Pedro Alves <palves@redhat.com>
5576 * linux-low.h (NULL_REGSET): Define.
5577 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5578 * linux-arm-low.c (arm_regsets): Likewise.
5579 * linux-crisv32-low.c (cris_regsets): Likewise.
5580 * linux-m68k-low.c (m68k_regsets): Likewise.
5581 * linux-mips-low.c (mips_regsets): Likewise.
5582 * linux-nios2-low.c (nios2_regsets): Likewise.
5583 * linux-ppc-low.c (ppc_regsets): Likewise.
5584 * linux-s390-low.c (s390_regsets): Likewise.
5585 * linux-sh-low.c (sh_regsets): Likewise.
5586 * linux-sparc-low.c (sparc_regsets): Likewise.
5587 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5588 * linux-tile-low.c (tile_regsets): Likewise.
5589 * linux-x86-low.c (x86_regsets): Likewise.
5590 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5592 2015-10-29 Pedro Alves <palves@redhat.com>
5594 * linux-low.h (NULL_REGSET): Define.
5595 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5596 * linux-arm-low.c (arm_regsets): Likewise.
5597 * linux-crisv32-low.c (cris_regsets): Likewise.
5598 * linux-m68k-low.c (m68k_regsets): Likewise.
5599 * linux-mips-low.c (mips_regsets): Likewise.
5600 * linux-nios2-low.c (nios2_regsets): Likewise.
5601 * linux-ppc-low.c (ppc_regsets): Likewise.
5602 * linux-s390-low.c (s390_regsets): Likewise.
5603 * linux-sh-low.c (sh_regsets): Likewise.
5604 * linux-sparc-low.c (sparc_regsets): Likewise.
5605 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5606 * linux-tile-low.c (tile_regsets): Likewise.
5607 * linux-x86-low.c (x86_regsets): Likewise.
5608 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5610 2015-10-26 Doug Evans <dje@google.com>
5612 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5614 2015-10-26 Doug Evans <dje@google.com>
5616 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5618 2015-10-26 Doug Evans <dje@google.com>
5620 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5622 (attach_thread, find_new_threads_callback): Ditto.
5624 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5626 * mem-break.h (set_breakpoint_data): Remove.
5628 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5630 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5631 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5632 (initialize_low): Remove set_breakpoint_data call.
5633 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5634 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5635 (initialize_low): Remove set_breakpoint_data call.
5636 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5637 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5638 (initialize_low): Remove set_breakpoint_data call.
5640 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5642 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5643 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5644 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5645 * target.h (target_breakpoint_kind_from_pc): New macro.
5647 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5649 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5650 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5651 the default breakpoint kind.
5653 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5655 * linux-arm-low.c (arm_supports_z_point_type): Add software
5658 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5660 * linux-arm-low.c: Refactor breakpoint definitions.
5661 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5662 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5664 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5666 * Makefile.in: Add arm.c/o.
5667 * configure.srv: Likewise.
5668 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5669 (arm_breakpoint_kind_from_pc): New function.
5670 (arm_sw_breakpoint_from_kind): Return proper kind.
5671 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5673 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5675 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5677 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5678 (struct raw_breakpoint) <size>: Remove.
5679 (struct raw_breakpoint) <kind>: Add.
5680 (bp_size): New function.
5681 (bp_opcode): Likewise.
5682 (find_raw_breakpoint_at): Adjust for kind.
5683 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5684 (remove_memory_breakpoint): Adjust for kind call bp_size.
5685 (set_raw_breakpoint_at): Adjust for kind.
5686 (set_breakpoint): Likewise.
5687 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5688 (delete_raw_breakpoint): Adjust for kind.
5689 (delete_breakpoint): Likewise.
5690 (find_gdb_breakpoint): Likewise.
5691 (set_gdb_breakpoint_1): Likewise.
5692 (set_gdb_breakpoint): Likewise.
5693 (delete_gdb_breakpoint_1): Likewise.
5694 (delete_gdb_breakpoint): Likewise.
5695 (uninsert_raw_breakpoint): Likewise.
5696 (reinsert_raw_breakpoint): Likewise.
5697 (set_breakpoint_data): Remove.
5698 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5699 (check_mem_read): Adjust for kind call bp_size.
5700 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5701 (clone_one_breakpoint): Adjust for kind.
5702 * mem-break.h (set_gdb_breakpoint): Likewise.
5703 (delete_gdb_breakpoint): Likewise.
5704 * server.c (process_serial_event): Likewise.
5706 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5708 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5709 (struct linux_target_ops) <breakpoint>: Remove.
5710 (struct linux_target_ops) <breakpoint_len>: Remove.
5711 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5712 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5713 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5714 (arm_sw_breakpoint_from_kind): New function.
5715 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
5716 (struct linux_target_ops) <breakpoint>: Remove.
5717 (struct linux_target_ops) <breakpoint_len>: Remove.
5718 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5719 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5720 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
5721 (struct linux_target_ops) <breakpoint>: Remove.
5722 (struct linux_target_ops) <breakpoint_len>: Remove.
5723 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5724 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5725 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5726 (struct linux_target_ops) <breakpoint>: Remove.
5727 (struct linux_target_ops) <breakpoint_len>: Remove.
5728 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5729 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5730 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5731 and sw_breakpoint_from_kind to increment the pc.
5732 (linux_breakpoint_kind_from_pc): New function.
5733 (linux_sw_breakpoint_from_kind): New function.
5734 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5735 (initialize_low): Call breakpoint_kind_from_pc and
5736 sw_breakpoint_from_kind to replace breakpoint_data/len.
5737 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5739 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5740 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
5741 (struct linux_target_ops) <breakpoint>: Remove.
5742 (struct linux_target_ops) <breakpoint_len>: Remove.
5743 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5744 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5745 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
5746 (struct linux_target_ops) <breakpoint>: Remove.
5747 (struct linux_target_ops) <breakpoint_len>: Remove.
5748 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5749 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5750 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
5751 (struct linux_target_ops) <breakpoint>: Remove.
5752 (struct linux_target_ops) <breakpoint_len>: Remove.
5753 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5754 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5755 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
5756 (struct linux_target_ops) <breakpoint>: Remove.
5757 (struct linux_target_ops) <breakpoint_len>: Remove.
5758 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5759 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5760 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
5761 (struct linux_target_ops) <breakpoint>: Remove.
5762 (struct linux_target_ops) <breakpoint_len>: Remove.
5763 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5764 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5765 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
5766 (struct linux_target_ops) <breakpoint>: Remove.
5767 (struct linux_target_ops) <breakpoint_len>: Remove.
5768 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5769 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5770 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
5771 (struct linux_target_ops) <breakpoint>: Remove.
5772 (struct linux_target_ops) <breakpoint_len>: Remove.
5773 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5774 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5775 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
5776 (struct linux_target_ops) <breakpoint>: Remove.
5777 (struct linux_target_ops) <breakpoint_len>: Remove.
5778 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5779 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5780 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
5781 (struct linux_target_ops) <breakpoint>: Remove.
5782 (struct linux_target_ops) <breakpoint_len>: Remove.
5783 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5784 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5785 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5786 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
5787 (struct linux_target_ops) <breakpoint>: Remove.
5788 (struct linux_target_ops) <breakpoint_len>: Remove.
5789 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5790 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5791 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5792 (struct linux_target_ops) <breakpoint>: Remove.
5793 (struct linux_target_ops) <breakpoint_len>: Remove.
5794 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5795 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5797 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5799 * linux-cris-low.c (cris_get_pc): Remove void arg.
5801 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5803 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5806 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5808 * inferiors.c (thread_pid_matches_callback): New function.
5809 (find_thread_process): New function.
5810 (remove_thread): Reset current_thread.
5811 (remove_process): Assert threads have been removed first.
5813 2015-10-15 Yao Qi <yao.qi@linaro.org>
5815 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5817 (aarch64_remove_point): Likewise.
5818 * regcache.c (regcache_register_size): New function.
5820 2015-10-12 Yao Qi <yao.qi@linaro.org>
5822 * linux-aarch64-low.c: Update all callers as emit_load_store
5823 is renamed to aarch64_emit_load_store.
5825 2015-10-12 Yao Qi <yao.qi@linaro.org>
5827 * linux-aarch64-low.c: Update all callers of function renaming
5828 from emit_insn to aarch64_emit_insn.
5830 2015-10-12 Yao Qi <yao.qi@linaro.org>
5832 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5833 arch/aarch64-insn.h.
5834 (struct aarch64_memory_operand): Likewise.
5836 (emit_insn): Move to arch/aarch64-insn.c.
5837 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5838 (emit_load_store): Move to arch/aarch64-insn.c.
5839 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5840 (can_encode_int32): Remove.
5842 2015-10-12 Yao Qi <yao.qi@linaro.org>
5844 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5845 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5846 (aarch64_relocate_instruction): Likewise.
5847 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5848 (struct aarch64_insn_visitor): Likewise.
5850 2015-10-12 Yao Qi <yao.qi@linaro.org>
5852 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5853 (struct aarch64_insn_visitor): New.
5854 (struct aarch64_insn_relocation_data): New.
5855 (aarch64_ftrace_insn_reloc_b): New function.
5856 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5857 (aarch64_ftrace_insn_reloc_cb): Likewise.
5858 (aarch64_ftrace_insn_reloc_tb): Likewise.
5859 (aarch64_ftrace_insn_reloc_adr): Likewise.
5860 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5861 (aarch64_ftrace_insn_reloc_others): Likewise.
5863 (aarch64_relocate_instruction): Use visitor.
5865 2015-10-12 Yao Qi <yao.qi@linaro.org>
5867 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5868 int. Add argument buf.
5869 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5870 aarch64_relocate_instruction.
5872 2015-10-12 Yao Qi <yao.qi@linaro.org>
5874 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5875 argument insn. Remove local variable insn. Don't call
5877 (aarch64_install_fast_tracepoint_jump_pad): Call
5880 2015-09-30 Yao Qi <yao.qi@linaro.org>
5882 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5883 (emit_load_store_pair): Likewise.
5885 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5887 * dll.c (match_dll): Add cast(s).
5888 (unloaded_dll): Likewise.
5889 * linux-low.c (second_thread_of_pid_p): Likewise.
5890 (delete_lwp_callback): Likewise.
5891 (count_events_callback): Likewise.
5892 (select_event_lwp_callback): Likewise.
5893 (linux_set_resume_request): Likewise.
5894 * server.c (accumulate_file_name_length): Likewise.
5895 (emit_dll_description): Likewise.
5896 (handle_qxfer_threads_worker): Likewise.
5897 (visit_actioned_threads): Likewise.
5898 * thread-db.c (any_thread_of): Likewise.
5899 * tracepoint.c (same_process_p): Likewise.
5900 (match_blocktype): Likewise.
5901 (build_traceframe_info_xml): Likewise.
5903 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5905 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5907 (gdb_unparse_agent_expr): Likewise.
5908 * hostio.c (require_data): Likewise.
5909 (handle_pread): Likewise.
5910 * linux-low.c (disable_regset): Likewise.
5911 (fetch_register): Likewise.
5912 (store_register): Likewise.
5913 (get_dynamic): Likewise.
5914 (linux_qxfer_libraries_svr4): Likewise.
5915 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5916 (set_fast_tracepoint_jump): Likewise.
5917 (uninsert_fast_tracepoint_jumps_at): Likewise.
5918 (reinsert_fast_tracepoint_jumps_at): Likewise.
5919 (validate_inserted_breakpoint): Likewise.
5920 (clone_agent_expr): Likewise.
5921 * regcache.c (init_register_cache): Likewise.
5922 * remote-utils.c (putpkt_binary_1): Likewise.
5923 (decode_M_packet): Likewise.
5924 (decode_X_packet): Likewise.
5925 (look_up_one_symbol): Likewise.
5926 (relocate_instruction): Likewise.
5927 (monitor_output): Likewise.
5928 * server.c (handle_search_memory): Likewise.
5929 (handle_qxfer_exec_file): Likewise.
5930 (handle_qxfer_libraries): Likewise.
5931 (handle_qxfer): Likewise.
5932 (handle_query): Likewise.
5933 (handle_v_cont): Likewise.
5934 (handle_v_run): Likewise.
5935 (captured_main): Likewise.
5936 * target.c (write_inferior_memory): Likewise.
5937 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5938 * tracepoint.c (init_trace_buffer): Likewise.
5939 (add_tracepoint_action): Likewise.
5940 (add_traceframe): Likewise.
5941 (add_traceframe_block): Likewise.
5942 (cmd_qtdpsrc): Likewise.
5943 (cmd_qtdv): Likewise.
5944 (cmd_qtstatus): Likewise.
5945 (response_source): Likewise.
5946 (response_tsv): Likewise.
5947 (cmd_qtnotes): Likewise.
5948 (gdb_collect): Likewise.
5949 (initialize_tracepoint): Likewise.
5951 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5953 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5954 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5955 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5957 (enum aarch64_condition_codes): New enum.
5958 (w0): New static global.
5961 (struct aarch64_memory_operand) <type>: New
5962 MEMORY_OPERAND_POSTINDEX type.
5963 (postindex_memory_operand): New helper function.
5964 (emit_ret): New function.
5965 (emit_load_store_pair): New function, factored out of emit_stp
5966 with support for MEMORY_OPERAND_POSTINDEX.
5967 (emit_stp): Rewrite using emit_load_store_pair.
5968 (emit_ldp): New function.
5969 (emit_load_store): Likewise.
5970 (emit_ldr): Mention post-index instruction in comment.
5971 (emit_ldrh): New function.
5972 (emit_ldrb): New function.
5973 (emit_ldrsw): Mention post-index instruction in comment.
5974 (emit_str): Likewise.
5975 (emit_subs): New function.
5976 (emit_cmp): Likewise.
5977 (emit_and): Likewise.
5978 (emit_orr): Likewise.
5979 (emit_orn): Likewise.
5980 (emit_eor): Likewise.
5981 (emit_mvn): Likewise.
5982 (emit_lslv): Likewise.
5983 (emit_lsrv): Likewise.
5984 (emit_asrv): Likewise.
5985 (emit_mul): Likewise.
5986 (emit_sbfm): Likewise.
5987 (emit_sbfx): Likewise.
5988 (emit_ubfm): Likewise.
5989 (emit_ubfx): Likewise.
5990 (emit_csinc): Likewise.
5991 (emit_cset): Likewise.
5992 (emit_nop): Likewise.
5993 (emit_ops_insns): New helper function.
5994 (emit_pop): Likewise.
5995 (emit_push): Likewise.
5996 (aarch64_emit_prologue): New function.
5997 (aarch64_emit_epilogue): Likewise.
5998 (aarch64_emit_add): Likewise.
5999 (aarch64_emit_sub): Likewise.
6000 (aarch64_emit_mul): Likewise.
6001 (aarch64_emit_lsh): Likewise.
6002 (aarch64_emit_rsh_signed): Likewise.
6003 (aarch64_emit_rsh_unsigned): Likewise.
6004 (aarch64_emit_ext): Likewise.
6005 (aarch64_emit_log_not): Likewise.
6006 (aarch64_emit_bit_and): Likewise.
6007 (aarch64_emit_bit_or): Likewise.
6008 (aarch64_emit_bit_xor): Likewise.
6009 (aarch64_emit_bit_not): Likewise.
6010 (aarch64_emit_equal): Likewise.
6011 (aarch64_emit_less_signed): Likewise.
6012 (aarch64_emit_less_unsigned): Likewise.
6013 (aarch64_emit_ref): Likewise.
6014 (aarch64_emit_if_goto): Likewise.
6015 (aarch64_emit_goto): Likewise.
6016 (aarch64_write_goto_address): Likewise.
6017 (aarch64_emit_const): Likewise.
6018 (aarch64_emit_call): Likewise.
6019 (aarch64_emit_reg): Likewise.
6020 (aarch64_emit_pop): Likewise.
6021 (aarch64_emit_stack_flush): Likewise.
6022 (aarch64_emit_zero_ext): Likewise.
6023 (aarch64_emit_swap): Likewise.
6024 (aarch64_emit_stack_adjust): Likewise.
6025 (aarch64_emit_int_call_1): Likewise.
6026 (aarch64_emit_void_call_2): Likewise.
6027 (aarch64_emit_eq_goto): Likewise.
6028 (aarch64_emit_ne_goto): Likewise.
6029 (aarch64_emit_lt_goto): Likewise.
6030 (aarch64_emit_le_goto): Likewise.
6031 (aarch64_emit_gt_goto): Likewise.
6032 (aarch64_emit_ge_got): Likewise.
6033 (aarch64_emit_ops_impl): New static global variable.
6034 (aarch64_emit_ops): New target function, return
6035 &aarch64_emit_ops_impl.
6036 (struct linux_target_ops): Install it.
6038 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6040 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
6041 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
6043 * linux-aarch64-ipa.c: New file.
6044 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
6046 (aarch64_get_thread_area): New target method.
6047 (extract_signed_bitfield): New helper function.
6048 (aarch64_decode_ldr_literal): New function.
6049 (enum aarch64_opcodes): New enum.
6050 (struct aarch64_register): New struct.
6051 (struct aarch64_operand): New struct.
6052 (x0): New static global.
6061 (aarch64_register): New helper function.
6062 (register_operand): Likewise.
6063 (immediate_operand): Likewise.
6064 (struct aarch64_memory_operand): New struct.
6065 (offset_memory_operand): New helper function.
6066 (preindex_memory_operand): Likewise.
6067 (enum aarch64_system_control_registers): New enum.
6068 (ENCODE): New macro.
6069 (emit_insn): New helper function.
6070 (emit_b): New function.
6071 (emit_bcond): Likewise.
6072 (emit_cb): Likewise.
6073 (emit_tb): Likewise.
6074 (emit_blr): Likewise.
6075 (emit_stp): Likewise.
6076 (emit_ldp_q_offset): Likewise.
6077 (emit_stp_q_offset): Likewise.
6078 (emit_load_store): Likewise.
6079 (emit_ldr): Likewise.
6080 (emit_ldrsw): Likewise.
6081 (emit_str): Likewise.
6082 (emit_ldaxr): Likewise.
6083 (emit_stxr): Likewise.
6084 (emit_stlr): Likewise.
6085 (emit_data_processing_reg): Likewise.
6086 (emit_data_processing): Likewise.
6087 (emit_add): Likewise.
6088 (emit_sub): Likewise.
6089 (emit_mov): Likewise.
6090 (emit_movk): Likewise.
6091 (emit_mov_addr): Likewise.
6092 (emit_mrs): Likewise.
6093 (emit_msr): Likewise.
6094 (emit_sevl): Likewise.
6095 (emit_wfe): Likewise.
6096 (append_insns): Likewise.
6097 (can_encode_int32_in): New helper function.
6098 (aarch64_relocate_instruction): New function.
6099 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
6100 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
6101 (struct linux_target_ops): Install aarch64_get_thread_area,
6102 aarch64_install_fast_tracepoint_jump_pad and
6103 aarch64_get_min_fast_tracepoint_insn_len.
6105 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
6107 * Makefile.in (aarch64-insn.o): New rule.
6108 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
6110 2015-09-21 Yao Qi <yao.qi@linaro.org>
6112 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
6114 2015-09-21 Yao Qi <yao.qi@linaro.org>
6116 * tracepoint.c (max_jump_pad_size): Remove.
6118 2015-09-18 Yao Qi <yao.qi@linaro.org>
6120 * linux-aarch64-low.c: Don't include sys/uio.h.
6121 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
6123 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
6125 * tracepoint.c (eval_result_type): Change prototype.
6126 (condition_true_at_tracepoint): Fix argument to compiled_cond.
6128 2015-09-15 Pedro Alves <palves@redhat.com>
6130 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
6131 Check whether to report exec events instead of checking whether
6132 multiprocess is enabled.
6134 2015-09-15 Pedro Alves <palves@redhat.com>
6137 * remote-utils.c (prepare_resume_reply): Merge
6138 TARGET_WAITKIND_VFORK_DONE switch case with the
6139 TARGET_WAITKIND_FORKED case.
6141 2015-09-15 Yao Qi <yao.qi@linaro.org>
6143 * server.c (handle_query): Check string comparison using
6144 "else if" instead of "if".
6146 2015-09-15 Yao Qi <yao.qi@linaro.org>
6148 * server.c (vCont_supported): New global variable.
6149 (handle_query): Set vCont_supported to 1 if "vContSupported+"
6150 matches. Append ";vContSupported+" to own_buf.
6151 (handle_v_requests): Append ";s;S" to own_buf if target supports
6152 hardware single step or vCont_supported is false.
6153 (capture_main): Set vCont_supported to zero.
6155 2015-09-15 Yao Qi <yao.qi@linaro.org>
6157 * linux-low.c (linux_supports_conditional_breakpoints): Rename
6159 (linux_supports_hardware_single_step): ... New function.
6160 (linux_target_ops): Update.
6161 * lynx-low.c (lynx_target_ops): Set field
6162 supports_hardware_single_step to target_can_do_hardware_single_step.
6163 * nto-low.c (nto_target_ops): Likewise.
6164 * spu-low.c (spu_target_ops): Likewise.
6165 * win32-low.c (win32_target_ops): Likewise.
6166 * target.c (target_can_do_hardware_single_step): New function.
6167 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6168 Remove. <supports_hardware_single_step>: New field.
6169 (target_supports_conditional_breakpoints): Remove.
6170 (target_supports_hardware_single_step): New macro.
6171 (target_can_do_hardware_single_step): Declare.
6172 * server.c (handle_query): Use target_supports_hardware_single_step
6173 instead of target_supports_conditional_breakpoints.
6175 2015-09-15 Yao Qi <yao.qi@linaro.org>
6177 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
6179 (struct linux_target_ops the_low_target): Install
6180 aarch64_linux_siginfo_fixup.
6182 2015-09-11 Don Breazeal <donb@codesourcery.com>
6183 Luis Machado <lgustavo@codesourcery.com>
6185 * linux-low.c (linux_mourn): Static declaration.
6186 (linux_arch_setup): Move in front of
6187 handle_extended_wait.
6188 (linux_arch_setup_thread): New function.
6189 (handle_extended_wait): Handle exec events. Call
6190 linux_arch_setup_thread. Make event_lwp argument a
6191 pointer-to-a-pointer.
6192 (check_zombie_leaders): Do not check stopped threads.
6193 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
6194 (linux_low_filter_event): Add lwp and thread for exec'ing
6195 non-leader thread if leader thread has been deleted.
6196 Refactor code into linux_arch_setup_thread and call it.
6197 Pass child lwp pointer by reference to handle_extended_wait.
6198 (linux_wait_for_event_filtered): Update comment.
6199 (linux_wait_1): Prevent clobbering exec event status.
6200 (linux_supports_exec_events): New function.
6201 (linux_target_ops) <supports_exec_events>: Initialize new member.
6202 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
6204 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
6205 * server.c (report_exec_events): New global variable.
6206 (handle_query): Handle qSupported query for exec-events feature.
6207 (captured_main): Initialize report_exec_events.
6208 * server.h (report_exec_events): Declare new global variable.
6209 * target.h (struct target_ops) <supports_exec_events>: New
6211 (target_supports_exec_events): New macro.
6212 * win32-low.c (win32_target_ops) <supports_exec_events>:
6213 Initialize new member.
6215 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
6217 * linux-low.c (linux_low_enable_btrace): Remove.
6218 (linux_target_ops): Replace linux_low_enable_btrace with
6219 linux_enable_btrace.
6221 2015-09-03 Yao Qi <yao.qi@linaro.org>
6223 * linux-aarch64-low.c (aarch64_insert_point): Call
6224 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
6227 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
6229 * linux-low.c (check_stopped_by_breakpoint): Use
6230 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
6232 2015-08-27 Pedro Alves <palves@redhat.com>
6234 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
6236 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
6238 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
6239 the XNEW-family equivalent.
6240 (compile_bytecodes): Likewise.
6241 * dll.c (loaded_dll): Likewise.
6242 * event-loop.c (append_callback_event): Likewise.
6243 (create_file_handler): Likewise.
6244 (create_file_event): Likewise.
6245 * hostio.c (handle_open): Likewise.
6246 * inferiors.c (add_thread): Likewise.
6247 (add_process): Likewise.
6248 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
6249 * linux-arm-low.c (arm_new_process): Likewise.
6250 (arm_new_thread): Likewise.
6251 * linux-low.c (add_to_pid_list): Likewise.
6252 (linux_add_process): Likewise.
6253 (handle_extended_wait): Likewise.
6254 (add_lwp): Likewise.
6255 (enqueue_one_deferred_signal): Likewise.
6256 (enqueue_pending_signal): Likewise.
6257 (linux_resume_one_lwp_throw): Likewise.
6258 (linux_resume_one_thread): Likewise.
6259 (linux_read_memory): Likewise.
6260 (linux_write_memory): Likewise.
6261 * linux-mips-low.c (mips_linux_new_process): Likewise.
6262 (mips_linux_new_thread): Likewise.
6263 (mips_add_watchpoint): Likewise.
6264 * linux-x86-low.c (initialize_low_arch): Likewise.
6265 * lynx-low.c (lynx_add_process): Likewise.
6266 * mem-break.c (set_raw_breakpoint_at): Likewise.
6267 (set_breakpoint): Likewise.
6268 (add_condition_to_breakpoint): Likewise.
6269 (add_commands_to_breakpoint): Likewise.
6270 (clone_agent_expr): Likewise.
6271 (clone_one_breakpoint): Likewise.
6272 * regcache.c (new_register_cache): Likewise.
6273 * remote-utils.c (look_up_one_symbol): Likewise.
6274 * server.c (queue_stop_reply): Likewise.
6275 (start_inferior): Likewise.
6276 (queue_stop_reply_callback): Likewise.
6277 (handle_target_event): Likewise.
6278 * spu-low.c (fetch_ppc_memory): Likewise.
6279 (store_ppc_memory): Likewise.
6280 * target.c (set_target_ops): Likewise.
6281 * thread-db.c (thread_db_load_search): Likewise.
6282 (try_thread_db_load_1): Likewise.
6283 * tracepoint.c (add_tracepoint): Likewise.
6284 (add_tracepoint_action): Likewise.
6285 (create_trace_state_variable): Likewise.
6286 (cmd_qtdpsrc): Likewise.
6287 (cmd_qtro): Likewise.
6288 (add_while_stepping_state): Likewise.
6289 * win32-low.c (child_add_thread): Likewise.
6290 (get_image_name): Likewise.
6292 2015-08-25 Yao Qi <yao.qi@linaro.org>
6294 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
6296 2015-08-25 Yao Qi <yao.qi@linaro.org>
6298 * Makefile.in (aarch64-linux.o): New rule.
6299 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
6301 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
6302 (aarch64_init_debug_reg_state): Make it extern.
6303 (aarch64_linux_prepare_to_resume): Remove.
6305 2015-08-25 Yao Qi <yao.qi@linaro.org>
6307 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
6308 lwp_arch_private_info and ptid_of_lwp.
6310 2015-08-25 Yao Qi <yao.qi@linaro.org>
6312 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
6313 Find proc_info by find_process_pid. All callers updated.
6315 2015-08-25 Yao Qi <yao.qi@linaro.org>
6317 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
6319 (debug_reg_change_callback): Remove.
6320 (aarch64_notify_debug_reg_change): Remove.
6322 2015-08-25 Yao Qi <yao.qi@linaro.org>
6324 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
6325 Call current_lwp_ptid.
6327 2015-08-25 Yao Qi <yao.qi@linaro.org>
6329 * linux-aarch64-low.c (debug_reg_change_callback): Use
6332 2015-08-25 Yao Qi <yao.qi@linaro.org>
6334 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
6336 2015-08-25 Yao Qi <yao.qi@linaro.org>
6338 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
6340 2015-08-25 Yao Qi <yao.qi@linaro.org>
6342 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
6345 2015-08-25 Yao Qi <yao.qi@linaro.org>
6347 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
6349 (debug_reg_change_callback): Remove argument entry and add argument
6350 lwp. Remove local variable thread. Don't print thread id in the
6351 debugging output. Don't check whether pid of thread equals to pid.
6352 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
6353 iterate_over_lwps instead find_inferior.
6355 2015-08-24 Pedro Alves <palves@redhat.com>
6357 * inferiors.c (get_first_process): New function.
6358 * inferiors.h (get_first_process): New declaration.
6359 * remote-utils.c (read_ptid): Default to the first process in the
6360 list, instead of to the current thread's process.
6362 2015-08-24 Pedro Alves <palves@redhat.com>
6364 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
6365 * event-loop.c: Likewise.
6366 * remote-utils.c: Likewise.
6367 * tracepoint.c: Likewise.
6369 2015-08-24 Pedro Alves <palves@redhat.com>
6371 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
6374 2015-08-21 Pedro Alves <palves@redhat.com>
6376 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
6377 instead of literal 1.
6379 2015-08-21 Pedro Alves <palves@redhat.com>
6381 * tdesc.c (default_description): Explicitly zero-initialize.
6383 2015-08-21 Pedro Alves <palves@redhat.com>
6386 * inferiors.c (remove_thread): Discard any pending stop reply for
6388 * server.c (remove_all_on_match_pid): Rename to ...
6389 (remove_all_on_match_ptid): ... this. Work with a filter ptid
6391 (discard_queued_stop_replies): Change parameter to a ptid. Now
6393 (handle_v_kill, kill_inferior_callback, captured_main)
6394 (process_serial_event): Adjust.
6395 * server.h (discard_queued_stop_replies): Declare.
6397 2015-08-21 Pedro Alves <palves@redhat.com>
6399 * linux-low.c (wait_for_sigstop): Always switch to no thread
6400 selected if the previously current thread dies.
6401 * lynx-low.c (lynx_request_interrupt): Use the first thread's
6402 process instead of the current thread's.
6403 * remote-utils.c (input_interrupt): Don't check if there's no
6405 * server.c (gdb_read_memory, gdb_write_memory): If setting the
6406 current thread to the general thread fails, error out.
6407 (handle_qxfer_auxv, handle_qxfer_libraries)
6408 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
6409 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
6410 (handle_query): Check if there's a thread selected instead of
6411 checking whether there's any thread in the thread list.
6412 (handle_qxfer_threads, handle_qxfer_btrace)
6413 (handle_qxfer_btrace_conf): Don't error out early if there's no
6414 thread in the thread list.
6415 (handle_v_cont, myresume): Don't set the current thread to the
6417 (process_serial_event) <Hg handling>: Also set thread_id if the
6418 previous general thread is still alive.
6419 (process_serial_event) <g/G handling>: If setting the current
6420 thread to the general thread fails, error out.
6421 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
6422 thread's lwp instead of the current thread's.
6423 * target.c (set_desired_thread): If the desired thread was not
6424 found, leave the current thread pointing to NULL. Return an int
6425 (boolean) indicating success.
6426 * target.h (set_desired_thread): Change return type to int.
6428 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
6430 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
6431 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
6433 (ps_get_thread_area): New function.
6435 2015-08-19 Gary Benson <gbenson@redhat.com>
6437 * hostio.c (handle_pread): Do not attempt to read more data
6438 than hostio_reply_with_data can fit in a packet.
6440 2015-08-18 Joel Brobecker <brobecker@adacore.com>
6442 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
6444 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
6446 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
6448 2015-08-06 Pedro Alves <palves@redhat.com>
6450 * tracepoint.c (expr_eval_result): Now an int.
6452 2015-08-06 Pedro Alves <palves@redhat.com>
6454 * gdbthread.h (struct regcache): Forward declare.
6455 (struct thread_info) <regcache_data>: Now a struct regcache
6457 * inferiors.c (inferior_regcache_data)
6458 (set_inferior_regcache_data): Now work with struct regcache
6460 * inferiors.h (struct regcache): Forward declare.
6461 (inferior_regcache_data, set_inferior_regcache_data): Now work
6462 with struct regcache pointers.
6463 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
6464 (free_register_cache_thread): Remove struct regcache pointer
6467 2015-08-06 Pedro Alves <palves@redhat.com>
6469 * server.c (captured_main): On error, print the exception message
6470 to stderr, and if run_once is set, throw a quit.
6472 2015-08-06 Pedro Alves <palves@redhat.com>
6474 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
6477 2015-08-06 Pedro Alves <palves@redhat.com>
6479 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
6480 reading beyond the passed in buffer length.
6482 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
6484 * tracepoint.c (symbol_list) <required>: Remove.
6486 2015-08-06 Pedro Alves <palves@redhat.com>
6488 * linux-low.c (handle_extended_wait): Set the fork child's suspend
6489 count if stopping and suspending threads.
6490 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
6491 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
6492 (linux_detach): Complete an ongoing step-over.
6493 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
6495 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
6496 (linux_wait_1): If passing a signal to the inferior after
6497 finishing a step-over, unsuspend and re-resume all lwps. If we
6498 see a single-step event but the thread should be continuing, don't
6499 pass the trap to gdb.
6500 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
6501 internal_error instead of gdb_assert.
6502 (enqueue_pending_signal): New function.
6503 (check_ptrace_stopped_lwp_gone): Add debug output.
6504 (start_step_over): Use internal_error instead of gdb_assert.
6505 (complete_ongoing_step_over): New function.
6506 (linux_resume_one_thread): Don't resume a suspended thread.
6507 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
6510 2015-08-06 Pedro Alves <palves@redhat.com>
6512 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
6513 (linux_thread_alive): Use lwp_is_marked_dead.
6514 (extended_event_reported): Delete.
6515 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
6516 instead of extended_event_reported.
6517 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
6519 (lwp_is_marked_dead): New function.
6520 (lwp_running): Use lwp_is_marked_dead.
6521 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
6524 2015-08-06 Pedro Alves <palves@redhat.com>
6526 * linux-low.c (linux_wait_1): Move fork event output out of the
6527 !report_to_gdb check. Pass event_child->waitstatus to
6528 target_waitstatus_to_string instead of ourstatus.
6530 2015-08-04 Yao Qi <yao.qi@linaro.org>
6532 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
6533 if current_thread is 32 bit.
6535 2015-08-04 Yao Qi <yao.qi@linaro.org>
6537 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6538 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6539 * server.c (extended_protocol): Remove "static".
6540 * server.h (extended_protocol): Declare it.
6542 2015-08-04 Yao Qi <yao.qi@linaro.org>
6544 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
6545 both aarch64 and aarch32.
6546 (aarch64_set_pc): Likewise.
6548 2015-08-04 Yao Qi <yao.qi@linaro.org>
6550 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
6551 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
6552 arm-with-neon.xml to srv_xmlfiles.
6553 * linux-aarch64-low.c: Include linux-aarch32-low.h.
6554 (is_64bit_tdesc): New function.
6555 (aarch64_linux_read_description): New function.
6556 (aarch64_arch_setup): Call aarch64_linux_read_description.
6557 (regs_info): Rename to regs_info_aarch64.
6558 (aarch64_regs_info): Return right regs_info.
6559 (initialize_low_arch): Call initialize_low_arch_aarch32.
6561 2015-08-04 Yao Qi <yao.qi@linaro.org>
6563 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
6564 * linux-aarch32-low.c: New file.
6565 * linux-aarch32-low.h: New file.
6566 * linux-arm-low.c (arm_fill_gregset): Move it to
6567 linux-aarch32-low.c.
6568 (arm_store_gregset): Likewise.
6569 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
6570 (arm_store_vfpregset): Call arm_store_vfpregset_num.
6571 (arm_arch_setup): Check if PTRACE_GETREGSET works.
6572 (regs_info): Rename to regs_info_arm.
6573 (arm_regs_info): Return regs_info_aarch32 if
6574 have_ptrace_getregset is 1 and target description is
6575 arm_with_neon or arm_with_vfpv3.
6576 (initialize_low_arch): Don't call init_registers_arm_with_neon.
6577 Call initialize_low_arch_aarch32 instead.
6579 2015-08-04 Yao Qi <yao.qi@linaro.org>
6581 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
6582 * linux-low.c: ... here.
6583 * linux-low.h (have_ptrace_getregset): Declare it.
6585 2015-08-04 Pedro Alves <palves@redhat.com>
6587 * thread-db.c (struct thread_db): Use new typedefs.
6588 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6590 (disable_thread_event_reporting): Cast result of dlsym to
6591 destination function pointer type.
6592 (thread_db_mourn): Use td_ta_delete_ftype.
6594 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6596 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6598 (CDX_BREAKPOINT): Define for R2.
6599 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6600 (the_low_target): Add comments.
6602 2015-07-30 Yao Qi <yao.qi@linaro.org>
6604 * linux-arm-low.c (arm_hwcap): Remove it.
6605 (arm_read_description): New local variable arm_hwcap. Don't
6606 set arm_hwcap to zero.
6608 2015-07-30 Yao Qi <yao.qi@linaro.org>
6610 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6611 Use regcache->tdesc instead.
6612 (arm_store_wmmxregset): Likewise.
6613 (arm_fill_vfpregset): Likewise.
6614 (arm_store_vfpregset): Likewise.
6616 2015-07-30 Yao Qi <yao.qi@linaro.org>
6618 * linux-arm-low.c: Include arch/arm.h.
6619 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6620 (arm_store_gregset): Likewise.
6622 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6624 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6625 ptrace's 4th parameter.
6627 2015-07-27 Yao Qi <yao.qi@linaro.org>
6629 * configure.srv (case aarch64*-*-linux*): Don't set
6632 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6634 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6636 * linux-arm-low.c: Likewise.
6637 * linux-cris-low.c: Likewise.
6638 * linux-crisv32-low.c: Likewise.
6639 * linux-low.c: Likewise.
6640 * linux-m68k-low.c: Likewise.
6641 * linux-mips-low.c: Likewise.
6642 * linux-nios2-low.c: Likewise.
6643 * linux-s390-low.c: Likewise.
6644 * linux-sparc-low.c: Likewise.
6645 * linux-tic6x-low.c: Likewise.
6646 * linux-tile-low.c: Likewise.
6647 * linux-x86-low.c: Likewise.
6649 2015-07-24 Pedro Alves <palves@redhat.com>
6651 * config.in: Regenerate.
6652 * configure: Regenerate.
6654 2015-07-24 Pedro Alves <palves@redhat.com>
6656 * acinclude.m4: Include ../ptrace.m4.
6657 * configure.ac: Call GDB_AC_PTRACE.
6658 * config.in, configure: Regenerate.
6660 2015-07-24 Yao Qi <yao.qi@linaro.org>
6662 * linux-low.c (linux_create_inferior): Remove setting to
6663 proc->priv->new_inferior.
6664 (linux_attach): Likewise.
6665 (linux_low_filter_event): Likewise.
6666 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6668 2015-07-24 Yao Qi <yao.qi@linaro.org>
6670 * linux-low.c (linux_arch_setup): New function.
6671 (linux_low_filter_event): If proc->tdesc is NULL and
6672 proc->attached is true, call the_low_target.arch_setup.
6673 Otherwise, keep status pending, and return.
6674 (linux_resume_one_lwp_throw): Don't call get_pc if
6675 thread->while_stepping isn't NULL. Don't call
6676 get_thread_regcache if proc->tdesc is NULL.
6677 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6678 (linux_target_ops): Install arch_setup.
6679 * server.c (start_inferior): Call the_target->arch_setup.
6680 * target.h (struct target_ops) <arch_setup>: New field.
6681 (target_arch_setup): New marco.
6682 * lynx-low.c (lynx_target_ops): Update.
6683 * nto-low.c (nto_target_ops): Update.
6684 * spu-low.c (spu_target_ops): Update.
6685 * win32-low.c (win32_target_ops): Update.
6687 2015-07-24 Yao Qi <yao.qi@linaro.org>
6689 * linux-low.c (linux_add_process): Don't set
6690 proc->priv->new_inferior.
6691 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6692 (linux_attach): Likewise.
6694 2015-07-24 Yao Qi <yao.qi@linaro.org>
6696 * server.c (start_inferior): Code refactor.
6698 2015-07-24 Yao Qi <yao.qi@linaro.org>
6700 * server.c (process_serial_event): Set general_thread.
6702 2015-07-21 Yao Qi <yao.qi@linaro.org>
6704 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6705 aarch64_linux_get_debug_reg_capacity.
6707 2015-07-17 Yao Qi <yao.qi@linaro.org>
6709 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6710 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6711 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6712 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6713 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6714 (AARCH64_HWP_ALIGNMENT): Likewise.
6715 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6716 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6717 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6718 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6719 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6720 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6721 (struct aarch64_debug_reg_state): Likewise.
6722 (struct arch_lwp_info): Likewise.
6723 (aarch64_align_watchpoint): Likewise.
6724 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6725 (aarch64_watchpoint_length): Likewise.
6726 (aarch64_point_encode_ctrl_reg): Likewise
6727 (aarch64_point_is_aligned): Likewise.
6728 (aarch64_align_watchpoint): Likewise.
6729 (aarch64_linux_set_debug_regs):
6730 (aarch64_dr_state_insert_one_point): Likewise.
6731 (aarch64_dr_state_remove_one_point): Likewise.
6732 (aarch64_handle_breakpoint): Likewise.
6733 (aarch64_handle_aligned_watchpoint): Likewise.
6734 (aarch64_handle_unaligned_watchpoint): Likewise.
6735 (aarch64_handle_watchpoint): Likewise.
6737 2015-07-17 Yao Qi <yao.qi@linaro.org>
6739 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6740 and don't aarch64_get_debug_reg_state. All callers update.
6741 (aarch64_handle_aligned_watchpoint): Likewise.
6742 (aarch64_handle_unaligned_watchpoint): Likewise.
6743 (aarch64_handle_watchpoint): Likewise.
6744 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6745 (aarch64_remove_point): Likewise.
6747 2015-07-17 Yao Qi <yao.qi@linaro.org>
6749 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6751 (aarch64_handle_unaligned_watchpoint): Likewise.
6753 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6755 Revert the previous 3 commits:
6756 Move gdb_regex* to common/
6757 Move linux_find_memory_regions_full & co.
6758 gdbserver build-id attribute generator
6760 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6761 Jan Kratochvil <jan.kratochvil@redhat.com>
6763 gdbserver build-id attribute generator.
6764 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6765 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6766 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6768 (get_dynamic): Use find_pdhr to traverse program headers.
6769 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6770 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6771 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6772 (get_hex_build_id): New.
6773 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6774 to reply XML document.
6776 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6777 Jan Kratochvil <jan.kratochvil@redhat.com>
6779 * target.c: Include target/target-utils.h and fcntl.h.
6780 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6781 (target_fileio_read_stralloc): New functions.
6783 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6785 * Makefile.in (OBS): Add gdb_regex.o.
6787 * config.in: Rebuilt.
6788 * configure: Rebuilt.
6790 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6791 Jan Kratochvil <jan.kratochvil@redhat.com>
6793 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6794 * Makefile.in (OBS): Add target-utils.o.
6795 (linux-maps.o, target-utils.o): New.
6796 * configure.srv (srv_linux_obj): Add linux-maps.o.
6798 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6800 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6802 (the_low_target): Install it.
6804 2015-07-14 Pedro Alves <palves@redhat.com>
6806 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6807 Instead, ignore ECHILD, and throw an error for other errnos.
6809 2015-07-10 Pedro Alves <palves@redhat.com>
6811 * event-loop.c (struct callback_event) <data>: Change type to
6812 gdb_client_data instance instead of gdb_client_data pointer.
6813 (append_callback_event): Adjust.
6815 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6817 * linux-aarch64-low.c: Add comments for each linux_target_ops
6818 method. Remove comments already covered in target_ops and
6819 linux_target_ops definitions.
6820 (the_low_target): Add comments for each unimplemented method.
6822 2015-07-09 Yao Qi <yao.qi@linaro.org>
6824 * linux-aarch64-low.c (aarch64_regmap): Remove.
6825 (aarch64_usrregs_info): Remove.
6826 (regs_info): Set field usrregs to NULL.
6828 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6830 * linux-low.c: Include "rsp-low.h"
6831 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6832 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6833 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6834 (handle_btrace_enable_pt): New.
6835 (handle_btrace_general_set): Support "pt".
6836 (handle_btrace_conf_general_set): Support "pt:size".
6838 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6840 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6843 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6845 * linux-aarch64-low.c: Remove comment about endianness.
6846 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6847 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6850 2015-06-24 Gary Benson <gbenson@redhat.com>
6852 * linux-i386-ipa.c (stdint.h): Do not include.
6853 * lynx-i386-low.c (stdint.h): Likewise.
6854 * lynx-ppc-low.c (stdint.h): Likewise.
6855 * mem-break.c (stdint.h): Likewise.
6856 * thread-db.c (stdint.h): Likewise.
6857 * tracepoint.c (stdint.h): Likewise.
6858 * win32-low.c (stdint.h): Likewise.
6860 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6862 * server.c (write_qxfer_response): Update call to
6863 remote_escape_output.
6865 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6866 Jan Kratochvil <jan.kratochvil@redhat.com>
6868 Merge multiple hex conversions.
6869 * gdbreplay.c (tohex): Rename to 'fromhex'.
6870 (logchar): Use fromhex.
6872 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6874 * server.c (handle_qxfer_libraries): Set `version' attribute for
6877 2015-06-10 Gary Benson <gbenson@redhat.com>
6879 * target.h (struct target_ops) <multifs_open>: New field.
6880 <multifs_unlink>: Likewise.
6881 <multifs_readlink>: Likewise.
6882 * linux-low.c (nat/linux-namespaces.h): New include.
6883 (linux_target_ops): Initialize the_target->multifs_open,
6884 the_target->multifs_unlink and the_target->multifs_readlink.
6885 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6886 * hostio.c (hostio_fs_pid): New static variable.
6887 (hostio_handle_new_gdb_connection): New function.
6888 (handle_setfs): Likewise.
6889 (handle_open): Use the_target->multifs_open as appropriate.
6890 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6891 (handle_readlink): Use the_target->multifs_readlink as
6893 (handle_vFile): Handle vFile:setfs packets.
6894 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6895 after target_handle_new_gdb_connection.
6897 2015-06-10 Gary Benson <gbenson@redhat.com>
6899 * configure.ac (AC_CHECK_FUNCS): Add setns.
6900 * config.in: Regenerate.
6901 * configure: Likewise.
6902 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6903 (linux-namespaces.o): New rule.
6904 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6906 2015-06-09 Gary Benson <gbenson@redhat.com>
6908 * hostio.c (handle_open): Process mode argument with
6909 fileio_to_host_mode.
6911 2015-06-01 Yao Qi <yao.qi@linaro.org>
6913 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6914 * linux-x86-low.c: Likewise.
6916 2015-05-28 Don Breazeal <donb@codesourcery.com>
6918 * linux-low.c (handle_extended_wait): Initialize
6919 thread_info.last_resume_kind for new fork children.
6921 2015-05-15 Pedro Alves <palves@redhat.com>
6923 * target.h (target_handle_new_gdb_connection): Rewrite using if
6924 wrapped in do/while.
6926 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6928 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6929 * configure, config.in: Regenerate.
6930 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6933 2015-05-12 Don Breazeal <donb@codesourcery.com>
6935 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6936 PTRACE_EVENT_VFORK_DONE.
6937 (linux_low_ptrace_options, extended_event_reported): Add vfork
6939 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6940 and "vforkdone" for RSP 'T' Stop Reply Packet.
6941 * server.h (report_vfork_events): Declare
6944 2015-05-12 Don Breazeal <donb@codesourcery.com>
6946 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6947 (the_low_target) <new_fork>: Initialize new member.
6948 * linux-arm-low.c (arm_new_fork): New function.
6949 (the_low_target) <new_fork>: Initialize new member.
6950 * linux-low.c (handle_extended_wait): Call new target function
6952 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6953 * linux-mips-low.c (mips_add_watchpoint): New function
6954 extracted from mips_insert_point.
6955 (the_low_target) <new_fork>: Initialize new member.
6956 (mips_linux_new_fork): New function.
6957 (mips_insert_point): Call mips_add_watchpoint.
6958 * linux-x86-low.c (x86_linux_new_fork): New function.
6959 (the_low_target) <new_fork>: Initialize new member.
6961 2015-05-12 Don Breazeal <donb@codesourcery.com>
6963 * linux-low.c (handle_extended_wait): Implement return value,
6964 rename argument 'event_child' to 'event_lwp', handle
6965 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6966 (linux_low_ptrace_options): New function.
6967 (linux_low_filter_event): Call linux_low_ptrace_options,
6968 use different argument fo linux_enable_event_reporting,
6969 use return value from handle_extended_wait.
6970 (extended_event_reported): New function.
6971 (linux_wait_1): Call extended_event_reported and set
6972 status to report fork events.
6973 (linux_write_memory): Add pid to debug message.
6974 (reset_lwp_ptrace_options_callback): New function.
6975 (linux_handle_new_gdb_connection): New function.
6976 (linux_target_ops): Initialize new structure member.
6977 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6978 * lynx-low.c: Initialize new structure member.
6979 * remote-utils.c (prepare_resume_reply): Implement stop reason
6980 "fork" for "T" stop message.
6981 * server.c (handle_query): Call handle_new_gdb_connection.
6982 * server.h (report_fork_events): Declare global flag.
6983 * target.h (struct target_ops) <handle_new_gdb_connection>:
6985 (target_handle_new_gdb_connection): New macro.
6986 * win32-low.c: Initialize new structure member.
6988 2015-05-12 Don Breazeal <donb@codesourcery.com>
6990 * mem-break.c (APPEND_TO_LIST): Define macro.
6991 (clone_agent_expr): New function.
6992 (clone_one_breakpoint): New function.
6993 (clone_all_breakpoints): New function.
6994 * mem-break.h: Declare new functions.
6996 2015-05-12 Don Breazeal <donb@codesourcery.com>
6998 * linux-low.c (linux_supports_fork_events): New function.
6999 (linux_supports_vfork_events): New function.
7000 (linux_target_ops): Initialize new structure members.
7001 (initialize_low): Call linux_check_ptrace_features.
7002 * lynx-low.c (lynx_target_ops): Initialize new structure
7004 * server.c (report_fork_events, report_vfork_events):
7006 (handle_query): Add new features to qSupported packet and
7008 (captured_main): Initialize new global variables.
7009 * target.h (struct target_ops) <supports_fork_events>:
7011 <supports_vfork_events>: New member.
7012 (target_supports_fork_events): New macro.
7013 (target_supports_vfork_events): New macro.
7014 * win32-low.c (win32_target_ops): Initialize new structure
7017 2015-05-12 Gary Benson <gbenson@redhat.com>
7019 * server.c (handle_qxfer_exec_file): Use current process
7022 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
7024 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
7025 Remove HAVE_PTRACE_GETREGS conditionals.
7026 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
7027 instead of PTRACE_GETREGS and PTRACE_SETREGS.
7029 2015-05-08 Yao Qi <yao.qi@linaro.org>
7031 * linux-low.c (linux_supports_conditional_breakpoints): New
7033 (linux_target_ops): Install new target method.
7034 * lynx-low.c (lynx_target_ops): Install NULL hook for
7035 supports_conditional_breakpoints.
7036 * nto-low.c (nto_target_ops): Likewise.
7037 * spu-low.c (spu_target_ops): Likewise.
7038 * win32-low.c (win32_target_ops): Likewise.
7039 * server.c (handle_query): Check
7040 target_supports_conditional_breakpoints.
7041 * target.h (struct target_ops) <supports_conditional_breakpoints>:
7043 (target_supports_conditional_breakpoints): New macro.
7045 2015-05-06 Pedro Alves <palves@redhat.com>
7048 * server.c (start_inferior): If the process exits, mourn it.
7050 2015-04-21 Gary Benson <gbenson@redhat.com>
7052 * hostio.c (fileio_open_flags_to_host): Factored out to
7053 fileio_to_host_openflags in common/fileio.c. Single use
7056 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
7058 * linux-xtensa-low.c (xtensa_fill_gregset)
7059 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
7062 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
7064 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
7065 (regs_info): Replace usrregs pointer with NULL.
7067 2015-04-17 Gary Benson <gbenson@redhat.com>
7069 * target.h (struct target_ops) <pid_to_exec_file>: New field.
7070 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
7071 * server.c (handle_qxfer_exec_file): New function.
7072 (qxfer_packets): Add exec-file entry.
7073 (handle_query): Report qXfer:exec-file:read as supported packet.
7075 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
7077 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
7079 2015-04-09 Gary Benson <gbenson@redhat.com>
7081 * hostio-errno.c (errno_to_fileio_error): Remove function.
7082 Update caller to use remote_fileio_to_fio_error.
7084 2015-04-09 Yao Qi <yao.qi@linaro.org>
7086 * linux-low.c (linux_insert_point): Call
7087 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
7088 (linux_remove_point): Call remove_memory_breakpoint if type is
7090 * linux-x86-low.c (x86_insert_point): Don't call
7091 insert_memory_breakpoint.
7092 (x86_remove_point): Don't call remove_memory_breakpoint.
7094 2015-04-01 Pedro Alves <palves@redhat.com>
7095 Cleber Rosa <crosa@redhat.com>
7097 * server.c (gdbserver_usage): Reorganize and extend the usage
7100 2015-03-24 Pedro Alves <palves@redhat.com>
7102 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
7103 output. Also dump TRAP_TRACE.
7104 (linux_low_filter_event): In debug output, distinguish a
7105 resume_stop SIGSTOP from a delayed SIGSTOP.
7107 2015-03-24 Gary Benson <gbenson@redhat.com>
7109 * linux-x86-low.c (x86_linux_new_thread): Moved to
7111 (x86_linux_prepare_to_resume): Likewise.
7113 2015-03-24 Gary Benson <gbenson@redhat.com>
7115 * Makefile.in (x86-linux-dregs.o): New rule.
7116 * configure.srv: Add x86-linux-dregs.o to relevant targets.
7117 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
7118 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
7119 (x86_linux_dr_get): Likewise.
7120 (x86_linux_dr_set): Likewise.
7121 (update_debug_registers_callback): Likewise.
7122 (x86_linux_dr_set_addr): Likewise.
7123 (x86_linux_dr_get_addr): Likewise.
7124 (x86_linux_dr_set_control): Likewise.
7125 (x86_linux_dr_get_control): Likewise.
7126 (x86_linux_dr_get_status): Likewise.
7127 (x86_linux_update_debug_registers): Likewise.
7129 2015-03-24 Gary Benson <gbenson@redhat.com>
7131 * linux-x86-low.c (x86_linux_update_debug_registers):
7132 New function, factored out from...
7133 (x86_linux_prepare_to_resume): ...this.
7135 2015-03-24 Gary Benson <gbenson@redhat.com>
7137 * linux-x86-low.c (x86_linux_dr_get): Update comments.
7138 (x86_linux_dr_set): Likewise.
7139 (update_debug_registers_callback): Likewise.
7140 (x86_linux_dr_set_addr): Likewise.
7141 (x86_linux_dr_get_addr): Likewise.
7142 (x86_linux_dr_set_control): Likewise.
7143 (x86_linux_dr_get_control): Likewise.
7144 (x86_linux_dr_get_status): Likewise.
7145 (x86_linux_prepare_to_resume): Likewise.
7147 2015-03-24 Gary Benson <gbenson@redhat.com>
7149 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
7150 Use perror_with_name. Pass string through gettext.
7151 (x86_linux_dr_set): Likewise.
7153 2015-03-24 Gary Benson <gbenson@redhat.com>
7155 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
7156 (x86_linux_dr_set_addr): ...this.
7157 (x86_dr_low_get_addr): Rename to...
7158 (x86_linux_dr_get_addr): ...this.
7159 (x86_dr_low_set_control): Rename to...
7160 (x86_linux_dr_set_control): ...this.
7161 (x86_dr_low_get_control): Rename to...
7162 (x86_linux_dr_get_control): ...this.
7163 (x86_dr_low_get_status): Rename to...
7164 (x86_linux_dr_get_status): ...this.
7165 (x86_dr_low): Update with new function names.
7167 2015-03-24 Gary Benson <gbenson@redhat.com>
7169 * Makefile.in (x86-linux.o): New rule.
7170 * configure.srv: Add x86-linux.o to relevant targets.
7171 * linux-low.c (lwp_set_arch_private_info): New function.
7172 (lwp_arch_private_info): Likewise.
7173 * linux-x86-low.c: Include nat/x86-linux.h.
7174 (arch_lwp_info): Removed structure.
7175 (update_debug_registers_callback):
7176 Use lwp_set_debug_registers_changed.
7177 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
7178 and lwp_set_debug_registers_changed.
7179 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
7181 2015-03-24 Gary Benson <gbenson@redhat.com>
7183 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
7184 * linux-arm-low.c (arm_new_thread): Likewise.
7185 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
7186 * linux-mips-low.c (mips_linux_new_thread): Likewise.
7187 * linux-x86-low.c (x86_linux_new_thread): Likewise.
7188 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
7190 2015-03-24 Gary Benson <gbenson@redhat.com>
7192 * linux-low.c (ptid_of_lwp): New function.
7193 (lwp_is_stopped): Likewise.
7194 (lwp_stop_reason): Likewise.
7195 * linux-x86-low.c (update_debug_registers_callback):
7197 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
7200 2015-03-24 Gary Benson <gbenson@redhat.com>
7202 * linux-low.h (linux_stop_lwp): Remove declaration.
7204 2015-03-24 Gary Benson <gbenson@redhat.com>
7206 * linux-low.h: Include nat/linux-nat.h.
7207 * linux-low.c (iterate_over_lwps_args): New structure.
7208 (iterate_over_lwps_filter): New function.
7209 (iterate_over_lwps): Likewise.
7210 * linux-x86-low.c (update_debug_registers_callback):
7211 Update signature to what iterate_over_lwps expects.
7212 Remove PID check that iterate_over_lwps now performs.
7213 (x86_dr_low_set_addr): Use iterate_over_lwps.
7214 (x86_dr_low_set_control): Likewise.
7216 2015-03-24 Gary Benson <gbenson@redhat.com>
7218 * linux-x86-low.c (x86_debug_reg_state): New function.
7219 (x86_linux_prepare_to_resume): Use the above.
7221 2015-03-24 Gary Benson <gbenson@redhat.com>
7223 * linux-low.c (current_lwp_ptid): New function.
7224 * linux-x86-low.c: Include nat/linux-nat.h.
7225 (x86_dr_low_get_addr): Use current_lwp_ptid.
7226 (x86_dr_low_get_control): Likewise.
7227 (x86_dr_low_get_status): Likewise.
7229 2015-03-20 Pedro Alves <palves@redhat.com>
7231 * tracepoint.c (cmd_qtstatus): Make "str" const.
7233 2015-03-20 Pedro Alves <palves@redhat.com>
7235 * server.c (handle_general_set): Make "req_str" const.
7237 2015-03-19 Pedro Alves <palves@redhat.com>
7239 * linux-low.c (linux_resume_one_lwp): Rename to ...
7240 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
7241 instead call perror_with_name.
7242 (check_ptrace_stopped_lwp_gone): New function.
7243 (linux_resume_one_lwp): Reimplement as wrapper around
7244 linux_resume_one_lwp_throw that swallows errors if the LWP is
7247 2015-03-19 Pedro Alves <palves@redhat.com>
7249 * linux-low.c (count_events_callback, select_event_lwp_callback):
7250 No longer check whether the thread has resume_stop as last resume
7253 2015-03-19 Pedro Alves <palves@redhat.com>
7255 * linux-low.c (count_events_callback, select_event_lwp_callback):
7256 Use the lwp's status_pending_p field, not the thread's.
7258 2015-03-19 Pedro Alves <palves@redhat.com>
7260 * linux-low.c (select_event_lwp_callback): Update comments to
7261 no longer mention SIGTRAP.
7263 2015-03-18 Gary Benson <gbenson@redhat.com>
7265 * server.c (handle_query): Do not report vFile:fstat as supported.
7267 2015-03-11 Gary Benson <gbenson@redhat.com>
7269 * hostio.c (sys/types.h): New include.
7270 (sys/stat.h): Likewise.
7271 (common-remote-fileio.h): Likewise.
7272 (handle_fstat): New function.
7273 (handle_vFile): Handle vFile:fstat packets.
7275 2015-03-11 Gary Benson <gbenson@redhat.com>
7277 * configure.ac (AC_CHECK_MEMBERS): Add checks for
7278 struct stat.st_blocks and struct stat.st_blksize.
7279 * configure: Regenerate.
7280 * config.in: Likewise.
7281 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
7282 (OBS): Add common-remote-fileio.o.
7283 (common-remote-fileio.o): New rule.
7285 2015-03-09 Pedro Alves <palves@redhat.com>
7287 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
7288 'struct sockaddr' pointer in 'accept' call.
7290 2015-03-09 Pedro Alves <palves@redhat.com>
7293 2015-03-07 Pedro Alves <palves@redhat.com>
7294 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
7295 or <winsock2.h> here. Instead include "gdb_socket.h".
7296 (remote_open): Use union gdb_sockaddr_u.
7297 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
7298 or <winsock2.h> here. Instead include "gdb_socket.h".
7299 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
7300 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
7302 (init_named_socket, gdb_agent_helper_thread): Use union
7305 2015-03-07 Pedro Alves <palves@redhat.com>
7307 * configure.ac (build_warnings): Move
7308 -Wdeclaration-after-statement to the C-specific set.
7309 * configure: Regenerate.
7311 2015-03-07 Pedro Alves <palves@redhat.com>
7313 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
7314 or <winsock2.h> here. Instead include "gdb_socket.h".
7315 (remote_open): Use union gdb_sockaddr_u.
7316 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
7317 or <winsock2.h> here. Instead include "gdb_socket.h".
7318 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
7319 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
7321 (init_named_socket, gdb_agent_helper_thread): Use union
7324 2015-03-07 Pedro Alves <palves@redhat.com>
7326 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
7329 2015-03-06 Yao Qi <yao.qi@linaro.org>
7331 * linux-aarch64-low.c (aarch64_insert_point): Use
7332 show_debug_regs as a boolean.
7333 (aarch64_remove_point): Likewise.
7335 2015-03-05 Pedro Alves <palves@redhat.com>
7337 * lynx-low.c (lynx_target_ops): Install NULL hooks for
7338 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
7339 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
7340 * nto-low.c (nto_target_ops): Likewise.
7341 * spu-low.c (spu_target_ops): Likewise.
7342 * win32-low.c (win32_target_ops): Likewise.
7344 2015-03-04 Pedro Alves <palves@redhat.com>
7346 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
7347 Decide whether a breakpoint triggered based on the SIGTRAP's
7349 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
7350 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
7351 (linux_low_filter_event): Check for breakpoints before checking
7353 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
7355 (linux_stopped_by_sw_breakpoint)
7356 (linux_supports_stopped_by_sw_breakpoint)
7357 (linux_stopped_by_hw_breakpoint)
7358 (linux_supports_stopped_by_hw_breakpoint): New functions.
7359 (linux_target_ops): Install new target methods.
7361 2015-03-04 Pedro Alves <palves@redhat.com>
7363 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
7364 * server.c (swbreak_feature, hwbreak_feature): New globals.
7365 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
7366 (captured_main): Clear swbreak_feature and hwbreak_feature.
7367 * server.h (swbreak_feature, hwbreak_feature): Declare.
7368 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
7369 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
7370 supports_stopped_by_hw_breakpoint>: New fields.
7371 (target_supports_stopped_by_sw_breakpoint)
7372 (target_stopped_by_sw_breakpoint)
7373 (target_supports_stopped_by_hw_breakpoint)
7374 (target_stopped_by_hw_breakpoint): Declare.
7376 2015-03-04 Pedro Alves <palves@redhat.com>
7378 enum lwp_stop_reason -> enum target_stop_reason
7379 * linux-low.c (check_stopped_by_breakpoint): Adjust.
7380 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
7381 (linux_wait_1, stuck_in_jump_pad_callback)
7382 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
7383 (linux_stopped_by_watchpoint):
7384 * linux-low.h (enum lwp_stop_reason): Delete.
7385 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
7386 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7388 2015-03-04 Yao Qi <yao.qi@linaro.org>
7390 * Makefile.in (SFILES): Add linux-aarch64-low.c.
7392 2015-03-03 Gary Benson <gbenson@redhat.com>
7394 * hostio.c (handle_vFile): Fix prefix lengths.
7396 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
7398 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
7401 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
7403 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
7404 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
7405 (clean): Add "rm -f" for above C files.
7406 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
7407 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
7408 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
7409 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
7410 * linux-s390-low.c (HWCAP_S390_VX): New macro.
7411 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
7412 (init_registers_s390x_vx_linux64)
7413 (init_registers_s390x_tevx_linux64)
7414 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
7415 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
7417 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
7418 (s390_store_vxrs_high): New functions.
7419 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
7421 (s390_arch_setup): Add logic for selecting one of the new target
7422 descriptions. Activate the new vector regsets if applicable.
7423 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
7424 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
7425 and init_registers_s390x_tevx_linux64.
7427 2015-03-01 Pedro Alves <palves@redhat.com>
7429 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
7432 2015-02-27 Pedro Alves <palves@redhat.com>
7434 * linux-x86-low.c (u_debugreg_offset): New function.
7435 (x86_linux_dr_get, x86_linux_dr_set): Use it.
7437 2015-02-27 Pedro Alves <palves@redhat.com>
7439 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
7440 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
7441 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
7442 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7443 (ps_lsetfpregs, ps_getpid)
7444 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
7445 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
7446 (ps_lsetxregs, ps_plog): Declare.
7448 2015-02-27 Pedro Alves <palves@redhat.com>
7450 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
7451 IP_AGENT_EXPORT_FUNC.
7452 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
7453 IP_AGENT_EXPORT_FUNC.
7454 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
7455 (IP_AGENT_EXPORT): Delete.
7456 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7457 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7458 (gdb_trampoline_buffer_error, collecting, gdb_collect)
7459 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
7460 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
7461 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
7462 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
7463 (traceframe_read_count, traceframe_write_count)
7464 (traceframes_created, trace_state_variables, get_raw_reg)
7465 (get_trace_state_variable_value, set_trace_state_variable_value)
7466 (ust_loaded, helper_thread_id, cmd_buf): Use
7467 IPA_SYM_EXPORTED_NAME.
7468 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
7469 (tracepoints) Use IP_AGENT_EXPORT_VAR.
7470 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
7471 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7472 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
7473 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
7474 EXTERN_C_PUSH/EXTERN_C_POP.
7475 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
7476 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
7477 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7478 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
7479 (traceframe_write_count, traceframe_read_count)
7480 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
7481 (about_to_request_buffer_space, get_trace_state_variable_value)
7482 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
7483 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
7484 EXTERN_C_PUSH/EXTERN_C_POP.
7485 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
7486 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
7487 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
7488 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7489 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7490 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7491 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
7492 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
7494 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
7495 (IP_AGENT_EXPORT_VAR_DECL): Define.
7497 (gdb_agent_get_raw_reg): Declare.
7499 2015-02-27 Tom Tromey <tromey@redhat.com>
7500 Pedro Alves <palves@redhat.com>
7502 Rename symbols whose names are reserved C++ keywords throughout.
7504 2015-02-27 Pedro Alves <palves@redhat.com>
7506 * Makefile.in (COMPILER): New, get it from autoconf.
7507 (CXX): Get from autoconf instead.
7508 (COMPILE.pre): Use COMPILER.
7509 (CC-LD): Rename to ...
7510 (CC_LD): ... this. Use COMPILER.
7511 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
7512 (CXX_FOR_TARGET): Default to g++ instead of gcc.
7513 * acinclude.m4: Include build-with-cxx.m4.
7514 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
7515 Disable -Werror by default if building in C++ mode.
7516 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
7517 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
7518 the C++ compiler. Save/restore CXXFLAGS too.
7519 * configure: Regenerate.
7521 2015-02-27 Pedro Alves <palves@redhat.com>
7523 * acinclude.m4: Include libiberty.m4.
7524 * configure.ac: Call libiberty_INIT.
7525 * config.in, configure: Regenerate.
7527 2015-02-26 Pedro Alves <palves@redhat.com>
7529 * linux-low.c (linux_wait_1): When incrementing the PC past a
7530 program breakpoint always use the_low_target.breakpoint_len as
7531 increment, rather than the maximum between that and
7532 the_low_target.decr_pc_after_break.
7534 2015-02-23 Pedro Alves <palves@redhat.com>
7536 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
7537 thread was doing a step-over; always adjust the PC if
7538 we stepped over a permanent breakpoint.
7539 (linux_wait_1): If we stepped over breakpoint that was on top of a
7540 permanent breakpoint, manually advance the PC past it.
7542 2015-02-23 Pedro Alves <palves@redhat.com>
7544 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
7546 (x86_fill_gregset, x86_store_gregset): Use it when handling
7549 2015-02-20 Pedro Alves <palves@redhat.com>
7551 * thread-db.c: Include "nat/linux-procfs.h".
7552 (thread_db_init): Skip listing new threads if the kernel supports
7553 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
7555 2015-02-20 Pedro Alves <palves@redhat.com>
7557 * linux-low.c (status_pending_p_callback): Use ptid_match.
7559 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
7561 PR breakpoints/16812
7562 * linux-low.c (wstatus_maybe_breakpoint): Remove.
7563 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
7564 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
7566 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
7568 PR breakpoints/15956
7569 * tracepoint.c (cmd_qtinit): Add check for current_thread.
7571 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7573 * linux-low.c (linux_low_btrace_conf): Print size.
7574 * server.c (handle_btrace_conf_general_set): New.
7575 (hanle_general_set): Call handle_btrace_conf_general_set.
7576 (handle_query): Report Qbtrace-conf:bts:size as supported.
7578 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7580 * linux-low.c (linux_low_enable_btrace): Update parameters.
7581 (linux_low_btrace_conf): New.
7582 (linux_target_ops)<to_btrace_conf>: Initialize.
7583 * server.c (current_btrace_conf): New.
7584 (handle_btrace_enable): Rename to ...
7585 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
7586 to target_enable_btrace. Update comment. Update users.
7587 (handle_qxfer_btrace_conf): New.
7588 (qxfer_packets): Add btrace-conf entry.
7589 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7590 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7591 (target_ops)<read_btrace_conf>: New.
7592 (target_enable_btrace): Update parameters.
7593 (target_read_btrace_conf): New.
7595 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7597 * server.c (handle_btrace_general_set): Remove call to
7598 target_supports_btrace.
7599 (supported_btrace_packets): New.
7600 (handle_query): Call supported_btrace_packets.
7601 * target.h: include btrace-common.h.
7602 (btrace_target_info): Removed.
7603 (supports_btrace, target_supports_btrace): Update parameters.
7605 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7607 * Makefile.in (SFILES): Add common/btrace-common.c.
7608 (OBS): Add common/btrace-common.o.
7609 (btrace-common.o): Add build rules.
7610 * linux-low: Include btrace-common.h.
7611 (linux_low_read_btrace): Use struct btrace_data. Call
7612 btrace_data_init and btrace_data_fini.
7614 2015-02-06 Pedro Alves <palves@redhat.com>
7616 * thread-db.c (find_new_threads_callback): Add debug output.
7618 2015-02-04 Pedro Alves <palves@redhat.com>
7620 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7621 (resume_stopped_resumed_lwps): New function.
7622 (linux_wait_for_event_filtered): Use it.
7624 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7626 * Makefile.in (SFILES): Add linux-personality.c.
7627 (linux-personality.o): New rule.
7628 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7629 list of objects to be built.
7630 * linux-low.c: Include nat/linux-personality.h.
7631 (linux_create_inferior): Remove code to disable address space
7632 randomization (moved to ../nat/linux-personality.c). Create
7633 cleanup to disable address space randomization.
7635 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7637 * Makefile.in (posix-strerror.o): New rule.
7638 (mingw-strerror.o): Likewise.
7639 * configure: Regenerated.
7640 * configure.ac: Source file ../common/common.host. Initialize new
7641 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7643 2015-01-14 Yao Qi <yao@codesourcery.com>
7645 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7646 (ppc-linux.o): New rule.
7647 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7648 * configure.ac: AC_CHECK_FUNCS(getauxval).
7649 * config.in: Re-generated.
7650 * configure: Re-generated.
7651 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7652 ppc64_64bit_inferior_p
7654 2015-01-14 Yao Qi <yao@codesourcery.com>
7656 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7657 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7658 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7659 (PT_ORIG_R3, PT_TRAP): Likewise.
7660 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7661 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7662 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7664 2015-01-10 Joel Brobecker <brobecker@adacore.com>
7666 * i387-fp.c (i387_cache_to_xsave): In look over
7667 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7668 zmmh_low_space field by use of zmmh_high_space.
7670 2015-01-09 Pedro Alves <palves@redhat.com>
7672 * linux-low.c (step_over_bkpt): Move higher up in the file.
7673 (handle_extended_wait): Don't store the stop_pc here.
7674 (get_stop_pc): Adjust comments and rename to ...
7675 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7676 stopped for a software breakpoint or hardware breakpoint.
7677 (thread_still_has_status_pending_p): New function.
7678 (status_pending_p_callback): Use
7679 thread_still_has_status_pending_p. If the event is no longer
7680 interesting, resume the LWP.
7681 (handle_tracepoints): Add assert.
7682 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7683 (wstatus_maybe_breakpoint): New function.
7684 (cancel_breakpoint): Delete function.
7685 (check_stopped_by_watchpoint): New function, factored out from
7686 linux_low_filter_event.
7687 (lp_status_maybe_breakpoint): Delete function.
7688 (linux_low_filter_event): Remove filter_ptid argument.
7689 Leave thread group exits pending here. Store the LWP's stop PC.
7690 Always leave events pending.
7691 (linux_wait_for_event_filtered): Pull all events out of the
7692 kernel, and leave them all pending.
7693 (count_events_callback, select_event_lwp_callback): Consider all
7695 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7696 (select_event_lwp): Only give preference to the stepping LWP in
7697 all-stop mode. Adjust comments.
7698 (ignore_event): New function.
7699 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7700 references to cancel_breakpoints. Adjust to renames. Also give
7701 equal priority to all LWPs that have had events in non-stop mode.
7702 If reporting a software breakpoint event, unadjust the LWP's PC.
7703 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7704 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7706 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7707 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7708 (linux_stopped_by_watchpoint): Adjust.
7709 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7710 * linux-low.h (enum lwp_stop_reason): New.
7711 (struct lwp_info) <stop_pc>: Adjust comment.
7712 <stopped_by_watchpoint>: Delete field.
7713 <stop_reason>: New field.
7714 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7715 * mem-break.c (software_breakpoint_inserted_here)
7716 (hardware_breakpoint_inserted_here): New function.
7717 * mem-break.h (software_breakpoint_inserted_here)
7718 (hardware_breakpoint_inserted_here): Declare.
7719 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7720 (cancel_breakpoints): Delete.
7721 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7722 (upload_fast_traceframes): Remove references to
7725 2015-01-09 Pedro Alves <palves@redhat.com>
7727 * thread-db.c (find_new_threads_callback): Ignore thread if the
7728 kernel thread ID is -1.
7730 2015-01-09 Pedro Alves <palves@redhat.com>
7732 * linux-low.c (linux_attach_fail_reason_string): Move to
7733 nat/linux-ptrace.c, and rename.
7734 (linux_attach_lwp): Update comment.
7735 (attach_proc_task_lwp_callback): New function.
7736 (linux_attach): Adjust to rename and use
7737 linux_proc_attach_tgid_threads.
7738 (linux_attach_fail_reason_string): Delete declaration.
7740 2015-01-01 Joel Brobecker <brobecker@adacore.com>
7742 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7743 * server.c (gdbserver_version): Likewise.
7745 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7747 * remote-utils.c: Include ctype.h.
7748 (input_interrupt): Explicitly handle the case when the char
7749 received is the NUL byte. Improve the printing of non-ASCII
7752 2014-12-16 Joel Brobecker <brobecker@adacore.com>
7754 * linux-low.c (linux_low_filter_event): Update call to
7755 linux_enable_event_reporting following the addition of
7756 a new parameter to that function.
7758 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
7761 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7762 (AARCH64_FPCR_REGNO): Likewise.
7763 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7764 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7765 (aarch64_store_fpregset): Likewise.
7767 2014-12-15 Joel Brobecker <brobecker@adacore.com>
7769 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7770 Remove FIXME comment about assumption about N.
7772 2014-12-13 Joel Brobecker <brobecker@adacore.com>
7774 * configure.ac: If large-file support is disabled in GDBserver,
7775 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7776 * configure: Regenerate.
7778 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7780 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7781 warning upon ENODATA from ptrace.
7782 * linux-s390-low.c (s390_store_tdb): New.
7783 (s390_regsets): Add regset for NT_S390_TDB.
7785 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7787 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7788 without a fill_function.
7789 * linux-s390-low.c (s390_fill_last_break): Remove.
7790 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7791 (s390_arch_setup): Use regset's size instead of fill_function for
7794 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7796 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7797 the regset's store function when ptrace returned an error.
7798 * regcache.c (get_thread_regcache): Invalidate register cache
7799 before fetching inferior's registers.
7801 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7803 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7804 while-loop as for-loop.
7805 (regsets_store_inferior_registers): Likewise.
7807 2014-11-28 Yao Qi <yao@codesourcery.com>
7809 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7810 * config.in, configure: Re-generate.
7811 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7814 2014-11-21 Yao Qi <yao@codesourcery.com>
7816 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7817 (AC_CHECK_HEADERS): Remove malloc.h.
7818 * configure: Re-generated.
7819 * config.in: Re-generated.
7820 * server.h: Don't include alloca.h and malloc.h.
7821 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7822 Don't include malloc.h.
7824 2014-11-17 Joel Brobecker <brobecker@adacore.com>
7826 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7827 corresponding ERRNO check in same block.
7829 2014-11-12 Pedro Alves <palves@redhat.com>
7831 * server.c (cont_thread): Update comment.
7832 (start_inferior, attach_inferior): No longer clear cont_thread.
7833 (handle_v_cont): No longer set cont_thread.
7834 (captured_main): Clear cont_thread each time a GDB connects.
7836 2014-11-12 Pedro Alves <palves@redhat.com>
7838 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7839 thread, and don't resume all threads if the Hc thread has exited.
7841 2014-11-12 Pedro Alves <palves@redhat.com>
7843 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7844 the process group instead of to a specific LWP.
7846 2014-10-15 Pedro Alves <palves@redhat.com>
7849 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7851 (arm_set_thread_context): Delete.
7852 (the_low_target): Adjust.
7853 * win32-i386-low.c (debug_registers_changed)
7854 (debug_registers_used): Delete.
7855 (update_debug_registers_callback): New function.
7856 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7857 needing to update their debug registers.
7858 (win32_get_current_dr): New function.
7859 (x86_dr_low_get_addr, x86_dr_low_get_control)
7860 (x86_dr_low_get_status): Fetch the debug register from the thread
7862 (i386_initial_stuff): Adjust.
7863 (i386_get_thread_context): Remove current_event parameter. Don't
7864 clear debug_registers_changed nor copy DR values to
7866 (i386_set_thread_context): Delete.
7867 (i386_prepare_to_resume): New function.
7868 (i386_thread_added): Mark the thread as needing to update irs
7870 (the_low_target): Remove i386_set_thread_context and install
7871 i386_prepare_to_resume.
7872 * win32-low.c (win32_get_thread_context): Adjust.
7873 (win32_set_thread_context): Use SetThreadContext
7875 (win32_prepare_to_resume): New function.
7876 (win32_require_context): New function, factored out from ...
7877 (thread_rec): ... this.
7878 (continue_one_thread): Call win32_prepare_to_resume on each thread
7879 we're about to continue.
7880 (win32_resume): Call win32_prepare_to_resume on the event thread.
7881 * win32-low.h (struct win32_thread_info)
7882 <debug_registers_changed>: New field.
7883 (struct win32_target_ops): Change prototype of set_thread_context,
7884 delete set_thread_context and add prepare_to_resume.
7885 (win32_require_context): New declaration.
7887 2014-10-08 Gary Benson <gbenson@redhat.com>
7889 * server.h: Do not include common-exceptions.h.
7891 2014-10-08 Gary Benson <gbenson@redhat.com>
7893 * server.h: Do not include cleanups.h.
7895 2014-09-30 James Hogan <james.hogan@imgtec.com>
7897 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7900 2014-09-23 Yao Qi <yao@codesourcery.com>
7902 * linux-low.c (lp_status_maybe_breakpoint): New function.
7903 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7904 (count_events_callback): Likewise.
7905 (select_event_lwp_callback): Likewise.
7906 (cancel_breakpoints_callback): Likewise.
7908 2014-09-19 Don Breazeal <donb@codesourcery.com>
7910 * linux-low.c (handle_extended_wait): Call
7911 linux_ptrace_get_extended_event.
7912 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7913 linux_is_extended_waitstatus.
7915 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7917 * Makefile.in (CPPFLAGS): Define.
7918 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7919 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7921 2014-09-16 Gary Benson <gbenson@redhat.com>
7923 * inferiors.h (current_inferior): Renamed as...
7924 (current_thread): New variable. All uses updated.
7925 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7926 (maybe_move_out_of_jump_pad): Likewise.
7927 (cancel_breakpoint): Likewise.
7928 (linux_low_filter_event): Likewise.
7929 (wait_for_sigstop): Likewise.
7930 (linux_resume_one_lwp): Likewise.
7931 (need_step_over_p): Likewise.
7932 (start_step_over): Likewise.
7933 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7934 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7935 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7936 and save_inferior as saved_thread.
7937 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7939 (regcache_invalidate_thread): Likewise.
7940 * remote-utils.c (prepare_resume_reply): Likewise.
7941 * thread-db.c (thread_db_get_tls_address): Likewise.
7942 (disable_thread_event_reporting): Likewise.
7943 (remove_thread_event_breakpoints): Likewise.
7944 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7946 * target.h (set_desired_inferior): Renamed as...
7947 (set_desired_thread): New declaration. All uses updated.
7948 * server.c (myresume): Updated comment to reference thread instead
7950 (handle_serial_event): Likewise.
7951 (handle_target_event): Likewise.
7953 2014-09-12 Tom Tromey <tromey@redhat.com>
7954 Gary Benson <gbenson@redhat.com>
7956 * regcache.h: Include common-regcache.h.
7957 (regcache_read_pc): Don't declare.
7958 * regcache.c (get_thread_regcache_for_ptid): New function.
7960 2014-09-11 Tom Tromey <tromey@redhat.com>
7961 Gary Benson <gbenson@redhat.com>
7963 * symbol.c: New file.
7964 * Makefile.in (SFILES): Add symbol.c.
7965 (OBS): Add symbol.o.
7967 2014-09-11 Gary Benson <gbenson@redhat.com>
7969 * target.c (target_stop_ptid, target_continue_ptid): New
7972 2014-09-11 Tom Tromey <tromey@redhat.com>
7973 Gary Benson <gbenson@redhat.com>
7975 * target.h: Include target/target.h.
7976 * target.c (target_read_memory, target_read_uint32)
7977 (target_write_memory): New functions.
7979 2014-09-11 Gary Benson <gbenson@redhat.com>
7981 * server.h (debug_hw_points): Don't declare.
7982 * server.c (debug_hw_points): Don't define. Replace all uses
7983 with show_debug_regs.
7984 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7985 all uses with show_debug_regs.
7987 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7989 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7990 endianness into account.
7991 (ppc_supply_ptrace_register): Likewise.
7993 2014-09-03 James Hogan <james.hogan@imgtec.com>
7995 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7996 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7998 2014-09-03 Gary Benson <gbenson@redhat.com>
8000 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
8001 ALL_DEBUG_ADDRESS_REGISTERS.
8003 2014-09-02 Gary Benson <gbenson@redhat.com>
8005 * i386-low.h: Renamed as...
8006 * x86-low.h: New file. All type, function and variable name
8007 prefixes changed from "i386_" to "x86_". All references updated.
8008 * i386-low.c: Renamed as...
8009 * x86-low.c: New file. All type, function and variable name
8010 prefixes changed from "i386_" to "x86_". All references updated.
8012 2014-09-02 Gary Benson <gbenson@redhat.com>
8014 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
8015 (x86_linux_new_thread): Likewise.
8017 2014-08-29 Gary Benson <gbenson@redhat.com>
8019 * server.h (setjmp.h): Do not include.
8020 (toplevel): Do not declare.
8021 (common-exceptions.h): Include.
8022 (cleanups.h): Likewise.
8023 * server.c (toplevel): Do not define.
8024 (exit_code): New static global.
8025 (detach_or_kill_for_exit_cleanup): New function.
8026 (main): New function. Original main renamed to...
8027 (captured_main): New function.
8028 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
8030 2014-08-29 Gary Benson <gbenson@redhat.com>
8032 * Makefile.in (SFILES): Add common/common-exceptions.c.
8033 (OBS): Add common-exceptions.o.
8034 (common-exceptions.o): New rule.
8035 * utils.c (prepare_to_throw_exception): New function.
8037 2014-08-29 Gary Benson <gbenson@redhat.com>
8039 * config.in: Regenerate.
8040 * configure: Likewise.
8042 2014-08-29 Gary Benson <gbenson@redhat.com>
8044 * Makefile.in (SFILES): Add common/cleanups.c.
8046 (cleanups.o): New rule.
8048 2014-08-29 Gary Benson <gbenson@redhat.com>
8050 * utils.c (internal_vwarning): New function.
8052 2014-08-28 Gary Benson <gbenson@redhat.com>
8054 * utils.h (fatal): Remove declaration.
8055 * utils.c (fatal): Remove function.
8057 2014-08-28 Gary Benson <gbenson@redhat.com>
8059 * tracepoint.c (gdb_agent_init): Replace fatal with
8061 (initialize_tracepoint): Likewise.
8063 2014-08-28 Gary Benson <gbenson@redhat.com>
8065 * remote-utils.c (remote_prepare): Replace fatal with error.
8067 2014-08-28 Gary Benson <gbenson@redhat.com>
8069 * linux-low.c (linux_async): Replace fatal with warning.
8071 (linux_start_non_stop): Return -1 if linux_async failed.
8073 2014-08-28 Gary Benson <gbenson@redhat.com>
8075 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
8077 (i386_dr_low_get_addr): Remove vague comment.
8078 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
8081 2014-08-28 Gary Benson <gbenson@redhat.com>
8083 * inferiors.c (get_thread_process): Replace check with gdb_assert.
8084 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
8086 (linux_resume_one_lwp): Likewise.
8087 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
8089 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
8090 with internal_error.
8091 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
8092 (init_register_cache): Replace fatal with gdb_assert_not_reached.
8093 (find_register_by_name): Replace fatal with internal_error.
8094 (find_regno): Likewise.
8095 * tdesc.c (init_target_desc): Replace check with gdb_assert.
8096 * thread-db.c (thread_db_create_event): Likewise.
8097 (thread_db_load_search): Likewise.
8098 (try_thread_db_load_1): Likewise.
8099 * tracepoint.c (get_jump_space_head): Replace fatal with
8101 (claim_trampoline_space): Likewise.
8102 (have_fast_tracepoint_trampoline_buffer): Likewise.
8103 (cmd_qtstart): Likewise.
8104 (stop_tracing): Likewise.
8105 (fast_tracepoint_collecting): Likewise.
8106 (target_malloc): Likewise.
8107 (download_tracepoint): Likewise.
8108 (download_trace_state_variables): Replace check with gdb_assert.
8109 (upload_fast_traceframes): Replace fatal with internal_error.
8111 2014-08-19 Tom Tromey <tromey@redhat.com>
8112 Gary Benson <gbenson@redhat.com>
8114 * Makefile.in (SFILES): Add common/common-debug.c.
8115 (OBS): Add common-debug.o.
8116 (common-debug.o): New rule.
8117 * debug.h (debug_printf): Don't declare.
8118 * debug.c (debug_printf): Renamed and rewritten as...
8119 (debug_vprintf): New function.
8121 2014-08-19 Gary Benson <gbenson@redhat.com>
8123 * utils.h: Do not include print-utils.h.
8125 2014-08-19 Tom Tromey <tromey@redhat.com>
8126 Gary Benson <gbenson@redhat.com>
8128 * server.h: Add static assertion.
8129 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
8131 2014-08-19 Tom Tromey <tromey@redhat.com>
8132 Gary Benson <gbenson@redhat.com>
8134 * Makefile.in (SFILES): Add common/errors.c.
8135 (OBS): Add errors.o.
8136 (IPA_OBS): Add errors-ipa.o.
8137 (errors.o): New rule.
8138 (errors-ipa.o): Likewise.
8139 * utils.h (perror_with_name, error, warning): Don't declare.
8140 * utils.c (warning): Renamed and rewritten as...
8141 (vwarning): New function.
8142 (error): Renamed and rewritten as...
8143 (verror): New function.
8144 (internal_error): Renamed and rewritten as...
8145 (internal_verror): New function.
8147 2014-08-07 Gary Benson <gbenson@redhat.com>
8149 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
8150 * configure: Regenerate.
8151 * config.in: Likewise.
8152 * server.h: Do not include errno.h.
8153 * event-loop.c: Likewise.
8154 * hostio-errno.c: Likewise.
8155 * linux-low.c: Likewise.
8156 * remote-utils.c: Likewise.
8157 * spu-low.c: Likewise.
8158 * utils.c: Likewise.
8159 * gdbreplay.c: Unconditionally include errno.h.
8161 2014-08-07 Gary Benson <gbenson@redhat.com>
8163 * server.h: Do not include string.h.
8164 * event-loop.c: Likewise.
8165 * linux-low.c: Likewise.
8166 * regcache.c: Likewise.
8167 * remote-utils.c: Likewise.
8168 * spu-low.c: Likewise.
8169 * utils.c: Likewise.
8171 2014-08-07 Gary Benson <gbenson@redhat.com>
8173 * server.h: Do not include gdb_assert.h.
8175 2014-08-07 Gary Benson <gbenson@redhat.com>
8177 * server.h: Do not include common-utils.h.
8179 2014-08-07 Gary Benson <gbenson@redhat.com>
8181 * server.h: Do not include ptid.h.
8182 * notif.h: Likewise.
8184 2014-08-07 Gary Benson <gbenson@redhat.com>
8186 * server.h: Do not include gdb_locale.h.
8188 2014-08-07 Gary Benson <gbenson@redhat.com>
8190 * server.h: Do not include gdb/signals.h.
8191 * win32-low.c: Likewise.
8193 2014-08-07 Gary Benson <gbenson@redhat.com>
8195 * server.h: Do not include pathmax.h.
8197 2014-08-07 Gary Benson <gbenson@redhat.com>
8199 * server.h: Do not include libiberty.h.
8200 * linux-bfin-low.c: Likewise.
8202 2014-08-07 Gary Benson <gbenson@redhat.com>
8204 * server.h: Do not include ansidecl.h.
8206 2014-08-07 Gary Benson <gbenson@redhat.com>
8208 * linux-x86-low.c: Do not include stddef.h.
8209 * lynx-ppc-low.c: Likewise.
8210 * tracepoint.c: Likewise.
8212 2014-08-07 Gary Benson <gbenson@redhat.com>
8214 * server.h: Do not include stdarg.h.
8215 * nto-low.c: Likewise.
8217 2014-08-07 Gary Benson <gbenson@redhat.com>
8219 * server.h: Do not include stdlib.h.
8220 * inferiors.c: Likewise.
8221 * linux-low.c: Likewise.
8222 * regcache.c: Likewise.
8223 * spu-low.c: Likewise.
8224 * tracepoint.c: Likewise.
8225 * utils.c: Likewise.
8227 2014-08-07 Gary Benson <gbenson@redhat.com>
8229 * server.h: Do not include stdio.h.
8230 * linux-low.c: Likewise.
8231 * remote-utils.c: Likewise.
8232 * spu-low.c: Likewise.
8233 * utils.c: Likewise.
8234 * wincecompat.c: Likewise.
8236 2014-08-06 Gary Benson <gbenson@redhat.com>
8238 * regcache.c (init_register_cache): Move conditionals inside if.
8240 2014-08-06 Gary Benson <gbenson@redhat.com>
8242 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
8244 2014-07-31 Gary Benson <gbenson@redhat.com>
8246 * ax.h: Do not include server.h.
8247 * gdbthread.h: Likewise.
8248 * lynx-low.h: Likewise.
8249 * notif.h: Likewise.
8251 2014-07-30 Gary Benson <gbenson@redhat.com>
8253 * server.h: Include common-defs.h.
8254 Do not include config.h or build-gnulib-gdbserver/config.h.
8256 2014-07-30 Gary Benson <gbenson@redhat.com>
8258 * hostio-errno.c: Move server.h to top of includes list.
8259 * inferiors.c: Likewise.
8260 * linux-x86-low.c: Likewise.
8261 * notif.c: Include server.h.
8263 2014-07-24 Tom Tromey <tromey@redhat.com>
8264 Gary Benson <gbenson@redhat.com>
8266 * server.h (CORE_ADDR): Now unsigned.
8268 2014-07-16 Pedro Alves <palves@redhat.com>
8270 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
8272 2014-07-15 Pedro Alves <palves@redhat.com>
8274 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
8277 2014-07-11 Pedro Alves <palves@redhat.com>
8279 * linux-low.c (kill_wait_lwp): New function, based on
8280 kill_one_lwp_callback, but use my_waitpid directly.
8281 (kill_one_lwp_callback, linux_kill): Use it.
8283 2014-06-23 Pedro Alves <palves@redhat.com>
8285 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
8286 before setting DR0..DR3.
8288 2014-06-20 Gary Benson <gbenson@redhat.com>
8290 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
8291 * configure: Regenerated.
8292 * config.in: Likewise.
8294 2014-06-20 Gary Benson <gbenson@redhat.com>
8296 * Makefile.in (SFILES): Update locations for files moved
8298 (object file files): Reordered.
8300 2014-06-20 Gary Benson <gbenson@redhat.com>
8302 * i386-low.h (i386_dr_low_can_set_addr): Removed.
8303 (i386_dr_low_set_addr): Likewise.
8304 (i386_dr_low_get_addr): Likewise.
8305 (i386_dr_low_can_set_control): Likewise.
8306 (i386_dr_low_set_control): Likewise.
8307 (i386_dr_low_get_control): Likewise.
8308 (i386_dr_low_get_status): Likewise.
8309 (i386_get_debug_register_length): Likewise.
8310 * linux-x86-low.c (i386_dr_low_set_addr):
8311 Changed signature. Made static.
8312 (i386_dr_low_get_addr): Likewise.
8313 (i386_dr_low_set_control): Likewise.
8314 (i386_dr_low_get_control): Likewise.
8315 (i386_dr_low_get_status): Likewise.
8316 (i386_dr_low): New global variable.
8317 * win32-i386-low.c (i386_dr_low_set_addr):
8318 Changed signature. Made static.
8319 (i386_dr_low_get_addr): Likewise.
8320 (i386_dr_low_set_control): Likewise.
8321 (i386_dr_low_get_control): Likewise.
8322 (i386_dr_low_get_status): Likewise.
8323 (i386_dr_low): New global variable.
8325 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
8327 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
8328 * Makefile.in (AR, AR_FLAGS): Define.
8329 * configure: Regenerate.
8331 2014-06-19 Gary Benson <gbenson@redhat.com>
8333 * Makefile.in (i386-dregs.o): New rule.
8334 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
8335 * i386-low.c (target.h): Remove include.
8336 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
8337 (DR_CONTROL_SHIFT): Likewise.
8338 (DR_CONTROL_SIZE): Likewise.
8339 (DR_RW_EXECUTE): Likewise.
8340 (DR_RW_WRITE): Likewise.
8341 (DR_RW_READ): Likewise.
8342 (DR_RW_IORW): Likewise.
8343 (DR_LEN_1): Likewise.
8344 (DR_LEN_2): Likewise.
8345 (DR_LEN_4): Likewise.
8346 (DR_LEN_8): Likewise.
8347 (DR_LOCAL_ENABLE_SHIFT): Likewise.
8348 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
8349 (DR_ENABLE_SIZE): Likewise.
8350 (DR_LOCAL_SLOWDOWN): Likewise.
8351 (DR_GLOBAL_SLOWDOWN): Likewise.
8352 (DR_CONTROL_RESERVED): Likewise.
8353 (I386_DR_CONTROL_MASK): Likewise.
8354 (I386_DR_VACANT): Likewise.
8355 (I386_DR_LOCAL_ENABLE): Likewise.
8356 (I386_DR_GLOBAL_ENABLE): Likewise.
8357 (I386_DR_DISABLE): Likewise.
8358 (I386_DR_SET_RW_LEN): Likewise.
8359 (I386_DR_GET_RW_LEN): Likewise.
8360 (I386_DR_WATCH_HIT): Likewise.
8361 (i386_wp_op_t): Likewise.
8362 (i386_show_dr): Likewise.
8363 (i386_length_and_rw_bits): Likewise.
8364 (i386_insert_aligned_watchpoint): Likewise.
8365 (i386_remove_aligned_watchpoint): Likewise.
8366 (i386_handle_nonaligned_watchpoint): Likewise.
8367 i386_update_inferior_debug_regs(): Likewise.
8368 (i386_dr_insert_watchpoint): Likewise.
8369 (i386_dr_remove_watchpoint): Likewise.
8370 (i386_dr_region_ok_for_watchpoint): Likewise.
8371 (i386_dr_stopped_data_address): Likewise.
8372 (i386_dr_stopped_by_watchpoint): Likewise.
8374 2014-06-19 Gary Benson <gbenson@redhat.com>
8376 * i386-low.c (i386_dr_show): Renamed to
8377 i386_show_dr and made static. All uses updated.
8378 (i386_dr_length_and_rw_bits): Renamed to
8379 i386_length_and_rw_bits and made static.
8381 (i386_dr_insert_aligned_watchpoint): Renamed to
8382 i386_insert_aligned_watchpoint and made static.
8384 (i386_dr_remove_aligned_watchpoint): Renamed to
8385 i386_remove_aligned_watchpoint and made static.
8387 (i386_dr_update_inferior_debug_regs): Renamed to
8388 i386_update_inferior_debug_regs and made static.
8391 2014-06-18 Gary Benson <gbenson@redhat.com>
8393 * i386-low.h (i386_dr_low_can_set_addr): New macro.
8394 (i386_dr_low_can_set_control): Likewise.
8395 (i386_get_debug_register_length): Likewise.
8396 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
8397 (i386_dr_low_can_set_control): Likewise.
8398 (i386_get_debug_register_length): Likewise.
8400 2014-06-17 Gary Benson <gbenson@redhat.com>
8402 * i386-low.h (i386-dregs.h): New include.
8403 (DR_FIRSTADDR): Now in i386-dregs.h.
8404 (DR_LASTADDR): Likewise.
8405 (DR_NADDR): Likewise.
8406 (DR_STATUS): Likewise.
8407 (DR_CONTROL): Likewise.
8408 (i386_debug_reg_state): Likewise.
8409 (i386_dr_insert_watchpoint): Likewise.
8410 (i386_dr_remove_watchpoint): Likewise.
8411 (i386_dr_region_ok_for_watchpoint): Likewise.
8412 (i386_dr_stopped_data_address): Likewise.
8413 (i386_dr_stopped_by_watchpoint): Likewise.
8414 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
8416 2014-06-18 Gary Benson <gbenson@redhat.com>
8418 * i386-low.h (i386_low_insert_watchpoint): Renamed to
8419 i386_dr_insert_watchpoint.
8420 (i386_low_remove_watchpoint): Renamed to
8421 i386_dr_remove_watchpoint.
8422 (i386_low_region_ok_for_watchpoint): Renamed to
8423 i386_dr_region_ok_for_watchpoint.
8424 (i386_low_stopped_data_address): Renamed to
8425 i386_dr_stopped_data_address.
8426 (i386_low_stopped_by_watchpoint): Renamed to
8427 i386_dr_stopped_by_watchpoint.
8428 * i386-low.c (i386_show_dr): Renamed to
8429 i386_dr_show and made nonstatic. All uses updated.
8430 (i386_length_and_rw_bits): Renamed to
8431 i386_dr_length_and_rw_bits and made nonstatic.
8433 (i386_insert_aligned_watchpoint): Renamed to
8434 i386_dr_insert_aligned_watchpoint and made nonstatic.
8436 (i386_remove_aligned_watchpoint): Renamed to
8437 i386_dr_remove_aligned_watchpoint and made nonstatic.
8439 (i386_update_inferior_debug_regs): Renamed to
8440 i386_dr_update_inferior_debug_regs and made nonstatic.
8442 (i386_low_insert_watchpoint): Renamed to
8443 i386_dr_insert_watchpoint. All uses updated.
8444 (i386_low_remove_watchpoint): Renamed to
8445 i386_dr_remove_watchpoint. All uses updated.
8446 (i386_low_region_ok_for_watchpoint): Renamed to
8447 i386_dr_region_ok_for_watchpoint. All uses updated.
8448 (i386_low_stopped_data_address): Renamed to
8449 i386_dr_stopped_data_address. All uses updated.
8450 (i386_low_stopped_by_watchpoint): Renamed to
8451 i386_dr_stopped_by_watchpoint. All uses updated.
8453 2014-06-18 Gary Benson <gbenson@redhat.com>
8455 * i386-low.c (i386_dr_low_can_set_addr): New macro.
8456 (i386_dr_low_can_set_control): Likewise.
8457 (i386_insert_aligned_watchpoint): New check.
8459 2014-06-18 Gary Benson <gbenson@redhat.com>
8461 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
8464 2014-06-18 Gary Benson <gbenson@redhat.com>
8466 * i386-low.c (i386_length_and_rw_bits): Use internal_error
8467 instead of fatal and error.
8468 (i386_handle_nonaligned_watchpoint): Likewise.
8470 2014-06-18 Gary Benson <gbenson@redhat.com>
8472 * i386-low.c (i386_get_debug_register_length): New macro.
8473 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
8474 (i386_show_dr): Use debug_printf instead of fprintf. Use
8475 phex to format values.
8477 2014-06-18 Gary Benson <gbenson@redhat.com>
8479 * i386-low.h: Comment changes.
8480 * i386-low.c: Likewise.
8482 2014-06-18 Gary Benson <gbenson@redhat.com>
8484 * i386-low.c: Whitespace changes.
8486 2014-06-12 Tom Tromey <tromey@redhat.com>
8488 * utils.c (freeargv): Remove.
8490 2014-06-12 Tom Tromey <tromey@redhat.com>
8492 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
8493 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
8494 (parse_debug_format_options): Likewise.
8495 (gdbserver_usage): Likewise.
8496 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
8497 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
8498 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
8500 ($(LIBGNU)): Depend on libiberty.
8501 (all-lib): Recurse into all subdirs.
8502 (install-only): Invoke "install" target in subdirs.
8503 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
8505 * configure: Rebuild.
8506 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
8507 for vasprintf, vsnprintf, or gettimeofday.
8508 * configure.srv: Don't add safe-ctype.o or lbasename.o to
8511 2014-06-05 Joel Brobecker <brobecker@adacore.com>
8513 * development.sh: Delete.
8514 * Makefile.in (config.status): Adjust dependency on development.sh.
8515 * configure.ac: Adjust development.sh source call.
8516 * configure: Regenerate.
8518 2014-06-02 Pedro Alves <palves@redhat.com>
8520 * ax.c (gdb_free_agent_expr): New function.
8521 * ax.h (gdb_free_agent_expr): New declaration.
8522 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
8524 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
8526 (clear_breakpoint_conditions_and_commands): New function.
8527 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
8528 (clear_breakpoint_conditions_and_commands): New declaration.
8530 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8532 * linux-aarch64-low.c (asm/ptrace.h): Include.
8534 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8536 Fix TLS access for -static -pthread.
8537 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
8538 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
8539 (thread_db_load_search, try_thread_db_load_1): Initialize it.
8541 2014-05-20 Pedro Alves <palves@redhat.com>
8543 * linux-aarch64-low.c (aarch64_insert_point)
8544 (aarch64_remove_point): No longer check whether the type is
8545 supported here. Adjust to new interface.
8546 (the_low_target): Install aarch64_supports_z_point_type as
8547 supports_z_point_type method.
8548 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
8549 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
8550 instead of a Z packet char. Adjust.
8551 (arm_supports_z_point_type): New function.
8552 (arm_insert_point, arm_remove_point): Adjust to new interface.
8553 (the_low_target): Install arm_supports_z_point_type.
8554 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
8555 (cris_insert_point, cris_remove_point): Adjust to new interface.
8556 Don't check whether the type is supported here.
8557 (the_low_target): Install cris_supports_z_point_type.
8558 * linux-low.c (linux_supports_z_point_type): New function.
8559 (linux_insert_point, linux_remove_point): Adjust to new interface.
8560 * linux-low.h (struct linux_target_ops) <insert_point,
8561 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
8562 raw_breakpoint pointer parameter.
8563 <supports_z_point_type>: New method.
8564 * linux-mips-low.c (mips_supports_z_point_type): New function.
8565 (mips_insert_point, mips_remove_point): Adjust to new interface.
8566 Use mips_supports_z_point_type.
8567 (the_low_target): Install mips_supports_z_point_type.
8568 * linux-ppc-low.c (the_low_target): Install NULL as
8569 supports_z_point_type method.
8570 * linux-s390-low.c (the_low_target): Install NULL as
8571 supports_z_point_type method.
8572 * linux-sparc-low.c (the_low_target): Install NULL as
8573 supports_z_point_type method.
8574 * linux-x86-low.c (x86_supports_z_point_type): New function.
8575 (x86_insert_point): Adjust to new insert_point interface. Use
8576 insert_memory_breakpoint. Adjust to new
8577 i386_low_insert_watchpoint interface.
8578 (x86_remove_point): Adjust to remove_point interface. Use
8579 remove_memory_breakpoint. Adjust to new
8580 i386_low_remove_watchpoint interface.
8581 (the_low_target): Install x86_supports_z_point_type.
8582 * lynx-low.c (lynx_target_ops): Install NULL as
8583 supports_z_point_type callback.
8584 * nto-low.c (nto_supports_z_point_type): New.
8585 (nto_insert_point, nto_remove_point): Adjust to new interface.
8586 (nto_target_ops): Install nto_supports_z_point_type.
8587 * mem-break.c: Adjust intro comment.
8588 (struct raw_breakpoint) <raw_type, size>: New fields.
8589 <inserted>: Update comment.
8590 <shlib_disabled>: Delete field.
8591 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8592 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8593 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8594 (raw_bkpt_type_to_target_hw_bp_type): New function.
8595 (find_enabled_raw_code_breakpoint_at): New function.
8596 (find_raw_breakpoint_at): New type and size parameters. Use them.
8597 (insert_memory_breakpoint): New function, based off
8598 set_raw_breakpoint_at.
8599 (remove_memory_breakpoint): New function.
8600 (set_raw_breakpoint_at): Reimplement.
8601 (set_breakpoint): New, based on set_breakpoint_at.
8602 (set_breakpoint_at): Reimplement.
8603 (delete_raw_breakpoint): Go through the_target->remove_point
8604 instead of assuming memory breakpoints.
8605 (find_gdb_breakpoint_at): Delete.
8606 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8607 (find_gdb_breakpoint): New function.
8608 (set_gdb_breakpoint_at): Delete.
8609 (z_type_supported): New function.
8610 (set_gdb_breakpoint_1): New function, loosely based off
8611 set_gdb_breakpoint_at.
8612 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8613 (delete_gdb_breakpoint_at): Delete.
8614 (delete_gdb_breakpoint_1): New function, loosely based off
8615 delete_gdb_breakpoint_at.
8616 (delete_gdb_breakpoint): New function.
8617 (clear_gdb_breakpoint_conditions): Rename to ...
8618 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8620 (add_condition_to_breakpoint): Make static.
8621 (add_breakpoint_condition): Take a struct breakpoint pointer
8622 instead of an address. Adjust.
8623 (gdb_condition_true_at_breakpoint): Rename to ...
8624 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8626 (gdb_condition_true_at_breakpoint): Reimplement.
8627 (add_breakpoint_commands): Take a struct breakpoint pointer
8628 instead of an address. Adjust.
8629 (gdb_no_commands_at_breakpoint): Rename to ...
8630 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8631 parameter. Return true if no breakpoint was found. Change debug
8633 (gdb_no_commands_at_breakpoint): Reimplement.
8634 (run_breakpoint_commands): Rename to ...
8635 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8636 and change return type to boolean.
8637 (run_breakpoint_commands): New function.
8638 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8639 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8640 breakpoint. Go through the_target->remove_point instead of
8641 assuming memory breakpoint.
8642 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8643 software and hardware breakpoints.
8644 (reinsert_raw_breakpoint): Go through the_target->insert_point
8645 instead of assuming memory breakpoint.
8646 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8647 software and hardware breakpoints.
8648 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8649 Check both software and hardware breakpoints.
8650 (validate_inserted_breakpoint): Assert the breakpoint is a
8651 software breakpoint. Set the inserted flag to -1 instead of
8652 setting shlib_disabled.
8653 (delete_disabled_breakpoints): Adjust.
8654 (validate_breakpoints): Only validate software breakpoints.
8655 Adjust to inserted flag change.
8656 (check_mem_read, check_mem_write): Skip breakpoint types other
8657 than software breakpoints. Adjust to inserted flag change.
8658 * mem-break.h (enum raw_bkpt_type): New enum.
8659 (raw_breakpoint, struct process_info): Forward declare.
8660 (Z_packet_to_target_hw_bp_type): Delete declaration.
8661 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8662 (set_gdb_breakpoint, delete_gdb_breakpoint)
8663 (clear_breakpoint_conditions): New declarations.
8664 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8665 (breakpoint_inserted_here): Update comment.
8666 (add_breakpoint_condition, add_breakpoint_commands): Replace
8667 address parameter with a breakpoint pointer parameter.
8668 (gdb_breakpoint_here): Update comment.
8669 (delete_gdb_breakpoint_at): Delete.
8670 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8671 * server.c (process_point_options): Take a struct breakpoint
8672 pointer instead of an address. Adjust.
8673 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8674 delete_gdb_breakpoint.
8675 * spu-low.c (spu_target_ops): Install NULL as
8676 supports_z_point_type method.
8677 * target.h: Include mem-break.h.
8678 (struct target_ops) <prepare_to_access_memory>: Update comment.
8679 <supports_z_point_type>: New field.
8680 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8681 instead of a char. Also take a raw breakpoint pointer.
8682 * win32-arm-low.c (the_low_target): Install NULL as
8683 supports_z_point_type.
8684 * win32-i386-low.c (i386_supports_z_point_type): New function.
8685 (i386_insert_point, i386_remove_point): Adjust to new interface.
8686 (the_low_target): Install i386_supports_z_point_type.
8687 * win32-low.c (win32_supports_z_point_type): New function.
8688 (win32_insert_point, win32_remove_point): Adjust to new interface.
8689 (win32_target_ops): Install win32_supports_z_point_type.
8690 * win32-low.h (struct win32_target_ops):
8691 <supports_z_point_type>: New method.
8692 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8693 instead of a char. Also take a raw breakpoint pointer.
8695 2014-05-20 Pedro Alves <palves@redhat.com>
8697 * mem-break.h: Include break-common.h.
8698 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8699 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8700 (Z_packet_to_target_hw_bp_type): New declaration.
8701 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8702 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8703 (Z_PACKET_ACCESS_WP): Delete macros.
8704 (Z_packet_to_hw_type): Delete function.
8705 * i386-low.h: Don't include break-common.h here.
8706 (Z_packet_to_hw_type): Delete declaration.
8707 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8708 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8709 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8710 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8711 * linux-aarch64-low.c: Don't include break-common.h here.
8712 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8713 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8714 (Z_packet_to_target_hw_bp_type): Delete function.
8715 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8717 (mips_insert_point, mips_remove_point): Use
8718 Z_packet_to_target_hw_bp_type.
8720 2014-05-20 Pedro Alves <palves@redhat.com>
8722 * linux-aarch64-low.c: Include break-common.h.
8723 (enum target_point_type): Delete.
8724 (Z_packet_to_point_type): Rename to ...
8725 (Z_packet_to_target_hw_bp_type): ... this, and return a
8726 target_hw_bp_type instead.
8727 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8728 instead of an enum target_point_type.
8729 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8731 (aarch64_dr_state_insert_one_point)
8732 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8733 (aarch64_handle_aligned_watchpoint)
8734 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8735 Take an enum target_hw_bp_type instead of an enum
8737 (aarch64_supports_z_point_type): New function.
8738 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8739 use Z_packet_to_target_hw_bp_type.
8741 2014-05-20 Joel Brobecker <brobecker@adacore.com>
8743 * configure.ac: Only use -Werror by default when DEVELOPMENT
8745 * configure: Regenerate.
8747 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8749 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8750 * linux-x86-low.c (X86_64_USER_REGS): New.
8751 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8753 2014-04-28 Yao Qi <yao@codesourcery.com>
8755 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8758 2014-04-25 Pedro Alves <palves@redhat.com>
8761 * linux-low.c (linux_attach_fail_reason_string): New function.
8762 (linux_attach_lwp): Delete.
8763 (linux_attach_lwp_1): Rename to ...
8764 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8765 argument. Remove "initial" parameter. Return int instead of
8766 void. Don't error or warn here.
8767 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8768 failure to attach to the tgid. Call warning when failing to
8770 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
8771 argument. Remove "initial" parameter. Return int instead of
8772 void. Don't error or warn here.
8773 (linux_attach_fail_reason_string): New declaration.
8774 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8775 interface change. Use linux_attach_fail_reason_string.
8777 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
8778 Walfred Tedeschi <walfred.tedeschi@intel.com>
8780 * Makefile.in: Added rules to handle new files
8781 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8782 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8783 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8784 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8785 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8786 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8788 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8789 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8790 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8791 i386/x32-avx512.xml.
8792 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8793 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8794 i386/x32-avx512-linux.xml.
8795 * i387-fp.c (num_avx512_k_registers): New constant for number
8797 (num_avx512_zmmh_low_registers): New constant for number of
8798 lower ZMM registers (0-15).
8799 (num_avx512_zmmh_high_registers): New constant for number of
8800 higher ZMM registers (16-31).
8801 (num_avx512_ymmh_registers): New contant for number of higher
8802 YMM registers (ymm16-31 added by avx521 on x86_64).
8803 (num_avx512_xmm_registers): New constant for number of higher
8804 XMM registers (xmm16-31 added by AVX512 on x86_64).
8805 (struct i387_xsave): Add space for AVX512 registers.
8806 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8807 Add code to handle AVX512 registers.
8808 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8809 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8810 prototypei from generated file.
8811 (tdesc_amd64_avx512_linux): Likewise.
8812 (init_registers_x32_avx512_linux): Likewise.
8813 (tdesc_x32_avx512_linux): Likewise.
8814 (init_registers_i386_avx512_linux): Likewise.
8815 (tdesc_i386_avx512_linux): Likewise.
8816 (x86_64_regmap): Add AVX512 registers.
8817 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8819 (initialize_low_arch): Add code to initialize AVX512 registers.
8821 2014-04-23 Pedro Alves <palves@redhat.com>
8823 * mem-break.c (find_gdb_breakpoint_at): Make static.
8824 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8826 2014-04-23 Pedro Alves <palves@redhat.com>
8828 * i386-low.c: Don't include break-common.h here.
8829 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8830 prototype to take target_hw_bp_type as argument instead of a Z
8832 * i386-low.h: Include break-common.h here.
8833 (Z_packet_to_hw_type): Declare.
8834 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8836 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8837 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8838 (x86_remove_point): Convert the packet number to a
8839 target_hw_bp_type before calling i386_low_remove_watchpoint.
8840 * win32-i386-low.c (i386_insert_point): Convert the packet number
8841 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8842 (i386_remove_point): Convert the packet number to a
8843 target_hw_bp_type before calling i386_low_remove_watchpoint.
8845 2014-04-23 Pedro Alves <palves@redhat.com>
8847 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8849 2014-04-10 Pedro Alves <palves@redhat.com>
8851 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8852 Check if the condition or command is NULL before checking if the
8853 breakpoint is known. On success, return true.
8854 * mem-break.h (add_breakpoint_condition): Document return.
8855 (add_breakpoint_commands): Add describing comment.
8856 * server.c (skip_to_semicolon): New function.
8857 (process_point_options): Use it.
8859 2014-04-09 Pedro Alves <palves@redhat.com>
8861 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8864 2014-02-27 Pedro Alves <palves@redhat.com>
8867 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8869 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8871 (last_thread_of_process_p): Take a PID argument instead of a
8873 (linux_wait_for_lwp): Delete.
8874 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8876 (linux_low_filter_event): New function, party factored out from
8877 linux_wait_for_event.
8878 (linux_wait_for_event): Rename to ...
8879 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8880 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8881 sigsuspend. Check for zombie leaders.
8882 (linux_wait_for_event): Reimplement as wrapper around
8883 linux_wait_for_event_filtered.
8884 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8885 a normal or signal exit is seen, it's the whole process exiting.
8886 (wait_for_sigstop): No longer a for_each_inferior callback.
8887 Rewrite on top of linux_wait_for_event_filtered.
8888 (stop_all_lwps): Call wait_for_sigstop directly.
8889 * server.c (resume, handle_target_event): Handle
8890 TARGET_WAITKIND_NO_RESUMED.
8892 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8894 * win32-low.c (psapi_get_dll_name,
8895 * win32_CreateToolhelp32Snapshot): Delete.
8896 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8897 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8899 (handle_load_dll): Add function description.
8900 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8902 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8904 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8906 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8907 base address when calling win32_add_one_solib.
8908 (handle_load_dll): Delete local variable load_addr.
8909 Remove 0x1000 offset applied to DLL base address when calling
8910 win32_add_one_solib.
8911 (handle_unload_dll): Add comment.
8913 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8915 * win32-low.c (win32_add_all_dlls): Renames
8916 win32_ensure_ntdll_loaded. Rewrite function documentation.
8917 Adjust implementation to always load all DLLs.
8918 Add 0x1000 offset to DLL base address when calling
8919 win32_add_one_solib.
8920 (child_initialization_done): New static global.
8921 (do_initial_child_stuff): Set child_initialization_done to
8922 zero during child initialization, and 1 after. Replace call
8923 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8925 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8926 (handle_unload_dll): Add function documentation.
8927 (get_child_debug_event): Ignore load and unload DLL events
8928 during child initialization.
8930 2014-02-20 Doug Evans <dje@google.com>
8932 Remove global all_lwps.
8933 * inferiors.h (ptid_of): Move here from linux-low.h.
8934 (pid_of, lwpid_of): Ditto.
8935 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8936 parameter is a struct thread_info * now.
8937 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8938 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8939 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8941 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8942 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8943 * linux-arm-low.c (update_registers_callback): Update, "entry"
8944 parameter is a struct thread_info * now.
8945 Fetch lwpid from current_inferior directly.
8946 (arm_insert_point): Pass &all_threads to find_inferior instead of
8948 (arm_remove_point): Ditto.
8949 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8950 (arm_prepare_to_resume): Fetch pid from thread.
8951 (arm_read_description): Fetch lwpid from current_inferior directly.
8952 * linux-low.c (all_lwps): Delete.
8953 (delete_lwp): Delete call to remove_inferior.
8954 (handle_extended_wait): Fetch lwpid from thread.
8955 (add_lwp): Don't set lwp->entry.id. Remove call to
8956 add_inferior_to_list.
8957 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8958 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8959 (kill_one_lwp_callback): Ditto.
8960 (linux_kill): Don't dereference NULL pointer.
8961 Fetch ptid,lwpid from thread.
8962 (get_detach_signal): Fetch ptid from thread.
8963 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8964 Simplify call to regcache_invalidate_thread.
8965 (delete_lwp_callback): Update, "entry" parameter is a
8966 struct thread_info * now. Fetch pid from thread.
8967 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8968 (status_pending_p_callback): Update, "entry" parameter is a
8969 struct thread_info * now. Fetch ptid from thread.
8970 (find_lwp_pid): Update, "entry" parameter is a
8971 struct thread_info * now.
8972 (linux_wait_for_lwp): Fetch pid from thread.
8973 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8974 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8975 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8976 (dequeue_one_deferred_signal): Ditto.
8977 (cancel_breakpoint): Fetch ptid from current_inferior.
8978 (linux_wait_for_event): Pass &all_threads to find_inferior,
8979 not &all_lwps. Fetch ptid, lwpid from thread.
8980 (count_events_callback): Update, "entry" parameter is a
8981 struct thread_info * now.
8982 (select_singlestep_lwp_callback): Ditto.
8983 (select_event_lwp_callback): Ditto.
8984 (cancel_breakpoints_callback): Ditto.
8985 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8987 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8988 (unsuspend_one_lwp): Update, "entry" parameter is a
8989 struct thread_info * now.
8990 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8992 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8993 Fetch lwpid from thread, not lwp.
8994 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8995 Pass &all_threads to find_inferior, not &all_lwps.
8996 (send_sigstop): Fetch lwpid from thread, not lwp.
8997 (send_sigstop_callback): Update, "entry" parameter is a
8998 struct thread_info * now.
8999 (suspend_and_send_sigstop_callback): Ditto.
9000 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
9001 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
9002 struct thread_info * now.
9003 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
9005 (lwp_running): Update, "entry" parameter is a
9006 struct thread_info * now.
9007 (stop_all_lwps): Fetch ptid from thread.
9008 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
9009 (linux_resume_one_lwp): Fetch lwpid from thread.
9010 (linux_set_resume_request): Update, "entry" parameter is a
9011 struct thread_info * now. Fetch pid, lwpid from thread.
9012 (resume_status_pending_p): Update, "entry" parameter is a
9013 struct thread_info * now.
9014 (need_step_over_p): Ditto. Fetch lwpid from thread.
9015 (start_step_over): Fetch lwpid from thread.
9016 (linux_resume_one_thread): Update, "entry" parameter is a
9017 struct thread_info * now. Fetch lwpid from thread.
9018 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
9019 (proceed_one_lwp): Update, "entry" parameter is a
9020 struct thread_info * now. Fetch lwpid from thread.
9021 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
9022 struct thread_info * now.
9023 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
9024 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
9025 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
9027 (regsets_store_inferior_registers): Ditto.
9028 (fetch_register, store_register): Ditto.
9029 (linux_read_memory, linux_write_memory): Ditto.
9030 (linux_request_interrupt): Ditto.
9031 (linux_read_auxv): Ditto.
9032 (linux_xfer_siginfo): Ditto.
9033 (linux_qxfer_spu): Ditto.
9034 (linux_qxfer_libraries_svr4): Ditto.
9035 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
9036 moved to inferiors.h.
9038 (get_thread_lwp): Update.
9039 (struct lwp_info): Delete member "entry". Simplify comment for
9042 * linux-mips-low.c (mips_read_description): Fetch lwpid from
9043 current_inferior directly.
9044 (update_watch_registers_callback): Update, "entry" parameter is a
9045 struct thread_info * now. Fetch pid from thread.
9046 (mips_linux_prepare_to_resume): Fetch ptid from thread.
9047 (mips_insert_point): Fetch lwpid from current_inferior.
9048 Pass &all_threads to find_inferior, not &all_lwps.
9049 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
9050 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
9052 (mips_stopped_data_address): Ditto.
9053 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
9055 * linux-tile-low.c (tile_arch_setup): Ditto.
9056 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
9057 (update_debug_registers_callback): Update, "entry" parameter is a
9058 struct thread_info * now. Fetch pid from thread.
9059 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
9060 Pass &all_threads to find_inferior, not &all_lwps.
9061 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
9062 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
9063 Pass &all_threads to find_inferior, not &all_lwps.
9064 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
9065 (i386_dr_low_get_status): Ditto.
9066 (x86_linux_prepare_to_resume): Fetch ptid from thread.
9067 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
9068 (x86_linux_read_description): Ditto.
9069 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
9071 2014-02-20 Doug Evans <dje@google.com>
9073 * inferiors.c (get_first_inferior): Fix buglet.
9075 2014-02-19 Doug Evans <dje@google.com>
9077 * gdbthread.h (add_thread): Change result type to struct thread_info *.
9078 * inferiors.c (add_thread): Change result type to struct thread_info *.
9079 All callers updated.
9080 (add_lwp): Call add_thread here instead of in callers.
9081 All callers updated.
9082 * linux-low.h (get_lwp_thread): Rewrite.
9083 (struct lwp_info): New member "thread".
9085 2014-02-19 Doug Evans <dje@google.com>
9087 * linux-low.c (add_lwp): Change result to struct lwp_info *.
9088 All callers updated.
9090 2014-02-19 Doug Evans <dje@google.com>
9092 * inferiors.c (add_thread): Fix whitespace.
9094 2014-02-19 Doug Evans <dje@google.com>
9096 * dll.c (clear_dlls): Replace accessing list implemention details
9098 * gdbthread.h (get_first_thread): Declare.
9099 * inferiors.c (for_each_inferior_with_data): New function.
9100 (get_first_thread): New function.
9101 (find_thread_ptid): Simplify.
9102 (get_first_inferior): New function.
9103 (clear_list): Delete.
9104 (one_inferior_p): New function.
9105 (clear_inferior_list): New function.
9106 (clear_inferiors): Update.
9107 * inferiors.h (for_each_inferior_with_data): Declare.
9108 (clear_inferior_list): Declare.
9109 (one_inferior_p): Declare.
9110 (get_first_inferior): Declare.
9111 * linux-low.c (linux_wait_for_event): Replace accessing list
9112 implemention details with API function.
9113 * server.c (target_running): Ditto.
9114 (accumulate_file_name_length): New function.
9115 (emit_dll_description): New function.
9116 (handle_qxfer_libraries): Replace accessing list implemention
9117 details with API function.
9118 (handle_qxfer_threads_worker): New function.
9119 (handle_qxfer_threads_proper): Replace accessing list implemention
9120 details with API function.
9121 (handle_query): Ditto.
9122 (visit_actioned_threads_callback_ftype): New typedef.
9123 (visit_actioned_threads_data): New struct.
9124 (visit_actioned_threads): Rewrite to be find_inferior callback.
9125 (resume): Call find_inferior.
9126 (handle_status): Replace accessing list implemention
9127 details with API function.
9128 (process_serial_event): Replace accessing list implemention details
9130 * target.c (set_desired_inferior): Replace accessing list implemention
9131 details with API function.
9132 * tracepoint.c (same_process_p): New function.
9133 (gdb_agent_about_to_close): Replace accessing list implemention
9134 details with API function.
9135 * win32-low.c (child_delete_thread): Replace accessing list
9136 implemention details with API function.
9137 (match_dll_by_basename): New function.
9138 (dll_is_loaded_by_basename): New function.
9139 (win32_ensure_ntdll_loaded): Replace accessing list implemention
9140 details call to dll_is_loaded_by_basename.
9142 2014-02-19 Doug Evans <dje@google.com>
9144 * dll.h (struct dll_info): Add comment.
9145 * gdbthread.h (struct thread_info): Add comment.
9146 (current_ptid): Simplify.
9147 * inferiors.c (add_process): Update.
9148 (remove_process): Update.
9149 * inferiors.h (struct process_info): Rename member "head" to "entry".
9150 * linux-low.c (delete_lwp): Update.
9152 (last_thread_of_process_p): Update.
9153 (kill_one_lwp_callback, linux_kill): Update.
9154 (status_pending_p_callback): Update.
9155 (wait_for_sigstop): Update. Simplify read of ptid.
9156 (start_step_over): Update.
9157 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
9158 (get_lwp_thread): Update.
9159 (struct lwp_info): Rename member "head" to "entry".
9160 * regcache.h (inferior_list_entry): Delete.
9161 * server.c (kill_inferior_callback): Update.
9162 (detach_or_kill_inferior_callback): Update.
9163 (print_started_pid): Update.
9164 (print_attached_pid): Update.
9165 (process_serial_event): Simplify read of ptid.
9166 * thread-db.c (thread_db_create_event): Update.
9167 (thread_db_get_tls_address): Update.
9168 * win32-low.c (current_inferior_ptid): Simplify.
9170 2014-02-19 Tom Tromey <tromey@redhat.com>
9172 * target.h (struct target_ops) <supports_btrace>: Add target_ops
9174 (target_supports_btrace): Update.
9176 2014-02-14 Yao Qi <yao@codesourcery.com>
9178 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
9179 (rsp-low-ipa.o): New target.
9181 2014-02-12 Tom Tromey <tromey@redhat.com>
9183 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
9184 convert_ascii_to_int.
9185 * regcache.c (registers_to_string): Likewise.
9186 * remote-utils.c (decode_M_packet): Likewise.
9187 * server.c (process_serial_event): Likewise.
9189 2014-02-12 Tom Tromey <tromey@redhat.com>
9191 * server.c (handle_query, handle_v_run): Use hex2bin, not
9193 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
9195 2014-02-12 Tom Tromey <tromey@redhat.com>
9197 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
9198 convert_int_to_ascii.
9199 * regcache.c (registers_to_string, collect_register_as_string):
9201 * remote-utils.c (look_up_one_symbol, relocate_instruction):
9203 * server.c (process_serial_event): Likewise.
9204 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
9205 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
9207 2014-02-12 Tom Tromey <tromey@redhat.com>
9209 * remote-utils.c (look_up_one_symbol, monitor_output): Use
9210 bin2hex, not hexify.
9211 * tracepoint.c (cmd_qtstatus): Likewise.
9213 2014-02-12 Tom Tromey <tromey@redhat.com>
9215 * remote-utils.c (monitor_output): Pass explicit length to
9218 2014-02-12 Tom Tromey <tromey@redhat.com>
9220 * tracepoint.c: Include rsp-low.h.
9221 * server.c: Include rsp-low.h.
9222 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
9223 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
9225 * remote-utils.c: Include rsp-low.h.
9226 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
9227 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
9228 (convert_int_to_ascii, convert_ascii_to_int): Move to
9230 * regcache.c: Include rsp-low.h.
9231 * ax.c: Include rsp-low.h.
9232 * Makefile.in (SFILES): Add common/rsp-low.c.
9233 (OBS): Add rsp-low.o.
9234 (rsp-low.o): New target.
9236 2014-02-12 Tom Tromey <tromey@redhat.com>
9238 * utils.h (pulongest, plongest, phex_nz): Don't declare.
9239 Include print-utils.h.
9240 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
9241 (plongest, thirty_two, phex_nz): Remove.
9242 * Makefile.in (SFILES): Add common/print-utils.c.
9243 (OBS): Add print-utils.o.
9244 (print-utils-ipa.o): New target.
9245 (print-utils.o): New target.
9246 (IPA_OBJS): Add print-utils-ipa.o.
9248 2014-02-06 Tom Tromey <tromey@redhat.com>
9250 * Makefile.in (SFILES): Fix indentation.
9252 2014-02-05 Doug Evans <dje@google.com>
9254 * linux-low.c (linux_wait_for_event): Improve comment.
9255 (linux_wait_1): Keep current_inferior in sync with event_child.
9257 2014-01-22 Doug Evans <dje@google.com>
9259 * gdbthread.h (gdb_id_to_thread): Delete, unused.
9261 2014-01-22 Doug Evans <dje@google.com>
9263 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
9264 * configure: Regenerate.
9265 * config.in: Regenerate.
9266 * Makefile.in (SFILES): Add debug.c.
9268 * debug.c: New file.
9269 * debug.h: New file.
9270 * linux-aarch64-low.c (*): Update all debugging printfs to use
9271 debug_printf instead of fprintf.
9272 * linux-arm-low.c (*): Ditto.
9273 * linux-cris-low.c (*): Ditto.
9274 * linux-crisv32-low.c (*): Ditto.
9275 * linux-m32r-low.c (*): Ditto.
9276 * linux-sparc-low.c (*): Ditto.
9277 * linux-x86.c (*): Ditto.
9278 * linux-low.c (*): Ditto.
9279 (linux_wait_1): Add calls to debug_enter, debug_exit.
9280 (linux_wait): Remove redundant debugging printf.
9281 (stop_all_lwps): Add calls to debug_enter, debug_exit.
9282 (linux_resume, unstop_all_lwps): Ditto.
9283 * mem-break.c (*): Update all debugging printfs to use
9284 debug_printf instead of fprintf.
9285 * remote-utils.c (*): Ditto.
9286 * thread-db.c (*): Ditto.
9287 * server.c #include <ctype.h>, "gdb_vecs.h".
9288 (debug_threads): Moved to debug.c.
9289 (*): Update all debugging printfs to use debug_printf instead of
9291 (start_inferior): Replace call to fflush with call to debug_flush.
9292 (monitor_show_help): Mention set debug-format.
9293 (parse_debug_format_options): New function.
9294 (handle_monitor_command): Handle "monitor set debug-format".
9295 (gdbserver_usage): Mention --debug-format.
9296 (main): Parse --debug-format.
9297 * server.h (debug_threads): Declaration moved to debug.h.
9299 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
9300 trace_debug_1 that uses debug_printf.
9301 (tracepoint_look_up_symbols): Update all debugging printfs to use
9302 debug_printf instead of fprintf.
9304 2014-01-20 Baruch Siach <baruch@tkos.co.il>
9306 * linux-xtensa-low.c: Include asm/ptrace.h instead of
9309 2014-01-17 Pedro Alves <palves@redhat.com>
9312 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
9313 defined after including gdb_proc_service.h.
9315 2014-01-16 Doug Evans <dje@google.com>
9317 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
9318 (match_dll): Use it.
9320 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
9322 * target.h (target_ops) <read_btrace>: Change parameters and
9323 return type to allow error reporting.
9324 * server.c (handle_qxfer_btrace): Support delta reads. Pass
9325 trace reading errors on.
9326 * linux-low.c (linux_low_read_btrace): Pass trace reading
9328 (linux_low_disable_btrace): New.
9330 2014-01-15 Doug Evans <dje@google.com>
9332 * inferiors.c (thread_id_to_gdb_id): Delete.
9333 * inferiors.h (thread_id_to_gdb_id): Delete.
9335 2014-01-13 Eli Zaretskii <eliz@gnu.org>
9337 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
9338 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
9341 2014-01-08 Pedro Alves <palves@redhat.com>
9343 * server.c (handle_status): Don't discard previous queued stop
9344 replies or thread's pending status here.
9345 (main) <disconnection>: Do it here instead.
9347 2014-01-08 Pedro Alves <palves@redhat.com>
9349 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
9350 * server.c (visit_actioned_threads, handle_pending_status): New
9352 (handle_v_cont): Factor out parts to ...
9353 (resume): ... this new function. If in all-stop, and a thread
9354 being resumed has a pending status, report it without actually
9356 (myresume): Adjust to use the new 'resume' function.
9357 (clear_pending_status_callback, set_pending_status_callback)
9358 (find_status_pending_thread_callback): New functions.
9359 (handle_status): Handle the case of multiple threads having
9360 interesting statuses to report. Report threads' real last signal
9361 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
9362 with an interesting thread to report the status for, instead of
9363 always reporting the status of the first thread.
9365 2014-01-01 Joel Brobecker <brobecker@adacore.com>
9367 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
9368 * gdbreplay.c (gdbreplay_version): Likewise.
9370 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
9372 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
9373 iov.iov_len with the real length in use.
9375 2013-12-13 Joel Brobecker <brobecker@adacore.com>
9377 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
9378 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
9379 for all targets that use win32-low.c.
9380 * win32-low.c (win32_ensure_ntdll_loaded): New function.
9381 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
9383 2013-12-13 Pedro Alves <palves@redhat.com>
9385 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
9386 if equal to TARGET_WAITKIND_LOADED.
9387 * win32-low.c (cached_status): New static global.
9388 (win32_wait): Add declaration.
9389 (do_initial_child_stuff): Flush all initial pending debug events
9390 up to the initial breakpoint.
9391 (win32_wait): If CACHED_STATUS was set, return that instead
9392 of doing a real wait. Remove the code resuming the execution
9393 of the inferior after receiving a TARGET_WAITKIND_LOADED event
9394 during the initial phase. Also remove the code changing
9395 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
9396 TARGET_WAITKIND_STOPPED.
9398 2013-12-11 Yao Qi <yao@codesourcery.com>
9400 * notif.c (handle_notif_ack): Return 0 if no notification
9403 2013-11-20 Doug Evans <dje@google.com>
9405 * linux-low.c (linux_set_resume_request): Fix comment.
9407 2013-11-20 Doug Evans <dje@google.com>
9409 * linux-low.c (resume_status_pending_p): Tweak comment.
9411 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
9413 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
9414 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
9415 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
9416 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
9417 (srv_amd64_regobj): Add amd64-mpx.o.
9418 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
9419 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
9420 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
9421 * i387-fp.c (num_pl_bnd_register) Added constant.
9422 (num_pl_bnd_cfg_registers) Added constant.
9423 (struct i387_xsave) Added reserved area and MPX fields.
9424 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
9425 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
9427 (tdesc_i386_mpx_linux): Add MPX amd64 target.
9428 (init_registers_amd64_mpx_linux): Declare new function.
9429 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
9430 (x86_64_regmap): Add MPX registers.
9431 (x86_linux_read_description): Add MPX case.
9432 (initialize_low_arch): Initialize MPX targets.
9434 2013-11-18 Tom Tromey <tromey@redhat.com>
9436 * configure: Rebuild.
9437 * configure.ac: Don't check for stdlib.h.
9438 * gdbreplay.c: Unconditionally include stdlib.h.
9440 2013-11-18 Tom Tromey <tromey@redhat.com>
9442 * config.in: Rebuild.
9443 * configure: Rebuild.
9444 * configure.ac: Don't use AC_HEADER_DIRENT.
9446 2013-11-18 Tom Tromey <tromey@redhat.com>
9448 * server.h: Don't check HAVE_STRING_H.
9449 * gdbreplay.c: Don't check HAVE_STRING_H.
9450 * configure: Rebuild.
9452 2013-11-18 Tom Tromey <tromey@redhat.com>
9454 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
9457 2013-11-08 Tom Tromey <tromey@redhat.com>
9459 * configure, config.in: Rebuild.
9460 * configure.ac: Remove unused configury.
9462 2013-11-08 Tom Tromey <tromey@redhat.com>
9464 * acinclude.m4: Include common.m4, codeset.m4.
9465 * configure, config.in: Rebuild.
9466 * configure.ac: Use GDB_AC_COMMON.
9468 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
9470 * linux-s390-low.c (HWCAP_S390_TE): New define.
9471 (s390_arch_setup): Consider the TE field in the HWCAP for
9472 determining 'have_regset_tdb'.
9474 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
9477 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
9480 2013-10-02 Pedro Alves <palves@redhat.com>
9482 * server.c (process_serial_event): Don't output "GDBserver
9483 exiting" if GDB is connected through stdio.
9484 * target.c (mywait): Likewise, be silent if GDB is connected
9487 2013-10-01 Joel Brobecker <brobecker@adacore.com>
9489 * lynx-low.c (lynx_add_threads_after_attach): New function.
9490 (lynx_attach): Remove call to add_thread. Add call to
9491 lynx_add_threads_after_attach instead.
9493 2013-09-28 Mike Frysinger <vapier@gentoo.org>
9495 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
9496 * config.in, configure: Regenerated.
9498 2013-09-18 Yao Qi <yao@codesourcery.com>
9501 * server.c (start_inferior): Clear 'resume_info'.
9503 2013-09-16 Jiong Wang <jiwang@tilera.com>
9505 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
9508 2013-09-16 Jiong Wang <jiwang@tilera.com>
9510 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
9511 linux-tile-low.o to srv_tgtobj.
9513 2013-09-16 Will Newton <will.newton@linaro.org>
9515 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
9518 2013-09-06 Pedro Alves <palves@redhat.com>
9520 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
9521 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
9522 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
9523 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
9524 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
9525 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
9527 2013-09-06 Pedro Alves <palves@redhat.com>
9529 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
9530 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
9532 2013-09-06 Pedro Alves <palves@redhat.com>
9534 * linux-amd64-ipa.c: Include tracepoint.h.
9535 * linux-i386-ipa.c: Include tracepoint.h.
9537 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9539 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
9540 (ps_get_thread_area): New function.
9542 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9544 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
9545 (initialize_low_arch): Call init_registers_crisv32 rather than
9546 init_register_crisv32.
9548 2013-09-05 Pedro Alves <palves@redhat.com>
9550 * server.h (handle_vFile, hostio_last_error_from_errno): Move
9552 * hostio.h: ... this new file.
9553 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
9554 win32-low.c: Include hostio.h.
9556 2013-09-05 Pedro Alves <palves@redhat.com>
9558 * server.h (gdb_client_data, handler_func, callback_handler_func)
9559 (delete_file_handler, add_file_handler, append_callback_event)
9560 (delete_callback_event, start_event_loop, initialize_event_loop):
9561 Move to event-loop.h and include it.
9562 * event-loop.h: New file.
9564 2013-09-05 Pedro Alves <palves@redhat.com>
9566 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
9567 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
9568 (loaded_dll, unloaded_dll): Move to ...
9569 * dll.h: ... this new file.
9570 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
9572 2013-09-05 Pedro Alves <palves@redhat.com>
9574 * server.h (current_process, get_thread_process, all_processes)
9575 (add_inferior_to_list, for_each_inferior, current_inferior)
9576 (remove_inferior, add_process, remove_process, find_process_pid)
9577 (have_started_inferiors_p, have_attached_inferiors_p)
9578 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
9579 (clear_inferiors, find_inferior, find_inferior_id)
9580 (inferior_target_data, set_inferior_target_data)
9581 (inferior_regcache_data, set_inferior_regcache_data): Move to
9582 inferiors.h, and include it.
9583 * inferiors.h: New file.
9585 2013-09-05 Pedro Alves <palves@redhat.com>
9587 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9591 2013-09-05 Pedro Alves <palves@redhat.com>
9593 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9595 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9596 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9597 (handle_tracepoint_general_set, handle_tracepoint_query)
9598 (tracepoint_finished_step, tracepoint_was_hit)
9599 (release_while_stepping_state_list, current_traceframe)
9600 (in_readonly_region, traceframe_read_mem)
9601 (fetch_traceframe_registers, traceframe_read_sdata)
9602 (traceframe_read_info, struct fast_tpoint_collect_status)
9603 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9604 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9605 (supply_fast_tracepoint_registers)
9606 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9607 (ipa_tdesc, claim_trampoline_space)
9608 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9609 (agent_mem_read, agent_get_trace_state_variable_value)
9610 (agent_set_trace_state_variable_value, agent_tsv_read)
9611 (agent_mem_read_string, get_raw_reg_func_addr)
9612 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9613 * tracepoint.h: ... this new file.
9615 2013-09-05 Pedro Alves <palves@redhat.com>
9617 * server.h (perror_with_name, error, fatal, warning, paddress)
9618 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9620 * utils.h: New file.
9622 2013-09-05 Pedro Alves <palves@redhat.com>
9624 * server.h (remote_debug, noack_mode, transport_is_reliable)
9625 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9626 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9627 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9628 (write_enn, initialize_async_io, enable_async_io)
9629 (disable_async_io, check_remote_input_interrupt_request)
9630 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9631 (dead_thread_notify, prepare_resume_reply)
9632 (decode_address_to_semicolon, decode_address, decode_m_packet)
9633 (decode_M_packet, decode_X_packet, decode_xfer_write)
9634 (decode_search_memory_packet, unhexify, hexify)
9635 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9636 (look_up_one_symbol, relocate_instruction)
9637 (monitor_output): Move to remote-utils.h, and include it.
9638 * remote-utils.h: New file.
9640 2013-09-05 Pedro Alves <palves@redhat.com>
9642 * server.h (_): Delete.
9644 2013-09-02 Pedro Alves <palves@redhat.com>
9646 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9647 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9649 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9651 2013-09-02 Pierre Muller <muller@sourceware.org>
9653 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9654 or WriteProcessMemory complete successfully and handle
9655 ERROR_PARTIAL_COPY error.
9657 2013-09-02 Pedro Alves <palves@redhat.com>
9659 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9660 error instead of EIO.
9662 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9665 * linux-low.c: Include filestuff.h.
9666 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9667 * lynx-low.c: Include filestuff.h.
9668 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9669 * server.c: Include filestuff.h.
9670 (main): Call notice_open_fds.
9671 * spu-low.c: Include filestuff.h.
9672 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9674 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
9676 * Makefile.in: Explain why ../target and ../nat are not
9677 listed as include file search paths.
9678 (linux-waitpid.o): New object file rule.
9679 * configure.srv (srv_native_linux_obj): New variable.
9680 Replace all occurrences of linux native object files with
9681 $srv_native_linux_obj.
9682 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9683 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9684 (linux_enable_event_reporting): Remove declaration.
9685 (my_waitpid): Moved to common/linux-waitpid.c.
9686 (linux_wait_for_event): Pass ptid when calling
9687 linux_enable_event_reporting.
9688 (linux_supports_tracefork_flag): Remove.
9689 (linux_enable_event_reporting): Likewise.
9690 (linux_tracefork_grandchild): Remove.
9691 (STACK_SIZE): Moved to common/linux-ptrace.c.
9692 (linux_tracefork_child): Remove.
9693 (linux_test_for_tracefork): Remove.
9694 (linux_look_up_symbols): Call linux_supports_traceclone.
9695 (initialize_low): Remove call to linux_test_for_tracefork.
9696 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9697 common/linux-ptrace.h.
9698 (PTRACE_TYPE_ARG4): Likewise.
9699 Include linux-ptrace.h.
9701 2013-08-21 Pedro Alves <palves@redhat.com>
9703 * config.in: Renegerate.
9705 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
9707 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9708 (SFILES): Remove $(srcdir)/common/target-common.c and
9709 add $(srcdir)/target/waitstatus.c.
9710 (OBS): Remove target-common.o and add waitstatus.o.
9711 (server_h): Remove $(srcdir)/../common/target-common.h and
9712 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9713 and $(srcdir)/../target/waitstatus.h.
9714 (target-common.o): Remove.
9715 (waitstatus.o): New target object file.
9716 * target.h: Do not include target-common.h and
9717 include target/resume.h, target/wait.h and
9718 target/waitstatus.h.
9720 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
9722 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9723 to PTRACE_TYPE_ARG3.
9724 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9725 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9727 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9728 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9730 2013-07-27 Jie Zhang <jie@codesourcery.com>
9731 Daniel Jacobowitz <dan@codesourcery.com>
9732 Yao Qi <yao@codesourcery.com>
9734 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9735 (mips-linux-watch.o): New rule.
9736 (mips_linux_watch_h): New variable.
9737 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9739 * linux-mips-low.c: Include mips-linux-watch.h.
9740 (struct arch_process_info, struct arch_lwp_info): New.
9741 (update_watch_registers_callback): New function.
9742 (mips_linux_new_process, mips_linux_new_thread) New functions.
9743 (mips_linux_prepare_to_resume, mips_insert_point): New
9745 (mips_remove_point, mips_stopped_by_watchpoint): New
9747 (rsp_bp_type_to_target_hw_bp_type): New function.
9748 (mips_stopped_data_address): New function.
9749 (the_low_target): Add watchpoint support functions.
9751 2013-07-27 Yao Qi <yao@codesourcery.com>
9753 * i386-low.c: Include break-common.h.
9754 (enum target_hw_bp_type): Remove.
9756 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
9758 * Makefile.in (SFILES): /common/target-common.c.
9759 (OBS): Add target-common.o.
9760 (server_h): Add $(srcdir)/../common/target-common.h.
9761 (target-common.o): New target.
9762 * server.c (queue_stop_reply_callback): Free
9763 status string after use.
9764 * target.c (target_waitstatus_to_string): Remove.
9765 * target.h: Include target-common.h.
9766 (resume_kind): Likewise.
9767 (target_waitkind): Likewise.
9768 (target_waitstatus): Likewise.
9769 (TARGET_WNOHANG): Likewise.
9771 2013-07-04 Yao Qi <yao@codesourcery.com>
9773 * Makefile.in (host_alias): Use @host_noncanonical@.
9774 (target_alias): Use @target_noncanonical@.
9775 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9776 ACX_NONCANONICAL_HOST.
9777 * configure: Regenerated.
9780 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9782 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9783 * configure: Rebuild.
9784 * Makefile.in (version_host, version_target): Get from configure.
9785 (version.c): Use $(version_host) and $(version_target).
9787 2013-07-03 Pedro Alves <palves@redhat.com>
9789 * Makefile.in (config.status): Depend on development.sh.
9790 * acinclude.m4: Include libmcheck.m4.
9791 * configure: Regenerate.
9793 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9795 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9796 attribute inside the parentheses.
9797 (winapi_DebugSetProcessKillOnExit): Ditto.
9798 (winapi_DebugBreakProcess): Ditto.
9799 (winapi_GenerateConsoleCtrlEvent): Ditto.
9801 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9803 * notif.h (notif_event): Add a dummy member to avoid compiler
9806 2013-07-01 Pedro Alves <palves@redhat.com>
9808 * hostio.c (HOSTIO_PATH_MAX): Define.
9809 (require_filename, handle_open, handle_unlink, handle_readlink):
9812 2013-07-01 Pedro Alves <palves@redhat.com>
9814 * server.h: Include "pathmax.h".
9815 * linux-low.c: Don't include sys/param.h.
9816 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9818 * win32-low.c: Don't include sys/param.h.
9819 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9821 2013-07-01 Pedro Alves <palves@redhat.com>
9823 * event-loop.c: Don't check HAVE_UNISTD_H before including
9825 * gdbreplay.c: Likewise.
9826 * remote-utils.c: Likewise.
9827 * server.c: Likewise.
9828 * configure.ac: Don't check for unistd.h.
9829 * configure: Regenerate.
9831 2013-06-28 Tom Tromey <tromey@redhat.com>
9833 * Makefile.in (version.c): Use version.in, not
9836 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9838 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9839 * configure: Rebuild.
9840 * Makefile.in (version_host, version_target): Get from configure.
9841 (version.c): Use $(version_host) and $(version_target).
9843 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9845 Fix trace-status to output user name without trailing colon.
9846 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9848 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9850 Fix trace-status to output proper start-time and stop-time.
9851 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9852 output start time and stop time in hex as gdb expects.
9854 2013-06-26 Pedro Alves <pedro@codesourcery.com>
9856 * tracepoint.c (build_traceframe_info_xml): Output trace state
9857 variables present in the trace buffer.
9859 2013-06-24 Tom Tromey <tromey@redhat.com>
9861 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9863 (version.o): Remove.
9864 * gdbreplay.c: Include version.h.
9865 (version, host_name): Don't declare.
9866 * server.h: Include version.h.
9867 (version, host_name): Don't declare.
9869 2013-06-12 Pedro Alves <palves@redhat.com>
9871 * linux-x86-low.c (linux_is_elf64): Delete global.
9872 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9873 with local linux_pid_exe_is_elf_64_file use.
9875 2013-06-11 Pedro Alves <palves@redhat.com>
9877 * linux-low.c (regset_disabled, disable_regset): New functions.
9878 (regsets_fetch_inferior_registers)
9879 (regsets_store_inferior_registers): Use them.
9880 (initialize_regsets_info); Don't allocate the disabled_regsets
9882 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9885 2013-06-11 Pedro Alves <palves@redhat.com>
9887 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9890 2013-06-11 Pedro Alves <palves@redhat.com>
9892 * linux-x86-low.c (initialize_low_arch): Call
9893 init_registers_x32_avx_linux.
9895 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9897 Fix compatibility with Android Bionic.
9898 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9901 2013-06-07 Pedro Alves <palves@redhat.com>
9904 * Makefile.in (OBS): Add tdesc.o.
9905 (IPA_OBJS): Add tdesc-ipa.o.
9906 (tdesc-ipa.o): New rule.
9907 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9909 * linux-low.c (new_inferior): Delete.
9910 (disabled_regsets, num_regsets): Delete.
9911 (linux_add_process): Adjust to set the new per-process
9913 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9914 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9915 was a stop. When calling arch_setup, switch the current inferior
9916 to the thread that got an event.
9917 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9918 (regsets_fetch_inferior_registers)
9919 (regsets_store_inferior_registers): New regsets_info parameter.
9921 (linux_register_in_regsets): New regs_info parameter. Adjust to
9923 (register_addr, fetch_register, store_register): New usrregs_info
9924 parameter. Adjust to use it.
9925 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9926 parameter regs_info. Adjust to use it.
9927 (linux_fetch_registers): Get the current inferior's regs_info, and
9929 (linux_store_registers): Ditto.
9930 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9931 (initialize_low): Don't initialize the target_regsets here. Call
9932 initialize_low_arch.
9933 * linux-low.h (target_regsets): Delete declaration.
9934 (struct regsets_info): New.
9935 (struct usrregs_info): New.
9936 (struct regs_info): New.
9937 (struct process_info_private) <new_inferior>: New field.
9938 (struct linux_target_ops): Delete the num_regs, regmap, and
9939 regset_bitmap fields. New field regs_info.
9940 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9941 * i387-fp.c (num_xmm_registers): Delete.
9942 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9943 calls to new interface.
9944 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9945 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9946 Infer the number of xmm registers from the regcache's target
9948 * i387-fp.h (num_xmm_registers): Delete.
9949 * inferiors.c (add_thread): Don't install the thread's regcache
9951 * proc-service.c (gregset_info): Fetch the current inferior's
9952 regs_info. Adjust to use it.
9953 * regcache.c: Include tdesc.h.
9954 (register_bytes, reg_defs, num_registers)
9955 (gdbserver_expedite_regs): Delete.
9956 (get_thread_regcache): If the thread doesn't have a regcache yet,
9957 create one, instead of aborting gdbserver.
9958 (regcache_invalidate_one): Rename to ...
9959 (regcache_invalidate_thread): ... this.
9960 (regcache_invalidate_one): New.
9961 (regcache_invalidate): Only invalidate registers of the current
9963 (init_register_cache): Add target_desc parameter, and use it.
9964 (new_register_cache): Ditto. Assert the target description has a
9965 non zero registers_size.
9966 (regcache_cpy): Add assertions. Adjust.
9967 (realloc_register_cache, set_register_cache): Delete.
9968 (registers_to_string, registers_from_string): Adjust.
9969 (find_register_by_name, find_regno, find_register_by_number)
9970 (register_cache_size): Add target_desc parameter, and use it.
9971 (free_register_cache_thread, free_register_cache_thread_one)
9972 (regcache_release, register_cache_size): New.
9973 (register_size): Add target_desc parameter, and use it.
9974 (register_data, supply_register, supply_register_zeroed)
9975 (supply_regblock, supply_register_by_name, collect_register)
9976 (collect_register_as_string, collect_register_by_name): Adjust.
9977 * regcache.h (struct target_desc): Forward declare.
9978 (struct regcache) <tdesc>: New field.
9979 (init_register_cache, new_register_cache): Add target_desc
9981 (regcache_invalidate_thread): Declare.
9982 (regcache_invalidate_one): Delete declaration.
9983 (regcache_release): Declare.
9984 (find_register_by_number, register_cache_size, register_size)
9985 (find_regno): Add target_desc parameter.
9986 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9988 * remote-utils.c: Include tdesc.h.
9989 (outreg, prepare_resume_reply): Adjust.
9990 * server.c: Include tdesc.h.
9991 (gdbserver_xmltarget): Delete declaration.
9992 (get_features_xml, process_serial_event): Adjust.
9993 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9995 (struct process_info) <tdesc>: New field.
9996 (ipa_tdesc): Declare.
9997 * tdesc.c: New file.
9998 * tdesc.h: New file.
9999 * tracepoint.c: Include tdesc.h.
10000 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
10001 (get_context_regcache): Adjust to pass ipa_tdesc down.
10002 (do_action_at_tracepoint): Adjust to get the register cache size
10003 from the context regcache's description.
10004 (traceframe_walk_blocks): Adjust to get the register cache size
10005 from the current trace frame's description.
10006 (traceframe_get_pc): Adjust to get current trace frame's
10007 description and pass it down.
10008 (gdb_collect): Adjust to get the register cache size from the
10010 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
10011 (gdbserver_xmltarget): Delete.
10012 (initialize_low_tracepoint): Set the ipa's target description.
10013 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
10014 (initialize_low_tracepoint): Set the ipa's target description.
10015 * linux-x86-low.c: Include tdesc.h.
10016 [__x86_64__] (is_64bit_tdesc): New.
10017 (ps_get_thread_area, x86_get_thread_area): Use it.
10018 (i386_cannot_store_register): Rename to ...
10019 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
10020 (i386_cannot_fetch_register): Rename to ...
10021 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
10022 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
10024 (target_regsets): Rename to ...
10025 (x86_regsets): ... this.
10026 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
10028 (x86_siginfo_fixup): Use is_64bit_tdesc.
10029 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
10030 (tdesc_x32_avx_linux, tdesc_x32_linux)
10031 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
10033 (x86_linux_update_xmltarget): Delete.
10034 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
10035 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
10036 (AMD64_LINUX_USER64_CS): New.
10037 (x86_linux_read_description): New, based on
10038 x86_linux_update_xmltarget.
10039 (same_process_callback): New.
10040 (x86_arch_setup_process_callback): New.
10041 (x86_linux_update_xmltarget): New.
10042 (x86_regsets_info): New.
10043 (amd64_linux_regs_info): New.
10044 (i386_linux_usrregs_info): New.
10045 (i386_linux_regs_info): New.
10046 (x86_linux_regs_info): New.
10047 (x86_arch_setup): Reimplement.
10048 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
10049 (x86_emit_ops): Ditto.
10050 (the_low_target): Adjust. Install x86_linux_regs_info,
10051 x86_cannot_fetch_register, and x86_cannot_store_register.
10052 (initialize_low_arch): New.
10053 * linux-ia64-low.c (tdesc_ia64): Declare.
10054 (ia64_fetch_register): Adjust.
10055 (ia64_usrregs_info, regs_info): New globals.
10056 (ia64_regs_info): New function.
10057 (the_low_target): Adjust.
10058 (initialize_low_arch): New function.
10059 * linux-sparc-low.c (tdesc_sparc64): Declare.
10060 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
10062 (sparc_arch_setup): New function.
10063 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
10064 (the_low_target): Adjust.
10065 (initialize_low_arch): New function.
10066 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
10067 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
10068 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
10069 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
10070 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
10071 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
10072 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
10073 (tdesc_powerpc_isa205_vsx64l): Declare.
10074 (ppc_cannot_store_register, ppc_collect_ptrace_register)
10075 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
10076 (ppc_set_pc, ppc_get_hwcap): Adjust.
10077 (ppc_usrregs_info): Forward declare.
10078 (!__powerpc64__) ppc_regmap_adjusted: New global.
10079 (ppc_arch_setup): Adjust to the current process'es target
10081 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
10082 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
10083 (ppc_store_evrregset): Adjust.
10084 (target_regsets): Rename to ...
10085 (ppc_regsets): ... this, and make static.
10086 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
10087 (ppc_regs_info): New function.
10088 (the_low_target): Adjust.
10089 (initialize_low_arch): New function.
10090 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
10091 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
10092 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
10093 (tdesc_s390x_linux64v2): Declare.
10094 (s390_collect_ptrace_register, s390_supply_ptrace_register)
10095 (s390_fill_gregset, s390_store_last_break): Adjust.
10096 (target_regsets): Rename to ...
10097 (s390_regsets): ... this, and make static.
10098 (s390_get_pc, s390_set_pc): Adjust.
10099 (s390_get_hwcap): New target_desc parameter, and use it.
10100 [__s390x__] (have_hwcap_s390_high_gprs): New global.
10101 (s390_arch_setup): Adjust to set the current process'es target
10102 description. Don't adjust the regmap.
10103 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
10104 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
10105 (regs_info_3264): New globals.
10106 (s390_regs_info): New function.
10107 (the_low_target): Adjust.
10108 (initialize_low_arch): New function.
10109 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
10110 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
10111 [__mips64] (init_registers_mips_linux)
10112 (init_registers_mips_dsp_linux): Delete defines.
10113 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
10114 (have_dsp): New global.
10115 (mips_read_description): New, based on mips_arch_setup.
10116 (mips_arch_setup): Reimplement.
10117 (get_usrregs_info): New function.
10118 (mips_cannot_fetch_register, mips_cannot_store_register)
10119 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
10120 (mips_fill_fpregset, mips_store_fpregset): Adjust.
10121 (target_regsets): Rename to ...
10122 (mips_regsets): ... this, and make static.
10123 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
10124 (dsp_regs_info, regs_info): New globals.
10125 (mips_regs_info): New function.
10126 (the_low_target): Adjust.
10127 (initialize_low_arch): New function.
10128 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
10129 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
10131 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
10132 (arm_read_description): New, with bits factored from
10134 (arm_arch_setup): Reimplement.
10135 (target_regsets): Rename to ...
10136 (arm_regsets): ... this, and make static.
10137 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
10138 (arm_regs_info): New function.
10139 (the_low_target): Adjust.
10140 (initialize_low_arch): New function.
10141 * linux-m68k-low.c (tdesc_m68k): Declare.
10142 (target_regsets): Rename to ...
10143 (m68k_regsets): ... this, and make static.
10144 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
10145 (m68k_regs_info): New function.
10146 (m68k_arch_setup): New function.
10147 (the_low_target): Adjust.
10148 (initialize_low_arch): New function.
10149 * linux-sh-low.c (tdesc_sharch): Declare.
10150 (target_regsets): Rename to ...
10151 (sh_regsets): ... this, and make static.
10152 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
10153 (sh_regs_info, sh_arch_setup): New functions.
10154 (the_low_target): Adjust.
10155 (initialize_low_arch): New function.
10156 * linux-bfin-low.c (tdesc_bfin): Declare.
10157 (bfin_arch_setup): New function.
10158 (bfin_usrregs_info, regs_info): New globals.
10159 (bfin_regs_info): New function.
10160 (the_low_target): Adjust.
10161 (initialize_low_arch): New function.
10162 * linux-cris-low.c (tdesc_cris): Declare.
10163 (cris_arch_setup): New function.
10164 (cris_usrregs_info, regs_info): New globals.
10165 (cris_regs_info): New function.
10166 (the_low_target): Adjust.
10167 (initialize_low_arch): New function.
10168 * linux-cris-low.c (tdesc_crisv32): Declare.
10169 (cris_arch_setup): New function.
10170 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
10171 (cris_regs_info): New function.
10172 (the_low_target): Adjust.
10173 (initialize_low_arch): New function.
10174 * linux-m32r-low.c (tdesc_m32r): Declare.
10175 (m32r_arch_setup): New function.
10176 (m32r_usrregs_info, regs_info): New globals.
10177 (m32r_regs_info): Adjust.
10178 (initialize_low_arch): New function.
10179 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
10180 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
10181 (tic6x_usrregs_info): Forward declare.
10182 (tic6x_read_description): New function, based on ...
10183 (tic6x_arch_setup): ... this. Reimplement.
10184 (target_regsets): Rename to ...
10185 (tic6x_regsets): ... this, and make static.
10186 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
10187 (tic6x_regs_info): New function.
10188 (the_low_target): Adjust.
10189 (initialize_low_arch): New function.
10190 * linux-xtensa-low.c (tdesc_xtensa): Declare.
10191 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
10192 (target_regsets): Rename to ...
10193 (xtensa_regsets): ... this, and make static.
10194 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
10196 (xtensa_arch_setup, xtensa_regs_info): New functions.
10197 (the_low_target): Adjust.
10198 (initialize_low_arch): New function.
10199 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
10200 (nios2_arch_setup): Set the current process'es tdesc.
10201 (target_regsets): Rename to ...
10202 (nios2_regsets): ... this.
10203 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
10204 (nios2_regs_info): New function.
10205 (the_low_target): Adjust.
10206 (initialize_low_arch): New function.
10207 * linux-aarch64-low.c (tdesc_aarch64): Declare.
10208 (aarch64_arch_setup): Set the current process'es tdesc.
10209 (target_regsets): Rename to ...
10210 (aarch64_regsets): ... this.
10211 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
10212 (aarch64_regs_info): New function.
10213 (the_low_target): Adjust.
10214 (initialize_low_arch): New function.
10215 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
10217 (target_regsets): Rename to ...
10218 (tile_regsets): ... this.
10219 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
10220 (tile_regs_info): New function.
10221 (tile_arch_setup): Set the current process'es tdesc.
10222 (the_low_target): Adjust.
10223 (initialize_low_arch): New function.
10224 * spu-low.c (tdesc_spu): Declare.
10225 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
10226 * win32-arm-low.c (tdesc_arm): Declare.
10227 (arm_arch_setup): New function.
10228 (the_low_target): Install arm_arch_setup instead of
10229 init_registers_arm.
10230 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
10231 (init_windows_x86): Rename to ...
10232 (i386_arch_setup): ... this. Set `win32_tdesc'.
10233 (the_low_target): Adjust.
10234 * win32-low.c (win32_tdesc): New global.
10235 (child_add_thread): Don't create the thread cache here.
10236 (do_initial_child_stuff): Set the new process'es tdesc.
10237 * win32-low.h (struct target_desc): Forward declare.
10238 (win32_tdesc): Declare.
10239 * lynx-i386-low.c (tdesc_i386): Declare global.
10240 (lynx_i386_arch_setup): Set `lynx_tdesc'.
10241 * lynx-low.c (lynx_tdesc): New global.
10242 (lynx_add_process): Set the new process'es tdesc.
10243 * lynx-low.h (struct target_desc): Forward declare.
10244 (lynx_tdesc): Declare global.
10245 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
10246 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
10247 * nto-low.c (nto_tdesc): New global.
10248 (do_attach): Set the new process'es tdesc.
10249 * nto-low.h (struct target_desc): Forward declare.
10250 (nto_tdesc): Declare.
10251 * nto-x86-low.c (tdesc_i386): Declare.
10252 (nto_x86_arch_setup): Set `nto_tdesc'.
10254 2013-06-04 Gary Benson <gbenson@redhat.com>
10256 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
10257 to qSupported response when appropriate.
10258 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
10259 with nonzero-length annex.
10260 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
10261 arguments supplied in annex.
10263 2013-05-31 Doug Evans <dje@google.com>
10266 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
10267 64 bits in 64-cross-32 environment.
10269 2013-05-28 Pedro Alves <palves@redhat.com>
10271 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
10272 (aarch64-without-fpu.c): Delete rule.
10273 * configure.srv (aarch64*-*-linux*): Remove references to
10274 aarch64-without-fpu.o and aarch64-without-fpu.xml.
10275 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
10278 2013-05-24 Pedro Alves <palves@redhat.com>
10280 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
10281 instead of strchr/decode_address. Error if the range isn't split
10282 with a ','. Don't assume there's be a ':' in the action.
10284 2013-05-23 Yao Qi <yao@codesourcery.com>
10285 Pedro Alves <palves@redhat.com>
10287 * linux-low.c (lwp_in_step_range): New function.
10288 (linux_wait_1): If the thread was range stepping and stopped
10289 outside the stepping range, report the stop to GDB. Otherwise,
10290 continue stepping. Add range stepping debug output.
10291 (linux_set_resume_request): Copy the step range from the resume
10292 request to the lwp.
10293 (linux_supports_range_stepping): New.
10294 (linux_target_ops) <supports_range_stepping>: Set to
10295 linux_supports_range_stepping.
10296 * linux-low.h (struct linux_target_ops)
10297 <supports_range_stepping>: New field.
10298 (struct lwp_info) <step_range_start, step_range_end>: New fields.
10299 * linux-x86-low.c (x86_supports_range_stepping): New.
10300 (the_low_target) <supports_range_stepping>: Set to
10301 x86_supports_range_stepping.
10302 * server.c (handle_v_cont): Handle 'r' action.
10303 (handle_v_requests): Append ";r" if the target supports range
10305 * target.h (struct thread_resume) <step_range_start,
10306 step_range_end>: New fields.
10307 (struct target_ops) <supports_range_stepping>:
10309 (target_supports_range_stepping): New macro.
10311 2013-05-17 Joel Brobecker <brobecker@adacore.com>
10313 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
10314 confusion in comment.
10316 2013-05-17 Joel Brobecker <brobecker@adacore.com>
10318 * lynx-low.c (struct process_info_private): New type.
10319 (lynx_add_process): New function.
10320 (lynx_create_inferior, lynx_attach): Replace calls to
10321 add_process by calls to lynx_add_process.
10322 (lynx_resume): If PTID is null, then try using
10323 current_process()->private->last_wait_event_ptid.
10325 (lynx_clear_inferiors): Delete. The contents of that function
10326 has been inlined in lynx_mourn;
10327 (lynx_wait_1): Save the ptid in the process's private data.
10328 (lynx_mourn): Free the process' private data. Replace call
10329 to lynx_clear_inferiors by call to clear_inferiors.
10331 2013-05-17 Yao Qi <yao@codesourcery.com>
10333 * i386-low.c (i386_length_and_rw_bits): Move the comment to
10336 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
10338 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
10339 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
10340 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
10341 PT_TEXT_END_ADDR guards. Update comments.
10342 (linux_target_op) <read_offsets>: Conditionally define to
10343 linux_read_offsets if the target is UCLIBC and if it defines
10344 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
10346 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
10347 Andrew Jenner <andrew@codesourcery.com>
10349 * Makefile.in (SFILES): Add linux-nios2-low.c.
10350 (clean): Add action to delete nios2-linux.c.
10351 (nios2-linux.c): New rule.
10352 * configure.srv: Add nios2*-*-linux*.
10353 * linux-nios2-low.c: New.
10355 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
10357 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
10359 2013-04-25 Hui Zhu <hui@codesourcery.com>
10362 * ax.c (ax_printf): Add fflush.
10364 2013-04-22 Tom Tromey <tromey@redhat.com>
10366 * Makefile.in (SFILES): Add filestuff.c.
10367 (OBS): Add filestuff.o.
10368 (filestuff.o): New target.
10369 * config.in, configure: Rebuild.
10370 * configure.ac: Check for fdwalk, pipe2.
10372 2013-04-17 Pedro Alves <palves@redhat.com>
10374 * configure.ac (USE_THREAD_DB): Delete variable.
10375 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
10376 Don't AC_SUBST USE_THREAD_DB.
10377 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
10378 * config.in, configure: Regenerate.
10380 2013-04-16 Pedro Alves <palves@redhat.com>
10382 * linux-low.h (struct lwp_info) <thread_known>: Move under
10383 the USE_THREAD_DB #ifdef.
10385 2013-04-16 Pedro Alves <palves@redhat.com>
10387 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
10388 (linux-low.o): Delete rule.
10389 * linux-low.h: Always include "gdb_thread_db.h" instead of
10390 conditionally including thread_db.h.
10391 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
10394 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10396 * Makefile.in (install-only): Fix make install regression.
10398 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
10400 Convert man pages to texinfo, new gdbinit.5 texinfo page.
10401 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
10403 * gdbserver.1: Remove.
10405 2013-03-22 Pedro Alves <palves@redhat.com>
10407 * linux-low.c (handle_extended_wait): Don't call
10408 linux_enable_event_reporting.
10410 2013-03-15 Tony Theodore <tonyt@logyst.com>
10413 * Makefile.in (SHELL): Use @SHELL@.
10415 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
10417 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
10420 2013-03-13 Joel Brobecker <brobecker@adacore.com>
10422 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
10423 Remove extraneous NULL element.
10425 2013-03-13 Yao Qi <yao@codesourcery.com>
10427 * tracepoint.c (traceframe_read_tsv): Look for the last matched
10428 'V' block in trace frame.
10430 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10432 * target.h (struct target_ops): Add btrace ops.
10433 (target_supports_btrace): New macro.
10434 (target_enable_btrace): New macro.
10435 (target_disable_btrace): New macro.
10436 (target_read_btrace): New macro.
10437 * gdbthread.h (struct thread_info): Add btrace field.
10438 * server.c: Include btrace-common.h.
10439 (handle_btrace_general_set): New function.
10440 (handle_btrace_enable): New function.
10441 (handle_btrace_disable): New function.
10442 (handle_general_set): Call handle_btrace_general_set.
10443 (handle_qxfer_btrace): New function.
10444 (struct qxfer qxfer_packets[]): Add btrace entry.
10445 * inferiors.c (remove_thread): Disable btrace.
10446 * linux-low: Include linux-btrace.h.
10447 (linux_low_enable_btrace): New function.
10448 (linux_low_read_btrace): New function.
10449 (linux_target_ops): Add btrace ops.
10450 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
10451 Add srv_linux_btrace=yes.
10452 (x86_64-*-linux*): Add linux-btrace.o.
10453 Add srv_linux_btrace=yes.
10454 * configure.ac: Define HAVE_LINUX_BTRACE.
10455 * config.in: Regenerated.
10456 * configure: Regenerated.
10458 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10460 * server.c (handle_qxfer): Preserve error message if -3 is
10462 (qxfer): Document the -3 return value.
10464 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10466 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
10467 (linux_btrace_h): New variable.
10468 (linux-btrace.o): New rule.
10470 2013-03-08 Stan Shebs <stan@codesourcery.com>
10471 Hafiz Abid Qadeer <abidh@codesourcery.com>
10473 * tracepoint.c (trace_buffer_size): New global.
10474 (DEFAULT_TRACE_BUFFER_SIZE): New define.
10475 (init_trace_buffer): Change to one-argument function. Allocate
10476 trace buffer memory.
10477 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
10478 handle QTBuffer:size packet.
10479 (cmd_bigqtbuffer_size): New function.
10480 (initialize_tracepoint): Call init_trace_buffer with
10481 DEFAULT_TRACE_BUFFER_SIZE.
10482 * server.c (handle_query): Add QTBuffer:size in the
10485 2013-03-07 Yao Qi <yao@codesourcery.com>
10487 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
10488 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
10490 (cmd_qtsp): Adjust condition. Do post increment.
10491 Set cur_action and cur_step_action back to 0.
10493 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
10496 * linux-low.c (linux_write_memory): Return early success if LEN is
10499 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
10501 * configure.srv: Add x86_64-*-cygwin* as target.
10503 2013-02-28 Tom Tromey <tromey@redhat.com>
10505 * configure.ac: Invoke AC_SYS_LARGEFILE.
10506 * configure, config.in: Rebuild.
10508 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
10510 * win32-low.c: Throughout, fix format strings and casts of
10511 printf-like functions to avoid type related warnings on all
10513 (get_child_debug_event): Print dwDebugEventCode as hex since
10514 that's how it's usually documented.
10516 2013-02-28 Yao Qi <yao@codesourcery.com>
10518 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
10521 2013-02-27 Jiong Wang <jiwang@tilera.com>
10523 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
10524 (reg-tilegx32.c): New rule.
10525 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
10526 * linux-tile-low.c (tile_arch_setup): New function. Invoke
10527 different register info initializer according to elf class.
10528 (init_registers_tilgx32): New function. The tilegx32 register info
10530 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
10531 (tile_store_gregset): Likewise.
10533 2013-02-27 Yao Qi <yao@codesourcery.com>
10535 * server.c (process_point_options): Print debug message when
10536 debug_threads is true.
10538 2013-02-26 Yao Qi <yao@codesourcery.com>
10540 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
10542 2013-02-19 Pedro Alves <palves@redhat.com>
10543 Kai Tietz <ktietz@redhat.com>
10547 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
10548 instead of strtoul to extract address from packet.
10549 (process_serial_event) <'z'>: Likewise.
10551 2013-02-18 Yao Qi <yao@codesourcery.com>
10553 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
10555 2013-02-14 Pedro Alves <palves@redhat.com>
10559 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
10560 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
10562 2013-02-14 Pedro Alves <palves@redhat.com>
10564 * tracepoint.c (cmd_qtdpsrc): Use savestring.
10566 2013-02-14 Pedro Alves <palves@redhat.com>
10568 * tracepoint.c (save_string): Delete.
10569 (add_tracepoint_action): Use savestring instead of save_string.
10571 2013-02-12 Pedro Alves <palves@redhat.com>
10573 * linux-xtensa-low.c: Ditto.
10574 * xtensa-xtregs.c: Ditto.
10576 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
10578 * thread-db.c (thread_db_get_tls_address): NULL pointer check
10581 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10583 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
10584 aarch64_num_wp_regs and aarch64_num_bp_regs to
10585 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10587 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10589 * linux-aarch64-low.c (ps_get_thread_area): Replace
10590 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10592 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10593 Marcus Shawcroft <marcus.shawcroft@arm.com>
10594 Nigel Stephens <nigel.stephens@arm.com>
10595 Yufeng Zhang <yufeng.zhang@arm.com>
10597 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10598 (aarch64.c, aarch64-without-fpu.c): New targets.
10599 * configure.srv (aarch64*-*-linux*): New.
10600 * linux-aarch64-low.c: New file.
10602 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10604 * linux-low.c (handle_extended_wait, linux_create_inferior)
10605 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10606 (dequeue_one_deferred_signal, linux_resume_one_thread)
10607 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10608 (linux_tracefork_grandchild, linux_test_for_tracefork)
10609 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10610 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10611 where the argument is 0.
10613 2013-01-25 Yao Qi <yao@codesourcery.com>
10615 * event-loop.c: Include "queue.h".
10616 (gdb_event_p): New typedef.
10617 (struct gdb_event) <next_event>: Remove.
10618 (event_queue): Change to QUEUE(gdb_event_p).
10619 (async_queue_event): Remove.
10620 (gdb_event_xfree): New.
10621 (initialize_event_loop): New.
10622 (process_event): Use API from QUEUE.
10623 (wait_for_event): Likewise.
10624 * server.c (main): Call initialize_event_loop.
10625 * server.h (initialize_event_loop): Declare.
10627 2013-01-18 Yao Qi <yao@codesourcery.com>
10629 * ax.h (struct eval_agent_expr_context): New.
10630 (gdb_eval_agent_expr): Update declaration.
10631 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10632 TFRAME. Add new argument CTX.
10633 * server.h (struct eval_agent_expr_context): Declare.
10634 (agent_mem_read, agent_tsv_read): Update declaration.
10635 (agent_mem_read_string): Likewise.
10636 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10637 (add_traceframe_block): Add new argument TPOINT.
10638 Increase TPOINT->traceframe_usage.
10639 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10640 eval_tracepoint_agent_expr.
10641 (condition_true_at_tracepoint): Likewise.
10642 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10643 (agent_mem_read_string, agent_tsv_read): Likewise.
10645 2013-01-16 Yao Qi <yao@codesourcery.com>
10647 * linux-low.c (linux_resume_one_lwp): Don't check
10648 'lwp->bp_reinsert != 0'.
10650 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10651 Pedro Alves <palves@redhat.com>
10653 * lynx-low.c (ptrace_request_to_str): Define a temporary
10654 macro and use it to simplify this function's implementation.
10656 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10658 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10661 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10663 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10665 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10667 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10669 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10671 * lynx-low.c (lynx_resume): Use the resume_info parameter
10672 to determine the ptid for the lynx_ptrace call, unless
10673 it is equal to minus_one_ptid, in which case we use the
10674 ptid of the current_inferior.
10675 (lynx_wait_1): After having received a thread create/exit
10676 event, resume the inferior's execution using the signaling
10677 thread's ptid, rather than the old ptid.
10679 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10681 * lynx-low.c (lynx_resume): Delete variable ret.
10683 2013-01-01 Joel Brobecker <brobecker@adacore.com>
10685 * gdbreplay.c (gdbreplay_version): Update copyright year.
10686 * server.c (gdbserver_version): Likewise.
10688 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10690 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10693 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10695 * lynx-low.c (ptrace_request_to_str): Add handling for
10696 PTRACE_GETTRACESIG.
10698 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10700 * lynx-low.c (lynx_attach): Delete variable new_process.
10702 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10704 * lynx-low.c (lynx_create_inferior): Delete variable
10707 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10709 * lynx-low.c (ptrace_request_to_str): Do not handle
10710 PTRACE_GETTHREADLIST if this macro does not exist.
10712 2012-12-15 Yao Qi <yao@codesourcery.com>
10714 * Makefile.in (OBS): Add notif.o.
10715 * notif.c, notif.h: New.
10716 * server.c: Include "notif.h".
10717 (struct vstop_notif) <next>: Remove.
10719 (queue_stop_reply): Update.
10720 (push_event, send_next_stop_reply): Remove.
10721 (discard_queued_stop_replies): Update.
10722 (notif_stop): New variable.
10723 (handle_v_stopped): Remove.
10724 (handle_v_requests): Don't call handle_v_stopped. Call
10725 handle_ack_notif instead.
10726 (queue_stop_reply_callback): Call notif_event_enque instead
10727 of queue_stop_reply.
10728 (handle_status): Don't call send_next_stop_reply, call
10729 notif_write_event instead.
10730 (kill_inferior_callback): Likewise.
10731 (detach_or_kill_inferior_callback): Likewise.
10732 (main): Call initialize_notif.
10733 (process_serial_event): Call QUEUE_is_empty.
10734 (handle_target_event): Call notif_push instead of push event.
10735 * server.h (push_event): Remove declaration.
10737 2012-12-10 Tom Tromey <tromey@redhat.com>
10739 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10740 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10743 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10744 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10745 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10746 (amd64-linux-ipa.o, ax.o): Rewrite.
10747 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10748 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10749 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10750 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10751 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10752 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10753 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10754 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10755 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10756 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10757 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10758 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10759 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10760 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10761 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10762 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10763 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10764 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10765 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10766 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10767 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10768 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10769 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10770 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10771 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10772 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10773 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10774 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10775 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10776 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10777 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10778 (reg-tilegx.o): Remove.
10779 (all_object_files): New macro.
10780 Include .deps files.
10781 * aclocal.m4, configure: Rebuild.
10782 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10783 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10784 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10786 2012-12-05 Tom Tromey <tromey@redhat.com>
10789 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10791 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
10793 * configure.ac: Check for linux/perf_event.h.
10794 * config.in: Regenerated.
10795 * configure: Regenerated.
10797 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10799 * hostio.c (handle_readlink): Decrease buffer size
10800 parameter passed to readlink by one byte.
10802 2012-11-26 Yao Qi <yao@codesourcery.com>
10804 * configure.ac (build_warnings): Append '-Wempty-body'.
10805 * configure: Regenerated.
10806 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10809 2012-11-15 Pierre Muller <muller@sourceware.org>
10811 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10812 * config.in: Regenerate.
10813 * configure: Regenerate.
10814 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10815 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10816 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10817 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10819 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10820 instead of <sys/wait.h> header.
10821 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10823 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
10825 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10826 (various make rules): Remove -DGDBSERVER
10828 2012-11-09 Yao Qi <yao@codesourcery.com>
10830 * spu-low.c (current_ptid): Move it to ..
10831 * gdbthread.h: ... here. New.
10832 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10833 * server.c (myresume, process_serial_event): Likewise.
10834 * thread-db.c (thread_db_find_new_threads): Likewise.
10835 * tracepoint.c (run_inferior_command): Likewise.
10837 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
10839 * server.c (handle_search_memory_1): Include access length in
10842 2012-09-05 Michael Brandt <michael.brandt@axis.com>
10844 * linux-crisv32-low.c: Fix compile errors.
10846 2012-09-04 Yao Qi <yao@codesourcery.com>
10848 * tracepoint.c (cmd_qtsv): Adjust debug message.
10849 Don't check CUR_TPOINT.
10851 2012-08-28 Yao Qi <yao@codesourcery.com>
10853 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10854 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10855 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10856 Remove declarations of xmalloc, xreallloc, xstrdup and
10858 * Makefile.in (libiberty_h): New.
10859 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10860 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10862 2012-08-23 Yao Qi <yao@codesourcery.com>
10864 * server.h: Remove declaration of 'xsnprintf'.
10866 2012-08-22 Keith Seitz <keiths@redhat.com>
10868 * server.h: Include build-gnulib-gbserver/config.h.
10869 * gdbreplay.c: Likewise.
10871 2012-08-08 Doug Evans <dje@google.com>
10873 * Makefile.in (SFILES): Add gdb_vecs.c.
10874 (OBS): Add gdb_vecs.o.
10875 (gdb_vecs_h, host_defs_h): New variables.
10876 (thread-db.o): Add $(gdb_vecs_h) dependency.
10877 (gdb_vecs.o): New rule.
10878 * thread-db.c: #include "gdb_vecs.h".
10879 (thread_db_load_search): Use a vector to iterate over path elements.
10880 Handle text appearing after "$pdir".
10882 * configure.ac: Add check for strstr.
10883 * config.in: Regenerate.
10884 * configure: Regenerate.
10886 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10888 * hostio.c (handle_pread): If pread fails, fall back to attempting
10890 (handle_pwrite): Likewise for pwrite.
10892 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10894 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10895 between unsupported TYPE and unimplementable ADDR/LEN combination.
10896 (arm_insert_point): Act on new return value.
10898 2012-07-31 Pedro Alves <palves@redhat.com>
10900 * server.c (process_point_options): Only skip tokens if we find
10901 one that is unrecognized. Don't treat 'X' specially while
10902 skipping unrecognized tokens.
10904 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10906 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10907 to 4-byte-align HW breakpoint addresses for Thumb.
10909 2012-07-27 Yao Qi <yao@codesourcery.com>
10913 * server.h: Declare gdb_agent_about_to_close.
10914 * target.c (kill_inferior): Include "agent.h".
10915 New. Send command 'kill'.
10916 * target.h (kill_inferior): Removed macro.
10917 * tracepoint.c (gdb_agent_about_to_close): New.
10918 (gdb_agent_helper_thread): Handle command 'close'.
10919 Wait endlessly until the inferior stops.
10920 Install gdb_agent_remove_socket to atexit hook.
10921 (agent_socket_name): New static variable.
10922 (gdb_agent_socket_init): Replace local variable 'name' with
10923 'agent_socket_name'.
10924 (gdb_agent_remove_socket): New.
10926 2012-07-27 Yao Qi <yao@codesourcery.com>
10928 * server.c (process_point_options): Stop at 'X' when parsing.
10930 2012-07-19 Michael Eager <eager@eagercon.com>
10932 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10934 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10935 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10936 hardware breakpoint.
10938 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10940 * gdbserver/linux-low.c (initialize_low): Call
10941 linux_ptrace_init_warnings.
10943 2012-07-02 Doug Evans <dje@google.com>
10945 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10948 2012-07-02 Stan Shebs <stan@codesourcery.com>
10950 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10951 (ax.o): Add it to build rule.
10953 (OBS): Add format.o.
10954 (IPA_OBS): Add format.o.
10955 * server.c (handle_query): Claim support for breakpoint commands.
10956 (process_point_options): Add command case.
10957 (process_serial_event): Leave running if there are printfs in
10959 * mem-break.h (any_persistent_commands): Declare.
10960 (add_breakpoint_commands): Declare.
10961 (gdb_no_commands_at_breakpoint): Declare.
10962 (run_breakpoint_commands): Declare.
10963 * mem-break.c (struct point_command_list): New struct.
10964 (struct breakpoint): New field command_list.
10965 (any_persistent_commands): New function.
10966 (add_commands_to_breakpoint): New function.
10967 (add_breakpoint_commands): New function.
10968 (gdb_no_commands_at_breakpoint): New function.
10969 (run_breakpoint_commands): New function.
10970 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10972 * ax.c: Include format.h.
10973 (ax_printf): New function.
10974 (gdb_eval_agent_expr): Add printf opcode.
10976 2012-06-13 Yao Qi <yao@codesourcery.com>
10978 * server.c (start_inferior): Remove duplicated writes to fields
10979 'last_resume_kind' and 'last_status' of 'current_inferior'.
10981 2012-06-12 Yao Qi <yao@codesourcery.com>
10982 Pedro Alves <palves@redhat.com>
10984 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10986 * server.c (handle_v_cont): Extend comment.
10988 2012-06-11 Yao Qi <yao@codesourcery.com>
10990 * linux-low.c (linux_attach): Add 'static'.
10992 2012-06-06 Yao Qi <yao@codesourcery.com>
10994 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10996 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10998 Fix gcc -flto compilation warning.
10999 * server.c (main): Make variable multi_mode and attach volatile.
11001 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11003 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
11004 if the platform doesn't know about it.
11006 2012-05-30 Jeff Kenton <jkenton@tilera.com>
11008 * Makefile.in (SFILES): Add linux-tile-low.c.
11009 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
11010 * configure.srv: Handle tilegx-*-linux*.
11011 * linux-tile-low.c: New file.
11013 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
11015 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
11017 2012-05-24 Pedro Alves <palves@redhat.com>
11021 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
11023 2012-05-24 Pedro Alves <palves@redhat.com>
11027 Replace target_signal with gdb_signal throughout.
11029 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
11031 * linux-low.c (linux_store_registers): Avoid the copying sequence
11032 when no data has been retrieved by ptrace.
11034 2012-05-22 Will Deacon <will.deacon@arm.com>
11036 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
11037 Include asm/ptrace.h.
11038 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
11041 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
11043 * linux-low.c (linux_store_registers): Don't re-retrieve data
11044 with ptrace that has already been obtained from /proc. Always
11045 copy any data retrieved with ptrace to the buffer supplied.
11047 2012-05-11 Yao Qi <yao@codesourcery.com>
11048 Pedro Alves <palves@redhat.com>
11050 * linux-low.c (enum stopping_threads_kind): New.
11051 (stopping_threads): Change type to `enum stopping_threads_kind'.
11052 (handle_extended_wait): If stopping and suspending threads, leave
11053 the new_lwp suspended too.
11054 (linux_wait_for_event): Adjust.
11055 (stop_all_lwps): Set `stopping_threads' to
11056 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
11057 whether we're suspending threads or just stopping them. Assert no
11060 2012-04-29 Yao Qi <yao@codesourcery.com>
11062 * server.h: Move some code to ...
11063 * gdbthread.h: ... here. New.
11064 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
11065 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
11066 (nto-low.o, win32-low.o): Likewise.
11067 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
11068 * regcache.c, remote-utils.c, server.c: Likewise.
11069 * target.c, tracepoint.c, win32-low.c: Likewise.
11071 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11073 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
11074 (PTRACE_ARG4_TYPE): Likewise.
11075 (PTRACE_XFER_TYPE): Likewise.
11076 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
11077 ptrace to PTRACE_ARG3_TYPE.
11078 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
11079 (PTRACE_ARG4_TYPE): Likewise.
11080 (PTRACE_XFER_TYPE): Likewise.
11081 (linux_detach_one_lwp): Cast fourth argument of
11082 ptrace to long then PTRACE_ARG4_TYPE.
11083 (regsets_fetch_inferior_registers): Cast third argument of
11084 ptrace to long then PTRACE_ARG3_TYPE.
11085 (regsets_store_inferior_registers): Likewise.
11087 2012-04-20 Pedro Alves <palves@redhat.com>
11089 * configure: Regenerate.
11091 2012-04-19 Pedro Alves <palves@redhat.com>
11093 * Makefile.in (GNULIB_BUILDDIR): New.
11094 (LIBGNU, INCGNU, GNULIB_H): Adjust.
11095 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
11096 (all, install-only, uninstall, clean-info, all-lib, clean): No
11097 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
11098 (maintainer-clean realclean distclean): Use subdir_do.
11100 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
11101 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
11102 * acinclude.m4: Include acx_configure_dir.m4.
11103 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
11104 calls. Call AC_PROG_RANLIB. Configure gnulib using
11107 (GNULIB_STDINT_H): Adjust.
11108 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
11109 * gdbreplay.c: Include build-gnulib/config.h.
11110 * server.h: Likewise.
11111 * aclocal.m4: Regenerate.
11112 * config.in: Regenerate.
11113 * configure: Regenerate.
11115 2012-04-19 Pedro Alves <palves@redhat.com>
11117 * Makefile.in (LIBGNU, INCGNU): Adjust.
11118 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
11119 (all, install-only, uninstall, clean-info, all-lib, clean)
11120 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
11121 * configure.ac: Adjust AC_OUTPUT output.
11122 * aclocal.m4: Regenerate.
11123 * configure: Regenerate.
11125 2012-04-19 Pedro Alves <palves@redhat.com>
11127 * Makefile.in (generated_files): New.
11128 (server_h): Remove the explicit dependency on config.h, and depend
11129 on $generated_files.
11131 2012-04-19 Pedro Alves <palves@redhat.com>
11133 * Makefile.in (INCGNU): Add -Ignulib.
11135 2012-04-19 Pedro Alves <palves@redhat.com>
11137 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
11138 (INCGNU): ... this, and spell out -I here.
11139 (GNULIB_LIB): Rename to ...
11140 (LIBGNU): ... this.
11141 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
11143 2012-04-19 Pedro Alves <palves@redhat.com>
11145 * config.in: Regenerate.
11147 2012-04-19 Pedro Alves <palves@redhat.com>
11149 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
11150 * server.h (memmem): Remove declaration.
11151 * config.in: Regenerate.
11152 * configure: Regenerate.
11154 2012-04-19 Yao Qi <yao@codesourcery.com>
11156 * Makefile.in (SFILES): Add common/vec.c.
11160 2012-04-19 Yao Qi <yao@codesourcery.com>
11162 * remote-utils.c (prepare_resume_reply): Replace with macro
11163 target_core_of_thread.
11164 * server.c (handle_qxfer_threads_proper): Likewise.
11165 * target.h (traget_core_of_thread): New macro.
11167 2012-04-18 Pedro Alves <palves@redhat.com>
11169 * aclocal.m4: Regenerate.
11170 * configure: Regenerate.
11172 2012-04-16 Yao Qi <yao@codesourcery.com>
11174 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
11175 duplicated on address.
11177 2012-04-16 Yao Qi <yao@codesourcery.com>
11179 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
11180 (struct tracepoint_action_ops) <send>: New field.
11181 (m_tracepoint_action_send, r_tracepoint_action_send): New.
11182 (agent_expr_send, x_tracepoint_action_send): New.
11183 (l_tracepoint_action_send): New.
11184 (cmd_qtdp): Download and install tracepoint
11185 according to `use_agent'.
11186 (run_inferior_command): Add one more parameter `len'.
11188 (tracepoint_send_agent): New.
11189 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
11191 2012-04-16 Yao Qi <yao@codesourcery.com>
11193 * tracepoint.c (download_tracepoints): Moved to ...
11194 (cmd_qtstart): ... here.
11196 2012-04-14 Yao Qi <yao@codesourcery.com>
11198 * tracepoint.c: Include inttypes.h.
11199 (struct collect_memory_action): Use sized types.
11200 (struct tracepoint): Likewise.
11201 (cmd_qtdp, stop_tracing): Update print specifiers.
11202 (cmd_qtp, response_tracepoint): Likewise.
11203 (collect_data_at_tracepoint): Likewise.
11204 (collect_data_at_step): Likewise.
11206 2012-04-14 Yao Qi <yao@codesourcery.com>
11208 Import gnulib module inttypes.
11209 * aclocal.m4, config.in, configure: Regenerated.
11211 2012-04-14 Yao Qi <yao@codesourcery.com>
11213 * Makefile.in (maintainer-clean, realclean, distclean): Remove
11214 Makefile and config.status at last.
11216 2012-04-13 Yao Qi <yao@codesourcery.com>
11218 * tracepoint.c: Include stdint.h unconditionally.
11220 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11222 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
11223 on BFD_HAVE_SYS_PROCFS_TYPE.
11224 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
11225 * configure: Regenerate.
11226 * config.in: Likewise.
11228 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
11230 * Makefile.in (clean): Also remove x32.c x32-linux.c
11231 x32-avx.c x32-avx-linux.c.
11232 (x32.o): New target.
11234 (x32-linux.o): Likewise.
11235 (x32-linux.c): Likewise.
11236 (x32-avx.o): Likewise.
11237 (x32-avx.c): Likewise.
11238 (x32-avx-linux.o): Likewise.
11239 (x32-avx-linux.c): Likewise.
11241 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
11242 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
11243 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
11244 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
11245 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
11246 i386/x32-avx-linux.xml.
11248 * linux-x86-low.c (init_registers_x32_linux): New prototype.
11249 (init_registers_x32_avx_linux): Likwise.
11250 (x86_linux_update_xmltarget): Call init_registers_x32_linux
11251 or init_registers_x32_avx_linux if linux_is_elf64 is false.
11253 2012-04-13 Pedro Alves <palves@redhat.com>
11255 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
11256 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
11257 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
11258 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
11261 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
11263 * linux-x86-low.c (compat_x32_clock_t): New.
11264 (compat_x32_siginfo_t): Likewise.
11265 (compat_x32_siginfo_from_siginfo): Likewise.
11266 (siginfo_from_compat_x32_siginfo): Likewise.
11267 (linux_is_elf64): Likewise.
11268 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
11269 and siginfo_from_compat_x32_siginfo for x32.
11270 (x86_arch_setup): Set linux_is_elf64.
11272 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
11275 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
11277 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
11278 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
11279 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
11280 compatible with process.
11282 2012-04-12 Yao Qi <yao@codesourcery.com>
11284 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
11285 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
11286 (install-only, install-info, clean): Handle sub dir gnulib.
11287 (all-lib, am--refresh): New targets.
11288 (memmem.o): Remove target.
11289 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
11290 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
11291 (AC_REPLACE_FUNCS): Remove memmem.
11292 Invoke gl_INIT and AM_INIT_AUTOMAKE.
11293 (AC_OUTPUT): Generate Makefile in gnulib/.
11294 * aclocal.m4, config.in, configure: Regenerated.
11296 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
11298 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
11300 2012-04-05 Pedro Alves <palves@redhat.com>
11302 -Werror=strict-aliasing
11304 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
11307 2012-04-04 Pedro Alves <palves@redhat.com>
11309 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
11310 (sparc_store_gregset_from_stack, sparc_store_gregset)
11311 (sparc_breakpoint_at): Fix formatting.
11313 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
11315 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
11317 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
11318 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
11319 * config.in: Regenerate.
11320 * configure: Likewise.
11322 2012-03-29 Pedro Alves <palves@redhat.com>
11324 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
11325 Correct ptrace arguments.
11327 2012-03-28 Pedro Alves <palves@redhat.com>
11329 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
11330 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
11331 (IA64_FR1_REGNUM): New defines.
11332 (ia64_fetch_register): New.
11333 (the_low_target): Install it.
11334 * linux-low.h (struct linux_target_ops) <fetch_register>: New
11336 * linux-low.c (linux_fetch_registers): Try the
11337 the_low_target.fetch_register hook first.
11339 * linux-arm-low.c (the_low_target): Adjust.
11340 * linux-bfin-low.c (the_low_target): Adjust.
11341 * linux-cris-low.c (the_low_target): Adjust.
11342 * linux-crisv32-low.c (the_low_target): Adjust.
11343 * linux-m32r-low.c (the_low_target): Adjust.
11344 * linux-m68k-low.c (the_low_target): Adjust.
11345 * linux-mips-low.c (the_low_target): Adjust.
11346 * linux-ppc-low.c (the_low_target): Adjust.
11347 * linux-s390-low.c (the_low_target): Adjust.
11348 * linux-sh-low.c (the_low_target): Adjust.
11349 * linux-sparc-low.c (the_low_target): Adjust.
11350 * linux-tic6x-low.c (the_low_target): Adjust.
11351 * linux-x86-low.c (the_low_target): Adjust.
11352 * linux-xtensa-low.c (the_low_target): Adjust.
11354 2012-03-26 Pedro Alves <palves@redhat.com>
11356 * server.c (handle_qxfer_libraries): Don't bail early if
11357 the_target->qxfer_libraries_svr4 is not NULL.
11359 2012-03-26 Pedro Alves <palves@redhat.com>
11361 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
11363 2012-03-23 Pedro Alves <palves@redhat.com>
11365 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
11366 "library-list-svr4" element's start tag when the the DSO list is
11369 2012-03-23 Pedro Alves <palves@redhat.com>
11371 * linux-low.c (read_one_ptr): Read the inferior's pointer through
11372 a variable whose type size is the same as the inferior's pointer
11375 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
11377 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
11379 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
11380 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
11381 * linux-low.h: Include <signal.h>.
11382 (struct siginfo): Remove forward declaration.
11383 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
11386 2012-03-21 Mike Frysinger <vapier@gentoo.org>
11388 * .gitignore: Ignore more files.
11390 2012-03-19 Pedro Alves <palves@redhat.com>
11391 Jan Kratochvil <jan.kratochvil@redhat.com>
11393 * server.c (cont_thread, general_thread): Add describing comments.
11394 (start_inferior): Clear `cont_thread'.
11395 (handle_v_cont): Don't set `cont_thread' if resuming all threads
11398 2012-03-15 Yao Qi <yao@codesourcery.com>
11400 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
11402 (cmd_qtdp): ... here.
11404 2012-03-15 Yao Qi <yao@codesourcery.com>
11406 * tracepoint.c (struct tracepoint_action_ops): New.
11407 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
11408 (m_tracepoint_action_download): New.
11409 (r_tracepoint_action_download): New.
11410 (x_tracepoint_action_download): New.
11411 (l_tracepoint_action_download): New.
11412 (add_tracepoint_action): Install `action->ops' according type.
11413 (download_tracepoint_1): Move code `download' function pointer
11414 of various tracepoint_action_ops.
11416 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
11418 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
11419 linux_ptrace_attach_warnings.
11421 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
11423 * Makefile.in (linux-ptrace.o): New.
11424 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
11425 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
11426 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
11427 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
11428 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
11430 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
11432 2012-03-08 Yao Qi <yao@codesourcery.com>
11433 Pedro Alves <palves@redhat.com>
11435 Fix PR server/13392.
11436 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
11437 offset of JMP insn.
11438 * tracepoint.c (remove_tracepoint): New.
11439 (cmd_qtdp): Call remove_tracepoint when failed to install.
11441 2012-03-07 Pedro Alves <palves@redhat.com>
11443 * linux-low.c (get_detach_signal): New.
11444 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
11445 Pass on pending signals to PTRACE_DETACH. Check the result of the
11447 * server.c (program_signals, program_signals_p): New.
11448 (handle_general_set): Handle QProgramSignals.
11449 * server.h (program_signals, program_signals_p): Declare.
11451 2012-03-05 Pedro Alves <palves@redhat.com>
11452 Jan Kratochvil <jan.kratochvil@redhat.com>
11454 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
11457 2012-03-03 Yao Qi <yao@codesourcery.com>
11459 * tracepoint.c (tracepoint_look_up_symbols): Update call to
11460 agent_look_up_symbols.
11462 2012-03-03 Yao Qi <yao@codesourcery.com>
11464 * Makefile.in (linux-low.o): Keep dependence on agent.h.
11465 (linux-x86-low.o): Likewise.
11466 * server.h: Remove in_process_agent_loaded.
11467 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
11471 2012-03-03 Yao Qi <yao@codesourcery.com>
11473 * tracepoint.c (gdb_agent_capability): New global.
11474 (in_process_agent_loaded_ust): Renamed to
11475 `in_process_agent_supports_ust'.
11477 (in_process_agent_supports_ust): Call agent_capability_check.
11478 (clear_installed_tracepoints): Assert that agent supports
11481 2012-03-03 Yao Qi <yao@codesourcery.com>
11483 * linux-low.c (linux_supports_agent): New.
11484 (linux_target_ops): Initialize field `supports_agent' with
11485 linux_supports_agent.
11486 * target.h (struct target_ops) <supports_agent>: New.
11487 (target_supports_agent): New macro.
11488 * server.c (handle_general_set): Handle packet 'QAgent'.
11489 (handle_query): Send `QAgent+'.
11490 * Makefile.in (server.o): Depends on agent.h.
11492 2012-03-03 Yao Qi <yao@codesourcery.com>
11494 * Makefile.in (OBS): Add agent.o.
11495 Add new rule for agent.o.
11496 Track dependence of tracepoint.c on agent.h.
11497 * tracepoint.c (run_inferior_command_1):
11498 (run_inferior_command): Call agent_run_command.
11499 (gdb_ust_connect_sync_socket): Deleted. Move it to
11501 (resume_thread, stop_thread): Likewise.
11502 (gdb_ust_socket_init): Renamed to ...
11503 (gdb_agent_socket_init): ... New.
11504 (gdb_ust_thread): Renamed to ...
11505 (gdb_agent_helper_thread): ... New.
11506 (gdb_ust_init): Move some code to ...
11507 (gdb_agent_init): ... here. New.
11508 [HAVE_UST]: Call gdb_ust_init.
11509 (initialize_tracepoint_ftlib): Call gdb_agent_init.
11510 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
11511 * config.in, configure: Regenerated.
11513 2012-03-02 Pedro Alves <palves@redhat.com>
11515 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
11516 * linux-low.c (struct simple_pid_list): New.
11517 (stopped_pids): New a struct simple_pid_list pointer.
11518 (add_to_pid_list, pull_pid_from_list): New.
11519 (handle_extended_wait): Don't assume the first signal new children
11520 report is SIGSTOP. Adjust call to pull_pid_from_list.
11521 (linux_wait_for_lwp): Adjust.
11523 2012-03-02 Yao Qi <yao@codesourcery.com>
11525 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
11528 2012-03-02 Yao Qi <yao@codesourcery.com>
11530 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
11531 `stop_pc' and `tpoint'. Update caller.
11533 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
11535 * linux-low.h (linux_target_ops): Add regset_bitmap member.
11536 * linux-low.c (use_linux_regsets): New macro.
11537 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
11538 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
11539 (linux_register_in_regsets): New function.
11540 (usr_fetch_inferior_registers): Skip registers covered by
11542 (usr_store_inferior_registers): Likewise.
11543 (usr_fetch_inferior_registers): New macro.
11544 (usr_store_inferior_registers): Likewise.
11545 (linux_fetch_registers): Handle mixed regset/non-regset targets.
11546 (linux_store_registers): Likewise.
11547 * linux-mips-low.c (init_registers_mips_dsp_linux): New
11549 (init_registers_mips64_dsp_linux): Likewise.
11550 (init_registers_mips_linux): New macro.
11551 (init_registers_mips_dsp_linux): Likewise.
11552 (mips_dsp_num_regs): Likewise.
11553 (DSP_BASE, DSP_CONTROL): New fallback macros.
11554 (mips_base_regs): New macro.
11555 (mips_regmap): Use it. Fix the size.
11556 (mips_dsp_regmap): New variable.
11557 (mips_dsp_regset_bitmap): Likewise.
11558 (mips_arch_setup): New function.
11559 (mips_cannot_fetch_register): Use the_low_target.regmap rather
11561 (mips_cannot_store_register): Likewise.
11562 (the_low_target): Update .arch_setup, .num_regs and .regmap
11563 initializers. Add .regset_bitmap initializer.
11564 * linux-arm-low.c (the_low_target): Add .regset_bitmap
11566 * linux-bfin-low.c (the_low_target): Likewise.
11567 * linux-cris-low.c (the_low_target): Likewise.
11568 * linux-crisv32-low.c (the_low_target): Likewise.
11569 * linux-ia64-low.c (the_low_target): Likewise.
11570 * linux-m32r-low.c (the_low_target): Likewise.
11571 * linux-m68k-low.c (the_low_target): Likewise.
11572 * linux-ppc-low.c (the_low_target): Likewise.
11573 * linux-s390-low.c (the_low_target): Likewise.
11574 * linux-sh-low.c (the_low_target): Likewise.
11575 * linux-sparc-low.c (the_low_target): Likewise.
11576 * linux-tic6x-low.c (the_low_target): Likewise.
11577 * linux-x86-low.c (the_low_target): Likewise.
11578 * linux-xtensa-low.c (the_low_target): Likewise.
11579 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
11580 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
11581 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
11583 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
11584 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11586 2012-02-29 Yao Qi <yao@codesourcery.com>
11587 Pedro Alves <palves@redhat.com>
11589 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11590 `step_over_finished' is true.
11592 2012-02-27 Pedro Alves <palves@redhat.com>
11594 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11595 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11597 2012-02-27 Pedro Alves <palves@redhat.com>
11600 * linux-low.c (pid_is_stopped): New.
11601 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11603 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
11605 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11608 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11610 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11612 2012-02-24 Luis Machado <lgustavo@codesourcery>
11614 * server.c (handle_query): Advertise support for target-side
11615 breakpoint condition evaluation.
11616 (process_point_options): New function.
11617 (process_serial_event): When inserting a breakpoint, check for
11618 a target-side condition that should be evaluated.
11620 * mem-break.c: Include regcache.h and ax.h.
11621 (point_cond_list_t): New data structure.
11622 (breakpoint) <cond_list>: New field.
11623 (find_gdb_breakpoint_at): Make non-static.
11624 (delete_gdb_breakpoint_at): Clear any target-side
11626 (clear_gdb_breakpoint_conditions): New function.
11627 (add_condition_to_breakpoint): Likewise.
11628 (add_breakpoint_condition): Likewise.
11629 (gdb_condition_true_at_breakpoint): Likewise.
11630 (gdb_breakpoint_here): Return result directly instead
11631 of going through a local variable.
11633 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11634 (clear_gdb_breakpoint_conditions): Likewise.
11635 (add_breakpoint_condition): Likewise.
11636 (gdb_condition_true_at_breakpoint): Likewise.
11638 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11639 (need_step_over_p): Take target-side breakpoint condition into
11642 2012-02-24 Luis Machado <lgustavo@codesourcery>
11644 * server.h: Include tracepoint.h.
11645 (agent_mem_read, agent_get_trace_state_variable_value,
11646 agent_set_trace_state_variable_value,
11647 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11648 get_set_tsv_func_addr): New prototypes.
11650 * ax.h: New include file.
11651 * ax.c: New source file.
11653 * tracepoint.c: Include ax.h.
11654 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11655 agent_expr, eval_result_type): Move to ax.h.
11656 (parse_agent_expr): Rename to ...
11657 (gdb_parse_agent_expr): ... this, make it non-static and move
11659 (unparse_agent_expr) Rename to ...
11660 (gdb_unparse_agent_expr): ... this, make it non-static and move
11662 (eval_agent_expr): Rename to ...
11663 (eval_tracepoint_agent_expr): ... this.
11664 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11665 forward declarations.
11666 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11667 (agent_get_trace_state_variable_value): New function.
11668 (agent_set_trace_state_variable_value): New function.
11669 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11670 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11671 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11672 (condition_true_at_tracepoint): Likewise.
11673 (parse_agent_expr): Rename to ...
11674 (gdb_parse_agent_expr): ... this and move to ax.c.
11675 (unparse_agent_expr): Rename to ...
11676 (gdb_unparse_agent_expr): ... this and move to ax.c.
11677 (gdb_agent_op_name): Move to ax.c.
11678 (eval_agent_expr): Rename to ...
11679 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11681 (eval_tracepoint_agent_expr): New function.
11682 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
11684 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11686 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11687 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11688 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11689 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11690 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11691 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11692 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11693 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11694 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11695 (compile_bytecodes): Remove forward declaration.
11696 (is_goto_target): Move to ax.c.
11697 (compile_bytecodes): Move to ax.c and call
11698 agent_get_trace_state_variable_value (...) and
11699 agent_set_trace_state_variable_value (...).
11701 * Makefile.in: Update ax.c and IPA dependencies.
11703 2012-02-24 Pedro Alves <palves@redhat.com>
11705 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11706 (cmd_bigqtbuffer_circular): ... this. Only handle
11707 'QTBuffer:circular:'.
11708 (handle_tracepoint_general_set): Adjust.
11710 2012-02-16 Yao Qi <yao@codesourcery.com>
11712 * inferiors.c: Move code to ...
11713 * dll.c: .... here. New.
11714 * server.h: Declare clear_dlls.
11715 * Makefile.in (SFILES): Add dll.c.
11719 2012-02-11 Yao Qi <yao@codesourcery.com>
11721 * server.c: (handle_monitor_command): Add a new parameter
11723 (handle_query): Update caller.
11725 2012-02-09 Joel Brobecker <brobecker@adacore.com>
11727 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11728 * configure, config.in: Regenerate.
11729 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11732 2012-02-02 Pedro Alves <palves@redhat.com>
11734 Try SIGKILL first, then PTRACE_KILL.
11735 * linux-low.c (linux_kill_one_lwp): New.
11736 (linux_kill_one_lwp): Rename to ...
11737 (kill_one_lwp_callback): ... this. Use the new
11738 linux_kill_one_lwp.
11740 2012-02-02 Pedro Alves <palves@redhat.com>
11742 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11745 2012-01-27 Pedro Alves <palves@redhat.com>
11747 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11748 (elf_64_file_p): Make static.
11749 (linux_pid_exe_is_elf_64_file): New.
11750 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11751 Delete declarations.
11752 (linux_pid_exe_is_elf_64_file): Declare.
11753 * linux-x86-low.c (x86_arch_setup): Use
11754 linux_pid_exe_is_elf_64_file.
11756 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11758 * linux-low.c (linux_wait_for_event_1): Rename to ...
11759 (linux_wait_for_event): ... here and merge it with former
11760 linux_wait_for_event - new variable wait_ptid, use it.
11761 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11763 2012-01-23 Pedro Alves <palves@redhat.com>
11765 * server.c (main): Avoid yet another case of infinite loop while
11766 detaching/killing after a longjmp.
11768 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11771 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11773 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11775 * hostio.c (handle_readlink): New function.
11776 (handle_vFile): Call it to handle "vFile:readlink" packets.
11778 2012-01-20 Pedro Alves <palves@redhat.com>
11779 Ulrich Weigand <ulrich.weigand@linaro.org>
11781 * server.c (handle_v_requests): Only support vAttach and vRun to
11782 start multiple processes when in extended protocol mode.
11784 2012-01-17 Pedro Alves <palves@redhat.com>
11786 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11787 memalign plus mprotect to allocate the scratch buffer.
11789 2012-01-13 Pedro Alves <palves@redhat.com>
11791 * server.c (attach_inferior): Clear `cont_thread'.
11793 2012-01-13 Pedro Alves <palves@redhat.com>
11795 * server.c (main): Avoid infinite loop while detaching/killing
11798 2012-01-09 Doug Evans <dje@google.com>
11800 * server.c (start_inferior): Set last_ptid in --wrapper case.
11802 2012-01-06 Yao Qi <yao@codesourcery.com>
11804 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11806 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11808 2012-01-04 Yao Qi <yao@codesourcery.com>
11810 * tracepoint.c (cmd_qtdp): Print debug message
11811 for static tracepoint.
11813 2012-01-04 Yao Qi <yao@codesourcery.com>
11815 * tracepoint.c (trace_vdebug): Differentiate debug message
11816 between gdbserver and IPA.
11818 2012-01-03 Yao Qi <yao@codesourcery.com>
11820 * tracepoint.c (tracepoint_was_hit): Don't collect for
11823 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11825 * terminal.h: Reformat copyright header.
11827 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11829 * server.c (gdbserver_version): Update copyright year.
11830 * gdbreplay.c (gdbreplay_version): Likewise.
11832 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11834 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11837 2011-12-18 Hui Zhu <teawater@gmail.com>
11838 * linux-low.c (linux_create_inferior): Save return value to ret.
11840 2011-12-18 Hui Zhu <teawater@gmail.com>
11842 * linux-low.c (linux_create_inferior): Save return value to ret.
11844 2011-12-16 Doug Evans <dje@google.com>
11846 * linux-low.c (linux_create_inferior): If stdio connection,
11847 redirect stdin from /dev/null, stdout to stderr.
11848 * remote-utils.c (remote_is_stdio): New static global.
11849 (remote_connection_is_stdio): New function.
11850 (remote_prepare): Handle stdio connection.
11851 (remote_open): Ditto.
11852 (remote_close): Don't close stdin for stdio connections.
11853 (read_prim,write_prim): New functions. Replace all calls to
11854 read/write to these.
11855 * server.c (main): Watch for "-" argument. Move call to
11856 remote_prepare before start_inferior.
11857 * server.h (STDIO_CONNECTION_NAME): New macro.
11858 (remote_connection_is_stdio): Declare.
11860 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11861 in debugging output.
11863 2011-12-15 Yao Qi <yao@codesourcery.com>
11865 * tracepoint.c: Include sys/syscall.h.
11866 (gdb_ust_thread): Remove preprocessor conditional.
11868 2011-12-14 Pedro Alves <pedro@codesourcery.com>
11870 * linux-low.c (linux_detach_one_lwp): Call
11871 the_low_target.prepare_to_resume before detaching.
11873 2011-12-14 Yao Qi <yao@codesourcery.com>
11875 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11878 2011-12-14 Yao Qi <yao@codesourcery.com>
11880 * i386-low.c (i386_low_stopped_data_address): Initialize local
11881 variable `control'.
11883 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11887 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11888 DR_CONTROL unless necessary. Extend comments.
11889 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11890 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11892 2011-12-13 Yao Qi <yao@codesourcery.com>
11894 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11896 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11898 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11900 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11901 Print new debug message for such case.
11903 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11905 Fix overlapping memcpy.
11906 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11907 the read_inferior_memory transfer.
11908 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11909 write_inferior_memory transfer.
11910 (set_fast_tracepoint_jump): New variable buf. Use it for the
11911 read_inferior_memory and write_inferior_memory transfers.
11912 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11913 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11914 Use it for the write_inferior_memory transfer.
11915 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11918 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11920 * linux-low.c (fetch_register, store_register): Make code
11921 consistent, fix formatting.
11923 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11925 * linux-low.c (usr_store_inferior_registers): Factor out code
11926 to handle individual registers into...
11927 (store_register): ... this new function.
11929 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11931 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11932 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11933 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11934 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11935 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11936 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11937 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11938 (srv_xmlfiles): Add new XML files.
11940 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11942 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11943 (init_registers_s390_linux32v1): Add prototype.
11944 (init_registers_s390_linux32v2): Likewise.
11945 (init_registers_s390_linux64v1): Likewise.
11946 (init_registers_s390_linux64v2): Likewise.
11947 (init_registers_s390x_linux64v1): Likewise.
11948 (init_registers_s390x_linux64v2): Likewise.
11949 (s390_num_regs): Increment to 52.
11950 (s390_regmap): Add orig_r2 register.
11951 (s390_num_regs_3264): Increment to 68.
11952 (s390_regmap_3264): Add orig_r2 register.
11953 (s390_collect_ptrace_register): Handle orig_r2 register.
11954 (s390_supply_ptrace_register): Likewise.
11955 (s390_fill_last_break): New function.
11956 (s390_store_last_break): Likewise.
11957 (s390_fill_system_call): New function.
11958 (s390_store_system_call): Likewise.
11959 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11961 (s390_check_regset): New function.
11962 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11963 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11964 Update target_regsets for available register sets.
11966 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11967 Jan Kratochvil <jan.kratochvil@redhat.com>
11969 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11970 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11972 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11973 * linux-low.h (struct process_info_private): New member r_debug.
11974 * server.c (handle_qxfer_libraries): Call
11975 the_target->qxfer_libraries_svr4.
11976 (handle_qxfer_libraries_svr4): New function.
11977 (qxfer_packets): New entry "libraries-svr4".
11978 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11979 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11980 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11981 PACKET_qXfer_libraries_svr4.
11983 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11985 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11986 PSW address/mask between 8-byte and 16-byte formats.
11987 (s390_supply_ptrace_register): Likewise.
11988 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11989 basic addressing mode bit.
11991 2011-11-24 Stan Shebs <stan@codesourcery.com>
11993 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11995 2011-11-17 Stan Shebs <stan@codesourcery.com>
11997 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11998 (tracing_start_time): New global.
11999 (tracing_stop_time): New global.
12000 (tracing_user_name): New global.
12001 (tracing_notes): New global.
12002 (tracing_stop_note): New global.
12003 (cmd_qtstart): Set traceframe_usage, start_time.
12004 (stop_tracing): Set stop_time.
12005 (cmd_qtstatus): Report additional status.
12006 (cmd_qtp): New function.
12007 (handle_tracepoint_query): Call it.
12008 (cmd_qtnotes): New function.
12009 (handle_tracepoint_general_set): Call it.
12010 (get_timestamp): Rename from tsv_get_timestamp.
12012 2011-11-14 Stan Shebs <stan@codesourcery.com>
12013 Kwok Cheung Yeung <kcy@codesourcery.com>
12015 * linux-x86-low.c (small_jump_insn): New.
12016 (i386_install_fast_tracepoint_jump_pad): Add arguments for
12017 trampoline and error message, build a trampoline and issue a small
12018 jump instruction to it.
12019 (x86_install_fast_tracepoint_jump_pad): Add arguments for
12020 trampoline and error message.
12021 (x86_get_min_fast_tracepoint_insn_len): New.
12022 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
12023 * linux-low.h (struct linux_target_ops): Add arguments to
12024 install_fast_tracepoint_jump_pad operation, add new operation.
12025 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
12027 (linux_get_min_fast_tracepoint_insn_len): New function.
12028 (linux_target_op): Add new operation.
12029 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
12030 (gdb_trampoline_buffer_end): Ditto.
12031 (gdb_trampoline_buffer_error): Ditto.
12032 (struct ipa_sym_addresses): Add fields for new IPA variables.
12033 (symbol_list): Add entries for new IPA variables.
12034 (struct tracepoint): Add fields to hold the address range of the
12035 trampoline used by the tracepoint.
12036 (trampoline_buffer_head): New static variable.
12037 (trampoline_buffer_tail): Ditto.
12038 (claim_trampoline_space): New function.
12039 (have_fast_tracepoint_trampoline_buffer): New function.
12040 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
12042 (install_fast_tracepoint): Ditto, also add error buffer argument.
12043 (cmd_qtminftpilen): New function.
12044 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
12045 (fast_tracepoint_from_trampoline_address): New function.
12046 (fast_tracepoint_collecting): Handle trampoline as part of jump
12048 (set_trampoline_buffer_space): New function.
12049 (initialize_tracepoint): Initialize new IPA variables.
12050 * target.h (struct target_ops): Add arguments to
12051 install_fast_tracepoint_jump_pad operation, add new
12052 get_min_fast_tracepoint_insn_len operation.
12053 (target_get_min_fast_tracepoint_insn_len): New.
12054 (install_fast_tracepoint_jump_pad): Add arguments.
12055 * server.h (IPA_BUFSIZ): Define.
12056 * linux-i386-ipa.c: Include extra header files.
12057 (initialize_fast_tracepoint_trampoline_buffer): New function.
12058 (initialize_low_tracepoint): Call it.
12059 * server.h (set_trampoline_buffer_space): Declare.
12060 (claim_trampoline_space): Ditto.
12061 (have_fast_tracepoint_trampoline_buffer): Ditto.
12063 2011-11-14 Yao Qi <yao@codesourcery.com>
12065 * server.c (handle_query): Handle InstallInTrace for qSupported.
12066 * tracepoint.c (add_tracepoint): Sort list.
12067 (install_tracepoint, download_tracepoint): New.
12068 (cmd_qtdp): Call them to install and download tracepoints.
12069 (sort_tracepoints): Removed.
12070 (cmd_qtstart): Update.
12072 2011-11-14 Yao Qi <yao@codesourcery.com>
12074 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
12075 * mem-break.h: Declare.
12076 * tracepoint.c (cmd_qtstart): Move some code to ...
12077 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
12079 (download_tracepoints): Move some code to ...
12080 (download_tracepoint_1): ... here. New.
12082 2011-11-08 Yao Qi <yao@codesourcery.com>
12084 * remote-utils.c (relocate_instruction): A comment fix.
12086 2011-11-07 Joel Brobecker <brobecker@adacore.com>
12088 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
12089 (i386_dr_low_get_control, i386_dr_low_get_status): Use
12090 dr_status_mirror and dr_control_mirror from debug_reg_state.
12091 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
12092 (i386_initial_stuff): Remove use of deleted globals.
12093 (i386_get_thread_context, i386_set_thread_context,
12094 i386_thread_added): Use dr_status_mirror and dr_control_mirror
12095 from debug_reg_state.
12097 2011-11-05 Yao Qi <yao@codesourcery.com>
12099 * tracepoint.c (gdb_collect): Loop over tracepoints of same
12100 address as TPOINT's.
12102 2011-11-02 Stan Shebs <stan@codesourcery.com>
12104 * tracepoint.c (agent_mem_read_string): New function.
12105 (eval_agent_expr): Call it for tracenz.
12106 * server.c (handle_query): Report support for tracenz.
12108 2011-11-02 Yao Qi <yao@codesourcery.com>
12110 * tracepoint.c (cmd_qtstart): Remove unused local variables.
12112 2011-11-02 Yao Qi <yao@codesourcery.com>
12114 * target.h: Fix a typo in comment.
12116 2011-10-31 Pedro Alves <pedro@codesourcery.com>
12118 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
12119 clobber the breakpoints' shadows with fast tracepoint jumps.
12120 * mem-break.h (check_mem_write): Add `myaddr' parameter.
12121 * target.c (write_inferior_memory): Also pass MYADDR down to
12124 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
12126 * configure.ac: Check support for personality routine.
12127 * configure: Regenerate.
12128 * config.in: Likewise.
12129 * linux-low.c: Include <sys/personality.h>.
12130 Define ADDR_NO_RANDOMIZE if necessary.
12131 (linux_create_inferior): Disable address space randomization when
12132 forking inferior, if requested.
12133 (linux_supports_disable_randomization): New function.
12134 (linux_target_ops): Install it.
12135 * server.h (disable_randomization): Declare.
12136 * server.c (disable_randomization): New global variable.
12137 (handle_general_set): Handle QDisableRandomization.
12138 (handle_query): Likewise for qSupported.
12139 (main): Support --disable-randomization and --no-disable-randomization
12140 command line arguments.
12141 * target.h (struct target_ops): Add supports_disable_randomization.
12142 (target_supports_disable_randomization): New macro.
12144 2011-09-29 Mike Frysinger <vapier@gentoo.org>
12146 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
12148 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
12149 [!PT_GETDSBT] (target_loadmap): New definition.
12150 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
12151 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
12152 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
12153 and PT_GETDSBT to LINUX_LOADMAP.
12154 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
12155 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
12157 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
12159 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
12160 (arm_linux_hwbp_cap): New static variable.
12161 (arm_linux_get_hwbp_cap): Replace by ...
12162 (arm_linux_init_hwbp_cap): ... this new function.
12163 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
12164 (arm_linux_get_hw_watchpoint_count): Likewise.
12165 (arm_linux_get_hw_watchpoint_max_length): Likewise.
12166 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
12167 (arm_prepare_to_resume): Use perror_with_name instead of error.
12169 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
12171 * linux-arm-low.c: Include <signal.h>.
12172 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
12173 (struct arm_linux_hwbp_cap): New data type.
12174 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
12175 (struct arm_linux_hw_breakpoint): New data type.
12176 (MAX_BPTS, MAX_WPTS): Define.
12177 (struct arch_process_info, struct arch_lwp_info): New data types.
12178 (arm_linux_get_hwbp_cap): New function.
12179 (arm_linux_get_hw_breakpoint_count): Likewise.
12180 (arm_linux_get_hw_watchpoint_count): Likewise.
12181 (arm_linux_get_hw_watchpoint_max_length): Likewise.
12182 (arm_hwbp_control_initialize): Likewise.
12183 (arm_hwbp_control_is_enabled): Likewise.
12184 (arm_hwbp_control_is_initialized): Likewise.
12185 (arm_hwbp_control_disable): Likewise.
12186 (arm_linux_hw_breakpoint_equal): Likewise.
12187 (arm_linux_hw_point_initialize): Likewise.
12188 (struct update_registers_data): New data structure.
12189 (update_registers_callback: New function.
12190 (arm_insert_point): Likewise.
12191 (arm_remove_point): Likewise.
12192 (arm_stopped_by_watchpoint): Likewise.
12193 (arm_stopped_data_address): Likewise.
12194 (arm_new_process): Likewise.
12195 (arm_new_thread): Likewise.
12196 (arm_prepare_to_resume): Likewise.
12197 (the_low_target): Register arm_insert_point, arm_remove_point,
12198 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
12199 arm_new_thread, and arm_prepare_to_resume.
12201 2011-09-15 Stan Shebs <stan@codesourcery.com>
12203 * server.h (struct emit_ops): Add compare-goto fields.
12204 * tracepoint.c (gdb_agent_op_sizes): New table.
12205 (emit_eq_goto): New function.
12206 (emit_ne_goto): New function.
12207 (emit_lt_goto): New function.
12208 (emit_le_goto): New function.
12209 (emit_gt_goto): New function.
12210 (emit_ge_goto): New function.
12211 (is_goto_target): New function.
12212 (compile_bytecodes): Recognize special cases of compare-goto
12213 combinations and call specialized emitters for them.
12214 * linux-x86-low.c (amd64_emit_eq_goto): New function.
12215 (amd64_emit_ne_goto): New function.
12216 (amd64_emit_lt_goto): New function.
12217 (amd64_emit_le_goto): New function.
12218 (amd64_emit_gt_goto): New function.
12219 (amd64_emit_ge_goto): New function.
12220 (amd64_emit_ops): Add the new functions.
12221 (i386_emit_eq_goto): New function.
12222 (i386_emit_ne_goto): New function.
12223 (i386_emit_lt_goto): New function.
12224 (i386_emit_le_goto): New function.
12225 (i386_emit_gt_goto): New function.
12226 (i386_emit_ge_goto): New function.
12227 (i386_emit_ops): Add the new functions.
12229 2011-09-08 Stan Shebs <stan@codesourcery.com>
12231 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
12232 (i386_emit_epilogue): Restore %ebx.
12234 2011-08-31 Jie Zhang <jzhang918@gmail.com>
12236 * server.c (step_thread): Remove definition.
12237 (process_serial_event): Don't handle Hs.
12238 * server.h (step_thread): Remove declaration.
12239 * target.c (set_desired_inferior): Remove use of step_thread.
12241 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
12243 * linux-low.c: Include linux-procfs.h.
12244 (linux_attach_lwp_1): Update comments.
12245 (linux_attach): Scan for existing threads when attaching to a
12246 process that is the tgid.
12247 * Makefile.in: Update dependencies.
12249 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
12251 * configure.srv: Add linux-procfs.o dependencies.
12253 2011-08-14 Yao Qi <yao@codesourcery.com>
12255 * target.h (struct target_ops): Fix indent.
12256 * win32-low.c (win32_target_ops): Fix comment.
12258 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
12259 Yao Qi <yao@codesourcery.com>
12261 * Makefile.in (clean): Remove tic6x-*.c files.
12262 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
12263 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
12264 (tic6x-c64xp-linux.c): Likewise.
12265 * configure.srv: Add support for tic6x-*-uclinux.
12266 * linux-tic6x-low.c: New.
12267 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
12269 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
12270 Yao Qi <yao@codesourcery.com>
12272 * target.h (struct target_ops): Add read_loadmap.
12273 * linux-low.c (struct target_loadseg): New type.
12274 (struct target_loadmap): New type.
12275 (linux_read_loadmap): New function.
12276 (linux_target_ops): Add linux_read_loadmap.
12277 * server.c (handle_query): Support qXfer:fdpic:read packet.
12278 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
12281 2011-08-05 Eli Zaretskii <eliz@gnu.org>
12283 * win32-low.c: Include <stdint.h>.
12285 2011-07-22 Pedro Alves <pedro@codesourcery.com>
12287 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
12288 to the inferior here.
12289 (i386_remove_aligned_watchpoint): Ditto.
12290 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
12291 fit part of the watchpoint in the debug registers.
12292 (i386_update_inferior_debug_regs): New.
12293 (i386_low_insert_watchpoint): Work on a local mirror of the debug
12294 registers, and only update the inferior on success.
12295 (i386_low_remove_watchpoint): Ditto.
12297 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
12299 * linux-low.c (compare_ints, unique, list_threads, show_process,
12300 linux_core_of_thread): Delete.
12301 (linux_target_ops): Change linux_core_of_thread to
12302 linux_common_core_of_thread.
12303 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
12304 * utils.c (malloc_failure): Change type of argument.
12305 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
12306 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
12307 common/linux-osdata.c, common/ptid.c and common/buffer.c.
12308 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
12309 (IPA_OBJS): Add common-utils-ipa.o.
12310 (ptid_h, linux_osdata_h): New macros.
12311 (server_h): Add common/common-utils.h, common/xml-utils.h,
12312 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
12314 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
12315 ptid.o, buffer.o): New rules.
12316 (linux-low.o): Add common/linux-osdata.h as a dependency.
12317 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
12318 * configure.ac: Add AC_HEADER_DIRENT check.
12319 * config.in: Regenerate.
12320 * configure: Regenerate.
12321 * remote-utils.c (xml_escape_text): Delete.
12322 (buffer_grow, buffer_free, buffer_init, buffer_finish,
12323 buffer_xml_printf): Move to common/buffer.c.
12324 * server.c (main): Remove call to initialize_inferiors.
12325 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
12326 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
12327 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
12328 internal_error, gdb_assert, gdb_assert_fail): Delete.
12329 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
12330 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
12332 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
12333 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
12334 initialize_inferiors): Delete.
12336 2011-07-20 Pedro Alves <pedro@codesourcery.com>
12338 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
12341 2011-05-31 Pedro Alves <pedro@codesourcery.com>
12343 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
12345 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
12347 2011-05-26 Yao Qi <yao@codesourcery.com>
12349 * Makefile.in (thread-db.o): Track dependence to
12350 common/gdb_thread_db.h.
12351 * thread-db.c: include gdb_thread_db.h from right place.
12353 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
12355 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
12356 __FILE__ and __LINE__ to internal_error.
12358 2011-05-13 Doug Evans <dje@google.com>
12360 * thread-db.c (try_thread_db_load_from_sdir): New function.
12361 (try_thread_db_load_from_dir): New function.
12362 (thread_db_load_search): Handle $sdir, ignore $pdir.
12363 Remove trying of system directories if search of
12364 libthread-db-search-path fails, that is now done via $sdir.
12366 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
12368 * server.c (handle_query): Add EnableDisableTracepoints to the list
12369 of supported features.
12370 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
12372 (cmd_qtenable_disable): New.
12373 (cmd_qtstart): Install tracepoints even if disabled.
12374 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
12375 receiving a QTEnable or QTDisable packet.
12376 (gdb_collect): Skip data collection if fast tracepoint is disabled.
12377 (ust_marker_to_static_tracepoint): Do not ignore disabled static
12379 (gdb_probe): Skip data collection if static tracepoint is disabled.
12381 2011-05-10 Doug Evans <dje@google.com>
12383 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
12385 2011-05-04 Doug Evans <dje@google.com>
12387 * linux-low.c (linux_join): Skip process lookup.
12388 * spu-low.c (spu_join): Ditto.
12389 * server.c (join_inferiors_callback): Delete.
12390 (process_serial_event): For 'D' packet (detach) call join_inferior
12393 2011-05-04 Joseph Myers <joseph@codesourcery.com>
12395 * README: Don't mention xscale*-*-linux*.
12396 * configure.srv (xscale*-*-linux*): Don't handle target.
12398 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
12400 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
12402 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
12403 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
12404 (i386_emit_void_call_2): Likewise.
12406 2011-04-26 Yao Qi <yao@codesourcery.com>
12408 * linux-low.c: Move common macros to linux-ptrace.h.
12409 Include linux-ptrace.h.
12410 * Makefile.in (linux_ptrace_h): New.
12411 (linux-low.o): Depends on linux-ptrace.h.
12413 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
12415 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
12416 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
12417 (remote_prepare): New function with most of the TCP code from ...
12418 (remote_open): ... here. Detect PORT here unconditionally. Move also
12419 setting transport_is_reliable.
12420 * server.c (run_once): New variable.
12421 (gdbserver_usage): Document it.
12422 (main): Set run_once for `--once'. Call remote_prepare. Exit after
12423 the first run if RUN_ONCE.
12424 * server.h (run_once, remote_prepare): New declarations.
12426 2011-04-19 Tom Tromey <tromey@redhat.com>
12428 * win32-low.c (handle_load_dll): Remove duplicate "the".
12430 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
12432 Remove support for old Cygwin 1.5 versions.
12433 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
12434 function to avoid warning.
12435 (win32_add_one_solib): Use cygwin_conv_path function to avoid
12438 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
12440 * gdbserver/server.h (Macro _): Define it if not available.
12442 2011-03-14 Michael Snyder <msnyder@vmware.com>
12444 * hostio.c (handle_close): Remove unnecessary null test.
12446 2011-03-10 Joel Brobecker <brobecker@adacore.com>
12448 * Makefile.in (maintainer-clean realclean distclean): Remove
12449 "make ... subdir_do" command.
12451 2011-03-10 Michael Snyder <msnyder@vmware.com>
12453 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
12455 * server.c (handle_v_run): Free alloced buffer on early return.
12457 2011-03-09 Yao Qi <yao@codesourcery.com>
12460 2011-03-04 Yao Qi <yao@codesourcery.com>
12462 * Makefile.in: Remove GNU make feature --directory.
12464 2011-03-05 Yao Qi <yao@codesourcery.com>
12466 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12467 (subdir_do): New make target. Copied from gdb/Makefile.
12468 (maintainer-clean, realclean, distclean, clean): Call corresponding
12469 make targets in common/Makefile.
12471 2011-02-11 Yao Qi <yao@codesourcery.com>
12473 * configure.ac: Call AC_PROG_RANLIB.
12474 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12475 * configure: Regenerate.
12477 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12479 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
12481 2011-03-06 Yao Qi <yao@codesourcery.com>
12483 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
12485 2011-03-05 Yao Qi <yao@codesourcery.com>
12487 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12488 (subdir_do): New make target. Copied from gdb/Makefile.
12489 (maintainer-clean, realclean, distclean, clean): Call corresponding
12490 make targets in common/Makefile.
12492 2011-03-04 Yao Qi <yao@codesourcery.com>
12494 * Makefile.in: Remove GNU make feature --directory.
12496 2011-03-04 Michael Snyder <msnyder@vmware.com>
12498 * server.c (queue_stop_reply): Call xmalloc not malloc.
12500 2011-03-02 Michael Snyder <msnyder@vmware.com>
12502 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
12504 2011-02-28 Michael Snyder <msnyder@vmware.com>
12506 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
12507 (cmd_qtframe): Ditto.
12508 (cmd_qtbuffer): Ditto.
12509 (cmd_bigqtbuffer): Ditto.
12511 * utils.c (decimal2str): Initialize 'width' to nine, then
12512 don't mess with it.
12514 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
12516 * hostio.c (require_data): Free *data, not data.
12518 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12520 * hostio.c (require_data): Use free, not xfree.
12522 2011-02-27 Michael Snyder <msnyder@vmware.com>
12524 * server.c (handle_query): Discard unused value.
12526 * hostio.c (require_data): Free malloc memory before returning
12529 2011-02-26 Michael Snyder <msnyder@vmware.com>
12531 * linux-low.c (list_threads): Call closedir for dirent.
12533 2011-02-27 Michael Snyder <msnyder@vmware.com>
12535 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
12536 a case statement falls through.
12538 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
12540 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
12543 2011-02-26 Michael Snyder <msnyder@vmware.com>
12545 * utils.c (decimal2str): Eliminate dead code and dead param.
12546 (pulongest): Drop dead param from call to decimal2str.
12549 2011-02-24 Joel Brobecker <brobecker@adacore.com>
12551 Revert the following patch (not approved yet):
12552 2011-02-21 Hui Zhu <teawater@gmail.com>
12553 * tracepoint.c (tp_printf): New function.
12554 (eval_agent_expr): Handle gdb_agent_op_printf.
12556 2011-02-21 Hui Zhu <teawater@gmail.com>
12558 * tracepoint.c (tp_printf): New function.
12559 (eval_agent_expr): Handle gdb_agent_op_printf.
12561 2011-02-18 Tom Tromey <tromey@redhat.com>
12563 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
12564 (tracepoint.o): Likewise.
12565 * tracepoint.c (enum gdb_agent_op): Use ax.def.
12566 (gdb_agent_op_names): Likewise.
12568 2011-02-18 Tom Tromey <tromey@redhat.com>
12570 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
12571 gdb_agent_op_rot>: New constants.
12572 (gdb_agent_op_names): Add pick and roll.
12573 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
12576 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
12578 * aclocal.m4: Regenerated with aclocal-1.11.1.
12580 2011-02-14 Pedro Alves <pedro@codesourcery.com>
12582 * server.c (handle_qxfer_traceframe_info): New.
12583 (qxfer_packets): Register "traceframe-info".
12584 (handle_query): Report support for qXfer:traceframe-info:read+.
12585 * tracepoint.c (match_blocktype): New.
12586 (traceframe_find_block_type): Rename to ...
12587 (traceframe_walk_blocks): ... this. Add callback filter argument,
12589 (traceframe_find_block_type): New, reimplemented on top of
12590 traceframe_walk_blocks.
12591 (build_traceframe_info_xml): New.
12592 (traceframe_read_info): New.
12593 * server.h (traceframe_read_info): Declare.
12595 2011-02-11 Yao Qi <yao@codesourcery.com>
12597 * configure.ac: Call AC_PROG_RANLIB.
12598 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12599 * configure: Regenerate.
12601 2011-02-07 Pedro Alves <pedro@codesourcery.com>
12603 * server.c (gdb_read_memory): Change return semantics to allow
12605 (handle_search_memory_1): Adjust.
12606 (process_serial_event) <'m' packet>: Handle partial transfers.
12607 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12609 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12611 * regcache.c (init_register_cache): Initialize
12612 regcache->register_status.
12613 (free_register_cache): Release regcache->register_status.
12614 (regcache_cpy): Copy register_status.
12615 (registers_to_string): Print 'x's for unavailable registers.
12616 (supply_register): Mark the register's status valid or
12617 unavailable, depending on whether a buffer was passed in or not.
12618 (supply_register_zeroed): New.
12619 (supply_regblock): Mark the registers' status valid or
12620 unavailable, depending on whether a buffer was passed in or not.
12621 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12622 (struct regcache): New `register_status' field.
12623 (supply_register_zeroed): Declare.
12624 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12625 supply_register_zeroed, rather than passing a NULL buffer to
12627 * tracepoint.c (fetch_traceframe_registers): Update comment.
12629 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12631 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12634 2011-01-25 Pedro Alves <pedro@codesourcery.com>
12636 * server.h (decode_xfer_write): Change prototype.
12637 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12638 and don't extract the annex here.
12639 * server.c (decode_xfer_read): Remove `annex' parameter,
12640 and don't extract the annex here.
12641 (decode_xfer): New.
12642 (struct qxfer): New.
12643 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12644 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12645 (handle_qxfer_statictrace): New functions, abstracted out from
12646 handle_query, and made to use the struct qxfer interface.
12647 (handle_threads_qxfer_proper): Rename to ...
12648 (handle_qxfer_threads_proper): ... this.
12649 (handle_threads_qxfer): Rename to ...
12650 (handle_qxfer_threads): ... this. Adjust.
12651 (qxfer_packets): New array.
12652 (handle_qxfer): New function.
12653 (handle_query): Use handle_qxfer.
12655 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12657 * gdbreplay.c: Shorten lines of >= 80 columns.
12658 * linux-low.c: Ditto.
12659 * linux-ppc-low.c: Ditto.
12660 * linux-s390-low.c: Ditto.
12661 * linux-sparc-low.c: Ditto.
12662 * linux-x86-low.c: Ditto.
12663 * linux-xtensa-low.c: Ditto.
12664 * mem-break.c: Ditto.
12665 * nto-low.c: Ditto.
12666 * regcache.h: Ditto.
12667 * remote-utils.c: Ditto.
12670 * thread-db.c: Ditto.
12671 * tracepoint.c: Ditto.
12673 * win32-low.h: Ditto.
12675 2011-01-05 Joel Brobecker <brobecker@adacore.com>
12677 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12680 2011-01-01 Joel Brobecker <brobecker@adacore.com>
12682 * server.c (gdbserver_version): Update copyright year in version
12684 * gdbreplay.c (gdbreplay_version): Ditto.
12686 2010-12-29 Jie Zhang <jie.zhang@analog.com>
12688 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12689 * linux-bfin-low.c: New file.
12690 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12691 PT_DATA_ADDR for BFIN targets.
12692 * Makefile.in (SFILES): Add linux-bfin-low.c.
12693 (clean): Remove reg-bfin.c.
12694 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12695 * README: Mention supported Blackfin targets.
12697 2010-12-23 Mike Frysinger <vapier@gentoo.org>
12699 * .gitignore: New file.
12701 2010-11-16 Mike Frysinger <vapier@gentoo.org>
12703 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12705 2010-10-22 Jie Zhang <jie@codesourcery.com>
12707 * Makefile.in: Add FLAGS_TO_PASS variable.
12708 (install): Remove dependency of install-only and recursively
12709 invoke make for install-only.
12711 2010-10-04 Doug Evans <dje@google.com>
12713 * Makefile.in (uninstall): Use $(DESTDIR).
12715 2010-09-24 Pedro Alves <pedro@codesourcery.com>
12719 * linux-x86-low.c (compat_siginfo_from_siginfo)
12720 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12721 si_code is < 0. Check for si_code == SI_TIMER before checking for
12724 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12726 * lynx-i386-low.c: New file.
12727 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12729 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12731 * lynx-low.c (ptrace_request_to_str): Remove handling for
12732 request values that have been removed in LynxOS 5.x.
12734 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12736 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12739 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12741 * configure.ac: Add --enable-inprocess-agent option.
12742 * configure: Rebuilt.
12744 2010-09-06 Yao Qi <yao@codesourcery.com>
12746 * linux-low.c (linux_kill): Remove unused variable.
12747 (linux_stabilize_threads): Likewise.
12748 * server.c (start_inferior): Likewise.
12749 (queue_stop_reply_callback): Likewise.
12750 * tracepoint.c (do_action_at_tracepoint): Likewise.
12752 2010-09-06 Yao Qi <yao@codesourcery.com>
12754 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12757 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12759 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12761 2010-09-06 Pedro Alves <pedro@codesourcery.com>
12763 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12766 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12768 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12769 gdbserver/lynx-ppc-low.c: New files.
12770 * Makefile.in (lynx_low_h): New variable.
12771 (lynx-low.o, lynx-ppc-low.o): New rules.
12772 * configure.ac: On LynxOS, link with -lnetinet.
12773 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12774 * configure: regenerate.
12776 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12778 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12779 * configure.ac: Add check for vasprintf and vsnprintf.
12780 * configure, config.in: Regenerate.
12781 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12783 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12785 * gdbreplay.c: Move include of alloca.h up, next to include of
12787 * server.h: Add include of malloc.h.
12788 * mem-break.c: Remove include of malloc.h.
12789 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12791 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12793 * Makefile.in (memmem.o): Build with -Wno-error.
12795 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12797 * utils.c (xsnprintf): Make non-static.
12798 * server.h: Add xsnprintf declaration.
12799 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12800 replace calls to snprintf by calls to xsnprintf throughout.
12802 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12804 * configure.ac: Add configure check for alloca.
12805 * configure, config.in: Regenerate.
12806 * server.h: Include alloca.h if it exists.
12807 * gdbreplay.c: Include alloca.h if it exists.
12809 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12811 * linux-low.c (__SIGRTMIN): Define if not already defined.
12812 (linux_create_inferior): Check for __ANDROID__ rather than
12814 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12815 are already deferred.
12816 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12817 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12818 stopped and already has a pending signal to report.
12819 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12820 a pending signal to report or is moving out of a jump pad.
12821 (linux_init_signals): Check for __ANDROID__ rather than
12824 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12826 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12827 debug_threads check. Avoid a linear search when not doing debug
12830 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12832 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12833 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12834 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12835 (process_event): Change local fd's type to gdb_fildes_t.
12836 (create_file_handler): Adjust prototype.
12837 (delete_file_handler): Adjust prototype.
12838 (handle_file_event): Adjust prototype. Use pfildes.
12839 (create_file_event): Adjsut prototype.
12840 * remote-utils.c (remote_desc, listen_desc): Change type to
12842 * server.h: New gdb_fildes_t typedef.
12843 [USE_WIN32API]: Include winsock2.h.
12844 (delete_file_handler, add_file_handler): Adjust prototypes.
12845 (pfildes): Declare.
12846 * utils.c (pfildes): New.
12848 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12850 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12851 * configure: Regenerate.
12853 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12855 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12856 (linux_done_accessing_memory): ... this.
12857 (linux_target_ops): Adjust.
12858 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12859 * nto-low.c (nto_target_ops): Adjust comment.
12860 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12861 * spu-low.c (spu_target_ops): Adjust comment.
12862 * target.h (target_ops): Rename unprepare_to_access_memory field
12863 to done_accessing_memory.
12864 (unprepare_to_access_memory): Rename to ...
12865 (done_accessing_memory): ... this.
12867 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12869 * linux-low.c (linux_prepare_to_access_memory): New.
12870 (linux_unprepare_to_access_memory): New.
12871 (linux_target_ops): Install them.
12872 * server.c (read_memory): Rename to ...
12873 (gdb_read_memory): ... this. Use
12874 prepare_to_access_memory/prepare_to_access_memory.
12875 (write_memory): Rename to ...
12876 (gdb_write_memory): ... this. Use
12877 prepare_to_access_memory/prepare_to_access_memory.
12878 (handle_search_memory_1): Adjust.
12879 (process_serial_event): Adjust.
12880 * target.h (struct target_ops): New fields
12881 prepare_to_access_memory and unprepare_to_access_memory.
12882 (prepare_to_access_memory, unprepare_to_access_memory): New.
12883 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12884 prepare_to_access_memory/prepare_to_access_memory.
12885 * nto-low.c (nto_target_ops): Adjust.
12886 * spu-low.c (spu_target_ops): Adjust.
12887 * win32-low.c (win32_target_ops): Adjust.
12889 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12891 * Makefile.in (WARN_CFLAGS): Get it from configure.
12892 (WERROR_CFLAGS): New.
12893 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12894 * configure.ac: Introduce --enable-werror, which adds -Werror to
12895 the compiler command line. Enabled by default. Disable with
12896 --disable-werror. Add -Wdeclaration-after-statement
12897 Wpointer-arith and -Wformat-nonliteral to warning flags.
12898 * configure: Regenerate.
12900 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12902 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12904 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12906 * gdbreplay.c (remote_error): New.
12908 (expect): Use gdbchar. Check for error reading from GDB.
12909 Clarify sync error output.
12910 (play): Check for errors writing to GDB.
12911 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12912 * remote-utils.c (getpkt): Check for errors writing to the remote
12915 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12917 * linux-low.c (linux_wait_1): Move non-debugging code out of
12918 `debug_threads' control.
12920 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12922 * linux-low.c (linux_wait_1): Don't set last_status here.
12923 * server.c (push_event, queue_stop_reply_callback): Assert we're
12924 not pushing a TARGET_WAITKIND_IGNORE event.
12925 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12926 (myresume, handle_target_event): Set the thread's last_resume_kind
12927 and last_status from the target returned status.
12929 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12933 * linux-x86-low.c (update_debug_registers_callback): New.
12934 (i386_dr_low_set_addr): Use it.
12935 (i386_dr_low_get_addr): New.
12936 (i386_dr_low_set_control): Use update_debug_registers_callback.
12937 (i386_dr_low_get_control): New.
12938 (i386_dr_low_get_status): Adjust.
12939 * linux-low.c (linux_stop_lwp): New.
12940 * linux-low.h (linux_stop_lwp): Declare.
12942 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12943 argument instead of a i386_debug_reg_state.
12944 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12945 a i386_debug_reg_state.
12946 (i386_insert_aligned_watchpoint): Adjust.
12947 (i386_remove_aligned_watchpoint): Adjust.
12948 (i386_low_stopped_data_address): Read the debug registers from the
12949 inferior instead of from the mirrors.
12950 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12951 (i386_dr_low_get_addr): Declare.
12952 (i386_dr_low_get_control): Declare.
12953 (i386_dr_low_get_status): Change prototype.
12955 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12956 (i386_dr_low_get_addr): New.
12957 (i386_dr_low_get_control): New.
12958 (i386_dr_low_get_status): Adjust prototype. Return
12960 (i386_initial_stuff): Clear dr_status_mirror and
12962 (i386_get_thread_context): Adjust.
12963 (i386_set_thread_context): Adjust.
12964 (i386_thread_added): Adjust.
12966 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12968 * linux-low.h (linux_thread_area): Delete declaration.
12970 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12972 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12973 after its termination.
12975 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12977 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12978 (gdb_wants_all_stopped): Delete.
12979 (linux_wait_1): Don't call them.
12980 * server.c (handle_v_cont): Tag all threads as want-stopped.
12981 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12982 stopped as "client-wants-stopped".
12984 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12986 * Makefile.in (signals_h): New.
12987 (server_h): Depend on it.
12988 (server.o): Don't depend on $(signals_def).
12989 (signals.o): Depend on $(signals_def).
12991 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12993 * Makefile.in (signals_def): New.
12994 (server_h): Append include/gdb/signals.h and signals_def.
12995 (server.o): Append signals_def.
12997 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12999 * server.c (handle_target_event): Use target_signal_to_host for
13000 resume_info.sig initialization.
13001 * target.h (struct thread_resume) <sig>: New comment.
13003 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
13005 * server.c (handle_query): strcpy() the returned string from paddress()
13006 instead of sprintf().
13007 * utils.c (paddress): Return phex_nz().
13009 2010-07-07 Joel Brobecker <brobecker@adacore.com>
13011 * server.c (handle_v_cont): Call mourn_inferior if process
13013 (myresume): Likewise.
13015 2010-07-01 Pedro Alves <pedro@codesourcery.com>
13017 Static tracepoints, and integration with UST.
13019 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
13020 * mem-break.c (uninsert_all_breakpoints)
13021 (reinsert_all_breakpoints): New.
13022 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
13023 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
13024 (gdb_agent_ust_loaded, helper_thread_id)
13025 (gdb_agent_helper_thread_id): New macros.
13026 (struct ipa_sym_addresses): Add addr_ust_loaded,
13027 addr_helper_thread_id, addr_cmd_buf.
13028 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
13029 (in_process_agent_loaded_ust): New.
13030 (write_e_ust_not_loaded): New.
13031 (maybe_write_ipa_ust_not_loaded): New.
13032 (struct collect_static_trace_data_action): New.
13033 (enum tracepoint_type) <static_tracepoint>: New.
13034 (struct tracepoint) <handle>: Mention static tracepoints.
13035 (struct static_tracepoint_ctx): New.
13036 (CMD_BUF_SIZE): New.
13037 (add_tracepoint_action): Handle static tracepoint actions.
13038 (unprobe_marker_at): New.
13039 (clear_installed_tracepoints): Handle static tracepoints.
13040 (cmd_qtdp): Handle static tracepoints.
13041 (probe_marker_at): New.
13042 (cmd_qtstart): Handle static tracepoints.
13043 (response_tracepoint): Handle static tracepoints.
13044 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
13045 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
13046 (get_context_regcache): Handle static tracepoints.
13047 (do_action_at_tracepoint): Handle static tracepoint actions.
13048 (traceframe_find_block_type): Handle static trace data blocks.
13049 (traceframe_read_sdata): New.
13050 (download_tracepoints): Download static tracepoint actions.
13051 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
13052 (GDB_PROBE_NAME): New.
13054 (GET_UST_SYM): New.
13057 (ust_marker_to_static_tracepoint): New.
13059 (collect_ust_data_at_tracepoint): New.
13060 (gdb_ust_probe): New.
13061 (UNIX_PATH_MAX, SOCK_DIR): New.
13062 (gdb_ust_connect_sync_socket): New.
13063 (resume_thread, stop_thread): New.
13064 (run_inferior_command): New.
13065 (init_named_socket): New.
13066 (gdb_ust_socket_init): New.
13067 (cstr_to_hexstr): New.
13069 (first_marker, next_marker): New.
13070 (response_ust_marker): New.
13071 (cmd_qtfstm, cmd_qtsstm): New.
13072 (unprobe_marker_at, probe_marker_at): New.
13073 (cmd_qtstmat, gdb_ust_thread): New.
13074 (gdb_ust_init): New.
13075 (initialize_tracepoint_ftlib): Call gdb_ust_init.
13076 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
13077 (ST_REGENTRY): New.
13078 (x86_64_st_collect_regmap): New.
13079 (X86_64_NUM_ST_COLLECT_GREGS): New.
13080 (AMD64_RIP_REGNUM): New.
13081 (supply_static_tracepoint_registers): New.
13082 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
13083 (ST_REGENTRY): New.
13084 (i386_st_collect_regmap): New.
13085 (i386_NUM_ST_COLLECT_GREGS): New.
13086 (supply_static_tracepoint_registers): New.
13087 * server.c (handle_query): Handle qXfer:statictrace:read.
13088 <qSupported>: Report support for StaticTracepoints, and
13089 qXfer:statictrace:read features.
13090 * server.h (traceframe_read_sdata)
13091 (supply_static_tracepoint_registers): Declare.
13092 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
13093 (unpack_varlen_hex): Include in IPA build.
13094 * Makefile.in (ustlibs, ustinc): New.
13095 (IPA_OBJS): Add remote-utils-ipa.o.
13096 ($(IPA_LIB)): Link -ldl and -lpthread.
13098 (IPAGENT_CFLAGS): Add UST_CFLAGS.
13099 * config.in, configure: Regenerate.
13101 2010-06-20 Ian Lance Taylor <iant@google.com>
13102 Pedro Alves <pedro@codesourcery.com>
13104 * linux-x86-low.c (always_true): Delete.
13105 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
13106 trying to fool the compiler with always_true.
13108 2010-06-20 Pedro Alves <pedro@codesourcery.com>
13110 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
13111 conditions in gdbserver.
13113 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
13115 * spu-low.c (spu_read_memory): Wrap around local store limit.
13116 (spu_write_memory): Likewise.
13118 2010-06-15 Pedro Alves <pedro@codesourcery.com>
13120 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
13121 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
13123 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
13125 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
13126 uses with LONGEST uses.
13128 2010-06-14 Stan Shebs <stan@codesourcery.com>
13129 Pedro Alves <pedro@codesourcery.com>
13133 * linux-x86-low.c: Include limits.h.
13135 (always_true): New.
13138 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
13139 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
13140 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
13141 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
13142 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
13143 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
13144 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
13145 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
13146 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
13147 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
13148 (amd64_emit_void_call_2): New.
13149 (amd64_emit_ops): New.
13150 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
13151 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
13152 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
13153 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
13154 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
13155 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
13156 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
13157 (i386_emit_call, i386_emit_reg, i386_emit_pop)
13158 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
13159 (i386_emit_stack_adjust, i386_emit_int_call_1)
13160 (i386_emit_void_call_2): New.
13161 (i386_emit_ops): New.
13162 (x86_emit_ops): New.
13163 (the_low_target): Install x86_emit_ops.
13164 * server.h (struct emit_ops): New.
13165 (get_raw_reg_func_addr): Declare.
13166 (current_insn_ptr, emit_error): Declare.
13167 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
13168 (set_trace_state_variable_value): New defines.
13169 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
13170 addr_get_trace_state_variable_value and
13171 addr_set_trace_state_variable_value.
13172 (symbol_list): New fields for get_raw_reg,
13173 get_trace_state_variable_value and set_trace_state_variable_value.
13174 (condfn): New typedef.
13175 (struct tracepoint): New field `compiled_cond'.
13176 (do_action_at_tracepoint): Clear compiled_cond.
13177 (get_trace_state_variable_value, set_trace_state_variable_value):
13179 (condition_true_at_tracepoint): If there's a compiled condition,
13181 (current_insn_ptr, emit_error): New globals.
13182 (struct bytecode_address): New.
13183 (get_raw_reg_func_addr): New.
13184 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
13185 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
13186 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
13187 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
13188 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
13189 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
13190 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
13191 (compile_tracepoint_condition, compile_bytecodes): New.
13192 * target.h (emit_ops): Forward declare.
13193 (struct target_ops): New field emit_ops.
13194 (target_emit_ops): New.
13195 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
13196 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
13197 * linux-low.c (linux_emit_ops): New.
13198 (linux_target_ops): Install it.
13199 * linux-low.h (struct linux_target_ops): New field emit_ops.
13201 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
13203 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
13204 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
13206 2010-06-01 Pedro Alves <pedro@codesourcery.com>
13207 Stan Shebs <stan@codesourcery.com>
13209 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
13210 (all): Depend on $(extra_libraries).
13211 (install-only): Install the IPA.
13212 (IPA_OBJS, IPA_LIB): New.
13213 (clean): Remove the IPA lib.
13214 (IPAGENT_CFLAGS): New.
13215 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
13216 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
13217 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
13218 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
13219 * configure.ac: Check for atomic builtins support in the compiler.
13220 (IPA_DEPFILES, extra_libraries): Define.
13221 * configure.srv (ipa_obj): Add description.
13222 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
13223 (i[34567]86-*-linux*): Set ipa_obj.
13224 (x86_64-*-linux*): Set ipa_obj.
13225 * linux-low.c (stabilizing_threads): New.
13226 (supports_fast_tracepoints): New.
13227 (linux_detach): Stabilize threads before detaching.
13228 (handle_tracepoints): Handle internal tracing breakpoints. Assert
13229 the lwp is either not stabilizing, or is moving out of a jump pad.
13230 (linux_fast_tracepoint_collecting): New.
13231 (maybe_move_out_of_jump_pad): New.
13232 (enqueue_one_deferred_signal): New.
13233 (dequeue_one_deferred_signal): New.
13234 (linux_wait_for_event_1): If moving out of a jump pad, defer
13235 pending signals to later.
13236 (linux_stabilize_threads): New.
13237 (linux_wait_1): Check if threads need moving out of jump pads, and
13239 (stuck_in_jump_pad_callback): New.
13240 (move_out_of_jump_pad_callback): New.
13241 (lwp_running): New.
13242 (linux_resume_one_lwp): Handle moving out of jump pads.
13243 (linux_set_resume_request): Dequeue deferred signals.
13244 (need_step_over_p): Also step over fast tracepoint jumps.
13245 (start_step_over): Also uninsert fast tracepoint jumps.
13246 (finish_step_over): Also reinsert fast tracepoint jumps.
13247 (linux_install_fast_tracepoint_jump): New.
13248 (linux_target_ops): Install linux_stabilize_threads and
13249 linux_install_fast_tracepoint_jump_pad.
13250 * linux-low.h (linux_target_ops) <get_thread_area,
13251 install_fast_tracepoint_jump_pad>: New fields.
13252 (struct lwp_info) <collecting_fast_tracepoint,
13253 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
13254 (linux_get_thread_area): Declare.
13255 * linux-x86-low.c (jump_insn): New.
13256 (x86_get_thread_area): New.
13257 (append_insns): New.
13258 (push_opcode): New.
13259 (amd64_install_fast_tracepoint_jump_pad): New.
13260 (i386_install_fast_tracepoint_jump_pad): New.
13261 (x86_install_fast_tracepoint_jump_pad): New.
13262 (the_low_target): Install x86_get_thread_area and
13263 x86_install_fast_tracepoint_jump_pad.
13264 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
13265 (struct fast_tracepoint_jump): New.
13266 (fast_tracepoint_jump_insn): New.
13267 (fast_tracepoint_jump_shadow): New.
13268 (find_fast_tracepoint_jump_at): New.
13269 (fast_tracepoint_jump_here): New.
13270 (delete_fast_tracepoint_jump): New.
13271 (set_fast_tracepoint_jump): New.
13272 (uninsert_fast_tracepoint_jumps_at): New.
13273 (reinsert_fast_tracepoint_jumps_at): New.
13274 (set_breakpoint_at): Use write_inferior_memory.
13275 (uninsert_raw_breakpoint): Use write_inferior_memory.
13276 (check_mem_read): Mask out fast tracepoint jumps.
13277 (check_mem_write): Mask out fast tracepoint jumps.
13278 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
13279 (set_fast_tracepoint_jump): Declare.
13280 (delete_fast_tracepoint_jump)
13281 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
13282 (reinsert_fast_tracepoint_jumps_at): Declare.
13283 * regcache.c: Don't compile many functions when building the
13284 in-process agent library.
13285 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
13286 the register buffer in the heap.
13287 (free_register_cache): If the register buffer isn't owned by the
13288 regcache, don't free it.
13289 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
13290 pre-existing register caches.
13291 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
13293 (convert_ascii_to_int): : Constify `from' parameter type.
13294 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
13295 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
13296 the needed buffer in-place.
13297 (relocate_instruction): New.
13298 * server.c (handle_query) <qSymbols>: If the target supports
13299 tracepoints, give it a chance of looking up symbols. Report
13300 support for fast tracepoints.
13301 (handle_status): Stabilize threads.
13302 (process_serial_event): Adjust.
13303 * server.h (struct fast_tracepoint_jump): Forward declare.
13304 (struct process_info) <fast_tracepoint_jumps>: New field.
13305 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
13306 (decode_X_packet, decode_M_packet): Adjust.
13307 (relocate_instruction): Declare.
13308 (in_process_agent_loaded): Declare.
13309 (tracepoint_look_up_symbols): Declare.
13310 (struct fast_tpoint_collect_status): Declare.
13311 (fast_tracepoint_collecting): Declare.
13312 (force_unlock_trace_buffer): Declare.
13313 (handle_tracepoint_bkpts): Declare.
13314 (initialize_low_tracepoint)
13315 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
13316 * target.h (struct target_ops) <stabilize_threads,
13317 install_fast_tracepoint_jump_pad>: New fields.
13318 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
13319 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
13320 [HAVE_STDINT_H]: Include stdint.h.
13321 (trace_debug_1): Rename to ...
13322 (trace_vdebug): ... this.
13323 (trace_debug): Rename to ...
13324 (trace_debug_1): ... this. Add `level' parameter.
13325 (trace_debug): New.
13326 (ATTR_USED, ATTR_NOINLINE): New.
13327 (IP_AGENT_EXPORT): New.
13328 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
13329 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
13330 (about_to_request_buffer_space, trace_buffer_is_full)
13331 (stopping_tracepoint, expr_eval_result, error_tracepoint)
13332 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
13333 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
13334 (traceframe_write_count, traceframes_created)
13335 (trace_state_variables)
13336 New renaming defines.
13337 (struct ipa_sym_addresses): New.
13338 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
13339 (symbol_list): New.
13340 (ipa_sym_addrs): New.
13341 (all_tracepoint_symbols_looked_up): New.
13342 (in_process_agent_loaded): New.
13343 (write_e_ipa_not_loaded): New.
13344 (maybe_write_ipa_not_loaded): New.
13345 (tracepoint_look_up_symbols): New.
13346 (debug_threads) [IN_PROCESS_AGENT]: New.
13347 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
13348 (UNKNOWN_SIDE_EFFECTS): New.
13349 (stop_tracing): New.
13350 (flush_trace_buffer): New.
13351 (stop_tracing_bkpt): New.
13352 (flush_trace_buffer_bkpt): New.
13353 (read_inferior_integer): New.
13354 (read_inferior_uinteger): New.
13355 (read_inferior_data_pointer): New.
13356 (write_inferior_data_pointer): New.
13357 (write_inferior_integer): New.
13358 (write_inferior_uinteger): New.
13359 (struct collect_static_trace_data_action): Delete.
13360 (enum tracepoint_type): New.
13361 (struct tracepoint) <type>: New field `type'.
13362 <actions_str, step_actions, step_actions_str>: Only include in
13364 <orig_size, obj_addr_on_target, adjusted_insn_addr>
13365 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
13366 (tracepoints): Use IP_AGENT_EXPORT.
13367 (last_tracepoint): Don't include in the IPA.
13368 (stopping_tracepoint): Use IP_AGENT_EXPORT.
13369 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
13370 (alloced_trace_state_variables): New.
13371 (trace_state_variables): Use IP_AGENT_EXPORT.
13372 (traceframe_t): Delete unused variable.
13373 (circular_trace_buffer): Don't include in the IPA.
13374 (trace_buffer_start): Delete.
13375 (struct trace_buffer_control): New.
13376 (trace_buffer_free): Delete.
13377 (struct ipa_trace_buffer_control): New.
13378 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
13379 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
13381 (trace_buffer_ctrl): New.
13382 (TRACE_BUFFER_CTRL_CURR): New.
13383 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
13384 Reimplement as macros.
13385 (trace_buffer_wrap): Delete.
13386 (traceframe_write_count, traceframe_read_count)
13387 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
13388 (struct tracepoint_hit_ctx) <type>: New field.
13389 (struct fast_tracepoint_ctx): New.
13390 (memory_barrier): New.
13392 (record_tracepoint_error): Update atomically in the IPA.
13393 (clear_inferior_trace_buffer): New.
13394 (about_to_request_buffer_space): New.
13395 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
13396 updating the same buffer.
13397 (add_tracepoint): Default the tracepoint's type to trap
13398 tracepoint, and orig_size to -1.
13399 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
13400 internal variables.
13401 (create_trace_state_variable): New parameter `gdb'. Handle it.
13402 (clear_installed_tracepoints): Clear fast tracepoint jumps.
13403 (cmd_qtdp): Handle fast tracepoints.
13404 (cmd_qtdv): Adjust.
13405 (max_jump_pad_size): New.
13406 (gdb_jump_pad_head): New.
13407 (get_jump_space_head): New.
13408 (claim_jump_space): New.
13409 (sort_tracepoints): New.
13410 (MAX_JUMP_SIZE): New.
13411 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
13413 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
13414 support. Upload fast traceframes, and delete internal IPA
13416 (stop_tracing_handler): New.
13417 (flush_trace_buffer_handler): New.
13418 (cmd_qtstop): Upload fast tracepoints.
13419 (response_tracepoint): Handle fast tracepoints.
13420 (tracepoint_finished_step): Upload fast traceframes. Set the
13421 tracepoint hit context's tracepoint type.
13422 (handle_tracepoint_bkpts): New.
13423 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
13424 type. Add comment about fast tracepoints.
13425 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
13426 non-existing action_str field.
13427 (get_context_regcache): Handle fast tracepoints.
13428 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
13430 (fast_tracepoint_from_jump_pad_address): New.
13431 (fast_tracepoint_from_ipa_tpoint_address): New.
13432 (collecting_t): New.
13433 (force_unlock_trace_buffer): New.
13434 (fast_tracepoint_collecting): New.
13436 (gdb_collect): New.
13437 (write_inferior_data_ptr): New.
13438 (target_tp_heap): New.
13439 (target_malloc): New.
13440 (download_agent_expr): New.
13442 (download_tracepoints): New.
13443 (download_trace_state_variables): New.
13444 (upload_fast_traceframes): New.
13445 (IPA_FIRST_TRACEFRAME): New.
13446 (IPA_NEXT_TRACEFRAME_1): New.
13447 (IPA_NEXT_TRACEFRAME): New.
13448 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
13449 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
13450 (gdb_jump_pad_buffer_end): New.
13451 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
13452 (initialize_tracepoint): Adjust.
13453 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
13454 buffer. Initialize the low module.
13455 * utils.c (PREFIX, TOOLNAME): New.
13456 (malloc_failure): Use PREFIX.
13457 (error): In the IPA, an error causes an exit.
13458 (fatal, warning): Use PREFIX.
13459 (internal_error): Use TOOLNAME.
13460 (NUMCELLS): Increase to 10.
13461 * configure, config.in: Regenerate.
13463 2010-06-01 Pedro Alves <pedro@codesourcery.com>
13465 * server.c (handle_query) <qSupported>: Do two passes over the
13466 qSupported string to avoid nesting strtok.
13468 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13470 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
13472 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
13473 -Wl,--dynamic-list.
13474 * configure: Regenerate.
13475 * proc-service.list: New.
13477 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13479 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
13482 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
13484 * gdbreplay.c (remote_open): Check error return from socket() call by
13485 its equality to -1 not by it being negative.
13486 * remote-utils.c (remote_open): Likewise.
13488 2010-05-23 Pedro Alves <pedro@codesourcery.com>
13490 * config.h: Regenerate.
13492 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13494 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
13495 doesn't provide PTRACE_GET_THREAD_AREA.
13497 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13499 * linux-m68k-low.c: Include <asm/ptrace.h>
13500 (ps_get_thread_area): Implement.
13502 2010-05-03 Doug Evans <dje@google.com>
13504 * event-loop.c (struct callback_event): New struct.
13505 (callback_list): New global.
13506 (append_callback_event, delete_callback_event): New functions.
13507 (process_callback): New function.
13508 (start_event_loop): Call it.
13509 * remote-utils.c (NOT_SCHEDULED): Define.
13510 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
13511 moved out of readchar.
13512 (readchar): Rewrite. Call reschedule before returning.
13513 (reset_readchar): New function.
13514 (remote_close): Call it.
13515 (process_remaining, reschedule): New functions.
13516 * server.h (callback_handler_func): New typedef.
13517 (append_callback_event, delete_callback_event): Declare.
13519 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13521 * proc-service.c (ps_pglobal_lookup): Use
13522 thread_db_look_up_one_symbol.
13523 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
13524 parameter. Use it instead of all_symbols_looked_up.
13525 * server.h (struct process_info) <all_symbols_looked_up>: Delete
13527 (all_symbols_looked_up): Don't declare.
13528 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
13529 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
13531 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
13532 Set all_symbols_looked_up here.
13533 (thread_db_look_up_one_symbol): New.
13534 (thread_db_get_tls_address): Adjust.
13535 (thread_db_load_search, try_thread_db_load_1): Always allocate the
13536 thread_db object on the heap, and tentatively set it in the
13538 (thread_db_init): Don't set all_symbols_looked_up here.
13539 * linux-low.h (thread_db_look_up_one_symbol): Declare.
13541 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13543 * linux-low.c (linux_kill, linux_detach): Adjust.
13544 (status_pending_p_callback): Remove redundant statement. Check
13545 for !TARGET_WAITIKIND_IGNORE, instead of
13546 TARGET_WAITKIND_STOPPED.
13547 (handle_tracepoints): Make sure LWP is locked. Adjust.
13548 (linux_wait_for_event_1): Adjust.
13549 (linux_cancel_breakpoints): New.
13550 (unsuspend_one_lwp): New.
13551 (unsuspend_all_lwps): New.
13552 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
13553 (send_sigstop_callback): Change return type to int, add new
13554 `except' parameter and handle it.
13555 (suspend_and_send_sigstop_callback): New.
13556 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
13557 pass them down. If SUSPEND, also increment the lwp's suspend
13559 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
13560 (need_step_over_p): Don't consider suspended LWPs.
13561 (start_step_over): Adjust.
13562 (proceed_one_lwp): Change return type to int, add new `except'
13563 parameter and handle it.
13564 (unsuspend_and_proceed_one_lwp): New.
13565 (proceed_all_lwps): Use find_inferior instead of
13567 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
13568 also decrement the suspend count of LWPs. Pass `except' down,
13569 instead of hacking its suspend count.
13570 (linux_pause_all): Add `freeze' parameter. Adjust.
13571 (linux_unpause_all): New.
13572 (linux_target_ops): Install linux_unpause_all.
13573 * server.c (handle_status): Adjust.
13574 * target.h (struct target_ops): New fields `unpause_all' and
13575 `cancel_breakpoints'. Add new parameter to `pause_all'.
13576 (pause_all): Add new `freeze' parameter.
13577 (unpause_all): New.
13578 (cancel_breakpoints): New.
13579 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
13580 cancel breakpoints.
13581 (cmd_qtstart): Pause threads.
13582 (stop_tracing): Pause threads, and cancel breakpoints.
13583 * win32-low.c (win32_target_ops): Adjust.
13585 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13587 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13588 the inferior right away from here...
13589 (linux_wait_1): ... to here, and adjust to check the thread's
13590 last_resume_kind instead of the lwp's step or stop_expected flags.
13592 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13594 * README: Use consistent `GDB' and `GDBserver' spellings.
13596 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13598 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13599 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13600 (linux_detach_one_lwp): Assume the lwp is stopped.
13601 (any_thread_of): Delete.
13602 (linux_detach): Stop all lwps here. Don't blindly delete all
13604 (delete_lwp_callback): New.
13605 (linux_mourn): Delete all lwps of the process that is gone.
13606 (linux_wait_1): Don't delete the last lwp of the process here.
13607 * mem-break.h (mark_breakpoints_out): Declare.
13608 * mem-break.c (mark_breakpoints_out): New.
13609 (free_all_breakpoints): Use it.
13610 * server.c (handle_target_event): If the process is gone, mark
13612 * thread-db.c (struct thread_db) <create_bp>: New field.
13613 (thread_db_enable_reporting): Fix prototype. Store a thread event
13614 breakpoint reference in the thread_db struct.
13615 (thread_db_load_search): Clear the thread_db object.
13616 (try_thread_db_load_1): Ditto.
13617 (switch_to_process): New.
13618 (disable_thread_event_reporting): Use it.
13619 (remove_thread_event_breakpoints): New.
13620 (thread_db_detach, thread_db_mourn): Use it.
13622 2010-05-01 Pedro Alves <pedro@codesourcery.com>
13624 * linux-low.c (linux_enable_event_reporting): New.
13625 (linux_wait_for_event_1, handle_extended_wait): Use it.
13627 2010-04-30 Pedro Alves <pedro@codesourcery.com>
13629 * linux-low.c (linux_kill_one_lwp, linux_kill)
13630 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13631 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13632 SIGSTOP even if the LWP is stopped.
13633 (send_sigstop_callback): New.
13634 (stop_all_lwps): Use send_sigstop_callback instead.
13635 (linux_resume_one_thread): Adjust.
13636 (proceed_one_lwp): Still proceed an LWP that the client has
13637 requested to stop, if we haven't reported it as stopped yet. Make
13638 sure that LWPs the client want stopped, have a pending SIGSTOP.
13640 2010-04-26 Doug Evans <dje@google.com>
13642 * server.c (handle_general_set): Make static.
13644 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13645 Print received char after testing for error/eof instead of before.
13646 (input_interrupt): Tweak comment.
13648 2010-04-23 Doug Evans <dje@google.com>
13650 * server.c (start_inferior): Print inferior argv if --debug.
13652 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13654 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13655 * nto-x86-low.c: Include server.h
13657 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13659 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13660 be consistent with other sources of this directory.
13661 (init_registers_amd64): Correct name of source file of this function
13664 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13666 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13667 64-bit executables.
13669 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13671 * win32-i386-low.c: Add 64-bit support.
13672 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13673 (init_registers_amd64): Declare.
13674 (mappings): Add 64-bit version of array.
13675 (init_windows_x86): New function.
13676 (the_low_target): Change init_arch field to init_windows_x86.
13678 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13680 * win32-low.c: Adapt to support also 64-bit architecture.
13681 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13682 (get_image_name): Use SIZE_T type for local variable `done'.
13683 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13684 (toolhelp_get_dll_name): Idem.
13685 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13686 Use uintptr_t typecast to avoid warning.
13687 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13688 (handle_exception): Use phex_nz to avoid warning.
13689 (win32_wait): Remove unused local variable `process'.
13691 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13693 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13696 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13698 * configure.ac: Use `ws2_32' library for srv_mingw.
13699 * configure: Regenerate.
13700 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13701 * remote-utils.c: Likewise.
13703 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13705 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13706 if __x86_64__ is defined.
13708 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13710 * configure: Regenerate.
13712 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13714 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13715 * target.h (target_ops): New get_tib_address field.
13716 * win32-low.h (win32_thread_info): Add thread_local_base field.
13717 * win32-low.c (child_add_thread): Add tlb argument.
13718 Set thread_local_base field to TLB.
13719 (get_child_debug_event): Adapt to child_add_thread change.
13720 (win32_get_tib_address): New function.
13721 (win32_target_ops): Set get_tib_address field to
13722 win32_get_tib_address.
13723 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13725 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13727 * linux-low.c (linux_mourn): Also remove the process.
13728 * server.c (handle_target_event): Don't remove the process here.
13729 * nto-low.c (nto_mourn): New.
13730 (nto_target_ops): Install it.
13731 * spu-low.c (spu_mourn): New.
13732 (spu_target_ops): Install it.
13733 * win32-low.c (win32_mourn): New.
13734 (win32_target_ops): Install it.
13736 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13738 * server.h (buffer_xml_printf): Remove redundant `;'.
13740 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13742 * regcache.c (set_register_cache): Invalidate regcaches before
13743 changing the register cache layout.
13744 (regcache_invalidate_one): Allow a NULL regcache.
13745 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13746 regcaches before changing the register cache layout or the target
13749 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13751 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13752 variable warning on Linux/x86-64.
13754 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13756 GDBserver disconnected tracing support.
13758 * linux-low.c (linux_remove_process): Delete.
13759 (add_lwp): Don't set last_resume_kind here.
13760 (linux_kill): Use `mourn'.
13761 (linux_detach): Use `thread_db_detach', and `mourn'.
13762 (linux_mourn): New.
13763 (linux_attach_lwp_1): Adjust comment.
13764 (linux_attach): last_resume_kind moved the thread_info; adjust.
13765 (status_pending_p_callback): Adjust.
13766 (linux_wait_for_event_1): Adjust.
13767 (count_events_callback, select_singlestep_lwp_callback)
13768 (select_event_lwp_callback, cancel_breakpoints_callback)
13769 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13770 (proceed_one_lwp): Adjust.
13771 (linux_async): Add debug output.
13772 (linux_thread_stopped): New.
13773 (linux_pause_all): New.
13774 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13776 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13777 (thread_db_free): Delete declaration.
13778 (thread_db_detach, thread_db_mourn): Declare.
13779 * thread-db.c (thread_db_init): Use thread_db_mourn.
13780 (thread_db_free): Delete, split in two.
13781 (disable_thread_event_reporting): New.
13782 (thread_db_detach): New.
13783 (thread_db_mourn): New.
13785 * server.h (struct thread_info) <last_resume_kind>: New field.
13786 <attached>: Add comment.
13787 <gdb_detached>: New field.
13788 (handler_func): Change return type to int.
13789 (handle_serial_event, handle_target_event): Ditto.
13790 (gdb_connected): Declare.
13792 (disconnected_tracing): Declare.
13793 (stop_tracing): Declare.
13795 * server.c (handle_query) <qSupported>: Report support for
13796 disconnected tracing.
13797 (queue_stop_reply_callback): Account for running threads.
13798 (gdb_wants_thread_stopped): New.
13799 (gdb_wants_all_threads_stopped): New.
13800 (gdb_reattached_process): New.
13801 (handle_status): Clear the `gdb_detached' flag of all processes.
13802 In all-stop, stop all threads.
13803 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13804 (process_serial_event): If the remote connection breaks, or if an
13805 exit was forced with "monitor exit", force an event loop exit.
13806 Handle disconnected tracing on detach.
13807 (handle_serial_event): Adjust.
13808 (handle_target_event): If GDB isn't connected, forward events back
13809 to the inferior, unless the last process exited, in which case,
13810 exit gdbserver. Adjust interface.
13812 * remote-utils.c (remote_open): Don't block in accept. Instead
13813 register an event loop source on the listen socket file
13814 descriptor. Refactor bits into ...
13815 (listen_desc): ... this new global.
13816 (gdb_connected): ... this new function.
13817 (enable_async_notification): ... this new function.
13818 (handle_accept_event): ... this new function.
13819 (remote_close): Clear remote_desc.
13821 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13823 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13825 (mourn_inferior): Define.
13826 (target_process_qsupported): Avoid the dangling else problem.
13827 (thread_stopped): Define.
13828 (pause_all): Define.
13829 (target_waitstatus_to_string): Declare.
13830 * target.c (target_waitstatus_to_string): New.
13832 * tracepoint.c (tracing): Make extern.
13833 (disconnected_tracing): New.
13834 (stop_tracing): Make extern. Handle tracing stops due to GDB
13836 (cmd_qtdisconnected): New.
13837 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13838 (handle_tracepoint_general_set): Handle QTDisconnected.
13840 * event-loop.c (event_handler_func): Change return type to int.
13841 (process_event): Bail out if the event handler wants the event
13843 (handle_file_event): Ditto.
13844 (start_event_loop): Bail out if the event handler wants the event
13847 * nto-low.c (nto_target_ops): Adjust.
13848 * spu-low.c (spu_wait): Don't remove the process here.
13849 (spu_target_ops): Adjust.
13850 * win32-low.c (win32_wait): Don't remove the process here.
13851 (win32_target_ops): Adjust.
13853 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13855 * regcache.c (realloc_register_cache): Invalidate inferior's
13856 regcache before recreating it.
13858 2010-04-09 Pedro Alves <pedro@codesourcery.com>
13860 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13862 2010-04-09 Stan Shebs <stan@codesourcery.com>
13863 Pedro Alves <pedro@codesourcery.com>
13865 * server.h (LONGEST): New.
13866 (struct thread_info) <while_stepping>: New field.
13867 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13869 (initialize_tracepoint, handle_tracepoint_general_set)
13870 (handle_tracepoint_query, tracepoint_finished_step)
13871 (tracepoint_was_hit, release_while_stepping_state_list):
13872 (current_traceframe): Declare.
13873 * server.c (handle_general_set): Handle tracepoint packets.
13874 (read_memory): New.
13875 (write_memory): New.
13876 (handle_search_memory_1): Use read_memory.
13877 (handle_query): Report support for conditional tracepoints, trace
13878 state variables, and tracepoint sources. Handle tracepoint
13880 (main): Initialize the tracepoints module.
13881 (process_serial_event): Handle traceframe reads/writes.
13883 * linux-low.c (handle_tracepoints): New.
13884 (linux_wait_1): Call it.
13885 (linux_resume_one_lwp): Handle while-stepping.
13886 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13887 (linux_target_ops): Install them.
13888 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13890 * linux-x86-low.c (x86_supports_tracepoints): New.
13891 (the_low_target). Install it.
13893 * mem-break.h (delete_breakpoint): Declare.
13894 * mem-break.c (delete_breakpoint): Make external.
13896 * target.h (struct target_ops): Add `supports_tracepoints',
13897 `read_pc', and `write_pc' fields.
13898 (target_supports_tracepoints): Define.
13899 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13902 * regcache.h (struct regcache) <registers_owned>: New field.
13903 (init_register_cache, regcache_cpy): Declare.
13904 (regcache_read_pc, regcache_write_pc): Declare.
13905 (register_cache_size): Declare.
13906 (supply_regblock): Declare.
13907 * regcache.c (init_register_cache): New.
13908 (new_register_cache): Use it.
13909 (regcache_cpy): New.
13910 (register_cache_size): New.
13911 (supply_regblock): New.
13912 (regcache_read_pc, regcache_write_pc): New.
13914 * tracepoint.c: New.
13916 * Makefile.in (OBS): Add tracepoint.o.
13917 (tracepoint.o): New rule.
13919 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13921 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13923 (i386-mmx.c): Likewise.
13924 (i386-mmx-linux.o): Likewise.
13925 (i386-mmx-linux.c): Likewise.
13927 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13928 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13929 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13930 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13932 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13933 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13934 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13936 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13938 * Makefile.in (clean): Updated.
13940 (i386-avx.c): Likewise.
13941 (i386-avx-linux.o): Likewise.
13942 (i386-avx-linux.c): Likewise.
13943 (amd64-avx.o): Likewise.
13944 (amd64-avx.c): Likewise.
13945 (amd64-avx-linux.o): Likewise.
13946 (amd64-avx-linux.c): Likewise.
13948 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13949 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13950 (srv_amd64_regobj): Add amd64-avx.o.
13951 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13952 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13953 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13954 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13955 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13956 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13957 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13959 * i387-fp.c: Include "i386-xstate.h".
13961 (i387_cache_to_xsave): Likewise.
13962 (i387_xsave_to_cache): Likewise.
13963 (x86_xcr0): Likewise.
13965 * i387-fp.h (i387_cache_to_xsave): Likewise.
13966 (i387_xsave_to_cache): Likewise.
13967 (x86_xcr0): Likewise.
13969 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13970 * linux-crisv32-low.c (target_regsets): Likewise.
13971 * linux-m68k-low.c (target_regsets): Likewise.
13972 * linux-mips-low.c (target_regsets): Likewise.
13973 * linux-ppc-low.c (target_regsets): Likewise.
13974 * linux-s390-low.c (target_regsets): Likewise.
13975 * linux-sh-low.c (target_regsets): Likewise.
13976 * linux-sparc-low.c (target_regsets): Likewise.
13977 * linux-xtensa-low.c (target_regsets): Likewise.
13979 * linux-low.c: Include <sys/uio.h>.
13980 (regsets_fetch_inferior_registers): Support nt_type.
13981 (regsets_store_inferior_registers): Likewise.
13982 (linux_process_qsupported): New.
13983 (linux_target_ops): Add linux_process_qsupported.
13985 * linux-low.h (regset_info): Add nt_type.
13986 (linux_target_ops): Add process_qsupported.
13988 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13990 (init_registers_i386_avx_linux): New.
13991 (init_registers_amd64_avx_linux): Likewise.
13992 (xmltarget_i386_linux_no_xml): Likewise.
13993 (xmltarget_amd64_linux_no_xml): Likewise.
13994 (PTRACE_GETREGSET): Likewise.
13995 (PTRACE_SETREGSET): Likewise.
13996 (x86_fill_xstateregset): Likewise.
13997 (x86_store_xstateregset): Likewise.
13998 (use_xml): Likewise.
13999 (x86_linux_update_xmltarget): Likewise.
14000 (x86_linux_process_qsupported): Likewise.
14001 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
14002 (x86_arch_setup): Don't call init_registers_amd64_linux nor
14003 init_registers_i386_linux here. Call
14004 x86_linux_update_xmltarget.
14005 (the_low_target): Add x86_linux_process_qsupported.
14007 * server.c (handle_query): Call target_process_qsupported.
14009 * target.h (target_ops): Add process_qsupported.
14010 (target_process_qsupported): New.
14012 2010-04-03 Pedro Alves <pedro@codesourcery.com>
14014 * inferiors.c (add_thread): Set last_status kind to
14015 TARGET_WAITKIND_IGNORE.
14016 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
14017 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
14018 (linux_wait_1): Move `thread' local definition to block that uses
14019 it. Don't NULL initialize `event_child'.
14020 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
14021 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
14022 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
14024 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14026 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
14027 an extended waitstatus, or by a watchpoint.
14028 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
14029 thread was stepping or has been stopped by a watchpoint.
14031 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14033 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
14034 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
14035 of another, then delete the previous, and validate all
14037 (validate_inserted_breakpoint): New.
14038 (delete_disabled_breakpoints): New.
14039 (validate_breakpoints): New.
14040 (check_mem_read): Validate breakpoints before trusting their
14041 shadow. Delete disabled breakpoints.
14042 (check_mem_write): Validate breakpoints before trusting they
14043 should be inserted. Delete disabled breakpoints.
14044 * mem-break.h (validate_breakpoints):
14045 * server.c (handle_query): Validate breakpoints when we see a
14048 2010-04-01 Pedro Alves <pedro@codesourcery.com>
14050 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
14051 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
14052 if we could tell there's a GDB breakpoint at stop_pc.
14053 (need_step_over_p): Don't do a step over if we find a GDB
14054 breakpoint at the resume PC.
14056 * mem-break.c (struct raw_breakpoint): New.
14057 (enum bkpt_type): New type `gdb_breakpoint'.
14058 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
14059 fields. New field `raw'.
14060 (find_raw_breakpoint_at): New.
14061 (set_raw_breakpoint_at): Handle refcounting. Create a raw
14062 breakpoint instead.
14063 (set_breakpoint_at): Adjust.
14064 (delete_raw_breakpoint): New.
14065 (release_breakpoint): New.
14066 (delete_breakpoint): Rename to...
14067 (delete_breakpoint_1): ... this. Add proc parameter. Use
14068 release_breakpoint. Return ENOENT.
14069 (delete_breakpoint): Reimplement.
14070 (find_breakpoint_at): Delete.
14071 (find_gdb_breakpoint_at): New.
14072 (delete_breakpoint_at): Delete.
14073 (set_gdb_breakpoint_at): New.
14074 (delete_gdb_breakpoint_at): New.
14075 (gdb_breakpoint_here): New.
14076 (set_reinsert_breakpoint): Use release_breakpoint.
14077 (uninsert_breakpoint): Rename to ...
14078 (uninsert_raw_breakpoint): ... this.
14079 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
14080 (reinsert_raw_breakpoint): Change parameter type to
14082 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
14084 (check_breakpoints): Adjust. Use release_breakpoint.
14085 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
14086 (breakpoint_inserted_here): Ditto.
14087 (check_mem_read): Adjust to iterate over raw breakpoints instead.
14088 Don't trust the breakpoint's shadow if it is not inserted.
14089 (check_mem_write): Adjust to iterate over raw breakpoints instead.
14090 (delete_all_breakpoints): Adjust.
14091 (free_all_breakpoints): Mark all breakpoints as uninserted, and
14092 use delete_breakpoint_1.
14094 * mem-break.h (breakpoints_supported): Delete declaration.
14095 (set_gdb_breakpoint_at): Declare.
14096 (gdb_breakpoint_here): Declare.
14097 (delete_breakpoint_at): Delete.
14098 (delete_gdb_breakpoint_at): Declare.
14100 * server.h (struct raw_breakpoint): Forward declare.
14101 (struct process_info): New field `raw_breakpoints'.
14103 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
14106 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14108 * linux-low.c (status_pending_p_callback): Fix comment.
14109 (linux_wait_for_event_1): Move most of the internal breakpoint
14110 handling from here...
14111 (linux_wait_1): ... to here.
14112 (count_events_callback): New.
14113 (select_singlestep_lwp_callback): New.
14114 (select_event_lwp_callback): New.
14115 (cancel_breakpoints_callback): New.
14116 (select_event_lwp): New.
14117 (linux_wait_1): Simplify internal breakpoint handling. Give equal
14118 priority to all LWPs that have had events that should be reported
14119 to the client. Cancel breakpoints when about to reporting the
14120 event to the client, not while stopping lwps. No longer cancel
14121 finished single-steps here.
14122 (cancel_finished_single_step): Delete.
14123 (cancel_finished_single_steps): Delete.
14125 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14127 * mem-break.c (enum bkpt_type): New.
14128 (struct breakpoint): New field `type'.
14129 (set_breakpoint_at): Change return type to struct breakpoint
14130 pointer. Set type to `other_breakpoint' by default.
14131 (delete_breakpoint): Rewrite, supporting more than one breakpoint
14132 in the breakpoint list.
14133 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
14134 (reinsert_breakpoint): Rename to ...
14135 (reinsert_raw_breakpoint): ... this.
14136 (reinsert_breakpoints_at): Adjust.
14137 * mem-break.h (struct breakpoint): Declare.
14138 (set_breakpoint_at): Change return type to struct breakpoint
14141 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14143 * server.c (handle_query): Assign, not compare.
14145 2010-03-24 Pedro Alves <pedro@codesourcery.com>
14147 Teach linux gdbserver to step-over-breakpoints.
14149 * linux-low.c (can_hardware_single_step): New.
14150 (supports_breakpoints): New.
14151 (handle_extended_wait): If stopping threads, read the stop pc of
14152 the new cloned LWP.
14154 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
14155 low target doesn't support retrieving the PC.
14156 (add_lwp): Set last_resume_kind to resume_continue.
14157 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
14158 (linux_attach): Don't clear stop_expected. Set the lwp's
14159 last_resume_kind to resume_stop.
14160 (linux_detach_one_lwp): Don't check for removed breakpoints.
14161 (check_removed_breakpoint): Delete.
14162 (status_pending_p): Rename to ...
14163 (status_pending_p_callback): ... this. Don't check for removed
14164 breakpoints. Don't consider threads that are stopped from GDB's
14166 (linux_wait_for_lwp): Always read the stop_pc here.
14167 (cancel_breakpoint): New.
14168 (step_over_bkpt): New global.
14169 (linux_wait_for_event_1): Implement stepping over breakpoints.
14170 (gdb_wants_lwp_stopped): New.
14171 (gdb_wants_all_stopped): New.
14172 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
14173 single-step traps here. Store the thread's last reported target
14175 (send_sigstop): Don't clear stop_expected. Always set it,
14177 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
14178 (cancel_finished_single_step): New.
14179 (cancel_finished_single_steps): New.
14180 (wait_for_sigstop): Don't cancel finished single-step traps here.
14181 (linux_resume_one_lwp): Don't check for removed breakpoints.
14182 Don't set `step' on non-hardware step archs.
14183 (linux_set_resume_request): Ignore resume_stop requests if already
14184 stopping or stopped. Set the lwp's last_resume_kind.
14185 (resume_status_pending_p): Don't check for removed breakpoints.
14186 (need_step_over_p): New.
14187 (start_step_over): New.
14188 (finish_step_over): New.
14189 (linux_resume_one_thread): Always queue a sigstop for resume_stop
14190 requests. Clear the thread's last reported target waitstatus.
14191 Don't use the `suspended' flag. Don't consider pending breakpoints.
14192 (linux_resume): Start a step-over if necessary.
14193 (proceed_one_lwp): New.
14194 (proceed_all_lwps): New.
14195 (unstop_all_lwps): New.
14196 * linux-low.h (struct lwp_info): Rewrite comment for the
14197 `suspended' flag. Add the `stop_pc' field. Delete the
14198 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
14199 Add `'last_resume_kind' and `need_step_over' fields.
14200 * inferiors.c (struct thread_info): Delete, moved elsewhere.
14201 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
14202 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
14203 (set_raw_breakpoint_at): New.
14204 (set_breakpoint_at): Rewrite to use it.
14205 (reinsert_breakpoint_handler): Delete.
14206 (set_reinsert_breakpoint): New.
14207 (reinsert_breakpoint_by_bp): Delete.
14208 (delete_reinsert_breakpoints): New.
14209 (uninsert_breakpoint): Rewrite.
14210 (uninsert_breakpoints_at): New.
14211 (reinsert_breakpoint): Rewrite.
14212 (reinsert_breakpoints_at): New.
14213 (check_breakpoints): Rewrite.
14214 (breakpoint_here): New.
14215 (breakpoint_inserted_here): New.
14216 (check_mem_read): Adjust.
14217 * mem-break.h (breakpoints_supported, breakpoint_here)
14218 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
14219 (reinsert_breakpoint_by_bp): Delete declaration.
14220 (delete_reinsert_breakpoints): Declare.
14221 (reinsert_breakpoint): Delete declaration.
14222 (reinsert_breakpoints_at): Declare.
14223 (uninsert_breakpoint): Delete declaration.
14224 (uninsert_breakpoints_at): Declare.
14225 (check_breakpoints): Adjust prototype.
14226 * server.h: Adjust include order.
14227 (struct thread_info): Declare here. Add a `last_status' field.
14229 2010-03-23 Michael Snyder <msnyder@vmware.com>
14231 * server.c (crc32): New function.
14232 (handle_query): Add handling for 'qCRC:' request.
14234 2010-03-23 Pedro Alves <pedro@codesourcery.com>
14236 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
14237 lwp had been stopped by a watchpoint.
14239 2010-03-16 Pedro Alves <pedro@codesourcery.com>
14241 * server.h (internal_error): Declare.
14242 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
14243 * utils.c (internal_error): New function.
14245 2010-03-15 Andreas Schwab <schwab@redhat.com>
14247 * configure.srv: Fix typo setting srv_regobj.
14249 2010-03-15 Pedro Alves <pedro@codesourcery.com>
14251 * linux-low.c (fetch_register): Avoid passing a non string literal
14253 (usr_store_inferior_registers): Ditto.
14255 2010-03-14 Pedro Alves <pedro@codesourcery.com>
14257 * linux-low.c (linux_write_memory): Bail out early if peeking
14260 2010-03-14 Pedro Alves <pedro@codesourcery.com>
14262 * linux-low.h (struct lwp_info): New fields
14263 `stopped_by_watchpoint' and `stopped_data_address'.
14264 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
14265 here, and cache them in the lwp object.
14266 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
14268 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
14270 (linux_stopped_by_watchpoint): Rewrite.
14271 (linux_stopped_data_address): Rewrite.
14273 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
14275 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
14276 switching the current inferior, not before.
14278 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
14280 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
14281 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
14282 i386-linux.c and amd64-linux.c.
14283 (reg-i386.o): Removed.
14284 (reg-i386.c): Likewise.
14285 (reg-i386-linux.o): Likewise.
14286 (reg-i386-linux.c): Likewise.
14287 (reg-x86-64.o): Likewise.
14288 (reg-x86-64.c): Likewise.
14289 (reg-x86-64-linux.o): Likewise.
14290 (reg-x86-64-linux.c): Likewise.
14292 (i386.c): Likewise.
14293 (i386-linux.o): Likewise.
14294 (i386-linux.c): Likewise.
14295 (amd64.o): Likewise.
14296 (amd64.c): Likewise.
14297 (amd64-linux.o): Likewise.
14298 (amd64-linux.c): Likewise.
14300 * configure.srv (srv_i386_regobj): New.
14301 (srv_i386_linux_regobj): Likewise.
14302 (srv_amd64_regobj): Likewise.
14303 (srv_amd64_linux_regobj): Likewise.
14304 (srv_i386_32bit_xmlfiles): Likewise.
14305 (srv_i386_64bit_xmlfiles): Likewise.
14306 (srv_i386_xmlfiles): Likewise.
14307 (srv_amd64_xmlfiles): Likewise.
14308 (srv_i386_linux_xmlfiles): Likewise.
14309 (srv_amd64_linux_xmlfiles): Likewise.
14310 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
14311 srv_xmlfiles to $srv_i386_xmlfiles.
14312 (i[34567]86-*-mingw32ce*): Likewise.
14313 (i[34567]86-*-mingw*): Likewise.
14314 (i[34567]86-*-nto*): Likewise.
14315 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
14316 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
14317 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
14318 (x86_64-*-linux*): Likewise.
14320 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
14321 (init_registers_amd64_linux): New.
14322 (x86_arch_setup): Replace init_registers_x86_64_linux with
14323 init_registers_amd64_linux.
14325 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
14327 * configure.ac: Check for libdl. If it is not available link against
14328 static libthread_db.
14329 * configure: Regenerate.
14331 2010-02-22 Pedro Alves <pedro@codesourcery.com>
14335 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
14336 handing a read watchpoint.
14337 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
14339 2010-02-12 Doug Evans <dje@google.com>
14341 * linux-low.c (linux_supports_tracefork_flag): Document.
14342 (linux_look_up_symbols): Add comment.
14344 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
14346 * regcache.c (supply_register): Clear regcache if buf is NULL.
14348 2010-02-02 Nicolas Roche <roche@sourceware.org>
14349 Joel Brobecker <brobecker@adacore.com>
14351 * inferiors.c (find_inferior): Add function documentation.
14352 (unloaded_dll): Handle the case where the unloaded dll has not
14353 been previously registered in the dll list.
14355 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
14357 * linux-arm-low.c (thumb_breakpoint_len): Delete.
14358 (thumb2_breakpoint): New.
14359 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
14361 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
14363 * linux-low.c (get_stop_pc): Check for SIGTRAP.
14364 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
14367 2010-01-21 Pedro Alves <pedro@codesourcery.com>
14369 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
14371 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
14373 * linux-s390-low.c (s390_collect_ptrace_register)
14374 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
14376 2010-01-21 Doug Evans <dje@google.com>
14378 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
14379 (PTRACE_ARG4_TYPE): New macro.
14380 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
14381 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
14382 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
14383 (usr_store_inferior_registers): Ditto.
14384 (linux_read_memory, linux_write_memory): Ditto.
14385 (linux_test_for_tracefork): Ditto.
14387 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
14388 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
14390 2010-01-21 Pedro Alves <pedro@codesourcery.com>
14392 * proc-service.c (ps_lgetregs): Don't refetch registers from the
14395 2010-01-21 Pedro Alves <pedro@codesourcery.com>
14397 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
14398 prototype to take a regcache. Adjust.
14400 2010-01-20 Pedro Alves <pedro@codesourcery.com>
14402 * regcache.h (struct thread_info): Forward declare.
14403 (struct regcache): New.
14404 (new_register_cache): Adjust prototype.
14405 (get_thread_regcache): Declare.
14406 (free_register_cache): Adjust prototype.
14407 (registers_to_string, registers_from_string): Ditto.
14408 (supply_register, supply_register_by_name, collect_register)
14409 (collect_register_as_string, collect_register_by_name): Ditto.
14410 * regcache.c (struct inferior_regcache_data): Delete.
14411 (get_regcache): Rename to ...
14412 (get_thread_regcache): ... this. Adjust. Switch inferior before
14413 fetching registers.
14414 (regcache_invalidate_one): Adjust.
14415 (regcache_invalidate): Fix prototype.
14416 (new_register_cache): Return the new register cache.
14417 (free_register_cache): Change prototype.
14418 (realloc_register_cache): Adjust.
14419 (registers_to_string): Change prototype to take a regcache. Adjust.
14420 (registers_from_string): Ditto.
14421 (register_data): Ditto.
14422 (supply_register): Ditto.
14423 (supply_register_by_name): Ditto.
14424 (collect_register): Ditto.
14425 (collect_register_as_string): Ditto.
14426 (collect_register_by_name): Ditto.
14427 * server.c (process_serial_event): Adjust.
14428 * linux-low.h (regset_fill_func, regset_store_func): Change
14430 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
14432 * linux-low.c (get_stop_pc): Adjust.
14433 (check_removed_breakpoint): Adjust.
14434 (linux_wait_for_event): Adjust.
14435 (linux_resume_one_lwp): Adjust.
14436 (fetch_register): Add regcache parameter. Adjust.
14437 (usr_store_inferior_registers): Ditto.
14438 (regsets_fetch_inferior_registers): Ditto.
14439 (regsets_store_inferior_registers): Ditto.
14440 (linux_fetch_registers, linux_store_registers): Ditto.
14441 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
14443 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
14445 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
14446 prototype to take a regcache.
14447 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
14448 * remote-utils.c (convert_ascii_to_int, outreg)
14449 (prepare_resume_reply): Change prototype to take a regcache.
14451 * target.h (struct target_ops) <fetch_registers, store_registers>:
14452 Change prototype to take a regcache.
14453 (fetch_inferior_registers, store_inferior_registers): Change
14454 prototype to take a regcache. Adjust.
14455 * proc-service.c (ps_lgetregs): Adjust.
14456 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
14457 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
14458 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
14459 take a regcache. Adjust.
14460 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
14461 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
14462 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
14463 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
14464 * linux-cris-low.c (cris_get_pc, cris_set_pc)
14465 (cris_cannot_fetch_register):
14466 (cris_breakpoint_at): Change prototype to take a regcache.
14468 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
14469 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
14470 to take a regcache. Adjust.
14471 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
14473 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
14474 take a regcache. Adjust.
14475 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
14476 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
14477 (m68k_set_pc): Change prototype to take a regcache. Adjust.
14478 * linux-mips-low.c (mips_get_pc):
14479 (mips_set_pc): Change prototype to take a regcache. Adjust.
14480 (mips_reinsert_addr): Adjust.
14481 (mips_collect_register): Change prototype to take a regcache.
14483 (mips_supply_register):
14484 (mips_collect_register_32bit, mips_supply_register_32bit)
14485 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
14486 (mips_store_fpregset): Ditto.
14487 * linux-ppc-low.c (ppc_supply_ptrace_register)
14488 (ppc_supply_ptrace_register): Ditto.
14489 (parse_spufs_run): Adjust.
14490 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
14491 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
14492 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
14493 take a regcache. Adjust.
14494 * linux-s390-low.c (s390_collect_ptrace_register)
14495 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
14496 (s390_set_pc): Change prototype to take a regcache. Adjust.
14497 (s390_arch_setup): Adjust.
14498 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
14499 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
14500 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14501 (sparc_fill_gregset, sparc_store_gregset_from_stack)
14502 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
14504 (sparc_breakpoint_at): Adjust.
14505 * linux-xtensa-low.c (xtensa_fill_gregset):
14506 (xtensa_store_gregset):
14507 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
14508 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
14509 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
14510 prototype to take a regcache. Adjust.
14511 * win32-arm-low.c (arm_fetch_inferior_register)
14512 (arm_store_inferior_register): Change prototype to take a
14514 * win32-i386-low.c (i386_fetch_inferior_register)
14515 (i386_store_inferior_register): Change prototype to take a
14517 * win32-low.c (child_fetch_inferior_registers)
14518 (child_store_inferior_registers): Change prototype to take a
14520 (win32_wait): Adjust.
14521 (win32_fetch_inferior_registers): Change prototype to take a
14523 (win32_store_inferior_registers): Adjust.
14524 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
14525 store_inferior_register>: Change prototype to take a regcache.
14527 2010-01-20 Doug Evans <dje@google.com>
14529 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
14531 (linux_wait_for_event1, linux_init_signals): Ditto.
14532 (W_STOPCODE): Provide definition if missing.
14534 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
14536 * linux-low.c (linux_core_of_thread): New.
14537 (compare_ints, show_process, list_threads): New.
14538 (linux_qxfer_osdata): Report threads and cores.
14539 (linux_target_op): Register linux_core_of_thread.
14540 * remote-utils.c (prepare_resume_reply): Report the core.
14541 (buffer_xml_printf): Support %d specifier.
14542 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
14544 (handle_query): Handle qXfer:threads. Announce availability
14546 * target.h (struct target_ops): New field core_of_thread.
14548 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
14550 * Makefile.in (clean): Remove new generated files.
14551 (reg-s390.o, reg-s390.c): Remove rules.
14552 (reg-s390x.o, reg-s390x.c): Likewise.
14553 (s390-linux32.o, s390-linux32.c): Add rules.
14554 (s390-linux64.o, s390-linux64.c): Likewise.
14555 (s390x-linux64.o, s390x-linux64.c): Likewise.
14556 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
14557 * linux-s390-low.c: Include <elf.h>.
14558 (HWCAP_S390_HIGH_GPRS): Define if undefined.
14559 (init_registers_s390): Remove prototype.
14560 (init_registers_s390x): Likewise.
14561 (init_registers_s390_linux32): Add prototype.
14562 (init_registers_s390_linux64): Likewise.
14563 (init_registers_s390x_linux64): Likewise.
14564 (s390_num_regs_3264): New define.
14565 (s390_regmap_3264): New global variable.
14566 (s390_cannot_fetch_register): Remove obsolete check.
14567 (s390_cannot_store_register): Likewise.
14568 (s390_collect_ptrace_register): Handle upper/lower register halves.
14569 (s390_supply_ptrace_register): Likewise.
14570 (s390_fill_gregset): Update to register number changes.
14571 (s390_get_hwcap): New routine.
14572 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
14573 Install appropriate regmap and register set.
14575 2010-01-01 Joel Brobecker <brobecker@adacore.com>
14577 * server.c (gdbserver_version): Update copyright year to 2010.
14578 * gdbreplay.c (gdbreplay_version): Likewise.
14580 2009-12-28 Doug Evans <dje@google.com>
14582 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
14583 elf/external.h. Include <elf.h> instead but only if necessary.
14585 2009-12-28 Pedro Alves <pedro@codesourcery.com>
14587 * linux-low.c (linux_remove_process): Remove `detaching'
14588 parameter. Don't release/detach from thread_db here.
14589 (linux_kill): Release/detach from thread_db here, ...
14590 (linux_detach): ... and here, before actually detaching.
14591 (linux_wait_1): ... and here, when a process exits.
14592 * thread-db.c (any_thread_of): New.
14593 (thread_db_free): Switch the current inferior to a thread of the
14596 2009-12-21 Doug Evans <dje@google.com>
14598 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14600 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14601 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14602 warning ifndef __NR_tkill. Move setting of errno there too.
14603 Delete unnecessary resetting of errno after syscall.
14604 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14606 * configure.ac: Check for dladdr.
14607 * config.in: Regenerate.
14608 * configure: Regenerate.
14609 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14610 (try_thread_db_load): Update.
14612 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14614 2009-12-18 Doug Evans <dje@google.com>
14616 * event-loop.c: Include unistd.h if it exists.
14618 * linux-low.c (my_waitpid): Move definition away from being in
14619 between linux_tracefork_child/linux_test_for_tracefork.
14621 * gdb_proc_service.h (psaddr_t): Fix type.
14622 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14623 signature to match glibc.
14625 2009-12-16 Doug Evans <dje@google.com>
14627 * linux-low.c (linux_read_memory): Fix argument to read.
14629 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14631 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14632 events, don't leave current_inferior pointing at null.
14634 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14636 * win32-low.c (LOG): Delete.
14637 (OUTMSG): Output to stderr.
14638 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14639 on compile time LOG macro.
14640 (win32_wait): Fix debug output.
14642 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14644 * win32-low.c (win32_add_one_solib): If the dll name is
14645 "ntdll.dll", prepend the system directory to the dll path.
14647 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14649 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14651 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
14652 Vladimir Prus <vladimir@codesourcery.com>
14654 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14655 * configure.ac: Check for __mcoldfire__ and set
14656 gdb_cv_m68k_is_coldfire.
14657 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14658 reg-cf.o and reg-m68k.o.
14659 * configure: Regenerated.
14661 2009-11-16 Pedro Alves <pedro@codesourcery.com>
14663 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14664 Pass it to thread_db_free.
14665 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14666 proper `detaching' argument to linux_remove_process.
14667 * linux-low.h (thread_db_free): Add `detaching' parameter.
14668 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14670 (thread_db_free): Add `detaching' parameter. Only
14671 call td_ta_clear_event if detaching from process.
14673 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14675 * thread-db.c (thread_db_free): Fix typo.
14677 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14680 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14682 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14684 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14685 with an i686 compiler.
14686 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14688 * configure: Rebuilt.
14690 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14694 * server.c (handle_search_memory_1): Correct read_addr initialization
14695 in loop for searching subsequent chunks.
14697 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14699 * configure.ac: New --with-libthread-db option.
14700 * thread-db.c: Allow direct dependence on libthread_db.
14701 (thread_db_free): Adjust.
14702 * config.in: Regenerate.
14703 * configure: Likewise.
14705 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14708 * thread-db.c (attach_thread): New function.
14709 (maybe_attach_thread): Return success/failure.
14710 (find_new_threads_callback): Adjust.
14711 (thread_db_find_new_threads): Loop until no new threads.
14713 2009-10-13 Pedro Alves <pedro@codesourcery.com>
14715 * proc-service.c (ps_lgetregs): Formatting.
14717 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14719 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14720 * configure.ac: Adjust.
14721 * linux-low.h (struct process_info_private): Move members to struct
14723 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14724 * linux-low.c (linux_remove_process): Adjust.
14725 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14726 * server.c (handle_query): Move code ...
14727 (handle_monitor_command): ... here. New function.
14728 * target.h (struct target_ops): New member.
14729 * thread-db.c (struct thread_db): New.
14730 (libthread_db_search_path): New variable.
14731 (thread_db_create_event, thread_db_enable_reporting)
14732 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14733 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14734 (try_thread_db_load_1, dladdr_to_soname): New functions.
14735 (try_thread_db_load, thread_db_load_search): New functions.
14736 (thread_db_init): Search for libthread_db.
14737 (thread_db_free): New function.
14738 (thread_db_handle_monitor_command): Likewise.
14739 * config.in: Regenerate.
14740 * configure: Regenerate.
14742 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14744 * spu-low.c (spu_kill): Wait for inferior to terminate.
14745 Call clear_inferiors.
14746 (spu_detach): Call clear_inferiors.
14748 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14750 * aclocal.m4: Regenerate.
14751 * config.in: Likewise.
14752 * configure: Likewise.
14754 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14756 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14757 (parse_spufs_run): New function.
14758 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14759 (ppc_breakpoint_at): Handle SPU breakpoints.
14761 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14763 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14764 (SPUFS_MAGIC): Define.
14765 (spu_enumerate_spu_ids): New function.
14766 (linux_qxfer_spu): New function.
14767 (linux_target_ops): Install linux_qxfer_spu.
14769 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14771 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14772 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14773 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14774 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14775 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14776 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14777 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14778 (init_registers_powerpc_cell32l): Add prototype.
14779 (init_registers_powerpc_cell64l): Likewise.
14780 (ppc_arch_setup): Detect Cell/B.E. architecture.
14782 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14784 * Makefile.in (datarootdir): New variable.
14786 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14788 * linux-low.c (linux_write_memory): Update debugging output.
14789 * Makefile.in (clean): Add new descriptions.
14790 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14791 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14792 * configure.srv: Add new files for arm*-*-linux*.
14793 * linux-arm-low.c: Add new declarations.
14794 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14795 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14796 (HWCAP_VFPv3D16): New.
14797 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14798 instead of __IWMMXT__.
14799 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14800 (arm_arch_setup): New.
14801 (target_regsets): Remove #ifdef. Add VFP regset.
14802 (the_low_target): Use arm_arch_setup.
14804 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14806 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14807 the main thread again.
14809 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14811 Adding Neutrino gdbserver.
14812 * configure: Regenerated.
14813 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14814 * configure.srv (i[34567]86-*-nto*): New target.
14815 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14816 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14817 (nto_comctrl) [__QNX__]: New function.
14818 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14820 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
14822 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14825 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14826 Pedro Alves <pedro@codesourcery.com>
14828 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14829 don't support CONTEXT_EXTENDED_REGISTERS.
14830 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14831 (the_low_target): Install them.
14832 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14833 failing with ERROR_PIPE_NOT_CONNECTED.
14835 2009-06-30 Doug Evans <dje@google.com>
14836 Pierre Muller <muller@ics.u-strasbg.fr>
14838 Add h/w watchpoint support to x86-linux, win32-i386.
14839 * Makefile.in (SFILES): Add i386-low.c
14840 (i386_low_h): Define.
14841 (i386-low.o): Add dependencies.
14842 (linux-x86-low.o): Add i386-low.h dependency.
14843 (win32-i386-low.o): Ditto.
14844 * i386-low.c: New file.
14845 * i386-low.h: New file.
14846 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14847 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14848 * linux-low.c (linux_add_process): Initialize arch_private.
14849 (linux_remove_process): Free arch_private.
14850 (add_lwp): Initialize arch_private.
14851 (delete_lwp): Free arch_private.
14852 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14854 * linux-low.h (process_info_private): New member arch_private.
14855 (lwp_info): New member arch_private.
14856 (linux_target_ops): New members new_process, new_thread,
14858 (ptid_of): New macro.
14859 * linux-x86-low.c: Include stddef.h, i386-low.h.
14860 (arch_process_info): New struct.
14861 (arch_lwp_info): New struct.
14862 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14863 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14864 (i386_dr_low_get_status): New function.
14865 (x86_insert_point, x86_remove_point): New functions.
14866 (x86_stopped_by_watchpoint): New function.
14867 (x86_stopped_data_address): New function.
14868 (x86_linux_new_process, x86_linux_new_thread): New functions.
14869 (x86_linux_prepare_to_resume): New function.
14870 (the_low_target): Add entries for insert_point, remove_point,
14871 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14873 * server.c (debug_hw_points): New global.
14874 (monitor_show_help): Document set debug-hw-points.
14875 (handle_query): Process "set debug-hw-points".
14876 * server.h (debug_hw_points): Declare.
14877 (paddress): Declare.
14878 * utils.c (NUMCELLS, CELLSIZE): New macros.
14879 (get_sell, xsnprintf, paddress): New functions.
14880 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14881 remove_point, stopped_by_watchpoint, stopped_data_address.
14882 * win32-i386-low.c: Include i386-low.h.
14883 (debug_reg_state): Replaces dr.
14884 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14885 (i386_dr_low_get_status): New function.
14886 (i386_insert_point, i386_remove_point): New functions.
14887 (i386_stopped_by_watchpoint): New function.
14888 (i386_stopped_data_address): New function.
14889 (i386_initial_stuff): Update.
14890 (get_thread_context,set_thread_context,i386_thread_added): Update.
14891 (the_low_target): Add entries for insert_point,
14892 remove_point, stopped_by_watchpoint, stopped_data_address.
14893 * win32-low.c (win32_insert_watchpoint): New function.
14894 (win32_remove_watchpoint): New function.
14895 (win32_stopped_by_watchpoint): New function.
14896 (win32_stopped_data_address): New function.
14897 (win32_target_ops): Add entries for insert_watchpoint,
14898 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14899 * win32-low.h (win32_target_ops): New members insert_point,
14900 remove_point, stopped_by_watchpoint, stopped_data_address.
14902 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14904 * server.c (process_serial_event): Re-return unsupported, not
14905 error, if the type isn't recognized. Re-allow supporting only
14906 insert or remove packets. Also call require_running for
14907 breakpoints. Add missing break statement to default case. Tidy.
14908 * target.h (struct target_ops): Rename insert_watchpoint to
14909 insert_point, and remove_watchpoint to remove_point.
14911 * linux-low.h (struct linux_target_ops): Likewise.
14912 * linux-low.c (linux_insert_watchpoint): Rename to ...
14913 (linux_insert_point): ... this. Adjust.
14914 (linux_remove_watchpoint): Rename to ...
14915 (linux_remove_point): ... this. Adjust.
14916 (linux_target_ops): Adjust.
14917 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14918 (cris_insert_point): ... this.
14919 (cris_remove_watchpoint): Rename to ...
14920 (cris_remove_point): ... this.
14921 (the_low_target): Adjust.
14923 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14925 * server.c (handle_v_kill): Pass signal_pid to
14926 kill_inferior if multi_process is zero.
14928 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14930 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14931 * target.h (target_ops): Comment for *_watchpoint to make it clear
14932 the functions can get types '0' and '1'.
14934 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14936 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14937 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14938 * regcache.c (get_regcache): Likewise.
14939 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14940 * win32-low.c (child_fetch_inferior_registers): Remove check for
14943 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14944 Pedro Alves <pedro@codesourcery.com>
14946 * target.h (struct target_ops) <supports_multi_process>: New
14948 (target_supports_multi_process): New.
14949 * server.c (handle_query): Even if GDB reports support, only
14950 enable multi-process if the target also supports it. Report
14951 multi-process support only if the target backend supports it.
14952 * linux-low.c (linux_supports_multi_process): New function.
14953 (linux_target_ops): Install it as target_supports_multi_process
14956 2009-05-24 Doug Evans <dje@google.com>
14958 Global renaming of find_thread_pid to find_thread_ptid.
14959 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14960 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14961 All callers updated.
14963 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14964 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14967 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14968 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14969 (linux_resume_one_lwp): Ditto.
14971 2009-05-23 Doug Evans <dje@google.com>
14973 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14974 from struct inferior_list_entry * to struct lwp_info *.
14975 All callers updated.
14977 2009-05-13 Doug Evans <dje@google.com>
14979 * linux-x86-low.c: Don't include assert.h.
14980 (x86_siginfo_fixup): Use fatal, not assert.
14981 (x86_arch_setup): Fix comment.
14983 2009-05-12 Doug Evans <dje@google.com>
14985 Biarch support for i386/amd64 gdbserver.
14986 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14987 Add linux-x86-low.c.
14988 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14989 (linux-x86-low.o): Add.
14990 * linux-x86-64-low.c: Delete.
14991 * linux-i386-low.c: Delete.
14992 * linux-x86-low.c: New file.
14993 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14995 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14997 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14998 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14999 (linux_child_pid_to_exec_file): New function.
15000 (elf_64_header_p, elf_64_file_p): New functions.
15001 (siginfo_fixup): New function.
15002 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
15003 give target a chance to convert layout.
15004 * linux-low.h (linux_target_ops): New member siginfo_fixup.
15005 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
15007 2009-05-07 Doug Evans <dje@google.com>
15009 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
15010 (regsets_store_inferior_registers): Ditto.
15012 2009-05-06 Pedro Alves <pedro@codesourcery.com>
15016 * linux-low.c (must_set_ptrace_flags): Delete.
15017 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
15019 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
15020 `lwp->must_set_ptrace_flags' instead.
15021 (linux_wait_for_event_1): Set ptrace options here.
15022 (linux_wait_1): ... not here.
15024 2009-04-30 Doug Evans <dje@google.com>
15026 * inferiors.c (started_inferior_callback): New function.
15027 (attached_inferior_callback): New function.
15028 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
15029 * server.c (print_started_pid, print_attached_pid): New functions.
15030 (detach_or_kill_for_exit): New function.
15031 (main): Call it instead of for_each_inferior (kill_inferior_callback).
15032 * server.h (have_started_inferiors_p): Declare.
15033 (have_attached_inferiors_p): Declare.
15035 * inferiors.c (remove_process): Fix memory leak, free process.
15036 * linux-low.c (linux_remove_process): New function.
15037 (linux_kill): Call it instead of remove_process.
15038 (linux_detach, linux_wait_1): Ditto.
15040 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
15042 * configure.srv: Add x86 Windows CE target.
15044 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
15046 * inferiors.c (get_thread_process): Make global.
15047 * server.h (get_thread_process): Add prototype.
15048 * thread-db.c (find_one_thread): Use get_thread_process
15049 instead of current_process.
15050 (thread_db_get_tls_address): Do not crash if called when
15051 thread layer is not yet initialized.
15053 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
15055 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
15056 * spu-low.c (current_tid): Rename to ...
15057 (current_ptid): ... this.
15058 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
15059 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
15060 ptid_get_lwp (current_ptid) instead of current_tid.
15061 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
15062 instead of current_tid. Use find_process_pid to verify pid
15063 argument is valid. Pass proper argument to remove_process.
15064 (spu_thread_alive): Compare current_ptid instead of current_tid.
15065 (spu_resume): Likewise.
15067 2009-04-02 Pedro Alves <pedro@codesourcery.com>
15069 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
15072 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15074 Implement the multiprocess extensions, and add linux multiprocess
15077 * server.h (ULONGEST): Declare.
15078 (struct ptid, ptid_t): New.
15079 (minus_one_ptid, null_ptid): Declare.
15080 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
15081 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
15082 (struct inferior_list_entry): Change `id' type from unsigned from
15084 (struct sym_cache, struct breakpoint, struct
15085 process_info_private): Forward declare.
15086 (struct process_info): Declare.
15087 (current_process): Declare.
15088 (all_processes): Declare.
15089 (initialize_inferiors): Declare.
15090 (add_thread): Adjust to use ptid_t.
15091 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
15092 (add_process, remove_process, find_thread_pid): Declare.
15093 (find_inferior_id): Adjust to use ptid_t.
15094 (cont_thread, general_thread, step_thread): Change type to ptid_t.
15095 (multi_process): Declare.
15096 (push_event): Adjust to use ptid_t.
15097 (read_ptid, write_ptid): Declare.
15098 (prepare_resume_reply): Adjust to use ptid_t.
15099 (clear_symbol_cache): Declare.
15100 * inferiors.c (all_processes): New.
15101 (null_ptid, minus_one_ptid): New.
15102 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
15103 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
15104 (add_thread): Change unsigned long to ptid. Remove gdb_id
15106 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
15107 (gdb_id_to_thread): Rename to ...
15108 (find_thread_pid): ... this. Change unsigned long to ptid.
15109 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
15110 (loaded_dll, pull_pid_from_list): Adjust.
15111 (add_process, remove_process, find_process_pid)
15112 (get_thread_process, current_process, initialize_inferiors): New.
15113 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
15114 (struct target_waitstatus) <related_pid>: Ditto.
15115 (struct target_ops) <kill, detach>: Add `pid' argument. Change
15116 return type to int.
15117 (struct target_ops) <join>: Add `pid' argument.
15118 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
15119 (struct target_ops) <wait>: Add `ptid' field. Change return type
15121 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
15122 (mywait): Add `ptid' argument. Change return type to ptid_t.
15123 (target_pid_to_str): Declare.
15124 * target.c (set_desired_inferior): Adjust to use ptids.
15125 (mywait): Add new `ptid' argument. Adjust.
15126 (target_pid_to_str): New.
15127 * mem-break.h (free_all_breakpoints): Declare.
15128 * mem-break.c (breakpoints): Delelete.
15129 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
15130 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
15131 to use per-process breakpoint list.
15132 (free_all_breakpoints): New.
15133 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
15134 (symbol_cache, all_symbols_looked_up): Delete.
15136 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
15138 (prepare_resume_reply): Change ptid argument's type from unsigned
15139 long to ptid_t. Adjust. Implement W;process and X;process.
15140 (free_sym_cache, clear_symbol_cache): New.
15141 (look_up_one_symbol): Adjust to per-process symbol cache. *
15142 * server.c (cont_thread, general_thread, step_thread): Change type
15144 (attached): Delete.
15145 (multi_process): New.
15146 (last_ptid): Change type to ptid_t.
15147 (struct vstop_notif) <ptid>: Change type to ptid_t.
15148 (queue_stop_reply, push_event): Change `ptid' argument's type to
15150 (discard_queued_stop_replies): Add `pid' argument.
15151 (start_inferior): Adjust to use ptids. Adjust to mywait interface
15152 changes. Don't reference the `attached' global.
15153 (attach_inferior): Adjust to mywait interface changes.
15154 (handle_query): Adjust to use ptids. Parse GDB's qSupported
15155 features. Handle and report "multiprocess+". Handle
15157 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
15159 (handle_v_kill): New.
15160 (handle_v_stopped): Adjust to use target_pid_to_str.
15161 (handle_v_requests): Allow multiple attaches and runs when
15162 multiprocess extensions are in effect. Handle "vKill".
15163 (myresume): Adjust to use ptids.
15164 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
15165 (handle_status): Adjust to discard_queued_stop_replies interface
15167 (first_thread_of, kill_inferior_callback)
15168 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
15169 (main): Call initialize_inferiors. Adjust to use ptids, killing
15170 and detaching from all inferiors. Handle multiprocess packet
15172 * linux-low.h: Include gdb_proc_service.h.
15173 (struct process_info_private): New.
15174 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
15175 <lwpid_of>: Use ptid_get_lwp.
15176 (get_lwp_thread): Adjust.
15177 (struct lwp_info): Add `dead' member.
15178 (find_lwp_pid): Declare.
15179 * linux-low.c (thread_db_active): Delete.
15180 (new_inferior): Adjust comment.
15181 (inferior_pid): Delete.
15182 (linux_add_process): New.
15183 (handle_extended_wait): Adjust.
15184 (add_lwp): Change unsigned long to ptid.
15185 (linux_create_inferior): Add process to processes table. Adjust
15186 to use ptids. Don't set new_inferior here.
15187 (linux_attach_lwp): Rename to ...
15188 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
15189 it. Adjust to use ptids.
15190 (linux_attach_lwp): New.
15191 (linux_attach): Add process to processes table. Don't set
15193 (struct counter): New.
15194 (second_thread_of_pid_p, last_thread_of_process_p): New.
15195 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
15196 multiple processes.
15197 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
15198 processes. Remove process from process table.
15199 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
15200 to multiple processes.
15201 (any_thread_of): New.
15202 (linux_detach): Add `pid' argument, and handle it. Remove process
15203 from processes table.
15204 (linux_join): Add `pid' argument. Handle it.
15205 (linux_thread_alive): Change unsighed long argument to ptid_t.
15206 Consider dead lwps as not being alive.
15207 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
15208 threads we're not interested in.
15209 (same_lwp, find_lwp_pid): New.
15210 (linux_wait_for_lwp): Change `pid' argument's type from int to
15212 (linux_wait_for_event): Rename to ...
15213 (linux_wait_for_event_1): ... this. Change `pid' argument's type
15214 from int to ptid_t. Adjust.
15215 (linux_wait_for_event): New.
15216 (linux_wait_1): Add `ptid' argument. Change return type to
15217 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
15218 that exit from the process table.
15219 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
15221 (mark_lwp_dead): New.
15222 (wait_for_sigstop): Adjust to use ptids. If a process exits while
15223 stopping all threads, mark its main lwp as dead.
15224 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
15226 (fetch_register, usr_store_inferior_registers)
15227 (regsets_fetch_inferior_registers)
15228 (regsets_store_inferior_registers, linux_read_memory)
15229 (linux_write_memory): Inline `inferior_pid'.
15230 (linux_look_up_symbols): Adjust to use per-process
15231 `thread_db_active'.
15232 (linux_request_interrupt): Adjust to use ptids.
15233 (linux_read_auxv): Inline `inferior_pid'.
15234 (initialize_low): Don't reference thread_db_active.
15235 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
15236 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
15237 (ps_getpid): Return the pid of the current inferior.
15238 * thread-db.c (proc_handle, thread_agent): Delete.
15239 (thread_db_create_event, thread_db_enable_reporting): Adjust to
15241 (find_one_thread): Change argument type to ptid_t. Adjust to
15243 (maybe_attach_thread): Adjust to per-process data and ptids.
15244 (thread_db_find_new_threads): Ditto.
15245 (thread_db_init): Ditto.
15246 * spu-low.c (spu_create_inferior, spu_attach): Add process to
15247 processes table. Adjust to use ptids.
15248 (spu_kill, spu_detach): Adjust interface. Remove process from
15250 (spu_join, spu_thread_alive): Adjust interface.
15251 (spu_wait): Adjust interface. Remove process from processes
15252 table. Adjust to use ptids.
15253 * win32-low.c (current_inferior_tid): Delete.
15254 (current_inferior_ptid): New.
15255 (debug_event_ptid): New.
15256 (thread_rec): Take a ptid. Adjust.
15257 (child_add_thread): Add `pid' argument. Adjust to use ptids.
15258 (child_delete_thread): Ditto.
15259 (do_initial_child_stuff): Add `attached' argument. Add process to
15261 (child_fetch_inferior_registers, child_store_inferior_registers):
15263 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
15264 (win32_attach): Pass 1 to do_initial_child_stuff.
15265 (win32_kill): Adjust interface. Remove process from processes
15267 (win32_detach): Ditto.
15268 (win32_join): Adjust interface.
15269 (win32_thread_alive): Take a ptid.
15270 (win32_resume): Adjust to use ptids.
15271 (get_child_debug_event): Ditto.
15272 (win32_wait): Adjust interface. Remove exiting process from
15275 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15277 Non-stop mode support.
15279 * server.h (non_stop): Declare.
15280 (gdb_client_data, handler_func): Declare.
15281 (delete_file_handler, add_file_handler, start_event_loop):
15283 (handle_serial_event, handle_target_event, push_event)
15284 (putpkt_notif): Declare.
15285 * target.h (enum resume_kind): New.
15286 (struct thread_resume): Replace `step' field by `kind' field.
15287 (TARGET_WNOHANG): Define.
15288 (struct target_ops) <wait>: Add `options' argument.
15289 <supports_non_stop, async, start_non_stop>: New fields.
15290 (target_supports_non_stop, target_async): New.
15291 (start_non_stop): Declare.
15292 (mywait): Add `options' argument.
15293 * target.c (mywait): Add `options' argument. Print child exit
15294 notifications here.
15295 (start_non_stop): New.
15296 * server.c (non_stop, own_buf, mem_buf): New globals.
15297 (struct vstop_notif): New.
15298 (notif_queue): New global.
15299 (queue_stop_reply, push_event, discard_queued_stop_replies)
15300 (send_next_stop_reply): New.
15301 (start_inferior): Adjust to use resume_kind. Adjust to mywait
15303 (attach_inferior): In non-stop mode, don't wait for the target
15305 (handle_general_set): Handle QNonStop.
15306 (handle_query): When handling qC, return the current general
15307 thread, instead of the first thread of the list.
15308 (handle_query): If the backend supports non-stop mode, include
15309 QNonStop+ in the qSupported query response.
15310 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
15312 (handle_v_attach, handle_v_run): Handle non-stop mode.
15313 (handle_v_stopped): New.
15314 (handle_v_requests): Report support for vCont;t. Handle vStopped.
15315 (myresume): Adjust to use resume_kind. Handle non-stop.
15316 (queue_stop_reply_callback): New.
15317 (handle_status): Handle non-stop mode.
15318 (main): Clear non_stop flag on reconnection. Use the event-loop.
15319 Refactor serial protocol handling from here ...
15320 (process_serial_event): ... to this new function. When GDB
15321 selects any thread, select one here. In non-stop mode, wait until
15322 GDB acks all pending events before exiting.
15323 (handle_serial_event, handle_target_event): New.
15324 * remote-utils.c (remote_open): Install remote_desc in the event
15326 (remote_close): Remove remote_desc from the event loop.
15327 (putpkt_binary): Rename to...
15328 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
15329 (putpkt_binary): New as wrapper around putpkt_binary_1.
15330 (putpkt_notif): New.
15331 (prepare_resume_reply): In non-stop mode, don't change the
15333 * event-loop.c: New.
15334 * Makefile.in (OBJ): Add event-loop.o.
15335 (event-loop.o): New rule.
15337 * linux-low.h (pid_of): Moved here.
15339 (get_lwp_thread): Use lwpid_of.
15340 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
15341 * linux-low.c (pid_of): Delete.
15342 (inferior_pid): Use lwpid_of.
15343 (linux_event_pipe): New.
15344 (target_is_async_p): New.
15346 (handle_extended_wait): Use lwpid_of.
15347 (add_lwp): Don't set lwpid field.
15348 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
15349 (linux_kill_one_lwp): If killing a running lwp, stop it first.
15350 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
15351 (linux_detach_one_lwp): If detaching from a running lwp, stop it
15352 first. Adjust to linux_wait_for_event interface changes. Use
15354 (linux_detach): Don't delete the main lwp here.
15355 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
15356 (status_pending_p): Don't consider explicitly suspended lwps.
15357 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
15358 pointer. Add OPTIONS argument. Change return type to int. Use
15359 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
15360 (linux_wait_for_event): Take an integer pid instead of a lwp_info
15361 pointer. Add status pointer argument. Return a pid instead of a
15362 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
15363 changes. In non-stop mode, don't switch to a random thread.
15364 (linux_wait): Rename to...
15365 (linux_wait_1): ... this. Add target_options argument, and handle
15366 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
15367 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
15368 clean exit and signal exit code. Don't stop all threads in
15369 non-stop mode. In all-stop mode, only stop all threads when
15370 reporting a stop to GDB. Handle explicit thread stop requests.
15371 (async_file_flush, async_file_mark): New.
15373 (send_sigstop): Use lwpid_of.
15374 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
15375 interface changes. In non-stop mode, don't switch to a random
15377 (linux_resume_one_lwp): Use lwpid_of.
15378 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
15379 (linux_resume_one_thread): ... this. Handle resume_stop. In
15380 non-stop mode, don't look for pending flag in all threads.
15381 (resume_status_pending_p): Don't consider explicitly suspended
15383 (my_waitpid): Reimplement. Emulate __WALL.
15384 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15386 (sigchld_handler, linux_supports_non_stop, linux_async)
15387 (linux_start_non_stop): New.
15388 (linux_target_ops): Register linux_supports_non_stop, linux_async
15389 and linux_start_non_stop.
15390 (initialize_low): Install SIGCHLD handler.
15391 * thread-db.c (thread_db_create_event, find_one_thread)
15392 (thread_db_get_tls_address): Use lwpid_of.
15393 * win32-low.c (win32_detach): Adjust to use resume_kind.
15394 (win32_wait): Add `options' argument.
15395 * spu-low.c (spu_resume): Adjust to use resume_kind.
15396 (spu_wait): Add `options' argument.
15398 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15400 Decouple target code from remote protocol.
15402 * target.h (enum target_waitkind): New.
15403 (struct target_waitstatus): New.
15404 (struct target_ops) <wait>: Return an unsigned long. Take a
15405 target_waitstatus pointer instead of a char pointer.
15406 (mywait): Likewise.
15407 * target.c (mywait): Change prototype to return an unsigned long.
15408 Take a target_waitstatus pointer instead of a char pointer. Adjust.
15409 * server.h (thread_from_wait, old_thread_from_wait): Delete
15411 (prepare_resume_reply): Change prototype to take a
15413 * server.c (thread_from_wait, old_thread_from_wait): Delete.
15414 (last_status, last_ptid): New.
15415 (start_inferior): Remove "statusptr" argument. Adjust. Return a
15416 pid instead of a signal.
15417 (attach_inferior): Remove "status" and "signal" parameters.
15419 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
15421 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
15422 (handle_v_requests, myresume): Remove "status" and "signal"
15423 parameters. Adjust.
15424 (handle_status): New.
15425 (main): Delete local `status'. Adjust.
15426 * remote-utils.c: Include target.h.
15427 (prepare_resume_reply): Change prototype to take a
15428 target_waitstatus. Adjust.
15430 * linux-low.c (linux_wait): Adjust to new target_ops->wait
15432 * spu-low.c (spu_wait): Adjust.
15433 * win32-low.c (enum target_waitkind, struct target_waitstatus):
15435 (win32_wait): Adjust.
15437 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15439 * target.h (struct thread_resume): Delete leave_stopped member.
15440 (struct target_ops): Add a `n' argument to the `resume' callback.
15441 * server.c (start_inferior): Adjust.
15442 (handle_v_cont, myresume): Adjust.
15443 * linux-low.c (check_removed_breakpoint): Adjust to resume
15444 interface change, and to removed leave_stopped field.
15445 (resume_ptr): Delete.
15446 (struct thread_resume_array): New.
15447 (linux_set_resume_request): Add new `arg' parameter. Adjust to
15448 resume interface change.
15449 (linux_continue_one_thread, linux_queue_one_thread)
15450 (resume_status_pending_p): Check if the resume field is NULL
15451 instead of checking the leave_stopped member.
15452 (linux_resume): Adjust to the target resume interface change.
15453 * spu-low.c (spu_resume): Adjust to the target resume interface
15455 * win32-low.c (win32_detach, win32_resume): Ditto.
15457 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15459 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
15461 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
15463 (linux_continue_one_thread): Only preserve the stepping flag if
15464 there's a pending breakpoint.
15466 2009-03-31 Pedro Alves <pedro@codesourcery.com>
15468 * server.c (main): After the inferior having exited, call
15469 remote_close before exiting gdbserver.
15471 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
15473 Fix size of FPSCR in Power 7 processors.
15474 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
15475 (PPC_FEATURE_HAS_DFP): New #define.
15476 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
15479 2009-03-23 Pedro Alves <pedro@codesourcery.com>
15481 * server.c (handle_query) Whitespace and formatting.
15483 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15485 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
15486 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
15487 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
15488 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
15489 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
15490 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
15491 Makefile.in, configure.ac: Fix whitespace throughout.
15492 * configure: Regenerate.
15494 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15496 * inferiors.c (find_inferior): Make it safe for the callback
15497 function to delete the currently iterated inferior.
15499 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15501 * Makefile.in (linuw_low_h): Move higher.
15502 (thread-db.o): Depend on $(linux_low_h).
15504 2009-03-17 Pedro Alves <pedro@codesourcery.com>
15506 Rename "process" to "lwp" throughout.
15508 * linux-low.c (all_processes): Rename to...
15509 (all_lwps): ... this.
15510 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
15511 (add_process): Rename to ...
15512 (add_lwp): ... this. Adjust.
15513 (linux_create_inferior): Adjust.
15514 (linux_attach_lwp): Adjust.
15515 (linux_attach): Adjust.
15516 (linux_kill_one_process): Rename to ...
15517 (linux_kill_one_lwp): ... this. Adjust.
15518 (linux_kill): Adjust.
15519 (linux_detach_one_process): Rename to ...
15520 (linux_detach_one_lwp): ... this. Adjust.
15521 (linux_detach): Adjust.
15522 (check_removed_breakpoint): Adjust.
15523 (status_pending_p): Adjust.
15524 (linux_wait_for_process): Rename to ...
15525 (linux_wait_for_lwp): ... this. Adjust.
15526 (linux_wait_for_event): Adjust.
15527 (send_sigstop): Adjust.
15528 (wait_for_sigstop): Adjust.
15529 (stop_all_processes): Rename to ...
15530 (stop_all_lwps): ... this.
15531 (linux_resume_one_process): Rename to ...
15532 (linux_resume_one_lwp): ... this. Adjust.
15533 (linux_set_resume_request, linux_continue_one_thread)
15534 (linux_queue_one_thread, resume_status_pending_p)
15535 (usr_store_inferior_registers, regsets_store_inferior_registers)
15536 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15538 * linux-low.h (get_process): Rename to ...
15539 (get_lwp): ... this. Adjust.
15540 (get_thread_process): Rename to ...
15541 (get_thread_lwp): ... this. Adjust.
15542 (get_process_thread): Rename to ...
15543 (get_lwp_thread): ... this. Adjust.
15544 (struct process_info): Rename to ...
15545 (struct lwp_info): ... this.
15546 (all_processes): Rename to ...
15547 (all_lwps): ... this.
15548 * proc-service.c (ps_lgetregs): Adjust.
15549 * thread-db.c (thread_db_create_event, find_one_thread)
15550 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
15552 2009-03-14 Pedro Alves <pedro@codesourcery.com>
15554 * server.c (handle_query): Handle "qAttached".
15556 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
15558 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
15559 GPLv3, update license URL.
15561 2009-03-01 Doug Evans <dje@google.com>
15563 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
15564 (server_h): Add gdb_signals.h.
15565 (signals.o): Update.
15566 * server.h (target_signal_from_host,target_signal_to_host_p)
15567 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
15569 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
15571 * remote-utils.c (getpkt): Also generate remote-debug
15572 information if noack_mode is set.
15574 2009-02-06 Pedro Alves <pedro@codesourcery.com>
15576 * server.c (handle_query): Report qXfer:siginfo:read and
15577 qXfer:siginfo:write as supported and handle them.
15578 * target.h (struct target_ops) <qxfer_siginfo>: New field.
15579 * linux-low.c (linux_xfer_siginfo): New.
15580 (linux_target_ops): Set it.
15582 2009-01-26 Pedro Alves <pedro@codesourcery.com>
15584 * server.c (gdbserver_usage): Mention --remote-debug.
15585 (main): Accept '--remote-debug' switch.
15587 2009-01-18 Doug Evans <dje@google.com>
15589 * regcache.c (new_register_cache): No need to check result of xcalloc.
15590 * server.c (handle_search_memory): Back out calls to xmalloc,
15591 result is checked and error is returned to user upon failure.
15592 (handle_query): Ditto. Add more checks for result of malloc.
15593 (handle_v_cont): Check result of malloc, report error back to
15595 (handle_v_run): Ditto. Call freeargv.
15596 * server.h (freeargv): Declare.
15597 * utils.c (freeargv): New fn.
15599 2009-01-15 Doug Evans <dje@google.com>
15601 * gdbreplay.c (perror_with_name): Make arg const char *.
15602 * server.h (target_signal_to_name): Make return type const char *.
15603 * thread-db.c (thread_db_err_str): Make return type const char *.
15604 * utils.c (perror_with_name): Make arg const char *.
15606 2009-01-14 Pedro Alves <pedro@codesourcery.com>
15608 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15609 when handling a EXIT_PROCESS_DEBUG_EVENT.
15611 2009-01-06 Joel Brobecker <brobecker@adacore.com>
15613 * gdbreplay.c (gdbreplay_version): Update copyright year.
15614 * server.c (gdbserver_version): Likewise.
15616 2009-01-05 Doug Evans <dje@google.com>
15618 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
15619 (handle_extended_wait): Improve comment.
15621 2008-12-13 Doug Evans <dje@google.com>
15623 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15624 * server.h (ATTR_MALLOC): New macro.
15625 (xmalloc,xcalloc,xstrdup): Declare.
15626 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15627 * inferiors.c: Ditto.
15628 * linux-low.c: Ditto.
15629 * mem-break.c: Ditto.
15630 * regcache.c: Ditto.
15631 * remote-utils.c: Ditto.
15634 * win32-low.c: Ditto.
15636 2008-12-12 Doug Evans <dje@google.com>
15638 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15639 in debugging printf.
15641 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15643 2008-12-09 Doug Evans <dje@google.com>
15645 * linux-low.h (struct process_info): Delete member tid, unused.
15646 * thread-db.c (find_one_thread): Update.
15647 (maybe_attach_thread): Update.
15649 2008-12-02 Pedro Alves <pedro@codesourcery.com>
15651 * target.h (struct target_ops): Add qxfer_osdata member.
15652 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15654 (linux_qxfer_osdata): New functions.
15655 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15657 * server.c (handle_query): Handle "qXfer:osdata:read:".
15658 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15659 (buffer_xml_printf): New functions.
15660 * server.h (struct buffer): New.
15661 (buffer_grow_str, buffer_grow_str0): New macros.
15662 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15663 (buffer_xml_printf): Declare.
15665 2008-11-24 Doug Evans <dje@google.com>
15667 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15669 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15671 * server.c (handle_v_run): Always use the supplied argument list.
15673 2008-11-19 Bob Wilson <bob.wilson@acm.org>
15675 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15676 (xtensa_regmap_table): Add entry for scompare1.
15678 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15680 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15681 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15682 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15683 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15684 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15685 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15686 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15687 XML target descriptions.
15688 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15689 when inferior is running on an ISA 2.05 or later processor. Add
15690 special case to return offset for full 64-bit slot of FPSCR when
15693 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15695 * Makefile.in (SFILES, clean): Added sparc64 files.
15696 (reg-sparc64.o, reg-sparc64.c): New.
15697 * configure.srv (sparc*-*-linux*): New configuration.
15698 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15699 syscall arguments for SPARC.
15700 (regsets_store_inferior_registers): Likewise.
15701 * linux-sparc-low.c: New file.
15703 2008-10-21 Doug Evans <dje@google.com>
15705 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15706 (READLINE_DIR,READLINE_DEP): Delete.
15707 (INTERNAL_CFLAGS): Update.
15708 (LINTFLAGS): Update.
15710 2008-10-10 Pedro Alves <pedro@codesourcery.com>
15712 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15713 whole argv from the last run, not just argv[0].
15715 2008-09-08 Pedro Alves <pedro@codesourcery.com>
15717 * regcache.c (new_register_cache): Return NULL if the register
15718 cache size isn't known yet.
15719 (free_register_cache): Avoid dereferencing a NULL regcache.
15721 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15723 * configure.srv: Merge MIPS and MIPS64.
15725 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15727 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15729 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
15731 * Makefile.in: Add required vsx dependencies.
15733 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15734 Declare init_registers_powerpc_vsx32l.
15735 Declare init_registers_powerpc_vsx64l.
15736 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15737 (ppc_arch_setup): Check for VSX in hwcap.
15738 (ppc_fill_vsxregset): New function.
15739 (ppc_store_vsxregset): New function.
15740 Add new VSX entry in regset_info target_regsets.
15742 * configure.srv: Add new VSX dependencies.
15744 2008-08-12 Pedro Alves <pedro@codesourcery.com>
15746 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15747 (remote_open): Set or clear transport_is_reliable.
15748 (putpkt_binary): Don't expect acks in noack mode.
15749 (getpkt): Don't send ack/nac in noack mode.
15750 * server.c (handle_general_set): Handle QStartNoAckMode.
15751 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15753 (main): Reset noack_mode on every connection.
15754 * server.h (noack_mode): Declare.
15756 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15758 * Makefile.in (GDBREPLAY_OBS): New variable.
15759 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15761 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15762 Daniel Jacobowitz <dan@codesourcery.com>
15764 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15765 (usr_store_inferior_registers): Likewise.
15766 (regsets_store_inferior_registers): Likewise.
15768 2008-07-31 Rolf Jansen <rj@surtec.com>
15769 Pedro Alves <pedro@codesourcery.com>
15771 * configure.ac: Check for memmem declaration.
15772 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15773 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15774 (disable_packet_qfThreadInfo): Unconditionally compile.
15775 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15776 * configure, config.in: Regenerate.
15778 2008-07-28 Doug Kwan <dougkwan@google.com>
15780 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15781 (linux_write_memory): Remove declaration of errno.
15783 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15785 * linux-low.c (handle_extended_wait): Do not use "status"
15786 variable uninitialized.
15788 2008-07-07 Pedro Alves <pedro@codesourcery.com>
15790 * server.c (handle_v_attach): Inhibit reporting dll changes.
15792 2008-06-27 Pedro Alves <pedro@codesourcery.com>
15794 * remote-utils.c (prepare_resume_reply): If requested, don't
15795 output "thread:TID" in the T stop reply.
15797 * server.c (disable_packet_vCont, disable_packet_Tthread)
15798 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15799 (handle_query): If requested, disable support for qC, qfThreadInfo
15801 (handle_v_requests): If requested, disable support for vCont.
15802 (gdbserver_show_disableable): New.
15803 (main): Handle --disable-packet and --disable-packet=LIST.
15805 * server.h (disable_packet_vCont, disable_packet_Tthread)
15806 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15808 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15810 * server.c (gdbserver_usage): Mention --version.
15812 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15814 * Makefile.in (gdbreplay.o): New rule.
15816 2008-06-06 Joseph Myers <joseph@codesourcery.com>
15818 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15819 message, not gdbserver.
15821 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
15822 Nathan Sidwell <nathan@codesourcery.com>
15823 Joseph Myers <joseph@codesourcery.com>
15825 * acinclude.m4: Include ../../config/acx.m4.
15826 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15827 * configure, config.in: Regenerate.
15828 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15829 * server.c (gdbserver_version): Print PKGVERSION.
15830 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15831 (main): Adjust gdbserver_usage calls.
15832 * gdbreplay.c (version, host_name): Add declarations.
15833 (gdbreplay_version, gdbreplay_usage): New.
15834 (main): Accept --version and --help options.
15836 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15838 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15839 (arm_breakpoint_at): Handle Thumb.
15840 (the_low_target): Add comment.
15842 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15844 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15846 2008-05-09 Doug Evans <dje@google.com>
15848 * server.h (decode_search_memory_packet): Declare.
15849 * remote-utils.c (decode_search_memory_packet): New fn.
15850 * server.c (handle_search_memory_1): New fn.
15851 (handle_search_memory): New fn.
15852 (handle_query): Process qSearch:memory packets.
15854 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15856 * regcache.c (registers_length): Remove.
15857 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15858 full register packet.
15859 * regcache.h (registers_length): Remove prototype.
15860 * server.h (PBUFSIZ): Define to 16384.
15862 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15864 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15865 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15866 powerpc-64l.o, and powerpc-altivec64l.o.
15867 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15868 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15869 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15870 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15871 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15874 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15875 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15876 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15877 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15878 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15879 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15880 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15881 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15882 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15883 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15886 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15887 (init_registers_powerpc_32l): ... this new prototype.
15888 (init_registers_powerpc_32): Remove, replace by ...
15889 (init_registers_powerpc_altivec32l): ... this new prototype.
15890 (init_registers_powerpc_e500): Remove, replace by ...
15891 (init_registers_powerpc_e500l): ... this new prototype.
15892 (init_registers_ppc64): Remove, replace by ...
15893 (init_registers_powerpc_64l): ... this new prototype.
15894 (init_registers_powerpc_64): Remove, replace by ...
15895 (init_registers_powerpc_altivec64l): ... this new prototype.
15896 (ppc_num_regs): Set to 73.
15897 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15898 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15899 (ppc_cannot_store_register): Handle orig_r3 and trap.
15900 (ppc_arch_setup): Update init_registers_... calls.
15901 (ppc_fill_gregset): Handle orig_r3 and trap.
15903 * inferiors.c (clear_inferiors): Reset current_inferior.
15905 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15907 * acinclude.m4: Add override.m4.
15908 * configure: Regenerate.
15910 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15912 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15913 initial call to init_register_ppc64.
15915 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15917 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15918 single powerpc*-*-linux* case.
15919 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15921 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15923 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15924 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15926 * linux-ppc-low.c: Include <elf.h>.
15927 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15928 (ppc_hwcap): New global variable.
15929 (ppc_regmap): Remove __SPE__ #ifdef sections.
15930 (ppc_regmap_e500): New global variable.
15931 (ppc_cannot_store_register): Update __SPE__ special case.
15932 (ppc_get_hwcap): New function.
15933 (ppc_arch_setup): Use it to determine whether inferior supports
15934 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15935 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15936 Do not access registers if target does not support AltiVec.
15937 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15938 Do not access registers if target does not support SPE.
15939 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15941 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15943 * linux-low.c (disabled_regsets, num_regsets): New.
15944 (use_regsets_p): Delete.
15945 (linux_wait_for_process): Clear disabled_regsets.
15946 (regsets_fetch_inferior_registers): Check and set it.
15947 (regsets_store_inferior_registers): Likewise.
15948 (linux_fetch_registers, linux_store_registers): Do not use
15950 (initialize_low): Allocate disabled_regsets.
15952 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15954 * Makefile.in (LIBOBJS): New.
15955 (OBS): Use LIBOBJS.
15956 (memmem.o): New rule.
15957 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15958 * configure: Regenerated.
15960 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15962 * server.c (handle_query): Never return "unsupported" for
15963 qXfer:features:read queries.
15965 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15967 * server.c (get_features_xml): Fix inverted condition.
15968 (handle_query): Always support qXfer:feature:read.
15970 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15972 * server.c (wrapper_argv): New.
15973 (start_inferior): Handle wrapper_argv. If set, expect an extra
15975 (gdbserver_usage): Document --wrapper.
15976 (main): Parse --wrapper.
15978 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15980 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15981 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15982 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15983 (ppc_set_pc): Likewise.
15984 (ppc_arch_setup): New function.
15985 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15986 of collect_register.
15987 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15989 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15991 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15992 instead of linux-ppc64-low.o.
15993 * linux-ppc64-low.c: Remove file.
15994 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15995 (linux-ppc64-low.o): Remove rule.
15997 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15998 (init_registers_powerpc_64): Likewise.
15999 (ppc_regmap): Conditionally define depending on __powerpc64__.
16000 (ppc_cannot_store_register): Do not special-case "fpscr" when
16001 compiled on __powerpc64__.
16002 (ppc_collect_ptrace_register): New function.
16003 (ppc_supply_ptrace_register): New function.
16004 (ppc_breakpoint): Change type to "unsigned int".
16005 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
16006 (the_low_target): Conditionally provide initializers for the
16007 arch_setup member depending on __powerpc64__. Install
16008 collect_ptrace_register and supply_ptrace_register members.
16010 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
16012 * regcache.h (gdbserver_xmltarget): Add extern declaration.
16013 * server.c (gdbserver_xmltarget): Define.
16014 (get_features_xml): Use it to replace "target.xml" and arch_string.
16016 * configure.srv: Remove srv_xmltarget. Add XML files that were
16017 mentioned there to srv_xmlfiles instead. Remove conditional tests
16018 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
16019 srv_xmlfiles and srv_regobj to include all possible choices.
16020 * configure.ac (srv_xmltarget): Remove.
16021 (srv_xmlfiles): Do not add "target.xml".
16022 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
16023 checks for supplementary target information.
16024 * configure: Regenerate.
16025 * Makefile.in (XML_TARGET): Remove.
16026 (target.xml): Remove rule.
16027 (clean): Do not clean up target.xml.
16028 (.PRECIOUS): Do not mention target.xml.
16030 * target.h (struct target_ops): Remove arch_string member.
16031 * linux-low.c (linux_arch_string): Remove.
16032 (linux_target_ops): Remove arch_string initializer.
16033 * linux-low.h (struct linux_target_ops): Remove arch_string member.
16034 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
16035 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
16036 * spu-low.c (spu_arch_string): Remove.
16037 (spu_target_ops): Remove arch_string initializer.
16038 * win32-low.c (win32_arch_string): Remove.
16039 (win32_target_ops): Remove arch_string initializer.
16040 * win32-low.h (struct win32_target_ops): Remove arch_string member.
16041 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
16042 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
16044 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16046 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
16047 by collect_ptrace_register and supply_ptrace_register hooks.
16048 * linux-low.c (fetch_register): Use supply_ptrace_register callback
16049 instead of checking for the_low_target.left_pad_xfer.
16050 (usr_store_inferior_registers): Use collect_ptrace_register callback
16051 instead of checking for the_low_target.left_pad_xfer.
16053 * linux-s390-low.c (s390_collect_ptrace_register): New function.
16054 (s390_supply_ptrace_register): Likewise.
16055 (s390_fill_gregset): Call s390_collect_ptrace_register.
16056 (the_low_target): Update.
16058 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
16059 (ppc_supply_ptrace_register): Likewise.
16060 (the_low_target): Update.
16062 * linux-i386-low.c (the_low_target): Update.
16063 * linux-x86-64-low.c (the_low_target): Update.
16065 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16067 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
16068 reg-s390.o and reg-s390x.o.
16070 * linux-low.c (new_inferior): New global variable.
16071 (linux_create_inferior, linux_attach): Set it.
16072 (linux_wait_for_process): Call the_low_target.arch_setup after the
16073 target has stopped for the first time.
16074 (initialize_low): Do not call the_low_target.arch_setup.
16076 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
16077 (s390_set_pc): Likewise.
16078 (s390_arch_setup): New function.
16079 (the_low_target): Use s390_arch_setup as arch_setup routine.
16081 * regcache.c (realloc_register_cache): New function.
16082 (set_register_cache): Call it for each existing regcache.
16084 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
16086 * server.h (init_registers): Remove prototype.
16088 * linux-low.h (struct linux_target_ops): Add arch_setup field.
16089 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
16090 instead of init_registers ().
16091 * linux-arm-low.c (init_registers_arm): Add prototype.
16092 (init_registers_arm_with_iwmmxt): Likewise.
16093 (the_low_target): Add initializer for arch_setup field.
16094 * linux-cris-low.c (init_registers_cris): Add prototype.
16095 (the_low_target): Add initializer for arch_setup field.
16096 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
16097 (the_low_target): Add initializer for arch_setup field.
16098 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
16099 (the_low_target): Add initializer for arch_setup field.
16100 * linux-ia64-low.c (init_registers_ia64): Add prototype.
16101 (the_low_target): Add initializer for arch_setup field.
16102 * linux-m32r-low.c (init_registers_m32r): Add prototype.
16103 (the_low_target): Add initializer for arch_setup field.
16104 * linux-m68k-low.c (init_registers_m68k): Add prototype.
16105 (the_low_target): Add initializer for arch_setup field.
16106 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
16107 (init_registers_mips64_linux): Likewise.
16108 (the_low_target): Add initializer for arch_setup field.
16109 * linux-ppc-low.c (init_registers_ppc): Add prototype.
16110 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
16111 (the_low_target): Add initializer for arch_setup field.
16112 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
16113 (init_registers_powerpc_64): Likewise.
16114 (the_low_target): Add initializer for arch_setup field.
16115 * linux-s390-low.c (init_registers_s390): Add prototype.
16116 (init_registers_s390x): Likewise.
16117 (the_low_target): Add initializer for arch_setup field.
16118 * linux-sh-low.c (init_registers_sh): Add prototype.
16119 (the_low_target): Add initializer for arch_setup field.
16120 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
16121 (the_low_target): Add initializer for arch_setup field.
16122 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
16123 (the_low_target): Add initializer for arch_setup field.
16125 * win32-low.h (struct win32_target_ops): Add arch_setup field.
16126 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
16127 instead of init_registers ().
16128 * win32-arm-low.c (init_registers_arm): Add prototype.
16129 (the_low_target): Add initializer for arch_setup field.
16130 * win32-i386-low.c (init_registers_i386): Add prototype.
16131 (the_low_target): Add initializer for arch_setup field.
16133 * spu-low.c (init_registers_spu): Add prototype.
16134 (initialize_low): Call initialie_registers_spu () instead of
16135 initialize_registers ().
16137 2008-02-19 Pedro Alves <pedro@codesourcery.com>
16139 * server.c (handle_v_requests): When handling the vRun and vAttach
16140 packets, if already debugging a process, don't kill it. Return an
16143 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
16145 * server.c (handle_query): Correct length check.
16147 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
16149 * win32-low.c (do_initial_child_stuff): Add process handle
16150 parameter. Set current_process_handle and current_process_id from the
16151 parameters. Clear globals.
16152 (win32_create_inferior): Don't set current_process_handle and
16153 current_process_id here. Instead pass them on the call to
16154 do_initial_child_stuff.
16155 (win32_attach): Likewise.
16156 (win32_clear_inferiors): New.
16157 (win32_kill): Don't close the current process handle or the
16158 current thread handle here. Instead call win32_clear_inferiors.
16159 (win32_detach): Don't open a new handle to the process. Call
16160 win32_clear_inferiors.
16161 (win32_join): Don't rely on current_process_handle; open a new
16162 handle using the process id.
16163 (win32_wait): Call win32_clear_inferiors when the inferior process
16166 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
16168 * server.c (monitor_show_help): Add "exit".
16170 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
16172 * Makefile.in (SFILES): Add linux-xtensa-low.c.
16173 (clean): Add reg-xtensa.c.
16174 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
16175 * configure.srv (xtensa*-*-linux*) New target.
16176 * linux-xtensa-low.c: New.
16177 * xtensa-xtregs.c: New.
16179 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
16181 * hostio.c: Don't include errno.h.
16182 (errno_to_fileio_errno): Move to hostio-errno.
16183 * hostio.c: (hostio_error): Remove the error parameter. Defer the
16184 error number outputting to the target->hostio_last_error callback.
16185 (hostio_packet_error): Use FILEIO_EINVAL directly.
16186 (handle_open, handle_pread, hostio_error, handle_unlink): Update
16187 calls to hostio_error.
16188 * hostio-errno.c: New.
16189 * server.h (hostio_last_error_from_errno): Declare.
16190 * target.h (target_ops): Add hostio_last_error member.
16191 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
16192 as hostio_last_error handler.
16193 * spu-low.c (spu_target_ops): Likewise.
16194 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
16195 (wince_hostio_last_error): New functions.
16196 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
16197 as hostio_last_error handler.
16198 (win32_target_ops) [!_WIN32_WCE]: Register
16199 hostio_last_error_from_errno as hostio_last_error handler.
16200 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
16201 (hostio-errno.o): New rule.
16202 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
16203 * configure.srv (srv_hostio_err_objs): New variable. Default to
16205 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
16206 * configure: Regenerate.
16208 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16210 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
16211 (linux_kill, linux_detach): Clean up the process list.
16212 * remote-utils.c (remote_open): Improve port number parsing.
16213 (putpkt_binary, input_interrupt): Only send interrupts if the target
16215 * server.c (extended_protocol): Make static.
16216 (attached): Define earlier.
16217 (exit_requested, response_needed, program_argv): New variables.
16218 (target_running): New.
16219 (start_inferior): Clear attached here.
16220 (attach_inferior): Set attached here.
16221 (require_running): Define.
16222 (handle_query): Use require_running and target_running. Implement
16224 (handle_v_attach, handle_v_run): New.
16225 (handle_v_requests): Use require_running. Handle vAttach and vRun.
16226 (gdbserver_usage): Update.
16227 (main): Redo argument parsing. Handle --debug and --multi. Handle
16228 --attach along with other options or after the port. Save
16229 program_argv. Support no initial program. Resynchronize
16230 communication with GDB after an error. Handle "monitor exit".
16231 Use require_running and target_running. Always allow the extended
16232 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
16233 restart in extended mode.
16234 * README: Refer to the GDB manual. Update --attach usage.
16236 2007-12-20 Andreas Schwab <schwab@suse.de>
16238 * linux-low.c (STACK_SIZE): Define.
16239 (linux_tracefork_child): Use it. Use __clone2 on ia64.
16240 (linux_test_for_tracefork): Likewise.
16242 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
16244 * linux-low.c (linux_wait_for_event): Update messages. Do not
16245 reinsert auto-delete breakpoints.
16246 * mem-break.c (struct breakpoint): Change return type of handler to
16248 (set_breakpoint_at): Update handler type.
16249 (reinsert_breakpoint_handler): Return 1 instead of calling
16251 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
16253 (check_breakpoints): Delete auto-delete breakpoints and return 2.
16254 * mem-break.h (set_breakpoint_at): Update handler type.
16255 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
16256 * win32-low.c (auto_delete_breakpoint): New.
16257 (get_child_debug_event): Use it.
16259 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
16261 * configure.ac: Check for pread and pwrite.
16262 * hostio.c (handle_pread): Fall back to lseek and read.
16263 (handle_pwrite): Fall back to lseek and write.
16264 * config.in, configure: Regenerated.
16266 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
16268 * server.c (myresume): Add own_buf argument.
16269 (main): Update calls.
16271 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
16273 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
16274 * remote-utils.c (remote_open): Do not call disable_async_io.
16275 (block_async_io): Delete.
16276 (unblock_async_io): Make static.
16277 (initialize_async_io): New.
16278 * server.c (handle_v_cont): Handle async I/O here.
16279 (myresume): Likewise. Move other common resume tasks here...
16280 (main): ... from here. Call initialize_async_io. Disable async
16281 I/O before the main loop.
16282 * server.h (initialize_async_io): Declare.
16283 (block_async_io, unblock_async_io): Delete prototypes.
16284 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
16286 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
16288 * remote-utils.c (readchar): Allow binary data in received messages.
16290 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
16292 * win32-low.c (attaching): New global.
16293 (win32_create_inferior): Clear the `attaching' global.
16294 (win32_attach): Set the `attaching' global.
16295 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
16296 attaching. Only set a breakpoint at the entry point if not
16299 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
16301 * server.c (main): Don't report dll events on the initial
16302 connection on attaches.
16304 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
16306 * server.c (main): Relax numerical bases supported for the pid of
16307 the --attach command line argument.
16309 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
16311 * win32-low.c (win32_attach): Call OpenProcess before
16312 DebugActiveProcess, not after. Add last error output to error
16315 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
16317 * win32-low.c (win32_get_thread_context)
16318 (win32_set_thread_context): New functions.
16319 (thread_rec): Use win32_get_thread_context.
16320 (continue_one_thread, win32_resume): Use win32_set_thread_context.
16321 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
16324 2007-12-03 Leo Zayas
16325 Pedro Alves <pedro_alves@portugalmail.pt>
16327 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
16329 (child_add_thread): Minor cleanup.
16330 (child_continue): Resume artificially suspended threads before
16331 calling ContinueDebugEvent.
16332 (suspend_one_thread): New.
16333 (fake_breakpoint_event): New.
16334 (get_child_debug_event): Change return type to int. Check here if
16335 gdb sent an interrupt request. If a soft interrupt was requested,
16336 fake a breakpoint event. Return 0 if there is no event to handle,
16338 (win32_wait): Don't check here if gdb sent an interrupt request.
16339 Ensure there is a valid event to handle.
16340 (win32_request_interrupt): Add soft interruption method as last
16343 2007-12-03 Leo Zayas
16344 Pedro Alves <pedro_alves@portugalmail.pt>
16346 * win32-low.h (win32_thread_info): Add descriptions to the
16347 structure members. Replace `suspend_count' counter by a
16349 * win32-low.c (thread_rec): Update condition of when to get the
16350 context from the inferior. Rely on ContextFlags being set if it
16351 has already been retrieved. Only suspend the inferior thread if
16352 we haven't already. Warn if that fails.
16353 (continue_one_thread): s/suspend_count/suspended/. Only call
16354 ResumeThread once. Warn if that fails.
16356 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
16358 * win32-low.c (win32_wait): Don't read from the inferior when it
16359 has already exited.
16361 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
16363 * Makefile.in (win32_low_h): New variable.
16364 (win32-low.o): Add dependency on $(win32_low_h).
16365 (win32-arm-low.o, win32-i386-low.o): New rules.
16367 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
16369 * hostio.c: Correct copyright year.
16371 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
16373 * Makefile.in (OBS): Add hostio.o.
16374 (hostio.o): New rule.
16375 * server.h (handle_vFile): Declare.
16376 * hostio.c: New file.
16377 * server.c (handle_v_requests): Take packet_len and new_packet_len
16378 for binary packets. Call handle_vFile.
16379 (main): Update call to handle_v_requests.
16381 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
16383 * linux-low.c: Include <sched.h>.
16385 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
16387 * linux-low.c (linux_tracefork_grandchild): New.
16388 (linux_tracefork_child): Use clone.
16389 (linux_test_for_tracefork): Use clone; allocate and free a stack.
16391 2007-10-31 Joel Brobecker <brobecker@adacore.com>
16393 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
16395 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
16397 * linux-low.c (handle_extended_wait): Handle unexpected signals.
16399 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
16401 * inferiors.c (change_inferior_id): Delete.
16402 (add_pid_to_list, pull_pid_from_list): New.
16403 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
16404 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
16405 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
16406 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
16407 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
16408 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
16409 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
16410 (using_threads): Always set to 1.
16411 (handle_extended_wait): New.
16412 (add_process): Do not set TID.
16413 (linux_create_inferior): Set must_set_ptrace_flags.
16414 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
16415 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
16416 (linux_thread_alive): Rename TID argument to LWPID.
16417 (linux_wait_for_process): Handle unknown processes. Do not use TID.
16418 (linux_wait_for_event): Do not use TID or check using_threads. Update
16419 call to dead_thread_notify. Call handle_extended_wait.
16420 (linux_create_inferior): Use PTRACE_SETOPTIONS.
16421 (send_sigstop): Delete sigstop_sent.
16422 (wait_for_sigstop): Avoid TID.
16423 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
16424 (linux_test_for_tracefork): New.
16425 (linux_lookup_signals): Use thread_db_active and
16426 linux_supports_tracefork_flag.
16427 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
16428 * linux-low.h (get_process_thread): Avoid TID.
16429 (struct process_ifo): Move thread_known and tid to the end. Remove
16431 (linux_attach_lwp, thread_db_init): Update prototypes.
16432 * server.h (change_inferior_id): Delete prototype.
16433 (add_pid_to_list, pull_pid_from_list): New prototypes.
16434 * thread-db.c (thread_db_use_events): New.
16435 (find_first_thread): Rename to...
16436 (find_one_thread): ...this. Update callers and messages. Do not
16437 call fatal. Check thread_db_use_events. Do not call
16438 change_inferior_id or new_thread_notify.
16439 (maybe_attach_thread): Update. Do not call new_thread_notify.
16440 (thread_db_init): Set thread_db_use_events. Check use_events.
16441 * utils.c (fatal, warning): Correct message prefix.
16443 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
16445 * Makefile.in (clean): Remove new files.
16446 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
16447 (powerpc-64.o, powerpc-64.c): New rules.
16448 * configure.srv: Use alternate register sets for powerpc64-*-linux*
16449 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
16451 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
16453 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
16454 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
16455 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
16456 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
16457 (target_regsets): Add AltiVec and SPE register sets.
16458 * configure.ac: Check for AltiVec and SPE.
16459 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
16460 (ppc_fill_vrregset, ppc_store_vrregset): New.
16461 (target_regsets): Add AltiVec register set.
16462 * configure: Regenerated.
16464 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
16466 * linux-low.c (O_LARGEFILE): Define.
16467 (linux_read_memory): Use /proc/PID/mem.
16468 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
16469 * configure, config.in: Regenerated.
16471 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16473 * linux-low.c (linux_wait_for_event): Do not pass signals while
16476 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16478 * win32-low.c (create_process): New.
16479 (win32_create_inferior): Use create_process instead of
16480 CreateProcess. If create_process failed retry appending an ".exe"
16481 suffix. Store the GetLastError result immediatelly after
16482 create_process calls and use it on the call to error.
16484 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16486 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
16488 2007-08-23 Joel Brobecker <brobecker@adacore.com>
16490 * configure.ac: Switch license to GPLv3.
16492 2007-08-01 Michael Snyder <msnyder@access-company.com>
16494 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
16496 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
16498 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
16500 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
16501 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
16502 CloseToolhelp32Snapshot.
16503 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
16504 CloseToolhelp32Snapshot.
16506 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
16508 * server.c (main): Check for inferior exit before main loop.
16510 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
16512 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
16513 instead of on tmp_desc.
16515 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
16516 Daniel Jacobowitz <dan@codesourcery.com>
16518 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
16519 (add_thread): Minor cleanups.
16520 (clear_inferiors): Move lower in the file. Clear the DLL
16522 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
16523 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
16524 (xml_escape_text): New.
16525 * server.c (handle_query): Handle qXfer:libraries:read. Report it
16527 (handle_v_cont): Report errors.
16528 (gdbserver_version): Update.
16529 (main): Correct size of own_buf. Do not report initial DLL events.
16530 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
16531 (unloaded_dll, xml_escape_text): New.
16532 * win32-low.c (enum target_waitkind): Update comments.
16533 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
16534 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
16535 (win32_EnumProcessModules, win32_GetModuleInformation)
16536 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
16537 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
16538 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
16539 (win32_Module32First, win32_Module32Next, load_toolhelp)
16540 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
16541 (get_child_debug_event): Handle DLL events.
16542 (win32_wait): Likewise.
16544 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16546 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
16547 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
16549 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16551 * win32-low.c (handle_output_debug_string): Ignore event if not
16554 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16556 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
16558 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
16560 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
16562 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
16564 * inferiors.c (change_inferior_id): Add comment.
16565 * linux-low.c (check_removed_breakpoint): Add an early
16566 prototype. Improve debug output.
16567 (linux_attach): Doc update.
16568 (linux_detach_one_process, linux_detach): Clean up before releasing
16570 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
16571 * linux-low.h (struct process_info): Doc improvement.
16572 * mem-break.c (delete_all_breakpoints): New.
16573 * mem-break.h (delete_all_breakpoints): New prototype.
16574 * thread-db.c (find_first_thread): New.
16575 (thread_db_create_event): Call it instead of
16576 thread_db_find_new_threads. Clean up unused variables.
16577 (maybe_attach_thread): Remove first thread handling.
16578 (thread_db_find_new_threads): Use find_first_thread.
16579 (thread_db_get_tls_address): Likewise.
16581 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
16583 * thread-db.c (thread_db_find_new_threads): Add prototype.
16584 (thread_db_create_event): Check for the main thread before adding
16586 (maybe_attach_thread): Only enable event reporting if TID == 0.
16587 (thread_db_get_tls_address): Check for new threads.
16589 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16591 * linux-low.c (linux_create_inferior): Try execv before execvp.
16592 * spu-low.c (spu_create_inferior): Likewise.
16594 2007-06-13 Mike Frysinger <vapier@gentoo.org>
16596 * linux-low.c (linux_create_inferior): Change execv to execvp.
16597 * spu-low.c (spu_create_inferior): Likewies.
16599 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16601 * Makefile.in (clean): Clean new files instead of deleted ones.
16602 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16603 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16605 * configure.srv: Specify XML files and new regformats for MIPS and
16607 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16608 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16609 an entry for the restart register.
16610 (mips_cannot_fetch_register, mips_cannot_store_register)
16611 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16612 register names to match the XML descriptions.
16613 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16614 restart register instead of $0.
16616 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16617 Markus Deuling <deuling@de.ibm.com>
16619 * remote-utils.c (decode_xfer_write): New function.
16620 * server.h (decode_xfer_write): Add prototype.
16621 * server.c (handle_query): Add PACKET_LEN argument. Support
16622 qXfer:spu:read and qXfer:spu:write packets.
16623 (main): Pass packet_len to handle_query.
16624 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16625 * target.h (target_ops): Add qxfer_spu.
16627 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16629 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16630 accessing non-seekable spufs files.
16632 2007-05-16 Markus Deuling <deuling@de.ibm.com>
16634 * server.c (handle_query): Add reply for qC packet.
16636 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16637 Leo Zayas <lerele@champenstudios@com>
16639 * server.h (check_remote_input_interrupt_request): New function.
16640 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16641 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16642 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16643 (check_remote_input_interrupt_request): New function.
16644 * server.h (check_remote_input_interrupt_request): Declare.
16645 * win32-low.c (winapi_DebugBreakProcess,
16646 winapi_GenerateConsoleCtrlEvent): New typedefs.
16647 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16649 (win32_wait): Check for remote interrupt request
16650 with check_remote_input_interrupt_request.
16651 (win32_request_interrupt): New function.
16652 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16654 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16656 * win32-low.c (debug_registers_changed,
16657 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16658 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16659 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16660 (thread_rec): Get context using the low target.
16661 (child_add_thread): Call thread_added on the low target,
16662 which does the same thing.
16664 (do_initial_child_stuff): Remove debug registers references.
16665 Set context using the low target. Resume threads after
16666 setting the contexts.
16667 (child_continue): Remove dead variable. Remove debug
16668 registers references.
16669 (child_fetch_inferior_registers): Go through the low target.
16670 (do_child_store_inferior_registers): Remove.
16671 (child_store_inferior_registers): Go through the low target.
16672 (win32_resume): Remove debug registers references.
16673 Set context using the low target.
16674 (handle_exception): Change return type to void. Don't record
16675 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16676 first chance exception.
16677 (get_child_debug_event): Change return type to void. Remove
16678 goto loop. Always return after waiting for debug event.
16679 (win32_wait): Convert to switch statement. Handle spurious
16682 * win32-i386-low.c (debug_registers_changed,
16683 debug_registers_used): New.
16684 (initial_stuff): Rename to ...
16685 (i386_initial_stuff): ... this. Clear debug registers
16687 (store_debug_registers): Delete.
16688 (i386_get_thread_context): New.
16689 (load_debug_registers): Delete.
16690 (i386_set_thread_context): New.
16691 (i386_thread_added): New.
16692 (single_step): Rename to ...
16693 (i386_single_step): ... this.
16694 (do_fetch_inferior_registers): Rename to ...
16695 (i386_fetch_inferior_register): ... this.
16696 (i386_store_inferior_register): New.
16697 (the_low_target): Adapt to new interface.
16699 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16700 (arm_get_thread_context): New.
16701 (arm_set_thread_context): New.
16703 (do_fetch_inferior_registers): Rename to ...
16704 (arm_fetch_inferior_register): ... this.
16705 (arm_store_inferior_register): New.
16706 (arm_wince_breakpoint): Reimplement as unsigned long.
16707 (arm_wince_breakpoint_len): Define.
16708 (the_low_target): Adapt to new interface.
16710 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16711 load_debug_registers. Add get_thread_context, set_thread_context,
16712 thread_added and store_inferior_register. Rename
16713 fetch_inferior_registers to fetch_inferior_register.
16714 (regptr): Remove declaration.
16716 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16718 * linux-low.c (linux_detach): Change return type to int. Return 0.
16719 * spu-low.c (spu_detach): Likewise.
16721 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16723 * target.h (target_ops): Change return type of detach to int.
16725 (join_inferior): New.
16726 * server.c (main): Don't skip detach support on mingw32.
16727 If the inferior doesn't support detaching return error.
16728 Call join_inferior instead of using waitpid.
16729 * linux-low.c (linux_join): New.
16730 (linux_target_op): Add linux_join.
16731 * spu-low.c (spu_join): New.
16732 (spu_target_ops): Add spu_join.
16733 * win32-low.c (win32_detach): Adapt to new interface.
16734 Reopen current_process_handle before detaching. Issue a child
16735 resume before detaching.
16737 (win32_target_op): Add win32_join.
16739 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16741 * win32-low.c (win32-attach): Fix return value.
16742 * target.h (target_ops): Describe ATTACH return values.
16744 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16746 * win32-low.c (GETPROCADDRESS): Define.
16747 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16748 (winapi_DebugSetProcessKillOnExit): Likewise.
16749 (win32_create_inferior): Force usage of ansi CreateProcessA.
16750 (win32_attach): Use GETPROCADDRESS.
16751 (win32_detach): Likewise.
16753 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16755 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16757 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16759 * win32-low.c: Commit leftover changes from 2007-03-29.
16761 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16763 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16764 fields short instead of int. Add explicit padding.
16765 (i387_cache_to_fsave): Remove unnecessary casts.
16766 (i387_fsave_to_cache): Doc fix.
16767 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16769 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16771 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16772 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16774 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16776 * configure.srv (arm*-*-mingw32ce*): Move near the other
16779 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16781 * configure.ac: Add errno checking.
16782 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16783 sys/file.h and malloc.h.
16784 (AC_CHECK_DECLS): Add perror.
16785 (srv_mingwce): Handle.
16786 * configure.srv (i[34567]86-*-cygwin*): Add
16787 win32-i386-low.o to srv_tgtobj.
16788 (i[34567]86-*-mingw*): Likewise.
16789 (arm*-*-mingw32ce*): Add case.
16790 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16791 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16792 [__MINGW32CE__] (strerror): New function.
16793 [__MINGW32CE__] (errno): Define to GetLastError.
16794 [__MINGW32CE__] (COUNTOF): New macro.
16795 (remote_open): Remove extra close call.
16796 * mem-break.c (delete_breakpoint_at): New function.
16797 * mem-break.h (delete_breakpoint_at): Declare.
16798 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16799 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16800 [USE_WIN32API] (read, write): Add char* casts.
16801 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16802 * server.h: Include wincecompat.h on Windows CE.
16803 [HAVE_ERRNO_H]: Check.
16804 (perror): Declare if not declared.
16805 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16806 (perror_with_name): Remove errno declaration.
16807 * wincecompat.h: New.
16808 * wincecompat.c: New.
16809 * win32-low.h: New.
16810 * win32-arm-low.c: New.
16811 * win32-i386-low.c: New.
16812 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16813 (OUTMSG2): Make it safe.
16815 (COUNTOF): New macro.
16816 (NUM_REGS): Get it from the low target.
16817 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16818 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16819 (thread_rec): Let low target handle debug registers.
16820 (child_add_thread): Likewise.
16821 (child_init_thread_list): Likewise.
16822 (continue_one_thread): Likewise.
16824 (do_child_fetch_inferior_registers): Move to ...
16825 * win32-i386-low.c: ... here, and rename to ...
16826 (do_fetch_inferior_registers): ... this.
16827 * win32-low.c (child_fetch_inferior_registers):
16828 Go through the low target.
16829 (do_child_store_inferior_registers): Use regptr.
16830 (strwinerror): New function.
16831 (win32_create_inferior): Handle Windows CE.
16832 Use strwinerror instead of strerror on Windows error
16833 codes. Add program to the error output.
16834 Don't close the main thread handle on Windows CE.
16835 (win32_attach): Use coredll.dll on Windows CE.
16836 (win32_kill): Close current process and current
16838 (win32_detach): Use coredll.dll on Windows CE.
16839 (win32_resume): Let low target handle debug registers, and
16841 (handle_exception): Add/Remove initial breakpoint. Avoid
16842 non-existant WSTOPSIG on Windows CE.
16843 (win32_read_inferior_memory): Cast to remove warning.
16844 (win32_arch_string): Go through the low target.
16845 (initialize_low): Call set_breakpoint_data with the low
16846 target's breakpoint.
16847 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16848 FOP_REGNUM, mappings): Move to ...
16849 * win32-i386-low.c: ... here.
16850 * win32-low.c (win32_thread_info): Move to ...
16851 * win32-low.h: ... here.
16852 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16853 win32-arm-low.c and wincecompat.c.
16854 (all:): Add $EXEEXT.
16855 (install-only:): Likewise.
16856 (gdbserver:): Likewise.
16857 (gdbreplay:): Likewise.
16858 * config.in: Regenerate.
16859 * configure: Regenerate.
16861 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16863 * win32-low.c: Rename typedef thread_info to
16864 win32_thread_info throughout.
16866 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16868 * win32-i386-low.c: Rename to ...
16869 * win32-low.c: ... this.
16870 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16871 * Makefile.in: Likewise.
16873 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16875 * remote-utils.c (monitor_output): Constify msg parameter.
16876 * server.h (monitor_output): Likewise.
16877 * win32-i386-low.c (handle_output_debug_string): New.
16878 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16879 handle_output_debug_string.
16880 (get_child_debug_event): Likewise.
16882 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16884 * server.c (main): Correct strtoul check.
16886 2007-03-27 Jon Ringle <jon@ringle.org>
16888 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16890 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16892 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16894 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16896 * terminal.h: Check HAVE_SGTTY_H.
16898 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16900 * remote-utils.c (remote_open): Print out the assigned port number.
16902 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16904 * remote-utils.c (monitor_output): New function.
16905 * server.c (debug_threads): Define here.
16906 (monitor_show_help): New function.
16907 (handle_query): Handle qRcmd.
16908 (main): Do not handle 'd' packet.
16909 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16910 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16913 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16915 * Makefile.in (EXEEXT): New.
16916 (clean): Use $(EXEEXT).
16918 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16920 * target.h (target_ops): Rename send_signal to request_interrupt,
16921 and remove enum target_signal parameter.
16922 * linux-low.c (linux_request_interrupt): Rename from
16923 linux_send_signal, and always send SIGINT.
16924 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16925 and always send SIGINT.
16926 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16928 (input_interrupt): Likewise.
16930 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16932 * server.c (get_features_xml): Check if target implemented
16934 * win32-i386-low.c (win32_arch_string): New.
16935 (win32_target_ops): Add win32_arch_string as arch_string member.
16937 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16939 * spu-low.c (spu_arch_string): New.
16940 (spu_target_ops): Add spu_arch_string.
16942 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16944 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16945 * configure.ac: Do not check for terminal.h.
16946 * configure, config.in: Regenerated.
16948 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16950 * Makefile.in (OBS): Add $(XML_BUILTIN).
16951 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16953 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16954 (arm-with-iwmmxt.c): New.
16955 * config.in, configure: Regenerate.
16956 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16957 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16958 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16959 (arm*-*-linux*): Add iWMMXt and regset support.
16960 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16961 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16962 (arm_store_wmmxregset, target_regsets): New.
16963 * server.c (get_features_xml): Take annex argument. Check builtin
16965 (handle_query): Handle multiple annexes.
16967 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16969 * remote-utils.c [USE_WIN32API] (read, write): Define.
16970 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16973 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16975 * linux-i386-low.c (the_low_target): Set arch_string.
16976 * linux-x86-64-low.c (the_low_target): Likewise.
16977 * linux-low.c (linux_arch_string): New.
16978 (linux_target_ops): Add it.
16979 * linux-low.h (struct linux_target_ops): Add arch_string.
16980 * server.c (write_qxfer_response): Use const void * for DATA.
16981 (get_features_xml): New.
16982 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16983 * target.h (struct target_ops): Add arch_string method.
16985 2007-01-03 Denis Pilat <denis.pilat@st.com>
16986 Daniel Jacobowitz <dan@codesourcery.com>
16988 * linux-low.c (linux_kill): Handle being called with no threads.
16989 * win32-i386-low.c (win32_kill): Likewise.
16990 (get_child_debug_event): Clear current_process_handle.
16992 2006-12-30 Denis PILAT <denis.pilat@st.com>
16993 Daniel Jacobowitz <dan@codesourcery.com>
16995 * remote-utils.c (remote_open): Check the type of specified
16996 serial port devices before opening them.
16997 * server.c (main): Kill the inferior if an error occurs during
16998 the first remote_open.
17000 2006-12-05 Markus Deuling <deuling@de.ibm.com>
17002 * README: Update supported targets.
17004 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
17006 * Makefile.in (clean): Remove reg-mips64.c.
17007 (reg-mips64.c, reg-mips64.o): New rules.
17008 * configure.srv: Handle mips64. Include regset support for mips.
17009 * linux-mips-low.c (union mips_register): New.
17010 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
17011 (mips_breakpoint, mips_breakpoint_at): Use int.
17012 (mips_collect_register, mips_supply_register)
17013 (mips_collect_register_32bit, mips_supply_register_32bit)
17014 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
17015 (mips_store_fpregset, target_regsets): New.
17016 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
17018 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
17020 * configure.srv: Add target "spu*-*-*".
17021 * Makefile.in (clean): Remove reg-spu.c.
17022 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
17023 * spu-low.c: New file.
17025 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
17027 * configure.ac: Correct td_thr_tls_get_addr test.
17028 * configure: Regenerated.
17030 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
17032 * linux-low.c (linux_wait_for_event): Reformat. Use the
17033 pass_signals array.
17034 * remote-utils.c (decode_address_to_semicolon): New.
17035 * server.c (pass_signals, handle_general_set): New.
17036 (handle_query): Mention QPassSignals for qSupported.
17037 (main): Call handle_general_set.
17038 * server.h (pass_signals, decode_address_to_semicolon): New.
17040 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
17042 * server.c (handle_query): Correct error handling for read_auxv.
17044 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
17046 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
17047 and srv_linux_thread_db to yes.
17048 * linux-s390-low.c (s390_fill_gregset): New function.
17049 (target_regsets): Define data structure.
17051 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
17053 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
17054 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
17055 * config.in, configure: Regenerated.
17056 * inferiors.c (gdb_id_to_thread): New function.
17057 (gdb_id_to_thread_id): Use it.
17058 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
17059 * linux-low.h (struct process_info): Add th member.
17060 (thread_db_get_tls_address): New prototype.
17061 * remote-utils.c (decode_address): Make non-static.
17062 * server.c (handle_query): Handle qGetTLSAddr.
17063 * server.h (gdb_id_to_thread, decode_address): New prototypes.
17064 * target.h (struct target_ops): Add get_tls_address.
17065 * thread-db.c (maybe_attach_thread): Save the thread handle.
17066 (thread_db_get_tls_address): New.
17068 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
17070 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
17071 (linux_resume_one_process): Take a siginfo_t *. Update all
17072 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
17073 (struct pending_signals): Add a siginfo_t.
17074 (linux_wait_for_process): Always set last_status.
17075 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
17076 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
17077 * linux-low.h (struct process_info): Add last_status.
17079 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
17081 * remote-utils.c (try_rle): New function.
17082 (putpkt_binary): Use it.
17084 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
17086 * Makefile.in (clean): Clean reg-x86-64-linux.c.
17087 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
17088 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
17089 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
17090 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
17093 2006-08-08 Richard Sandiford <richard@codesourcery.com>
17095 * server.c (terminal_fd): New variable.
17096 (old_foreground_pgrp): Likewise.
17097 (restore_old_foreground_pgrp): New function.
17098 (start_inferior): Record the terminal file descriptor in terminal_fd
17099 and its original foreground group in old_foreground_pgrp. Register
17100 restore_old_foreground_pgrp with atexit().
17102 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
17104 * server.c (handle_query): Correct qPart to qXfer.
17106 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
17108 * configure.ac: Check for more headers which are missing on
17109 Windows. Automatically supply -lwsock32 and USE_WIN32API.
17110 * configure.srv: Add Cygwin and mingw32.
17111 * remote-utils.c: Don't include headers unconditionally which
17112 are missing on mingw32. Include <winsock.h> for mingw32.
17113 (remote_open): Adjust for mingw32 support. Flush
17114 standard error after writing to it.
17115 (remote_close, putpkt_binary, input_interrupt, block_async_io)
17116 (unblock_async_io, enable_async_io, disable_async_io)
17117 (readchar, getpkt): Update for Winsock support.
17118 (prepare_resume_reply): Expect a protocol signal number.
17119 * server.c: Disable <sys/wait.h> on mingw32.
17120 (start_inferior): Adjust for mingw32 support. Flush
17121 standard error after writing to it.
17122 (attach_inferior): Likewise. Use protocol signal
17124 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
17126 * win32-i386-low.c: New file.
17127 * Makefile.in (XM_CLIBS): Set.
17128 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
17129 (win32-i386-low.o): New dependency rule.
17130 * linux-low.c (linux_wait): Use target signal numbers.
17131 * target.h (struct target_ops): Doc fix.
17132 * server.h (target_signal_to_name): New prototype.
17133 * gdbreplay.c: Don't include headers unconditionally which
17134 are missing on mingw32. Include <winsock.h> for mingw32.
17135 (remote_close, remote_open): Adjust for Winsock support.
17136 * configure, config.in: Regenerated.
17138 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
17140 * server.c (decode_xfer_read, write_qxfer_response): New.
17141 (handle_query): Take a packet length argument. Handle
17142 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
17143 the qSupported response.
17144 (main): Update call to handle_query.
17146 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
17148 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
17149 (putpkt_binary): Renamed from putpkt and adjusted for binary
17151 (putpkt): New wrapper for putpkt_binary.
17152 (readchar): Don't mask off the high bit.
17153 (decode_X_packet): New function.
17154 * server.c (main): Call putpkt_binary if a handler sets the packet
17155 length. Save the length of the incoming packet. Handle 'X'.
17156 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
17158 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
17160 * server.c (handle_query): Handle qSupported.
17162 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
17164 * remote-utils.c (all_symbols_looked_up): New variable.
17165 (look_up_one_symbol): Check it.
17166 * server.h (look_up_one_symbol): New declaration.
17167 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
17169 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
17171 * Makefile.in (linux-arm-low.o): Update dependencies.
17172 * linux-arm-low.c: Include "gdb_proc_service.h".
17173 (PTRACE_GET_THREAD_AREA): Define.
17174 (ps_get_thread_area): New function.
17176 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
17178 * configure.srv (m68k*-*-uclinux*): New target.
17179 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
17180 (linux_resume_one_process): Remove extraneous cast.
17181 (linux_read_offsets): New.
17182 (linux_target_op): Add linux_read_offsets on mmuless systems.
17183 * server.c (handle_query): Add qOffsets logic.
17184 * target.h (struct target_ops): Add read_offsets.
17186 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
17188 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
17189 (PTRACE_GET_THREAD_AREA): Define.
17190 (ps_get_thread_area): New function.
17191 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
17192 (linux-x86-64-low.o): Update.
17194 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
17196 * configure.ac: Remove checks for prfpregset_t.
17197 * gdb_proc_service.h: New file.
17198 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
17199 new "gdb_proc_service.h".
17200 * proc-service.c: Likewise.
17201 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
17202 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
17203 * Makefile.in (gdb_proc_service_h): Updated.
17204 * configure, config.in: Regenerated.
17206 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17208 * remote-utils.c (prepare_resume_reply): Move declaration
17209 of gdb_id_from_wait to the top of the block.
17211 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
17213 * linux-low.c (regsets_store_inferior_registers): Read the regset
17214 from the target before filling it.
17216 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
17218 * server.c (attach_inferior): Return SIGTRAP for a successful
17221 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
17223 * Makefile.in (OBS): Add version.o.
17224 (STAGESTUFF): Delete.
17225 (version.o): Add dependencies.
17226 (version.c): Replace rule.
17227 (clean): Remove version.c.
17228 * server.c (gdbserver_version): New.
17229 (gdbserver_usage): Use printf.
17230 (main): Handle --version and --help.
17231 * server.h (version, host_name): Add declarations.
17233 2005-12-23 Eli Zaretskii <eliz@gnu.org>
17245 * linux-x86-64-low.c:
17247 * linux-s390-low.c:
17248 * linux-ppc64-low.c:
17250 * linux-mips-low.c:
17251 * linux-m68k-low.c:
17252 * linux-m32r-low.c:
17255 * linux-ia64-low.c:
17256 * linux-i386-low.c:
17257 * linux-crisv32-low.c:
17269 * gdbserver.1: Add (C) after Copyright. Update the FSF
17272 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
17274 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
17275 (arm_breakpoint_at): Recognize both breakpoints.
17276 (the_low_target): Use the correct breakpoint instruction.
17278 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
17280 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
17281 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
17282 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
17283 (the_low_target): Update.
17285 2005-10-25 Andreas Schwab <schwab@suse.de>
17287 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
17289 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
17290 (ia64_num_regs): Reduce to 462.
17292 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
17294 * acinclude.m4: Correct quoting.
17295 * aclocal.m4: Regenerated.
17297 Suggested by SZOKOVACS Robert <szo@ies.hu>:
17298 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
17299 (thread_db_init): Call thread_db_err_str.
17300 * configure.ac: Check for TD_VERSION.
17301 * config.in, configure: Regenerated.
17303 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
17305 * server.h (error, fatal, warning): Add ATTR_FORMAT.
17307 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
17309 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
17310 is not available. Define HAVE_PTRACE_GETREGS if it is.
17311 * config.in, configure: Regenerated.
17312 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
17313 * linux-i386-low.c, linux-m68k-low.c: Update to use
17314 HAVE_PTRACE_GETREGS.
17315 * linux-low.c (regsets_fetch_inferior_registers)
17316 (regsets_store_inferior_registers): Only return 0 if we processed
17318 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
17319 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
17321 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
17323 * inferiors.c (struct thread_info): Add gdb_id.
17324 (add_thread): Add gdb_id argument.
17325 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
17326 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
17327 calls to add_thread.
17328 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
17329 * server.c (handle_query): Use thread_to_gdb_id.
17330 (handle_v_cont, main): Use gdb_id_to_thread_id.
17331 * server.h (add_thread): Update prototype.
17332 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
17335 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
17337 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
17338 left-padded registers.
17339 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
17340 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
17342 2005-07-01 Steve Ellcey <sje@cup.hp.com>
17344 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
17345 * configure: Regenerate.
17346 * config.in: Regenerate.
17347 * server.h (NEED_DECLARATION_STRERROR):
17348 Replace with !HAVE_DECL_STRERROR.
17350 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
17352 * linux-low.c (linux_wait, linux_send_signal): Don't test
17353 an unsigned long variable for > 0 if it could be MAX_ULONG.
17354 * server.c (myresume): Likewise.
17355 * target.c (set_desired_inferior): Likewise.
17357 2005-06-13 Mark Kettenis <kettenis@gnu.org>
17359 * configure.ac: Simplify and improve check for socklen_t.
17360 * configure, config.in: Regenerate.
17362 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
17364 * acconfig.h: Remove.
17365 * configure.ac: Add a test for socklen_t. Use three-argument
17366 AC_DEFINE throughout.
17367 * config.in: Regenerated using autoheader 2.59.
17368 * configure: Regenerated.
17370 * gdbreplay.c (socklen_t): Provide a default.
17371 (remote_open): Use socklen_t.
17372 * remote-utils.c (socklen_t): Provide a default.
17373 (remote_open): Use socklen_t.
17374 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
17377 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
17379 * linux-low.c (linux_read_memory, linux_write_memory)
17380 (linux_read_auxv): Likewise.
17381 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
17382 (check_mem_write): Likewise.
17383 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
17385 * regcache.c (struct inferior_rgcache_data, registers_to_string)
17386 (registers_from_string, register_data): Likewise.
17387 * server.c (handle_query, main): Likewise.
17388 * server.h (convert_ascii_to_int, convert_int_to_ascii)
17389 (decode_M_packet): Likewise.
17390 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
17391 * target.h (struct target_ops): Update read_memory, write_memory,
17393 (read_inferior_memory, write_inferior_memory): Update.
17394 * linux-low.h (struct linux_target_ops): Change type of breakpoint
17395 to unsigned char *.
17396 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
17397 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
17398 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
17399 linux-s390-low.c, linux-sh-low.c: Update for changes in
17400 read_inferior_memory and the_low_target->breakpoint.
17402 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
17404 * Makefile.in (SFILES): Add linux-ppc64-low.c.
17405 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
17406 * configure.srv: Add powerpc64-*-linux*.
17407 * linux-ppc64-low.c: New file.
17409 2005-05-23 Orjan Friberg <orjanf@axis.com>
17411 * linux-cris-low.c: New file with support for CRIS.
17412 * linux-crisv32-low.c: Ditto for CRISv32.
17413 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
17414 (clean): Add reg-cris.c and reg-crisv32.c.
17415 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
17416 reg-crisv32.o, and reg-crisv32.c to make rules.
17417 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
17418 recognized targets.
17420 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
17422 * linux-low.c (fetch_register): Ensure buffer size is a multiple
17423 of sizeof (PTRACE_XFER_TYPE).
17424 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
17426 2005-05-12 Orjan Friberg <orjanf@axis.com>
17428 * target.h (struct target_ops): Add insert_watchpoint,
17429 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
17430 pointers for hardware watchpoint support.
17431 * linux-low.h (struct linux_target_ops): Ditto.
17432 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
17433 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
17434 to linux_target_ops.
17435 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
17437 * server.c (main): Recognize 'Z' and 'z' packets.
17439 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
17441 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
17442 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
17443 (the_low_target): Add new members.
17445 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
17447 * proc-service.c (ps_lgetregs): Search all_processes instead of
17450 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
17452 * server.c (start_inferior): Change return type to int.
17453 (attach_inferior): Change sigptr to int *.
17454 (handle_v_cont, handle_v_requests): Change signal to int *.
17455 (main): Change signal to int.
17457 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
17459 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
17460 * configure.srv: Add m32r*-*-linux*.
17461 * linux-m32r-low.c: New file.
17463 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
17465 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
17467 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17469 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
17470 Take unsigned long arguments for PIDs.
17471 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
17472 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
17473 (wait_for_sigstop, linux_resume_one_process)
17474 (regsets_fetch_inferior_registers, linux_send_signal)
17475 (linux_read_auxv): Likewise. Update the types of variables holding
17476 PIDs. Update format string specifiers.
17477 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
17478 * remote-utils.c (prepare_resume_reply): Likewise.
17479 * server.c (cont_thread, general_thread, step_thread)
17480 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
17482 (handle_query): Update format specifiers.
17483 (handle_v_cont, main): Use strtoul for thread IDs.
17484 * server.h (struct inferior_list_entry): Use unsigned long for ID.
17485 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
17486 (general_thread, step_thread, thread_from_wait)
17487 (old_thread_from_wait): Update.
17488 * target.h (struct thread_resume): Use unsigned long for THREAD.
17489 (struct target_ops): Use unsigned long for arguments to attach and
17492 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
17494 * acinclude.m4: Include bfd/bfd.m4 directly.
17495 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
17496 <agriffis@toolchain.org>.
17497 * aclocal.m4, configure: Regenerated.
17499 2005-01-07 Andrew Cagney <cagney@gnu.org>
17501 * configure.ac: Rename configure.in, require autoconf 2.59.
17502 * configure: Re-generate.
17504 2004-12-08 Daniel Jacobowitz <dan@debian.org>
17506 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
17507 LIBS when finished.
17508 * aclocal.m4: Regenerated.
17509 * configure: Regenerated.
17511 2004-11-21 Andreas Schwab <schwab@suse.de>
17513 * linux-m68k-low.c (m68k_num_gregs): Define.
17514 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
17515 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
17516 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
17517 (m68k_breakpoint_at): New. Add to the_low_target.
17519 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
17520 srv_linux_thread_db to yes.
17522 2004-10-20 Joel Brobecker <brobecker@gnat.com>
17524 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
17525 (ARCH_SET_FS): Likewise.
17526 (ARCH_GET_FS): Likewise.
17527 (ARCH_GET_GS): Likewise.
17529 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17531 * linux-i386-low.c (ps_get_thread_area): New.
17532 * linux-x86-64-low.c (ps_get_thread_area): New.
17533 * linux-low.c: Include <sys/syscall.h>.
17534 (linux_kill_one_process): Don't kill the first thread here.
17535 (linux_kill): Kill the first thread here.
17536 (kill_lwp): New function.
17537 (send_sigstop, linux_send_signal): Use it.
17538 * proc-service.c: Clean up #ifdefs.
17539 (fpregset_info): Delete.
17540 (ps_lgetregs): Update and enable implementation.
17541 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
17543 * remote-utils.c (struct sym_cache, symbol_cache): New.
17544 (input_interrupt): Print a clearer message.
17545 (async_io_enabled): New variable.
17546 (enable_async_io, disable_async_io): Use it. Update comments.
17547 (look_up_one_symbol): Use the symbol cache.
17548 * thread-db.c (thread_db_look_up_symbols): New function.
17549 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
17551 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17553 * configure.in: Test for -rdynamic.
17554 * configure: Regenerated.
17555 * Makefile (INTERNAL_LDFLAGS): New.
17556 (gdbserver, gdbreplay): Use it.
17558 2004-09-02 Andrew Cagney <cagney@gnu.org>
17560 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
17562 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
17564 * linux-low.c (linux_wait): Clear all_processes list also.
17566 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17568 * linux-low.c: Include <errno.h>. Remove extern declaration of
17571 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17573 * gdbreplay.c, server.h, utils.c: Update copyright years.
17575 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17577 * server.c (main): Print child status or termination signal from
17578 variable 'signal', not 'sig'.
17580 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17582 * linux-low.c (linux_read_memory): Change return type to
17583 int. Check for and return error from ptrace().
17584 * target.c (read_inferior_memory): Change return type to int. Pass
17585 back return status from the_target->read_memory().
17586 * target.h (struct target_ops): Adapt *read_memory() prototype.
17588 (read_inferior_memory): Adapt prototype.
17589 * server.c (main): Return an error packet if
17590 read_inferior_memory() returns an error.
17592 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
17594 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17595 Unify with other clean targets.
17597 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17599 * server.c (handle_v_cont): Call set_desired_inferior.
17601 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17603 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17605 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17607 * linux-low.c (linux_wait): Unblock async I/O.
17608 (linux_resume): Block and enable async I/O.
17609 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17610 * server.h (block_async_io, unblock_async_io): Add prototypes.
17612 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17614 * remote-utils.c (remote_open): Print a status notice after
17615 opening a TCP port.
17616 * server.c (attach_inferior): Print a status notice after
17619 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17621 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17623 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
17625 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17627 * server.c, target.h: Update copyright years.
17629 2004-02-25 Roland McGrath <roland@redhat.com>
17631 * target.h (struct target_ops): New member `read_auxv'.
17632 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17633 * linux-low.c (linux_read_auxv): New function.
17634 (linux_target_ops): Initialize `read_auxv' member to that.
17636 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17638 Committed by Jim Blandy <jimb@redhat.com>.
17640 * linux-s390-low.c (s390_num_regs): Update.
17641 (s390_regmap): Remove control registers. Use __s390x__ predefine
17642 instead of GPR_SIZE to distiguish s390 and s390x targets.
17644 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
17646 * linux-low.c: Update copyright year.
17647 (check_removed_breakpoint): Clear pending_is_breakpoint.
17648 (linux_set_resume_request, linux_queue_one_thread)
17649 (resume_status_pending_p): New functions.
17650 (linux_continue_one_thread): Use process->resume.
17651 (linux_resume): Only resume threads if there are no pending events.
17652 * linux-low.h (struct process_info): Add resume request
17655 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
17657 * regcache.c (new_register_cache): Clear the allocated register
17658 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17660 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
17662 * linux-low.c (linux_resume): Take a struct thread_resume *
17664 (linux_wait): Update call.
17665 (resume_ptr): New static variable.
17666 (linux_continue_one_thread): Renamed from
17667 linux_continue_one_process. Use resume_ptr.
17668 (linux_resume): Use linux_continue_one_thread.
17669 * server.c (handle_v_cont, handle_v_requests): New functions.
17670 (myresume): New function.
17671 (main): Handle 'v' case.
17672 * target.h (struct thread_resume): New type.
17673 (struct target_ops): Change argument of "resume" to struct
17675 (myresume): Delete macro.
17677 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17679 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17680 (uninstall): Support DESTDIR.
17682 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17684 * configure.srv: Add xscale*linux copy of arm*linux entry.
17686 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
17688 * linux-arm-low.c (arm_reinsert_addr): New function.
17689 (the_low_target): Add arm_reinsert_addr.
17691 2003-07-08 Mark Kettenis <kettenis@gnu.org>
17693 * mem-break.c: Remove whitespace at end of file.
17695 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17697 * configure.in: Check whether we need to prototype strerror.
17698 * server.h: Optionally prototype strerror.
17699 * gdbreplay.c (perror_with_name): Use strerror.
17700 * linux-low.c (linux_attach_lwp): Use strerror.
17701 * utils.c (perror_with_name): Use strerror.
17702 * config.in, configure: Regenerated.
17704 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17706 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17707 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17709 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
17711 * Makefile.in (SFILES): Update.
17712 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17713 low-sun3.c: Remove files.
17715 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
17717 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17718 (linux_detach_one_process, linux_detach): New functions.
17719 (linux_target_ops): Add linux_detach.
17720 * server.c (main): Handle 'D' packet.
17721 * target.h (struct target_ops): Add "detach" member.
17722 (detach_inferior): Define.
17724 2003-06-13 Mark Kettenis <kettenis@gnu.org>
17726 From Kelley Cook <kelleycook@wideopenwest.com>:
17727 * configure.srv: Accept i[34567]86 variants.
17729 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
17731 * linux-low.c (linux_wait_for_event): Correct comment typos.
17732 (linux_resume_one_process): Call check_removed_breakpoint.
17733 (linux_send_signal): New function.
17734 (linux_target_ops): Add linux_send_signal.
17735 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17737 * target.h (struct target_ops): Add send_signal.
17739 2003-05-29 Jim Blandy <jimb@redhat.com>
17741 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17742 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17743 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17744 away part of the register's value.
17746 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
17748 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17749 (linux_wait_for_event, linux_init_signals): Likewise.
17751 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
17753 * configure.in: Check for stdlib.h.
17754 * configure: Regenerated.
17755 * config.in: Regenerated.
17757 2003-01-04 Andreas Schwab <schwab@suse.de>
17759 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17761 2003-01-02 Andrew Cagney <ac131313@redhat.com>
17763 * Makefile.in: Remove obsolete code.
17765 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
17767 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17768 defined(PT_FPR0_HI).
17770 2002-11-17 Stuart Hughes <seh@zee2.com>
17772 * linux-arm-low.c (arm_num_regs): Increase.
17773 (arm_regmap): Include status register.
17775 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
17777 * linux-low.c (register_addr): Remove incorrect -1 check.
17779 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
17781 * linux-low.c (linux_create_inferior): Call setpgid. Return
17783 (unstopped_p, linux_signal_pid): Remove.
17784 (linux_target_ops): Remove linux_signal_pid.
17785 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17786 global instead of target method.
17787 * target.h (struct target_ops): Remove signal_pid. Update comment
17788 for create_inferior.
17789 * server.c (signal_pid): New variable.
17790 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
17791 gdbserver. Set the child to be the foreground process group.
17792 (attach_inferior): Set signal_pid.
17794 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
17796 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17798 2002-08-20 Jim Blandy <jimb@redhat.com>
17800 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17803 2002-08-01 Andrew Cagney <cagney@redhat.com>
17805 * Makefile.in: Make chill references obsolete.
17807 2002-07-24 Kevin Buettner <kevinb@redhat.com>
17809 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17810 * configure: Regenerate.
17811 * config.in: Regenerate.
17813 2002-07-09 David O'Brien <obrien@FreeBSD.org>
17815 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17816 (perror_with_name, remote_close, remote_open, expect, play): Static.
17818 2002-07-04 Michal Ludvig <mludvig@suse.cz>
17820 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17821 byte offsets instead of an array of indexes.
17822 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17824 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
17826 * regcache.c: Add comment.
17828 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
17830 * thread-db.c: New file.
17831 * proc-service.c: New file.
17832 * acinclude.m4: New file.
17833 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17834 proc-service.o, and thread-db.o.
17835 (linux-low.o): Add USE_THREAD_DB.
17836 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17837 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17838 * aclocal.m4: Regenerated.
17839 * config.in: Regenerated.
17840 * configure: Regenerated.
17841 * configure.in: Check for proc_service.h, sys/procfs.h,
17842 thread_db.h, and linux/elf.h headrs.
17843 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17844 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17845 Check for -lthread_db and thread support.
17846 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17847 PowerPC, and SuperH.
17848 * i387-fp.c: Constify arguments.
17849 * i387-fp.h: Likewise.
17850 * inferiors.c: (struct thread_info): Renamed from
17851 `struct inferior_info'. Remove PID member. Use generic inferior
17852 list header. All uses updated.
17853 (inferiors, signal_pid): Removed.
17854 (all_threads): New variable.
17855 (get_thread): Define.
17856 (add_inferior_to_list): New function.
17857 (for_each_inferior): New function.
17858 (change_inferior_id): New function.
17859 (add_inferior): Removed.
17860 (remove_inferior): New function.
17861 (add_thread): New function.
17862 (free_one_thread): New function.
17863 (remove_thread): New function.
17864 (clear_inferiors): Use for_each_inferior and free_one_thread.
17865 (find_inferior): New function.
17866 (find_inferior_id): New function.
17867 (inferior_target_data): Update argument type.
17868 (set_inferior_target_data): Likewise.
17869 (inferior_regcache_data): Likewise.
17870 (set_inferior_regcache_data): Likewise.
17871 * linux-low.c (linux_bp_reinsert): Remove.
17872 (all_processes, stopping_threads, using_thrads)
17873 (struct pending_signals, debug_threads, pid_of): New.
17874 (inferior_pid): Replace with macro.
17875 (struct inferior_linux_data): Remove.
17876 (get_stop_pc, add_process): New functions.
17877 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17878 Use add_process and add_thread.
17879 (linux_attach_lwp): New function, based on old linux_attach. Use
17880 add_process and add_thread. Set stop_expected for new threads.
17881 (linux_attach): New function.
17882 (linux_kill_one_process): New function.
17883 (linux_kill): Kill all LWPs.
17884 (linux_thread_alive): Use find_inferior_id.
17885 (check_removed_breakpoints, status_pending_p): New functions.
17886 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17887 Update. Use WNOHANG. Wait for cloned processes also. Update process
17888 struct for the found process.
17889 (linux_wait_for_event): New function.
17890 (linux_wait): Use it. Support LWPs.
17891 (send_sigstop, wait_for_sigstop, stop_all_processes)
17892 (linux_resume_one_process, linux_continue_one_process): New functions.
17893 (linux_resume): Support LWPs.
17894 (REGISTER_RAW_SIZE): Remove.
17895 (fetch_register): Use register_size instead. Call supply_register.
17896 (usr_store_inferior_registers): Likewise. Call collect_register.
17897 Fix recursive case.
17898 (regsets_fetch_inferior_registers): Improve error message.
17899 (regsets_store_inferior_registers): Add debugging.
17900 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17901 (unstopped_p, linux_signal_pid): New functions.
17902 (linux_target_ops): Add linux_signal_pid.
17903 (linux_init_signals): New function.
17904 (initialize_low): Call it. Initialize using_threads.
17905 * regcache.c (inferior_regcache_data): Add valid
17907 (get_regcache): Fetch registers lazily. Add fetch argument
17908 and update all callers.
17909 (regcache_invalidate_one, regcache_invalidate): New
17911 (new_register_cache): Renamed from create_register_cache.
17912 Return the new regcache.
17913 (free_register_cache): Change argument to a void *.
17914 (registers_to_string, registers_from_string): Call get_regcache
17915 with fetch flag set.
17916 (register_data): Make static. Pass fetch flag to get_regcache.
17917 (supply_register): Call get_regcache with fetch flag clear.
17918 (collect_register): Call get_regcache with fetch flag set.
17919 (collect_register_as_string): New function.
17920 * regcache.h: Update.
17921 * remote-utils.c (putpkt): Flush after debug output and use
17923 Handle input interrupts while waiting for an ACK.
17924 (input_interrupt): Use signal_pid method.
17925 (getpkt): Flush after debug output and use stderr.
17926 (outreg): Use collect_register_as_string.
17927 (new_thread_notify, dead_thread_notify): New functions.
17928 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17929 and general_thread.
17930 (look_up_one_symbol): Flush after debug output.
17931 * server.c (step_thread, server_waiting): New variables.
17932 (start_inferior): Don't use signal_pid. Update call to mywait.
17933 (attach_inferior): Update call to mywait.
17934 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17935 (main): Don't fetch/store registers explicitly. Use
17936 set_desired_inferior. Support proposed ``Hs'' packet. Update
17938 * server.h: Update.
17939 (struct inferior_list, struct_inferior_list_entry): New.
17940 * target.c (set_desired_inferior): New.
17941 (write_inferior_memory): Constify.
17942 (mywait): New function.
17943 * target.h: Update.
17944 (struct target_ops): New signal_pid method.
17945 (mywait): Removed macro, added prototype.
17947 * linux-low.h (regset_func): Removed.
17948 (regset_fill_func, regset_store_func): New.
17949 (enum regset_type): New.
17950 (struct regset_info): Add type field. Use new operation types.
17951 (struct linux_target_ops): stop_pc renamed to get_pc.
17952 Add decr_pc_after_break and breakpoint_at.
17953 (get_process, get_thread_proess, get_process_thread)
17954 (strut process_info, all_processes, linux_attach_lwp)
17955 (thread_db_init): New.
17957 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17958 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17959 (the_low_target): Add new members.
17960 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17961 (i386_store_fpxregset): Constify.
17962 (target_regsets): Add new kind identifier.
17963 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17964 (i386_set_pc): Add debugging.
17965 (i386_breakpoint_at): New function.
17966 (the_low_target): Add new members.
17967 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17968 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17969 (mips_breakpoint_at): New.
17970 (the_low_target): Add new members.
17971 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17972 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17973 (the_low_target): Add new members.
17974 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17975 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17976 (the_low_target): Add new members.
17977 * linux-x86-64-low.c (target_regsets): Add new kind
17980 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17982 From Martin Pool <mbp@samba.org>:
17983 * server.c (gdbserver_usage): New function.
17986 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17988 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17989 stop_at -> stop_pc.
17991 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17993 * Makefile.in: Remove obsolete code.
17995 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17997 * linux-low.c (regsets_fetch_inferior_registers),
17998 (regsets_store_inferior_registers): Removed cast to int from
18000 * regcache.h: Added declaration of struct inferior_info.
18002 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
18004 * inferiors.c (struct inferior_info): Add regcache_data.
18005 (add_inferior): Call create_register_cache.
18006 (clear_inferiors): Call free_register_cache.
18007 (inferior_regcache_data, set_inferior_regcache_data): New functions.
18008 * regcache.c (struct inferior_regcache_data): New.
18009 (registers): Remove.
18010 (get_regcache): New function.
18011 (create_register_cache, free_register_cache): New functions.
18012 (set_register_cache): Don't initialize the register cache here.
18013 (registers_to_string, registers_from_string, register_data): Call
18015 * regcache.h: Add prototypes.
18016 * server.h: Likewise.
18018 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
18020 * mem-break.c: New file.
18021 * mem-break.h: New file.
18022 * Makefile.in: Add mem-break.o rule; update server.h
18024 * inferiors.c (struct inferior_info): Add target_data
18026 (clear_inferiors): Free target_data member if set.
18027 (inferior_target_data, set_inferior_target_data): New functions.
18028 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
18029 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
18030 * linux-low.c (linux_bp_reinsert): New variable.
18031 (struct inferior_linux_data): New.
18032 (linux_create_inferior): Use set_inferior_target_data.
18033 (linux_attach): Likewise. Call add_inferior.
18034 (linux_wait_for_one_inferior): New function.
18035 (linux_wait): Call it.
18036 (linux_write_memory): Add const.
18037 (initialize_low): Call set_breakpoint_data.
18038 * linux-low.h (struct linux_target_ops): Add breakpoint
18040 * server.c (attach_inferior): Remove extra add_inferior
18042 * server.h: Include mem-break.h. Update inferior.c
18044 * target.c (read_inferior_memory)
18045 (write_inferior_memory): New functions.
18046 * target.h (read_inferior_memory)
18047 (write_inferior_memory): Change macros to prototypes.
18048 (struct target_ops): Update comments. Add const to write_memory
18051 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
18053 * linux-low.c (usr_store_inferior_registers): Support
18054 registers which are allowed to fail to store.
18055 * linux-low.h (linux_target_ops): Likewise.
18056 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
18057 (ppc_cannot_store_register): FPSCR may not be storable.
18059 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18061 * server.h: Include <string.h> if HAVE_STRING_H.
18062 * ChangeLog: Correct paths in last ChangeLog entry.
18064 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18066 * linux-low.h: Remove obsolete prototypes.
18067 (struct linux_target_ops): New.
18068 (extern the_low_target): New.
18069 * linux-low.c (num_regs, regmap): Remove declarations.
18070 (register_addr): Use the_low_target explicitly.
18071 (fetch_register): Likewise.
18072 (usr_fetch_inferior_registers): Likewise.
18073 (usr_store_inferior_registers): Likewise.
18074 * linux-arm-low.c (num_regs): Remove.
18075 (arm_num_regs): Define.
18076 (arm_regmap): Renamed from regmap, made static.
18077 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
18079 (arm_cannot_store_register): Renamed from cannot_store_register,
18081 (the_low_target): New.
18082 * linux-i386-low.c (num_regs): Remove.
18083 (i386_num_regs): Define.
18084 (i386_regmap): Renamed from regmap, made static.
18085 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
18087 (i386_cannot_store_register): Renamed from cannot_store_register,
18089 (the_low_target): New.
18090 * linux-ia64-low.c (num_regs): Remove.
18091 (ia64_num_regs): Define.
18092 (ia64_regmap): Renamed from regmap, made static.
18093 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
18095 (ia64_cannot_store_register): Renamed from cannot_store_register,
18097 (the_low_target): New.
18098 * linux-m68k-low.c (num_regs): Remove.
18099 (m68k_num_regs): Define.
18100 (m68k_regmap): Renamed from regmap, made static.
18101 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
18103 (m68k_cannot_store_register): Renamed from cannot_store_register,
18105 (the_low_target): New.
18106 * linux-mips-low.c (num_regs): Remove.
18107 (mips_num_regs): Define.
18108 (mips_regmap): Renamed from regmap, made static.
18109 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
18111 (mips_cannot_store_register): Renamed from cannot_store_register,
18113 (the_low_target): New.
18114 * linux-ppc-low.c (num_regs): Remove.
18115 (ppc_num_regs): Define.
18116 (ppc_regmap): Renamed from regmap, made static.
18117 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
18119 (ppc_cannot_store_register): Renamed from cannot_store_register,
18121 (the_low_target): New.
18122 * linux-s390-low.c (num_regs): Remove.
18123 (s390_num_regs): Define.
18124 (s390_regmap): Renamed from regmap, made static.
18125 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
18127 (s390_cannot_store_register): Renamed from cannot_store_register,
18129 (the_low_target): New.
18130 * linux-sh-low.c (num_regs): Remove.
18131 (sh_num_regs): Define.
18132 (sh_regmap): Renamed from regmap, made static.
18133 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
18135 (sh_cannot_store_register): Renamed from cannot_store_register,
18137 (the_low_target): New.
18138 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
18139 (the_low_target): New.
18141 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18143 * Makefile.in: Add stamp-h target.
18144 * configure.in: Create stamp-h.
18145 * configure: Regenerated.
18147 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18149 * inferiors.c: New file.
18150 * target.c: New file.
18151 * target.h: New file.
18152 * Makefile.in: Add target.o and inferiors.o. Update
18154 * linux-low.c (inferior_pid): New static variable,
18155 moved from server.c.
18156 (linux_create_inferior): Renamed from create_inferior.
18157 Call add_inferior. Return 0 on success instead of a PID.
18158 (linux_attach): Renamed from myattach.
18159 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
18160 (linux_thread_alive): Renamed from mythread_alive.
18161 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
18163 (linux_resume): Renamed from myresume. Add missing ``return 0''.
18164 (regsets_store_inferior_registers): Correct error message.
18165 Add missing ``return 0''.
18166 (linux_fetch_registers): Renamed from fetch_inferior_registers.
18167 (linux_store_registers): Renamed from store_inferior_registers.
18168 (linux_read_memory): Renamed from read_inferior_memory.
18169 (linux_write_memory): Renamed from write_inferior_memory.
18170 (linux_target_ops): New structure.
18171 (initialize_low): Call set_target_ops ().
18172 * remote-utils.c (unhexify): New function.
18173 (hexify): New function.
18174 (input_interrupt): Send signals to ``signal_pid''.
18175 * server.c (inferior_pid): Remove.
18176 (start_inferior): Update create_inferior call.
18177 (attach_inferior): Call add_inferior.
18178 (handle_query): New function.
18179 (main): Call handle_query for `q' packets.
18180 * server.h: Include "target.h". Remove obsolete prototypes.
18181 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
18183 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
18185 * Makefile.in: Add WARN_CFLAGS. Update configury
18187 * configure.in: Check for <string.h>
18188 * configure: Regenerate.
18189 * config.in: Regenerate.
18190 * gdbreplay.c: Include needed system headers.
18191 (remote_open): Remove strchr prototype.
18192 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
18193 * regcache.c (supply_register): Change buf argument to const void *.
18194 (supply_register_by_name): Likewise.
18195 (collect_register): Change buf argument to void *.
18196 (collect_register_by_name): Likewise.
18197 * regcache.h: Add missing prototypes.
18198 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
18199 * server.c (handle_query): New function.
18200 (attached): New static variable, moved out of main.
18201 (main): Quiet longjmp clobber warnings.
18202 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
18203 * utils.c (error): Remove NORETURN.