1 2020-01-10 Pedro Alves <palves@redhat.com>
3 * fork-child.c (post_fork_inferior): Pass target down to
5 * inferiors.c (switch_to_thread): Add process_stratum_target
7 * lynx-low.c (lynx_target_ops): Now a process_stratum_target.
8 * nto-low.c (nto_target_ops): Now a process_stratum_target.
9 * linux-low.c (linux_target_ops): Now a process_stratum_target.
10 * remote-utils.c (prepare_resume_reply): Pass the target to
12 * target.c (the_target): Now a process_stratum_target.
13 (done_accessing_memory): Pass the target to switch_to_thread.
14 (set_target_ops): Ajust to use process_stratum_target.
15 * target.h (struct target_ops): Rename to ...
16 (struct process_stratum_target): ... this.
17 (the_target, set_target_ops): Adjust.
18 (prepare_to_access_memory): Adjust comment.
19 * win32-low.c (child_xfer_memory): Adjust to use
20 process_stratum_target.
21 (win32_target_ops): Now a process_stratum_target.
23 2020-01-06 Eli Zaretskii <eliz@gnu.org>
24 Pedro Alves <palves@redhat.com>
26 * win32-low.c (get_child_debug_event): Extract the fatal exception
27 from the exit status and convert to the equivalent Posix signal
29 (win32_wait): Allow TARGET_WAITKIND_SIGNALLED status as well.
30 * Makefile.in (OBS, SFILES): Add gdb_wait.[co].
32 2020-01-01 Hannes Domani <ssbssa@yahoo.de>
34 * Makefile.in: Use INSTALL_PROGRAM_ENV.
36 2020-01-01 Joel Brobecker <brobecker@adacore.com>
38 * server.c (gdbserver_version): Change copyright year to 2020.
39 * gdbreplay.c (gdbreplay_version): Likewise.
41 2019-12-19 Christian Biesinger <cbiesinger@google.com>
43 * configure: Regenerate.
44 * configure.ac: Quote variable arguments of test.
46 2019-12-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
48 * Makefile.in: Fix build with GNU Make 3.81
50 2019-12-16 Tom Tromey <tromey@adacore.com>
52 * server.c (get_exec_file): Constify result.
54 2019-12-10 Christian Biesinger <cbiesinger@google.com>
56 * Makefile.in: Add safe-strerror.c to gdbreplay and IPA, and change
57 UNDO_GNULIB_CFLAGS to undo strerror_r instead of strerror.
58 * config.in: Regenerate.
59 * configure: Regenerate.
60 * configure.ac: Don't check for strerror.
61 * linux-i386-ipa.c (initialize_fast_tracepoint_trampoline_buffer):
62 Call safe_strerror instead of strerror.
63 * server.h (strerror): Remove this now-unnecessary declaration.
64 * tracepoint.c (init_named_socket): Call safe_strerror instead of
66 (gdb_agent_helper_thread): Likewise.
67 * utils.c (perror_with_name): Likewise.
69 2019-11-26 Tom Tromey <tom@tromey.com>
71 * configure, config.in: Rebuild.
73 2019-11-26 Tom Tromey <tom@tromey.com>
75 * remote-utils.c (block_unblock_async_io): Use gdb_sigmask.
76 * linux-low.c (linux_wait_for_event_filtered, linux_async): Use
78 * configure, config.in: Rebuild.
80 2019-11-26 Tom Tromey <tom@tromey.com>
82 * Makefile.in (PTHREAD_CFLAGS, PTHREAD_LIBS): New variables.
83 (INTERNAL_CFLAGS_BASE): Use PTHREAD_CFLAGS.
84 (GDBSERVER_LIBS): Use PTHREAD_LIBS.
85 * acinclude.m4: Include ax_pthread.m4.
86 * config.in, configure: Rebuild.
88 2019-11-26 Christian Biesinger <cbiesinger@google.com>
90 * debug.c (debug_set_output): Call safe_strerror instead of
92 * linux-low.c (attach_proc_task_lwp_callback): Likewise.
93 (linux_kill_one_lwp): Likewise.
94 (linux_detach_one_lwp): Likewise.
95 (linux_wait_for_event_filtered): Likewise.
96 (store_register): Likewise.
97 * lynx-low.c (lynx_attach): Likewise.
98 * mem-break.c (insert_memory_breakpoint): Likewise.
99 (remove_memory_breakpoint): Likewise.
100 (delete_fast_tracepoint_jump): Likewise.
101 (set_fast_tracepoint_jump): Likewise.
102 (uninsert_fast_tracepoint_jumps_at): Likewise.
103 (reinsert_fast_tracepoint_jumps_at): Likewise.
104 * nto-low.c (nto_xfer_memory): Likewise.
105 (nto_resume): Likewise.
107 2019-11-20 Luis Machado <luis.machado@linaro.org>
109 * linux-aarch64-low.c (is_sve_tdesc): Check against target feature
110 instead of register count.
111 * tdesc.c (tdesc_contains_feature): New function.
112 * tdesc.h (tdesc_contains_feature): New prototype.
114 2019-11-15 Christian Biesinger <cbiesinger@google.com>
116 * Makefile.in: Add safe-strerror.c.
117 * configure: Regenerate.
118 * configure.ac: Don't source common.host.
120 2019-11-15 Christian Biesinger <cbiesinger@google.com>
122 * config.in: Regenerate.
123 * configure: Regenerate.
125 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
127 * ax.c (ax_printf): Handle size_t_arg.
129 2019-11-06 Christian Biesinger <cbiesinger@google.com>
131 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
132 * mi/mi-main.c (output_cores): Likewise.
133 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
134 (linux_xfer_osdata_modules): Likewise.
135 * remote.c (register_remote_support_xml): Likewise.
136 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
137 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
139 2019-11-01 Christian Biesinger <cbiesinger@google.com>
141 * configure: Regenerate.
142 * configure.ac: Remove check for strerror_r.
144 2019-10-31 Christian Biesinger <cbiesinger@google.com>
146 * config.in: Regenerate.
147 * configure: Regenerate.
148 * configure.ac: Also check for strerror_r.
150 2019-10-31 Christian Biesinger <cbiesinger@google.com>
152 * ax.h (debug_agent): Remove duplicate declaration.
154 2019-10-26 Tom de Vries <tdevries@suse.de>
156 * linux-aarch64-low.c: Fix typos in comments.
157 * linux-arm-low.c: Same.
159 * linux-ppc-low.c: Same.
160 * proc-service.c: Same.
163 * tracepoint.c: Same.
166 2019-10-25 Tom Tromey <tromey@adacore.com>
168 * utils.c (xstrdup): Remove.
170 2019-10-23 Tom Tromey <tom@tromey.com>
172 * configure, config.in: Rebuild.
174 2019-10-23 Tom Tromey <tom@tromey.com>
176 * configure: Rebuild.
177 * acinclude.m4: Use m4_include, not sinclude.
179 2019-10-17 Tom Tromey <tromey@adacore.com>
181 * configure: Rebuild.
182 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
183 in AC_CONFIG_FILES invocation.
184 * Makefile.in (stamp-h, Makefile): Use new-style config.status
187 2019-10-16 Christian Biesinger <cbiesinger@google.com>
189 * server.c: Include xml-builtin.h.
190 (get_xml_features): Don't declare xml_builtins here.
192 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
194 * Makefile.in: Remove references to vec-ipa.o.
196 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
198 * Makefile.in: Remove references to vec.c.
200 2019-10-02 Christian Biesinger <cbiesinger@google.com>
202 * server.c (server_waiting): Change to bool.
203 (extended_protocol): Likewise.
204 (response_needed): Likewise.
205 (exit_requested): Likewise.
206 (run_once): Likewise.
207 (report_no_resumed): Likewise.
208 (non_stop): Likewise.
209 (disable_packet_vCont): Likewise.
210 (disable_packet_Tthread): Likewise.
211 (disable_packet_qC): Likewise.
212 (disable_packet_qfThreadInfo): Likewise.
213 (handle_general_set): Update.
214 (handle_detach): Update.
215 (handle_monitor_command): Update.
216 (handle_query): Update.
217 (captured_main): Update.
218 (process_serial_event): Update.
219 * server.h (server_waiting): Change to bool.
220 (disable_packet_vCont): Likewise.
221 (disable_packet_Tthread): Likewise.
222 (disable_packet_qC): Likewise.
223 (disable_packet_qfThreadInfo): Likewise.
224 (run_once): Likewise.
225 (non_stop): Likewise.
226 * target.c (target_stop_and_wait): Update.
228 2019-10-02 Tom Tromey <tromey@adacore.com>
230 * Makefile.in (SFILES): Add common-inferior.c.
231 (OBS): Add common-inferior.o.
232 * server.c (startup_with_shell): Don't define.
234 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
236 * linux-low.c (linux_low_read_btrace): Update for change to
239 2019-09-20 Christian Biesinger <cbiesinger@google.com>
241 * debug.c (debug_threads): Remove comment in favor of the header.
242 * debug.h (using_threads): Add declaration.
243 (debug_threads): Add comment.
244 * linux-aarch64-low.c: Include debug.h and remove declaration of
246 * nto-low.c: Likewise.
247 * remote-utils.c: Likewise.
248 * thread-db.c: Likewise.
250 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
252 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
253 and powerpc-cell64l-ipa.o.
254 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
255 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
256 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
259 * spu-low.c: Remove file.
261 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
262 (parse_spufs_run): Remove.
263 (ppc_get_pc): Remove Cell/B.E. support.
264 (ppc_set_pc): Likewise.
265 (ppc_breakpoint_at): Likewise.
266 (ppc_arch_setup): Likewise.
267 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
268 tdesc_powerpc_cell32l.
269 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
270 or init_registers_powerpc_cell32l.
271 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
272 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
273 or init_registers_powerpc_cell32l.
274 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
275 (init_registers_powerpc_cell32l): Remove prototype.
276 (init_registers_powerpc_cell64l): Likewise.
278 * target.h (struct target_ops): Remove qxfer_spu member.
279 * server.c (handle_qxfer_spu): Remove.
280 (qxfer_packets): Remove entry for "spu".
281 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
282 * linux-low.c (SPUFS_MAGIC): Remove.
283 (spu_enumerate_spu_ids): Remove.
284 (linux_qxfer_spu): Remove.
285 (linux_target_ops): Remove qxfer_spu member.
286 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
287 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
288 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
290 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
292 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
293 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
294 * config.in: Regenerate.
295 * configure: Regenerate.
297 2019-08-15 Tom Tromey <tromey@adacore.com>
299 * target.c (target_write_memory): Use gdb::byte_vector.
301 2019-08-15 Tom Tromey <tromey@adacore.com>
303 * tracepoint.c (write_inferior_data_pointer)
304 (write_inferior_integer, write_inferior_int8)
305 (write_inferior_uinteger, m_tracepoint_action_download)
306 (r_tracepoint_action_download, x_tracepoint_action_download)
307 (l_tracepoint_action_download, clear_inferior_trace_buffer)
308 (download_agent_expr, download_tracepoint_1)
309 (download_trace_state_variables, upload_fast_traceframes): Update.
310 * server.c (gdb_write_memory): Update.
311 * remote-utils.c (relocate_instruction): Update.
312 * proc-service.c (ps_pdwrite): Update.
313 * mem-break.c (remove_memory_breakpoint)
314 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
315 (uninsert_fast_tracepoint_jumps_at)
316 (reinsert_fast_tracepoint_jumps_at): Update.
317 * linux-x86-low.c (append_insns)
318 (i386_install_fast_tracepoint_jump_pad)
319 (amd64_write_goto_address, i386_write_goto_address): Update.
320 * linux-s390-low.c (append_insns, s390_write_goto_address):
322 * linux-ppc-low.c (ppc_relocate_instruction)
323 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
324 (ppc_write_goto_address): Update.
325 * linux-aarch64-low.c (append_insns): Update.
326 * target.h (struct target_ops): Update.
327 (write_inferior_memory): Don't declare.
328 * target.c (target_write_memory): Rename from
329 write_inferior_memory. Remove old target_write_memory.
331 2019-08-15 Tom Tromey <tromey@adacore.com>
333 * target.c (write_inferior_memory): Use std::vector.
335 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
338 * configure.ac: Drop enable-libmcheck support.
339 * configure, config.in: Rebuild.
340 * acinclude.m4: Don't include it.
342 2019-07-19 Alan Hayward <alan.hayward@arm.com>
344 * configure.srv: Remove Arm xml files.
346 2019-07-19 Alan Hayward <alan.hayward@arm.com>
348 * configure.srv: Add new files. Remove xml generated files.
349 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
351 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
352 * linux-aarch32-tdesc.c: New file.
353 * linux-aarch32-tdesc.h: New file.
354 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
355 * linux-arm-low.c (init_registers_arm, tdesc_arm)
356 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
357 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
358 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
359 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
360 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
361 (arm_read_description): Call arm_linux_read_description.
362 (initialize_low_arch): Don't init registers.
363 * linux-arm-tdesc.c: New file.
364 * linux-arm-tdesc.h: New file.
366 2019-07-10 Alan Hayward <alan.hayward@arm.com>
368 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
369 Move counter inside for.
370 (arm_read_description): Check ptrace earlier.
371 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
373 2019-07-09 Tom Tromey <tom@tromey.com>
375 * configure: Rebuild.
376 * configure.ac: Change common to gdbsupport.
377 * acinclude.m4: Change common to gdbsupport.
378 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
379 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
380 common to gdbsupport.
381 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
382 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
383 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
384 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
385 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
386 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
387 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
388 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
389 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
390 common to gdbsupport.
392 2019-07-04 Alan Hayward <alan.hayward@arm.com>
394 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
396 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
398 2019-07-04 Alan Hayward <alan.hayward@arm.com>
400 * configure.srv: Remove legacy xml.
401 * linux-aarch64-low.c (initialize_low_arch): Remove
402 initialize_low_tdesc call.
403 * linux-aarch64-tdesc-selftest.c: Remove file.
404 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
405 * linux-x86-low.c (initialize_low_arch): Remove
406 initialize_low_tdesc call.
407 * linux-x86-tdesc-selftest.c: Remove file.
408 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
410 2019-06-20 Tom de Vries <tdevries@suse.de>
412 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
413 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
415 2019-06-19 Tom de Vries <tdevries@suse.de>
417 * debug.h (debug_write): Change return type to ssize_t.
418 * debug.c (debug_write): Same.
420 2019-06-14 Tom Tromey <tom@tromey.com>
422 * configure.ac: Use new path to gnulib.
423 * configure: Rebuild.
424 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
427 2019-06-11 Tom Tromey <tom@tromey.com>
429 * Makefile.in (SFILES): Add alloc.c.
431 (IPA_OBJS): Add alloc-ipa.o.
432 (alloc-ipa.o): New target.
433 (%.o: ../%.c): New pattern rule.
435 2019-06-10 Tom Tromey <tromey@adacore.com>
437 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
438 end warning with a newline.
439 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
441 * thread-db.c (attach_thread): Don't end warning with a newline.
442 (thread_db_notice_clone): Likewise.
443 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
445 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
446 end warning with a newline.
448 2019-06-04 Pedro Alves <palves@redhat.com>
450 * server.c (captured_main): Use make_unique_xstrdup.
452 2019-06-02 Tom Tromey <tom@tromey.com>
454 * gdbreplay.c (fromhex): Remove.
455 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
457 2019-05-29 Tom Tromey <tromey@adacore.com>
459 * configure: Rebuild.
461 2019-05-06 Kevin Buettner <kevinb@redhat.com>
463 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
464 sign extension code on 32-bit builds.
466 2019-05-03 Eli Zaretskii <eliz@gnu.org>
469 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
471 2019-04-19 Tom Tromey <tom@tromey.com>
473 * server.c (struct vstop_notif): Derive from notif_event.
475 (queue_stop_reply): Update.
476 (remove_all_on_match_ptid): Change type. Rewrite.
477 (discard_queued_stop_replies): Rewrite.
478 (in_queued_stop_replies_ptid): Change type.
479 (in_queued_stop_replies): Rewrite.
480 (notif_stop): Update.
481 (queue_stop_reply_callback): Update.
482 (captured_main): Don't call initialize_notif.
483 (push_stop_notification): Update.
484 * notif.c (notif_write_event, handle_notif_ack)
485 (notif_event_enque, notif_push): Update.
486 (notif_event_xfree, initialize_notif): Remove.
487 * notif.h (struct notif_event): Include <list>, not
489 (struct notif_server) <queue>: Now a std::list.
490 (notif_event_p): Remove typedef.
491 (initialize_notif): Don't declare.
492 (struct notif_event): Add virtual destructor.
494 2019-04-17 Alan Hayward <alan.hayward@arm.com>
496 * ax.c (ax_vdebug): Call debug_printf.
497 * debug.c (debug_write): New function.
498 * debug.h (debug_write): New declaration.
499 * linux-low.c (sigchld_handler): Call debug_write.
501 2019-04-17 Alan Hayward <alan.hayward@arm.com>
503 * debug.c (debug_set_output): New function.
504 (debug_vprintf): Send output to debug_file.
505 (debug_flush): Likewise.
506 * debug.h (debug_set_output): New declaration.
507 * server.c (handle_monitor_command): Add debug-file option.
508 (captured_main): Likewise.
510 2019-04-17 Alan Hayward <alan.hayward@arm.com>
512 * debug.c (remote_debug): Add definition.
513 * debug.h (remote_debug): Add declaration.
514 * hostio.c (remote_debug): Remove declaration.
515 * remote-utils.c (struct ui_file): Likewise.
516 (remote_debug): Likewise.
517 * remote-utils.h (remote_debug): Likewise,
518 * server.c (remote_debug): Remove definition.
520 2019-04-10 Kevin Buettner <kevinb@redhat.com>
522 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
523 when using a 64-bit gdbserver.
525 2019-04-09 Tom Tromey <tromey@adacore.com>
527 * linux-low.c (select_event_lwp): Use find_thread_in_random.
529 2019-04-08 Tom Tromey <tom@tromey.com>
531 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
533 (linux_resume_one_lwp): Likewise.
535 2019-04-08 Tom Tromey <tom@tromey.com>
537 * gdbreplay.c: Update.
538 * linux-low.c: Update.
541 2019-04-08 Tom Tromey <tom@tromey.com>
543 * server.c: Use C++ exception handling.
544 * linux-low.c: Use C++ exception handling.
545 * gdbreplay.c: Use C++ exception handling.
547 2019-04-08 Tom Tromey <tom@tromey.com>
549 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
550 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
551 (captured_main, main): Update.
552 * gdbreplay.c (main): Update.
554 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
556 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
557 value in argument pointer, return 1 if the entry is found and 0
558 otherwise. Move comment.
559 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
560 * linux-low.h (linux_get_auxv): Declare.
561 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
563 2019-04-05 Tom Tromey <tromey@adacore.com>
565 * server.c (gdbserver_usage): Use upper-case for metasyntactic
568 2019-03-28 Alan Hayward <alan.hayward@arm.com>
570 * linux-low.c (AT_HWCAP2): Add define if not already included.
572 2019-03-26 Alan Hayward <alan.hayward@arm.com>
574 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
575 (aarch64_arch_setup): Call linux_get_hwcap.
576 * linux-arm-low.c (arm_get_hwcap): Remove function.
577 (arm_read_description): Call linux_get_hwcap.
578 * linux-low.c (linux_get_auxv): New function.
579 (linux_get_hwcap): Likewise.
580 (linux_get_hwcap2): Likewise.
581 * linux-low.h (linux_get_hwcap): New declaration.
582 (linux_get_hwcap2): Likewise.
583 * linux-ppc-low.c (ppc_get_auxv): Remove function.
584 (ppc_arch_setup): Call linux_get_hwcap.
585 * linux-s390-low.c (s390_get_hwcap): Remove function.
586 (s390_arch_setup): Call linux_get_hwcap.
588 2019-03-22 Alan Hayward <alan.hayward@arm.com>
589 Jiong Wang <jiong.wang@arm.com>
591 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
592 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
594 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
596 2019-03-22 Alan Hayward <alan.hayward@arm.com>
597 Jiong Wang <jiong.wang@arm.com>
599 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
600 (aarch64_get_hwcap): New function.
601 (aarch64_arch_setup): Read APIA hwcap.
603 2019-03-22 Alan Hayward <alan.hayward@arm.com>
604 Jiong Wang <jiong.wang@arm.com>
606 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
607 (initialize_low_tracepoint): Likewise.
608 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
609 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
610 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
611 (aarch64_linux_read_description): Likewise.
612 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
614 2019-03-12 John Baldwin <jhb@FreeBSD.org>
616 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
617 i386_create_target_description for 'segments' parameter.
618 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
619 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
620 * win32-i386-low.c (i386_arch_setup): Likewise.
622 2019-03-12 Tom Tromey <tromey@adacore.com>
624 * linux-low.c (iterate_over_lwps): Update.
626 2019-03-06 Tom Tromey <tom@tromey.com>
628 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
629 (captured_main): Use SCOPE_EXIT.
631 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
633 * configure.srv: Use '$enable_unittest' instead of '$development'
634 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
637 2019-02-27 Tom Tromey <tromey@adacore.com>
639 * gdbreplay.c (logchar): Handle \r\n.
641 2019-02-07 Alan Hayward <alan.hayward@arm.com>
643 * linux-low.c (linux_attach): Add process before lwp.
644 * server.c (attach_inferior): Check if already attached.
646 2019-02-07 Tom Tromey <tom@tromey.com>
648 * x86-tdesc.h: Rename include guard.
649 * x86-low.h: Add include guard.
650 * wincecompat.h: Rename include guard.
651 * win32-low.h: Add include guard.
652 * utils.h: Rename include guard.
653 * tracepoint.h: Rename include guard.
654 * tdesc.h: Rename include guard.
655 * target.h: Rename include guard.
656 * server.h: Rename include guard.
657 * remote-utils.h: Rename include guard.
658 * regcache.h: Rename include guard.
659 * nto-low.h: Rename include guard.
660 * notif.h: Add include guard.
661 * mem-break.h: Rename include guard.
662 * lynx-low.h: Add include guard.
663 * linux-x86-tdesc.h: Add include guard.
664 * linux-s390-tdesc.h: Add include guard.
665 * linux-ppc-tdesc-init.h: Add include guard.
666 * linux-low.h: Add include guard.
667 * linux-aarch64-tdesc.h: Add include guard.
668 * linux-aarch32-low.h: Add include guard.
669 * inferiors.h: Rename include guard.
670 * i387-fp.h: Rename include guard.
671 * hostio.h: Rename include guard.
672 * gdbthread.h: Rename include guard.
673 * gdb_proc_service.h: Rename include guard.
674 * event-loop.h: Rename include guard.
675 * dll.h: Rename include guard.
676 * debug.h: Rename include guard.
677 * ax.h: Rename include guard.
679 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
682 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
683 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
685 2019-01-25 Tom Tromey <tom@tromey.com>
687 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
689 2019-01-25 Tom Tromey <tom@tromey.com>
691 * win32-low.c: Fix common/ includes.
692 * win32-i386-low.c: Fix common/ includes.
693 * tracepoint.c: Fix common/ includes.
694 * thread-db.c: Fix common/ includes.
695 * target.h: Fix common/ includes.
696 * symbol.c: Fix common/ includes.
697 * spu-low.c: Fix common/ includes.
698 * server.h: Fix common/ includes.
699 * server.c: Fix common/ includes.
700 * remote-utils.c: Fix common/ includes.
701 * regcache.h: Fix common/ includes.
702 * regcache.c: Fix common/ includes.
703 * nto-x86-low.c: Fix common/ includes.
704 * notif.h: Fix common/ includes.
705 * mem-break.h: Fix common/ includes.
706 * lynx-low.c: Fix common/ includes.
707 * lynx-i386-low.c: Fix common/ includes.
708 * linux-x86-tdesc-selftest.c: Fix common/ includes.
709 * linux-x86-low.c: Fix common/ includes.
710 * linux-low.c: Fix common/ includes.
711 * inferiors.h: Fix common/ includes.
712 * i387-fp.c: Fix common/ includes.
713 * hostio.c: Fix common/ includes.
714 * hostio-errno.c: Fix common/ includes.
715 * gdbthread.h: Fix common/ includes.
716 * gdbreplay.c: Fix common/ includes.
717 * fork-child.c: Fix common/ includes.
718 * event-loop.c: Fix common/ includes.
720 (enum gdb_agent_op): Fix common/ includes.
722 2019-01-21 Tom Tromey <tom@tromey.com>
724 * tracepoint.c: Fix includes.
725 * remote-utils.c: Fix includes.
726 * linux-x86-low.c: Fix includes.
728 2019-01-01 Joel Brobecker <brobecker@adacore.com>
730 * gdbreplay.c (gdbreplay_version): Update copyright year in
732 * server.c (gdbserver_version): Likewise.
734 2018-12-05 Alan Hayward <alan.hayward@arm.com>
736 * linux-low.c (add_lwp): Switch ordering.
738 2018-11-29 Tom Tromey <tom@tromey.com>
740 * win32-low.c (win32_join): Take pid, not process.
741 * target.h (struct target_ops) <join>: Change argument type.
742 (join_inferior): Change argument name.
743 * spu-low.c (spu_join): Take pid, not process.
744 * server.c (handle_detach): Preserve pid before destroying
746 * lynx-low.c (lynx_join): Take pid, not process.
747 * linux-low.c (linux_join): Take pid, not process.
749 2018-11-23 Alan Hayward <alan.hayward@arm.com>
751 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
752 (aarch64_cannot_fetch_register): Likewise.
753 (struct linux_target_ops): Update references.
755 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
757 * linux-ppc-low.c: Include nat/linux-ptrace.h.
759 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
761 * configure.srv (ipa_ppc_linux_regobj): Add
762 powerpc-isa207-htm-vsx32l-ipa.o and
763 powerpc-isa207-htm-vsx64l-ipa.o.
764 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
765 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
766 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
767 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
768 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
769 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
770 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
771 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
772 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
773 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
774 (init_registers_powerpc_isa207_htm_vsx32l)
775 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
776 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
777 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
778 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
779 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
780 (ppc_store_tm_ctarregset): New functions.
781 (ppc_regsets): Add entries for HTM regsets.
782 (ppc_arch_setup): Set htm in features struct when needed. Set
783 sizes for the HTM regsets.
784 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
785 (initialize_low_arch): Call
786 init_registers_powerpc_isa207_htm_vsx32l and
787 init_registers_powerpc_isa207_htm_vsx64l.
788 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
789 PPC_TDESC_ISA207_HTM_VSX.
790 (initialize_low_tracepoint): Call
791 init_registers_powerpc_isa207_htm_vsx32l and
792 init_registers_powerpc_isa207_htm_vsx64l.
794 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
796 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
797 rs6000/power-linux-pmu.xml to srv_xmlfiles.
798 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
799 (ppc_store_pmuregset): New functions.
800 (ppc_regsets): Add entries for ebb and pmu regsets.
801 (ppc_arch_setup): Set isa207 in features struct if the ebb and
802 pmu regsets are available. Set sizes for these regsets.
804 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
806 * configure.srv (ipa_ppc_linux_regobj): Add
807 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
808 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
809 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
810 rs6000/powerpc-isa207-vsx32l.xml, and
811 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
812 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
813 <PPC_TDESC_ISA207_VSX>: New enum value.
814 (init_registers_powerpc_isa207_vsx32l): Declare.
815 (init_registers_powerpc_isa207_vsx64l): Declare.
816 * linux-ppc-low.c (ppc_fill_tarregset): New function.
817 (ppc_store_tarregset): New function.
818 (ppc_regsets): Add entry for the TAR regset.
819 (ppc_arch_setup): Set isa207 in features struct when needed. Set
820 size for the TAR regsets.
821 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
822 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
823 and init_registers_powerpc_isa207_vsx64l.
824 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
825 (initialize_low_tracepoint): Call
826 init_registers_powerpc_isa207_vsx32l and
827 init_registers_powerpc_isa207_vsx64l.
829 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
830 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
832 * configure.srv (ipa_ppc_linux_regobj): Add
833 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
834 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
835 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
836 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
837 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
838 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
839 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
840 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
841 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
842 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
843 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
844 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
845 (ppc_hwcap): Add comment.
846 (ppc_hwcap2): New global.
847 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
848 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
849 (ppc_regsets): Add entries for the DSCR and PPR regsets.
850 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
851 when needed. Set sizes for the the DSCR and PPR regsets.
852 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
853 (initialize_low_arch): Call
854 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
855 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
856 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
857 PPC_TDESC_ISA205_PPR_DSCR_VSX.
858 (initialize_low_tracepoint): Call
859 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
860 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
862 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
864 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
866 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
867 Simon Marchi <simark@simark.ca>
869 * acinclude.m4: Include "../selftest.m4".
870 * configure: Regenerate.
871 * configure.ac: Use "GDB_AC_SELFTEST".
872 * configure.srv: Use "$enable_unittests" instead of
873 "$development" when checking whether unit tests have been
875 * server.c (captured_main): Update message informing that
876 selftests have been disabled.
878 2018-10-04 Tom Tromey <tom@tromey.com>
880 * configure: Rebuild.
882 2018-10-04 Tom Tromey <tom@tromey.com>
884 * server.c (handle_status): Rename inner "thread".
885 (process_serial_event): Declare "res" in 'm' case.
886 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
887 (iterate_over_lwps): Rename inner "thread".
888 (linux_qxfer_libraries_svr4): Rename inner "len".
889 * gdbthread.h (find_thread_in_random): Rename inner "thread".
891 2018-10-01 Gary Benson <gbenson@redhat.com>
893 * gdb_proc_service.h: Moved common code to
894 common/gdb_proc_service.h.
896 2018-10-01 Gary Benson <gbenson@redhat.com>
898 * gdb_proc_service.h: Synchronize comments and whitespace with
899 GDB's version of this file.
901 2018-09-25 Tom Tromey <tom@tromey.com>
903 * configure: Rebuild.
904 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
906 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
908 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
909 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
910 ($(IPA_LIB)): Sort IPA_OBJS.
912 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
914 * Makefile.in: Remove references to $(ADD_DEPS).
916 2018-09-16 Tom Tromey <tom@tromey.com>
918 * remote-utils.c (remote_open): Use GNU style for metasyntactic
920 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
923 2018-09-05 Tom Tromey <tom@tromey.com>
925 * configure: Rebuild.
927 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
930 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
932 2018-08-27 Tom Tromey <tom@tromey.com>
935 * configure: Rebuild.
937 2018-08-27 Tom Tromey <tom@tromey.com>
939 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
940 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
941 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
942 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
943 (s390x_emit_stack_adjust): Add casts to unsigned char.
945 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
949 * server.h (struct client_state) <disable_randomization>:
952 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
954 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
956 (mips_supply_ptrace_register): Likewise.
958 2018-07-22 Tom Tromey <tom@tromey.com>
960 * configure: Rebuild.
962 2018-07-22 Tom Tromey <tom@tromey.com>
964 * win32-low.c (win32_create_inferior): Remove unused variables.
965 * gdbreplay.c (remote_open): Remove unused variable.
966 * remote-utils.c (remote_prepare): Remove unused variable.
967 * x86-tdesc.h (X86_TDESC_H): Define.
968 (amd64_expedite_regs): Define conditionally.
969 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
970 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
971 * remote-utils.c (readchar): Remove unused variable.
973 2018-07-13 Pedro Alves <palves@redhat.com>
975 * linux-low.c (linux_kill): Change parameter to process_info
976 pointer instead of pid. Adjust.
977 * lynx-low.c (lynx_kill): Likewise.
978 * nto-low.c (nto_kill): Likewise.
979 * spu-low.c (spu_kill): Likewise.
980 * win32-low.c (win32_kill): Likewise.
981 * server.c (handle_v_kill, kill_inferior_callback)
982 (detach_or_kill_for_exit): Adjust.
983 * target.c (kill_inferior): Change parameter to process_info
984 pointer instead of pid. Adjust.
985 * target.h (struct target_ops) <kill>: Change parameter to
986 process_info pointer instead of pid. Adjust all implementations
988 (kill_inferior): Likewise.
990 2018-07-13 Pedro Alves <palves@redhat.com>
992 * linux-low.c (linux_detach, linux_join): Change parameter to
993 process_info pointer instead of pid. Adjust.
994 * lynx-low.c (lynx_detach, lynx_join): Likewise.
995 * nto-low.c (nto_detach): Likewise.
996 * spu-low.c (spu_detach, spu_join): Likewise.
997 * win32-low.c (win32_detach, win32_join): Likewise.
998 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
999 * target.h (struct target_ops) <detach, join>: Change parameter to
1000 process_info pointer instead of pid. Adjust all implementations
1002 (detach_inferior, join_inferior): Rename 'pid' parameter to
1005 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
1006 Jan Kratochvil <jan.kratochvil@redhat.com>
1007 Paul Fertser <fercerpav@gmail.com>
1008 Tsutomu Seki <sekiriki@gmail.com>
1010 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
1011 (OBS): Add 'common/netstuff.o'.
1012 (GDBREPLAY_OBS): Likewise.
1013 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
1014 (remote_open): Implement support for IPv6
1016 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
1018 (handle_accept_event): Accept connections from IPv6 sources.
1019 (remote_prepare): Handle IPv6-style hostnames; implement
1020 support for IPv6 connections.
1021 (remote_open): Implement support for printing connections from
1024 2018-07-11 Pedro Alves <palves@redhat.com>
1027 * mem-break.c (any_persistent_commands): Add process_info
1028 parameter and use it instead of relying on the current process.
1029 Change return type to bool.
1030 * mem-break.h (any_persistent_commands): Add process_info
1031 parameter and change return type to bool.
1032 * server.c (handle_detach): Remove require_running_or_return call.
1033 Look up the process_info for the process we're about to detach.
1034 If not found, return back error to GDB. Adjust
1035 any_persistent_commands call to pass down a process pointer.
1037 2018-07-11 Pedro Alves <palves@redhat.com>
1039 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
1040 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
1041 instead of collect_register_by_name.
1042 * regcache.c (regcache_raw_get_unsigned_by_name): New.
1043 * regcache.h (regcache_raw_get_unsigned_by_name): New.
1045 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
1046 Pedro Alves <palves@redhat.com>
1048 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
1050 2018-07-03 Tom Tromey <tom@tromey.com>
1052 * linux-low.c: Update.
1053 * lynx-low.c: Update.
1054 * mem-break.c: Update.
1055 * nto-low.c: Update.
1056 * remote-utils.c: Update.
1058 * spu-low.c: Update.
1060 * win32-low.c: Update.
1062 2018-07-03 Tom Tromey <tom@tromey.com>
1066 2018-07-03 Tom Tromey <tom@tromey.com>
1068 * linux-low.c: Update.
1070 2018-07-03 Tom Tromey <tom@tromey.com>
1074 2018-07-03 Tom Tromey <tom@tromey.com>
1076 * linux-low.c: Update.
1077 * linux-mips-low.c: Update.
1078 * lynx-low.c: Update.
1079 * nto-low.c: Update.
1080 * remote-utils.c: Update.
1082 * spu-low.c: Update.
1084 * thread-db.c: Update.
1086 2018-07-03 Tom Tromey <tom@tromey.com>
1088 * linux-low.c: Update.
1089 * linux-mips-low.c: Update.
1090 * lynx-low.c: Update.
1091 * mem-break.c: Update.
1092 * nto-low.c: Update.
1093 * remote-utils.c: Update.
1095 * spu-low.c: Update.
1097 * tracepoint.c: Update.
1099 2018-07-03 Tom Tromey <tom@tromey.com>
1101 * linux-low.c: Update.
1102 * linux-ppc-low.c: Update.
1103 * linux-x86-low.c: Update.
1104 * proc-service.c: Update.
1106 * spu-low.c: Update.
1107 * thread-db.c: Update.
1108 * win32-low.c: Update.
1110 2018-07-03 Tom Tromey <tom@tromey.com>
1112 * linux-low.c: Update.
1113 * lynx-low.c: Update.
1114 * nto-low.c: Update.
1115 * remote-utils.c: Update.
1116 * spu-low.c: Update.
1117 * thread-db.c: Update.
1118 * win32-low.c: Update.
1120 2018-06-29 Joel Brobecker <brobecker@adacore.com>
1122 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
1123 parameter in call to 'amd64_create_target_description'.
1125 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
1127 * x86-tdesc.h: Remove executable permission flag.
1129 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1131 * configure.ac: Remove AC_PREREQ, add missing quoting.
1132 * configure: Re-generate.
1133 * config.in: Re-generate.
1134 * aclocal.m4: Re-generate.
1136 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
1138 * tracepoint.h (current_traceframe): Remove declaration.
1140 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1142 * linux-aarch64-low.c (is_sve_tdesc): New function.
1143 (aarch64_sve_regs_copy_to_regcache): Likewise.
1144 (aarch64_sve_regs_copy_from_regcache): Likewise.
1145 (aarch64_regs_info): Add SVE checks.
1146 (initialize_low_arch): Initialize SVE.
1148 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1150 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
1152 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1154 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
1155 (initialize_low_tracepoint): Likewise
1156 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
1157 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
1159 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
1161 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
1163 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1165 * server.h (PBUFSIZ): Increase size
1167 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1169 * regcache.c (regcache::raw_compare): New function.
1170 * regcache.h (regcache::raw_compare): New declaration.
1172 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1174 * regcache.c (new_register_cache): Use new.
1175 (free_register_cache): Use delete.
1176 (register_data): Use const.
1177 (supply_register): Move body inside regcache.
1178 (regcache::raw_supply): New override function.
1179 (collect_register): Move body inside regcache.
1180 (regcache::raw_collect): New override function.
1181 (regcache::get_register_status): New override function.
1182 * regcache.h (struct regcache): Inherit from reg_buffer_common.
1184 2018-06-09 Tom Tromey <tom@tromey.com>
1186 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
1188 (event_queue): Use std::queue.
1189 (gdb_event_xfree): Remove.
1190 (initialize_event_loop, process_event, wait_for_event): Update.
1192 2018-06-08 Stan Cox <scox@redhat.com>
1194 * win32-low.c (win32_create_inferior): last_ptid and last_status
1195 moved to client_state.
1197 2018-06-08 Pedro Alves <palves@redhat.com>
1199 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
1200 common/common-exceptions.o, common/common-utils.o,
1201 common/errors.o, common/print-utils.o and utils.o.
1202 * gdbreplay.c: Include "common-defs.h" instead of the two
1203 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
1204 string.h or alloca.h.
1205 (perror_with_name): Delete.
1206 (remote_open): Use xstrdup instead of strdup.
1207 (main): Rename to ...
1208 (captured_main): ... this.
1211 2018-06-08 Tom Tromey <tom@tromey.com>
1213 * linux-low.c (linux_low_read_btrace): Update.
1215 2018-06-04 Stan Cox <scox@redhat.com>
1217 * server.h (struct client_state): New.
1218 * server.c (cont_thread, general_thread, multi_process)
1219 (report_fork_events, report_vfork_events, report_exec_events)
1220 (report_thread_events, swbreak_feature, hwbreak_feature)
1221 (vCont_supported, disable_randomization, pass_signals)
1222 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
1223 Moved to client_state.
1224 * remote-utils.c (remote_debug, noack_mode)
1225 (transport_is_reliable): Moved to client_state.
1226 * tracepoint.c (current_traceframe): Moved to client_state.
1229 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
1230 linux-low.c, remote-utils.h, target.c: Use client_state.
1232 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1234 * configure.srv: Add new c/h file.
1236 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1238 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1241 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1243 * gdb.arch/mips-fpregset-core.exp: New test.
1244 * gdb.arch/mips-fpregset-core.c: New test source.
1246 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1249 * hostio.c (require_int): Do not report overflow for integers
1250 between 0xfffffff and 0x7fffffff.
1252 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1254 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1255 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1256 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1258 (the_low_target): Wire them.
1260 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1262 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1263 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1264 mode. Call collect_register_by_name with vscr using
1265 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1266 (ppc_store_vrregset): Add and set vscr_offset variable as in
1267 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1270 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1272 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1273 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1274 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1276 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1278 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1279 (ppc_store_vsxregset): Likewise.
1280 (ppc_fill_vrregset): Likewise.
1281 (ppc_store_vrregset): Likewise.
1282 (ppc_fill_evrregset): Likewise.
1283 (ppc_store_evrregset): Likewise.
1284 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1285 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1288 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1290 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1291 wordsize of the inferior. Call ppc_linux_target_wordsize.
1293 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1295 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1296 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1297 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1298 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1299 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1300 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1301 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1302 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1303 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1304 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1305 (tdesc_powerpc_e500l): Remove.
1306 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1307 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1308 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1309 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1311 (ppc_arch_setup): Remove target description matching code. Fill a
1312 ppc_linux_features struct and call ppc_linux_match_description
1315 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1317 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1318 width of the requested register exceeds the width of the
1320 (mips_cannot_store_register): Likewise.
1322 2018-05-21 Maciej W. Rozycki <macro@mips.com>
1324 * linux-mips-low.c (mips_fetch_register): New function. Update
1326 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1327 (the_low_target): Wire `mips_fetch_register'.
1329 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1331 * lynx-i386-low.c (LYNXOS_178): New macro.
1332 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1333 the layout on LynxOS-178.
1334 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1335 handle floating point registers that are not supported by
1338 2018-05-10 Tom Tromey <tom@tromey.com>
1340 * configure: Rebuild.
1342 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1345 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1346 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1347 Use it to set the expedite_regs field in the given tdesc.
1348 * x86-tdesc.h: New file.
1349 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1350 Adjust following the addition of the new expedite_regs parameter
1351 to init_target_desc.
1352 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1353 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1354 (i386_linux_read_description, amd64_linux_read_description):
1355 Adjust following the addition of the new expedite_regs parameter
1356 to init_target_desc.
1357 * lynx-i386-low.c: #include "x86-tdesc.h".
1358 (lynx_i386_arch_setup): Adjust following the addition of the new
1359 expedite_regs parameter to init_target_desc.
1360 * nto-x86-low.c: #include "x86-tdesc.h".
1361 (nto_x86_arch_setup): Adjust following the addition of the new
1362 expedite_regs parameter to init_target_desc.
1363 * win32-i386-low.c: #include "x86-tdesc.h".
1364 (i386_arch_setup): Adjust following the addition of the new
1365 expedite_regs parameter to init_target_desc.
1367 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1370 * win32-low.c (win32_create_inferior): Add call to my_wait
1371 setting last_status global.
1373 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1376 * win32-low.c (create_process): Only call gdb_tilde_expand if
1377 inferior_cwd is not NULL.
1379 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1381 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1382 registers to the cache if their values have changed.
1383 (i387_xsave_to_cache): Provide default values for x87 control
1384 registers when these features are available, but disabled.
1385 * regcache.c (supply_register_by_name_zeroed): New function.
1386 * regcache.h (supply_register_by_name_zeroed): Declare new
1389 2018-05-07 Tom Tromey <tom@tromey.com>
1391 * configure: Rebuild.
1393 2018-05-04 Tom Tromey <tom@tromey.com>
1395 * configure: Rebuild.
1397 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1398 Pedro Alves <palves@redhat.com>
1400 * linux-aarch64-low.c (aarch64_stopped_data_address):
1403 2018-04-27 Tom Tromey <tom@tromey.com>
1405 * configure: Rebuild.
1407 2018-04-23 Tom Tromey <tom@tromey.com>
1409 * configure: Rebuild.
1411 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1413 * Makefile.in (depcomp): Add "..".
1414 (all_deps_files): New and use it.
1416 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1418 * configure.srv (aarch64*-*-linux*): Don't include xml.
1419 (i[34567]86-*-cygwin*): Likewise.
1420 (i[34567]86-*-linux*): Likewise.
1421 (i[34567]86-*-lynxos*): Likewise.
1422 (i[34567]86-*-mingw32ce*): Likewise.
1423 (i[34567]86-*-mingw*): Likewise.
1424 (i[34567]86-*-nto*): Likewise.
1425 (tic6x-*-uclinux): Likewise.
1426 (x86_64-*-linux*): Likewise.
1427 (x86_64-*-mingw*): Likewise.
1428 (x86_64-*-cygwin*): Likewise.
1430 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1432 * tdesc.c: Remove xml parameter.
1434 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1436 * server.c (get_features_xml): Remove cast.
1437 * tdesc.c (void target_desc::accept): Fill in function.
1438 (tdesc_get_features_xml): Remove old xml creation.
1439 (print_xml_feature::visit_pre): Add xml vistor.
1440 * tdesc.h (struct target_desc): Make xmltarget mutable.
1441 (tdesc_get_features_xml): Remove declaration.
1443 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1445 * tdesc.c (tdesc_architecture_name): Add new function.
1446 (tdesc_osabi_name): Likewise.
1447 (tdesc_get_features_xml): Use new functions.
1449 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1451 * tdesc.c (tdesc_create_flags): Remove.
1452 (tdesc_add_flag): Likewise.
1453 (tdesc_named_type): Likewise.
1454 (tdesc_create_union): Likewise.
1455 (tdesc_create_struct): Likewise.
1456 (tdesc_create_vector): Likewise.
1457 (tdesc_add_bitfield): Likewise.
1458 (tdesc_add_field): Likewise.
1459 (tdesc_set_struct_size): Likewise.
1461 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1463 * tdesc.c (~target_desc): Remove implictly deleted items.
1464 (init_target_desc): Iterate all features.
1465 (tdesc_get_features_xml): Use vector.
1466 (tdesc_create_feature): Create feature.
1467 * tdesc.h (tdesc_feature) Remove
1468 (target_desc): Add features.
1470 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1472 * Makefile.in: Add common/tdesc.c
1473 * tdesc.c (init_target_desc): init all reg_defs from register
1475 (tdesc_create_reg): Create tdesc_reg.
1476 * tdesc.h (tdesc_feature): Add register vector.
1478 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1480 * tdesc.h (struct target_desc) <features>: Change type to
1481 std::vector<std::string>.
1482 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1484 (tdesc_get_features_xml): Likewise.
1485 (tdesc_create_feature): Likewise.
1487 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1489 * regcache.c (find_register_by_number): Return a ref.
1490 (find_regno): Use references.
1491 (register_size): Likewise.
1492 (register_data): Likewise.
1493 * tdesc.c (target_desc::~target_desc): Remove free calls.
1494 (target_desc::operator==): Use std::vector compare.
1495 (init_target_desc): Use reference.
1496 (tdesc_create_reg): Use reg constructors.
1497 * tdesc.h (struct target_desc): Replace pointer with object.
1499 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1501 * regcache.c (find_register_by_number): Make static.
1502 (find_regno): Use find_register_by_number
1503 * regcache.h (struct reg): Remove declaration.
1505 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1507 * tdesc.c (target_desc::~target_desc): Move to here.
1508 (target_desc::operator==): Likewise.
1509 * tdesc.h (target_desc::~target_desc): Move from here.
1510 (target_desc::operator==): Likewise.
1512 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1514 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1516 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1518 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1520 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1521 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1522 and init_registers_s390_gs_linux64.
1524 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1526 * linux-s390-low.c (s390_fill_gs): Remove function.
1527 (s390_fill_gsbc): Remove function.
1528 (s390_regsets): Set fill functions for the guarded storage regsets
1531 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1533 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1534 the word size. Add comment.
1535 (s390_get_wordsize): New function.
1536 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1537 pswm with it. Instead, use s390_get_wordsize to determine the
1538 word size first and derive the correct tdesc from that directly.
1540 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1542 * Makefile.in: Include silent-rules.mk.
1543 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1544 (COMPILE): Add ECHO_CXX.
1545 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1546 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1547 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1548 (version-generated.c): Add ECHO_GEN.
1549 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1550 (IPAGENT_COMPILE): Add ECHO_CXX.
1551 (%-generated.c): Add ECHO_REGDAT.
1553 2018-03-14 Tom Tromey <tom@tromey.com>
1556 * ax.c (ax_printf): Special case for NULL.
1558 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1560 * linux-low.c (linux_qxfer_libraries_svr4): Use
1561 xml_escape_text_append.
1563 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1565 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1567 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1569 * server.c (handle_general_set): Remove unnecessary xstrdup.
1571 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1573 * server.c (parse_debug_format_options): Adjust to
1574 delim_string_to_char_ptr_vec changes.
1575 * thread-db.c (thread_db_load_search): Adjust to
1576 dirnames_to_char_ptr_vec changes.
1578 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1580 * target.h (target_enable_btrace, target_disable_btrace)
1581 (target_read_btrace, target_read_btrace_conf): Turn macro into
1582 inline function. Throw error if target method is not defined.
1583 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1584 check for btrace target method. Be prepared to handle exceptions
1585 from btrace target methods.
1587 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1589 * server.c (captured_main): Change order of error message printed
1590 when the current working directory cannot be found.
1592 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1594 * server.c: Include "filenames.h" and "pathstuff.h".
1595 (program_name): Delete variable.
1596 (program_path): New anonymous class.
1597 (get_exec_wrapper): Use "program_path" instead of
1599 (handle_v_run): Likewise.
1600 (captured_main): Likewise.
1601 (process_serial_event): Likewise.
1603 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1605 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1606 (OBJS): Add "pathstuff.o".
1607 * server.c (current_directory): New global variable.
1608 (captured_main): Initialize "current_directory".
1610 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1612 * tdesc.c: Use common/tdesc.h.
1613 * tdesc.h: Likewise.
1615 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1616 Simon Marchi <simon.marchi@ericsson.com>
1618 * Makefile.in: Switch order of make rules.
1620 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1622 * Makefile.in: Add common directory in build.
1623 * configure.ac: Add common reference.
1624 * configure: Regenerate.
1626 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1628 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1629 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1630 * spu-low.c (spu_target_ops): Likewise.
1631 * win32-low.c (win32_target_ops): Likewise.
1632 * server.c (supported_btrace_packets): Report packets unconditionally.
1633 * target.h (target_ops) <supports_btrace>: Remove.
1634 (target_supports_btrace): Remove.
1636 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1638 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1639 (handle_btrace_disable): Change return type to void. Use exceptions
1641 (handle_btrace_general_set): Catch exception and copy message to
1644 2018-02-08 Tom Tromey <tom@tromey.com>
1646 * linux-low.c (install_software_single_step_breakpoints): Use
1647 make_scoped_restore.
1648 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1649 (do_restore_current_thread_cleanup): Remove.
1650 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1653 2018-02-08 Tom Tromey <tom@tromey.com>
1655 * mem-break.c (set_raw_breakpoint_at): Use
1656 gdb::unique_xmalloc_ptr.
1658 2018-01-30 Pedro Alves <palves@redhat.com>
1661 * target.c (target_terminal::terminal_state): Rename to ...
1662 (target_terminal::m_terminal_state): ... this.
1664 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1666 * linux-low.c (handle_extended_wait): Surround call to
1667 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1669 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1671 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1672 linux_ptrace_attach_fail_reason_string now returning an
1674 (linux_attach): Likewise.
1675 * thread-db.c (attach_thread): Likewise.
1677 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1680 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1681 checking for fs_base/gs_base fields in struct user_regs_struct.
1682 * configure: Regenerate.
1684 2018-01-16 Yao Qi <yao.qi@linaro.org>
1687 * linux-low.c (fetch_register): Call supply_register instead of
1690 2018-01-08 Yao Qi <yao.qi@linaro.org>
1691 Simon Marchi <simon.marchi@ericsson.com>
1693 * Makefile.in (OBS): Remove selftest.o.
1694 * configure.ac: Set srv_selftest_objs if $development is true.
1695 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1696 * configure: Re-generated.
1697 * server.c (captured_main): Wrap variable selftest_filter with
1700 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1702 * server.c (parse_debug_format_options): Return std::string.
1703 (handle_monitor_command, captured_main): Adjust.
1705 2018-01-05 Pedro Alves <palves@redhat.com>
1708 * server.c (captured_main): Pass quiet=false to
1709 save_original_signals_state.
1711 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1713 * gdbreplay.c (gdbreplay_version): Update copyright year in
1715 * server.c (gdbserver_version): Likewise.
1717 2017-12-08 Tom Tromey <tom@tromey.com>
1719 * ax.c (ax_printf): Update.
1721 2017-12-07 Yao Qi <yao.qi@linaro.org>
1723 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1724 aarch64_linux_read_description.
1725 * linux-amd64-ipa.c (idx2mask): New array.
1726 (get_ipa_tdesc): Move idx2mask out.
1727 (initialize_low_tracepoint): Initialize target descriptions.
1728 * linux-i386-ipa.c (idx2mask): New array.
1729 (get_ipa_tdesc): Move idx2mask out.
1730 (initialize_low_tracepoint): Initialize target descriptions.
1732 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1734 * tdesc.c (struct tdesc_type): Change return type.
1735 (tdesc_add_flag): Change parameter type.
1736 (tdesc_add_bitfield): Likewise.
1737 (tdesc_add_field): Likewise.
1738 (tdesc_set_struct_size): Likewise.
1740 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1742 * regcache.c (registers_to_string): Remove unused variable.
1744 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1746 * inferiors.c (for_each_inferior_with_data): Remove.
1747 * inferiors.h (for_each_inferior_with_data): Remove.
1748 * server.c (handle_qxfer_threads_worker): Change parameter type.
1749 (handle_qxfer_threads_proper): Use for_each_thread.
1751 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1753 * inferiors.c (for_each_inferior): Remove.
1754 (clear_inferiors): Use for_each_thread.
1755 * inferiors.h (for_each_inferior): Remove.
1756 * linux-low.c (linux_wait_for_event_filtered): Use
1758 (linux_stabilize_threads): Likewise.
1759 * regcache.c (regcache_release): Likewise.
1760 * server.c (gdb_wants_all_threads_stopped): Likewise.
1761 (clear_pending_status_callback): Remove.
1762 (handle_status): Use for_each_thread.
1763 (captured_main): Likewise.
1764 * win32-low.c (child_init_thread_list): Likewise.
1765 (win32_clear_inferiors): Likewise.
1766 (fake_breakpoint_event): Likewise.
1768 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1770 * inferiors.h (find_inferior): Remove.
1771 * inferiors.c (find_inferior): Remove.
1773 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1775 * linux-low.c (resume_status_pending_p): Update comment.
1776 (need_step_over_p): Update comment.
1778 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1780 * linux-low.c (proceed_one_lwp): Return void, change parameter
1782 (unsuspend_and_proceed_one_lwp): Likewise.
1783 (proceed_all_lwps): Use for_each_thread.
1784 (unstop_all_lwps): Likewise.
1786 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1788 * linux-low.c (linux_resume_one_thread): Return void, take
1790 (linux_resume): Use for_each_thread.
1792 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1794 * linux-low.c (send_sigstop_callback): Return void, change
1795 parameter type. Rename to...
1796 (send_sigstop): ... this.
1797 (suspend_and_send_sigstop_callback): Return void, change parameter
1799 (suspend_and_send_sigstop): ... this.
1800 (stop_all_lwps): Use for_each_thread.
1802 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1804 * linux-low.c (lwp_running): Return bool, remove unused
1806 (linux_stabilize_threads): Use find_thread.
1808 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1810 * linux-low.c (select_singlestep_lwp_callback): Remove.
1811 (count_events_callback): Remove.
1812 (select_event_lwp_callback): Remove.
1813 (select_event_lwp): Use find_thread/for_each_thread.
1815 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1817 * linux-low.c (not_stopped_callback): Return bool, take filter
1819 (linux_wait_for_event_filtered): Use find_thread.
1820 (linux_wait_1): Likewise.
1822 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1824 * linux-low.c (same_lwp): Remove.
1825 (find_lwp_pid): Use find_thread.
1827 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1829 * linux-low.c (delete_lwp_callback): Remove.
1830 (linux_mourn): Use for_each_thread.
1832 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1834 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1835 args parameter, don't check for pid.
1836 (linux_detach): Use for_each_thread.
1838 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1840 * linux-low.c (struct counter): Remove.
1841 (second_thread_of_pid_p): Remove.
1842 (last_thread_of_process_p): Use find_thread.
1844 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1846 * inferiors.c (find_inferior_in_random): Remove.
1847 * inferiors.h (find_inferior_in_random): Remove.
1848 * linux-low.c (status_pending_p_callback): Return bool, accept
1849 parameter ptid directly.
1850 (linux_wait_for_event_filtered): Use find_thread_in_random.
1851 (linux_wait_1): Likewise.
1853 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1855 * inferiors.c (find_inferior_id): Remove.
1856 (find_thread_ptid): Move implemention from find_inferior_id to
1858 * inferiors.h (find_inferior_id): Remove.
1859 * server.c (handle_status): Use find_thread_ptid.
1860 (process_serial_event): Likewise.
1861 * thread-db.c (find_one_thread): Likewise.
1862 (thread_db_thread_handle): Likewise.
1863 * win32-low.c (thread_rec): Likewise.
1864 (child_delete_thread): Likewise.
1865 (win32_thread_alive): Likewise.
1866 (get_child_debug_event): Likewise.
1868 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1870 * linux-mips-low.c (update_watch_registers_callback): Return
1871 void, remove pid_p parameter, don't check for pid.
1872 (mips_insert_point, mips_remove_point): Use for_each_thread.
1874 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1876 * lynx.low (lynx_delete_thread_callback): Remove.
1877 (lynx_mourn): Use for_each_thread.
1879 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1881 * regcache.c (regcache_invalidate_one): Remove.
1882 (regcache_invalidate_pid): use for_each_thread.
1884 2017-11-26 Tom Tromey <tom@tromey.com>
1886 * linux-low.c (linux_create_inferior): Update.
1888 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1890 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1892 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1894 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1895 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1896 * linux-aarch64-tdesc-selftest.c: New file.
1897 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1899 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1901 * configure.srv: Add new file.
1902 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1903 * linux-aarch64-tdesc-selftest.c: New file.
1904 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1906 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1908 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1909 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1910 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1912 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1914 * configure.srv: Add new files.
1915 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1916 aarch64_linux_read_description.
1917 * linux-aarch64-low.c (aarch64_linux_read_description):
1918 Merge with aarch64_arch_setup.
1919 (aarch64_arch_setup): Call aarch64_linux_read_description.
1920 * linux-aarch64-tdesc.c: New file.
1921 * linux-aarch64-tdesc.h: New file.
1923 2017-11-24 Yao Qi <yao.qi@linaro.org>
1925 * configure.srv: Set $srv_regobj for tic6x-linux.
1926 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1927 (tic6x_read_description): Move some code to tic6x_arch_setup.
1928 (tic6x_tdesc_test): New function.
1929 (initialize_low_arch): Call selftests::register_test.
1931 2017-11-22 Yao Qi <yao.qi@linaro.org>
1933 * remote-utils.c (prepare_resume_reply): Use memcpy.
1935 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1937 * linux-low.c (kill_one_lwp_callback): Return void, take
1938 argument directly, don't filter on pid.
1939 (linux_kill): Use for_each_thread.
1941 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1943 * linux-low.c (need_step_over_p): Return bool, remove dummy
1945 (linux_resume, proceed_all_lwps): Use find_thread.
1947 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1949 * linux-low.c (resume_status_pending_p): Return bool, remove
1951 (linux_resume): Use find_thread.
1953 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1955 * linux-low.c (struct thread_resume_array): Remove.
1956 (linux_set_resume_request): Return void, take arguments
1958 (linux_resume): Use for_each_thread.
1960 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1962 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1963 return bool, remove data argument.
1964 (linux_stabilize_threads): Use find_thread.
1966 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1968 * linux-low.c (unsuspend_one_lwp): Remove.
1969 (unsuspend_all_lwps): Use for_each_thread, inline code from
1972 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1974 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1975 * linux-low.c (struct iterate_over_lwps_args): Remove.
1976 (iterate_over_lwps_filter): Remove.
1977 (iterate_over_lwps): Use find_thread.
1979 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1981 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1982 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1983 code from reset_lwp_ptrace_options_callback.
1985 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1987 * linux-arm-low.c (struct update_registers_data): Remove.
1988 (update_registers_callback): Return void, take arguments
1989 directly, don't check thread's pid.
1990 (arm_insert_point, arm_remove_point): Use for_each_thread.
1992 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1994 * win32-low.c (continue_one_thread): Return void, take argument
1996 (child_continue): Use for_each_thread.
1998 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
2000 * win32-i386-low.c (update_debug_registers_callback): Rename
2002 (update_debug_registers): ... this, return void, remove pid_p arg.
2003 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
2005 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
2007 * inferiors.h (struct process_info): Add constructor, initialize
2009 <syscalls_to_catch>: Change type to std::vector<int>.
2010 * inferiors.c (add_process): Allocate process_info with new.
2011 (remove_process): Free process_info with delete.
2012 * linux-low.c (handle_extended_wait): Adjust.
2013 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
2014 * server.c (handle_general_set): Adjust.
2016 2017-11-16 Pedro Alves <palves@redhat.com>
2018 * remote-utils.c (remote_close): Block SIGIO signals instead of
2019 uninstalling the SIGIO handler.
2021 2017-11-16 Alan Hayward <alan.hayward@arm.com>
2023 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
2025 2017-11-16 Yao Qi <yao.qi@linaro.org>
2027 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
2028 (tic6x_store_gregset): Likewise.
2029 (tic6x_usrregs_info): Move it up.
2031 2017-11-15 Alan Hayward <alan.hayward@arm.com>
2033 * Makefile.in: Update arch rules.
2034 * configure.srv: Explicitly mark arch/ files.
2036 2017-11-13 Andreas Schwab <schwab@suse.de>
2038 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
2040 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
2042 2017-11-06 Pedro Alves <palves@redhat.com>
2044 * config.in, configure: Regenerate.
2046 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2048 * target.c (struct thread_search): Remove.
2049 (thread_search_callback): Remove.
2050 (prepare_to_access_memory): Use for_each_thread instead of
2051 find_inferior. Inline code from thread_search_callback.
2053 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2055 * server.c (struct visit_actioned_threads_data): Remove.
2056 (visit_actioned_threads): Change prototype to take arguments
2058 (resume): Use find_thread instead of find_inferior.
2060 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
2062 * server.c (queue_stop_reply_callback): Change prototype, return
2064 (find_status_pending_thread_callback): Remove.
2065 (handle_status): Replace find_inferior with find_thread and
2068 2017-10-25 Alan Hayward <alan.hayward@arm.com>
2070 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
2072 (aarch64_store_gregset): Likewise.
2073 (aarch64_fill_fpregset): Likewise.
2074 (aarch64_store_fpregset): Likewise.
2076 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
2078 * gdbthread.h (find_thread, for_each_thread): New functions.
2079 * inferiors.c (thread_of_pid): Remove.
2080 (find_any_thread_of_pid): Use find_thread.
2081 * linux-low.c (num_lwps): Use for_each_thread.
2083 2017-10-17 Yao Qi <yao.qi@linaro.org>
2085 * Makefile.in: Remove one rule.
2086 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
2088 2017-10-17 Yao Qi <yao.qi@linaro.org>
2090 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
2091 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
2093 2017-10-17 Yao Qi <yao.qi@linaro.org>
2095 * configure.srv: Rename arm.o with arch/arm.o.
2097 2017-10-17 Yao Qi <yao.qi@linaro.org>
2099 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
2100 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
2101 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
2102 (arch-i386.o, arch-amd64.o): Remove rules.
2103 (arch/%.o): New rule.
2104 Update POSTCOMPILE and COMPILE.pre.
2105 * configure.ac: Invoke AC_CONFIG_COMMANDS.
2106 * configure: Re-generated.
2107 * configure.srv: Replace arch-i386.o with arch/i386.o.
2108 Replace arch-amd64.o with arch/amd64.o.
2110 2017-10-16 Yao Qi <yao.qi@linaro.org>
2112 * configure: Regenerated.
2114 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2116 * inferiors.h: (struct inferior_list): Remove.
2117 (struct inferior_list_entry); Remove.
2118 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
2119 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
2120 get_first_inferior): Remove.
2121 (for_each_inferior, for_each_inferior_with_data, find_inferior,
2122 find_inferior_id, find_inferior_in_random): Change signature.
2123 * inferiors.c (all_threads): Change type to
2124 std::list<thread_info *>.
2125 (get_thread): Remove macro.
2126 (find_inferior, find_inferior_id): Change signature, implement
2128 (find_inferior_in_random): Change signature, implement using
2129 find_thread_in_random.
2130 (for_each_inferior, for_each_inferior_with_data): Change
2131 signature, implement using for_each_thread.
2132 (add_inferior_to_list, remove_inferior): Remove.
2133 (add_thread, get_first_thread, thread_of_pid,
2134 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
2135 (get_first_inferior, one_inferior_p, clear_inferior_list):
2137 (clear_inferiors, get_thread_process): Update.
2138 * gdbthread.h: Include <list>.
2139 (struct thread_info) <entry>: Remove field.
2141 (all_threads): Change type to std::list<thread_info *>.
2142 (get_first_inferior): Add doc.
2143 (find_thread, for_each_thread, find_thread_in_random): New
2145 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
2146 * linux-arm-low.c (update_registers_callback): Update.
2147 * linux-low.c (second_thread_of_pid_p): Update.
2148 (kill_one_lwp_callback, linux_detach_lwp_callback,
2149 delete_lwp_callback, status_pending_p_callback, same_lwp,
2150 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
2151 iterate_over_lwps, not_stopped_callback,
2152 resume_stopped_resumed_lwps, count_events_callback,
2153 select_singlestep_lwp_callback, select_event_lwp_callback,
2154 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
2155 suspend_and_send_sigstop_callback, wait_for_sigstop,
2156 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
2157 lwp_running, linux_set_resume_request, resume_status_pending_p,
2158 need_step_over_p, start_step_over, linux_resume_one_thread,
2159 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
2160 reset_lwp_ptrace_options_callback): Update.
2161 * linux-mips-low.c (update_watch_registers_callback): Update.
2162 * regcache.c (regcache_invalidate_one, regcache_invalidate):
2164 (free_register_cache_thread_one): Remove.
2165 (regcache_release): Update.
2166 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
2167 handle_qxfer_threads_worker): Update.
2168 (handle_query): Update, use list iterator.
2169 (visit_actioned_threads, handle_pending_status,
2170 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
2171 clear_pending_status_callback, set_pending_status_callback,
2172 find_status_pending_thread_callback, handle_status,
2173 process_serial_event): Update.
2174 * target.c (thread_search_callback): Update.
2175 * thread-db.c (thread_db_get_tls_address): Update.
2176 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
2178 * win32-i386-low.c (update_debug_registers_callback): Update.
2179 * win32-low.c (delete_thread_info, child_delete_thread,
2180 continue_one_thread, suspend_one_thread,
2181 get_child_debug_event): Adjust.
2183 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2185 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
2186 * inferiors.h: Include <list>.
2187 (struct process_info) <entry>: Remove field.
2189 (pid_of): Change macro to function.
2190 (ptid_of, lwpid_of): Remove macro.
2191 (all_processes): Change type to std::list<process_info *>.
2192 (ALL_PROCESSES): Remove macro.
2193 (for_each_process, find_process): New function.
2194 * inferiors.c (all_processes): Change type to
2195 std::list<process_info *>.
2196 (find_thread_process): Adjust.
2197 (add_process): Likewise.
2198 (remove_process): Likewise.
2199 (find_process_pid): Likewise.
2200 (get_first_process): Likewise.
2201 (started_inferior_callback): Remove.
2202 (have_started_inferiors_p): Adjust.
2203 (attached_inferior_callback): Remove.
2204 (have_attached_inferiors_p): Adjust.
2205 * linux-low.c (check_zombie_leaders): Likewise.
2206 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
2207 (x86_linux_update_xmltarget): Adjust.
2208 * server.c (handle_query): Likewise.
2209 (gdb_reattached_process): Remove.
2210 (handle_status): Adjust.
2211 (kill_inferior_callback): Likewise.
2212 (detach_or_kill_inferior): Remove.
2213 (print_started_pid): Likewise.
2214 (print_attached_pid): Likewise.
2215 (detach_or_kill_for_exit): Update.
2216 (process_serial_event): Likewise.
2217 * linux-arm-low.c (arm_new_fork): Likewise.
2219 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2221 * dll.h: Include <list>.
2222 (struct dll_info): Add constructor.
2223 <entry>: Remove field.
2224 (all_dlls): Change type to std::list<dll_info>.
2225 * dll.c: Include <algorithm>.
2226 (get_dll): Remove macro.
2227 (all_dlls): Change type to std::list<dll_info *>.
2228 (free_one_dll): Remove.
2229 (match_dll): Likewise.
2230 (loaded_dll): Adjust.
2231 (unloaded_dll): Adjust to all_dlls type change, use
2232 std::find_if. Inline code from match_dll.
2233 (clear_dlls): Adjust to all_dlls type change.
2234 * server.c (emit_dll_description): Remove.
2235 (handle_qxfer_libraries): Adjust to all_dlls type change,
2236 integrate emit_dll_description's functionality.
2238 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2240 * linux-low.h (struct linux_target_ops) <delete_process>: New
2242 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2243 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2244 (struct linux_target_ops): Add delete_process callback.
2245 * linux-arm-low.c (arm_delete_process): New.
2246 (struct linux_target_ops): Add delete_process callback.
2247 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2248 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2249 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2250 * linux-mips-low.c (mips_linux_delete_process): New.
2251 (struct linux_target_ops): Add delete_process callback.
2252 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2253 * linux-s390-low.c (struct linux_target_ops): Likewise.
2254 * linux-sh-low.c (struct linux_target_ops): Likewise.
2255 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2256 * linux-tile-low.c (struct linux_target_ops): Likewise.
2257 * linux-x86-low.c (x86_linux_delete_process): New.
2258 (struct linux_target_ops): Add delete_process callback.
2259 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2261 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2263 * linux-aarch64-low.c (the_low_target): Add thread delete
2265 * linux-arm-low.c (arm_delete_thread): New function.
2266 (the_low_target): Add thread delete callback.
2267 * linux-bfin-low.c (the_low_target): Likewise.
2268 * linux-crisv32-low.c (the_low_target): Likewise.
2269 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2271 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2273 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2274 * linux-mips-low.c (mips_linux_delete_thread): New function.
2275 (the_low_target): Add thread delete callback.
2276 * linux-ppc-low.c (the_low_target): Likewise.
2277 * linux-s390-low.c (the_low_target): Likewise.
2278 * linux-sh-low.c (the_low_target): Likewise.
2279 * linux-tic6x-low.c (the_low_target): Likewise.
2280 * linux-tile-low.c (the_low_target): Likewise.
2281 * linux-x86-low.c (the_low_target): Likewise.
2282 * linux-xtensa-low.c (the_low_target): Likewise.
2284 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2286 * win32-low.c: Include "common-inferior.h".
2288 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2290 * inferiors.c (set_inferior_cwd): New function.
2291 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2292 (handle_query): Inform that QSetWorkingDir is supported.
2293 * win32-low.c (create_process): Pass the inferior's cwd to
2296 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2298 * inferiors.c (current_inferior_cwd): New global variable.
2299 (get_inferior_cwd): New function.
2300 * inferiors.h (struct process_info) <cwd>: New field.
2302 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2304 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2305 (OBS): Add gdb_tilde_expand.o.
2307 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2309 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2310 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2312 2017-09-29 Pedro Alves <palves@redhat.com>
2314 * ax.c (gdb_parse_agent_expr): Constify.
2315 * ax.h (gdb_parse_agent_expr): Constify.
2316 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2318 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2319 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2320 * remote-utils.h (read_ptid): Constify.
2321 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2322 (process_point_options, process_serial_event): Constify.
2323 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2324 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2325 (cmd_qtbuffer): Constify.
2327 2017-09-29 Pedro Alves <palves@redhat.com>
2329 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2332 2017-09-29 Pedro Alves <palves@redhat.com>
2334 * linux-low.c (handle_extended_wait): Pass parent thread instead
2335 of process to thread_db_notice_clone.
2336 * linux-low.h (thread_db_notice_clone): Replace parent process
2337 parameter with parent thread parameter.
2338 * thread-db.c (find_one_thread): Add comment.
2339 (thread_db_notice_clone): Replace parent process parameter with
2340 parent thread parameter. Temporarily switch to the parent thread.
2342 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2344 * gdbthread.h: Include "common-gdbthread.h".
2345 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2346 "if" when validating the ptid.
2347 * remote-utils.c: Include "gdbthread.h".
2348 (prepare_resume_reply): Use "switch_to_thread".
2349 * target.c (done_accessing_memory): Likewise.
2351 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2353 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2354 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2355 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2356 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2357 s390x-gs-linux64-ipa.o to ipa_obj.
2358 * linux-s390-low.c (HWCAP_S390_GS): New define.
2359 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2361 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2362 (s390_arch_setup): Check for guarded-storage support and choose
2364 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2365 init_registers_s390x_gs_linux64.
2366 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2368 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2369 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2371 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2373 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2375 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2377 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2378 (thread_db_thread_handle): Declare.
2379 * linux-low.c (linux_target_ops): Initialize thread_handle.
2380 * server.c (handle_qxfer_threads_worker): Add support for
2382 * target.h (struct target_ops): Add new function pointer,
2384 (target_thread_handle): Define.
2385 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2387 (thread_db_thread_handle): New function.
2389 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2391 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2392 * linux-low.h (thread_db_notice_clone): Declare.
2393 * thread-db.c (thread_db_notice_clone): New function.
2395 2017-09-21 Pedro Alves <palves@redhat.com>
2397 * server.c (gdb_read_memory, handle_status, process_serial_event)
2398 (handle_serial_event, handle_target_event): Adjust to
2399 set_desired_thread prototype change.
2400 * target.c (set_desired_thread): Remove 'use_general' parameter
2402 * target.h (set_desired_thread): Remove 'use_general' parameter.
2404 2017-09-20 Tom Tromey <tom@tromey.com>
2406 * target.c (target_terminal::terminal_state): Define.
2407 (target_terminal::init): Rename from target_terminal_init.
2408 (target_terminal::inferior): Rename from
2409 target_terminal_inferior.
2410 (target_terminal::ours): Rename from target_terminal_ours.
2411 (target_terminal::ours_for_output, target_terminal::info): New.
2413 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2415 * server.c (accumulate_file_name_length): Remove.
2416 (emit_dll_description): Adjust to std::string change.
2417 (handle_qxfer_libraries): Use std::string to hold document.
2419 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2421 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2422 return type of xml_escape_text.
2423 * server.c (emit_dll_description): Likewise.
2425 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2427 * server.c (captured_main): Accept argument for --selftest.
2428 Update run_tests call.
2429 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2430 when registering selftests.
2432 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2434 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2435 instead of "VEC" for "target_desc.reg_defs".
2436 (regcache_cpy): Likewise.
2437 (registers_to_string): Likewise.
2438 (registers_from_string): Likewise.
2439 (find_regno): Likewise.
2440 (supply_regblock): Likewise.
2441 (regcache_raw_read_unsigned): Likewise.
2442 * tdesc.c (init_target_desc): Likewise.
2443 (tdesc_create_reg): Likewise.
2444 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2445 (struct target_desc) <reg_defs>: Convert to "std::vector".
2446 (target_desc): Do not initialize "reg_defs".
2447 (~target_desc): Update code to use "std::vector" instead of "VEC"
2448 for "target_desc.reg_defs".
2449 (operator==): Likewise.
2451 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2453 * inferiors.h (thread_to_gdb_id): Remove.
2454 * inferiors.c (thread_to_gdb_id): Remove.
2455 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2456 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2457 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2459 * nto-low.c (nto_fetch_registers, nto_store_registers,
2460 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2462 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2464 * inferiors.h (gdb_id_to_thread_id): Remove.
2465 * inferiors.c (gdb_id_to_thread_id): Remove.
2466 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2467 removal. Move pid declaration closer to where it's used.
2469 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2471 * server.c (handle_detach): New function.
2472 (process_serial_event): Move code out, call handle_detach.
2474 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2476 * server.c (require_running): Rename to ...
2477 (require_running_or_return): ... this ...
2478 (require_running_or_break): ... and this.
2479 (handle_query, process_serial_event): Adjust.
2481 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2483 * linux-low.c (linux_set_resume_request): Remove unused
2486 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2488 * server.c (first_thread_of): Remove.
2489 (process_serial_event): Replace usage of first_thread_of with
2490 find_any_thread_of_pid.
2491 * tracepoint.c (same_process_p): Remove.
2492 (gdb_agent_about_to_close): Replace usage of same_process_p with
2493 find_any_thread_of_pid.
2494 * linux-x86-low.c (same_process_callback): Remove.
2495 (x86_arch_setup_process_callback): Replace usage of
2496 same_process_callback with find_any_thread_of_pid.
2497 * thread-db.c (any_thread_of): Remove.
2498 (switch_to_process): Replace usage of any_thread_of with
2499 find_any_thread_of_pid.
2500 * inferiors.c (thread_pid_matches_callback): Remove.
2501 (find_thread_process): Adjust to use find_any_thread_of_pid.
2503 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2505 * regcache.c (get_thread_regcache): Guard calls to "memset"
2508 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2510 * linux-low.c (handle_extended_wait): Use
2511 "allocate_target_description" instead of "XNEW".
2512 * linux-x86-low.c (initialize_low_arch): Likewise.
2514 2017-09-05 Yao Qi <yao.qi@linaro.org>
2516 * configure.srv (srv_i386_regobj): Remove.
2517 (srv_amd64_regobj): Remove.
2518 (srv_regobj): Set it to "" for x86 non-linux targets.
2519 * linux-x86-tdesc.c (i386_linux_read_description):
2520 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2521 (init_registers_i386): Remove the declaration.
2522 (tdesc_i386): Remove the declaration.
2523 (lynx_i386_arch_setup): Call i386_create_target_description.
2524 * nto-x86-low.c: Likewise.
2525 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2526 [!__x86_64__]: include arch/i386.h.
2527 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2529 2017-09-05 Yao Qi <yao.qi@linaro.org>
2531 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2532 i386/amd64-XXX-linux from it.
2534 2017-09-05 Yao Qi <yao.qi@linaro.org>
2536 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2538 (ipa_amd64_linux_regobj): Remove.
2539 (ipa_x32_linux_regobj): Remove.
2541 2017-09-05 Yao Qi <yao.qi@linaro.org>
2543 * Makefile.in (arch-amd64.o): New rule.
2544 * configure.srv: Append arch-amd64.o.
2545 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2546 (get_ipa_tdesc): Call amd64_linux_read_description.
2547 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2548 and init_registers_amd64_XXX.
2549 * linux-x86-low.c (x86_linux_read_description): Call
2550 amd64_linux_read_description.
2551 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2552 (initialize_low_arch): Don't call init_registers_x32_XXX and
2553 init_registers_amd64_XXX.
2554 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2555 and tdesc_amd64_XXX.
2556 [__x86_64__] (amd64_tdesc_test): New function.
2557 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2558 and init_registers_amd64_XXX.
2559 * linux-x86-tdesc.c: Include arch/amd64.h.
2560 (xcr0_to_tdesc_idx): New function.
2561 (i386_linux_read_description): New function.
2562 (amd64_get_ipa_tdesc_idx): New function.
2563 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2564 (amd64_get_ipa_tdesc): Declare.
2566 2017-09-05 Yao Qi <yao.qi@linaro.org>
2568 * configure.srv (srv_i386_linux_xmlfiles): Remove
2569 i386/i386-XXX-linux.xml from it.
2571 2017-09-05 Yao Qi <yao.qi@linaro.org>
2573 * configure.srv: Set srv_i386_linux_regobj empty if $development
2575 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2576 initialize_low_tdesc.
2577 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2578 with #if initialize_low_tdesc.
2579 * linux-x86-tdesc-selftest.c: New file.
2580 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2582 2017-09-05 Yao Qi <yao.qi@linaro.org>
2584 * Makefile.in (arch-i386.o): New rule.
2585 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2586 (x86_64-*-linux*): Likewise.
2587 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2588 include arch/i386.h.
2589 (i386_linux_read_description): Remove code and call
2590 i386_create_target_description.
2591 * tdesc.c (allocate_target_description): New function.
2592 * tdesc.h (set_tdesc_architecture): Remove declaration.
2593 (set_tdesc_osabi): Likewise.
2595 2017-09-05 Yao Qi <yao.qi@linaro.org>
2597 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2598 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2599 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2601 * server.c (get_features_xml): Call tdesc_get_features_xml.
2602 * tdesc.c (set_tdesc_architecture): New function.
2603 (set_tdesc_osabi): New function.
2604 (tdesc_get_features_xml): New function.
2605 (tdesc_create_feature): Add an argument.
2606 * tdesc.h (struct target_desc) <features>: New field.
2607 <arch, osabi>: New field.
2608 (~target_desc): xfree features, arch, and osabi.
2609 (target_desc::oerator==): Don't compare .xmltarget.
2610 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2611 (set_tdesc_osabi): Likewise.
2612 (tdesc_get_features_xml): Likewise.
2614 2017-09-05 Yao Qi <yao.qi@linaro.org>
2616 * linux-x86-tdesc.c: Include selftest.h.
2617 (i386_tdesc_test): New function.
2618 (initialize_low_tdesc): Call selftests::register_test.
2619 * tdesc.h: Include regdef.h.
2620 (target_desc): Override operator == and !=.
2622 2017-09-05 Yao Qi <yao.qi@linaro.org>
2624 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2625 (ipa_obj): Likewise.
2626 * linux-i386-ipa.c: Include common/x86-xstate.h
2627 (get_ipa_tdesc): Call i386_linux_read_description.
2628 (initialize_low_tracepoint): Don't call init_registers_XXX
2629 functions, call initialize_low_tdesc instead.
2630 * linux-x86-low.c (x86_linux_read_description): Call
2631 i386_linux_read_description.
2632 (initialize_low_arch): Don't call init_registers_i386_XXX
2633 functions, call initialize_low_tdesc.
2634 * linux-x86-tdesc.c: New file.
2635 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2636 (i386_get_ipa_tdesc_idx): Declare.
2637 (i386_get_ipa_tdesc): Declare.
2638 (initialize_low_tdesc): Declare.
2640 2017-09-05 Yao Qi <yao.qi@linaro.org>
2642 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2645 2017-09-05 Yao Qi <yao.qi@linaro.org>
2647 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2648 * regcache.c (get_thread_regcache): Use VEC_length.
2649 (init_register_cache): Likewise.
2650 (regcache_cpy): Likewise.
2651 (registers_to_string): Iterate reg_defs via VEC_iterate.
2652 (find_regno): Likewise.
2653 (find_register_by_number): Use VEC_index.
2654 (register_size): Call find_register_by_number.
2655 (register_data): Call find_register_by_number.
2656 (supply_regblock): Use VEC_length.
2657 (regcache_raw_read_unsigned): Likewise.
2658 * tdesc.c (init_target_desc): Iterate reg_defs via
2660 (default_description): Update initializer.
2661 (copy_target_description): Don't update field num_registers.
2662 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2663 <num_registers>: Remove.
2665 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2667 * Makefile.in (.SECONDARY): Define target.
2669 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2671 * linux-low.c (linux_wait_1): Adjust.
2672 * server.c (queue_stop_reply_callback): Adjust.
2674 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2676 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2677 QEnvironmentUnset and QEnvironmentReset packets.
2678 (handle_query): Inform remote that QEnvironmentHexEncoded,
2679 QEnvironmentUnset and QEnvironmentReset are supported.
2681 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2683 * inferiors.h (inferior_target_data): Rename to ...
2684 (thread_target_data): ... this.
2685 (inferior_regcache_data): Rename to ...
2686 (thread_regcache_data): ... this.
2687 (set_inferior_regcache_data): Rename to ...
2688 (set_thread_regcache_data): ... this.
2689 * inferiors.c (inferior_target_data): Rename to ...
2690 (thread_target_data): ... this.
2691 (inferior_regcache_data): Rename to ...
2692 (thread_regcache_data): ... this.
2693 (set_inferior_regcache_data): Rename to ...
2694 (set_thread_regcache_data): ... this.
2695 (free_one_thread): Update.
2696 * linux-low.h (get_thread_lwp): Update.
2697 * regcache.c (get_thread_regcache): Update.
2698 (regcache_invalidate_thread): Update.
2699 (free_register_cache_thread): Update.
2700 * win32-i386-low.c (update_debug_registers_callback): Update.
2701 (win32_get_current_dr): Update.
2702 * win32-low.c (thread_rec): Update.
2703 (delete_thread_info): Update.
2704 (continue_one_thread): Update.
2705 (suspend_one_thread): Update.
2707 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2709 * inferiors.c (set_inferior_target_data): Remove.
2710 * inferiors.h (set_inferior_target_data): Remove.
2712 2017-08-18 Yao Qi <yao.qi@linaro.org>
2714 * Makefile.in (OBS): Add selftest.o.
2715 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2716 * configure, config.in: Re-generated.
2717 * server.c: Include common/sefltest.h.
2718 (captured_main): Handle option --selftest.
2720 2017-08-09 Yao Qi <yao.qi@linaro.org>
2722 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2723 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2724 i386-avx-mpx.o and i386-mmx.o.
2725 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2726 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2727 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2728 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2729 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2730 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2731 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2732 i386/amd64-avx-mpx.xml.
2734 2017-08-09 Yao Qi <yao.qi@linaro.org>
2736 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2737 and x32-avx-avx512.o.
2738 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2739 i386/x32-avx-avx512.xml.
2741 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2743 * tracepoint.h (enum class fast_tpoint_collect_result): New
2745 (fast_tracepoint_collecting): Change return type to
2746 fast_tpoint_collect_result.
2747 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2748 * linux-low.h: Include tracepoint.h.
2749 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2750 fast_tpoint_collect_result.
2751 * linux-low.c (handle_tracepoints): Adjust.
2752 (linux_fast_tracepoint_collecting): Change return type to
2753 fast_tpoint_collect_result.
2754 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2755 linux_wait_1, stuck_in_jump_pad_callback,
2756 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2757 proceed_one_lwp): Adjust to type change.
2759 2017-07-10 Yao Qi <yao.qi@linaro.org>
2761 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2763 2017-06-29 Yao Qi <yao.qi@linaro.org>
2765 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2767 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2769 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2771 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2773 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2775 * linux-low.c (linux_create_inferior): Adjust code to access the
2776 environment information via 'gdb_environ' class.
2777 * lynx-low.c (lynx_create_inferior): Likewise.
2778 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2779 (get_environ): Return a pointer to 'our_environ'.
2780 (captured_main): Initialize 'our_environ'.
2781 * server.h (get_environ): Adjust prototype.
2782 * spu-low.c (spu_create_inferior): Adjust code to access the
2783 environment information via 'gdb_environ' class.
2785 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2787 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2788 usage of "register" keyword.
2790 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2792 * configure: Re-generate.
2794 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2796 * configure: Re-generate.
2798 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2800 * Makefile.in (COMPILE.pre): Add "-x c++".
2802 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2804 * fork-child.c: Conditionally include <signal.h>.
2806 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2808 * server.c (handle_general_set): Handle new packet
2809 "QStartupWithShell".
2810 (handle_query): Add "QStartupWithShell" to the list of supported
2812 (gdbserver_usage): Add help text explaining the
2813 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2815 (captured_main): Recognize and act upon the presence of the new
2818 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2819 Pedro Alves <palves@redhat.com>
2821 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2822 * configure: Regenerate.
2823 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2825 (i[34567]86-*-lynxos*): Likewise.
2826 (spu*-*-*): Likewise.
2827 * fork-child.c: New file.
2828 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2830 (linux_ptrace_fun): New function.
2831 (linux_create_inferior): Adjust function prototype to reflect
2832 change on "target.h". Adjust function code to use
2834 (linux_request_interrupt): Delete "signal_pid".
2835 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2836 (lynx_ptrace_fun): New function.
2837 (lynx_create_inferior): Adjust function prototype to reflect
2838 change on "target.h". Adjust function code to use
2840 * nto-low.c (nto_create_inferior): Adjust function prototype and
2841 code to reflect change on "target.h". Update comments.
2842 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2843 "common-terminal.h" and "environ.h".
2844 (terminal_fd): Moved to fork-child.c.
2845 (old_foreground_pgrp): Likewise.
2846 (restore_old_foreground_pgrp): Likewise.
2847 (last_status): Make it global.
2848 (last_ptid): Likewise.
2849 (our_environ): New variable.
2850 (startup_with_shell): Likewise.
2851 (program_name): Likewise.
2852 (program_argv): Rename to...
2853 (program_args): ...this.
2854 (wrapper_argv): New variable.
2855 (start_inferior): Delete function.
2856 (get_exec_wrapper): New function.
2857 (get_exec_file): Likewise.
2858 (get_environ): Likewise.
2859 (prefork_hook): Likewise.
2860 (post_fork_inferior): Likewise.
2861 (postfork_hook): Likewise.
2862 (postfork_child_hook): Likewise.
2863 (handle_v_run): Update code to deal with arguments coming from the
2864 remote host. Update calls from "start_inferior" to
2866 (captured_main): Likewise. Initialize environment variable. Call
2868 * server.h (post_fork_inferior): New prototype.
2869 (get_environ): Likewise.
2870 (last_status): Declare.
2871 (last_ptid): Likewise.
2872 (signal_pid): Likewise.
2873 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2874 (spu_ptrace_fun): New function.
2875 (spu_create_inferior): Adjust function prototype to reflect change
2876 on "target.h". Adjust function code to use "fork_inferior".
2877 * target.c (target_terminal_init): New function.
2878 (target_terminal_inferior): Likewise.
2879 (target_terminal_ours): Likewise.
2880 * target.h: Include <vector>.
2881 (struct target_ops) <create_inferior>: Update prototype.
2882 (create_inferior): Update macro.
2883 * utils.c (gdb_flush_out_err): New function.
2884 * win32-low.c (win32_create_inferior): Adjust function prototype
2885 and code to reflect change on "target.h".
2887 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2889 * inferiors.c (switch_to_thread): New function.
2891 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2893 * Makefile.in (SFILE): Add "common/job-control.c".
2894 (OBS): Add "job-control.o".
2896 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2898 * Makefile: Remove "@host_makefile_frag@".
2900 2017-05-05 Pedro Alves <palves@redhat.com>
2902 * configure: Regenerate.
2904 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2906 * configure: Regenerate.
2908 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2910 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2911 software_single_step change of return type to
2912 std::vector<CORE_ADDR>.
2913 * linux-low.c (install_software_single_step_breakpoints):
2915 * linux-low.h (install_software_single_step_breakpoints):
2918 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2920 * remote-utils.c: Include "gdb_termios.h" instead of
2922 * terminal.h: Delete file.
2924 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2926 * server.c: Include <vector>.
2927 <program_argv, wrapper_argv>: Convert to std::vector.
2928 (start_inferior): Rewrite function to use C++.
2929 (handle_v_run): Likewise. Update code that calculates the argv
2930 based on the vRun packet; use C++.
2931 (captured_main): Likewise.
2933 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2935 * server.c (handle_v_cont): Initialize thread_resume::thread
2938 2017-04-05 Pedro Alves <palves@redhat.com>
2940 * configure: Regenerate.
2942 2017-04-05 Pedro Alves <palves@redhat.com>
2944 * gdbreplay.c (sync_error): Constify.
2945 * linux-x86-low.c (push_opcode): Constify.
2947 2017-04-05 Pedro Alves <palves@redhat.com>
2949 * win32-low.c (get_child_debug_event)
2950 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2951 Report TARGET_WAITKIND_SPURIOUS instead.
2953 2017-04-05 Pedro Alves <palves@redhat.com>
2955 * remote-utils.c (remote_prepare, remote_open): Constify.
2956 * remote-utils.h (remote_prepare, remote_open): Constify.
2957 * server.c (captured_main): Constify 'port' handling.
2959 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2961 * Makefile.in (clean): Clear .deps.
2963 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2965 * .gitignore: Remove generated files, replace with wildcard.
2966 * (clean): Replace removal of generated files with wildcard.
2967 (version.c): Replace with...
2968 (version-generated.c): ...this.
2969 (xml-builtin.c): Replace with...
2970 (xml-builtin-generated.c): ...this.
2971 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2972 (%.c: *regformats*): Replace with...
2973 (%-generated.c: *regformats*): ...this.
2975 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2977 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2978 (xtensa_fill_gregset): Call collect_register_by_name for
2980 (xtensa_store_gregset): Call supply_register_by_name for
2983 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2985 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2986 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2987 (xtensa_store_gregset): Call supply_register for all registers in
2988 a0_regnum..a0_regnum + C0_NREGS range.
2990 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2992 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2993 (ax-ipa.o: ax.c): Remove.
2994 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2995 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2996 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2997 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2998 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
3000 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3002 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
3003 (print-utils-ipa.o: ../common/print-utils.c): Remove.
3004 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
3005 (errors-ipa.o: ../common/errors.c): Remove.
3006 (format-ipa.o: ../common/format.c): Remove.
3007 (common-utils-ipa.o: ../common/common-utils.c): Remove.
3009 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3011 * Makefile.in (%-ipa.o: %.c): New rule.
3012 (tracepoint-ipa.o: tracepoint.c): Remove.
3013 (utils-ipa.o: utils.c): Remove.
3014 (remote-utils-ipa.o: remote-utils.c): Remove.
3015 (regcache-ipa.o: regcache.c): Remove.
3016 (i386-linux-ipa.o: i386-linux.c): Remove.
3017 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
3018 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
3019 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
3020 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
3021 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
3022 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
3023 (amd64-linux-ipa.o: amd64-linux.c): Remove.
3024 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
3025 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
3026 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
3027 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
3028 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
3029 (aarch64-ipa.o: aarch64.c): Remove.
3030 (s390-linux32-ipa.o: s390-linux32.c): Remove.
3031 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
3032 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
3033 (s390-linux64-ipa.o: s390-linux64.c): Remove.
3034 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
3035 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
3036 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
3037 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
3038 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
3039 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
3040 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
3041 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
3042 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
3043 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
3044 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
3045 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
3046 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
3047 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
3048 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
3049 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
3050 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
3051 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
3052 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
3053 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
3054 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
3055 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
3056 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
3057 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
3058 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
3059 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
3060 (tdesc-ipa.o: tdesc.c): Remove.
3061 (x32-linux-ipa.o: x32-linux.c): Remove.
3062 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
3063 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
3065 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3067 * Makefile.in (%.o: ../arch/%.c): New rule.
3068 (arm.o: ../arch/arm.c): Remove.
3069 (arm-linux.o: ../arch/arm-linux.c): Remove.
3070 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
3071 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
3073 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3075 * Makefile.in (%.o: ../nat/%.c): New rule.
3076 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
3077 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
3078 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
3079 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
3080 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
3081 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
3082 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
3083 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
3084 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
3085 (linux-personality.o: ../nat/linux-personality.c): Remove.
3086 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
3087 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
3088 (x86-linux.o: ../nat/x86-linux.c): Remove.
3089 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
3090 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
3092 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3094 * Makefile.in (%.o: ../common/%.c): New rule.
3095 (signals.o: ../common/signals.c): Remove.
3096 (print-utils.o: ../common/print-utils.c): Remove.
3097 (rsp-low.o: ../common/rsp-low.c): Remove.
3098 (common-utils.o: ../common/common-utils.c): Remove.
3099 (posix-strerror.o: ../common/posix-strerror.c): Remove.
3100 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
3101 (vec.o: ../common/vec.c): Remove.
3102 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
3103 (xml-utils.o: ../common/xml-utils.c): Remove.
3104 (ptid.o: ../common/ptid.c): Remove.
3105 (buffer.o: ../common/buffer.c): Remove.
3106 (format.o: ../common/format.c): Remove.
3107 (filestuff.o: ../common/filestuff.c): Remove.
3108 (agent.o: ../common/agent.c): Remove.
3109 (errors.o: ../common/errors.c): Remove.
3110 (environ.o: ../common/environ.c): Remove.
3111 (common-debug.o: ../common/common-debug.c): Remove.
3112 (cleanups.o: ../common/cleanups.c): Remove.
3113 (common-exceptions.o: ../common/common-exceptions.c): Remove.
3114 (fileio.o: ../common/fileio.c): Remove.
3115 (common-regcache.o: ../common/common-regcache.c): Remove.
3116 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
3117 (new-op.o: ../common/new-op.c): Remove.
3118 (btrace-common.o: ../common/btrace-common.c): Remove.
3120 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3122 * Makefile.in (%.o: ../target/%.c): New rule.
3123 (waitstatus.o: ../target/waitstatus.c): Remove.
3125 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3128 (%.c: ../regformats/%.dat,
3129 (%.c: ../regformats/arm/%.dat,
3130 (%.c: ../regformats/i386/%.dat,
3131 (%.c: ../regformats/rs6000/%.dat): New rules.
3132 (aarch64.c): Remove.
3133 (reg-arm.c): Remove.
3134 (arm-with-iwmmxt.c): Remove.
3135 (arm-with-vfpv2.c): Remove.
3136 (arm-with-vfpv3.c): Remove.
3137 (arm-with-neon.c): Remove.
3138 (reg-bfin.c): Remove.
3139 (reg-cris.c): Remove.
3140 (reg-crisv32.c): Remove.
3142 (i386-linux.c): Remove.
3143 (i386-avx.c): Remove.
3144 (i386-avx-linux.c): Remove.
3145 (i386-avx-avx512.c): Remove.
3146 (i386-avx-avx512-linux.c): Remove.
3147 (i386-mpx.c): Remove.
3148 (i386-mpx-linux.c): Remove.
3149 (i386-avx-mpx-avx512-pku.c): Remove.
3150 (i386-avx-mpx-avx512-pku-linux.c): Remove.
3151 (i386-avx-mpx.c): Remove.
3152 (i386-avx-mpx-linux.c): Remove.
3153 (i386-mmx.c): Remove.
3154 (i386-mmx-linux.c): Remove.
3155 (reg-ia64.c): Remove.
3156 (reg-m32r.c): Remove.
3157 (reg-m68k.c): Remove.
3159 (mips-linux.c): Remove.
3160 (mips-dsp-linux.c): Remove.
3161 (mips64-linux.c): Remove.
3162 (mips64-dsp-linux.c): Remove.
3163 (nios2-linux.c): Remove.
3164 (powerpc-32.c): Remove.
3165 (powerpc-32l.c): Remove.
3166 (powerpc-altivec32l.c): Remove.
3167 (powerpc-cell32l.c): Remove.
3168 (powerpc-vsx32l.c): Remove.
3169 (powerpc-isa205-32l.c): Remove.
3170 (powerpc-isa205-altivec32l.c): Remove.
3171 (powerpc-isa205-vsx32l.c): Remove.
3172 (powerpc-e500l.c): Remove.
3173 (powerpc-64l.c): Remove.
3174 (powerpc-altivec64l.c): Remove.
3175 (powerpc-cell64l.c): Remove.
3176 (powerpc-vsx64l.c): Remove.
3177 (powerpc-isa205-64l.c): Remove.
3178 (powerpc-isa205-altivec64l.c): Remove.
3179 (powerpc-isa205-vsx64l.c): Remove.
3180 (s390-linux32.c): Remove.
3181 (s390-linux32v1.c): Remove.
3182 (s390-linux32v2.c): Remove.
3183 (s390-linux64.c): Remove.
3184 (s390-linux64v1.c): Remove.
3185 (s390-linux64v2.c): Remove.
3186 (s390-te-linux64.c): Remove.
3187 (s390-vx-linux64.c): Remove.
3188 (s390-tevx-linux64.c): Remove.
3189 (s390x-linux64.c): Remove.
3190 (s390x-linux64v1.c): Remove.
3191 (s390x-linux64v2.c): Remove.
3192 (s390x-te-linux64.c): Remove.
3193 (s390x-vx-linux64.c): Remove.
3194 (s390x-tevx-linux64.c): Remove.
3195 (tic6x-c64xp-linux.c): Remove.
3196 (tic6x-c64x-linux.c): Remove.
3197 (tic6x-c62x-linux.c): Remove.
3199 (reg-sparc64.c): Remove.
3200 (reg-spu.c): Remove.
3202 (amd64-linux.c): Remove.
3203 (amd64-avx.c): Remove.
3204 (amd64-avx-linux.c): Remove.
3205 (amd64-avx-avx512.c): Remove.
3206 (amd64-avx-avx512-linux.c): Remove.
3207 (amd64-mpx.c): Remove.
3208 (amd64-mpx-linux.c): Remove.
3209 (amd64-avx-mpx-avx512-pku.c): Remove.
3210 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
3211 (amd64-avx-mpx.c): Remove.
3212 (amd64-avx-mpx-linux.c): Remove.
3214 (x32-linux.c): Remove.
3215 (x32-avx.c): Remove.
3216 (x32-avx-linux.c): Remove.
3217 (x32-avx-avx512.c): Remove.
3218 (x32-avx-avx512-linux.c): Remove.
3219 (reg-xtensa.c): Remove.
3220 (reg-tilegx.c): Remove.
3221 (reg-tilegx32.c): Remove.
3223 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
3225 * Makefile.in (SFILES): Add "common/environ.c".
3226 (OBJS): Add "common/environ.h".
3228 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
3230 * configure.ac: Check if the fs_base and gs_base members of
3231 `struct user_regs_struct' exist.
3232 * config.in: Regenerated.
3233 * configure: Likewise.
3235 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
3237 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3239 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3240 (get_next_pcs_syscall_next_pc): Likewise.
3242 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
3244 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3245 * nto-x86-low.c: Likewise.
3247 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3249 * Makefile.in: Include disable-implicit-rules.mk.
3251 2016-11-23 Pedro Alves <palves@redhat.com>
3253 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3254 (debug_vprintf): Use std::chrono::steady_clock instead of
3255 gettimeofday. Use '.' instead of ':'.
3256 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3257 (get_timestamp): Use std::chrono::steady_clock instead of
3260 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3262 * Makefile.in: Fix whitespace formatting.
3264 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3266 * Makefile.in (SFILES, OBS): Flatten list and order
3269 2016-11-23 Pedro Alves <palves@redhat.com>
3271 * event-loop.c (handle_file_event): Use warning.
3272 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3273 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3276 2016-11-23 Pedro Alves <palves@redhat.com>
3278 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3280 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3281 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3282 debug_printf and debug_flush for debug output.
3283 * server.c (handle_general_set): Likewise.
3284 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3287 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3289 * Makefile.in (.c.o): Replace rule with ...
3290 (%.o: %.c): ... this one.
3292 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3294 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3295 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3297 * configure.ac: Remove checks for the make program.
3298 * configure: Re-generate.
3300 2016-10-28 Pedro Alves <palves@redhat.com>
3302 * Makefile.in (CXX_DIALECT): Get from configure.
3303 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3304 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3305 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3306 * config.in: Regenerate.
3307 * configure: Regenerate.
3309 2016-10-27 Yao Qi <yao.qi@linaro.org>
3311 * linux-low.c (linux_supports_range_stepping): Return true if
3312 can_software_single_step return true.
3314 2016-10-27 Yao Qi <yao.qi@linaro.org>
3316 * inferiors.c (find_inferior_in_random): New function.
3317 * inferiors.h (find_inferior_in_random): Declare.
3318 * linux-low.c (linux_wait_for_event_filtered): Call
3319 find_inferior_in_random instead of find_inferior.
3321 2016-10-27 Yao Qi <yao.qi@linaro.org>
3323 * linux-low.c (linux_wait_1): If single-step breakpoints are
3324 inserted, remove them.
3326 2016-10-26 Pedro Alves <palves@redhat.com>
3328 * linux-low.c (handle_extended_wait): Link parent/child fork
3330 (linux_wait_1): Unlink them.
3331 (linux_set_resume_request): Ignore resume requests for
3332 already-resumed and unhandled fork child threads.
3333 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3334 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3336 (handle_v_requests) <vCont>: Don't call require_running.
3337 * server.h (in_queued_stop_replies): New declaration.
3339 2016-10-24 Yao Qi <yao.qi@linaro.org>
3342 * linux-aarch64-low.c (append_insns): Cast the return value to
3345 2016-10-10 Yao Qi <yao.qi@linaro.org>
3347 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3349 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3351 * target.c (target_supports_multi_process): New function, moved
3353 * target.h (target_supports_multi_process): ... here. Remove
3356 2016-10-05 Tom Tromey <tom@tromey.com>
3359 * tracepoint.c (handle_tracepoint_bkpts): Check
3360 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3362 2016-10-05 Yao Qi <yao.qi@linaro.org>
3364 * configure.srv: Update the path of arm-*.xml files.
3366 2016-10-05 Terry Guo <terry.guo@arm.com>
3367 Yao Qi <yao.qi@linaro.org>
3369 * Makefile.in: Adjust the path of rules.
3370 * configure.srv: Update the path of xml files.
3371 * regformats/arm-with-iwmmxt.dat: Regenerated.
3372 * regformats/arm-with-neon.dat: Likewise.
3373 * regformats/arm-with-vfpv2.dat: Likewise.
3374 * regformats/arm-with-vfpv3.dat Likewise.
3376 2016-09-30 Yao Qi <yao.qi@linaro.org>
3379 * target.c (target_stop_and_wait): Don't call
3380 target_continue_no_signal, use resume_stop instead.
3382 2016-09-26 Yao Qi <yao.qi@linaro.org>
3384 * linux-low.c (linux_wait_1): Call debug_exit.
3386 2016-09-23 Pedro Alves <palves@redhat.com>
3388 * Makefile.in (SFILES): Add common/new-op.c.
3389 (OBS): Add common/new-op.o.
3390 (new-op.o): New rule.
3392 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3394 * .gitinore: Ignore more files.
3396 2016-09-21 Yao Qi <yao.qi@linaro.org>
3398 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3401 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3403 * server.c (start_inferior): Call target_mourn_inferior instead of
3404 mourn_inferior; pass ptid_t argument to it.
3406 (handle_target_event): Likewise.
3407 * target.c (target_mourn_inferior): New function.
3408 * target.h (mourn_inferior): Delete macro.
3410 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3412 * linux-low.c (lwp_is_stepping): New function.
3414 2016-09-06 Carl Love <cel@us.ibm.com>
3416 * server.c (start_inferior): Fixed comment, requested comment change
3417 didn't get updated correctly. Removed reference to ptrace () call as
3418 it is only true on Linux systems.
3420 2016-09-06 Carl Love <cel@us.ibm.com>
3422 * server.c (start_inferior): Do not call
3423 function target_post_create_inferior () if the
3424 inferior process has already exited.
3426 2016-09-05 Pedro Alves <palves@redhat.com>
3428 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3429 (COMPILE.pre, CC_LD): Use CXX directly.
3430 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3431 * acinclude.m4: Don't include build-with-cxx.m4.
3432 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3433 * configure: Regenerate.
3435 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3438 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3439 call writing data to own_buf.
3441 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3443 * target.c (mywait): Call target_wait instead of
3445 (target_wait): New function.
3447 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3449 * server.c (start_inferior): New variable 'ptid'. Replace calls
3450 to the_target->resume by target_continue{,_no_signal}, depending
3452 * target.c (target_stop_and_wait): Call target_continue_no_signal
3453 instead of the_target->resume.
3454 (target_continue): New function.
3456 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3458 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3460 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3463 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3465 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3466 * linux-arm-low.c (ps_get_thread_area): Likewise.
3467 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3468 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3469 * linux-mips-low.c (ps_get_thread_area): Likewise.
3470 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3471 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3472 * linux-x86-low.c (ps_get_thread_area): Likewise.
3473 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3475 2016-08-19 Pedro Alves <palves@redhat.com>
3477 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3479 2016-08-19 Pedro Alves <palves@redhat.com>
3481 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3482 comment. Use memcpy instead of casting through unsigned long.
3484 2016-08-19 Pedro Alves <palves@redhat.com>
3486 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3487 allocating around 0x80000000.
3489 2016-08-19 Pedro Alves <palves@redhat.com>
3492 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3493 (x32-avx512-linux-ipa.o): New rules.
3494 * configure.ac (x86_64-*-linux*): New x32 check.
3495 * configure.srv (ipa_x32_linux_regobj): New.
3496 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3497 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3499 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3501 * configure: Regenerate.
3503 2016-08-09 Pedro Alves <palves@redhat.com>
3506 * Makefile.in (OBS): Add signals-state-save-restore.o.
3507 (signals-state-save-restore.o): New rule.
3508 * config.in: Regenerate.
3509 * configure: Regenerate.
3510 * linux-low.c: Include "signals-state-save-restore.h".
3511 (linux_create_inferior): Call
3512 restore_original_signals_state.
3513 * server.c: Include "dispositions-save-restore.h".
3514 (captured_main): Call save_original_signals_state.
3516 2016-08-05 Pedro Alves <palves@redhat.com>
3518 * configure: Regenerate.
3520 2016-08-04 Yao Qi <yao.qi@linaro.org>
3522 * linux-low.c (regsets_fetch_inferior_registers): Check
3523 errno is ESRCH or not.
3525 2016-08-02 Yao Qi <yao.qi@linaro.org>
3527 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3528 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3529 (thread_db_load_search): Update.
3530 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3531 td_ta_set_event and td_ta_event_getmsg.
3533 2016-07-26 Pedro Alves <palves@redhat.com>
3536 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3537 of unsigned long for 64-bit registers and use uint32_t instead of
3538 unsigned int for 32-bit registers.
3540 2016-07-26 Pedro Alves <palves@redhat.com>
3542 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3545 2016-07-21 Tom Tromey <tom@tromey.com>
3547 * configure: Rebuild.
3549 2016-07-21 Yao Qi <yao.qi@linaro.org>
3551 * mem-break.c (find_gdb_breakpoint): Cast bp to
3552 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3554 2016-07-21 Yao Qi <yao.qi@linaro.org>
3556 * server.c (handle_v_requests): Support s and S actions
3557 if target_supports_software_single_step return true.
3559 2016-07-21 Yao Qi <yao.qi@linaro.org>
3561 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3562 is resume_step, call maybe_hw_step.
3563 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3565 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3567 (proceed_one_lwp): If resume request is resume_step, install
3568 reinsert breakpoints and call maybe_hw_step.
3570 2016-07-21 Yao Qi <yao.qi@linaro.org>
3572 * linux-low.c (proceed_one_lwp): Declare.
3573 (linux_resume_one_thread): Remove local variable 'step'.
3574 Lift code enqueue signal. Call proceed_one_lwp instead of
3575 linux_resume_one_lwp.
3577 2016-07-21 Yao Qi <yao.qi@linaro.org>
3579 * linux-low.c (linux_resume_one_thread): Call
3580 enqueue_pending_signal.
3582 2016-07-21 Yao Qi <yao.qi@linaro.org>
3584 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3585 * inferiors.c (do_restore_current_thread_cleanup): New function.
3586 (make_cleanup_restore_current_thread): Likewise.
3587 * linux-low.c (install_software_single_step_breakpoints): Call
3588 make_cleanup_restore_current_thread. Switch current_thread to
3591 2016-07-21 Yao Qi <yao.qi@linaro.org>
3593 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3594 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3595 (clone_one_breakpoint): Likewise.
3596 (delete_reinsert_breakpoints): Change parameter to thread.
3598 (has_reinsert_breakpoints): Likewise.
3599 (uninsert_reinsert_breakpoints): Likewise.
3600 (reinsert_reinsert_breakpoints): Likewise.
3601 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3602 (delete_reinsert_breakpoints): Likewise.
3603 (reinsert_reinsert_breakpoints): Likewise.
3604 (uninsert_reinsert_breakpoints): Likewise.
3605 (has_reinsert_breakpoints): Likewise.
3607 2016-07-21 Yao Qi <yao.qi@linaro.org>
3609 * inferiors.c (get_thread_process): Make parameter const.
3610 * inferiors.h (get_thread_process): Update declaration.
3611 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3612 Add new parameters child_thread and parent_thread. Callers
3614 * mem-break.h (clone_all_breakpoints): Update declaration.
3616 2016-07-21 Yao Qi <yao.qi@linaro.org>
3618 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3619 <command_list, handler>: Remove.
3620 (struct gdb_breakpoint): New.
3621 (struct other_breakpoint): New.
3622 (struct reinsert_breakpoint): New.
3623 (is_gdb_breakpoint): New function.
3624 (any_persistent_commands): Update command_list if
3625 is_gdb_breakpoint returns true.
3626 (set_breakpoint): Create breakpoints according to their types.
3627 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3628 (set_gdb_breakpoint_1): Likewise.
3629 (set_gdb_breakpoint): Likewise.
3630 (clear_breakpoint_conditions): Change parameter type to
3631 'struct gdb_breakpoint *'.
3632 (clear_breakpoint_commands): Likewise.
3633 (clear_breakpoint_conditions_and_commands): Likewise.
3634 (add_condition_to_breakpoint): Likewise.
3635 (add_breakpoint_condition): Likewise.
3636 (add_commands_to_breakpoint): Likewise.
3637 (check_breakpoints): Check other_breakpoint.
3638 (clone_one_breakpoint): Clone breakpopint according to its type.
3639 * mem-break.h (struct gdb_breakpoint): Declare.
3640 (set_gdb_breakpoint): Update declaration.
3641 (clear_breakpoint_conditions_and_commands): Likewise.
3642 (add_breakpoint_condition): Likewise.
3643 (add_breakpoint_commands): Likewise.
3644 * server.c (process_point_options): Change parameter type to
3645 'struct gdb_breakpoint *'.
3647 2016-07-21 Yao Qi <yao.qi@linaro.org>
3649 * mem-break.c (set_breakpoint_at): Rename it to ...
3650 (set_breakpoint_type_at): ... it.
3651 (set_breakpoint_at): Call set_breakpoint_type_at.
3652 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3653 * mem-break.h (set_breakpoint_at): Update comments.
3655 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3657 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3659 (nios2_store_gregset): Likewise.
3661 2016-07-01 Pedro Alves <palves@redhat.com>
3662 Antoine Tremblay <antoine.tremblay@ericsson.com>
3664 * linux-low.c: Change interface to take the target lwp_info
3665 pointer directly and return void. Handle detaching from a zombie
3667 (linux_detach_lwp_callback): New function.
3668 (linux_detach): Detach from the leader thread after detaching from
3671 2016-06-28 Yao Qi <yao.qi@linaro.org>
3673 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3674 for variable new_offset.
3675 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3676 (aarch64_ftrace_insn_reloc_cb): Likewise.
3677 (aarch64_ftrace_insn_reloc_tb): Likewise.
3678 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3679 PRIx64 instead of PRIx32.
3681 2016-06-28 Yao Qi <yao.qi@linaro.org>
3683 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3684 (the_low_target): Install arm_get_syscall_trapinfo.
3686 2016-06-28 Yao Qi <yao.qi@linaro.org>
3688 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3690 (the_low_target): Install aarch64_get_syscall_trapinfo.
3692 2016-06-28 Yao Qi <yao.qi@linaro.org>
3694 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3696 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3697 Remove parameter sysno.
3698 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3701 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3703 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3704 (s390_emit_ne_goto): Likewise.
3705 (s390_emit_lt_goto): Likewise.
3706 (s390_emit_le_goto): Likewise.
3707 (s390_emit_gt_goto): Likewise.
3708 (s390_emit_ge_goto): Likewise.
3709 (s390x_emit_eq_goto): Likewise.
3710 (s390x_emit_ne_goto): Likewise.
3711 (s390x_emit_lt_goto): Likewise.
3712 (s390x_emit_le_goto): Likewise.
3713 (s390x_emit_gt_goto): Likewise.
3714 (s390x_emit_ge_goto): Likewise.
3715 (s390_emit_ops_impl): Mark variable static.
3716 (s390x_emit_ops): Likewise.
3718 2016-06-17 Yao Qi <yao.qi@linaro.org>
3720 * linux-low.c (handle_extended_wait): Call
3721 uninsert_reinsert_breakpoints for the parent process. Remove
3722 reinsert breakpoints from the child process. Reinsert them to
3723 the parent process when vfork is done.
3724 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3725 (reinsert_reinsert_breakpoints): New function.
3726 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3727 (reinsert_reinsert_breakpoints): Declare.
3729 2016-06-17 Yao Qi <yao.qi@linaro.org>
3731 * linux-low.c (handle_extended_wait): If the parent is doing
3732 step-over, remove the reinsert breakpoints from the forked child.
3734 2016-06-17 Yao Qi <yao.qi@linaro.org>
3736 * linux-low.c (unsuspend_all_lwps): Declare.
3737 (linux_low_filter_event): If thread exited, call finish_step_over.
3738 If step-over is finished, unsuspend other threads.
3740 2016-06-17 Yao Qi <yao.qi@linaro.org>
3742 * linux-low.c (linux_resume_one_lwp_throw): Assert
3743 has_reinsert_breakpoints returns false.
3744 * mem-break.c (delete_disabled_breakpoints): Assert
3745 bp type isn't reinsert_breakpoint.
3747 2016-06-17 Yao Qi <yao.qi@linaro.org>
3749 * linux-low.c (maybe_hw_step): New function.
3750 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3751 (finish_step_over): Switch current_thread to lwp temporarily,
3752 and assert has_reinsert_breakpoints returns true.
3753 (proceed_one_lwp): Call maybe_hw_step.
3754 * mem-break.c (has_reinsert_breakpoints): New function.
3755 * mem-break.h (has_reinsert_breakpoints): Declare.
3757 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3759 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3761 2016-05-17 Yao Qi <yao.qi@linaro.org>
3763 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3764 instead of find_inferior.
3766 2016-05-05 Yao Qi <yao.qi@linaro.org>
3768 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3769 Initialize res to zero.
3771 2016-05-05 Yao Qi <yao.qi@linaro.org>
3773 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3776 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3778 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3779 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3780 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3782 2016-04-28 Par Olsson <par.olsson@windriver.com>
3783 Simon Marchi <simon.marchi@ericsson.com>
3785 * tracepoint.c (write_inferior_int8): New function.
3786 (cmd_qtenable_disable): Write enable flag using
3787 write_inferior_int8.
3789 2016-04-25 Yao Qi <yao.qi@linaro.org>
3791 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3792 (need_step_over_p): Return zero if the LWP has pending signals
3793 can be delivered on software single step target.
3795 2016-04-25 Yao Qi <yao.qi@linaro.org>
3797 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3798 return instead of error.
3800 2016-04-22 Yao Qi <yao.qi@linaro.org>
3802 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3805 2016-04-22 Yao Qi <yao.qi@linaro.org>
3807 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3808 signal when stepping over breakpoint with software single
3811 2016-04-21 Pedro Alves <palves@redhat.com>
3813 * linux-s390-low.c (s390_collect_ptrace_register)
3814 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3816 (s390_check_regset): Use void * instead of gdb_byte *.
3818 2016-04-20 Pedro Alves <palves@redhat.com>
3820 * configure: Renegerate.
3822 2016-04-20 Yao Qi <yao.qi@linaro.org>
3824 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3825 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3827 (arm_store_gregset): Likewise.
3829 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3831 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3832 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3833 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3834 (amd64-avx-mpx-linux.c): New rules.
3835 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3836 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3837 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3838 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3839 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3840 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3841 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3842 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3843 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3844 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3845 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3846 * linux-x86-low.c (x86_linux_read_description): Add case for
3847 X86_XSTATE_AVX_MPX_MASK.
3848 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3849 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3850 init_registers_i386_avx_mpx_linux.
3851 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3852 (initialize_low_tracepoint): Call
3853 init_registers_i386_avx_mpx_linux.
3854 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3855 (initialize_low_tracepoint): Call
3856 init_registers_amd64_avx_mpx_linux.
3857 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3858 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3859 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3862 2016-04-18 Pedro Alves <palves@redhat.com>
3864 * configure: Regenerate.
3866 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3868 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3869 (aarch64_emit_sub): Likewise.
3871 2016-04-12 Pedro Alves <palves@redhat.com>
3873 * utils.c (prepare_to_throw_exception): Delete.
3875 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3877 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3879 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3881 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3883 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3885 * linux-aarch64-ipa.c: Add <elf.h> include.
3886 * linux-ppc-ipa.c: Add <elf.h> include.
3887 * linux-s390-ipa.c: Add <elf.h> include.
3889 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3891 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3892 (get_raw_reg_ptr): Likewise.
3893 (get_trace_state_variable_value_ptr): Likewise.
3894 (set_trace_state_variable_value_ptr): Likewise.
3895 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3898 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3899 Marcin Kościelnicki <koriakin@0x04.net>
3902 * linux-ppc-low.c (emit_insns): New function.
3903 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3904 (ppc_emit_prologue): New function.
3905 (ppc_emit_epilogue): New function.
3906 (ppc_emit_add): New function.
3907 (ppc_emit_sub): New function.
3908 (ppc_emit_mul): New function.
3909 (ppc_emit_lsh): New function.
3910 (ppc_emit_rsh_signed): New function.
3911 (ppc_emit_rsh_unsigned): New function.
3912 (ppc_emit_ext): New function.
3913 (ppc_emit_zero_ext): New function.
3914 (ppc_emit_log_not): New function.
3915 (ppc_emit_bit_and): New function.
3916 (ppc_emit_bit_or): New function.
3917 (ppc_emit_bit_xor): New function.
3918 (ppc_emit_bit_not): New function.
3919 (ppc_emit_equal): New function.
3920 (ppc_emit_less_signed): New function.
3921 (ppc_emit_less_unsigned): New function.
3922 (ppc_emit_ref): New function.
3923 (ppc_emit_const): New function.
3924 (ppc_emit_reg): New function.
3925 (ppc_emit_pop): New function.
3926 (ppc_emit_stack_flush): New function.
3927 (ppc_emit_swap): New function.
3928 (ppc_emit_stack_adjust): New function.
3929 (ppc_emit_call): New function.
3930 (ppc_emit_int_call_1): New function.
3931 (ppc_emit_void_call_2): New function.
3932 (ppc_emit_if_goto): New function.
3933 (ppc_emit_goto): New function.
3934 (ppc_emit_eq_goto): New function.
3935 (ppc_emit_ne_goto): New function.
3936 (ppc_emit_lt_goto): New function.
3937 (ppc_emit_le_goto): New function.
3938 (ppc_emit_gt_goto): New function.
3939 (ppc_emit_ge_goto): New function.
3940 (ppc_write_goto_address): New function.
3941 (ppc_emit_ops_impl): New static variable.
3942 (ppc64v1_emit_prologue): New function.
3943 (ppc64v2_emit_prologue): New function.
3944 (ppc64_emit_epilogue): New function.
3945 (ppc64_emit_add): New function.
3946 (ppc64_emit_sub): New function.
3947 (ppc64_emit_mul): New function.
3948 (ppc64_emit_lsh): New function.
3949 (ppc64_emit_rsh_signed): New function.
3950 (ppc64_emit_rsh_unsigned): New function.
3951 (ppc64_emit_ext): New function.
3952 (ppc64_emit_zero_ext): New function.
3953 (ppc64_emit_log_not): New function.
3954 (ppc64_emit_bit_and): New function.
3955 (ppc64_emit_bit_or): New function.
3956 (ppc64_emit_bit_xor): New function.
3957 (ppc64_emit_bit_not): New function.
3958 (ppc64_emit_equal): New function.
3959 (ppc64_emit_less_signed): New function.
3960 (ppc64_emit_less_unsigned): New function.
3961 (ppc64_emit_ref): New function.
3962 (ppc64_emit_const): New function.
3963 (ppc64v1_emit_reg): New function.
3964 (ppc64v2_emit_reg): New function.
3965 (ppc64_emit_pop): New function.
3966 (ppc64_emit_stack_flush): New function.
3967 (ppc64_emit_swap): New function.
3968 (ppc64v1_emit_call): New function.
3969 (ppc64v2_emit_call): New function.
3970 (ppc64v1_emit_int_call_1): New function.
3971 (ppc64v2_emit_int_call_1): New function.
3972 (ppc64v1_emit_void_call_2): New function.
3973 (ppc64v2_emit_void_call_2): New function.
3974 (ppc64_emit_if_goto): New function.
3975 (ppc64_emit_eq_goto): New function.
3976 (ppc64_emit_ne_goto): New function.
3977 (ppc64_emit_lt_goto): New function.
3978 (ppc64_emit_le_goto): New function.
3979 (ppc64_emit_gt_goto): New function.
3980 (ppc64_emit_ge_goto): New function.
3981 (ppc64v1_emit_ops_impl): New static variable.
3982 (ppc64v2_emit_ops_impl): New static variable.
3983 (ppc_emit_ops): New function.
3984 (linux_low_target): Wire in ppc_emit_ops.
3986 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3987 Marcin Kościelnicki <koriakin@0x04.net>
3990 * Makefile.in: Add powerpc-*-ipa.o
3991 * configure.srv: Add ipa_obj for powerpc*-linux.
3992 * linux-ppc-ipa.c: New file.
3993 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3995 (PPC_FIELD): New macro.
3996 (PPC_SEXT): New macro.
3997 (PPC_OP6): New macro.
3998 (PPC_BO): New macro.
3999 (PPC_LI): New macro.
4000 (PPC_BD): New macro.
4001 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
4002 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
4003 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
4004 (ppc_get_thread_area): New function.
4005 (is_elfv2_inferior): New function.
4006 (gen_ds_form): New function.
4007 (GEN_STD): New macro.
4008 (GEN_STDU): New macro.
4009 (GEN_LD): New macro.
4010 (GEN_LDU): New macro.
4011 (gen_d_form): New function.
4012 (GEN_ADDI): New macro.
4013 (GEN_ADDIS): New macro.
4014 (GEN_LI): New macro.
4015 (GEN_LIS): New macro.
4016 (GEN_ORI): New macro.
4017 (GEN_ORIS): New macro.
4018 (GEN_LWZ): New macro.
4019 (GEN_STW): New macro.
4020 (GEN_STWU): New macro.
4021 (gen_xfx_form): New function.
4022 (GEN_MFSPR): New macro.
4023 (GEN_MTSPR): New macro.
4024 (GEN_MFCR): New macro.
4025 (GEN_MTCR): New macro.
4026 (GEN_SYNC): New macro.
4027 (GEN_LWSYNC): New macro.
4028 (gen_x_form): New function.
4029 (GEN_OR): New macro.
4030 (GEN_MR): New macro.
4031 (GEN_LWARX): New macro.
4032 (GEN_STWCX): New macro.
4033 (GEN_CMPW): New macro.
4034 (gen_md_form): New function.
4035 (GEN_RLDICL): New macro.
4036 (GEN_RLDICR): New macro.
4037 (gen_i_form): New function.
4039 (GEN_BL): New macro.
4040 (gen_b_form): New function.
4041 (GEN_BNE): New macro.
4042 (GEN_LOAD): New macro.
4043 (GEN_STORE): New macro.
4044 (gen_limm): New function.
4045 (gen_atomic_xchg): New function.
4046 (gen_call): New function.
4047 (ppc_relocate_instruction): New function.
4048 (ppc_install_fast_tracepoint_jump_pad): New function.
4049 (ppc_get_min_fast_tracepoint_insn_len): New function.
4050 (ppc_get_ipa_tdesc_idx): New function.
4051 (the_low_target): Wire in the new functions.
4052 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
4054 * linux-ppc-tdesc.h: New file.
4056 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
4058 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
4059 (alloc_jump_pad_buffer): New function.
4060 * linux-amd64-ipa.c: Add <sys/mman.h> include.
4061 (alloc_jump_pad_buffer): New function.
4062 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
4063 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
4064 (alloc_jump_pad_buffer): New function.
4065 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
4066 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
4067 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
4068 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
4070 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
4072 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
4073 * linux-amd64-ipa.c: Likewise.
4074 * linux-i386-ipa.c: Likewise.
4075 * linux-s390-ipa.c: Likewise.
4076 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
4077 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
4078 set_trace_state_variable_value_ptr.
4079 (struct ipa_sym_addresses): Likewise.
4080 (symbol_list): Likewise.
4081 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
4082 accessing gdb_collect directly.
4083 (gdb_collect_ptr_type): New typedef.
4084 (get_raw_reg_ptr_type): New typedef.
4085 (get_trace_state_variable_value_ptr_type): New typedef.
4086 (set_trace_state_variable_value_ptr_type): New typedef.
4087 (gdb_collect_ptr): New global.
4088 (get_raw_reg_ptr): New global.
4089 (get_trace_state_variable_value_ptr): New global.
4090 (set_trace_state_variable_value_ptr): New global.
4091 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
4092 accessing get_raw_reg directly.
4093 (get_get_tsv_func_addr): Likewise for
4094 get_trace_state_variable_value_ptr.
4095 (get_set_tsv_func_addr): Likewise for
4096 set_trace_state_variable_value_ptr.
4097 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
4099 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
4101 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
4103 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
4105 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
4107 (relocate_instruction): Remove own_buf.
4108 * server.c (own_buf): Make global.
4109 (handle_v_requests): Make global.
4110 * server.h (own_buf): New declaration.
4111 (handle_v_requests): New prototype.
4113 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4116 * linux-s390-low.c (add_insns): New function.
4117 (s390_emit_prologue): New function.
4118 (s390_emit_epilogue): New function.
4119 (s390_emit_add): New function.
4120 (s390_emit_sub): New function.
4121 (s390_emit_mul): New function.
4122 (s390_emit_lsh): New function.
4123 (s390_emit_rsh_signed): New function.
4124 (s390_emit_rsh_unsigned): New function.
4125 (s390_emit_ext): New function.
4126 (s390_emit_log_not): New function.
4127 (s390_emit_bit_and): New function.
4128 (s390_emit_bit_or): New function.
4129 (s390_emit_bit_xor): New function.
4130 (s390_emit_bit_not): New function.
4131 (s390_emit_equal): New function.
4132 (s390_emit_less_signed): New function.
4133 (s390_emit_less_unsigned): New function.
4134 (s390_emit_ref): New function.
4135 (s390_emit_if_goto): New function.
4136 (s390_emit_goto): New function.
4137 (s390_write_goto_address): New function.
4138 (s390_emit_litpool): New function.
4139 (s390_emit_const): New function.
4140 (s390_emit_call): New function.
4141 (s390_emit_reg): New function.
4142 (s390_emit_pop): New function.
4143 (s390_emit_stack_flush): New function.
4144 (s390_emit_zero_ext): New function.
4145 (s390_emit_swap): New function.
4146 (s390_emit_stack_adjust): New function.
4147 (s390_emit_set_r2): New function.
4148 (s390_emit_int_call_1): New function.
4149 (s390_emit_void_call_2): New function.
4150 (s390_emit_eq_goto): New function.
4151 (s390_emit_ne_goto): New function.
4152 (s390_emit_lt_goto): New function.
4153 (s390_emit_le_goto): New function.
4154 (s390_emit_gt_goto): New function.
4155 (s390_emit_ge_goto): New function.
4156 (s390x_emit_prologue): New function.
4157 (s390x_emit_epilogue): New function.
4158 (s390x_emit_add): New function.
4159 (s390x_emit_sub): New function.
4160 (s390x_emit_mul): New function.
4161 (s390x_emit_lsh): New function.
4162 (s390x_emit_rsh_signed): New function.
4163 (s390x_emit_rsh_unsigned): New function.
4164 (s390x_emit_ext): New function.
4165 (s390x_emit_log_not): New function.
4166 (s390x_emit_bit_and): New function.
4167 (s390x_emit_bit_or): New function.
4168 (s390x_emit_bit_xor): New function.
4169 (s390x_emit_bit_not): New function.
4170 (s390x_emit_equal): New function.
4171 (s390x_emit_less_signed): New function.
4172 (s390x_emit_less_unsigned): New function.
4173 (s390x_emit_ref): New function.
4174 (s390x_emit_if_goto): New function.
4175 (s390x_emit_const): New function.
4176 (s390x_emit_call): New function.
4177 (s390x_emit_reg): New function.
4178 (s390x_emit_pop): New function.
4179 (s390x_emit_stack_flush): New function.
4180 (s390x_emit_zero_ext): New function.
4181 (s390x_emit_swap): New function.
4182 (s390x_emit_stack_adjust): New function.
4183 (s390x_emit_int_call_1): New function.
4184 (s390x_emit_void_call_2): New function.
4185 (s390x_emit_eq_goto): New function.
4186 (s390x_emit_ne_goto): New function.
4187 (s390x_emit_lt_goto): New function.
4188 (s390x_emit_le_goto): New function.
4189 (s390x_emit_gt_goto): New function.
4190 (s390x_emit_ge_goto): New function.
4191 (s390_emit_ops): New function.
4192 (struct linux_target_ops): Fill in emit_ops hook.
4194 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4197 * Makefile.in: Add s390 IPA files.
4198 * configure.srv: Build IPA for s390.
4199 * linux-s390-ipa.c: New file.
4200 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
4201 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
4202 (tdesc_s390_linux32): Likewise.
4203 (init_registers_s390_linux32v1): Likewise.
4204 (tdesc_s390_linux32v1): Likewise.
4205 (init_registers_s390_linux32v2): Likewise.
4206 (tdesc_s390_linux32v2): Likewise.
4207 (init_registers_s390_linux64): Likewise.
4208 (tdesc_s390_linux64): Likewise.
4209 (init_registers_s390_linux64v1): Likewise.
4210 (tdesc_s390_linux64v1): Likewise.
4211 (init_registers_s390_linux64v2): Likewise.
4212 (tdesc_s390_linux64v2): Likewise.
4213 (init_registers_s390_te_linux64): Likewise.
4214 (tdesc_s390_te_linux64): Likewise.
4215 (init_registers_s390_vx_linux64): Likewise.
4216 (tdesc_s390_vx_linux64): Likewise.
4217 (init_registers_s390_tevx_linux64): Likewise.
4218 (tdesc_s390_tevx_linux64): Likewise.
4219 (init_registers_s390x_linux64): Likewise.
4220 (tdesc_s390x_linux64): Likewise.
4221 (init_registers_s390x_linux64v1): Likewise.
4222 (tdesc_s390x_linux64v1): Likewise.
4223 (init_registers_s390x_linux64v2): Likewise.
4224 (tdesc_s390x_linux64v2): Likewise.
4225 (init_registers_s390x_te_linux64): Likewise.
4226 (tdesc_s390x_te_linux64): Likewise.
4227 (init_registers_s390x_vx_linux64): Likewise.
4228 (tdesc_s390x_vx_linux64): Likewise.
4229 (init_registers_s390x_tevx_linux64): Likewise.
4230 (tdesc_s390x_tevx_linux64): Likewise.
4231 (have_hwcap_s390_vx): New static variable.
4232 (s390_arch_setup): Fill have_hwcap_s390_vx.
4233 (s390_get_thread_area): New function.
4234 (s390_ft_entry_gpr_esa): New const.
4235 (s390_ft_entry_gpr_zarch): New const.
4236 (s390_ft_entry_misc): New const.
4237 (s390_ft_entry_fr): New const.
4238 (s390_ft_entry_vr): New const.
4239 (s390_ft_main_31): New const.
4240 (s390_ft_main_64): New const.
4241 (s390_ft_exit_fr): New const.
4242 (s390_ft_exit_vr): New const.
4243 (s390_ft_exit_misc): New const.
4244 (s390_ft_exit_gpr_esa): New const.
4245 (s390_ft_exit_gpr_zarch): New const.
4246 (append_insns): New function.
4247 (s390_relocate_instruction): New function.
4248 (s390_install_fast_tracepoint_jump_pad): New function.
4249 (s390_get_min_fast_tracepoint_insn_len): New function.
4250 (s390_get_ipa_tdesc_idx): New function.
4251 (struct linux_target_ops): Wire in the above functions.
4252 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4253 * linux-s390-tdesc.h: New file.
4255 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4257 * linux-s390-low.c (s390_supports_tracepoints): New function.
4258 (struct linux_target_ops): Fill supports_tracepoints hook.
4260 2016-03-18 Yao Qi <yao.qi@linaro.org>
4262 * linux-low.c (lwp_signal_can_be_delivered): New function.
4263 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4265 2016-03-18 Yao Qi <yao.qi@linaro.org>
4267 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4268 0 if signal is enqueued. Remove 'signal' from one debugging
4269 message. Move one debugging message to some lines below.
4270 Remove code setting 'signal' to 0.
4272 2016-03-18 Yao Qi <yao.qi@linaro.org>
4274 * linux-low.c (linux_low_filter_event): Remove redundant
4275 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4277 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4279 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4280 (struct linux_target_ops): Wire in the above.
4282 2016-03-03 Yao Qi <yao.qi@linaro.org>
4284 * linux-low.c: Update comments to start_step_over.
4286 2016-03-03 Yao Qi <yao.qi@linaro.org>
4289 * linux-low.c (handle_extended_wait): Set child suspended
4290 if event_lwp->bp_reinsert isn't zero.
4292 2016-03-02 Yao Qi <yao.qi@linaro.org>
4294 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4295 enqueue_pending_signal.
4297 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4299 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4302 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4304 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4305 (s390_regmap_3264) [!__s390x__]: New global.
4306 (s390_collect_ptrace_register): Skip map entries containing -1.
4307 (s390_supply_ptrace_register): Ditto.
4308 (s390_fill_gprs_high): New function.
4309 (s390_store_gprs_high): New function.
4310 (s390_regsets): Add NT_S390_HIGH_GPRS.
4311 (s390_get_hwcap): Enable on 31-bit.
4312 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4313 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4314 Detect NT_S390_HIGH_GPRS.
4315 (s390_usrregs_info_3264): Enable on 31-bit.
4316 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4317 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4319 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4322 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4323 * configure.srv: Ditto.
4324 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4325 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4326 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4327 (init_registers_amd64_linux): Remove prototype.
4328 (tdesc_amd64_linux): Remove declaration.
4329 (get_ipa_tdesc): New function.
4330 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4331 initialize remaining tdescs.
4332 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4333 (init_registers_i386_linux): Remove prototype.
4334 (tdesc_i386_linux): Remove declaration.
4335 (get_ipa_tdesc): New function.
4336 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4337 initialize remaining tdescs.
4338 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4339 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4340 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4341 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4342 (x86_get_ipa_tdesc_idx): New function.
4343 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4344 * linux-x86-tdesc.h: New file.
4345 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4346 (target_get_ipa_tdesc_idx): New macro.
4347 * tracepoint.c (ipa_tdesc_idx): New macro.
4348 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4349 (symbol_list): Add ipa_tdesc_idx.
4350 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4351 (ipa_tdesc): Remove.
4352 (ipa_tdesc_idx): New variable.
4353 (get_context_regcache): Use get_ipa_tdesc.
4354 (gdb_collect): Ditto.
4356 * tracepoint.h (get_ipa_tdesc): New prototype.
4357 (ipa_tdesc): Remove.
4359 2016-02-24 Pedro Alves <palves@redhat.com>
4361 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4362 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4363 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4364 Factor out common code between the USE_SIGTRAP_SIGINFO and
4365 !USE_SIGTRAP_SIGINFO blocks.
4366 (linux_low_filter_event): Call save_stop_reason instead of
4367 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4369 (linux_wait_1): Update comments.
4371 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
4373 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4374 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4375 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4376 ppc_insert_point, ppc_remove_point.
4378 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4380 * linux-s390-low.c (s390_supports_z_point_type): New function.
4381 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4383 2016-02-16 Yao Qi <yao.qi@linaro.org>
4385 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4386 PC. Get pc from regcache_read_pc.
4388 2016-02-12 Yao Qi <yao.qi@linaro.org>
4390 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4391 or linux_get_pc_32bit.
4392 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4394 2016-02-12 Yao Qi <yao.qi@linaro.org>
4396 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4397 arm_linux_get_next_pcs_fixup.
4399 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4401 * tracepoint.c (x_tracepoint_action_download): Change
4402 write_inferior_data_ptr to write_inferior_data_pointer.
4403 (cmd_qtstart): Likewise.
4404 (write_inferior_data_ptr): Remove.
4405 (download_agent_expr): Change write_inferior_data_ptr to
4406 write_inferior_data_pointer.
4407 (download_tracepoint_1): Likewise.
4408 (download_tracepoint): Likewise.
4409 (download_trace_state_variables): Likewise.
4411 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
4412 Marcin Kościelnicki <koriakin@0x04.net>
4414 * tracepoint.c (struct tracepoint_action_ops): Remove.
4415 (struct tracepoint_action): Remove ops.
4416 (m_tracepoint_action_download, r_tracepoint_action_download)
4417 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4418 size and offset accordingly.
4419 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4420 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4421 (tracepoint_action_send, tracepoint_action_download): New functions.
4422 Helpers for trace action handlers.
4423 (add_tracepoint_action): Remove setup actions ops.
4424 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4426 2016-02-10 Yao Qi <yao.qi@linaro.org>
4428 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4430 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4432 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4434 * configure: Regenerate.
4436 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4438 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4439 void * to gdb_byte *.
4440 * linux-low.c (siginfo_fixup): Likewise.
4441 (linux_xfer_siginfo): Likewise.
4442 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4444 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4446 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4448 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4450 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4452 * linux-x86-low.c [__x86_64__]: Include
4453 "nat/amd64-linux-siginfo.h".
4454 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4455 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4456 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4457 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4458 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4459 (cpt_si_fd, si_timerid, si_overrun): Move from
4460 nat/amd64-linux-siginfo.c.
4461 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4463 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4465 * server.c (skip_to_semicolon): Remove.
4466 (process_point_options): Use strchrnul instead of
4469 2016-01-26 Yao Qi <yao.qi@linaro.org>
4471 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4472 * linux-low.c (install_software_single_step_breakpoints): Don't
4473 call regcache_read_pc.
4474 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4477 2016-01-26 Yao Qi <yao.qi@linaro.org>
4479 * linux-low.c (install_software_single_step_breakpoints): Call
4480 regcache_read_pc instead of get_pc.
4482 2016-01-26 Yao Qi <yao.qi@linaro.org>
4484 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4485 (unblock_async_io): Rename to ...
4486 (block_unblock_async_io): ... it. New function.
4487 (enable_async_io): Don't install SIGIO handler. Unblock it
4489 (disable_async_io): Don't ignore SIGIO. Block it instead.
4490 (initialize_async_io): Install SIGIO handler. Don't call
4493 2016-01-26 Yao Qi <yao.qi@linaro.org>
4495 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4496 first character is '\003', call *the_target->request_interrupt.
4498 2016-01-25 Yao Qi <yao.qi@linaro.org>
4500 * remote-utils.c (new_thread_notify): Remove.
4501 (dead_thread_notify): Likewise.
4502 * remote-utils.h (new_thread_notify): Remove declaration.
4503 (dead_thread_notify): Likewise.
4505 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4507 * gdb.trace/pending.exp: Fix expected message on continue.
4509 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4511 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4512 it works properly on big-endian machines where sizeof (CORE_ADDR)
4515 2016-01-21 Pedro Alves <palves@redhat.com>
4517 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4518 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4519 * configure: Regenerate.
4521 2016-01-21 Yao Qi <yao.qi@linaro.org>
4523 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4524 is_thumb and set it according to CPSR saved on the stack.
4525 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4526 arm_sigreturn_next_pc.
4528 2016-01-18 Yao Qi <yao.qi@linaro.org>
4530 * linux-low.c (linux_set_pc_64bit): New function.
4531 (linux_get_pc_64bit): New function.
4532 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4534 * linux-sparc-low.c (debug_threads): Remove declaration.
4535 (sparc_get_pc): Remove.
4536 (the_low_target): Use linux_get_pc_64bit instead of
4538 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4539 (the_low_target): Use linux_get_pc_64bit and
4542 2016-01-18 Yao Qi <yao.qi@linaro.org>
4544 * linux-arm-low.c (debug_threads): Remove declaration.
4545 (arm_get_pc, arm_set_pc): Remove.
4546 (the_low_target): Use linux_get_pc_32bit and
4548 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4549 (the_low_target): Use linux_get_pc_32bit and
4551 * linux-cris-low.c (debug_threads): Remove declaration.
4552 (cris_get_pc, cris_set_pc,): Remove.
4553 (the_low_target): Use linux_get_pc_32bit and
4555 * linux-crisv32-low.c (debug_threads): Remove declaration.
4556 (cris_get_pc, cris_set_pc): Remove.
4557 (the_low_target): Use linux_get_pc_32bit and
4559 * linux-low.c: Include inttypes.h.
4560 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4561 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4562 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4563 (the_low_target): Use linux_get_pc_32bit and
4565 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4566 (the_low_target): Use linux_get_pc_32bit and
4568 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4569 (the_low_target): Use linux_get_pc_32bit and
4571 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4572 (the_low_target): Use linux_get_pc_32bit and
4574 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4575 (the_low_target): Use linux_get_pc_32bit and
4578 2016-01-18 Gary Benson <gbenson@redhat.com>
4580 * configure.ac (AC_FUNC_FORK): New check.
4581 * config.in: Regenerate.
4582 * configure: Likewise.
4584 2016-01-14 Yao Qi <yao.qi@linaro.org>
4586 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4587 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4588 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4589 arm_get_next_pcs_ctor.
4591 2016-01-12 Josh Stone <jistone@redhat.com>
4592 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4594 * inferiors.h: Include "gdb_vecs.h".
4595 (struct process_info): Add syscalls_to_catch.
4596 * inferiors.c (remove_process): Free syscalls_to_catch.
4597 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4598 syscall_return stops.
4599 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4600 * server.c (handle_general_set): Handle QCatchSyscalls.
4601 (handle_query): Report support for QCatchSyscalls.
4602 * target.h (struct target_ops): Add supports_catch_syscall.
4603 (target_supports_catch_syscall): New macro.
4604 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4605 (struct lwp_info): Add syscall_state.
4606 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4607 Maintain syscall_state and syscalls_to_catch across exec.
4608 (get_syscall_trapinfo): New function, proxy to the_low_target.
4609 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4610 (linux_low_filter_event): Toggle syscall_state entry/return for
4611 syscall traps, and set it ignored for all others.
4612 (gdb_catching_syscalls_p): New function.
4613 (gdb_catch_this_syscall_p): New function.
4614 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4615 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4616 (linux_supports_catch_syscall): New function.
4617 (linux_target_ops): Install it.
4618 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4619 (the_low_target): Install it.
4621 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4623 * acinclude.m4: Include new ../warning.m4 file.
4624 * configure: Regenerated.
4625 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4627 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4629 * ax.c (is_goto_target): Mark static.
4630 * linux-low.c (register_addr): Likewise.
4631 (linux_fetch_registers, linux_store_registers): Likewise.
4632 * mem-break.c (any_persistent_commands): Fix old prototype.
4633 (add_commands_to_breakpoint): Mark static.
4634 * regcache.c (find_register_by_name): Delete unused func.
4635 * remote-utils.c (hex_or_minus_one): Mark static.
4636 * server.c (monitor_show_help): Mark static.
4637 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4638 handle_v_requests): Likewise.
4640 2016-01-12 Pedro Alves <palves@redhat.com>
4642 Remove use of the registered trademark symbol throughout.
4644 2016-01-08 Yao Qi <yao.qi@linaro.org>
4646 * remote-utils.c (getpkt): If c is '\003', call target hook
4649 2016-01-06 Yao Qi <yao.qi@linaro.org>
4651 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4652 linux-aarch32-low.c.
4653 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4654 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4655 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4656 (thumb2_breakpoint): Declare.
4657 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4658 linux-aarch32-low.h.
4659 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4660 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4661 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4663 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4665 * gdbreplay.c (gdbreplay_version): Change copyright year in
4667 * server.c (gdbserver_version): Likewise.
4669 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4671 * server.c (crc32_table): Delete.
4672 (crc32): Use libiberty's xcrc32 function.
4674 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4676 * lynx-low.c (lynx_delete_thread_callback): New function.
4677 (lynx_mourn): Properly delete our process and all of its
4678 threads. Remove call to clear_inferiors.
4680 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4682 * target.c (thread_search_callback): Add check that
4683 the thread_stopped target callback is not NULL before
4686 2015-12-21 Yao Qi <yao.qi@linaro.org>
4688 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4691 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4693 * server.c (handle_query): Call target_supports_software_single_step.
4695 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4697 * linux-low.c (single_step): New function.
4698 (linux_resume_one_lwp_throw): Call single_step.
4699 (start_step_over): Likewise.
4701 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4703 * Makefile.in (SFILES): Append arch/arm-linux.c,
4704 arch/arm-get-next-pcs.c.
4705 (arm-linux.o): New rule.
4706 (arm-get-next-pcs.o): New rule.
4707 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4709 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4710 to linux-aarch32-low.c.
4711 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4712 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4713 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4714 (thumb2_breakpoint_len): Likewise.
4715 (arm_is_thumb_mode): Make non-static.
4716 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4717 from linux-aarch32-low.c.
4718 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4719 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4720 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4721 (thumb2_breakpoint_len): Likewise.
4722 (arm_is_thumb_mode): New declaration.
4723 * linux-arm-low.c: Include arch/arm-linux.h
4724 aarch/arm-get-next-pcs.h, sys/syscall.h.
4725 (get_next_pcs_ops): New struct.
4726 (get_next_pcs_addr_bits_remove): New function.
4727 (get_next_pcs_is_thumb): New function.
4728 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4729 (arm_sigreturn_next_pc): Likewise.
4730 (get_next_pcs_syscall_next_pc): Likewise.
4731 (arm_gdbserver_get_next_pcs): Likewise.
4732 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4734 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4735 * server.h: Include gdb_vecs.h.
4737 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4739 * Makefile.in (SFILES): Append common/common-regcache.c.
4740 (OBS): Append common-regcache.o.
4741 (common-regcache.o): New rule.
4742 * regcache.c (init_register_cache): Initialize cache to
4744 (regcache_raw_read_unsigned): New function.
4745 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4746 register_status enum.
4748 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4750 * linux-aarch64-low.c (the_low_targets): Rename
4751 breakpoint_reinsert_addr to get_next_pcs.
4752 * linux-arm-low.c (the_low_targets): Likewise.
4753 * linux-bfin-low.c (the_low_targets): Likewise.
4754 * linux-cris-low.c (the_low_targets): Likewise.
4755 * linux-crisv32-low.c (the_low_targets): Likewise.
4756 * linux-low.c (can_software_single_step): Likewise.
4757 (install_software_single_step_breakpoints): New function.
4758 (start_step_over): Use install_software_single_step_breakpoints.
4759 * linux-low.h: New CORE_ADDR vector.
4760 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4762 * linux-mips-low.c (the_low_targets): Likewise.
4763 * linux-nios2-low.c (the_low_targets): Likewise.
4764 * linux-sparc-low.c (the_low_targets): Likewise.
4766 2015-12-17 Pedro Alves <palves@redhat.com>
4768 * linux-low.c (linux_kill_one_lwp): Remove references to
4770 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4772 (linux_init_signals): Delete.
4773 (initialize_low): Adjust.
4774 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4776 2015-12-16 Pedro Alves <palves@redhat.com>
4778 * configure.ac (compiler warning flags): When testing a
4779 -Wno-foo option, check whether -Wfoo works instead.
4780 * configure: Regenerate.
4782 2015-12-11 Don Breazeal <donb@codesourcery.com>
4784 * server.c (process_serial_event): Don't exit from gdbserver
4785 in remote mode if there are still active inferiors.
4787 2015-12-11 Yao Qi <yao.qi@linaro.org>
4789 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4790 arm_breakpoint_at if the process is 32-bit.
4792 2015-12-11 Yao Qi <yao.qi@linaro.org>
4794 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4797 2015-12-07 Yao Qi <yao.qi@linaro.org>
4799 * configure.srv: Append arm.o to srv_tgtobj for
4800 aarch64*-*-linux* target.
4801 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4802 from linux-arm-low.c.
4803 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4804 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4805 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4806 (thumb2_breakpoint_len): Likewise.
4807 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4808 (arm_breakpoint_kinds): Likewise.
4809 (arm_breakpoint_kind_from_pc): Likewise.
4810 (arm_sw_breakpoint_from_kind): Likewise.
4811 (arm_breakpoint_kind_from_current_state): Likewise.
4812 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4813 (arm_sw_breakpoint_from_kind): Declare.
4814 (arm_breakpoint_kind_from_current_state): Declare.
4815 (arm_breakpoint_at): Declare.
4816 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4817 arm_sw_breakpoint_from_kind if process is 32-bit.
4818 (aarch64_breakpoint_kind_from_pc): New function.
4819 (aarch64_breakpoint_kind_from_current_state): New function.
4820 (the_low_target): Initialize fields breakpoint_kind_from_pc
4821 and breakpoint_kind_from_current_state.
4822 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4823 linux-aarch32-low.c.
4824 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4825 (arm_breakpoint, arm_breakpoint_len): Likewise.
4826 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4827 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4828 (arm_is_thumb_mode): Likewise.
4829 (arm_breakpoint_at): Likewise.
4830 (arm_breakpoint_kind_from_pc): Likewise.
4831 (arm_sw_breakpoint_from_kind): Likewise.
4832 (arm_breakpoint_kind_from_current_state): Likewise.
4835 2015-08-04 Yao Qi <yao.qi@linaro.org>
4837 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4838 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4839 * server.c (extended_protocol): Remove "static".
4840 * server.h (extended_protocol): Declare it.
4842 2015-12-04 Josh Stone <jistone@redhat.com>
4844 * target.h (struct target_ops) <arch_setup>: Rename to ...
4845 (struct target_ops) <post_create_inferior>: ... this.
4846 (target_arch_setup): Rename to ...
4847 (target_post_create_inferior): ... this, calling post_create_inferior.
4848 * server.c (start_inferior): Update target_arch_setup calls to
4849 target_post_create_inferior.
4850 * linux-low.c (linux_low_ptrace_options): Forward declare.
4851 (linux_arch_setup): Update its comment for general use.
4852 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4853 (struct linux_target_ops): Use linux_post_create_inferior.
4854 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4855 to post_create_inferior.
4856 * nto-low.c (struct nto_target_ops): Likewise.
4857 * spu-low.c (struct spu_target_ops): Likewise.
4858 * win32-low.c (struct win32_target_ops): Likewise.
4860 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4862 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4864 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4866 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4867 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4868 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4869 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4870 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4871 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4872 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4873 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4874 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4875 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4876 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4877 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4879 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4881 * linux-low.c (linux_look_up_symbols): Don't call
4882 linux_supports_traceclone.
4883 * linux-low.h (thread_db_init): Remove use_events argument.
4884 * thread-db.c (thread_db_use_event): Remove global variable.
4885 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4886 (struct thread_db) <td_create_bp>: Remove field.
4887 (thread_db_create_event): Remove function.
4888 (thread_db_enable_reporting): Likewise.
4889 (find_one_thread): Don't check for thread_db_use_events.
4890 (attach_thread): Likewise.
4891 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4892 (try_thread_db_load_1): Don't check for thread_db_use_events.
4893 (thread_db_init): Remove use_events argument and thread events
4895 (remove_thread_event_breakpoints): Remove function.
4896 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4898 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4900 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4902 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4903 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4904 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4905 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4906 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4908 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4910 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4911 * linux-low.c (can_hardware_single_step): Use
4912 supports_hardware_single_step.
4913 (can_software_single_step): New function.
4914 (start_step_over): Call can_software_single_step.
4915 (linux_supports_hardware_single_step): New function.
4916 (struct target_ops) <supports_software_single_step>: Initialize.
4917 * linux-low.h (struct linux_target_ops)
4918 <supports_hardware_single_step>: Initialize.
4919 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4920 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4921 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4922 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4923 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4924 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4925 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4926 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4927 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4928 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4930 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4931 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4933 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4934 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4935 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4937 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4938 * target.h (struct target_ops): <supports_software_single_step>:
4940 (target_supports_software_single_step): New macro.
4942 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4944 * linux-low.c (linux_wait_1): Fix pc advance condition.
4945 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4946 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4948 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4950 * linux-arm-low.c (arm_is_thumb_mode): New function.
4951 (arm_breakpoint_at): Use arm_is_thumb_mode.
4952 (arm_breakpoint_kind_from_current_state): New function.
4953 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4955 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4956 (linux_breakpoint_kind_from_current_state): New function.
4957 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4958 * linux-low.h (struct linux_target_ops)
4959 <breakpoint_kind_from_current_state>: New field.
4960 * target.h (struct target_ops): Likewise.
4961 (target_breakpoint_kind_from_current_state): New macro.
4963 2015-11-30 Pedro Alves <palves@redhat.com>
4965 * linux-low.c (linux_resume): Wake up the event loop before
4968 2015-11-30 Pedro Alves <palves@redhat.com>
4970 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4972 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4974 * target.c (struct thread_search): New structure.
4975 (thread_search_callback): New function.
4976 (prev_general_thread): New global.
4977 (prepare_to_access_memory, done_accessing_memory): New functions.
4978 * target.h (prepare_to_access_memory, done_accessing_memory):
4979 Replace macros with function declarations.
4981 2015-11-30 Pedro Alves <palves@redhat.com>
4984 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4985 report TARGET_WAITKIND_NO_RESUMED.
4986 * remote-utils.c (prepare_resume_reply): Handle
4987 TARGET_WAITKIND_NO_RESUMED.
4988 * server.c (report_no_resumed): New global.
4989 (handle_query) <qSupported>: Handle "no-resumed+". Report
4990 "no-resumed+" support.
4991 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4992 return error if the client doesn't support no-resumed events.
4993 (push_stop_notification): New function.
4994 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4995 events if the client supports them.
4997 2015-11-30 Pedro Alves <palves@redhat.com>
4999 * linux-low.c (thread_still_has_status_pending_p): Don't check
5001 (lwp_resumed): New function.
5002 (status_pending_p_callback): Return early if the LWP is not
5003 supposed to be resumed.
5005 2015-11-30 Pedro Alves <palves@redhat.com>
5007 * linux-low.c (handle_extended_wait): Assert that the LWP's
5008 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
5009 thread create events, leave the new child's status pending.
5010 (linux_low_filter_event): If GDB wants to hear about thread exit
5011 events, leave the LWP marked dead and don't delete it.
5012 (linux_wait_for_event_filtered): Don't check for thread exit.
5013 (filter_exit_event): New function.
5014 (linux_wait_1): Use it, when returning an exit event.
5015 (linux_resume_one_lwp_throw): Assert that the LWP's
5016 waitstatus is TARGET_WAITKIND_IGNORE.
5017 * remote-utils.c (prepare_resume_reply): Handle
5018 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
5019 * server.c (report_thread_events): New global.
5020 (handle_general_set): Handle QThreadEvents.
5021 (handle_query) <qSupported>: Handle and report QThreadEvents+;
5022 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
5023 TARGET_WAITKIND_THREAD_EXITED.
5024 * server.h (report_thread_events): Declare.
5026 2015-11-30 Pedro Alves <palves@redhat.com>
5028 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
5029 the thread's last_resume_kind was resume_stop.
5031 2015-11-30 Pedro Alves <palves@redhat.com>
5033 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
5036 2015-11-30 Pedro Alves <palves@redhat.com>
5038 * server.c (handle_v_requests): Handle vCtrlC.
5040 2015-11-30 Pedro Alves <palves@redhat.com>
5042 * gdbthread.h (find_any_thread_of_pid): Declare.
5043 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
5045 * server.c (handle_query): If current_thread is NULL, look for
5046 another thread of the selected process.
5048 2015-11-26 Daniel Colascione <dancol@dancol.org>
5049 Simon Marchi <simon.marchi@ericsson.com>
5051 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
5052 * server.c (handle_qxfer_threads_worker): Refactor to include thread
5054 * target.h (struct target_ops) <thread_name>: New field.
5055 (target_thread_name): New macro.
5057 2015-11-23 Joel Brobecker <brobecker@adacore.com>
5059 * regcache.h (regcache_invalidate_pid): Add declaration.
5060 * regcache.c (regcache_invalidate_pid): New function, extracted
5061 from regcache_invalidate.
5062 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
5063 Add trivial documentation comment.
5064 * lynx-low.c: Use regcache_invalidate_pid instead of
5065 regcache_invalidate.
5067 2015-11-23 Joel Brobecker <brobecker@adacore.com>
5069 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
5070 and Elf64_auxv_t if the target is Android.
5072 2015-11-22 Doug Evans <xdje42@gmail.com>
5074 * target.h: #include <sys/types.h>.
5076 2015-11-19 Pedro Alves <palves@redhat.com>
5078 * linux-low.c (linux_process_qsupported): Change prototype.
5080 * linux-low.h (struct linux_target_ops) <process_qsupported>:
5082 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
5083 and adjust to loop over all features.
5084 * server.c (handle_query) <qSupported>: Adjust to call
5085 target_process_qsupported once, passing it a vector of unprocessed
5087 * target.h (struct target_ops) <process_qsupported>: Change
5089 (target_process_qsupported): Adjust.
5091 2015-11-19 Pedro Alves <palves@redhat.com>
5093 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
5095 * configure: Regenerate.
5097 2015-11-19 Pedro Alves <palves@redhat.com>
5099 * configure: Regenerate.
5101 2015-11-19 Yao Qi <yao.qi@linaro.org>
5103 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
5106 2015-11-19 Yao Qi <yao.qi@linaro.org>
5108 * linux-aarch64-low.c (enum aarch64_operand_type): New.
5109 (struct aarch64_operand): Move enum out.
5111 2015-11-19 Yao Qi <yao.qi@linaro.org>
5113 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
5114 struct user_fpsimd_state *.
5115 (aarch64_store_fpregset): Likewise.
5117 2015-11-19 Yao Qi <yao.qi@linaro.org>
5119 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
5120 struct user_pt_regs *.
5121 (aarch64_store_gregset): Likewise.
5123 2015-11-18 Pedro Alves <palves@redhat.com>
5125 * Makefile.in (all_object_files): Add $IPA_OBJS.
5127 2015-11-17 Pedro Alves <palves@redhat.com>
5129 * win32-low.c (win32_resume): Use gdb_signal_from_host,
5130 GDB_SIGNAL_0 and gdb_signal_to_string.
5132 2015-11-17 Pedro Alves <palves@redhat.com>
5134 * win32-low.c (handle_output_debug_string): Remove parameter.
5135 (win32_kill): Remove our_status local and adjust call to
5136 handle_output_debug_string.
5137 (get_child_debug_event): Adjust call to
5138 handle_output_debug_string.
5140 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5142 * linux-mips-low.c (mips_fill_gregset): Add cast.
5143 (mips_store_gregset): Likewise.
5144 (mips_fill_fpregset): Likewise.
5145 (mips_store_fpregset): Likewise.
5147 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5149 * linux-mips-low.c (mips_add_watchpoint): Rename private to
5152 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5154 * linux-mips-low.c (mips_linux_new_thread): Change type of
5155 watch_type to enum target_hw_bp_type.
5157 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5159 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
5160 Change return type to arm_hwbp_type.
5162 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5164 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
5165 (arm_store_gregset): Likewise.
5166 * linux-arm-low.c (arm_get_hwcap): Likewise.
5167 (arm_read_description): Likewise.
5169 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5171 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
5173 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5175 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
5176 (ppc_fill_vsxregset): Likewise.
5177 (ppc_store_vsxregset): Likewise.
5178 (ppc_fill_vrregset): Likewise.
5179 (ppc_store_vrregset): Likewise.
5180 (ppc_fill_evrregset): Likewise.
5181 (ppc_store_evrregset): Likewise.
5183 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5185 * linux-ppc-low.c (ppc_usrregs_info): Remove
5186 forward-declaration.
5187 (ppc_arch_setup): Move lower in file.
5189 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
5191 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
5192 (ps_pdwrite): Likewise.
5194 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
5196 * linux-arm-low.c (arm_new_thread): Move pointer dereference
5197 to after assert checks.
5199 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
5201 * proc-service.c (ps_pdread): Add/adjust casts.
5202 (ps_pdwrite): Add/adjust casts.
5204 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5206 * server.c (handle_search_memory_1): Cast return value of
5209 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5211 * server.c (write_qxfer_response): Change type of data to
5214 2015-10-29 Pedro Alves <palves@redhat.com>
5216 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
5218 2015-10-29 Pedro Alves <palves@redhat.com>
5220 * tracepoint.c (clear_installed_tracepoints): Add casts.
5222 2015-10-29 Pedro Alves <palves@redhat.com>
5224 * server.c (handle_v_cont, process_serial_event): Add enum
5225 gdb_signal casts to signal parsing code.
5227 2015-10-29 Pedro Alves <palves@redhat.com>
5229 * linux-low.h (NULL_REGSET): Define.
5230 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5231 * linux-arm-low.c (arm_regsets): Likewise.
5232 * linux-crisv32-low.c (cris_regsets): Likewise.
5233 * linux-m68k-low.c (m68k_regsets): Likewise.
5234 * linux-mips-low.c (mips_regsets): Likewise.
5235 * linux-nios2-low.c (nios2_regsets): Likewise.
5236 * linux-ppc-low.c (ppc_regsets): Likewise.
5237 * linux-s390-low.c (s390_regsets): Likewise.
5238 * linux-sh-low.c (sh_regsets): Likewise.
5239 * linux-sparc-low.c (sparc_regsets): Likewise.
5240 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5241 * linux-tile-low.c (tile_regsets): Likewise.
5242 * linux-x86-low.c (x86_regsets): Likewise.
5243 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5245 2015-10-29 Pedro Alves <palves@redhat.com>
5247 * linux-low.h (NULL_REGSET): Define.
5248 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5249 * linux-arm-low.c (arm_regsets): Likewise.
5250 * linux-crisv32-low.c (cris_regsets): Likewise.
5251 * linux-m68k-low.c (m68k_regsets): Likewise.
5252 * linux-mips-low.c (mips_regsets): Likewise.
5253 * linux-nios2-low.c (nios2_regsets): Likewise.
5254 * linux-ppc-low.c (ppc_regsets): Likewise.
5255 * linux-s390-low.c (s390_regsets): Likewise.
5256 * linux-sh-low.c (sh_regsets): Likewise.
5257 * linux-sparc-low.c (sparc_regsets): Likewise.
5258 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5259 * linux-tile-low.c (tile_regsets): Likewise.
5260 * linux-x86-low.c (x86_regsets): Likewise.
5261 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5263 2015-10-26 Doug Evans <dje@google.com>
5265 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5267 2015-10-26 Doug Evans <dje@google.com>
5269 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5271 2015-10-26 Doug Evans <dje@google.com>
5273 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5275 (attach_thread, find_new_threads_callback): Ditto.
5277 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5279 * mem-break.h (set_breakpoint_data): Remove.
5281 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5283 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5284 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5285 (initialize_low): Remove set_breakpoint_data call.
5286 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5287 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5288 (initialize_low): Remove set_breakpoint_data call.
5289 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5290 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5291 (initialize_low): Remove set_breakpoint_data call.
5293 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5295 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5296 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5297 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5298 * target.h (target_breakpoint_kind_from_pc): New macro.
5300 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5302 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5303 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5304 the default breakpoint kind.
5306 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5308 * linux-arm-low.c (arm_supports_z_point_type): Add software
5311 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5313 * linux-arm-low.c: Refactor breakpoint definitions.
5314 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5315 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5317 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5319 * Makefile.in: Add arm.c/o.
5320 * configure.srv: Likewise.
5321 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5322 (arm_breakpoint_kind_from_pc): New function.
5323 (arm_sw_breakpoint_from_kind): Return proper kind.
5324 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5326 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5328 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5330 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5331 (struct raw_breakpoint) <size>: Remove.
5332 (struct raw_breakpoint) <kind>: Add.
5333 (bp_size): New function.
5334 (bp_opcode): Likewise.
5335 (find_raw_breakpoint_at): Adjust for kind.
5336 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5337 (remove_memory_breakpoint): Adjust for kind call bp_size.
5338 (set_raw_breakpoint_at): Adjust for kind.
5339 (set_breakpoint): Likewise.
5340 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5341 (delete_raw_breakpoint): Adjust for kind.
5342 (delete_breakpoint): Likewise.
5343 (find_gdb_breakpoint): Likewise.
5344 (set_gdb_breakpoint_1): Likewise.
5345 (set_gdb_breakpoint): Likewise.
5346 (delete_gdb_breakpoint_1): Likewise.
5347 (delete_gdb_breakpoint): Likewise.
5348 (uninsert_raw_breakpoint): Likewise.
5349 (reinsert_raw_breakpoint): Likewise.
5350 (set_breakpoint_data): Remove.
5351 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5352 (check_mem_read): Adjust for kind call bp_size.
5353 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5354 (clone_one_breakpoint): Adjust for kind.
5355 * mem-break.h (set_gdb_breakpoint): Likewise.
5356 (delete_gdb_breakpoint): Likewise.
5357 * server.c (process_serial_event): Likewise.
5359 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5361 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5362 (struct linux_target_ops) <breakpoint>: Remove.
5363 (struct linux_target_ops) <breakpoint_len>: Remove.
5364 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5365 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5366 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5367 (arm_sw_breakpoint_from_kind): New function.
5368 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
5369 (struct linux_target_ops) <breakpoint>: Remove.
5370 (struct linux_target_ops) <breakpoint_len>: Remove.
5371 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5372 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5373 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
5374 (struct linux_target_ops) <breakpoint>: Remove.
5375 (struct linux_target_ops) <breakpoint_len>: Remove.
5376 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5377 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5378 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5379 (struct linux_target_ops) <breakpoint>: Remove.
5380 (struct linux_target_ops) <breakpoint_len>: Remove.
5381 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5382 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5383 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5384 and sw_breakpoint_from_kind to increment the pc.
5385 (linux_breakpoint_kind_from_pc): New function.
5386 (linux_sw_breakpoint_from_kind): New function.
5387 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5388 (initialize_low): Call breakpoint_kind_from_pc and
5389 sw_breakpoint_from_kind to replace breakpoint_data/len.
5390 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5392 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5393 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
5394 (struct linux_target_ops) <breakpoint>: Remove.
5395 (struct linux_target_ops) <breakpoint_len>: Remove.
5396 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5397 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5398 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
5399 (struct linux_target_ops) <breakpoint>: Remove.
5400 (struct linux_target_ops) <breakpoint_len>: Remove.
5401 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5402 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5403 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
5404 (struct linux_target_ops) <breakpoint>: Remove.
5405 (struct linux_target_ops) <breakpoint_len>: Remove.
5406 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5407 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5408 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
5409 (struct linux_target_ops) <breakpoint>: Remove.
5410 (struct linux_target_ops) <breakpoint_len>: Remove.
5411 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5412 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5413 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
5414 (struct linux_target_ops) <breakpoint>: Remove.
5415 (struct linux_target_ops) <breakpoint_len>: Remove.
5416 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5417 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5418 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
5419 (struct linux_target_ops) <breakpoint>: Remove.
5420 (struct linux_target_ops) <breakpoint_len>: Remove.
5421 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5422 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5423 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
5424 (struct linux_target_ops) <breakpoint>: Remove.
5425 (struct linux_target_ops) <breakpoint_len>: Remove.
5426 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5427 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5428 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
5429 (struct linux_target_ops) <breakpoint>: Remove.
5430 (struct linux_target_ops) <breakpoint_len>: Remove.
5431 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5432 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5433 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
5434 (struct linux_target_ops) <breakpoint>: Remove.
5435 (struct linux_target_ops) <breakpoint_len>: Remove.
5436 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5437 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5438 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5439 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
5440 (struct linux_target_ops) <breakpoint>: Remove.
5441 (struct linux_target_ops) <breakpoint_len>: Remove.
5442 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5443 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5444 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5445 (struct linux_target_ops) <breakpoint>: Remove.
5446 (struct linux_target_ops) <breakpoint_len>: Remove.
5447 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5448 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5450 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5452 * linux-cris-low.c (cris_get_pc): Remove void arg.
5454 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5456 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5459 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5461 * inferiors.c (thread_pid_matches_callback): New function.
5462 (find_thread_process): New function.
5463 (remove_thread): Reset current_thread.
5464 (remove_process): Assert threads have been removed first.
5466 2015-10-15 Yao Qi <yao.qi@linaro.org>
5468 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5470 (aarch64_remove_point): Likewise.
5471 * regcache.c (regcache_register_size): New function.
5473 2015-10-12 Yao Qi <yao.qi@linaro.org>
5475 * linux-aarch64-low.c: Update all callers as emit_load_store
5476 is renamed to aarch64_emit_load_store.
5478 2015-10-12 Yao Qi <yao.qi@linaro.org>
5480 * linux-aarch64-low.c: Update all callers of function renaming
5481 from emit_insn to aarch64_emit_insn.
5483 2015-10-12 Yao Qi <yao.qi@linaro.org>
5485 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5486 arch/aarch64-insn.h.
5487 (struct aarch64_memory_operand): Likewise.
5489 (emit_insn): Move to arch/aarch64-insn.c.
5490 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5491 (emit_load_store): Move to arch/aarch64-insn.c.
5492 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5493 (can_encode_int32): Remove.
5495 2015-10-12 Yao Qi <yao.qi@linaro.org>
5497 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5498 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5499 (aarch64_relocate_instruction): Likewise.
5500 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5501 (struct aarch64_insn_visitor): Likewise.
5503 2015-10-12 Yao Qi <yao.qi@linaro.org>
5505 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5506 (struct aarch64_insn_visitor): New.
5507 (struct aarch64_insn_relocation_data): New.
5508 (aarch64_ftrace_insn_reloc_b): New function.
5509 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5510 (aarch64_ftrace_insn_reloc_cb): Likewise.
5511 (aarch64_ftrace_insn_reloc_tb): Likewise.
5512 (aarch64_ftrace_insn_reloc_adr): Likewise.
5513 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5514 (aarch64_ftrace_insn_reloc_others): Likewise.
5516 (aarch64_relocate_instruction): Use visitor.
5518 2015-10-12 Yao Qi <yao.qi@linaro.org>
5520 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5521 int. Add argument buf.
5522 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5523 aarch64_relocate_instruction.
5525 2015-10-12 Yao Qi <yao.qi@linaro.org>
5527 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5528 argument insn. Remove local variable insn. Don't call
5530 (aarch64_install_fast_tracepoint_jump_pad): Call
5533 2015-09-30 Yao Qi <yao.qi@linaro.org>
5535 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5536 (emit_load_store_pair): Likewise.
5538 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5540 * dll.c (match_dll): Add cast(s).
5541 (unloaded_dll): Likewise.
5542 * linux-low.c (second_thread_of_pid_p): Likewise.
5543 (delete_lwp_callback): Likewise.
5544 (count_events_callback): Likewise.
5545 (select_event_lwp_callback): Likewise.
5546 (linux_set_resume_request): Likewise.
5547 * server.c (accumulate_file_name_length): Likewise.
5548 (emit_dll_description): Likewise.
5549 (handle_qxfer_threads_worker): Likewise.
5550 (visit_actioned_threads): Likewise.
5551 * thread-db.c (any_thread_of): Likewise.
5552 * tracepoint.c (same_process_p): Likewise.
5553 (match_blocktype): Likewise.
5554 (build_traceframe_info_xml): Likewise.
5556 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5558 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5560 (gdb_unparse_agent_expr): Likewise.
5561 * hostio.c (require_data): Likewise.
5562 (handle_pread): Likewise.
5563 * linux-low.c (disable_regset): Likewise.
5564 (fetch_register): Likewise.
5565 (store_register): Likewise.
5566 (get_dynamic): Likewise.
5567 (linux_qxfer_libraries_svr4): Likewise.
5568 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5569 (set_fast_tracepoint_jump): Likewise.
5570 (uninsert_fast_tracepoint_jumps_at): Likewise.
5571 (reinsert_fast_tracepoint_jumps_at): Likewise.
5572 (validate_inserted_breakpoint): Likewise.
5573 (clone_agent_expr): Likewise.
5574 * regcache.c (init_register_cache): Likewise.
5575 * remote-utils.c (putpkt_binary_1): Likewise.
5576 (decode_M_packet): Likewise.
5577 (decode_X_packet): Likewise.
5578 (look_up_one_symbol): Likewise.
5579 (relocate_instruction): Likewise.
5580 (monitor_output): Likewise.
5581 * server.c (handle_search_memory): Likewise.
5582 (handle_qxfer_exec_file): Likewise.
5583 (handle_qxfer_libraries): Likewise.
5584 (handle_qxfer): Likewise.
5585 (handle_query): Likewise.
5586 (handle_v_cont): Likewise.
5587 (handle_v_run): Likewise.
5588 (captured_main): Likewise.
5589 * target.c (write_inferior_memory): Likewise.
5590 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5591 * tracepoint.c (init_trace_buffer): Likewise.
5592 (add_tracepoint_action): Likewise.
5593 (add_traceframe): Likewise.
5594 (add_traceframe_block): Likewise.
5595 (cmd_qtdpsrc): Likewise.
5596 (cmd_qtdv): Likewise.
5597 (cmd_qtstatus): Likewise.
5598 (response_source): Likewise.
5599 (response_tsv): Likewise.
5600 (cmd_qtnotes): Likewise.
5601 (gdb_collect): Likewise.
5602 (initialize_tracepoint): Likewise.
5604 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5606 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5607 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5608 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5610 (enum aarch64_condition_codes): New enum.
5611 (w0): New static global.
5614 (struct aarch64_memory_operand) <type>: New
5615 MEMORY_OPERAND_POSTINDEX type.
5616 (postindex_memory_operand): New helper function.
5617 (emit_ret): New function.
5618 (emit_load_store_pair): New function, factored out of emit_stp
5619 with support for MEMORY_OPERAND_POSTINDEX.
5620 (emit_stp): Rewrite using emit_load_store_pair.
5621 (emit_ldp): New function.
5622 (emit_load_store): Likewise.
5623 (emit_ldr): Mention post-index instruction in comment.
5624 (emit_ldrh): New function.
5625 (emit_ldrb): New function.
5626 (emit_ldrsw): Mention post-index instruction in comment.
5627 (emit_str): Likewise.
5628 (emit_subs): New function.
5629 (emit_cmp): Likewise.
5630 (emit_and): Likewise.
5631 (emit_orr): Likewise.
5632 (emit_orn): Likewise.
5633 (emit_eor): Likewise.
5634 (emit_mvn): Likewise.
5635 (emit_lslv): Likewise.
5636 (emit_lsrv): Likewise.
5637 (emit_asrv): Likewise.
5638 (emit_mul): Likewise.
5639 (emit_sbfm): Likewise.
5640 (emit_sbfx): Likewise.
5641 (emit_ubfm): Likewise.
5642 (emit_ubfx): Likewise.
5643 (emit_csinc): Likewise.
5644 (emit_cset): Likewise.
5645 (emit_nop): Likewise.
5646 (emit_ops_insns): New helper function.
5647 (emit_pop): Likewise.
5648 (emit_push): Likewise.
5649 (aarch64_emit_prologue): New function.
5650 (aarch64_emit_epilogue): Likewise.
5651 (aarch64_emit_add): Likewise.
5652 (aarch64_emit_sub): Likewise.
5653 (aarch64_emit_mul): Likewise.
5654 (aarch64_emit_lsh): Likewise.
5655 (aarch64_emit_rsh_signed): Likewise.
5656 (aarch64_emit_rsh_unsigned): Likewise.
5657 (aarch64_emit_ext): Likewise.
5658 (aarch64_emit_log_not): Likewise.
5659 (aarch64_emit_bit_and): Likewise.
5660 (aarch64_emit_bit_or): Likewise.
5661 (aarch64_emit_bit_xor): Likewise.
5662 (aarch64_emit_bit_not): Likewise.
5663 (aarch64_emit_equal): Likewise.
5664 (aarch64_emit_less_signed): Likewise.
5665 (aarch64_emit_less_unsigned): Likewise.
5666 (aarch64_emit_ref): Likewise.
5667 (aarch64_emit_if_goto): Likewise.
5668 (aarch64_emit_goto): Likewise.
5669 (aarch64_write_goto_address): Likewise.
5670 (aarch64_emit_const): Likewise.
5671 (aarch64_emit_call): Likewise.
5672 (aarch64_emit_reg): Likewise.
5673 (aarch64_emit_pop): Likewise.
5674 (aarch64_emit_stack_flush): Likewise.
5675 (aarch64_emit_zero_ext): Likewise.
5676 (aarch64_emit_swap): Likewise.
5677 (aarch64_emit_stack_adjust): Likewise.
5678 (aarch64_emit_int_call_1): Likewise.
5679 (aarch64_emit_void_call_2): Likewise.
5680 (aarch64_emit_eq_goto): Likewise.
5681 (aarch64_emit_ne_goto): Likewise.
5682 (aarch64_emit_lt_goto): Likewise.
5683 (aarch64_emit_le_goto): Likewise.
5684 (aarch64_emit_gt_goto): Likewise.
5685 (aarch64_emit_ge_got): Likewise.
5686 (aarch64_emit_ops_impl): New static global variable.
5687 (aarch64_emit_ops): New target function, return
5688 &aarch64_emit_ops_impl.
5689 (struct linux_target_ops): Install it.
5691 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5693 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5694 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5696 * linux-aarch64-ipa.c: New file.
5697 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5699 (aarch64_get_thread_area): New target method.
5700 (extract_signed_bitfield): New helper function.
5701 (aarch64_decode_ldr_literal): New function.
5702 (enum aarch64_opcodes): New enum.
5703 (struct aarch64_register): New struct.
5704 (struct aarch64_operand): New struct.
5705 (x0): New static global.
5714 (aarch64_register): New helper function.
5715 (register_operand): Likewise.
5716 (immediate_operand): Likewise.
5717 (struct aarch64_memory_operand): New struct.
5718 (offset_memory_operand): New helper function.
5719 (preindex_memory_operand): Likewise.
5720 (enum aarch64_system_control_registers): New enum.
5721 (ENCODE): New macro.
5722 (emit_insn): New helper function.
5723 (emit_b): New function.
5724 (emit_bcond): Likewise.
5725 (emit_cb): Likewise.
5726 (emit_tb): Likewise.
5727 (emit_blr): Likewise.
5728 (emit_stp): Likewise.
5729 (emit_ldp_q_offset): Likewise.
5730 (emit_stp_q_offset): Likewise.
5731 (emit_load_store): Likewise.
5732 (emit_ldr): Likewise.
5733 (emit_ldrsw): Likewise.
5734 (emit_str): Likewise.
5735 (emit_ldaxr): Likewise.
5736 (emit_stxr): Likewise.
5737 (emit_stlr): Likewise.
5738 (emit_data_processing_reg): Likewise.
5739 (emit_data_processing): Likewise.
5740 (emit_add): Likewise.
5741 (emit_sub): Likewise.
5742 (emit_mov): Likewise.
5743 (emit_movk): Likewise.
5744 (emit_mov_addr): Likewise.
5745 (emit_mrs): Likewise.
5746 (emit_msr): Likewise.
5747 (emit_sevl): Likewise.
5748 (emit_wfe): Likewise.
5749 (append_insns): Likewise.
5750 (can_encode_int32_in): New helper function.
5751 (aarch64_relocate_instruction): New function.
5752 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5753 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5754 (struct linux_target_ops): Install aarch64_get_thread_area,
5755 aarch64_install_fast_tracepoint_jump_pad and
5756 aarch64_get_min_fast_tracepoint_insn_len.
5758 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5760 * Makefile.in (aarch64-insn.o): New rule.
5761 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5763 2015-09-21 Yao Qi <yao.qi@linaro.org>
5765 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5767 2015-09-21 Yao Qi <yao.qi@linaro.org>
5769 * tracepoint.c (max_jump_pad_size): Remove.
5771 2015-09-18 Yao Qi <yao.qi@linaro.org>
5773 * linux-aarch64-low.c: Don't include sys/uio.h.
5774 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5776 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5778 * tracepoint.c (eval_result_type): Change prototype.
5779 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5781 2015-09-15 Pedro Alves <palves@redhat.com>
5783 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5784 Check whether to report exec events instead of checking whether
5785 multiprocess is enabled.
5787 2015-09-15 Pedro Alves <palves@redhat.com>
5790 * remote-utils.c (prepare_resume_reply): Merge
5791 TARGET_WAITKIND_VFORK_DONE switch case with the
5792 TARGET_WAITKIND_FORKED case.
5794 2015-09-15 Yao Qi <yao.qi@linaro.org>
5796 * server.c (handle_query): Check string comparison using
5797 "else if" instead of "if".
5799 2015-09-15 Yao Qi <yao.qi@linaro.org>
5801 * server.c (vCont_supported): New global variable.
5802 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5803 matches. Append ";vContSupported+" to own_buf.
5804 (handle_v_requests): Append ";s;S" to own_buf if target supports
5805 hardware single step or vCont_supported is false.
5806 (capture_main): Set vCont_supported to zero.
5808 2015-09-15 Yao Qi <yao.qi@linaro.org>
5810 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5812 (linux_supports_hardware_single_step): ... New function.
5813 (linux_target_ops): Update.
5814 * lynx-low.c (lynx_target_ops): Set field
5815 supports_hardware_single_step to target_can_do_hardware_single_step.
5816 * nto-low.c (nto_target_ops): Likewise.
5817 * spu-low.c (spu_target_ops): Likewise.
5818 * win32-low.c (win32_target_ops): Likewise.
5819 * target.c (target_can_do_hardware_single_step): New function.
5820 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5821 Remove. <supports_hardware_single_step>: New field.
5822 (target_supports_conditional_breakpoints): Remove.
5823 (target_supports_hardware_single_step): New macro.
5824 (target_can_do_hardware_single_step): Declare.
5825 * server.c (handle_query): Use target_supports_hardware_single_step
5826 instead of target_supports_conditional_breakpoints.
5828 2015-09-15 Yao Qi <yao.qi@linaro.org>
5830 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5832 (struct linux_target_ops the_low_target): Install
5833 aarch64_linux_siginfo_fixup.
5835 2015-09-11 Don Breazeal <donb@codesourcery.com>
5836 Luis Machado <lgustavo@codesourcery.com>
5838 * linux-low.c (linux_mourn): Static declaration.
5839 (linux_arch_setup): Move in front of
5840 handle_extended_wait.
5841 (linux_arch_setup_thread): New function.
5842 (handle_extended_wait): Handle exec events. Call
5843 linux_arch_setup_thread. Make event_lwp argument a
5844 pointer-to-a-pointer.
5845 (check_zombie_leaders): Do not check stopped threads.
5846 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5847 (linux_low_filter_event): Add lwp and thread for exec'ing
5848 non-leader thread if leader thread has been deleted.
5849 Refactor code into linux_arch_setup_thread and call it.
5850 Pass child lwp pointer by reference to handle_extended_wait.
5851 (linux_wait_for_event_filtered): Update comment.
5852 (linux_wait_1): Prevent clobbering exec event status.
5853 (linux_supports_exec_events): New function.
5854 (linux_target_ops) <supports_exec_events>: Initialize new member.
5855 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5857 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5858 * server.c (report_exec_events): New global variable.
5859 (handle_query): Handle qSupported query for exec-events feature.
5860 (captured_main): Initialize report_exec_events.
5861 * server.h (report_exec_events): Declare new global variable.
5862 * target.h (struct target_ops) <supports_exec_events>: New
5864 (target_supports_exec_events): New macro.
5865 * win32-low.c (win32_target_ops) <supports_exec_events>:
5866 Initialize new member.
5868 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5870 * linux-low.c (linux_low_enable_btrace): Remove.
5871 (linux_target_ops): Replace linux_low_enable_btrace with
5872 linux_enable_btrace.
5874 2015-09-03 Yao Qi <yao.qi@linaro.org>
5876 * linux-aarch64-low.c (aarch64_insert_point): Call
5877 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5880 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5882 * linux-low.c (check_stopped_by_breakpoint): Use
5883 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5885 2015-08-27 Pedro Alves <palves@redhat.com>
5887 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5889 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5891 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5892 the XNEW-family equivalent.
5893 (compile_bytecodes): Likewise.
5894 * dll.c (loaded_dll): Likewise.
5895 * event-loop.c (append_callback_event): Likewise.
5896 (create_file_handler): Likewise.
5897 (create_file_event): Likewise.
5898 * hostio.c (handle_open): Likewise.
5899 * inferiors.c (add_thread): Likewise.
5900 (add_process): Likewise.
5901 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5902 * linux-arm-low.c (arm_new_process): Likewise.
5903 (arm_new_thread): Likewise.
5904 * linux-low.c (add_to_pid_list): Likewise.
5905 (linux_add_process): Likewise.
5906 (handle_extended_wait): Likewise.
5907 (add_lwp): Likewise.
5908 (enqueue_one_deferred_signal): Likewise.
5909 (enqueue_pending_signal): Likewise.
5910 (linux_resume_one_lwp_throw): Likewise.
5911 (linux_resume_one_thread): Likewise.
5912 (linux_read_memory): Likewise.
5913 (linux_write_memory): Likewise.
5914 * linux-mips-low.c (mips_linux_new_process): Likewise.
5915 (mips_linux_new_thread): Likewise.
5916 (mips_add_watchpoint): Likewise.
5917 * linux-x86-low.c (initialize_low_arch): Likewise.
5918 * lynx-low.c (lynx_add_process): Likewise.
5919 * mem-break.c (set_raw_breakpoint_at): Likewise.
5920 (set_breakpoint): Likewise.
5921 (add_condition_to_breakpoint): Likewise.
5922 (add_commands_to_breakpoint): Likewise.
5923 (clone_agent_expr): Likewise.
5924 (clone_one_breakpoint): Likewise.
5925 * regcache.c (new_register_cache): Likewise.
5926 * remote-utils.c (look_up_one_symbol): Likewise.
5927 * server.c (queue_stop_reply): Likewise.
5928 (start_inferior): Likewise.
5929 (queue_stop_reply_callback): Likewise.
5930 (handle_target_event): Likewise.
5931 * spu-low.c (fetch_ppc_memory): Likewise.
5932 (store_ppc_memory): Likewise.
5933 * target.c (set_target_ops): Likewise.
5934 * thread-db.c (thread_db_load_search): Likewise.
5935 (try_thread_db_load_1): Likewise.
5936 * tracepoint.c (add_tracepoint): Likewise.
5937 (add_tracepoint_action): Likewise.
5938 (create_trace_state_variable): Likewise.
5939 (cmd_qtdpsrc): Likewise.
5940 (cmd_qtro): Likewise.
5941 (add_while_stepping_state): Likewise.
5942 * win32-low.c (child_add_thread): Likewise.
5943 (get_image_name): Likewise.
5945 2015-08-25 Yao Qi <yao.qi@linaro.org>
5947 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5949 2015-08-25 Yao Qi <yao.qi@linaro.org>
5951 * Makefile.in (aarch64-linux.o): New rule.
5952 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5954 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5955 (aarch64_init_debug_reg_state): Make it extern.
5956 (aarch64_linux_prepare_to_resume): Remove.
5958 2015-08-25 Yao Qi <yao.qi@linaro.org>
5960 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5961 lwp_arch_private_info and ptid_of_lwp.
5963 2015-08-25 Yao Qi <yao.qi@linaro.org>
5965 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5966 Find proc_info by find_process_pid. All callers updated.
5968 2015-08-25 Yao Qi <yao.qi@linaro.org>
5970 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5972 (debug_reg_change_callback): Remove.
5973 (aarch64_notify_debug_reg_change): Remove.
5975 2015-08-25 Yao Qi <yao.qi@linaro.org>
5977 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5978 Call current_lwp_ptid.
5980 2015-08-25 Yao Qi <yao.qi@linaro.org>
5982 * linux-aarch64-low.c (debug_reg_change_callback): Use
5985 2015-08-25 Yao Qi <yao.qi@linaro.org>
5987 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5989 2015-08-25 Yao Qi <yao.qi@linaro.org>
5991 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5993 2015-08-25 Yao Qi <yao.qi@linaro.org>
5995 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5998 2015-08-25 Yao Qi <yao.qi@linaro.org>
6000 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
6002 (debug_reg_change_callback): Remove argument entry and add argument
6003 lwp. Remove local variable thread. Don't print thread id in the
6004 debugging output. Don't check whether pid of thread equals to pid.
6005 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
6006 iterate_over_lwps instead find_inferior.
6008 2015-08-24 Pedro Alves <palves@redhat.com>
6010 * inferiors.c (get_first_process): New function.
6011 * inferiors.h (get_first_process): New declaration.
6012 * remote-utils.c (read_ptid): Default to the first process in the
6013 list, instead of to the current thread's process.
6015 2015-08-24 Pedro Alves <palves@redhat.com>
6017 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
6018 * event-loop.c: Likewise.
6019 * remote-utils.c: Likewise.
6020 * tracepoint.c: Likewise.
6022 2015-08-24 Pedro Alves <palves@redhat.com>
6024 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
6027 2015-08-21 Pedro Alves <palves@redhat.com>
6029 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
6030 instead of literal 1.
6032 2015-08-21 Pedro Alves <palves@redhat.com>
6034 * tdesc.c (default_description): Explicitly zero-initialize.
6036 2015-08-21 Pedro Alves <palves@redhat.com>
6039 * inferiors.c (remove_thread): Discard any pending stop reply for
6041 * server.c (remove_all_on_match_pid): Rename to ...
6042 (remove_all_on_match_ptid): ... this. Work with a filter ptid
6044 (discard_queued_stop_replies): Change parameter to a ptid. Now
6046 (handle_v_kill, kill_inferior_callback, captured_main)
6047 (process_serial_event): Adjust.
6048 * server.h (discard_queued_stop_replies): Declare.
6050 2015-08-21 Pedro Alves <palves@redhat.com>
6052 * linux-low.c (wait_for_sigstop): Always switch to no thread
6053 selected if the previously current thread dies.
6054 * lynx-low.c (lynx_request_interrupt): Use the first thread's
6055 process instead of the current thread's.
6056 * remote-utils.c (input_interrupt): Don't check if there's no
6058 * server.c (gdb_read_memory, gdb_write_memory): If setting the
6059 current thread to the general thread fails, error out.
6060 (handle_qxfer_auxv, handle_qxfer_libraries)
6061 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
6062 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
6063 (handle_query): Check if there's a thread selected instead of
6064 checking whether there's any thread in the thread list.
6065 (handle_qxfer_threads, handle_qxfer_btrace)
6066 (handle_qxfer_btrace_conf): Don't error out early if there's no
6067 thread in the thread list.
6068 (handle_v_cont, myresume): Don't set the current thread to the
6070 (process_serial_event) <Hg handling>: Also set thread_id if the
6071 previous general thread is still alive.
6072 (process_serial_event) <g/G handling>: If setting the current
6073 thread to the general thread fails, error out.
6074 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
6075 thread's lwp instead of the current thread's.
6076 * target.c (set_desired_thread): If the desired thread was not
6077 found, leave the current thread pointing to NULL. Return an int
6078 (boolean) indicating success.
6079 * target.h (set_desired_thread): Change return type to int.
6081 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
6083 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
6084 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
6086 (ps_get_thread_area): New function.
6088 2015-08-19 Gary Benson <gbenson@redhat.com>
6090 * hostio.c (handle_pread): Do not attempt to read more data
6091 than hostio_reply_with_data can fit in a packet.
6093 2015-08-18 Joel Brobecker <brobecker@adacore.com>
6095 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
6097 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
6099 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
6101 2015-08-06 Pedro Alves <palves@redhat.com>
6103 * tracepoint.c (expr_eval_result): Now an int.
6105 2015-08-06 Pedro Alves <palves@redhat.com>
6107 * gdbthread.h (struct regcache): Forward declare.
6108 (struct thread_info) <regcache_data>: Now a struct regcache
6110 * inferiors.c (inferior_regcache_data)
6111 (set_inferior_regcache_data): Now work with struct regcache
6113 * inferiors.h (struct regcache): Forward declare.
6114 (inferior_regcache_data, set_inferior_regcache_data): Now work
6115 with struct regcache pointers.
6116 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
6117 (free_register_cache_thread): Remove struct regcache pointer
6120 2015-08-06 Pedro Alves <palves@redhat.com>
6122 * server.c (captured_main): On error, print the exception message
6123 to stderr, and if run_once is set, throw a quit.
6125 2015-08-06 Pedro Alves <palves@redhat.com>
6127 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
6130 2015-08-06 Pedro Alves <palves@redhat.com>
6132 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
6133 reading beyond the passed in buffer length.
6135 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
6137 * tracepoint.c (symbol_list) <required>: Remove.
6139 2015-08-06 Pedro Alves <palves@redhat.com>
6141 * linux-low.c (handle_extended_wait): Set the fork child's suspend
6142 count if stopping and suspending threads.
6143 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
6144 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
6145 (linux_detach): Complete an ongoing step-over.
6146 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
6148 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
6149 (linux_wait_1): If passing a signal to the inferior after
6150 finishing a step-over, unsuspend and re-resume all lwps. If we
6151 see a single-step event but the thread should be continuing, don't
6152 pass the trap to gdb.
6153 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
6154 internal_error instead of gdb_assert.
6155 (enqueue_pending_signal): New function.
6156 (check_ptrace_stopped_lwp_gone): Add debug output.
6157 (start_step_over): Use internal_error instead of gdb_assert.
6158 (complete_ongoing_step_over): New function.
6159 (linux_resume_one_thread): Don't resume a suspended thread.
6160 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
6163 2015-08-06 Pedro Alves <palves@redhat.com>
6165 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
6166 (linux_thread_alive): Use lwp_is_marked_dead.
6167 (extended_event_reported): Delete.
6168 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
6169 instead of extended_event_reported.
6170 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
6172 (lwp_is_marked_dead): New function.
6173 (lwp_running): Use lwp_is_marked_dead.
6174 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
6177 2015-08-06 Pedro Alves <palves@redhat.com>
6179 * linux-low.c (linux_wait_1): Move fork event output out of the
6180 !report_to_gdb check. Pass event_child->waitstatus to
6181 target_waitstatus_to_string instead of ourstatus.
6183 2015-08-04 Yao Qi <yao.qi@linaro.org>
6185 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
6186 if current_thread is 32 bit.
6188 2015-08-04 Yao Qi <yao.qi@linaro.org>
6190 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6191 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6192 * server.c (extended_protocol): Remove "static".
6193 * server.h (extended_protocol): Declare it.
6195 2015-08-04 Yao Qi <yao.qi@linaro.org>
6197 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
6198 both aarch64 and aarch32.
6199 (aarch64_set_pc): Likewise.
6201 2015-08-04 Yao Qi <yao.qi@linaro.org>
6203 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
6204 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
6205 arm-with-neon.xml to srv_xmlfiles.
6206 * linux-aarch64-low.c: Include linux-aarch32-low.h.
6207 (is_64bit_tdesc): New function.
6208 (aarch64_linux_read_description): New function.
6209 (aarch64_arch_setup): Call aarch64_linux_read_description.
6210 (regs_info): Rename to regs_info_aarch64.
6211 (aarch64_regs_info): Return right regs_info.
6212 (initialize_low_arch): Call initialize_low_arch_aarch32.
6214 2015-08-04 Yao Qi <yao.qi@linaro.org>
6216 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
6217 * linux-aarch32-low.c: New file.
6218 * linux-aarch32-low.h: New file.
6219 * linux-arm-low.c (arm_fill_gregset): Move it to
6220 linux-aarch32-low.c.
6221 (arm_store_gregset): Likewise.
6222 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
6223 (arm_store_vfpregset): Call arm_store_vfpregset_num.
6224 (arm_arch_setup): Check if PTRACE_GETREGSET works.
6225 (regs_info): Rename to regs_info_arm.
6226 (arm_regs_info): Return regs_info_aarch32 if
6227 have_ptrace_getregset is 1 and target description is
6228 arm_with_neon or arm_with_vfpv3.
6229 (initialize_low_arch): Don't call init_registers_arm_with_neon.
6230 Call initialize_low_arch_aarch32 instead.
6232 2015-08-04 Yao Qi <yao.qi@linaro.org>
6234 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
6235 * linux-low.c: ... here.
6236 * linux-low.h (have_ptrace_getregset): Declare it.
6238 2015-08-04 Pedro Alves <palves@redhat.com>
6240 * thread-db.c (struct thread_db): Use new typedefs.
6241 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6243 (disable_thread_event_reporting): Cast result of dlsym to
6244 destination function pointer type.
6245 (thread_db_mourn): Use td_ta_delete_ftype.
6247 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6249 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6251 (CDX_BREAKPOINT): Define for R2.
6252 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6253 (the_low_target): Add comments.
6255 2015-07-30 Yao Qi <yao.qi@linaro.org>
6257 * linux-arm-low.c (arm_hwcap): Remove it.
6258 (arm_read_description): New local variable arm_hwcap. Don't
6259 set arm_hwcap to zero.
6261 2015-07-30 Yao Qi <yao.qi@linaro.org>
6263 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6264 Use regcache->tdesc instead.
6265 (arm_store_wmmxregset): Likewise.
6266 (arm_fill_vfpregset): Likewise.
6267 (arm_store_vfpregset): Likewise.
6269 2015-07-30 Yao Qi <yao.qi@linaro.org>
6271 * linux-arm-low.c: Include arch/arm.h.
6272 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6273 (arm_store_gregset): Likewise.
6275 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6277 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6278 ptrace's 4th parameter.
6280 2015-07-27 Yao Qi <yao.qi@linaro.org>
6282 * configure.srv (case aarch64*-*-linux*): Don't set
6285 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6287 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6289 * linux-arm-low.c: Likewise.
6290 * linux-cris-low.c: Likewise.
6291 * linux-crisv32-low.c: Likewise.
6292 * linux-low.c: Likewise.
6293 * linux-m68k-low.c: Likewise.
6294 * linux-mips-low.c: Likewise.
6295 * linux-nios2-low.c: Likewise.
6296 * linux-s390-low.c: Likewise.
6297 * linux-sparc-low.c: Likewise.
6298 * linux-tic6x-low.c: Likewise.
6299 * linux-tile-low.c: Likewise.
6300 * linux-x86-low.c: Likewise.
6302 2015-07-24 Pedro Alves <palves@redhat.com>
6304 * config.in: Regenerate.
6305 * configure: Regenerate.
6307 2015-07-24 Pedro Alves <palves@redhat.com>
6309 * acinclude.m4: Include ../ptrace.m4.
6310 * configure.ac: Call GDB_AC_PTRACE.
6311 * config.in, configure: Regenerate.
6313 2015-07-24 Yao Qi <yao.qi@linaro.org>
6315 * linux-low.c (linux_create_inferior): Remove setting to
6316 proc->priv->new_inferior.
6317 (linux_attach): Likewise.
6318 (linux_low_filter_event): Likewise.
6319 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6321 2015-07-24 Yao Qi <yao.qi@linaro.org>
6323 * linux-low.c (linux_arch_setup): New function.
6324 (linux_low_filter_event): If proc->tdesc is NULL and
6325 proc->attached is true, call the_low_target.arch_setup.
6326 Otherwise, keep status pending, and return.
6327 (linux_resume_one_lwp_throw): Don't call get_pc if
6328 thread->while_stepping isn't NULL. Don't call
6329 get_thread_regcache if proc->tdesc is NULL.
6330 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6331 (linux_target_ops): Install arch_setup.
6332 * server.c (start_inferior): Call the_target->arch_setup.
6333 * target.h (struct target_ops) <arch_setup>: New field.
6334 (target_arch_setup): New marco.
6335 * lynx-low.c (lynx_target_ops): Update.
6336 * nto-low.c (nto_target_ops): Update.
6337 * spu-low.c (spu_target_ops): Update.
6338 * win32-low.c (win32_target_ops): Update.
6340 2015-07-24 Yao Qi <yao.qi@linaro.org>
6342 * linux-low.c (linux_add_process): Don't set
6343 proc->priv->new_inferior.
6344 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6345 (linux_attach): Likewise.
6347 2015-07-24 Yao Qi <yao.qi@linaro.org>
6349 * server.c (start_inferior): Code refactor.
6351 2015-07-24 Yao Qi <yao.qi@linaro.org>
6353 * server.c (process_serial_event): Set general_thread.
6355 2015-07-21 Yao Qi <yao.qi@linaro.org>
6357 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6358 aarch64_linux_get_debug_reg_capacity.
6360 2015-07-17 Yao Qi <yao.qi@linaro.org>
6362 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6363 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6364 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6365 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6366 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6367 (AARCH64_HWP_ALIGNMENT): Likewise.
6368 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6369 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6370 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6371 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6372 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6373 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6374 (struct aarch64_debug_reg_state): Likewise.
6375 (struct arch_lwp_info): Likewise.
6376 (aarch64_align_watchpoint): Likewise.
6377 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6378 (aarch64_watchpoint_length): Likewise.
6379 (aarch64_point_encode_ctrl_reg): Likewise
6380 (aarch64_point_is_aligned): Likewise.
6381 (aarch64_align_watchpoint): Likewise.
6382 (aarch64_linux_set_debug_regs):
6383 (aarch64_dr_state_insert_one_point): Likewise.
6384 (aarch64_dr_state_remove_one_point): Likewise.
6385 (aarch64_handle_breakpoint): Likewise.
6386 (aarch64_handle_aligned_watchpoint): Likewise.
6387 (aarch64_handle_unaligned_watchpoint): Likewise.
6388 (aarch64_handle_watchpoint): Likewise.
6390 2015-07-17 Yao Qi <yao.qi@linaro.org>
6392 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6393 and don't aarch64_get_debug_reg_state. All callers update.
6394 (aarch64_handle_aligned_watchpoint): Likewise.
6395 (aarch64_handle_unaligned_watchpoint): Likewise.
6396 (aarch64_handle_watchpoint): Likewise.
6397 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6398 (aarch64_remove_point): Likewise.
6400 2015-07-17 Yao Qi <yao.qi@linaro.org>
6402 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6404 (aarch64_handle_unaligned_watchpoint): Likewise.
6406 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6408 Revert the previous 3 commits:
6409 Move gdb_regex* to common/
6410 Move linux_find_memory_regions_full & co.
6411 gdbserver build-id attribute generator
6413 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6414 Jan Kratochvil <jan.kratochvil@redhat.com>
6416 gdbserver build-id attribute generator.
6417 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6418 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6419 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6421 (get_dynamic): Use find_pdhr to traverse program headers.
6422 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6423 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6424 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6425 (get_hex_build_id): New.
6426 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6427 to reply XML document.
6429 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6430 Jan Kratochvil <jan.kratochvil@redhat.com>
6432 * target.c: Include target/target-utils.h and fcntl.h.
6433 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6434 (target_fileio_read_stralloc): New functions.
6436 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6438 * Makefile.in (OBS): Add gdb_regex.o.
6440 * config.in: Rebuilt.
6441 * configure: Rebuilt.
6443 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6444 Jan Kratochvil <jan.kratochvil@redhat.com>
6446 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6447 * Makefile.in (OBS): Add target-utils.o.
6448 (linux-maps.o, target-utils.o): New.
6449 * configure.srv (srv_linux_obj): Add linux-maps.o.
6451 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6453 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6455 (the_low_target): Install it.
6457 2015-07-14 Pedro Alves <palves@redhat.com>
6459 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6460 Instead, ignore ECHILD, and throw an error for other errnos.
6462 2015-07-10 Pedro Alves <palves@redhat.com>
6464 * event-loop.c (struct callback_event) <data>: Change type to
6465 gdb_client_data instance instead of gdb_client_data pointer.
6466 (append_callback_event): Adjust.
6468 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6470 * linux-aarch64-low.c: Add comments for each linux_target_ops
6471 method. Remove comments already covered in target_ops and
6472 linux_target_ops definitions.
6473 (the_low_target): Add comments for each unimplemented method.
6475 2015-07-09 Yao Qi <yao.qi@linaro.org>
6477 * linux-aarch64-low.c (aarch64_regmap): Remove.
6478 (aarch64_usrregs_info): Remove.
6479 (regs_info): Set field usrregs to NULL.
6481 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6483 * linux-low.c: Include "rsp-low.h"
6484 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6485 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6486 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6487 (handle_btrace_enable_pt): New.
6488 (handle_btrace_general_set): Support "pt".
6489 (handle_btrace_conf_general_set): Support "pt:size".
6491 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6493 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6496 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6498 * linux-aarch64-low.c: Remove comment about endianness.
6499 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6500 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6503 2015-06-24 Gary Benson <gbenson@redhat.com>
6505 * linux-i386-ipa.c (stdint.h): Do not include.
6506 * lynx-i386-low.c (stdint.h): Likewise.
6507 * lynx-ppc-low.c (stdint.h): Likewise.
6508 * mem-break.c (stdint.h): Likewise.
6509 * thread-db.c (stdint.h): Likewise.
6510 * tracepoint.c (stdint.h): Likewise.
6511 * win32-low.c (stdint.h): Likewise.
6513 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6515 * server.c (write_qxfer_response): Update call to
6516 remote_escape_output.
6518 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6519 Jan Kratochvil <jan.kratochvil@redhat.com>
6521 Merge multiple hex conversions.
6522 * gdbreplay.c (tohex): Rename to 'fromhex'.
6523 (logchar): Use fromhex.
6525 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6527 * server.c (handle_qxfer_libraries): Set `version' attribute for
6530 2015-06-10 Gary Benson <gbenson@redhat.com>
6532 * target.h (struct target_ops) <multifs_open>: New field.
6533 <multifs_unlink>: Likewise.
6534 <multifs_readlink>: Likewise.
6535 * linux-low.c (nat/linux-namespaces.h): New include.
6536 (linux_target_ops): Initialize the_target->multifs_open,
6537 the_target->multifs_unlink and the_target->multifs_readlink.
6538 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6539 * hostio.c (hostio_fs_pid): New static variable.
6540 (hostio_handle_new_gdb_connection): New function.
6541 (handle_setfs): Likewise.
6542 (handle_open): Use the_target->multifs_open as appropriate.
6543 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6544 (handle_readlink): Use the_target->multifs_readlink as
6546 (handle_vFile): Handle vFile:setfs packets.
6547 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6548 after target_handle_new_gdb_connection.
6550 2015-06-10 Gary Benson <gbenson@redhat.com>
6552 * configure.ac (AC_CHECK_FUNCS): Add setns.
6553 * config.in: Regenerate.
6554 * configure: Likewise.
6555 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6556 (linux-namespaces.o): New rule.
6557 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6559 2015-06-09 Gary Benson <gbenson@redhat.com>
6561 * hostio.c (handle_open): Process mode argument with
6562 fileio_to_host_mode.
6564 2015-06-01 Yao Qi <yao.qi@linaro.org>
6566 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6567 * linux-x86-low.c: Likewise.
6569 2015-05-28 Don Breazeal <donb@codesourcery.com>
6571 * linux-low.c (handle_extended_wait): Initialize
6572 thread_info.last_resume_kind for new fork children.
6574 2015-05-15 Pedro Alves <palves@redhat.com>
6576 * target.h (target_handle_new_gdb_connection): Rewrite using if
6577 wrapped in do/while.
6579 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6581 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6582 * configure, config.in: Regenerate.
6583 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6586 2015-05-12 Don Breazeal <donb@codesourcery.com>
6588 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6589 PTRACE_EVENT_VFORK_DONE.
6590 (linux_low_ptrace_options, extended_event_reported): Add vfork
6592 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6593 and "vforkdone" for RSP 'T' Stop Reply Packet.
6594 * server.h (report_vfork_events): Declare
6597 2015-05-12 Don Breazeal <donb@codesourcery.com>
6599 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6600 (the_low_target) <new_fork>: Initialize new member.
6601 * linux-arm-low.c (arm_new_fork): New function.
6602 (the_low_target) <new_fork>: Initialize new member.
6603 * linux-low.c (handle_extended_wait): Call new target function
6605 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6606 * linux-mips-low.c (mips_add_watchpoint): New function
6607 extracted from mips_insert_point.
6608 (the_low_target) <new_fork>: Initialize new member.
6609 (mips_linux_new_fork): New function.
6610 (mips_insert_point): Call mips_add_watchpoint.
6611 * linux-x86-low.c (x86_linux_new_fork): New function.
6612 (the_low_target) <new_fork>: Initialize new member.
6614 2015-05-12 Don Breazeal <donb@codesourcery.com>
6616 * linux-low.c (handle_extended_wait): Implement return value,
6617 rename argument 'event_child' to 'event_lwp', handle
6618 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6619 (linux_low_ptrace_options): New function.
6620 (linux_low_filter_event): Call linux_low_ptrace_options,
6621 use different argument fo linux_enable_event_reporting,
6622 use return value from handle_extended_wait.
6623 (extended_event_reported): New function.
6624 (linux_wait_1): Call extended_event_reported and set
6625 status to report fork events.
6626 (linux_write_memory): Add pid to debug message.
6627 (reset_lwp_ptrace_options_callback): New function.
6628 (linux_handle_new_gdb_connection): New function.
6629 (linux_target_ops): Initialize new structure member.
6630 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6631 * lynx-low.c: Initialize new structure member.
6632 * remote-utils.c (prepare_resume_reply): Implement stop reason
6633 "fork" for "T" stop message.
6634 * server.c (handle_query): Call handle_new_gdb_connection.
6635 * server.h (report_fork_events): Declare global flag.
6636 * target.h (struct target_ops) <handle_new_gdb_connection>:
6638 (target_handle_new_gdb_connection): New macro.
6639 * win32-low.c: Initialize new structure member.
6641 2015-05-12 Don Breazeal <donb@codesourcery.com>
6643 * mem-break.c (APPEND_TO_LIST): Define macro.
6644 (clone_agent_expr): New function.
6645 (clone_one_breakpoint): New function.
6646 (clone_all_breakpoints): New function.
6647 * mem-break.h: Declare new functions.
6649 2015-05-12 Don Breazeal <donb@codesourcery.com>
6651 * linux-low.c (linux_supports_fork_events): New function.
6652 (linux_supports_vfork_events): New function.
6653 (linux_target_ops): Initialize new structure members.
6654 (initialize_low): Call linux_check_ptrace_features.
6655 * lynx-low.c (lynx_target_ops): Initialize new structure
6657 * server.c (report_fork_events, report_vfork_events):
6659 (handle_query): Add new features to qSupported packet and
6661 (captured_main): Initialize new global variables.
6662 * target.h (struct target_ops) <supports_fork_events>:
6664 <supports_vfork_events>: New member.
6665 (target_supports_fork_events): New macro.
6666 (target_supports_vfork_events): New macro.
6667 * win32-low.c (win32_target_ops): Initialize new structure
6670 2015-05-12 Gary Benson <gbenson@redhat.com>
6672 * server.c (handle_qxfer_exec_file): Use current process
6675 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6677 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6678 Remove HAVE_PTRACE_GETREGS conditionals.
6679 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6680 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6682 2015-05-08 Yao Qi <yao.qi@linaro.org>
6684 * linux-low.c (linux_supports_conditional_breakpoints): New
6686 (linux_target_ops): Install new target method.
6687 * lynx-low.c (lynx_target_ops): Install NULL hook for
6688 supports_conditional_breakpoints.
6689 * nto-low.c (nto_target_ops): Likewise.
6690 * spu-low.c (spu_target_ops): Likewise.
6691 * win32-low.c (win32_target_ops): Likewise.
6692 * server.c (handle_query): Check
6693 target_supports_conditional_breakpoints.
6694 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6696 (target_supports_conditional_breakpoints): New macro.
6698 2015-05-06 Pedro Alves <palves@redhat.com>
6701 * server.c (start_inferior): If the process exits, mourn it.
6703 2015-04-21 Gary Benson <gbenson@redhat.com>
6705 * hostio.c (fileio_open_flags_to_host): Factored out to
6706 fileio_to_host_openflags in common/fileio.c. Single use
6709 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6711 * linux-xtensa-low.c (xtensa_fill_gregset)
6712 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6715 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6717 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6718 (regs_info): Replace usrregs pointer with NULL.
6720 2015-04-17 Gary Benson <gbenson@redhat.com>
6722 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6723 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6724 * server.c (handle_qxfer_exec_file): New function.
6725 (qxfer_packets): Add exec-file entry.
6726 (handle_query): Report qXfer:exec-file:read as supported packet.
6728 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6730 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6732 2015-04-09 Gary Benson <gbenson@redhat.com>
6734 * hostio-errno.c (errno_to_fileio_error): Remove function.
6735 Update caller to use remote_fileio_to_fio_error.
6737 2015-04-09 Yao Qi <yao.qi@linaro.org>
6739 * linux-low.c (linux_insert_point): Call
6740 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6741 (linux_remove_point): Call remove_memory_breakpoint if type is
6743 * linux-x86-low.c (x86_insert_point): Don't call
6744 insert_memory_breakpoint.
6745 (x86_remove_point): Don't call remove_memory_breakpoint.
6747 2015-04-01 Pedro Alves <palves@redhat.com>
6748 Cleber Rosa <crosa@redhat.com>
6750 * server.c (gdbserver_usage): Reorganize and extend the usage
6753 2015-03-24 Pedro Alves <palves@redhat.com>
6755 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6756 output. Also dump TRAP_TRACE.
6757 (linux_low_filter_event): In debug output, distinguish a
6758 resume_stop SIGSTOP from a delayed SIGSTOP.
6760 2015-03-24 Gary Benson <gbenson@redhat.com>
6762 * linux-x86-low.c (x86_linux_new_thread): Moved to
6764 (x86_linux_prepare_to_resume): Likewise.
6766 2015-03-24 Gary Benson <gbenson@redhat.com>
6768 * Makefile.in (x86-linux-dregs.o): New rule.
6769 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6770 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6771 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6772 (x86_linux_dr_get): Likewise.
6773 (x86_linux_dr_set): Likewise.
6774 (update_debug_registers_callback): Likewise.
6775 (x86_linux_dr_set_addr): Likewise.
6776 (x86_linux_dr_get_addr): Likewise.
6777 (x86_linux_dr_set_control): Likewise.
6778 (x86_linux_dr_get_control): Likewise.
6779 (x86_linux_dr_get_status): Likewise.
6780 (x86_linux_update_debug_registers): Likewise.
6782 2015-03-24 Gary Benson <gbenson@redhat.com>
6784 * linux-x86-low.c (x86_linux_update_debug_registers):
6785 New function, factored out from...
6786 (x86_linux_prepare_to_resume): ...this.
6788 2015-03-24 Gary Benson <gbenson@redhat.com>
6790 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6791 (x86_linux_dr_set): Likewise.
6792 (update_debug_registers_callback): Likewise.
6793 (x86_linux_dr_set_addr): Likewise.
6794 (x86_linux_dr_get_addr): Likewise.
6795 (x86_linux_dr_set_control): Likewise.
6796 (x86_linux_dr_get_control): Likewise.
6797 (x86_linux_dr_get_status): Likewise.
6798 (x86_linux_prepare_to_resume): Likewise.
6800 2015-03-24 Gary Benson <gbenson@redhat.com>
6802 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6803 Use perror_with_name. Pass string through gettext.
6804 (x86_linux_dr_set): Likewise.
6806 2015-03-24 Gary Benson <gbenson@redhat.com>
6808 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6809 (x86_linux_dr_set_addr): ...this.
6810 (x86_dr_low_get_addr): Rename to...
6811 (x86_linux_dr_get_addr): ...this.
6812 (x86_dr_low_set_control): Rename to...
6813 (x86_linux_dr_set_control): ...this.
6814 (x86_dr_low_get_control): Rename to...
6815 (x86_linux_dr_get_control): ...this.
6816 (x86_dr_low_get_status): Rename to...
6817 (x86_linux_dr_get_status): ...this.
6818 (x86_dr_low): Update with new function names.
6820 2015-03-24 Gary Benson <gbenson@redhat.com>
6822 * Makefile.in (x86-linux.o): New rule.
6823 * configure.srv: Add x86-linux.o to relevant targets.
6824 * linux-low.c (lwp_set_arch_private_info): New function.
6825 (lwp_arch_private_info): Likewise.
6826 * linux-x86-low.c: Include nat/x86-linux.h.
6827 (arch_lwp_info): Removed structure.
6828 (update_debug_registers_callback):
6829 Use lwp_set_debug_registers_changed.
6830 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6831 and lwp_set_debug_registers_changed.
6832 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6834 2015-03-24 Gary Benson <gbenson@redhat.com>
6836 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6837 * linux-arm-low.c (arm_new_thread): Likewise.
6838 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6839 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6840 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6841 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6843 2015-03-24 Gary Benson <gbenson@redhat.com>
6845 * linux-low.c (ptid_of_lwp): New function.
6846 (lwp_is_stopped): Likewise.
6847 (lwp_stop_reason): Likewise.
6848 * linux-x86-low.c (update_debug_registers_callback):
6850 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6853 2015-03-24 Gary Benson <gbenson@redhat.com>
6855 * linux-low.h (linux_stop_lwp): Remove declaration.
6857 2015-03-24 Gary Benson <gbenson@redhat.com>
6859 * linux-low.h: Include nat/linux-nat.h.
6860 * linux-low.c (iterate_over_lwps_args): New structure.
6861 (iterate_over_lwps_filter): New function.
6862 (iterate_over_lwps): Likewise.
6863 * linux-x86-low.c (update_debug_registers_callback):
6864 Update signature to what iterate_over_lwps expects.
6865 Remove PID check that iterate_over_lwps now performs.
6866 (x86_dr_low_set_addr): Use iterate_over_lwps.
6867 (x86_dr_low_set_control): Likewise.
6869 2015-03-24 Gary Benson <gbenson@redhat.com>
6871 * linux-x86-low.c (x86_debug_reg_state): New function.
6872 (x86_linux_prepare_to_resume): Use the above.
6874 2015-03-24 Gary Benson <gbenson@redhat.com>
6876 * linux-low.c (current_lwp_ptid): New function.
6877 * linux-x86-low.c: Include nat/linux-nat.h.
6878 (x86_dr_low_get_addr): Use current_lwp_ptid.
6879 (x86_dr_low_get_control): Likewise.
6880 (x86_dr_low_get_status): Likewise.
6882 2015-03-20 Pedro Alves <palves@redhat.com>
6884 * tracepoint.c (cmd_qtstatus): Make "str" const.
6886 2015-03-20 Pedro Alves <palves@redhat.com>
6888 * server.c (handle_general_set): Make "req_str" const.
6890 2015-03-19 Pedro Alves <palves@redhat.com>
6892 * linux-low.c (linux_resume_one_lwp): Rename to ...
6893 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6894 instead call perror_with_name.
6895 (check_ptrace_stopped_lwp_gone): New function.
6896 (linux_resume_one_lwp): Reimplement as wrapper around
6897 linux_resume_one_lwp_throw that swallows errors if the LWP is
6900 2015-03-19 Pedro Alves <palves@redhat.com>
6902 * linux-low.c (count_events_callback, select_event_lwp_callback):
6903 No longer check whether the thread has resume_stop as last resume
6906 2015-03-19 Pedro Alves <palves@redhat.com>
6908 * linux-low.c (count_events_callback, select_event_lwp_callback):
6909 Use the lwp's status_pending_p field, not the thread's.
6911 2015-03-19 Pedro Alves <palves@redhat.com>
6913 * linux-low.c (select_event_lwp_callback): Update comments to
6914 no longer mention SIGTRAP.
6916 2015-03-18 Gary Benson <gbenson@redhat.com>
6918 * server.c (handle_query): Do not report vFile:fstat as supported.
6920 2015-03-11 Gary Benson <gbenson@redhat.com>
6922 * hostio.c (sys/types.h): New include.
6923 (sys/stat.h): Likewise.
6924 (common-remote-fileio.h): Likewise.
6925 (handle_fstat): New function.
6926 (handle_vFile): Handle vFile:fstat packets.
6928 2015-03-11 Gary Benson <gbenson@redhat.com>
6930 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6931 struct stat.st_blocks and struct stat.st_blksize.
6932 * configure: Regenerate.
6933 * config.in: Likewise.
6934 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6935 (OBS): Add common-remote-fileio.o.
6936 (common-remote-fileio.o): New rule.
6938 2015-03-09 Pedro Alves <palves@redhat.com>
6940 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6941 'struct sockaddr' pointer in 'accept' call.
6943 2015-03-09 Pedro Alves <palves@redhat.com>
6946 2015-03-07 Pedro Alves <palves@redhat.com>
6947 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6948 or <winsock2.h> here. Instead include "gdb_socket.h".
6949 (remote_open): Use union gdb_sockaddr_u.
6950 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6951 or <winsock2.h> here. Instead include "gdb_socket.h".
6952 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6953 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6955 (init_named_socket, gdb_agent_helper_thread): Use union
6958 2015-03-07 Pedro Alves <palves@redhat.com>
6960 * configure.ac (build_warnings): Move
6961 -Wdeclaration-after-statement to the C-specific set.
6962 * configure: Regenerate.
6964 2015-03-07 Pedro Alves <palves@redhat.com>
6966 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6967 or <winsock2.h> here. Instead include "gdb_socket.h".
6968 (remote_open): Use union gdb_sockaddr_u.
6969 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6970 or <winsock2.h> here. Instead include "gdb_socket.h".
6971 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6972 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6974 (init_named_socket, gdb_agent_helper_thread): Use union
6977 2015-03-07 Pedro Alves <palves@redhat.com>
6979 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6982 2015-03-06 Yao Qi <yao.qi@linaro.org>
6984 * linux-aarch64-low.c (aarch64_insert_point): Use
6985 show_debug_regs as a boolean.
6986 (aarch64_remove_point): Likewise.
6988 2015-03-05 Pedro Alves <palves@redhat.com>
6990 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6991 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6992 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6993 * nto-low.c (nto_target_ops): Likewise.
6994 * spu-low.c (spu_target_ops): Likewise.
6995 * win32-low.c (win32_target_ops): Likewise.
6997 2015-03-04 Pedro Alves <palves@redhat.com>
6999 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
7000 Decide whether a breakpoint triggered based on the SIGTRAP's
7002 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
7003 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
7004 (linux_low_filter_event): Check for breakpoints before checking
7006 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
7008 (linux_stopped_by_sw_breakpoint)
7009 (linux_supports_stopped_by_sw_breakpoint)
7010 (linux_stopped_by_hw_breakpoint)
7011 (linux_supports_stopped_by_hw_breakpoint): New functions.
7012 (linux_target_ops): Install new target methods.
7014 2015-03-04 Pedro Alves <palves@redhat.com>
7016 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
7017 * server.c (swbreak_feature, hwbreak_feature): New globals.
7018 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
7019 (captured_main): Clear swbreak_feature and hwbreak_feature.
7020 * server.h (swbreak_feature, hwbreak_feature): Declare.
7021 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
7022 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
7023 supports_stopped_by_hw_breakpoint>: New fields.
7024 (target_supports_stopped_by_sw_breakpoint)
7025 (target_stopped_by_sw_breakpoint)
7026 (target_supports_stopped_by_hw_breakpoint)
7027 (target_stopped_by_hw_breakpoint): Declare.
7029 2015-03-04 Pedro Alves <palves@redhat.com>
7031 enum lwp_stop_reason -> enum target_stop_reason
7032 * linux-low.c (check_stopped_by_breakpoint): Adjust.
7033 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
7034 (linux_wait_1, stuck_in_jump_pad_callback)
7035 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
7036 (linux_stopped_by_watchpoint):
7037 * linux-low.h (enum lwp_stop_reason): Delete.
7038 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
7039 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7041 2015-03-04 Yao Qi <yao.qi@linaro.org>
7043 * Makefile.in (SFILES): Add linux-aarch64-low.c.
7045 2015-03-03 Gary Benson <gbenson@redhat.com>
7047 * hostio.c (handle_vFile): Fix prefix lengths.
7049 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
7051 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
7054 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
7056 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
7057 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
7058 (clean): Add "rm -f" for above C files.
7059 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
7060 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
7061 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
7062 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
7063 * linux-s390-low.c (HWCAP_S390_VX): New macro.
7064 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
7065 (init_registers_s390x_vx_linux64)
7066 (init_registers_s390x_tevx_linux64)
7067 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
7068 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
7070 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
7071 (s390_store_vxrs_high): New functions.
7072 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
7074 (s390_arch_setup): Add logic for selecting one of the new target
7075 descriptions. Activate the new vector regsets if applicable.
7076 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
7077 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
7078 and init_registers_s390x_tevx_linux64.
7080 2015-03-01 Pedro Alves <palves@redhat.com>
7082 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
7085 2015-02-27 Pedro Alves <palves@redhat.com>
7087 * linux-x86-low.c (u_debugreg_offset): New function.
7088 (x86_linux_dr_get, x86_linux_dr_set): Use it.
7090 2015-02-27 Pedro Alves <palves@redhat.com>
7092 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
7093 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
7094 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
7095 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
7096 (ps_lsetfpregs, ps_getpid)
7097 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
7098 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
7099 (ps_lsetxregs, ps_plog): Declare.
7101 2015-02-27 Pedro Alves <palves@redhat.com>
7103 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
7104 IP_AGENT_EXPORT_FUNC.
7105 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
7106 IP_AGENT_EXPORT_FUNC.
7107 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
7108 (IP_AGENT_EXPORT): Delete.
7109 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7110 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7111 (gdb_trampoline_buffer_error, collecting, gdb_collect)
7112 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
7113 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
7114 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
7115 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
7116 (traceframe_read_count, traceframe_write_count)
7117 (traceframes_created, trace_state_variables, get_raw_reg)
7118 (get_trace_state_variable_value, set_trace_state_variable_value)
7119 (ust_loaded, helper_thread_id, cmd_buf): Use
7120 IPA_SYM_EXPORTED_NAME.
7121 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
7122 (tracepoints) Use IP_AGENT_EXPORT_VAR.
7123 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
7124 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7125 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
7126 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
7127 EXTERN_C_PUSH/EXTERN_C_POP.
7128 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
7129 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
7130 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7131 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
7132 (traceframe_write_count, traceframe_read_count)
7133 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
7134 (about_to_request_buffer_space, get_trace_state_variable_value)
7135 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
7136 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
7137 EXTERN_C_PUSH/EXTERN_C_POP.
7138 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
7139 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
7140 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
7141 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7142 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7143 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7144 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
7145 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
7147 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
7148 (IP_AGENT_EXPORT_VAR_DECL): Define.
7150 (gdb_agent_get_raw_reg): Declare.
7152 2015-02-27 Tom Tromey <tromey@redhat.com>
7153 Pedro Alves <palves@redhat.com>
7155 Rename symbols whose names are reserved C++ keywords throughout.
7157 2015-02-27 Pedro Alves <palves@redhat.com>
7159 * Makefile.in (COMPILER): New, get it from autoconf.
7160 (CXX): Get from autoconf instead.
7161 (COMPILE.pre): Use COMPILER.
7162 (CC-LD): Rename to ...
7163 (CC_LD): ... this. Use COMPILER.
7164 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
7165 (CXX_FOR_TARGET): Default to g++ instead of gcc.
7166 * acinclude.m4: Include build-with-cxx.m4.
7167 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
7168 Disable -Werror by default if building in C++ mode.
7169 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
7170 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
7171 the C++ compiler. Save/restore CXXFLAGS too.
7172 * configure: Regenerate.
7174 2015-02-27 Pedro Alves <palves@redhat.com>
7176 * acinclude.m4: Include libiberty.m4.
7177 * configure.ac: Call libiberty_INIT.
7178 * config.in, configure: Regenerate.
7180 2015-02-26 Pedro Alves <palves@redhat.com>
7182 * linux-low.c (linux_wait_1): When incrementing the PC past a
7183 program breakpoint always use the_low_target.breakpoint_len as
7184 increment, rather than the maximum between that and
7185 the_low_target.decr_pc_after_break.
7187 2015-02-23 Pedro Alves <palves@redhat.com>
7189 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
7190 thread was doing a step-over; always adjust the PC if
7191 we stepped over a permanent breakpoint.
7192 (linux_wait_1): If we stepped over breakpoint that was on top of a
7193 permanent breakpoint, manually advance the PC past it.
7195 2015-02-23 Pedro Alves <palves@redhat.com>
7197 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
7199 (x86_fill_gregset, x86_store_gregset): Use it when handling
7202 2015-02-20 Pedro Alves <palves@redhat.com>
7204 * thread-db.c: Include "nat/linux-procfs.h".
7205 (thread_db_init): Skip listing new threads if the kernel supports
7206 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
7208 2015-02-20 Pedro Alves <palves@redhat.com>
7210 * linux-low.c (status_pending_p_callback): Use ptid_match.
7212 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
7214 PR breakpoints/16812
7215 * linux-low.c (wstatus_maybe_breakpoint): Remove.
7216 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
7217 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
7219 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
7221 PR breakpoints/15956
7222 * tracepoint.c (cmd_qtinit): Add check for current_thread.
7224 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7226 * linux-low.c (linux_low_btrace_conf): Print size.
7227 * server.c (handle_btrace_conf_general_set): New.
7228 (hanle_general_set): Call handle_btrace_conf_general_set.
7229 (handle_query): Report Qbtrace-conf:bts:size as supported.
7231 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7233 * linux-low.c (linux_low_enable_btrace): Update parameters.
7234 (linux_low_btrace_conf): New.
7235 (linux_target_ops)<to_btrace_conf>: Initialize.
7236 * server.c (current_btrace_conf): New.
7237 (handle_btrace_enable): Rename to ...
7238 (handle_btrace_enable_bts): ... this. Pass ¤t_btrace_conf
7239 to target_enable_btrace. Update comment. Update users.
7240 (handle_qxfer_btrace_conf): New.
7241 (qxfer_packets): Add btrace-conf entry.
7242 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7243 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7244 (target_ops)<read_btrace_conf>: New.
7245 (target_enable_btrace): Update parameters.
7246 (target_read_btrace_conf): New.
7248 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7250 * server.c (handle_btrace_general_set): Remove call to
7251 target_supports_btrace.
7252 (supported_btrace_packets): New.
7253 (handle_query): Call supported_btrace_packets.
7254 * target.h: include btrace-common.h.
7255 (btrace_target_info): Removed.
7256 (supports_btrace, target_supports_btrace): Update parameters.
7258 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7260 * Makefile.in (SFILES): Add common/btrace-common.c.
7261 (OBS): Add common/btrace-common.o.
7262 (btrace-common.o): Add build rules.
7263 * linux-low: Include btrace-common.h.
7264 (linux_low_read_btrace): Use struct btrace_data. Call
7265 btrace_data_init and btrace_data_fini.
7267 2015-02-06 Pedro Alves <palves@redhat.com>
7269 * thread-db.c (find_new_threads_callback): Add debug output.
7271 2015-02-04 Pedro Alves <palves@redhat.com>
7273 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7274 (resume_stopped_resumed_lwps): New function.
7275 (linux_wait_for_event_filtered): Use it.
7277 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7279 * Makefile.in (SFILES): Add linux-personality.c.
7280 (linux-personality.o): New rule.
7281 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7282 list of objects to be built.
7283 * linux-low.c: Include nat/linux-personality.h.
7284 (linux_create_inferior): Remove code to disable address space
7285 randomization (moved to ../nat/linux-personality.c). Create
7286 cleanup to disable address space randomization.
7288 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7290 * Makefile.in (posix-strerror.o): New rule.
7291 (mingw-strerror.o): Likewise.
7292 * configure: Regenerated.
7293 * configure.ac: Source file ../common/common.host. Initialize new
7294 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7296 2015-01-14 Yao Qi <yao@codesourcery.com>
7298 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7299 (ppc-linux.o): New rule.
7300 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7301 * configure.ac: AC_CHECK_FUNCS(getauxval).
7302 * config.in: Re-generated.
7303 * configure: Re-generated.
7304 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7305 ppc64_64bit_inferior_p
7307 2015-01-14 Yao Qi <yao@codesourcery.com>
7309 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7310 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7311 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7312 (PT_ORIG_R3, PT_TRAP): Likewise.
7313 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7314 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7315 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7317 2015-01-10 Joel Brobecker <brobecker@adacore.com>
7319 * i387-fp.c (i387_cache_to_xsave): In look over
7320 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7321 zmmh_low_space field by use of zmmh_high_space.
7323 2015-01-09 Pedro Alves <palves@redhat.com>
7325 * linux-low.c (step_over_bkpt): Move higher up in the file.
7326 (handle_extended_wait): Don't store the stop_pc here.
7327 (get_stop_pc): Adjust comments and rename to ...
7328 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7329 stopped for a software breakpoint or hardware breakpoint.
7330 (thread_still_has_status_pending_p): New function.
7331 (status_pending_p_callback): Use
7332 thread_still_has_status_pending_p. If the event is no longer
7333 interesting, resume the LWP.
7334 (handle_tracepoints): Add assert.
7335 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7336 (wstatus_maybe_breakpoint): New function.
7337 (cancel_breakpoint): Delete function.
7338 (check_stopped_by_watchpoint): New function, factored out from
7339 linux_low_filter_event.
7340 (lp_status_maybe_breakpoint): Delete function.
7341 (linux_low_filter_event): Remove filter_ptid argument.
7342 Leave thread group exits pending here. Store the LWP's stop PC.
7343 Always leave events pending.
7344 (linux_wait_for_event_filtered): Pull all events out of the
7345 kernel, and leave them all pending.
7346 (count_events_callback, select_event_lwp_callback): Consider all
7348 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7349 (select_event_lwp): Only give preference to the stepping LWP in
7350 all-stop mode. Adjust comments.
7351 (ignore_event): New function.
7352 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7353 references to cancel_breakpoints. Adjust to renames. Also give
7354 equal priority to all LWPs that have had events in non-stop mode.
7355 If reporting a software breakpoint event, unadjust the LWP's PC.
7356 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7357 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7359 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7360 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7361 (linux_stopped_by_watchpoint): Adjust.
7362 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7363 * linux-low.h (enum lwp_stop_reason): New.
7364 (struct lwp_info) <stop_pc>: Adjust comment.
7365 <stopped_by_watchpoint>: Delete field.
7366 <stop_reason>: New field.
7367 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7368 * mem-break.c (software_breakpoint_inserted_here)
7369 (hardware_breakpoint_inserted_here): New function.
7370 * mem-break.h (software_breakpoint_inserted_here)
7371 (hardware_breakpoint_inserted_here): Declare.
7372 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7373 (cancel_breakpoints): Delete.
7374 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7375 (upload_fast_traceframes): Remove references to
7378 2015-01-09 Pedro Alves <palves@redhat.com>
7380 * thread-db.c (find_new_threads_callback): Ignore thread if the
7381 kernel thread ID is -1.
7383 2015-01-09 Pedro Alves <palves@redhat.com>
7385 * linux-low.c (linux_attach_fail_reason_string): Move to
7386 nat/linux-ptrace.c, and rename.
7387 (linux_attach_lwp): Update comment.
7388 (attach_proc_task_lwp_callback): New function.
7389 (linux_attach): Adjust to rename and use
7390 linux_proc_attach_tgid_threads.
7391 (linux_attach_fail_reason_string): Delete declaration.
7393 2015-01-01 Joel Brobecker <brobecker@adacore.com>
7395 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7396 * server.c (gdbserver_version): Likewise.
7398 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7400 * remote-utils.c: Include ctype.h.
7401 (input_interrupt): Explicitly handle the case when the char
7402 received is the NUL byte. Improve the printing of non-ASCII
7405 2014-12-16 Joel Brobecker <brobecker@adacore.com>
7407 * linux-low.c (linux_low_filter_event): Update call to
7408 linux_enable_event_reporting following the addition of
7409 a new parameter to that function.
7411 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
7414 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7415 (AARCH64_FPCR_REGNO): Likewise.
7416 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7417 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7418 (aarch64_store_fpregset): Likewise.
7420 2014-12-15 Joel Brobecker <brobecker@adacore.com>
7422 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7423 Remove FIXME comment about assumption about N.
7425 2014-12-13 Joel Brobecker <brobecker@adacore.com>
7427 * configure.ac: If large-file support is disabled in GDBserver,
7428 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7429 * configure: Regenerate.
7431 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7433 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7434 warning upon ENODATA from ptrace.
7435 * linux-s390-low.c (s390_store_tdb): New.
7436 (s390_regsets): Add regset for NT_S390_TDB.
7438 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7440 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7441 without a fill_function.
7442 * linux-s390-low.c (s390_fill_last_break): Remove.
7443 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7444 (s390_arch_setup): Use regset's size instead of fill_function for
7447 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7449 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7450 the regset's store function when ptrace returned an error.
7451 * regcache.c (get_thread_regcache): Invalidate register cache
7452 before fetching inferior's registers.
7454 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7456 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7457 while-loop as for-loop.
7458 (regsets_store_inferior_registers): Likewise.
7460 2014-11-28 Yao Qi <yao@codesourcery.com>
7462 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7463 * config.in, configure: Re-generate.
7464 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7467 2014-11-21 Yao Qi <yao@codesourcery.com>
7469 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7470 (AC_CHECK_HEADERS): Remove malloc.h.
7471 * configure: Re-generated.
7472 * config.in: Re-generated.
7473 * server.h: Don't include alloca.h and malloc.h.
7474 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7475 Don't include malloc.h.
7477 2014-11-17 Joel Brobecker <brobecker@adacore.com>
7479 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7480 corresponding ERRNO check in same block.
7482 2014-11-12 Pedro Alves <palves@redhat.com>
7484 * server.c (cont_thread): Update comment.
7485 (start_inferior, attach_inferior): No longer clear cont_thread.
7486 (handle_v_cont): No longer set cont_thread.
7487 (captured_main): Clear cont_thread each time a GDB connects.
7489 2014-11-12 Pedro Alves <palves@redhat.com>
7491 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7492 thread, and don't resume all threads if the Hc thread has exited.
7494 2014-11-12 Pedro Alves <palves@redhat.com>
7496 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7497 the process group instead of to a specific LWP.
7499 2014-10-15 Pedro Alves <palves@redhat.com>
7502 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7504 (arm_set_thread_context): Delete.
7505 (the_low_target): Adjust.
7506 * win32-i386-low.c (debug_registers_changed)
7507 (debug_registers_used): Delete.
7508 (update_debug_registers_callback): New function.
7509 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7510 needing to update their debug registers.
7511 (win32_get_current_dr): New function.
7512 (x86_dr_low_get_addr, x86_dr_low_get_control)
7513 (x86_dr_low_get_status): Fetch the debug register from the thread
7515 (i386_initial_stuff): Adjust.
7516 (i386_get_thread_context): Remove current_event parameter. Don't
7517 clear debug_registers_changed nor copy DR values to
7519 (i386_set_thread_context): Delete.
7520 (i386_prepare_to_resume): New function.
7521 (i386_thread_added): Mark the thread as needing to update irs
7523 (the_low_target): Remove i386_set_thread_context and install
7524 i386_prepare_to_resume.
7525 * win32-low.c (win32_get_thread_context): Adjust.
7526 (win32_set_thread_context): Use SetThreadContext
7528 (win32_prepare_to_resume): New function.
7529 (win32_require_context): New function, factored out from ...
7530 (thread_rec): ... this.
7531 (continue_one_thread): Call win32_prepare_to_resume on each thread
7532 we're about to continue.
7533 (win32_resume): Call win32_prepare_to_resume on the event thread.
7534 * win32-low.h (struct win32_thread_info)
7535 <debug_registers_changed>: New field.
7536 (struct win32_target_ops): Change prototype of set_thread_context,
7537 delete set_thread_context and add prepare_to_resume.
7538 (win32_require_context): New declaration.
7540 2014-10-08 Gary Benson <gbenson@redhat.com>
7542 * server.h: Do not include common-exceptions.h.
7544 2014-10-08 Gary Benson <gbenson@redhat.com>
7546 * server.h: Do not include cleanups.h.
7548 2014-09-30 James Hogan <james.hogan@imgtec.com>
7550 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7553 2014-09-23 Yao Qi <yao@codesourcery.com>
7555 * linux-low.c (lp_status_maybe_breakpoint): New function.
7556 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7557 (count_events_callback): Likewise.
7558 (select_event_lwp_callback): Likewise.
7559 (cancel_breakpoints_callback): Likewise.
7561 2014-09-19 Don Breazeal <donb@codesourcery.com>
7563 * linux-low.c (handle_extended_wait): Call
7564 linux_ptrace_get_extended_event.
7565 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7566 linux_is_extended_waitstatus.
7568 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7570 * Makefile.in (CPPFLAGS): Define.
7571 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7572 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7574 2014-09-16 Gary Benson <gbenson@redhat.com>
7576 * inferiors.h (current_inferior): Renamed as...
7577 (current_thread): New variable. All uses updated.
7578 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7579 (maybe_move_out_of_jump_pad): Likewise.
7580 (cancel_breakpoint): Likewise.
7581 (linux_low_filter_event): Likewise.
7582 (wait_for_sigstop): Likewise.
7583 (linux_resume_one_lwp): Likewise.
7584 (need_step_over_p): Likewise.
7585 (start_step_over): Likewise.
7586 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7587 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7588 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7589 and save_inferior as saved_thread.
7590 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7592 (regcache_invalidate_thread): Likewise.
7593 * remote-utils.c (prepare_resume_reply): Likewise.
7594 * thread-db.c (thread_db_get_tls_address): Likewise.
7595 (disable_thread_event_reporting): Likewise.
7596 (remove_thread_event_breakpoints): Likewise.
7597 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7599 * target.h (set_desired_inferior): Renamed as...
7600 (set_desired_thread): New declaration. All uses updated.
7601 * server.c (myresume): Updated comment to reference thread instead
7603 (handle_serial_event): Likewise.
7604 (handle_target_event): Likewise.
7606 2014-09-12 Tom Tromey <tromey@redhat.com>
7607 Gary Benson <gbenson@redhat.com>
7609 * regcache.h: Include common-regcache.h.
7610 (regcache_read_pc): Don't declare.
7611 * regcache.c (get_thread_regcache_for_ptid): New function.
7613 2014-09-11 Tom Tromey <tromey@redhat.com>
7614 Gary Benson <gbenson@redhat.com>
7616 * symbol.c: New file.
7617 * Makefile.in (SFILES): Add symbol.c.
7618 (OBS): Add symbol.o.
7620 2014-09-11 Gary Benson <gbenson@redhat.com>
7622 * target.c (target_stop_ptid, target_continue_ptid): New
7625 2014-09-11 Tom Tromey <tromey@redhat.com>
7626 Gary Benson <gbenson@redhat.com>
7628 * target.h: Include target/target.h.
7629 * target.c (target_read_memory, target_read_uint32)
7630 (target_write_memory): New functions.
7632 2014-09-11 Gary Benson <gbenson@redhat.com>
7634 * server.h (debug_hw_points): Don't declare.
7635 * server.c (debug_hw_points): Don't define. Replace all uses
7636 with show_debug_regs.
7637 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7638 all uses with show_debug_regs.
7640 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7642 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7643 endianness into account.
7644 (ppc_supply_ptrace_register): Likewise.
7646 2014-09-03 James Hogan <james.hogan@imgtec.com>
7648 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7649 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7651 2014-09-03 Gary Benson <gbenson@redhat.com>
7653 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7654 ALL_DEBUG_ADDRESS_REGISTERS.
7656 2014-09-02 Gary Benson <gbenson@redhat.com>
7658 * i386-low.h: Renamed as...
7659 * x86-low.h: New file. All type, function and variable name
7660 prefixes changed from "i386_" to "x86_". All references updated.
7661 * i386-low.c: Renamed as...
7662 * x86-low.c: New file. All type, function and variable name
7663 prefixes changed from "i386_" to "x86_". All references updated.
7665 2014-09-02 Gary Benson <gbenson@redhat.com>
7667 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7668 (x86_linux_new_thread): Likewise.
7670 2014-08-29 Gary Benson <gbenson@redhat.com>
7672 * server.h (setjmp.h): Do not include.
7673 (toplevel): Do not declare.
7674 (common-exceptions.h): Include.
7675 (cleanups.h): Likewise.
7676 * server.c (toplevel): Do not define.
7677 (exit_code): New static global.
7678 (detach_or_kill_for_exit_cleanup): New function.
7679 (main): New function. Original main renamed to...
7680 (captured_main): New function.
7681 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7683 2014-08-29 Gary Benson <gbenson@redhat.com>
7685 * Makefile.in (SFILES): Add common/common-exceptions.c.
7686 (OBS): Add common-exceptions.o.
7687 (common-exceptions.o): New rule.
7688 * utils.c (prepare_to_throw_exception): New function.
7690 2014-08-29 Gary Benson <gbenson@redhat.com>
7692 * config.in: Regenerate.
7693 * configure: Likewise.
7695 2014-08-29 Gary Benson <gbenson@redhat.com>
7697 * Makefile.in (SFILES): Add common/cleanups.c.
7699 (cleanups.o): New rule.
7701 2014-08-29 Gary Benson <gbenson@redhat.com>
7703 * utils.c (internal_vwarning): New function.
7705 2014-08-28 Gary Benson <gbenson@redhat.com>
7707 * utils.h (fatal): Remove declaration.
7708 * utils.c (fatal): Remove function.
7710 2014-08-28 Gary Benson <gbenson@redhat.com>
7712 * tracepoint.c (gdb_agent_init): Replace fatal with
7714 (initialize_tracepoint): Likewise.
7716 2014-08-28 Gary Benson <gbenson@redhat.com>
7718 * remote-utils.c (remote_prepare): Replace fatal with error.
7720 2014-08-28 Gary Benson <gbenson@redhat.com>
7722 * linux-low.c (linux_async): Replace fatal with warning.
7724 (linux_start_non_stop): Return -1 if linux_async failed.
7726 2014-08-28 Gary Benson <gbenson@redhat.com>
7728 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7730 (i386_dr_low_get_addr): Remove vague comment.
7731 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7734 2014-08-28 Gary Benson <gbenson@redhat.com>
7736 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7737 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7739 (linux_resume_one_lwp): Likewise.
7740 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7742 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7743 with internal_error.
7744 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7745 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7746 (find_register_by_name): Replace fatal with internal_error.
7747 (find_regno): Likewise.
7748 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7749 * thread-db.c (thread_db_create_event): Likewise.
7750 (thread_db_load_search): Likewise.
7751 (try_thread_db_load_1): Likewise.
7752 * tracepoint.c (get_jump_space_head): Replace fatal with
7754 (claim_trampoline_space): Likewise.
7755 (have_fast_tracepoint_trampoline_buffer): Likewise.
7756 (cmd_qtstart): Likewise.
7757 (stop_tracing): Likewise.
7758 (fast_tracepoint_collecting): Likewise.
7759 (target_malloc): Likewise.
7760 (download_tracepoint): Likewise.
7761 (download_trace_state_variables): Replace check with gdb_assert.
7762 (upload_fast_traceframes): Replace fatal with internal_error.
7764 2014-08-19 Tom Tromey <tromey@redhat.com>
7765 Gary Benson <gbenson@redhat.com>
7767 * Makefile.in (SFILES): Add common/common-debug.c.
7768 (OBS): Add common-debug.o.
7769 (common-debug.o): New rule.
7770 * debug.h (debug_printf): Don't declare.
7771 * debug.c (debug_printf): Renamed and rewritten as...
7772 (debug_vprintf): New function.
7774 2014-08-19 Gary Benson <gbenson@redhat.com>
7776 * utils.h: Do not include print-utils.h.
7778 2014-08-19 Tom Tromey <tromey@redhat.com>
7779 Gary Benson <gbenson@redhat.com>
7781 * server.h: Add static assertion.
7782 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7784 2014-08-19 Tom Tromey <tromey@redhat.com>
7785 Gary Benson <gbenson@redhat.com>
7787 * Makefile.in (SFILES): Add common/errors.c.
7788 (OBS): Add errors.o.
7789 (IPA_OBS): Add errors-ipa.o.
7790 (errors.o): New rule.
7791 (errors-ipa.o): Likewise.
7792 * utils.h (perror_with_name, error, warning): Don't declare.
7793 * utils.c (warning): Renamed and rewritten as...
7794 (vwarning): New function.
7795 (error): Renamed and rewritten as...
7796 (verror): New function.
7797 (internal_error): Renamed and rewritten as...
7798 (internal_verror): New function.
7800 2014-08-07 Gary Benson <gbenson@redhat.com>
7802 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7803 * configure: Regenerate.
7804 * config.in: Likewise.
7805 * server.h: Do not include errno.h.
7806 * event-loop.c: Likewise.
7807 * hostio-errno.c: Likewise.
7808 * linux-low.c: Likewise.
7809 * remote-utils.c: Likewise.
7810 * spu-low.c: Likewise.
7811 * utils.c: Likewise.
7812 * gdbreplay.c: Unconditionally include errno.h.
7814 2014-08-07 Gary Benson <gbenson@redhat.com>
7816 * server.h: Do not include string.h.
7817 * event-loop.c: Likewise.
7818 * linux-low.c: Likewise.
7819 * regcache.c: Likewise.
7820 * remote-utils.c: Likewise.
7821 * spu-low.c: Likewise.
7822 * utils.c: Likewise.
7824 2014-08-07 Gary Benson <gbenson@redhat.com>
7826 * server.h: Do not include gdb_assert.h.
7828 2014-08-07 Gary Benson <gbenson@redhat.com>
7830 * server.h: Do not include common-utils.h.
7832 2014-08-07 Gary Benson <gbenson@redhat.com>
7834 * server.h: Do not include ptid.h.
7835 * notif.h: Likewise.
7837 2014-08-07 Gary Benson <gbenson@redhat.com>
7839 * server.h: Do not include gdb_locale.h.
7841 2014-08-07 Gary Benson <gbenson@redhat.com>
7843 * server.h: Do not include gdb/signals.h.
7844 * win32-low.c: Likewise.
7846 2014-08-07 Gary Benson <gbenson@redhat.com>
7848 * server.h: Do not include pathmax.h.
7850 2014-08-07 Gary Benson <gbenson@redhat.com>
7852 * server.h: Do not include libiberty.h.
7853 * linux-bfin-low.c: Likewise.
7855 2014-08-07 Gary Benson <gbenson@redhat.com>
7857 * server.h: Do not include ansidecl.h.
7859 2014-08-07 Gary Benson <gbenson@redhat.com>
7861 * linux-x86-low.c: Do not include stddef.h.
7862 * lynx-ppc-low.c: Likewise.
7863 * tracepoint.c: Likewise.
7865 2014-08-07 Gary Benson <gbenson@redhat.com>
7867 * server.h: Do not include stdarg.h.
7868 * nto-low.c: Likewise.
7870 2014-08-07 Gary Benson <gbenson@redhat.com>
7872 * server.h: Do not include stdlib.h.
7873 * inferiors.c: Likewise.
7874 * linux-low.c: Likewise.
7875 * regcache.c: Likewise.
7876 * spu-low.c: Likewise.
7877 * tracepoint.c: Likewise.
7878 * utils.c: Likewise.
7880 2014-08-07 Gary Benson <gbenson@redhat.com>
7882 * server.h: Do not include stdio.h.
7883 * linux-low.c: Likewise.
7884 * remote-utils.c: Likewise.
7885 * spu-low.c: Likewise.
7886 * utils.c: Likewise.
7887 * wincecompat.c: Likewise.
7889 2014-08-06 Gary Benson <gbenson@redhat.com>
7891 * regcache.c (init_register_cache): Move conditionals inside if.
7893 2014-08-06 Gary Benson <gbenson@redhat.com>
7895 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7897 2014-07-31 Gary Benson <gbenson@redhat.com>
7899 * ax.h: Do not include server.h.
7900 * gdbthread.h: Likewise.
7901 * lynx-low.h: Likewise.
7902 * notif.h: Likewise.
7904 2014-07-30 Gary Benson <gbenson@redhat.com>
7906 * server.h: Include common-defs.h.
7907 Do not include config.h or build-gnulib-gdbserver/config.h.
7909 2014-07-30 Gary Benson <gbenson@redhat.com>
7911 * hostio-errno.c: Move server.h to top of includes list.
7912 * inferiors.c: Likewise.
7913 * linux-x86-low.c: Likewise.
7914 * notif.c: Include server.h.
7916 2014-07-24 Tom Tromey <tromey@redhat.com>
7917 Gary Benson <gbenson@redhat.com>
7919 * server.h (CORE_ADDR): Now unsigned.
7921 2014-07-16 Pedro Alves <palves@redhat.com>
7923 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7925 2014-07-15 Pedro Alves <palves@redhat.com>
7927 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7930 2014-07-11 Pedro Alves <palves@redhat.com>
7932 * linux-low.c (kill_wait_lwp): New function, based on
7933 kill_one_lwp_callback, but use my_waitpid directly.
7934 (kill_one_lwp_callback, linux_kill): Use it.
7936 2014-06-23 Pedro Alves <palves@redhat.com>
7938 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7939 before setting DR0..DR3.
7941 2014-06-20 Gary Benson <gbenson@redhat.com>
7943 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7944 * configure: Regenerated.
7945 * config.in: Likewise.
7947 2014-06-20 Gary Benson <gbenson@redhat.com>
7949 * Makefile.in (SFILES): Update locations for files moved
7951 (object file files): Reordered.
7953 2014-06-20 Gary Benson <gbenson@redhat.com>
7955 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7956 (i386_dr_low_set_addr): Likewise.
7957 (i386_dr_low_get_addr): Likewise.
7958 (i386_dr_low_can_set_control): Likewise.
7959 (i386_dr_low_set_control): Likewise.
7960 (i386_dr_low_get_control): Likewise.
7961 (i386_dr_low_get_status): Likewise.
7962 (i386_get_debug_register_length): Likewise.
7963 * linux-x86-low.c (i386_dr_low_set_addr):
7964 Changed signature. Made static.
7965 (i386_dr_low_get_addr): Likewise.
7966 (i386_dr_low_set_control): Likewise.
7967 (i386_dr_low_get_control): Likewise.
7968 (i386_dr_low_get_status): Likewise.
7969 (i386_dr_low): New global variable.
7970 * win32-i386-low.c (i386_dr_low_set_addr):
7971 Changed signature. Made static.
7972 (i386_dr_low_get_addr): Likewise.
7973 (i386_dr_low_set_control): Likewise.
7974 (i386_dr_low_get_control): Likewise.
7975 (i386_dr_low_get_status): Likewise.
7976 (i386_dr_low): New global variable.
7978 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7980 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7981 * Makefile.in (AR, AR_FLAGS): Define.
7982 * configure: Regenerate.
7984 2014-06-19 Gary Benson <gbenson@redhat.com>
7986 * Makefile.in (i386-dregs.o): New rule.
7987 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7988 * i386-low.c (target.h): Remove include.
7989 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7990 (DR_CONTROL_SHIFT): Likewise.
7991 (DR_CONTROL_SIZE): Likewise.
7992 (DR_RW_EXECUTE): Likewise.
7993 (DR_RW_WRITE): Likewise.
7994 (DR_RW_READ): Likewise.
7995 (DR_RW_IORW): Likewise.
7996 (DR_LEN_1): Likewise.
7997 (DR_LEN_2): Likewise.
7998 (DR_LEN_4): Likewise.
7999 (DR_LEN_8): Likewise.
8000 (DR_LOCAL_ENABLE_SHIFT): Likewise.
8001 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
8002 (DR_ENABLE_SIZE): Likewise.
8003 (DR_LOCAL_SLOWDOWN): Likewise.
8004 (DR_GLOBAL_SLOWDOWN): Likewise.
8005 (DR_CONTROL_RESERVED): Likewise.
8006 (I386_DR_CONTROL_MASK): Likewise.
8007 (I386_DR_VACANT): Likewise.
8008 (I386_DR_LOCAL_ENABLE): Likewise.
8009 (I386_DR_GLOBAL_ENABLE): Likewise.
8010 (I386_DR_DISABLE): Likewise.
8011 (I386_DR_SET_RW_LEN): Likewise.
8012 (I386_DR_GET_RW_LEN): Likewise.
8013 (I386_DR_WATCH_HIT): Likewise.
8014 (i386_wp_op_t): Likewise.
8015 (i386_show_dr): Likewise.
8016 (i386_length_and_rw_bits): Likewise.
8017 (i386_insert_aligned_watchpoint): Likewise.
8018 (i386_remove_aligned_watchpoint): Likewise.
8019 (i386_handle_nonaligned_watchpoint): Likewise.
8020 i386_update_inferior_debug_regs(): Likewise.
8021 (i386_dr_insert_watchpoint): Likewise.
8022 (i386_dr_remove_watchpoint): Likewise.
8023 (i386_dr_region_ok_for_watchpoint): Likewise.
8024 (i386_dr_stopped_data_address): Likewise.
8025 (i386_dr_stopped_by_watchpoint): Likewise.
8027 2014-06-19 Gary Benson <gbenson@redhat.com>
8029 * i386-low.c (i386_dr_show): Renamed to
8030 i386_show_dr and made static. All uses updated.
8031 (i386_dr_length_and_rw_bits): Renamed to
8032 i386_length_and_rw_bits and made static.
8034 (i386_dr_insert_aligned_watchpoint): Renamed to
8035 i386_insert_aligned_watchpoint and made static.
8037 (i386_dr_remove_aligned_watchpoint): Renamed to
8038 i386_remove_aligned_watchpoint and made static.
8040 (i386_dr_update_inferior_debug_regs): Renamed to
8041 i386_update_inferior_debug_regs and made static.
8044 2014-06-18 Gary Benson <gbenson@redhat.com>
8046 * i386-low.h (i386_dr_low_can_set_addr): New macro.
8047 (i386_dr_low_can_set_control): Likewise.
8048 (i386_get_debug_register_length): Likewise.
8049 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
8050 (i386_dr_low_can_set_control): Likewise.
8051 (i386_get_debug_register_length): Likewise.
8053 2014-06-17 Gary Benson <gbenson@redhat.com>
8055 * i386-low.h (i386-dregs.h): New include.
8056 (DR_FIRSTADDR): Now in i386-dregs.h.
8057 (DR_LASTADDR): Likewise.
8058 (DR_NADDR): Likewise.
8059 (DR_STATUS): Likewise.
8060 (DR_CONTROL): Likewise.
8061 (i386_debug_reg_state): Likewise.
8062 (i386_dr_insert_watchpoint): Likewise.
8063 (i386_dr_remove_watchpoint): Likewise.
8064 (i386_dr_region_ok_for_watchpoint): Likewise.
8065 (i386_dr_stopped_data_address): Likewise.
8066 (i386_dr_stopped_by_watchpoint): Likewise.
8067 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
8069 2014-06-18 Gary Benson <gbenson@redhat.com>
8071 * i386-low.h (i386_low_insert_watchpoint): Renamed to
8072 i386_dr_insert_watchpoint.
8073 (i386_low_remove_watchpoint): Renamed to
8074 i386_dr_remove_watchpoint.
8075 (i386_low_region_ok_for_watchpoint): Renamed to
8076 i386_dr_region_ok_for_watchpoint.
8077 (i386_low_stopped_data_address): Renamed to
8078 i386_dr_stopped_data_address.
8079 (i386_low_stopped_by_watchpoint): Renamed to
8080 i386_dr_stopped_by_watchpoint.
8081 * i386-low.c (i386_show_dr): Renamed to
8082 i386_dr_show and made nonstatic. All uses updated.
8083 (i386_length_and_rw_bits): Renamed to
8084 i386_dr_length_and_rw_bits and made nonstatic.
8086 (i386_insert_aligned_watchpoint): Renamed to
8087 i386_dr_insert_aligned_watchpoint and made nonstatic.
8089 (i386_remove_aligned_watchpoint): Renamed to
8090 i386_dr_remove_aligned_watchpoint and made nonstatic.
8092 (i386_update_inferior_debug_regs): Renamed to
8093 i386_dr_update_inferior_debug_regs and made nonstatic.
8095 (i386_low_insert_watchpoint): Renamed to
8096 i386_dr_insert_watchpoint. All uses updated.
8097 (i386_low_remove_watchpoint): Renamed to
8098 i386_dr_remove_watchpoint. All uses updated.
8099 (i386_low_region_ok_for_watchpoint): Renamed to
8100 i386_dr_region_ok_for_watchpoint. All uses updated.
8101 (i386_low_stopped_data_address): Renamed to
8102 i386_dr_stopped_data_address. All uses updated.
8103 (i386_low_stopped_by_watchpoint): Renamed to
8104 i386_dr_stopped_by_watchpoint. All uses updated.
8106 2014-06-18 Gary Benson <gbenson@redhat.com>
8108 * i386-low.c (i386_dr_low_can_set_addr): New macro.
8109 (i386_dr_low_can_set_control): Likewise.
8110 (i386_insert_aligned_watchpoint): New check.
8112 2014-06-18 Gary Benson <gbenson@redhat.com>
8114 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
8117 2014-06-18 Gary Benson <gbenson@redhat.com>
8119 * i386-low.c (i386_length_and_rw_bits): Use internal_error
8120 instead of fatal and error.
8121 (i386_handle_nonaligned_watchpoint): Likewise.
8123 2014-06-18 Gary Benson <gbenson@redhat.com>
8125 * i386-low.c (i386_get_debug_register_length): New macro.
8126 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
8127 (i386_show_dr): Use debug_printf instead of fprintf. Use
8128 phex to format values.
8130 2014-06-18 Gary Benson <gbenson@redhat.com>
8132 * i386-low.h: Comment changes.
8133 * i386-low.c: Likewise.
8135 2014-06-18 Gary Benson <gbenson@redhat.com>
8137 * i386-low.c: Whitespace changes.
8139 2014-06-12 Tom Tromey <tromey@redhat.com>
8141 * utils.c (freeargv): Remove.
8143 2014-06-12 Tom Tromey <tromey@redhat.com>
8145 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
8146 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
8147 (parse_debug_format_options): Likewise.
8148 (gdbserver_usage): Likewise.
8149 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
8150 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
8151 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
8153 ($(LIBGNU)): Depend on libiberty.
8154 (all-lib): Recurse into all subdirs.
8155 (install-only): Invoke "install" target in subdirs.
8156 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
8158 * configure: Rebuild.
8159 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
8160 for vasprintf, vsnprintf, or gettimeofday.
8161 * configure.srv: Don't add safe-ctype.o or lbasename.o to
8164 2014-06-05 Joel Brobecker <brobecker@adacore.com>
8166 * development.sh: Delete.
8167 * Makefile.in (config.status): Adjust dependency on development.sh.
8168 * configure.ac: Adjust development.sh source call.
8169 * configure: Regenerate.
8171 2014-06-02 Pedro Alves <palves@redhat.com>
8173 * ax.c (gdb_free_agent_expr): New function.
8174 * ax.h (gdb_free_agent_expr): New declaration.
8175 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
8177 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
8179 (clear_breakpoint_conditions_and_commands): New function.
8180 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
8181 (clear_breakpoint_conditions_and_commands): New declaration.
8183 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8185 * linux-aarch64-low.c (asm/ptrace.h): Include.
8187 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8189 Fix TLS access for -static -pthread.
8190 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
8191 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
8192 (thread_db_load_search, try_thread_db_load_1): Initialize it.
8194 2014-05-20 Pedro Alves <palves@redhat.com>
8196 * linux-aarch64-low.c (aarch64_insert_point)
8197 (aarch64_remove_point): No longer check whether the type is
8198 supported here. Adjust to new interface.
8199 (the_low_target): Install aarch64_supports_z_point_type as
8200 supports_z_point_type method.
8201 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
8202 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
8203 instead of a Z packet char. Adjust.
8204 (arm_supports_z_point_type): New function.
8205 (arm_insert_point, arm_remove_point): Adjust to new interface.
8206 (the_low_target): Install arm_supports_z_point_type.
8207 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
8208 (cris_insert_point, cris_remove_point): Adjust to new interface.
8209 Don't check whether the type is supported here.
8210 (the_low_target): Install cris_supports_z_point_type.
8211 * linux-low.c (linux_supports_z_point_type): New function.
8212 (linux_insert_point, linux_remove_point): Adjust to new interface.
8213 * linux-low.h (struct linux_target_ops) <insert_point,
8214 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
8215 raw_breakpoint pointer parameter.
8216 <supports_z_point_type>: New method.
8217 * linux-mips-low.c (mips_supports_z_point_type): New function.
8218 (mips_insert_point, mips_remove_point): Adjust to new interface.
8219 Use mips_supports_z_point_type.
8220 (the_low_target): Install mips_supports_z_point_type.
8221 * linux-ppc-low.c (the_low_target): Install NULL as
8222 supports_z_point_type method.
8223 * linux-s390-low.c (the_low_target): Install NULL as
8224 supports_z_point_type method.
8225 * linux-sparc-low.c (the_low_target): Install NULL as
8226 supports_z_point_type method.
8227 * linux-x86-low.c (x86_supports_z_point_type): New function.
8228 (x86_insert_point): Adjust to new insert_point interface. Use
8229 insert_memory_breakpoint. Adjust to new
8230 i386_low_insert_watchpoint interface.
8231 (x86_remove_point): Adjust to remove_point interface. Use
8232 remove_memory_breakpoint. Adjust to new
8233 i386_low_remove_watchpoint interface.
8234 (the_low_target): Install x86_supports_z_point_type.
8235 * lynx-low.c (lynx_target_ops): Install NULL as
8236 supports_z_point_type callback.
8237 * nto-low.c (nto_supports_z_point_type): New.
8238 (nto_insert_point, nto_remove_point): Adjust to new interface.
8239 (nto_target_ops): Install nto_supports_z_point_type.
8240 * mem-break.c: Adjust intro comment.
8241 (struct raw_breakpoint) <raw_type, size>: New fields.
8242 <inserted>: Update comment.
8243 <shlib_disabled>: Delete field.
8244 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8245 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8246 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8247 (raw_bkpt_type_to_target_hw_bp_type): New function.
8248 (find_enabled_raw_code_breakpoint_at): New function.
8249 (find_raw_breakpoint_at): New type and size parameters. Use them.
8250 (insert_memory_breakpoint): New function, based off
8251 set_raw_breakpoint_at.
8252 (remove_memory_breakpoint): New function.
8253 (set_raw_breakpoint_at): Reimplement.
8254 (set_breakpoint): New, based on set_breakpoint_at.
8255 (set_breakpoint_at): Reimplement.
8256 (delete_raw_breakpoint): Go through the_target->remove_point
8257 instead of assuming memory breakpoints.
8258 (find_gdb_breakpoint_at): Delete.
8259 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8260 (find_gdb_breakpoint): New function.
8261 (set_gdb_breakpoint_at): Delete.
8262 (z_type_supported): New function.
8263 (set_gdb_breakpoint_1): New function, loosely based off
8264 set_gdb_breakpoint_at.
8265 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8266 (delete_gdb_breakpoint_at): Delete.
8267 (delete_gdb_breakpoint_1): New function, loosely based off
8268 delete_gdb_breakpoint_at.
8269 (delete_gdb_breakpoint): New function.
8270 (clear_gdb_breakpoint_conditions): Rename to ...
8271 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8273 (add_condition_to_breakpoint): Make static.
8274 (add_breakpoint_condition): Take a struct breakpoint pointer
8275 instead of an address. Adjust.
8276 (gdb_condition_true_at_breakpoint): Rename to ...
8277 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8279 (gdb_condition_true_at_breakpoint): Reimplement.
8280 (add_breakpoint_commands): Take a struct breakpoint pointer
8281 instead of an address. Adjust.
8282 (gdb_no_commands_at_breakpoint): Rename to ...
8283 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8284 parameter. Return true if no breakpoint was found. Change debug
8286 (gdb_no_commands_at_breakpoint): Reimplement.
8287 (run_breakpoint_commands): Rename to ...
8288 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8289 and change return type to boolean.
8290 (run_breakpoint_commands): New function.
8291 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8292 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8293 breakpoint. Go through the_target->remove_point instead of
8294 assuming memory breakpoint.
8295 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8296 software and hardware breakpoints.
8297 (reinsert_raw_breakpoint): Go through the_target->insert_point
8298 instead of assuming memory breakpoint.
8299 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8300 software and hardware breakpoints.
8301 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8302 Check both software and hardware breakpoints.
8303 (validate_inserted_breakpoint): Assert the breakpoint is a
8304 software breakpoint. Set the inserted flag to -1 instead of
8305 setting shlib_disabled.
8306 (delete_disabled_breakpoints): Adjust.
8307 (validate_breakpoints): Only validate software breakpoints.
8308 Adjust to inserted flag change.
8309 (check_mem_read, check_mem_write): Skip breakpoint types other
8310 than software breakpoints. Adjust to inserted flag change.
8311 * mem-break.h (enum raw_bkpt_type): New enum.
8312 (raw_breakpoint, struct process_info): Forward declare.
8313 (Z_packet_to_target_hw_bp_type): Delete declaration.
8314 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8315 (set_gdb_breakpoint, delete_gdb_breakpoint)
8316 (clear_breakpoint_conditions): New declarations.
8317 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8318 (breakpoint_inserted_here): Update comment.
8319 (add_breakpoint_condition, add_breakpoint_commands): Replace
8320 address parameter with a breakpoint pointer parameter.
8321 (gdb_breakpoint_here): Update comment.
8322 (delete_gdb_breakpoint_at): Delete.
8323 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8324 * server.c (process_point_options): Take a struct breakpoint
8325 pointer instead of an address. Adjust.
8326 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8327 delete_gdb_breakpoint.
8328 * spu-low.c (spu_target_ops): Install NULL as
8329 supports_z_point_type method.
8330 * target.h: Include mem-break.h.
8331 (struct target_ops) <prepare_to_access_memory>: Update comment.
8332 <supports_z_point_type>: New field.
8333 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8334 instead of a char. Also take a raw breakpoint pointer.
8335 * win32-arm-low.c (the_low_target): Install NULL as
8336 supports_z_point_type.
8337 * win32-i386-low.c (i386_supports_z_point_type): New function.
8338 (i386_insert_point, i386_remove_point): Adjust to new interface.
8339 (the_low_target): Install i386_supports_z_point_type.
8340 * win32-low.c (win32_supports_z_point_type): New function.
8341 (win32_insert_point, win32_remove_point): Adjust to new interface.
8342 (win32_target_ops): Install win32_supports_z_point_type.
8343 * win32-low.h (struct win32_target_ops):
8344 <supports_z_point_type>: New method.
8345 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8346 instead of a char. Also take a raw breakpoint pointer.
8348 2014-05-20 Pedro Alves <palves@redhat.com>
8350 * mem-break.h: Include break-common.h.
8351 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8352 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8353 (Z_packet_to_target_hw_bp_type): New declaration.
8354 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8355 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8356 (Z_PACKET_ACCESS_WP): Delete macros.
8357 (Z_packet_to_hw_type): Delete function.
8358 * i386-low.h: Don't include break-common.h here.
8359 (Z_packet_to_hw_type): Delete declaration.
8360 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8361 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8362 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8363 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8364 * linux-aarch64-low.c: Don't include break-common.h here.
8365 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8366 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8367 (Z_packet_to_target_hw_bp_type): Delete function.
8368 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8370 (mips_insert_point, mips_remove_point): Use
8371 Z_packet_to_target_hw_bp_type.
8373 2014-05-20 Pedro Alves <palves@redhat.com>
8375 * linux-aarch64-low.c: Include break-common.h.
8376 (enum target_point_type): Delete.
8377 (Z_packet_to_point_type): Rename to ...
8378 (Z_packet_to_target_hw_bp_type): ... this, and return a
8379 target_hw_bp_type instead.
8380 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8381 instead of an enum target_point_type.
8382 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8384 (aarch64_dr_state_insert_one_point)
8385 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8386 (aarch64_handle_aligned_watchpoint)
8387 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8388 Take an enum target_hw_bp_type instead of an enum
8390 (aarch64_supports_z_point_type): New function.
8391 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8392 use Z_packet_to_target_hw_bp_type.
8394 2014-05-20 Joel Brobecker <brobecker@adacore.com>
8396 * configure.ac: Only use -Werror by default when DEVELOPMENT
8398 * configure: Regenerate.
8400 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8402 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8403 * linux-x86-low.c (X86_64_USER_REGS): New.
8404 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8406 2014-04-28 Yao Qi <yao@codesourcery.com>
8408 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8411 2014-04-25 Pedro Alves <palves@redhat.com>
8414 * linux-low.c (linux_attach_fail_reason_string): New function.
8415 (linux_attach_lwp): Delete.
8416 (linux_attach_lwp_1): Rename to ...
8417 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8418 argument. Remove "initial" parameter. Return int instead of
8419 void. Don't error or warn here.
8420 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8421 failure to attach to the tgid. Call warning when failing to
8423 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
8424 argument. Remove "initial" parameter. Return int instead of
8425 void. Don't error or warn here.
8426 (linux_attach_fail_reason_string): New declaration.
8427 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8428 interface change. Use linux_attach_fail_reason_string.
8430 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
8431 Walfred Tedeschi <walfred.tedeschi@intel.com>
8433 * Makefile.in: Added rules to handle new files
8434 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8435 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8436 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8437 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8438 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8439 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8441 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8442 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8443 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8444 i386/x32-avx512.xml.
8445 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8446 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8447 i386/x32-avx512-linux.xml.
8448 * i387-fp.c (num_avx512_k_registers): New constant for number
8450 (num_avx512_zmmh_low_registers): New constant for number of
8451 lower ZMM registers (0-15).
8452 (num_avx512_zmmh_high_registers): New constant for number of
8453 higher ZMM registers (16-31).
8454 (num_avx512_ymmh_registers): New contant for number of higher
8455 YMM registers (ymm16-31 added by avx521 on x86_64).
8456 (num_avx512_xmm_registers): New constant for number of higher
8457 XMM registers (xmm16-31 added by AVX512 on x86_64).
8458 (struct i387_xsave): Add space for AVX512 registers.
8459 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8460 Add code to handle AVX512 registers.
8461 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8462 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8463 prototypei from generated file.
8464 (tdesc_amd64_avx512_linux): Likewise.
8465 (init_registers_x32_avx512_linux): Likewise.
8466 (tdesc_x32_avx512_linux): Likewise.
8467 (init_registers_i386_avx512_linux): Likewise.
8468 (tdesc_i386_avx512_linux): Likewise.
8469 (x86_64_regmap): Add AVX512 registers.
8470 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8472 (initialize_low_arch): Add code to initialize AVX512 registers.
8474 2014-04-23 Pedro Alves <palves@redhat.com>
8476 * mem-break.c (find_gdb_breakpoint_at): Make static.
8477 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8479 2014-04-23 Pedro Alves <palves@redhat.com>
8481 * i386-low.c: Don't include break-common.h here.
8482 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8483 prototype to take target_hw_bp_type as argument instead of a Z
8485 * i386-low.h: Include break-common.h here.
8486 (Z_packet_to_hw_type): Declare.
8487 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8489 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8490 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8491 (x86_remove_point): Convert the packet number to a
8492 target_hw_bp_type before calling i386_low_remove_watchpoint.
8493 * win32-i386-low.c (i386_insert_point): Convert the packet number
8494 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8495 (i386_remove_point): Convert the packet number to a
8496 target_hw_bp_type before calling i386_low_remove_watchpoint.
8498 2014-04-23 Pedro Alves <palves@redhat.com>
8500 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8502 2014-04-10 Pedro Alves <palves@redhat.com>
8504 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8505 Check if the condition or command is NULL before checking if the
8506 breakpoint is known. On success, return true.
8507 * mem-break.h (add_breakpoint_condition): Document return.
8508 (add_breakpoint_commands): Add describing comment.
8509 * server.c (skip_to_semicolon): New function.
8510 (process_point_options): Use it.
8512 2014-04-09 Pedro Alves <palves@redhat.com>
8514 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8517 2014-02-27 Pedro Alves <palves@redhat.com>
8520 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8522 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8524 (last_thread_of_process_p): Take a PID argument instead of a
8526 (linux_wait_for_lwp): Delete.
8527 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8529 (linux_low_filter_event): New function, party factored out from
8530 linux_wait_for_event.
8531 (linux_wait_for_event): Rename to ...
8532 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8533 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8534 sigsuspend. Check for zombie leaders.
8535 (linux_wait_for_event): Reimplement as wrapper around
8536 linux_wait_for_event_filtered.
8537 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8538 a normal or signal exit is seen, it's the whole process exiting.
8539 (wait_for_sigstop): No longer a for_each_inferior callback.
8540 Rewrite on top of linux_wait_for_event_filtered.
8541 (stop_all_lwps): Call wait_for_sigstop directly.
8542 * server.c (resume, handle_target_event): Handle
8543 TARGET_WAITKIND_NO_RESUMED.
8545 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8547 * win32-low.c (psapi_get_dll_name,
8548 * win32_CreateToolhelp32Snapshot): Delete.
8549 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8550 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8552 (handle_load_dll): Add function description.
8553 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8555 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8557 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8559 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8560 base address when calling win32_add_one_solib.
8561 (handle_load_dll): Delete local variable load_addr.
8562 Remove 0x1000 offset applied to DLL base address when calling
8563 win32_add_one_solib.
8564 (handle_unload_dll): Add comment.
8566 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8568 * win32-low.c (win32_add_all_dlls): Renames
8569 win32_ensure_ntdll_loaded. Rewrite function documentation.
8570 Adjust implementation to always load all DLLs.
8571 Add 0x1000 offset to DLL base address when calling
8572 win32_add_one_solib.
8573 (child_initialization_done): New static global.
8574 (do_initial_child_stuff): Set child_initialization_done to
8575 zero during child initialization, and 1 after. Replace call
8576 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8578 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8579 (handle_unload_dll): Add function documentation.
8580 (get_child_debug_event): Ignore load and unload DLL events
8581 during child initialization.
8583 2014-02-20 Doug Evans <dje@google.com>
8585 Remove global all_lwps.
8586 * inferiors.h (ptid_of): Move here from linux-low.h.
8587 (pid_of, lwpid_of): Ditto.
8588 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8589 parameter is a struct thread_info * now.
8590 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8591 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8592 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8594 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8595 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8596 * linux-arm-low.c (update_registers_callback): Update, "entry"
8597 parameter is a struct thread_info * now.
8598 Fetch lwpid from current_inferior directly.
8599 (arm_insert_point): Pass &all_threads to find_inferior instead of
8601 (arm_remove_point): Ditto.
8602 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8603 (arm_prepare_to_resume): Fetch pid from thread.
8604 (arm_read_description): Fetch lwpid from current_inferior directly.
8605 * linux-low.c (all_lwps): Delete.
8606 (delete_lwp): Delete call to remove_inferior.
8607 (handle_extended_wait): Fetch lwpid from thread.
8608 (add_lwp): Don't set lwp->entry.id. Remove call to
8609 add_inferior_to_list.
8610 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8611 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8612 (kill_one_lwp_callback): Ditto.
8613 (linux_kill): Don't dereference NULL pointer.
8614 Fetch ptid,lwpid from thread.
8615 (get_detach_signal): Fetch ptid from thread.
8616 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8617 Simplify call to regcache_invalidate_thread.
8618 (delete_lwp_callback): Update, "entry" parameter is a
8619 struct thread_info * now. Fetch pid from thread.
8620 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8621 (status_pending_p_callback): Update, "entry" parameter is a
8622 struct thread_info * now. Fetch ptid from thread.
8623 (find_lwp_pid): Update, "entry" parameter is a
8624 struct thread_info * now.
8625 (linux_wait_for_lwp): Fetch pid from thread.
8626 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8627 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8628 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8629 (dequeue_one_deferred_signal): Ditto.
8630 (cancel_breakpoint): Fetch ptid from current_inferior.
8631 (linux_wait_for_event): Pass &all_threads to find_inferior,
8632 not &all_lwps. Fetch ptid, lwpid from thread.
8633 (count_events_callback): Update, "entry" parameter is a
8634 struct thread_info * now.
8635 (select_singlestep_lwp_callback): Ditto.
8636 (select_event_lwp_callback): Ditto.
8637 (cancel_breakpoints_callback): Ditto.
8638 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8640 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8641 (unsuspend_one_lwp): Update, "entry" parameter is a
8642 struct thread_info * now.
8643 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8645 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8646 Fetch lwpid from thread, not lwp.
8647 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8648 Pass &all_threads to find_inferior, not &all_lwps.
8649 (send_sigstop): Fetch lwpid from thread, not lwp.
8650 (send_sigstop_callback): Update, "entry" parameter is a
8651 struct thread_info * now.
8652 (suspend_and_send_sigstop_callback): Ditto.
8653 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8654 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8655 struct thread_info * now.
8656 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8658 (lwp_running): Update, "entry" parameter is a
8659 struct thread_info * now.
8660 (stop_all_lwps): Fetch ptid from thread.
8661 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8662 (linux_resume_one_lwp): Fetch lwpid from thread.
8663 (linux_set_resume_request): Update, "entry" parameter is a
8664 struct thread_info * now. Fetch pid, lwpid from thread.
8665 (resume_status_pending_p): Update, "entry" parameter is a
8666 struct thread_info * now.
8667 (need_step_over_p): Ditto. Fetch lwpid from thread.
8668 (start_step_over): Fetch lwpid from thread.
8669 (linux_resume_one_thread): Update, "entry" parameter is a
8670 struct thread_info * now. Fetch lwpid from thread.
8671 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8672 (proceed_one_lwp): Update, "entry" parameter is a
8673 struct thread_info * now. Fetch lwpid from thread.
8674 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8675 struct thread_info * now.
8676 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8677 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8678 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8680 (regsets_store_inferior_registers): Ditto.
8681 (fetch_register, store_register): Ditto.
8682 (linux_read_memory, linux_write_memory): Ditto.
8683 (linux_request_interrupt): Ditto.
8684 (linux_read_auxv): Ditto.
8685 (linux_xfer_siginfo): Ditto.
8686 (linux_qxfer_spu): Ditto.
8687 (linux_qxfer_libraries_svr4): Ditto.
8688 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8689 moved to inferiors.h.
8691 (get_thread_lwp): Update.
8692 (struct lwp_info): Delete member "entry". Simplify comment for
8695 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8696 current_inferior directly.
8697 (update_watch_registers_callback): Update, "entry" parameter is a
8698 struct thread_info * now. Fetch pid from thread.
8699 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8700 (mips_insert_point): Fetch lwpid from current_inferior.
8701 Pass &all_threads to find_inferior, not &all_lwps.
8702 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8703 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8705 (mips_stopped_data_address): Ditto.
8706 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8708 * linux-tile-low.c (tile_arch_setup): Ditto.
8709 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8710 (update_debug_registers_callback): Update, "entry" parameter is a
8711 struct thread_info * now. Fetch pid from thread.
8712 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8713 Pass &all_threads to find_inferior, not &all_lwps.
8714 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8715 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8716 Pass &all_threads to find_inferior, not &all_lwps.
8717 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8718 (i386_dr_low_get_status): Ditto.
8719 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8720 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8721 (x86_linux_read_description): Ditto.
8722 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8724 2014-02-20 Doug Evans <dje@google.com>
8726 * inferiors.c (get_first_inferior): Fix buglet.
8728 2014-02-19 Doug Evans <dje@google.com>
8730 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8731 * inferiors.c (add_thread): Change result type to struct thread_info *.
8732 All callers updated.
8733 (add_lwp): Call add_thread here instead of in callers.
8734 All callers updated.
8735 * linux-low.h (get_lwp_thread): Rewrite.
8736 (struct lwp_info): New member "thread".
8738 2014-02-19 Doug Evans <dje@google.com>
8740 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8741 All callers updated.
8743 2014-02-19 Doug Evans <dje@google.com>
8745 * inferiors.c (add_thread): Fix whitespace.
8747 2014-02-19 Doug Evans <dje@google.com>
8749 * dll.c (clear_dlls): Replace accessing list implemention details
8751 * gdbthread.h (get_first_thread): Declare.
8752 * inferiors.c (for_each_inferior_with_data): New function.
8753 (get_first_thread): New function.
8754 (find_thread_ptid): Simplify.
8755 (get_first_inferior): New function.
8756 (clear_list): Delete.
8757 (one_inferior_p): New function.
8758 (clear_inferior_list): New function.
8759 (clear_inferiors): Update.
8760 * inferiors.h (for_each_inferior_with_data): Declare.
8761 (clear_inferior_list): Declare.
8762 (one_inferior_p): Declare.
8763 (get_first_inferior): Declare.
8764 * linux-low.c (linux_wait_for_event): Replace accessing list
8765 implemention details with API function.
8766 * server.c (target_running): Ditto.
8767 (accumulate_file_name_length): New function.
8768 (emit_dll_description): New function.
8769 (handle_qxfer_libraries): Replace accessing list implemention
8770 details with API function.
8771 (handle_qxfer_threads_worker): New function.
8772 (handle_qxfer_threads_proper): Replace accessing list implemention
8773 details with API function.
8774 (handle_query): Ditto.
8775 (visit_actioned_threads_callback_ftype): New typedef.
8776 (visit_actioned_threads_data): New struct.
8777 (visit_actioned_threads): Rewrite to be find_inferior callback.
8778 (resume): Call find_inferior.
8779 (handle_status): Replace accessing list implemention
8780 details with API function.
8781 (process_serial_event): Replace accessing list implemention details
8783 * target.c (set_desired_inferior): Replace accessing list implemention
8784 details with API function.
8785 * tracepoint.c (same_process_p): New function.
8786 (gdb_agent_about_to_close): Replace accessing list implemention
8787 details with API function.
8788 * win32-low.c (child_delete_thread): Replace accessing list
8789 implemention details with API function.
8790 (match_dll_by_basename): New function.
8791 (dll_is_loaded_by_basename): New function.
8792 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8793 details call to dll_is_loaded_by_basename.
8795 2014-02-19 Doug Evans <dje@google.com>
8797 * dll.h (struct dll_info): Add comment.
8798 * gdbthread.h (struct thread_info): Add comment.
8799 (current_ptid): Simplify.
8800 * inferiors.c (add_process): Update.
8801 (remove_process): Update.
8802 * inferiors.h (struct process_info): Rename member "head" to "entry".
8803 * linux-low.c (delete_lwp): Update.
8805 (last_thread_of_process_p): Update.
8806 (kill_one_lwp_callback, linux_kill): Update.
8807 (status_pending_p_callback): Update.
8808 (wait_for_sigstop): Update. Simplify read of ptid.
8809 (start_step_over): Update.
8810 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8811 (get_lwp_thread): Update.
8812 (struct lwp_info): Rename member "head" to "entry".
8813 * regcache.h (inferior_list_entry): Delete.
8814 * server.c (kill_inferior_callback): Update.
8815 (detach_or_kill_inferior_callback): Update.
8816 (print_started_pid): Update.
8817 (print_attached_pid): Update.
8818 (process_serial_event): Simplify read of ptid.
8819 * thread-db.c (thread_db_create_event): Update.
8820 (thread_db_get_tls_address): Update.
8821 * win32-low.c (current_inferior_ptid): Simplify.
8823 2014-02-19 Tom Tromey <tromey@redhat.com>
8825 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8827 (target_supports_btrace): Update.
8829 2014-02-14 Yao Qi <yao@codesourcery.com>
8831 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8832 (rsp-low-ipa.o): New target.
8834 2014-02-12 Tom Tromey <tromey@redhat.com>
8836 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8837 convert_ascii_to_int.
8838 * regcache.c (registers_to_string): Likewise.
8839 * remote-utils.c (decode_M_packet): Likewise.
8840 * server.c (process_serial_event): Likewise.
8842 2014-02-12 Tom Tromey <tromey@redhat.com>
8844 * server.c (handle_query, handle_v_run): Use hex2bin, not
8846 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8848 2014-02-12 Tom Tromey <tromey@redhat.com>
8850 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8851 convert_int_to_ascii.
8852 * regcache.c (registers_to_string, collect_register_as_string):
8854 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8856 * server.c (process_serial_event): Likewise.
8857 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8858 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8860 2014-02-12 Tom Tromey <tromey@redhat.com>
8862 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8863 bin2hex, not hexify.
8864 * tracepoint.c (cmd_qtstatus): Likewise.
8866 2014-02-12 Tom Tromey <tromey@redhat.com>
8868 * remote-utils.c (monitor_output): Pass explicit length to
8871 2014-02-12 Tom Tromey <tromey@redhat.com>
8873 * tracepoint.c: Include rsp-low.h.
8874 * server.c: Include rsp-low.h.
8875 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8876 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8878 * remote-utils.c: Include rsp-low.h.
8879 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8880 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8881 (convert_int_to_ascii, convert_ascii_to_int): Move to
8883 * regcache.c: Include rsp-low.h.
8884 * ax.c: Include rsp-low.h.
8885 * Makefile.in (SFILES): Add common/rsp-low.c.
8886 (OBS): Add rsp-low.o.
8887 (rsp-low.o): New target.
8889 2014-02-12 Tom Tromey <tromey@redhat.com>
8891 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8892 Include print-utils.h.
8893 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8894 (plongest, thirty_two, phex_nz): Remove.
8895 * Makefile.in (SFILES): Add common/print-utils.c.
8896 (OBS): Add print-utils.o.
8897 (print-utils-ipa.o): New target.
8898 (print-utils.o): New target.
8899 (IPA_OBJS): Add print-utils-ipa.o.
8901 2014-02-06 Tom Tromey <tromey@redhat.com>
8903 * Makefile.in (SFILES): Fix indentation.
8905 2014-02-05 Doug Evans <dje@google.com>
8907 * linux-low.c (linux_wait_for_event): Improve comment.
8908 (linux_wait_1): Keep current_inferior in sync with event_child.
8910 2014-01-22 Doug Evans <dje@google.com>
8912 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8914 2014-01-22 Doug Evans <dje@google.com>
8916 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8917 * configure: Regenerate.
8918 * config.in: Regenerate.
8919 * Makefile.in (SFILES): Add debug.c.
8921 * debug.c: New file.
8922 * debug.h: New file.
8923 * linux-aarch64-low.c (*): Update all debugging printfs to use
8924 debug_printf instead of fprintf.
8925 * linux-arm-low.c (*): Ditto.
8926 * linux-cris-low.c (*): Ditto.
8927 * linux-crisv32-low.c (*): Ditto.
8928 * linux-m32r-low.c (*): Ditto.
8929 * linux-sparc-low.c (*): Ditto.
8930 * linux-x86.c (*): Ditto.
8931 * linux-low.c (*): Ditto.
8932 (linux_wait_1): Add calls to debug_enter, debug_exit.
8933 (linux_wait): Remove redundant debugging printf.
8934 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8935 (linux_resume, unstop_all_lwps): Ditto.
8936 * mem-break.c (*): Update all debugging printfs to use
8937 debug_printf instead of fprintf.
8938 * remote-utils.c (*): Ditto.
8939 * thread-db.c (*): Ditto.
8940 * server.c #include <ctype.h>, "gdb_vecs.h".
8941 (debug_threads): Moved to debug.c.
8942 (*): Update all debugging printfs to use debug_printf instead of
8944 (start_inferior): Replace call to fflush with call to debug_flush.
8945 (monitor_show_help): Mention set debug-format.
8946 (parse_debug_format_options): New function.
8947 (handle_monitor_command): Handle "monitor set debug-format".
8948 (gdbserver_usage): Mention --debug-format.
8949 (main): Parse --debug-format.
8950 * server.h (debug_threads): Declaration moved to debug.h.
8952 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8953 trace_debug_1 that uses debug_printf.
8954 (tracepoint_look_up_symbols): Update all debugging printfs to use
8955 debug_printf instead of fprintf.
8957 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8959 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8962 2014-01-17 Pedro Alves <palves@redhat.com>
8965 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8966 defined after including gdb_proc_service.h.
8968 2014-01-16 Doug Evans <dje@google.com>
8970 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8971 (match_dll): Use it.
8973 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8975 * target.h (target_ops) <read_btrace>: Change parameters and
8976 return type to allow error reporting.
8977 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8978 trace reading errors on.
8979 * linux-low.c (linux_low_read_btrace): Pass trace reading
8981 (linux_low_disable_btrace): New.
8983 2014-01-15 Doug Evans <dje@google.com>
8985 * inferiors.c (thread_id_to_gdb_id): Delete.
8986 * inferiors.h (thread_id_to_gdb_id): Delete.
8988 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8990 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8991 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8994 2014-01-08 Pedro Alves <palves@redhat.com>
8996 * server.c (handle_status): Don't discard previous queued stop
8997 replies or thread's pending status here.
8998 (main) <disconnection>: Do it here instead.
9000 2014-01-08 Pedro Alves <palves@redhat.com>
9002 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
9003 * server.c (visit_actioned_threads, handle_pending_status): New
9005 (handle_v_cont): Factor out parts to ...
9006 (resume): ... this new function. If in all-stop, and a thread
9007 being resumed has a pending status, report it without actually
9009 (myresume): Adjust to use the new 'resume' function.
9010 (clear_pending_status_callback, set_pending_status_callback)
9011 (find_status_pending_thread_callback): New functions.
9012 (handle_status): Handle the case of multiple threads having
9013 interesting statuses to report. Report threads' real last signal
9014 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
9015 with an interesting thread to report the status for, instead of
9016 always reporting the status of the first thread.
9018 2014-01-01 Joel Brobecker <brobecker@adacore.com>
9020 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
9021 * gdbreplay.c (gdbreplay_version): Likewise.
9023 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
9025 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
9026 iov.iov_len with the real length in use.
9028 2013-12-13 Joel Brobecker <brobecker@adacore.com>
9030 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
9031 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
9032 for all targets that use win32-low.c.
9033 * win32-low.c (win32_ensure_ntdll_loaded): New function.
9034 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
9036 2013-12-13 Pedro Alves <palves@redhat.com>
9038 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
9039 if equal to TARGET_WAITKIND_LOADED.
9040 * win32-low.c (cached_status): New static global.
9041 (win32_wait): Add declaration.
9042 (do_initial_child_stuff): Flush all initial pending debug events
9043 up to the initial breakpoint.
9044 (win32_wait): If CACHED_STATUS was set, return that instead
9045 of doing a real wait. Remove the code resuming the execution
9046 of the inferior after receiving a TARGET_WAITKIND_LOADED event
9047 during the initial phase. Also remove the code changing
9048 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
9049 TARGET_WAITKIND_STOPPED.
9051 2013-12-11 Yao Qi <yao@codesourcery.com>
9053 * notif.c (handle_notif_ack): Return 0 if no notification
9056 2013-11-20 Doug Evans <dje@google.com>
9058 * linux-low.c (linux_set_resume_request): Fix comment.
9060 2013-11-20 Doug Evans <dje@google.com>
9062 * linux-low.c (resume_status_pending_p): Tweak comment.
9064 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
9066 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
9067 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
9068 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
9069 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
9070 (srv_amd64_regobj): Add amd64-mpx.o.
9071 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
9072 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
9073 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
9074 * i387-fp.c (num_pl_bnd_register) Added constant.
9075 (num_pl_bnd_cfg_registers) Added constant.
9076 (struct i387_xsave) Added reserved area and MPX fields.
9077 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
9078 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
9080 (tdesc_i386_mpx_linux): Add MPX amd64 target.
9081 (init_registers_amd64_mpx_linux): Declare new function.
9082 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
9083 (x86_64_regmap): Add MPX registers.
9084 (x86_linux_read_description): Add MPX case.
9085 (initialize_low_arch): Initialize MPX targets.
9087 2013-11-18 Tom Tromey <tromey@redhat.com>
9089 * configure: Rebuild.
9090 * configure.ac: Don't check for stdlib.h.
9091 * gdbreplay.c: Unconditionally include stdlib.h.
9093 2013-11-18 Tom Tromey <tromey@redhat.com>
9095 * config.in: Rebuild.
9096 * configure: Rebuild.
9097 * configure.ac: Don't use AC_HEADER_DIRENT.
9099 2013-11-18 Tom Tromey <tromey@redhat.com>
9101 * server.h: Don't check HAVE_STRING_H.
9102 * gdbreplay.c: Don't check HAVE_STRING_H.
9103 * configure: Rebuild.
9105 2013-11-18 Tom Tromey <tromey@redhat.com>
9107 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
9110 2013-11-08 Tom Tromey <tromey@redhat.com>
9112 * configure, config.in: Rebuild.
9113 * configure.ac: Remove unused configury.
9115 2013-11-08 Tom Tromey <tromey@redhat.com>
9117 * acinclude.m4: Include common.m4, codeset.m4.
9118 * configure, config.in: Rebuild.
9119 * configure.ac: Use GDB_AC_COMMON.
9121 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
9123 * linux-s390-low.c (HWCAP_S390_TE): New define.
9124 (s390_arch_setup): Consider the TE field in the HWCAP for
9125 determining 'have_regset_tdb'.
9127 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
9130 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
9133 2013-10-02 Pedro Alves <palves@redhat.com>
9135 * server.c (process_serial_event): Don't output "GDBserver
9136 exiting" if GDB is connected through stdio.
9137 * target.c (mywait): Likewise, be silent if GDB is connected
9140 2013-10-01 Joel Brobecker <brobecker@adacore.com>
9142 * lynx-low.c (lynx_add_threads_after_attach): New function.
9143 (lynx_attach): Remove call to add_thread. Add call to
9144 lynx_add_threads_after_attach instead.
9146 2013-09-28 Mike Frysinger <vapier@gentoo.org>
9148 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
9149 * config.in, configure: Regenerated.
9151 2013-09-18 Yao Qi <yao@codesourcery.com>
9154 * server.c (start_inferior): Clear 'resume_info'.
9156 2013-09-16 Jiong Wang <jiwang@tilera.com>
9158 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
9161 2013-09-16 Jiong Wang <jiwang@tilera.com>
9163 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
9164 linux-tile-low.o to srv_tgtobj.
9166 2013-09-16 Will Newton <will.newton@linaro.org>
9168 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
9171 2013-09-06 Pedro Alves <palves@redhat.com>
9173 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
9174 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
9175 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
9176 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
9177 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
9178 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
9180 2013-09-06 Pedro Alves <palves@redhat.com>
9182 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
9183 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
9185 2013-09-06 Pedro Alves <palves@redhat.com>
9187 * linux-amd64-ipa.c: Include tracepoint.h.
9188 * linux-i386-ipa.c: Include tracepoint.h.
9190 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9192 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
9193 (ps_get_thread_area): New function.
9195 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9197 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
9198 (initialize_low_arch): Call init_registers_crisv32 rather than
9199 init_register_crisv32.
9201 2013-09-05 Pedro Alves <palves@redhat.com>
9203 * server.h (handle_vFile, hostio_last_error_from_errno): Move
9205 * hostio.h: ... this new file.
9206 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
9207 win32-low.c: Include hostio.h.
9209 2013-09-05 Pedro Alves <palves@redhat.com>
9211 * server.h (gdb_client_data, handler_func, callback_handler_func)
9212 (delete_file_handler, add_file_handler, append_callback_event)
9213 (delete_callback_event, start_event_loop, initialize_event_loop):
9214 Move to event-loop.h and include it.
9215 * event-loop.h: New file.
9217 2013-09-05 Pedro Alves <palves@redhat.com>
9219 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
9220 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
9221 (loaded_dll, unloaded_dll): Move to ...
9222 * dll.h: ... this new file.
9223 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
9225 2013-09-05 Pedro Alves <palves@redhat.com>
9227 * server.h (current_process, get_thread_process, all_processes)
9228 (add_inferior_to_list, for_each_inferior, current_inferior)
9229 (remove_inferior, add_process, remove_process, find_process_pid)
9230 (have_started_inferiors_p, have_attached_inferiors_p)
9231 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
9232 (clear_inferiors, find_inferior, find_inferior_id)
9233 (inferior_target_data, set_inferior_target_data)
9234 (inferior_regcache_data, set_inferior_regcache_data): Move to
9235 inferiors.h, and include it.
9236 * inferiors.h: New file.
9238 2013-09-05 Pedro Alves <palves@redhat.com>
9240 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9244 2013-09-05 Pedro Alves <palves@redhat.com>
9246 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9248 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9249 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9250 (handle_tracepoint_general_set, handle_tracepoint_query)
9251 (tracepoint_finished_step, tracepoint_was_hit)
9252 (release_while_stepping_state_list, current_traceframe)
9253 (in_readonly_region, traceframe_read_mem)
9254 (fetch_traceframe_registers, traceframe_read_sdata)
9255 (traceframe_read_info, struct fast_tpoint_collect_status)
9256 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9257 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9258 (supply_fast_tracepoint_registers)
9259 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9260 (ipa_tdesc, claim_trampoline_space)
9261 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9262 (agent_mem_read, agent_get_trace_state_variable_value)
9263 (agent_set_trace_state_variable_value, agent_tsv_read)
9264 (agent_mem_read_string, get_raw_reg_func_addr)
9265 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9266 * tracepoint.h: ... this new file.
9268 2013-09-05 Pedro Alves <palves@redhat.com>
9270 * server.h (perror_with_name, error, fatal, warning, paddress)
9271 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9273 * utils.h: New file.
9275 2013-09-05 Pedro Alves <palves@redhat.com>
9277 * server.h (remote_debug, noack_mode, transport_is_reliable)
9278 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9279 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9280 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9281 (write_enn, initialize_async_io, enable_async_io)
9282 (disable_async_io, check_remote_input_interrupt_request)
9283 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9284 (dead_thread_notify, prepare_resume_reply)
9285 (decode_address_to_semicolon, decode_address, decode_m_packet)
9286 (decode_M_packet, decode_X_packet, decode_xfer_write)
9287 (decode_search_memory_packet, unhexify, hexify)
9288 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9289 (look_up_one_symbol, relocate_instruction)
9290 (monitor_output): Move to remote-utils.h, and include it.
9291 * remote-utils.h: New file.
9293 2013-09-05 Pedro Alves <palves@redhat.com>
9295 * server.h (_): Delete.
9297 2013-09-02 Pedro Alves <palves@redhat.com>
9299 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9300 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9302 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9304 2013-09-02 Pierre Muller <muller@sourceware.org>
9306 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9307 or WriteProcessMemory complete successfully and handle
9308 ERROR_PARTIAL_COPY error.
9310 2013-09-02 Pedro Alves <palves@redhat.com>
9312 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9313 error instead of EIO.
9315 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9318 * linux-low.c: Include filestuff.h.
9319 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9320 * lynx-low.c: Include filestuff.h.
9321 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9322 * server.c: Include filestuff.h.
9323 (main): Call notice_open_fds.
9324 * spu-low.c: Include filestuff.h.
9325 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9327 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
9329 * Makefile.in: Explain why ../target and ../nat are not
9330 listed as include file search paths.
9331 (linux-waitpid.o): New object file rule.
9332 * configure.srv (srv_native_linux_obj): New variable.
9333 Replace all occurrences of linux native object files with
9334 $srv_native_linux_obj.
9335 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9336 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9337 (linux_enable_event_reporting): Remove declaration.
9338 (my_waitpid): Moved to common/linux-waitpid.c.
9339 (linux_wait_for_event): Pass ptid when calling
9340 linux_enable_event_reporting.
9341 (linux_supports_tracefork_flag): Remove.
9342 (linux_enable_event_reporting): Likewise.
9343 (linux_tracefork_grandchild): Remove.
9344 (STACK_SIZE): Moved to common/linux-ptrace.c.
9345 (linux_tracefork_child): Remove.
9346 (linux_test_for_tracefork): Remove.
9347 (linux_look_up_symbols): Call linux_supports_traceclone.
9348 (initialize_low): Remove call to linux_test_for_tracefork.
9349 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9350 common/linux-ptrace.h.
9351 (PTRACE_TYPE_ARG4): Likewise.
9352 Include linux-ptrace.h.
9354 2013-08-21 Pedro Alves <palves@redhat.com>
9356 * config.in: Renegerate.
9358 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
9360 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9361 (SFILES): Remove $(srcdir)/common/target-common.c and
9362 add $(srcdir)/target/waitstatus.c.
9363 (OBS): Remove target-common.o and add waitstatus.o.
9364 (server_h): Remove $(srcdir)/../common/target-common.h and
9365 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9366 and $(srcdir)/../target/waitstatus.h.
9367 (target-common.o): Remove.
9368 (waitstatus.o): New target object file.
9369 * target.h: Do not include target-common.h and
9370 include target/resume.h, target/wait.h and
9371 target/waitstatus.h.
9373 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
9375 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9376 to PTRACE_TYPE_ARG3.
9377 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9378 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9380 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9381 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9383 2013-07-27 Jie Zhang <jie@codesourcery.com>
9384 Daniel Jacobowitz <dan@codesourcery.com>
9385 Yao Qi <yao@codesourcery.com>
9387 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9388 (mips-linux-watch.o): New rule.
9389 (mips_linux_watch_h): New variable.
9390 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9392 * linux-mips-low.c: Include mips-linux-watch.h.
9393 (struct arch_process_info, struct arch_lwp_info): New.
9394 (update_watch_registers_callback): New function.
9395 (mips_linux_new_process, mips_linux_new_thread) New functions.
9396 (mips_linux_prepare_to_resume, mips_insert_point): New
9398 (mips_remove_point, mips_stopped_by_watchpoint): New
9400 (rsp_bp_type_to_target_hw_bp_type): New function.
9401 (mips_stopped_data_address): New function.
9402 (the_low_target): Add watchpoint support functions.
9404 2013-07-27 Yao Qi <yao@codesourcery.com>
9406 * i386-low.c: Include break-common.h.
9407 (enum target_hw_bp_type): Remove.
9409 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
9411 * Makefile.in (SFILES): /common/target-common.c.
9412 (OBS): Add target-common.o.
9413 (server_h): Add $(srcdir)/../common/target-common.h.
9414 (target-common.o): New target.
9415 * server.c (queue_stop_reply_callback): Free
9416 status string after use.
9417 * target.c (target_waitstatus_to_string): Remove.
9418 * target.h: Include target-common.h.
9419 (resume_kind): Likewise.
9420 (target_waitkind): Likewise.
9421 (target_waitstatus): Likewise.
9422 (TARGET_WNOHANG): Likewise.
9424 2013-07-04 Yao Qi <yao@codesourcery.com>
9426 * Makefile.in (host_alias): Use @host_noncanonical@.
9427 (target_alias): Use @target_noncanonical@.
9428 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9429 ACX_NONCANONICAL_HOST.
9430 * configure: Regenerated.
9433 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9435 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9436 * configure: Rebuild.
9437 * Makefile.in (version_host, version_target): Get from configure.
9438 (version.c): Use $(version_host) and $(version_target).
9440 2013-07-03 Pedro Alves <palves@redhat.com>
9442 * Makefile.in (config.status): Depend on development.sh.
9443 * acinclude.m4: Include libmcheck.m4.
9444 * configure: Regenerate.
9446 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9448 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9449 attribute inside the parentheses.
9450 (winapi_DebugSetProcessKillOnExit): Ditto.
9451 (winapi_DebugBreakProcess): Ditto.
9452 (winapi_GenerateConsoleCtrlEvent): Ditto.
9454 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9456 * notif.h (notif_event): Add a dummy member to avoid compiler
9459 2013-07-01 Pedro Alves <palves@redhat.com>
9461 * hostio.c (HOSTIO_PATH_MAX): Define.
9462 (require_filename, handle_open, handle_unlink, handle_readlink):
9465 2013-07-01 Pedro Alves <palves@redhat.com>
9467 * server.h: Include "pathmax.h".
9468 * linux-low.c: Don't include sys/param.h.
9469 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9471 * win32-low.c: Don't include sys/param.h.
9472 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9474 2013-07-01 Pedro Alves <palves@redhat.com>
9476 * event-loop.c: Don't check HAVE_UNISTD_H before including
9478 * gdbreplay.c: Likewise.
9479 * remote-utils.c: Likewise.
9480 * server.c: Likewise.
9481 * configure.ac: Don't check for unistd.h.
9482 * configure: Regenerate.
9484 2013-06-28 Tom Tromey <tromey@redhat.com>
9486 * Makefile.in (version.c): Use version.in, not
9489 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9491 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9492 * configure: Rebuild.
9493 * Makefile.in (version_host, version_target): Get from configure.
9494 (version.c): Use $(version_host) and $(version_target).
9496 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9498 Fix trace-status to output user name without trailing colon.
9499 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9501 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9503 Fix trace-status to output proper start-time and stop-time.
9504 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9505 output start time and stop time in hex as gdb expects.
9507 2013-06-26 Pedro Alves <pedro@codesourcery.com>
9509 * tracepoint.c (build_traceframe_info_xml): Output trace state
9510 variables present in the trace buffer.
9512 2013-06-24 Tom Tromey <tromey@redhat.com>
9514 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9516 (version.o): Remove.
9517 * gdbreplay.c: Include version.h.
9518 (version, host_name): Don't declare.
9519 * server.h: Include version.h.
9520 (version, host_name): Don't declare.
9522 2013-06-12 Pedro Alves <palves@redhat.com>
9524 * linux-x86-low.c (linux_is_elf64): Delete global.
9525 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9526 with local linux_pid_exe_is_elf_64_file use.
9528 2013-06-11 Pedro Alves <palves@redhat.com>
9530 * linux-low.c (regset_disabled, disable_regset): New functions.
9531 (regsets_fetch_inferior_registers)
9532 (regsets_store_inferior_registers): Use them.
9533 (initialize_regsets_info); Don't allocate the disabled_regsets
9535 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9538 2013-06-11 Pedro Alves <palves@redhat.com>
9540 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9543 2013-06-11 Pedro Alves <palves@redhat.com>
9545 * linux-x86-low.c (initialize_low_arch): Call
9546 init_registers_x32_avx_linux.
9548 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9550 Fix compatibility with Android Bionic.
9551 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9554 2013-06-07 Pedro Alves <palves@redhat.com>
9557 * Makefile.in (OBS): Add tdesc.o.
9558 (IPA_OBJS): Add tdesc-ipa.o.
9559 (tdesc-ipa.o): New rule.
9560 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9562 * linux-low.c (new_inferior): Delete.
9563 (disabled_regsets, num_regsets): Delete.
9564 (linux_add_process): Adjust to set the new per-process
9566 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9567 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9568 was a stop. When calling arch_setup, switch the current inferior
9569 to the thread that got an event.
9570 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9571 (regsets_fetch_inferior_registers)
9572 (regsets_store_inferior_registers): New regsets_info parameter.
9574 (linux_register_in_regsets): New regs_info parameter. Adjust to
9576 (register_addr, fetch_register, store_register): New usrregs_info
9577 parameter. Adjust to use it.
9578 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9579 parameter regs_info. Adjust to use it.
9580 (linux_fetch_registers): Get the current inferior's regs_info, and
9582 (linux_store_registers): Ditto.
9583 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9584 (initialize_low): Don't initialize the target_regsets here. Call
9585 initialize_low_arch.
9586 * linux-low.h (target_regsets): Delete declaration.
9587 (struct regsets_info): New.
9588 (struct usrregs_info): New.
9589 (struct regs_info): New.
9590 (struct process_info_private) <new_inferior>: New field.
9591 (struct linux_target_ops): Delete the num_regs, regmap, and
9592 regset_bitmap fields. New field regs_info.
9593 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9594 * i387-fp.c (num_xmm_registers): Delete.
9595 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9596 calls to new interface.
9597 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9598 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9599 Infer the number of xmm registers from the regcache's target
9601 * i387-fp.h (num_xmm_registers): Delete.
9602 * inferiors.c (add_thread): Don't install the thread's regcache
9604 * proc-service.c (gregset_info): Fetch the current inferior's
9605 regs_info. Adjust to use it.
9606 * regcache.c: Include tdesc.h.
9607 (register_bytes, reg_defs, num_registers)
9608 (gdbserver_expedite_regs): Delete.
9609 (get_thread_regcache): If the thread doesn't have a regcache yet,
9610 create one, instead of aborting gdbserver.
9611 (regcache_invalidate_one): Rename to ...
9612 (regcache_invalidate_thread): ... this.
9613 (regcache_invalidate_one): New.
9614 (regcache_invalidate): Only invalidate registers of the current
9616 (init_register_cache): Add target_desc parameter, and use it.
9617 (new_register_cache): Ditto. Assert the target description has a
9618 non zero registers_size.
9619 (regcache_cpy): Add assertions. Adjust.
9620 (realloc_register_cache, set_register_cache): Delete.
9621 (registers_to_string, registers_from_string): Adjust.
9622 (find_register_by_name, find_regno, find_register_by_number)
9623 (register_cache_size): Add target_desc parameter, and use it.
9624 (free_register_cache_thread, free_register_cache_thread_one)
9625 (regcache_release, register_cache_size): New.
9626 (register_size): Add target_desc parameter, and use it.
9627 (register_data, supply_register, supply_register_zeroed)
9628 (supply_regblock, supply_register_by_name, collect_register)
9629 (collect_register_as_string, collect_register_by_name): Adjust.
9630 * regcache.h (struct target_desc): Forward declare.
9631 (struct regcache) <tdesc>: New field.
9632 (init_register_cache, new_register_cache): Add target_desc
9634 (regcache_invalidate_thread): Declare.
9635 (regcache_invalidate_one): Delete declaration.
9636 (regcache_release): Declare.
9637 (find_register_by_number, register_cache_size, register_size)
9638 (find_regno): Add target_desc parameter.
9639 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9641 * remote-utils.c: Include tdesc.h.
9642 (outreg, prepare_resume_reply): Adjust.
9643 * server.c: Include tdesc.h.
9644 (gdbserver_xmltarget): Delete declaration.
9645 (get_features_xml, process_serial_event): Adjust.
9646 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9648 (struct process_info) <tdesc>: New field.
9649 (ipa_tdesc): Declare.
9650 * tdesc.c: New file.
9651 * tdesc.h: New file.
9652 * tracepoint.c: Include tdesc.h.
9653 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9654 (get_context_regcache): Adjust to pass ipa_tdesc down.
9655 (do_action_at_tracepoint): Adjust to get the register cache size
9656 from the context regcache's description.
9657 (traceframe_walk_blocks): Adjust to get the register cache size
9658 from the current trace frame's description.
9659 (traceframe_get_pc): Adjust to get current trace frame's
9660 description and pass it down.
9661 (gdb_collect): Adjust to get the register cache size from the
9663 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9664 (gdbserver_xmltarget): Delete.
9665 (initialize_low_tracepoint): Set the ipa's target description.
9666 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9667 (initialize_low_tracepoint): Set the ipa's target description.
9668 * linux-x86-low.c: Include tdesc.h.
9669 [__x86_64__] (is_64bit_tdesc): New.
9670 (ps_get_thread_area, x86_get_thread_area): Use it.
9671 (i386_cannot_store_register): Rename to ...
9672 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9673 (i386_cannot_fetch_register): Rename to ...
9674 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9675 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9677 (target_regsets): Rename to ...
9678 (x86_regsets): ... this.
9679 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9681 (x86_siginfo_fixup): Use is_64bit_tdesc.
9682 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9683 (tdesc_x32_avx_linux, tdesc_x32_linux)
9684 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9686 (x86_linux_update_xmltarget): Delete.
9687 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9688 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9689 (AMD64_LINUX_USER64_CS): New.
9690 (x86_linux_read_description): New, based on
9691 x86_linux_update_xmltarget.
9692 (same_process_callback): New.
9693 (x86_arch_setup_process_callback): New.
9694 (x86_linux_update_xmltarget): New.
9695 (x86_regsets_info): New.
9696 (amd64_linux_regs_info): New.
9697 (i386_linux_usrregs_info): New.
9698 (i386_linux_regs_info): New.
9699 (x86_linux_regs_info): New.
9700 (x86_arch_setup): Reimplement.
9701 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9702 (x86_emit_ops): Ditto.
9703 (the_low_target): Adjust. Install x86_linux_regs_info,
9704 x86_cannot_fetch_register, and x86_cannot_store_register.
9705 (initialize_low_arch): New.
9706 * linux-ia64-low.c (tdesc_ia64): Declare.
9707 (ia64_fetch_register): Adjust.
9708 (ia64_usrregs_info, regs_info): New globals.
9709 (ia64_regs_info): New function.
9710 (the_low_target): Adjust.
9711 (initialize_low_arch): New function.
9712 * linux-sparc-low.c (tdesc_sparc64): Declare.
9713 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9715 (sparc_arch_setup): New function.
9716 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9717 (the_low_target): Adjust.
9718 (initialize_low_arch): New function.
9719 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9720 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9721 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9722 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9723 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9724 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9725 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9726 (tdesc_powerpc_isa205_vsx64l): Declare.
9727 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9728 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9729 (ppc_set_pc, ppc_get_hwcap): Adjust.
9730 (ppc_usrregs_info): Forward declare.
9731 (!__powerpc64__) ppc_regmap_adjusted: New global.
9732 (ppc_arch_setup): Adjust to the current process'es target
9734 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9735 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9736 (ppc_store_evrregset): Adjust.
9737 (target_regsets): Rename to ...
9738 (ppc_regsets): ... this, and make static.
9739 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9740 (ppc_regs_info): New function.
9741 (the_low_target): Adjust.
9742 (initialize_low_arch): New function.
9743 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9744 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9745 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9746 (tdesc_s390x_linux64v2): Declare.
9747 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9748 (s390_fill_gregset, s390_store_last_break): Adjust.
9749 (target_regsets): Rename to ...
9750 (s390_regsets): ... this, and make static.
9751 (s390_get_pc, s390_set_pc): Adjust.
9752 (s390_get_hwcap): New target_desc parameter, and use it.
9753 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9754 (s390_arch_setup): Adjust to set the current process'es target
9755 description. Don't adjust the regmap.
9756 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9757 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9758 (regs_info_3264): New globals.
9759 (s390_regs_info): New function.
9760 (the_low_target): Adjust.
9761 (initialize_low_arch): New function.
9762 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9763 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9764 [__mips64] (init_registers_mips_linux)
9765 (init_registers_mips_dsp_linux): Delete defines.
9766 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9767 (have_dsp): New global.
9768 (mips_read_description): New, based on mips_arch_setup.
9769 (mips_arch_setup): Reimplement.
9770 (get_usrregs_info): New function.
9771 (mips_cannot_fetch_register, mips_cannot_store_register)
9772 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9773 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9774 (target_regsets): Rename to ...
9775 (mips_regsets): ... this, and make static.
9776 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9777 (dsp_regs_info, regs_info): New globals.
9778 (mips_regs_info): New function.
9779 (the_low_target): Adjust.
9780 (initialize_low_arch): New function.
9781 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9782 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9784 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9785 (arm_read_description): New, with bits factored from
9787 (arm_arch_setup): Reimplement.
9788 (target_regsets): Rename to ...
9789 (arm_regsets): ... this, and make static.
9790 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9791 (arm_regs_info): New function.
9792 (the_low_target): Adjust.
9793 (initialize_low_arch): New function.
9794 * linux-m68k-low.c (tdesc_m68k): Declare.
9795 (target_regsets): Rename to ...
9796 (m68k_regsets): ... this, and make static.
9797 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9798 (m68k_regs_info): New function.
9799 (m68k_arch_setup): New function.
9800 (the_low_target): Adjust.
9801 (initialize_low_arch): New function.
9802 * linux-sh-low.c (tdesc_sharch): Declare.
9803 (target_regsets): Rename to ...
9804 (sh_regsets): ... this, and make static.
9805 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9806 (sh_regs_info, sh_arch_setup): New functions.
9807 (the_low_target): Adjust.
9808 (initialize_low_arch): New function.
9809 * linux-bfin-low.c (tdesc_bfin): Declare.
9810 (bfin_arch_setup): New function.
9811 (bfin_usrregs_info, regs_info): New globals.
9812 (bfin_regs_info): New function.
9813 (the_low_target): Adjust.
9814 (initialize_low_arch): New function.
9815 * linux-cris-low.c (tdesc_cris): Declare.
9816 (cris_arch_setup): New function.
9817 (cris_usrregs_info, regs_info): New globals.
9818 (cris_regs_info): New function.
9819 (the_low_target): Adjust.
9820 (initialize_low_arch): New function.
9821 * linux-cris-low.c (tdesc_crisv32): Declare.
9822 (cris_arch_setup): New function.
9823 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9824 (cris_regs_info): New function.
9825 (the_low_target): Adjust.
9826 (initialize_low_arch): New function.
9827 * linux-m32r-low.c (tdesc_m32r): Declare.
9828 (m32r_arch_setup): New function.
9829 (m32r_usrregs_info, regs_info): New globals.
9830 (m32r_regs_info): Adjust.
9831 (initialize_low_arch): New function.
9832 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9833 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9834 (tic6x_usrregs_info): Forward declare.
9835 (tic6x_read_description): New function, based on ...
9836 (tic6x_arch_setup): ... this. Reimplement.
9837 (target_regsets): Rename to ...
9838 (tic6x_regsets): ... this, and make static.
9839 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9840 (tic6x_regs_info): New function.
9841 (the_low_target): Adjust.
9842 (initialize_low_arch): New function.
9843 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9844 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9845 (target_regsets): Rename to ...
9846 (xtensa_regsets): ... this, and make static.
9847 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9849 (xtensa_arch_setup, xtensa_regs_info): New functions.
9850 (the_low_target): Adjust.
9851 (initialize_low_arch): New function.
9852 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9853 (nios2_arch_setup): Set the current process'es tdesc.
9854 (target_regsets): Rename to ...
9855 (nios2_regsets): ... this.
9856 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9857 (nios2_regs_info): New function.
9858 (the_low_target): Adjust.
9859 (initialize_low_arch): New function.
9860 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9861 (aarch64_arch_setup): Set the current process'es tdesc.
9862 (target_regsets): Rename to ...
9863 (aarch64_regsets): ... this.
9864 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9865 (aarch64_regs_info): New function.
9866 (the_low_target): Adjust.
9867 (initialize_low_arch): New function.
9868 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9870 (target_regsets): Rename to ...
9871 (tile_regsets): ... this.
9872 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9873 (tile_regs_info): New function.
9874 (tile_arch_setup): Set the current process'es tdesc.
9875 (the_low_target): Adjust.
9876 (initialize_low_arch): New function.
9877 * spu-low.c (tdesc_spu): Declare.
9878 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9879 * win32-arm-low.c (tdesc_arm): Declare.
9880 (arm_arch_setup): New function.
9881 (the_low_target): Install arm_arch_setup instead of
9883 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9884 (init_windows_x86): Rename to ...
9885 (i386_arch_setup): ... this. Set `win32_tdesc'.
9886 (the_low_target): Adjust.
9887 * win32-low.c (win32_tdesc): New global.
9888 (child_add_thread): Don't create the thread cache here.
9889 (do_initial_child_stuff): Set the new process'es tdesc.
9890 * win32-low.h (struct target_desc): Forward declare.
9891 (win32_tdesc): Declare.
9892 * lynx-i386-low.c (tdesc_i386): Declare global.
9893 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9894 * lynx-low.c (lynx_tdesc): New global.
9895 (lynx_add_process): Set the new process'es tdesc.
9896 * lynx-low.h (struct target_desc): Forward declare.
9897 (lynx_tdesc): Declare global.
9898 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9899 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9900 * nto-low.c (nto_tdesc): New global.
9901 (do_attach): Set the new process'es tdesc.
9902 * nto-low.h (struct target_desc): Forward declare.
9903 (nto_tdesc): Declare.
9904 * nto-x86-low.c (tdesc_i386): Declare.
9905 (nto_x86_arch_setup): Set `nto_tdesc'.
9907 2013-06-04 Gary Benson <gbenson@redhat.com>
9909 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9910 to qSupported response when appropriate.
9911 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9912 with nonzero-length annex.
9913 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9914 arguments supplied in annex.
9916 2013-05-31 Doug Evans <dje@google.com>
9919 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9920 64 bits in 64-cross-32 environment.
9922 2013-05-28 Pedro Alves <palves@redhat.com>
9924 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9925 (aarch64-without-fpu.c): Delete rule.
9926 * configure.srv (aarch64*-*-linux*): Remove references to
9927 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9928 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9931 2013-05-24 Pedro Alves <palves@redhat.com>
9933 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9934 instead of strchr/decode_address. Error if the range isn't split
9935 with a ','. Don't assume there's be a ':' in the action.
9937 2013-05-23 Yao Qi <yao@codesourcery.com>
9938 Pedro Alves <palves@redhat.com>
9940 * linux-low.c (lwp_in_step_range): New function.
9941 (linux_wait_1): If the thread was range stepping and stopped
9942 outside the stepping range, report the stop to GDB. Otherwise,
9943 continue stepping. Add range stepping debug output.
9944 (linux_set_resume_request): Copy the step range from the resume
9946 (linux_supports_range_stepping): New.
9947 (linux_target_ops) <supports_range_stepping>: Set to
9948 linux_supports_range_stepping.
9949 * linux-low.h (struct linux_target_ops)
9950 <supports_range_stepping>: New field.
9951 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9952 * linux-x86-low.c (x86_supports_range_stepping): New.
9953 (the_low_target) <supports_range_stepping>: Set to
9954 x86_supports_range_stepping.
9955 * server.c (handle_v_cont): Handle 'r' action.
9956 (handle_v_requests): Append ";r" if the target supports range
9958 * target.h (struct thread_resume) <step_range_start,
9959 step_range_end>: New fields.
9960 (struct target_ops) <supports_range_stepping>:
9962 (target_supports_range_stepping): New macro.
9964 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9966 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9967 confusion in comment.
9969 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9971 * lynx-low.c (struct process_info_private): New type.
9972 (lynx_add_process): New function.
9973 (lynx_create_inferior, lynx_attach): Replace calls to
9974 add_process by calls to lynx_add_process.
9975 (lynx_resume): If PTID is null, then try using
9976 current_process()->private->last_wait_event_ptid.
9978 (lynx_clear_inferiors): Delete. The contents of that function
9979 has been inlined in lynx_mourn;
9980 (lynx_wait_1): Save the ptid in the process's private data.
9981 (lynx_mourn): Free the process' private data. Replace call
9982 to lynx_clear_inferiors by call to clear_inferiors.
9984 2013-05-17 Yao Qi <yao@codesourcery.com>
9986 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9989 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9991 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9992 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9993 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9994 PT_TEXT_END_ADDR guards. Update comments.
9995 (linux_target_op) <read_offsets>: Conditionally define to
9996 linux_read_offsets if the target is UCLIBC and if it defines
9997 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9999 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
10000 Andrew Jenner <andrew@codesourcery.com>
10002 * Makefile.in (SFILES): Add linux-nios2-low.c.
10003 (clean): Add action to delete nios2-linux.c.
10004 (nios2-linux.c): New rule.
10005 * configure.srv: Add nios2*-*-linux*.
10006 * linux-nios2-low.c: New.
10008 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
10010 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
10012 2013-04-25 Hui Zhu <hui@codesourcery.com>
10015 * ax.c (ax_printf): Add fflush.
10017 2013-04-22 Tom Tromey <tromey@redhat.com>
10019 * Makefile.in (SFILES): Add filestuff.c.
10020 (OBS): Add filestuff.o.
10021 (filestuff.o): New target.
10022 * config.in, configure: Rebuild.
10023 * configure.ac: Check for fdwalk, pipe2.
10025 2013-04-17 Pedro Alves <palves@redhat.com>
10027 * configure.ac (USE_THREAD_DB): Delete variable.
10028 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
10029 Don't AC_SUBST USE_THREAD_DB.
10030 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
10031 * config.in, configure: Regenerate.
10033 2013-04-16 Pedro Alves <palves@redhat.com>
10035 * linux-low.h (struct lwp_info) <thread_known>: Move under
10036 the USE_THREAD_DB #ifdef.
10038 2013-04-16 Pedro Alves <palves@redhat.com>
10040 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
10041 (linux-low.o): Delete rule.
10042 * linux-low.h: Always include "gdb_thread_db.h" instead of
10043 conditionally including thread_db.h.
10044 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
10047 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10049 * Makefile.in (install-only): Fix make install regression.
10051 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
10053 Convert man pages to texinfo, new gdbinit.5 texinfo page.
10054 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
10056 * gdbserver.1: Remove.
10058 2013-03-22 Pedro Alves <palves@redhat.com>
10060 * linux-low.c (handle_extended_wait): Don't call
10061 linux_enable_event_reporting.
10063 2013-03-15 Tony Theodore <tonyt@logyst.com>
10066 * Makefile.in (SHELL): Use @SHELL@.
10068 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
10070 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
10073 2013-03-13 Joel Brobecker <brobecker@adacore.com>
10075 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
10076 Remove extraneous NULL element.
10078 2013-03-13 Yao Qi <yao@codesourcery.com>
10080 * tracepoint.c (traceframe_read_tsv): Look for the last matched
10081 'V' block in trace frame.
10083 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10085 * target.h (struct target_ops): Add btrace ops.
10086 (target_supports_btrace): New macro.
10087 (target_enable_btrace): New macro.
10088 (target_disable_btrace): New macro.
10089 (target_read_btrace): New macro.
10090 * gdbthread.h (struct thread_info): Add btrace field.
10091 * server.c: Include btrace-common.h.
10092 (handle_btrace_general_set): New function.
10093 (handle_btrace_enable): New function.
10094 (handle_btrace_disable): New function.
10095 (handle_general_set): Call handle_btrace_general_set.
10096 (handle_qxfer_btrace): New function.
10097 (struct qxfer qxfer_packets[]): Add btrace entry.
10098 * inferiors.c (remove_thread): Disable btrace.
10099 * linux-low: Include linux-btrace.h.
10100 (linux_low_enable_btrace): New function.
10101 (linux_low_read_btrace): New function.
10102 (linux_target_ops): Add btrace ops.
10103 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
10104 Add srv_linux_btrace=yes.
10105 (x86_64-*-linux*): Add linux-btrace.o.
10106 Add srv_linux_btrace=yes.
10107 * configure.ac: Define HAVE_LINUX_BTRACE.
10108 * config.in: Regenerated.
10109 * configure: Regenerated.
10111 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10113 * server.c (handle_qxfer): Preserve error message if -3 is
10115 (qxfer): Document the -3 return value.
10117 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10119 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
10120 (linux_btrace_h): New variable.
10121 (linux-btrace.o): New rule.
10123 2013-03-08 Stan Shebs <stan@codesourcery.com>
10124 Hafiz Abid Qadeer <abidh@codesourcery.com>
10126 * tracepoint.c (trace_buffer_size): New global.
10127 (DEFAULT_TRACE_BUFFER_SIZE): New define.
10128 (init_trace_buffer): Change to one-argument function. Allocate
10129 trace buffer memory.
10130 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
10131 handle QTBuffer:size packet.
10132 (cmd_bigqtbuffer_size): New function.
10133 (initialize_tracepoint): Call init_trace_buffer with
10134 DEFAULT_TRACE_BUFFER_SIZE.
10135 * server.c (handle_query): Add QTBuffer:size in the
10138 2013-03-07 Yao Qi <yao@codesourcery.com>
10140 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
10141 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
10143 (cmd_qtsp): Adjust condition. Do post increment.
10144 Set cur_action and cur_step_action back to 0.
10146 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
10149 * linux-low.c (linux_write_memory): Return early success if LEN is
10152 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
10154 * configure.srv: Add x86_64-*-cygwin* as target.
10156 2013-02-28 Tom Tromey <tromey@redhat.com>
10158 * configure.ac: Invoke AC_SYS_LARGEFILE.
10159 * configure, config.in: Rebuild.
10161 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
10163 * win32-low.c: Throughout, fix format strings and casts of
10164 printf-like functions to avoid type related warnings on all
10166 (get_child_debug_event): Print dwDebugEventCode as hex since
10167 that's how it's usually documented.
10169 2013-02-28 Yao Qi <yao@codesourcery.com>
10171 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
10174 2013-02-27 Jiong Wang <jiwang@tilera.com>
10176 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
10177 (reg-tilegx32.c): New rule.
10178 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
10179 * linux-tile-low.c (tile_arch_setup): New function. Invoke
10180 different register info initializer according to elf class.
10181 (init_registers_tilgx32): New function. The tilegx32 register info
10183 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
10184 (tile_store_gregset): Likewise.
10186 2013-02-27 Yao Qi <yao@codesourcery.com>
10188 * server.c (process_point_options): Print debug message when
10189 debug_threads is true.
10191 2013-02-26 Yao Qi <yao@codesourcery.com>
10193 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
10195 2013-02-19 Pedro Alves <palves@redhat.com>
10196 Kai Tietz <ktietz@redhat.com>
10200 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
10201 instead of strtoul to extract address from packet.
10202 (process_serial_event) <'z'>: Likewise.
10204 2013-02-18 Yao Qi <yao@codesourcery.com>
10206 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
10208 2013-02-14 Pedro Alves <palves@redhat.com>
10212 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
10213 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
10215 2013-02-14 Pedro Alves <palves@redhat.com>
10217 * tracepoint.c (cmd_qtdpsrc): Use savestring.
10219 2013-02-14 Pedro Alves <palves@redhat.com>
10221 * tracepoint.c (save_string): Delete.
10222 (add_tracepoint_action): Use savestring instead of save_string.
10224 2013-02-12 Pedro Alves <palves@redhat.com>
10226 * linux-xtensa-low.c: Ditto.
10227 * xtensa-xtregs.c: Ditto.
10229 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
10231 * thread-db.c (thread_db_get_tls_address): NULL pointer check
10234 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10236 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
10237 aarch64_num_wp_regs and aarch64_num_bp_regs to
10238 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10240 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10242 * linux-aarch64-low.c (ps_get_thread_area): Replace
10243 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10245 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10246 Marcus Shawcroft <marcus.shawcroft@arm.com>
10247 Nigel Stephens <nigel.stephens@arm.com>
10248 Yufeng Zhang <yufeng.zhang@arm.com>
10250 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10251 (aarch64.c, aarch64-without-fpu.c): New targets.
10252 * configure.srv (aarch64*-*-linux*): New.
10253 * linux-aarch64-low.c: New file.
10255 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10257 * linux-low.c (handle_extended_wait, linux_create_inferior)
10258 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10259 (dequeue_one_deferred_signal, linux_resume_one_thread)
10260 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10261 (linux_tracefork_grandchild, linux_test_for_tracefork)
10262 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10263 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10264 where the argument is 0.
10266 2013-01-25 Yao Qi <yao@codesourcery.com>
10268 * event-loop.c: Include "queue.h".
10269 (gdb_event_p): New typedef.
10270 (struct gdb_event) <next_event>: Remove.
10271 (event_queue): Change to QUEUE(gdb_event_p).
10272 (async_queue_event): Remove.
10273 (gdb_event_xfree): New.
10274 (initialize_event_loop): New.
10275 (process_event): Use API from QUEUE.
10276 (wait_for_event): Likewise.
10277 * server.c (main): Call initialize_event_loop.
10278 * server.h (initialize_event_loop): Declare.
10280 2013-01-18 Yao Qi <yao@codesourcery.com>
10282 * ax.h (struct eval_agent_expr_context): New.
10283 (gdb_eval_agent_expr): Update declaration.
10284 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10285 TFRAME. Add new argument CTX.
10286 * server.h (struct eval_agent_expr_context): Declare.
10287 (agent_mem_read, agent_tsv_read): Update declaration.
10288 (agent_mem_read_string): Likewise.
10289 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10290 (add_traceframe_block): Add new argument TPOINT.
10291 Increase TPOINT->traceframe_usage.
10292 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10293 eval_tracepoint_agent_expr.
10294 (condition_true_at_tracepoint): Likewise.
10295 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10296 (agent_mem_read_string, agent_tsv_read): Likewise.
10298 2013-01-16 Yao Qi <yao@codesourcery.com>
10300 * linux-low.c (linux_resume_one_lwp): Don't check
10301 'lwp->bp_reinsert != 0'.
10303 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10304 Pedro Alves <palves@redhat.com>
10306 * lynx-low.c (ptrace_request_to_str): Define a temporary
10307 macro and use it to simplify this function's implementation.
10309 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10311 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10314 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10316 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10318 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10320 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10322 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10324 * lynx-low.c (lynx_resume): Use the resume_info parameter
10325 to determine the ptid for the lynx_ptrace call, unless
10326 it is equal to minus_one_ptid, in which case we use the
10327 ptid of the current_inferior.
10328 (lynx_wait_1): After having received a thread create/exit
10329 event, resume the inferior's execution using the signaling
10330 thread's ptid, rather than the old ptid.
10332 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10334 * lynx-low.c (lynx_resume): Delete variable ret.
10336 2013-01-01 Joel Brobecker <brobecker@adacore.com>
10338 * gdbreplay.c (gdbreplay_version): Update copyright year.
10339 * server.c (gdbserver_version): Likewise.
10341 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10343 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10346 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10348 * lynx-low.c (ptrace_request_to_str): Add handling for
10349 PTRACE_GETTRACESIG.
10351 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10353 * lynx-low.c (lynx_attach): Delete variable new_process.
10355 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10357 * lynx-low.c (lynx_create_inferior): Delete variable
10360 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10362 * lynx-low.c (ptrace_request_to_str): Do not handle
10363 PTRACE_GETTHREADLIST if this macro does not exist.
10365 2012-12-15 Yao Qi <yao@codesourcery.com>
10367 * Makefile.in (OBS): Add notif.o.
10368 * notif.c, notif.h: New.
10369 * server.c: Include "notif.h".
10370 (struct vstop_notif) <next>: Remove.
10372 (queue_stop_reply): Update.
10373 (push_event, send_next_stop_reply): Remove.
10374 (discard_queued_stop_replies): Update.
10375 (notif_stop): New variable.
10376 (handle_v_stopped): Remove.
10377 (handle_v_requests): Don't call handle_v_stopped. Call
10378 handle_ack_notif instead.
10379 (queue_stop_reply_callback): Call notif_event_enque instead
10380 of queue_stop_reply.
10381 (handle_status): Don't call send_next_stop_reply, call
10382 notif_write_event instead.
10383 (kill_inferior_callback): Likewise.
10384 (detach_or_kill_inferior_callback): Likewise.
10385 (main): Call initialize_notif.
10386 (process_serial_event): Call QUEUE_is_empty.
10387 (handle_target_event): Call notif_push instead of push event.
10388 * server.h (push_event): Remove declaration.
10390 2012-12-10 Tom Tromey <tromey@redhat.com>
10392 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10393 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10396 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10397 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10398 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10399 (amd64-linux-ipa.o, ax.o): Rewrite.
10400 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10401 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10402 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10403 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10404 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10405 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10406 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10407 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10408 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10409 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10410 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10411 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10412 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10413 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10414 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10415 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10416 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10417 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10418 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10419 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10420 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10421 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10422 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10423 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10424 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10425 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10426 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10427 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10428 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10429 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10430 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10431 (reg-tilegx.o): Remove.
10432 (all_object_files): New macro.
10433 Include .deps files.
10434 * aclocal.m4, configure: Rebuild.
10435 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10436 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10437 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10439 2012-12-05 Tom Tromey <tromey@redhat.com>
10442 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10444 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
10446 * configure.ac: Check for linux/perf_event.h.
10447 * config.in: Regenerated.
10448 * configure: Regenerated.
10450 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10452 * hostio.c (handle_readlink): Decrease buffer size
10453 parameter passed to readlink by one byte.
10455 2012-11-26 Yao Qi <yao@codesourcery.com>
10457 * configure.ac (build_warnings): Append '-Wempty-body'.
10458 * configure: Regenerated.
10459 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10462 2012-11-15 Pierre Muller <muller@sourceware.org>
10464 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10465 * config.in: Regenerate.
10466 * configure: Regenerate.
10467 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10468 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10469 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10470 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10472 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10473 instead of <sys/wait.h> header.
10474 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10476 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
10478 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10479 (various make rules): Remove -DGDBSERVER
10481 2012-11-09 Yao Qi <yao@codesourcery.com>
10483 * spu-low.c (current_ptid): Move it to ..
10484 * gdbthread.h: ... here. New.
10485 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10486 * server.c (myresume, process_serial_event): Likewise.
10487 * thread-db.c (thread_db_find_new_threads): Likewise.
10488 * tracepoint.c (run_inferior_command): Likewise.
10490 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
10492 * server.c (handle_search_memory_1): Include access length in
10495 2012-09-05 Michael Brandt <michael.brandt@axis.com>
10497 * linux-crisv32-low.c: Fix compile errors.
10499 2012-09-04 Yao Qi <yao@codesourcery.com>
10501 * tracepoint.c (cmd_qtsv): Adjust debug message.
10502 Don't check CUR_TPOINT.
10504 2012-08-28 Yao Qi <yao@codesourcery.com>
10506 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10507 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10508 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10509 Remove declarations of xmalloc, xreallloc, xstrdup and
10511 * Makefile.in (libiberty_h): New.
10512 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10513 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10515 2012-08-23 Yao Qi <yao@codesourcery.com>
10517 * server.h: Remove declaration of 'xsnprintf'.
10519 2012-08-22 Keith Seitz <keiths@redhat.com>
10521 * server.h: Include build-gnulib-gbserver/config.h.
10522 * gdbreplay.c: Likewise.
10524 2012-08-08 Doug Evans <dje@google.com>
10526 * Makefile.in (SFILES): Add gdb_vecs.c.
10527 (OBS): Add gdb_vecs.o.
10528 (gdb_vecs_h, host_defs_h): New variables.
10529 (thread-db.o): Add $(gdb_vecs_h) dependency.
10530 (gdb_vecs.o): New rule.
10531 * thread-db.c: #include "gdb_vecs.h".
10532 (thread_db_load_search): Use a vector to iterate over path elements.
10533 Handle text appearing after "$pdir".
10535 * configure.ac: Add check for strstr.
10536 * config.in: Regenerate.
10537 * configure: Regenerate.
10539 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10541 * hostio.c (handle_pread): If pread fails, fall back to attempting
10543 (handle_pwrite): Likewise for pwrite.
10545 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10547 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10548 between unsupported TYPE and unimplementable ADDR/LEN combination.
10549 (arm_insert_point): Act on new return value.
10551 2012-07-31 Pedro Alves <palves@redhat.com>
10553 * server.c (process_point_options): Only skip tokens if we find
10554 one that is unrecognized. Don't treat 'X' specially while
10555 skipping unrecognized tokens.
10557 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10559 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10560 to 4-byte-align HW breakpoint addresses for Thumb.
10562 2012-07-27 Yao Qi <yao@codesourcery.com>
10566 * server.h: Declare gdb_agent_about_to_close.
10567 * target.c (kill_inferior): Include "agent.h".
10568 New. Send command 'kill'.
10569 * target.h (kill_inferior): Removed macro.
10570 * tracepoint.c (gdb_agent_about_to_close): New.
10571 (gdb_agent_helper_thread): Handle command 'close'.
10572 Wait endlessly until the inferior stops.
10573 Install gdb_agent_remove_socket to atexit hook.
10574 (agent_socket_name): New static variable.
10575 (gdb_agent_socket_init): Replace local variable 'name' with
10576 'agent_socket_name'.
10577 (gdb_agent_remove_socket): New.
10579 2012-07-27 Yao Qi <yao@codesourcery.com>
10581 * server.c (process_point_options): Stop at 'X' when parsing.
10583 2012-07-19 Michael Eager <eager@eagercon.com>
10585 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10587 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10588 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10589 hardware breakpoint.
10591 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10593 * gdbserver/linux-low.c (initialize_low): Call
10594 linux_ptrace_init_warnings.
10596 2012-07-02 Doug Evans <dje@google.com>
10598 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10601 2012-07-02 Stan Shebs <stan@codesourcery.com>
10603 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10604 (ax.o): Add it to build rule.
10606 (OBS): Add format.o.
10607 (IPA_OBS): Add format.o.
10608 * server.c (handle_query): Claim support for breakpoint commands.
10609 (process_point_options): Add command case.
10610 (process_serial_event): Leave running if there are printfs in
10612 * mem-break.h (any_persistent_commands): Declare.
10613 (add_breakpoint_commands): Declare.
10614 (gdb_no_commands_at_breakpoint): Declare.
10615 (run_breakpoint_commands): Declare.
10616 * mem-break.c (struct point_command_list): New struct.
10617 (struct breakpoint): New field command_list.
10618 (any_persistent_commands): New function.
10619 (add_commands_to_breakpoint): New function.
10620 (add_breakpoint_commands): New function.
10621 (gdb_no_commands_at_breakpoint): New function.
10622 (run_breakpoint_commands): New function.
10623 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10625 * ax.c: Include format.h.
10626 (ax_printf): New function.
10627 (gdb_eval_agent_expr): Add printf opcode.
10629 2012-06-13 Yao Qi <yao@codesourcery.com>
10631 * server.c (start_inferior): Remove duplicated writes to fields
10632 'last_resume_kind' and 'last_status' of 'current_inferior'.
10634 2012-06-12 Yao Qi <yao@codesourcery.com>
10635 Pedro Alves <palves@redhat.com>
10637 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10639 * server.c (handle_v_cont): Extend comment.
10641 2012-06-11 Yao Qi <yao@codesourcery.com>
10643 * linux-low.c (linux_attach): Add 'static'.
10645 2012-06-06 Yao Qi <yao@codesourcery.com>
10647 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10649 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10651 Fix gcc -flto compilation warning.
10652 * server.c (main): Make variable multi_mode and attach volatile.
10654 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10656 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10657 if the platform doesn't know about it.
10659 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10661 * Makefile.in (SFILES): Add linux-tile-low.c.
10662 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10663 * configure.srv: Handle tilegx-*-linux*.
10664 * linux-tile-low.c: New file.
10666 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10668 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10670 2012-05-24 Pedro Alves <palves@redhat.com>
10674 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10676 2012-05-24 Pedro Alves <palves@redhat.com>
10680 Replace target_signal with gdb_signal throughout.
10682 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10684 * linux-low.c (linux_store_registers): Avoid the copying sequence
10685 when no data has been retrieved by ptrace.
10687 2012-05-22 Will Deacon <will.deacon@arm.com>
10689 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10690 Include asm/ptrace.h.
10691 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10694 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10696 * linux-low.c (linux_store_registers): Don't re-retrieve data
10697 with ptrace that has already been obtained from /proc. Always
10698 copy any data retrieved with ptrace to the buffer supplied.
10700 2012-05-11 Yao Qi <yao@codesourcery.com>
10701 Pedro Alves <palves@redhat.com>
10703 * linux-low.c (enum stopping_threads_kind): New.
10704 (stopping_threads): Change type to `enum stopping_threads_kind'.
10705 (handle_extended_wait): If stopping and suspending threads, leave
10706 the new_lwp suspended too.
10707 (linux_wait_for_event): Adjust.
10708 (stop_all_lwps): Set `stopping_threads' to
10709 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10710 whether we're suspending threads or just stopping them. Assert no
10713 2012-04-29 Yao Qi <yao@codesourcery.com>
10715 * server.h: Move some code to ...
10716 * gdbthread.h: ... here. New.
10717 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10718 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10719 (nto-low.o, win32-low.o): Likewise.
10720 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10721 * regcache.c, remote-utils.c, server.c: Likewise.
10722 * target.c, tracepoint.c, win32-low.c: Likewise.
10724 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10726 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10727 (PTRACE_ARG4_TYPE): Likewise.
10728 (PTRACE_XFER_TYPE): Likewise.
10729 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10730 ptrace to PTRACE_ARG3_TYPE.
10731 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10732 (PTRACE_ARG4_TYPE): Likewise.
10733 (PTRACE_XFER_TYPE): Likewise.
10734 (linux_detach_one_lwp): Cast fourth argument of
10735 ptrace to long then PTRACE_ARG4_TYPE.
10736 (regsets_fetch_inferior_registers): Cast third argument of
10737 ptrace to long then PTRACE_ARG3_TYPE.
10738 (regsets_store_inferior_registers): Likewise.
10740 2012-04-20 Pedro Alves <palves@redhat.com>
10742 * configure: Regenerate.
10744 2012-04-19 Pedro Alves <palves@redhat.com>
10746 * Makefile.in (GNULIB_BUILDDIR): New.
10747 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10748 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10749 (all, install-only, uninstall, clean-info, all-lib, clean): No
10750 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10751 (maintainer-clean realclean distclean): Use subdir_do.
10753 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10754 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10755 * acinclude.m4: Include acx_configure_dir.m4.
10756 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10757 calls. Call AC_PROG_RANLIB. Configure gnulib using
10760 (GNULIB_STDINT_H): Adjust.
10761 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10762 * gdbreplay.c: Include build-gnulib/config.h.
10763 * server.h: Likewise.
10764 * aclocal.m4: Regenerate.
10765 * config.in: Regenerate.
10766 * configure: Regenerate.
10768 2012-04-19 Pedro Alves <palves@redhat.com>
10770 * Makefile.in (LIBGNU, INCGNU): Adjust.
10771 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10772 (all, install-only, uninstall, clean-info, all-lib, clean)
10773 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10774 * configure.ac: Adjust AC_OUTPUT output.
10775 * aclocal.m4: Regenerate.
10776 * configure: Regenerate.
10778 2012-04-19 Pedro Alves <palves@redhat.com>
10780 * Makefile.in (generated_files): New.
10781 (server_h): Remove the explicit dependency on config.h, and depend
10782 on $generated_files.
10784 2012-04-19 Pedro Alves <palves@redhat.com>
10786 * Makefile.in (INCGNU): Add -Ignulib.
10788 2012-04-19 Pedro Alves <palves@redhat.com>
10790 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10791 (INCGNU): ... this, and spell out -I here.
10792 (GNULIB_LIB): Rename to ...
10793 (LIBGNU): ... this.
10794 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10796 2012-04-19 Pedro Alves <palves@redhat.com>
10798 * config.in: Regenerate.
10800 2012-04-19 Pedro Alves <palves@redhat.com>
10802 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10803 * server.h (memmem): Remove declaration.
10804 * config.in: Regenerate.
10805 * configure: Regenerate.
10807 2012-04-19 Yao Qi <yao@codesourcery.com>
10809 * Makefile.in (SFILES): Add common/vec.c.
10813 2012-04-19 Yao Qi <yao@codesourcery.com>
10815 * remote-utils.c (prepare_resume_reply): Replace with macro
10816 target_core_of_thread.
10817 * server.c (handle_qxfer_threads_proper): Likewise.
10818 * target.h (traget_core_of_thread): New macro.
10820 2012-04-18 Pedro Alves <palves@redhat.com>
10822 * aclocal.m4: Regenerate.
10823 * configure: Regenerate.
10825 2012-04-16 Yao Qi <yao@codesourcery.com>
10827 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10828 duplicated on address.
10830 2012-04-16 Yao Qi <yao@codesourcery.com>
10832 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10833 (struct tracepoint_action_ops) <send>: New field.
10834 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10835 (agent_expr_send, x_tracepoint_action_send): New.
10836 (l_tracepoint_action_send): New.
10837 (cmd_qtdp): Download and install tracepoint
10838 according to `use_agent'.
10839 (run_inferior_command): Add one more parameter `len'.
10841 (tracepoint_send_agent): New.
10842 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10844 2012-04-16 Yao Qi <yao@codesourcery.com>
10846 * tracepoint.c (download_tracepoints): Moved to ...
10847 (cmd_qtstart): ... here.
10849 2012-04-14 Yao Qi <yao@codesourcery.com>
10851 * tracepoint.c: Include inttypes.h.
10852 (struct collect_memory_action): Use sized types.
10853 (struct tracepoint): Likewise.
10854 (cmd_qtdp, stop_tracing): Update print specifiers.
10855 (cmd_qtp, response_tracepoint): Likewise.
10856 (collect_data_at_tracepoint): Likewise.
10857 (collect_data_at_step): Likewise.
10859 2012-04-14 Yao Qi <yao@codesourcery.com>
10861 Import gnulib module inttypes.
10862 * aclocal.m4, config.in, configure: Regenerated.
10864 2012-04-14 Yao Qi <yao@codesourcery.com>
10866 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10867 Makefile and config.status at last.
10869 2012-04-13 Yao Qi <yao@codesourcery.com>
10871 * tracepoint.c: Include stdint.h unconditionally.
10873 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10875 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10876 on BFD_HAVE_SYS_PROCFS_TYPE.
10877 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10878 * configure: Regenerate.
10879 * config.in: Likewise.
10881 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10883 * Makefile.in (clean): Also remove x32.c x32-linux.c
10884 x32-avx.c x32-avx-linux.c.
10885 (x32.o): New target.
10887 (x32-linux.o): Likewise.
10888 (x32-linux.c): Likewise.
10889 (x32-avx.o): Likewise.
10890 (x32-avx.c): Likewise.
10891 (x32-avx-linux.o): Likewise.
10892 (x32-avx-linux.c): Likewise.
10894 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10895 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10896 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10897 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10898 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10899 i386/x32-avx-linux.xml.
10901 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10902 (init_registers_x32_avx_linux): Likwise.
10903 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10904 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10906 2012-04-13 Pedro Alves <palves@redhat.com>
10908 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10909 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10910 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10911 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10914 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10916 * linux-x86-low.c (compat_x32_clock_t): New.
10917 (compat_x32_siginfo_t): Likewise.
10918 (compat_x32_siginfo_from_siginfo): Likewise.
10919 (siginfo_from_compat_x32_siginfo): Likewise.
10920 (linux_is_elf64): Likewise.
10921 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10922 and siginfo_from_compat_x32_siginfo for x32.
10923 (x86_arch_setup): Set linux_is_elf64.
10925 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10928 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10930 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10931 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10932 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10933 compatible with process.
10935 2012-04-12 Yao Qi <yao@codesourcery.com>
10937 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10938 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10939 (install-only, install-info, clean): Handle sub dir gnulib.
10940 (all-lib, am--refresh): New targets.
10941 (memmem.o): Remove target.
10942 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10943 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10944 (AC_REPLACE_FUNCS): Remove memmem.
10945 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10946 (AC_OUTPUT): Generate Makefile in gnulib/.
10947 * aclocal.m4, config.in, configure: Regenerated.
10949 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10951 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10953 2012-04-05 Pedro Alves <palves@redhat.com>
10955 -Werror=strict-aliasing
10957 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10960 2012-04-04 Pedro Alves <palves@redhat.com>
10962 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10963 (sparc_store_gregset_from_stack, sparc_store_gregset)
10964 (sparc_breakpoint_at): Fix formatting.
10966 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10968 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10970 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10971 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10972 * config.in: Regenerate.
10973 * configure: Likewise.
10975 2012-03-29 Pedro Alves <palves@redhat.com>
10977 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10978 Correct ptrace arguments.
10980 2012-03-28 Pedro Alves <palves@redhat.com>
10982 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10983 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10984 (IA64_FR1_REGNUM): New defines.
10985 (ia64_fetch_register): New.
10986 (the_low_target): Install it.
10987 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10989 * linux-low.c (linux_fetch_registers): Try the
10990 the_low_target.fetch_register hook first.
10992 * linux-arm-low.c (the_low_target): Adjust.
10993 * linux-bfin-low.c (the_low_target): Adjust.
10994 * linux-cris-low.c (the_low_target): Adjust.
10995 * linux-crisv32-low.c (the_low_target): Adjust.
10996 * linux-m32r-low.c (the_low_target): Adjust.
10997 * linux-m68k-low.c (the_low_target): Adjust.
10998 * linux-mips-low.c (the_low_target): Adjust.
10999 * linux-ppc-low.c (the_low_target): Adjust.
11000 * linux-s390-low.c (the_low_target): Adjust.
11001 * linux-sh-low.c (the_low_target): Adjust.
11002 * linux-sparc-low.c (the_low_target): Adjust.
11003 * linux-tic6x-low.c (the_low_target): Adjust.
11004 * linux-x86-low.c (the_low_target): Adjust.
11005 * linux-xtensa-low.c (the_low_target): Adjust.
11007 2012-03-26 Pedro Alves <palves@redhat.com>
11009 * server.c (handle_qxfer_libraries): Don't bail early if
11010 the_target->qxfer_libraries_svr4 is not NULL.
11012 2012-03-26 Pedro Alves <palves@redhat.com>
11014 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
11016 2012-03-23 Pedro Alves <palves@redhat.com>
11018 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
11019 "library-list-svr4" element's start tag when the the DSO list is
11022 2012-03-23 Pedro Alves <palves@redhat.com>
11024 * linux-low.c (read_one_ptr): Read the inferior's pointer through
11025 a variable whose type size is the same as the inferior's pointer
11028 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
11030 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
11032 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
11033 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
11034 * linux-low.h: Include <signal.h>.
11035 (struct siginfo): Remove forward declaration.
11036 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
11039 2012-03-21 Mike Frysinger <vapier@gentoo.org>
11041 * .gitignore: Ignore more files.
11043 2012-03-19 Pedro Alves <palves@redhat.com>
11044 Jan Kratochvil <jan.kratochvil@redhat.com>
11046 * server.c (cont_thread, general_thread): Add describing comments.
11047 (start_inferior): Clear `cont_thread'.
11048 (handle_v_cont): Don't set `cont_thread' if resuming all threads
11051 2012-03-15 Yao Qi <yao@codesourcery.com>
11053 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
11055 (cmd_qtdp): ... here.
11057 2012-03-15 Yao Qi <yao@codesourcery.com>
11059 * tracepoint.c (struct tracepoint_action_ops): New.
11060 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
11061 (m_tracepoint_action_download): New.
11062 (r_tracepoint_action_download): New.
11063 (x_tracepoint_action_download): New.
11064 (l_tracepoint_action_download): New.
11065 (add_tracepoint_action): Install `action->ops' according type.
11066 (download_tracepoint_1): Move code `download' function pointer
11067 of various tracepoint_action_ops.
11069 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
11071 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
11072 linux_ptrace_attach_warnings.
11074 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
11076 * Makefile.in (linux-ptrace.o): New.
11077 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
11078 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
11079 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
11080 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
11081 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
11083 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
11085 2012-03-08 Yao Qi <yao@codesourcery.com>
11086 Pedro Alves <palves@redhat.com>
11088 Fix PR server/13392.
11089 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
11090 offset of JMP insn.
11091 * tracepoint.c (remove_tracepoint): New.
11092 (cmd_qtdp): Call remove_tracepoint when failed to install.
11094 2012-03-07 Pedro Alves <palves@redhat.com>
11096 * linux-low.c (get_detach_signal): New.
11097 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
11098 Pass on pending signals to PTRACE_DETACH. Check the result of the
11100 * server.c (program_signals, program_signals_p): New.
11101 (handle_general_set): Handle QProgramSignals.
11102 * server.h (program_signals, program_signals_p): Declare.
11104 2012-03-05 Pedro Alves <palves@redhat.com>
11105 Jan Kratochvil <jan.kratochvil@redhat.com>
11107 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
11110 2012-03-03 Yao Qi <yao@codesourcery.com>
11112 * tracepoint.c (tracepoint_look_up_symbols): Update call to
11113 agent_look_up_symbols.
11115 2012-03-03 Yao Qi <yao@codesourcery.com>
11117 * Makefile.in (linux-low.o): Keep dependence on agent.h.
11118 (linux-x86-low.o): Likewise.
11119 * server.h: Remove in_process_agent_loaded.
11120 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
11124 2012-03-03 Yao Qi <yao@codesourcery.com>
11126 * tracepoint.c (gdb_agent_capability): New global.
11127 (in_process_agent_loaded_ust): Renamed to
11128 `in_process_agent_supports_ust'.
11130 (in_process_agent_supports_ust): Call agent_capability_check.
11131 (clear_installed_tracepoints): Assert that agent supports
11134 2012-03-03 Yao Qi <yao@codesourcery.com>
11136 * linux-low.c (linux_supports_agent): New.
11137 (linux_target_ops): Initialize field `supports_agent' with
11138 linux_supports_agent.
11139 * target.h (struct target_ops) <supports_agent>: New.
11140 (target_supports_agent): New macro.
11141 * server.c (handle_general_set): Handle packet 'QAgent'.
11142 (handle_query): Send `QAgent+'.
11143 * Makefile.in (server.o): Depends on agent.h.
11145 2012-03-03 Yao Qi <yao@codesourcery.com>
11147 * Makefile.in (OBS): Add agent.o.
11148 Add new rule for agent.o.
11149 Track dependence of tracepoint.c on agent.h.
11150 * tracepoint.c (run_inferior_command_1):
11151 (run_inferior_command): Call agent_run_command.
11152 (gdb_ust_connect_sync_socket): Deleted. Move it to
11154 (resume_thread, stop_thread): Likewise.
11155 (gdb_ust_socket_init): Renamed to ...
11156 (gdb_agent_socket_init): ... New.
11157 (gdb_ust_thread): Renamed to ...
11158 (gdb_agent_helper_thread): ... New.
11159 (gdb_ust_init): Move some code to ...
11160 (gdb_agent_init): ... here. New.
11161 [HAVE_UST]: Call gdb_ust_init.
11162 (initialize_tracepoint_ftlib): Call gdb_agent_init.
11163 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
11164 * config.in, configure: Regenerated.
11166 2012-03-02 Pedro Alves <palves@redhat.com>
11168 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
11169 * linux-low.c (struct simple_pid_list): New.
11170 (stopped_pids): New a struct simple_pid_list pointer.
11171 (add_to_pid_list, pull_pid_from_list): New.
11172 (handle_extended_wait): Don't assume the first signal new children
11173 report is SIGSTOP. Adjust call to pull_pid_from_list.
11174 (linux_wait_for_lwp): Adjust.
11176 2012-03-02 Yao Qi <yao@codesourcery.com>
11178 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
11181 2012-03-02 Yao Qi <yao@codesourcery.com>
11183 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
11184 `stop_pc' and `tpoint'. Update caller.
11186 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
11188 * linux-low.h (linux_target_ops): Add regset_bitmap member.
11189 * linux-low.c (use_linux_regsets): New macro.
11190 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
11191 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
11192 (linux_register_in_regsets): New function.
11193 (usr_fetch_inferior_registers): Skip registers covered by
11195 (usr_store_inferior_registers): Likewise.
11196 (usr_fetch_inferior_registers): New macro.
11197 (usr_store_inferior_registers): Likewise.
11198 (linux_fetch_registers): Handle mixed regset/non-regset targets.
11199 (linux_store_registers): Likewise.
11200 * linux-mips-low.c (init_registers_mips_dsp_linux): New
11202 (init_registers_mips64_dsp_linux): Likewise.
11203 (init_registers_mips_linux): New macro.
11204 (init_registers_mips_dsp_linux): Likewise.
11205 (mips_dsp_num_regs): Likewise.
11206 (DSP_BASE, DSP_CONTROL): New fallback macros.
11207 (mips_base_regs): New macro.
11208 (mips_regmap): Use it. Fix the size.
11209 (mips_dsp_regmap): New variable.
11210 (mips_dsp_regset_bitmap): Likewise.
11211 (mips_arch_setup): New function.
11212 (mips_cannot_fetch_register): Use the_low_target.regmap rather
11214 (mips_cannot_store_register): Likewise.
11215 (the_low_target): Update .arch_setup, .num_regs and .regmap
11216 initializers. Add .regset_bitmap initializer.
11217 * linux-arm-low.c (the_low_target): Add .regset_bitmap
11219 * linux-bfin-low.c (the_low_target): Likewise.
11220 * linux-cris-low.c (the_low_target): Likewise.
11221 * linux-crisv32-low.c (the_low_target): Likewise.
11222 * linux-ia64-low.c (the_low_target): Likewise.
11223 * linux-m32r-low.c (the_low_target): Likewise.
11224 * linux-m68k-low.c (the_low_target): Likewise.
11225 * linux-ppc-low.c (the_low_target): Likewise.
11226 * linux-s390-low.c (the_low_target): Likewise.
11227 * linux-sh-low.c (the_low_target): Likewise.
11228 * linux-sparc-low.c (the_low_target): Likewise.
11229 * linux-tic6x-low.c (the_low_target): Likewise.
11230 * linux-x86-low.c (the_low_target): Likewise.
11231 * linux-xtensa-low.c (the_low_target): Likewise.
11232 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
11233 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
11234 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
11236 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
11237 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11239 2012-02-29 Yao Qi <yao@codesourcery.com>
11240 Pedro Alves <palves@redhat.com>
11242 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11243 `step_over_finished' is true.
11245 2012-02-27 Pedro Alves <palves@redhat.com>
11247 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11248 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11250 2012-02-27 Pedro Alves <palves@redhat.com>
11253 * linux-low.c (pid_is_stopped): New.
11254 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11256 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
11258 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11261 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11263 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11265 2012-02-24 Luis Machado <lgustavo@codesourcery>
11267 * server.c (handle_query): Advertise support for target-side
11268 breakpoint condition evaluation.
11269 (process_point_options): New function.
11270 (process_serial_event): When inserting a breakpoint, check for
11271 a target-side condition that should be evaluated.
11273 * mem-break.c: Include regcache.h and ax.h.
11274 (point_cond_list_t): New data structure.
11275 (breakpoint) <cond_list>: New field.
11276 (find_gdb_breakpoint_at): Make non-static.
11277 (delete_gdb_breakpoint_at): Clear any target-side
11279 (clear_gdb_breakpoint_conditions): New function.
11280 (add_condition_to_breakpoint): Likewise.
11281 (add_breakpoint_condition): Likewise.
11282 (gdb_condition_true_at_breakpoint): Likewise.
11283 (gdb_breakpoint_here): Return result directly instead
11284 of going through a local variable.
11286 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11287 (clear_gdb_breakpoint_conditions): Likewise.
11288 (add_breakpoint_condition): Likewise.
11289 (gdb_condition_true_at_breakpoint): Likewise.
11291 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11292 (need_step_over_p): Take target-side breakpoint condition into
11295 2012-02-24 Luis Machado <lgustavo@codesourcery>
11297 * server.h: Include tracepoint.h.
11298 (agent_mem_read, agent_get_trace_state_variable_value,
11299 agent_set_trace_state_variable_value,
11300 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11301 get_set_tsv_func_addr): New prototypes.
11303 * ax.h: New include file.
11304 * ax.c: New source file.
11306 * tracepoint.c: Include ax.h.
11307 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11308 agent_expr, eval_result_type): Move to ax.h.
11309 (parse_agent_expr): Rename to ...
11310 (gdb_parse_agent_expr): ... this, make it non-static and move
11312 (unparse_agent_expr) Rename to ...
11313 (gdb_unparse_agent_expr): ... this, make it non-static and move
11315 (eval_agent_expr): Rename to ...
11316 (eval_tracepoint_agent_expr): ... this.
11317 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11318 forward declarations.
11319 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11320 (agent_get_trace_state_variable_value): New function.
11321 (agent_set_trace_state_variable_value): New function.
11322 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11323 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11324 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11325 (condition_true_at_tracepoint): Likewise.
11326 (parse_agent_expr): Rename to ...
11327 (gdb_parse_agent_expr): ... this and move to ax.c.
11328 (unparse_agent_expr): Rename to ...
11329 (gdb_unparse_agent_expr): ... this and move to ax.c.
11330 (gdb_agent_op_name): Move to ax.c.
11331 (eval_agent_expr): Rename to ...
11332 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11334 (eval_tracepoint_agent_expr): New function.
11335 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
11337 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11339 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11340 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11341 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11342 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11343 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11344 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11345 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11346 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11347 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11348 (compile_bytecodes): Remove forward declaration.
11349 (is_goto_target): Move to ax.c.
11350 (compile_bytecodes): Move to ax.c and call
11351 agent_get_trace_state_variable_value (...) and
11352 agent_set_trace_state_variable_value (...).
11354 * Makefile.in: Update ax.c and IPA dependencies.
11356 2012-02-24 Pedro Alves <palves@redhat.com>
11358 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11359 (cmd_bigqtbuffer_circular): ... this. Only handle
11360 'QTBuffer:circular:'.
11361 (handle_tracepoint_general_set): Adjust.
11363 2012-02-16 Yao Qi <yao@codesourcery.com>
11365 * inferiors.c: Move code to ...
11366 * dll.c: .... here. New.
11367 * server.h: Declare clear_dlls.
11368 * Makefile.in (SFILES): Add dll.c.
11372 2012-02-11 Yao Qi <yao@codesourcery.com>
11374 * server.c: (handle_monitor_command): Add a new parameter
11376 (handle_query): Update caller.
11378 2012-02-09 Joel Brobecker <brobecker@adacore.com>
11380 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11381 * configure, config.in: Regenerate.
11382 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11385 2012-02-02 Pedro Alves <palves@redhat.com>
11387 Try SIGKILL first, then PTRACE_KILL.
11388 * linux-low.c (linux_kill_one_lwp): New.
11389 (linux_kill_one_lwp): Rename to ...
11390 (kill_one_lwp_callback): ... this. Use the new
11391 linux_kill_one_lwp.
11393 2012-02-02 Pedro Alves <palves@redhat.com>
11395 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11398 2012-01-27 Pedro Alves <palves@redhat.com>
11400 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11401 (elf_64_file_p): Make static.
11402 (linux_pid_exe_is_elf_64_file): New.
11403 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11404 Delete declarations.
11405 (linux_pid_exe_is_elf_64_file): Declare.
11406 * linux-x86-low.c (x86_arch_setup): Use
11407 linux_pid_exe_is_elf_64_file.
11409 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11411 * linux-low.c (linux_wait_for_event_1): Rename to ...
11412 (linux_wait_for_event): ... here and merge it with former
11413 linux_wait_for_event - new variable wait_ptid, use it.
11414 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11416 2012-01-23 Pedro Alves <palves@redhat.com>
11418 * server.c (main): Avoid yet another case of infinite loop while
11419 detaching/killing after a longjmp.
11421 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11424 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11426 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11428 * hostio.c (handle_readlink): New function.
11429 (handle_vFile): Call it to handle "vFile:readlink" packets.
11431 2012-01-20 Pedro Alves <palves@redhat.com>
11432 Ulrich Weigand <ulrich.weigand@linaro.org>
11434 * server.c (handle_v_requests): Only support vAttach and vRun to
11435 start multiple processes when in extended protocol mode.
11437 2012-01-17 Pedro Alves <palves@redhat.com>
11439 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11440 memalign plus mprotect to allocate the scratch buffer.
11442 2012-01-13 Pedro Alves <palves@redhat.com>
11444 * server.c (attach_inferior): Clear `cont_thread'.
11446 2012-01-13 Pedro Alves <palves@redhat.com>
11448 * server.c (main): Avoid infinite loop while detaching/killing
11451 2012-01-09 Doug Evans <dje@google.com>
11453 * server.c (start_inferior): Set last_ptid in --wrapper case.
11455 2012-01-06 Yao Qi <yao@codesourcery.com>
11457 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11459 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11461 2012-01-04 Yao Qi <yao@codesourcery.com>
11463 * tracepoint.c (cmd_qtdp): Print debug message
11464 for static tracepoint.
11466 2012-01-04 Yao Qi <yao@codesourcery.com>
11468 * tracepoint.c (trace_vdebug): Differentiate debug message
11469 between gdbserver and IPA.
11471 2012-01-03 Yao Qi <yao@codesourcery.com>
11473 * tracepoint.c (tracepoint_was_hit): Don't collect for
11476 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11478 * terminal.h: Reformat copyright header.
11480 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11482 * server.c (gdbserver_version): Update copyright year.
11483 * gdbreplay.c (gdbreplay_version): Likewise.
11485 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11487 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11490 2011-12-18 Hui Zhu <teawater@gmail.com>
11491 * linux-low.c (linux_create_inferior): Save return value to ret.
11493 2011-12-18 Hui Zhu <teawater@gmail.com>
11495 * linux-low.c (linux_create_inferior): Save return value to ret.
11497 2011-12-16 Doug Evans <dje@google.com>
11499 * linux-low.c (linux_create_inferior): If stdio connection,
11500 redirect stdin from /dev/null, stdout to stderr.
11501 * remote-utils.c (remote_is_stdio): New static global.
11502 (remote_connection_is_stdio): New function.
11503 (remote_prepare): Handle stdio connection.
11504 (remote_open): Ditto.
11505 (remote_close): Don't close stdin for stdio connections.
11506 (read_prim,write_prim): New functions. Replace all calls to
11507 read/write to these.
11508 * server.c (main): Watch for "-" argument. Move call to
11509 remote_prepare before start_inferior.
11510 * server.h (STDIO_CONNECTION_NAME): New macro.
11511 (remote_connection_is_stdio): Declare.
11513 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11514 in debugging output.
11516 2011-12-15 Yao Qi <yao@codesourcery.com>
11518 * tracepoint.c: Include sys/syscall.h.
11519 (gdb_ust_thread): Remove preprocessor conditional.
11521 2011-12-14 Pedro Alves <pedro@codesourcery.com>
11523 * linux-low.c (linux_detach_one_lwp): Call
11524 the_low_target.prepare_to_resume before detaching.
11526 2011-12-14 Yao Qi <yao@codesourcery.com>
11528 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11531 2011-12-14 Yao Qi <yao@codesourcery.com>
11533 * i386-low.c (i386_low_stopped_data_address): Initialize local
11534 variable `control'.
11536 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11540 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11541 DR_CONTROL unless necessary. Extend comments.
11542 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11543 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11545 2011-12-13 Yao Qi <yao@codesourcery.com>
11547 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11549 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11551 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11553 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11554 Print new debug message for such case.
11556 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11558 Fix overlapping memcpy.
11559 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11560 the read_inferior_memory transfer.
11561 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11562 write_inferior_memory transfer.
11563 (set_fast_tracepoint_jump): New variable buf. Use it for the
11564 read_inferior_memory and write_inferior_memory transfers.
11565 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11566 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11567 Use it for the write_inferior_memory transfer.
11568 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11571 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11573 * linux-low.c (fetch_register, store_register): Make code
11574 consistent, fix formatting.
11576 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11578 * linux-low.c (usr_store_inferior_registers): Factor out code
11579 to handle individual registers into...
11580 (store_register): ... this new function.
11582 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11584 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11585 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11586 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11587 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11588 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11589 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11590 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11591 (srv_xmlfiles): Add new XML files.
11593 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11595 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11596 (init_registers_s390_linux32v1): Add prototype.
11597 (init_registers_s390_linux32v2): Likewise.
11598 (init_registers_s390_linux64v1): Likewise.
11599 (init_registers_s390_linux64v2): Likewise.
11600 (init_registers_s390x_linux64v1): Likewise.
11601 (init_registers_s390x_linux64v2): Likewise.
11602 (s390_num_regs): Increment to 52.
11603 (s390_regmap): Add orig_r2 register.
11604 (s390_num_regs_3264): Increment to 68.
11605 (s390_regmap_3264): Add orig_r2 register.
11606 (s390_collect_ptrace_register): Handle orig_r2 register.
11607 (s390_supply_ptrace_register): Likewise.
11608 (s390_fill_last_break): New function.
11609 (s390_store_last_break): Likewise.
11610 (s390_fill_system_call): New function.
11611 (s390_store_system_call): Likewise.
11612 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11614 (s390_check_regset): New function.
11615 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11616 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11617 Update target_regsets for available register sets.
11619 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11620 Jan Kratochvil <jan.kratochvil@redhat.com>
11622 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11623 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11625 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11626 * linux-low.h (struct process_info_private): New member r_debug.
11627 * server.c (handle_qxfer_libraries): Call
11628 the_target->qxfer_libraries_svr4.
11629 (handle_qxfer_libraries_svr4): New function.
11630 (qxfer_packets): New entry "libraries-svr4".
11631 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11632 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11633 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11634 PACKET_qXfer_libraries_svr4.
11636 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11638 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11639 PSW address/mask between 8-byte and 16-byte formats.
11640 (s390_supply_ptrace_register): Likewise.
11641 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11642 basic addressing mode bit.
11644 2011-11-24 Stan Shebs <stan@codesourcery.com>
11646 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11648 2011-11-17 Stan Shebs <stan@codesourcery.com>
11650 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11651 (tracing_start_time): New global.
11652 (tracing_stop_time): New global.
11653 (tracing_user_name): New global.
11654 (tracing_notes): New global.
11655 (tracing_stop_note): New global.
11656 (cmd_qtstart): Set traceframe_usage, start_time.
11657 (stop_tracing): Set stop_time.
11658 (cmd_qtstatus): Report additional status.
11659 (cmd_qtp): New function.
11660 (handle_tracepoint_query): Call it.
11661 (cmd_qtnotes): New function.
11662 (handle_tracepoint_general_set): Call it.
11663 (get_timestamp): Rename from tsv_get_timestamp.
11665 2011-11-14 Stan Shebs <stan@codesourcery.com>
11666 Kwok Cheung Yeung <kcy@codesourcery.com>
11668 * linux-x86-low.c (small_jump_insn): New.
11669 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11670 trampoline and error message, build a trampoline and issue a small
11671 jump instruction to it.
11672 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11673 trampoline and error message.
11674 (x86_get_min_fast_tracepoint_insn_len): New.
11675 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11676 * linux-low.h (struct linux_target_ops): Add arguments to
11677 install_fast_tracepoint_jump_pad operation, add new operation.
11678 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11680 (linux_get_min_fast_tracepoint_insn_len): New function.
11681 (linux_target_op): Add new operation.
11682 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11683 (gdb_trampoline_buffer_end): Ditto.
11684 (gdb_trampoline_buffer_error): Ditto.
11685 (struct ipa_sym_addresses): Add fields for new IPA variables.
11686 (symbol_list): Add entries for new IPA variables.
11687 (struct tracepoint): Add fields to hold the address range of the
11688 trampoline used by the tracepoint.
11689 (trampoline_buffer_head): New static variable.
11690 (trampoline_buffer_tail): Ditto.
11691 (claim_trampoline_space): New function.
11692 (have_fast_tracepoint_trampoline_buffer): New function.
11693 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11695 (install_fast_tracepoint): Ditto, also add error buffer argument.
11696 (cmd_qtminftpilen): New function.
11697 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11698 (fast_tracepoint_from_trampoline_address): New function.
11699 (fast_tracepoint_collecting): Handle trampoline as part of jump
11701 (set_trampoline_buffer_space): New function.
11702 (initialize_tracepoint): Initialize new IPA variables.
11703 * target.h (struct target_ops): Add arguments to
11704 install_fast_tracepoint_jump_pad operation, add new
11705 get_min_fast_tracepoint_insn_len operation.
11706 (target_get_min_fast_tracepoint_insn_len): New.
11707 (install_fast_tracepoint_jump_pad): Add arguments.
11708 * server.h (IPA_BUFSIZ): Define.
11709 * linux-i386-ipa.c: Include extra header files.
11710 (initialize_fast_tracepoint_trampoline_buffer): New function.
11711 (initialize_low_tracepoint): Call it.
11712 * server.h (set_trampoline_buffer_space): Declare.
11713 (claim_trampoline_space): Ditto.
11714 (have_fast_tracepoint_trampoline_buffer): Ditto.
11716 2011-11-14 Yao Qi <yao@codesourcery.com>
11718 * server.c (handle_query): Handle InstallInTrace for qSupported.
11719 * tracepoint.c (add_tracepoint): Sort list.
11720 (install_tracepoint, download_tracepoint): New.
11721 (cmd_qtdp): Call them to install and download tracepoints.
11722 (sort_tracepoints): Removed.
11723 (cmd_qtstart): Update.
11725 2011-11-14 Yao Qi <yao@codesourcery.com>
11727 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11728 * mem-break.h: Declare.
11729 * tracepoint.c (cmd_qtstart): Move some code to ...
11730 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11732 (download_tracepoints): Move some code to ...
11733 (download_tracepoint_1): ... here. New.
11735 2011-11-08 Yao Qi <yao@codesourcery.com>
11737 * remote-utils.c (relocate_instruction): A comment fix.
11739 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11741 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11742 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11743 dr_status_mirror and dr_control_mirror from debug_reg_state.
11744 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11745 (i386_initial_stuff): Remove use of deleted globals.
11746 (i386_get_thread_context, i386_set_thread_context,
11747 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11748 from debug_reg_state.
11750 2011-11-05 Yao Qi <yao@codesourcery.com>
11752 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11753 address as TPOINT's.
11755 2011-11-02 Stan Shebs <stan@codesourcery.com>
11757 * tracepoint.c (agent_mem_read_string): New function.
11758 (eval_agent_expr): Call it for tracenz.
11759 * server.c (handle_query): Report support for tracenz.
11761 2011-11-02 Yao Qi <yao@codesourcery.com>
11763 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11765 2011-11-02 Yao Qi <yao@codesourcery.com>
11767 * target.h: Fix a typo in comment.
11769 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11771 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11772 clobber the breakpoints' shadows with fast tracepoint jumps.
11773 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11774 * target.c (write_inferior_memory): Also pass MYADDR down to
11777 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11779 * configure.ac: Check support for personality routine.
11780 * configure: Regenerate.
11781 * config.in: Likewise.
11782 * linux-low.c: Include <sys/personality.h>.
11783 Define ADDR_NO_RANDOMIZE if necessary.
11784 (linux_create_inferior): Disable address space randomization when
11785 forking inferior, if requested.
11786 (linux_supports_disable_randomization): New function.
11787 (linux_target_ops): Install it.
11788 * server.h (disable_randomization): Declare.
11789 * server.c (disable_randomization): New global variable.
11790 (handle_general_set): Handle QDisableRandomization.
11791 (handle_query): Likewise for qSupported.
11792 (main): Support --disable-randomization and --no-disable-randomization
11793 command line arguments.
11794 * target.h (struct target_ops): Add supports_disable_randomization.
11795 (target_supports_disable_randomization): New macro.
11797 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11799 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11801 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11802 [!PT_GETDSBT] (target_loadmap): New definition.
11803 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11804 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11805 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11806 and PT_GETDSBT to LINUX_LOADMAP.
11807 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11808 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11810 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11812 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11813 (arm_linux_hwbp_cap): New static variable.
11814 (arm_linux_get_hwbp_cap): Replace by ...
11815 (arm_linux_init_hwbp_cap): ... this new function.
11816 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11817 (arm_linux_get_hw_watchpoint_count): Likewise.
11818 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11819 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11820 (arm_prepare_to_resume): Use perror_with_name instead of error.
11822 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11824 * linux-arm-low.c: Include <signal.h>.
11825 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11826 (struct arm_linux_hwbp_cap): New data type.
11827 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11828 (struct arm_linux_hw_breakpoint): New data type.
11829 (MAX_BPTS, MAX_WPTS): Define.
11830 (struct arch_process_info, struct arch_lwp_info): New data types.
11831 (arm_linux_get_hwbp_cap): New function.
11832 (arm_linux_get_hw_breakpoint_count): Likewise.
11833 (arm_linux_get_hw_watchpoint_count): Likewise.
11834 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11835 (arm_hwbp_control_initialize): Likewise.
11836 (arm_hwbp_control_is_enabled): Likewise.
11837 (arm_hwbp_control_is_initialized): Likewise.
11838 (arm_hwbp_control_disable): Likewise.
11839 (arm_linux_hw_breakpoint_equal): Likewise.
11840 (arm_linux_hw_point_initialize): Likewise.
11841 (struct update_registers_data): New data structure.
11842 (update_registers_callback: New function.
11843 (arm_insert_point): Likewise.
11844 (arm_remove_point): Likewise.
11845 (arm_stopped_by_watchpoint): Likewise.
11846 (arm_stopped_data_address): Likewise.
11847 (arm_new_process): Likewise.
11848 (arm_new_thread): Likewise.
11849 (arm_prepare_to_resume): Likewise.
11850 (the_low_target): Register arm_insert_point, arm_remove_point,
11851 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11852 arm_new_thread, and arm_prepare_to_resume.
11854 2011-09-15 Stan Shebs <stan@codesourcery.com>
11856 * server.h (struct emit_ops): Add compare-goto fields.
11857 * tracepoint.c (gdb_agent_op_sizes): New table.
11858 (emit_eq_goto): New function.
11859 (emit_ne_goto): New function.
11860 (emit_lt_goto): New function.
11861 (emit_le_goto): New function.
11862 (emit_gt_goto): New function.
11863 (emit_ge_goto): New function.
11864 (is_goto_target): New function.
11865 (compile_bytecodes): Recognize special cases of compare-goto
11866 combinations and call specialized emitters for them.
11867 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11868 (amd64_emit_ne_goto): New function.
11869 (amd64_emit_lt_goto): New function.
11870 (amd64_emit_le_goto): New function.
11871 (amd64_emit_gt_goto): New function.
11872 (amd64_emit_ge_goto): New function.
11873 (amd64_emit_ops): Add the new functions.
11874 (i386_emit_eq_goto): New function.
11875 (i386_emit_ne_goto): New function.
11876 (i386_emit_lt_goto): New function.
11877 (i386_emit_le_goto): New function.
11878 (i386_emit_gt_goto): New function.
11879 (i386_emit_ge_goto): New function.
11880 (i386_emit_ops): Add the new functions.
11882 2011-09-08 Stan Shebs <stan@codesourcery.com>
11884 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11885 (i386_emit_epilogue): Restore %ebx.
11887 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11889 * server.c (step_thread): Remove definition.
11890 (process_serial_event): Don't handle Hs.
11891 * server.h (step_thread): Remove declaration.
11892 * target.c (set_desired_inferior): Remove use of step_thread.
11894 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11896 * linux-low.c: Include linux-procfs.h.
11897 (linux_attach_lwp_1): Update comments.
11898 (linux_attach): Scan for existing threads when attaching to a
11899 process that is the tgid.
11900 * Makefile.in: Update dependencies.
11902 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11904 * configure.srv: Add linux-procfs.o dependencies.
11906 2011-08-14 Yao Qi <yao@codesourcery.com>
11908 * target.h (struct target_ops): Fix indent.
11909 * win32-low.c (win32_target_ops): Fix comment.
11911 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11912 Yao Qi <yao@codesourcery.com>
11914 * Makefile.in (clean): Remove tic6x-*.c files.
11915 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11916 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11917 (tic6x-c64xp-linux.c): Likewise.
11918 * configure.srv: Add support for tic6x-*-uclinux.
11919 * linux-tic6x-low.c: New.
11920 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11922 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11923 Yao Qi <yao@codesourcery.com>
11925 * target.h (struct target_ops): Add read_loadmap.
11926 * linux-low.c (struct target_loadseg): New type.
11927 (struct target_loadmap): New type.
11928 (linux_read_loadmap): New function.
11929 (linux_target_ops): Add linux_read_loadmap.
11930 * server.c (handle_query): Support qXfer:fdpic:read packet.
11931 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11934 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11936 * win32-low.c: Include <stdint.h>.
11938 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11940 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11941 to the inferior here.
11942 (i386_remove_aligned_watchpoint): Ditto.
11943 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11944 fit part of the watchpoint in the debug registers.
11945 (i386_update_inferior_debug_regs): New.
11946 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11947 registers, and only update the inferior on success.
11948 (i386_low_remove_watchpoint): Ditto.
11950 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11952 * linux-low.c (compare_ints, unique, list_threads, show_process,
11953 linux_core_of_thread): Delete.
11954 (linux_target_ops): Change linux_core_of_thread to
11955 linux_common_core_of_thread.
11956 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11957 * utils.c (malloc_failure): Change type of argument.
11958 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11959 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11960 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11961 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11962 (IPA_OBJS): Add common-utils-ipa.o.
11963 (ptid_h, linux_osdata_h): New macros.
11964 (server_h): Add common/common-utils.h, common/xml-utils.h,
11965 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11967 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11968 ptid.o, buffer.o): New rules.
11969 (linux-low.o): Add common/linux-osdata.h as a dependency.
11970 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11971 * configure.ac: Add AC_HEADER_DIRENT check.
11972 * config.in: Regenerate.
11973 * configure: Regenerate.
11974 * remote-utils.c (xml_escape_text): Delete.
11975 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11976 buffer_xml_printf): Move to common/buffer.c.
11977 * server.c (main): Remove call to initialize_inferiors.
11978 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11979 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11980 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11981 internal_error, gdb_assert, gdb_assert_fail): Delete.
11982 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11983 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11985 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11986 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11987 initialize_inferiors): Delete.
11989 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11991 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11994 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11996 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11998 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
12000 2011-05-26 Yao Qi <yao@codesourcery.com>
12002 * Makefile.in (thread-db.o): Track dependence to
12003 common/gdb_thread_db.h.
12004 * thread-db.c: include gdb_thread_db.h from right place.
12006 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
12008 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
12009 __FILE__ and __LINE__ to internal_error.
12011 2011-05-13 Doug Evans <dje@google.com>
12013 * thread-db.c (try_thread_db_load_from_sdir): New function.
12014 (try_thread_db_load_from_dir): New function.
12015 (thread_db_load_search): Handle $sdir, ignore $pdir.
12016 Remove trying of system directories if search of
12017 libthread-db-search-path fails, that is now done via $sdir.
12019 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
12021 * server.c (handle_query): Add EnableDisableTracepoints to the list
12022 of supported features.
12023 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
12025 (cmd_qtenable_disable): New.
12026 (cmd_qtstart): Install tracepoints even if disabled.
12027 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
12028 receiving a QTEnable or QTDisable packet.
12029 (gdb_collect): Skip data collection if fast tracepoint is disabled.
12030 (ust_marker_to_static_tracepoint): Do not ignore disabled static
12032 (gdb_probe): Skip data collection if static tracepoint is disabled.
12034 2011-05-10 Doug Evans <dje@google.com>
12036 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
12038 2011-05-04 Doug Evans <dje@google.com>
12040 * linux-low.c (linux_join): Skip process lookup.
12041 * spu-low.c (spu_join): Ditto.
12042 * server.c (join_inferiors_callback): Delete.
12043 (process_serial_event): For 'D' packet (detach) call join_inferior
12046 2011-05-04 Joseph Myers <joseph@codesourcery.com>
12048 * README: Don't mention xscale*-*-linux*.
12049 * configure.srv (xscale*-*-linux*): Don't handle target.
12051 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
12053 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
12055 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
12056 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
12057 (i386_emit_void_call_2): Likewise.
12059 2011-04-26 Yao Qi <yao@codesourcery.com>
12061 * linux-low.c: Move common macros to linux-ptrace.h.
12062 Include linux-ptrace.h.
12063 * Makefile.in (linux_ptrace_h): New.
12064 (linux-low.o): Depends on linux-ptrace.h.
12066 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
12068 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
12069 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
12070 (remote_prepare): New function with most of the TCP code from ...
12071 (remote_open): ... here. Detect PORT here unconditionally. Move also
12072 setting transport_is_reliable.
12073 * server.c (run_once): New variable.
12074 (gdbserver_usage): Document it.
12075 (main): Set run_once for `--once'. Call remote_prepare. Exit after
12076 the first run if RUN_ONCE.
12077 * server.h (run_once, remote_prepare): New declarations.
12079 2011-04-19 Tom Tromey <tromey@redhat.com>
12081 * win32-low.c (handle_load_dll): Remove duplicate "the".
12083 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
12085 Remove support for old Cygwin 1.5 versions.
12086 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
12087 function to avoid warning.
12088 (win32_add_one_solib): Use cygwin_conv_path function to avoid
12091 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
12093 * gdbserver/server.h (Macro _): Define it if not available.
12095 2011-03-14 Michael Snyder <msnyder@vmware.com>
12097 * hostio.c (handle_close): Remove unnecessary null test.
12099 2011-03-10 Joel Brobecker <brobecker@adacore.com>
12101 * Makefile.in (maintainer-clean realclean distclean): Remove
12102 "make ... subdir_do" command.
12104 2011-03-10 Michael Snyder <msnyder@vmware.com>
12106 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
12108 * server.c (handle_v_run): Free alloced buffer on early return.
12110 2011-03-09 Yao Qi <yao@codesourcery.com>
12113 2011-03-04 Yao Qi <yao@codesourcery.com>
12115 * Makefile.in: Remove GNU make feature --directory.
12117 2011-03-05 Yao Qi <yao@codesourcery.com>
12119 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12120 (subdir_do): New make target. Copied from gdb/Makefile.
12121 (maintainer-clean, realclean, distclean, clean): Call corresponding
12122 make targets in common/Makefile.
12124 2011-02-11 Yao Qi <yao@codesourcery.com>
12126 * configure.ac: Call AC_PROG_RANLIB.
12127 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12128 * configure: Regenerate.
12130 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12132 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
12134 2011-03-06 Yao Qi <yao@codesourcery.com>
12136 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
12138 2011-03-05 Yao Qi <yao@codesourcery.com>
12140 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12141 (subdir_do): New make target. Copied from gdb/Makefile.
12142 (maintainer-clean, realclean, distclean, clean): Call corresponding
12143 make targets in common/Makefile.
12145 2011-03-04 Yao Qi <yao@codesourcery.com>
12147 * Makefile.in: Remove GNU make feature --directory.
12149 2011-03-04 Michael Snyder <msnyder@vmware.com>
12151 * server.c (queue_stop_reply): Call xmalloc not malloc.
12153 2011-03-02 Michael Snyder <msnyder@vmware.com>
12155 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
12157 2011-02-28 Michael Snyder <msnyder@vmware.com>
12159 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
12160 (cmd_qtframe): Ditto.
12161 (cmd_qtbuffer): Ditto.
12162 (cmd_bigqtbuffer): Ditto.
12164 * utils.c (decimal2str): Initialize 'width' to nine, then
12165 don't mess with it.
12167 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
12169 * hostio.c (require_data): Free *data, not data.
12171 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12173 * hostio.c (require_data): Use free, not xfree.
12175 2011-02-27 Michael Snyder <msnyder@vmware.com>
12177 * server.c (handle_query): Discard unused value.
12179 * hostio.c (require_data): Free malloc memory before returning
12182 2011-02-26 Michael Snyder <msnyder@vmware.com>
12184 * linux-low.c (list_threads): Call closedir for dirent.
12186 2011-02-27 Michael Snyder <msnyder@vmware.com>
12188 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
12189 a case statement falls through.
12191 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
12193 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
12196 2011-02-26 Michael Snyder <msnyder@vmware.com>
12198 * utils.c (decimal2str): Eliminate dead code and dead param.
12199 (pulongest): Drop dead param from call to decimal2str.
12202 2011-02-24 Joel Brobecker <brobecker@adacore.com>
12204 Revert the following patch (not approved yet):
12205 2011-02-21 Hui Zhu <teawater@gmail.com>
12206 * tracepoint.c (tp_printf): New function.
12207 (eval_agent_expr): Handle gdb_agent_op_printf.
12209 2011-02-21 Hui Zhu <teawater@gmail.com>
12211 * tracepoint.c (tp_printf): New function.
12212 (eval_agent_expr): Handle gdb_agent_op_printf.
12214 2011-02-18 Tom Tromey <tromey@redhat.com>
12216 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
12217 (tracepoint.o): Likewise.
12218 * tracepoint.c (enum gdb_agent_op): Use ax.def.
12219 (gdb_agent_op_names): Likewise.
12221 2011-02-18 Tom Tromey <tromey@redhat.com>
12223 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
12224 gdb_agent_op_rot>: New constants.
12225 (gdb_agent_op_names): Add pick and roll.
12226 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
12229 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
12231 * aclocal.m4: Regenerated with aclocal-1.11.1.
12233 2011-02-14 Pedro Alves <pedro@codesourcery.com>
12235 * server.c (handle_qxfer_traceframe_info): New.
12236 (qxfer_packets): Register "traceframe-info".
12237 (handle_query): Report support for qXfer:traceframe-info:read+.
12238 * tracepoint.c (match_blocktype): New.
12239 (traceframe_find_block_type): Rename to ...
12240 (traceframe_walk_blocks): ... this. Add callback filter argument,
12242 (traceframe_find_block_type): New, reimplemented on top of
12243 traceframe_walk_blocks.
12244 (build_traceframe_info_xml): New.
12245 (traceframe_read_info): New.
12246 * server.h (traceframe_read_info): Declare.
12248 2011-02-11 Yao Qi <yao@codesourcery.com>
12250 * configure.ac: Call AC_PROG_RANLIB.
12251 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12252 * configure: Regenerate.
12254 2011-02-07 Pedro Alves <pedro@codesourcery.com>
12256 * server.c (gdb_read_memory): Change return semantics to allow
12258 (handle_search_memory_1): Adjust.
12259 (process_serial_event) <'m' packet>: Handle partial transfers.
12260 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12262 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12264 * regcache.c (init_register_cache): Initialize
12265 regcache->register_status.
12266 (free_register_cache): Release regcache->register_status.
12267 (regcache_cpy): Copy register_status.
12268 (registers_to_string): Print 'x's for unavailable registers.
12269 (supply_register): Mark the register's status valid or
12270 unavailable, depending on whether a buffer was passed in or not.
12271 (supply_register_zeroed): New.
12272 (supply_regblock): Mark the registers' status valid or
12273 unavailable, depending on whether a buffer was passed in or not.
12274 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12275 (struct regcache): New `register_status' field.
12276 (supply_register_zeroed): Declare.
12277 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12278 supply_register_zeroed, rather than passing a NULL buffer to
12280 * tracepoint.c (fetch_traceframe_registers): Update comment.
12282 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12284 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12287 2011-01-25 Pedro Alves <pedro@codesourcery.com>
12289 * server.h (decode_xfer_write): Change prototype.
12290 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12291 and don't extract the annex here.
12292 * server.c (decode_xfer_read): Remove `annex' parameter,
12293 and don't extract the annex here.
12294 (decode_xfer): New.
12295 (struct qxfer): New.
12296 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12297 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12298 (handle_qxfer_statictrace): New functions, abstracted out from
12299 handle_query, and made to use the struct qxfer interface.
12300 (handle_threads_qxfer_proper): Rename to ...
12301 (handle_qxfer_threads_proper): ... this.
12302 (handle_threads_qxfer): Rename to ...
12303 (handle_qxfer_threads): ... this. Adjust.
12304 (qxfer_packets): New array.
12305 (handle_qxfer): New function.
12306 (handle_query): Use handle_qxfer.
12308 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12310 * gdbreplay.c: Shorten lines of >= 80 columns.
12311 * linux-low.c: Ditto.
12312 * linux-ppc-low.c: Ditto.
12313 * linux-s390-low.c: Ditto.
12314 * linux-sparc-low.c: Ditto.
12315 * linux-x86-low.c: Ditto.
12316 * linux-xtensa-low.c: Ditto.
12317 * mem-break.c: Ditto.
12318 * nto-low.c: Ditto.
12319 * regcache.h: Ditto.
12320 * remote-utils.c: Ditto.
12323 * thread-db.c: Ditto.
12324 * tracepoint.c: Ditto.
12326 * win32-low.h: Ditto.
12328 2011-01-05 Joel Brobecker <brobecker@adacore.com>
12330 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12333 2011-01-01 Joel Brobecker <brobecker@adacore.com>
12335 * server.c (gdbserver_version): Update copyright year in version
12337 * gdbreplay.c (gdbreplay_version): Ditto.
12339 2010-12-29 Jie Zhang <jie.zhang@analog.com>
12341 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12342 * linux-bfin-low.c: New file.
12343 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12344 PT_DATA_ADDR for BFIN targets.
12345 * Makefile.in (SFILES): Add linux-bfin-low.c.
12346 (clean): Remove reg-bfin.c.
12347 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12348 * README: Mention supported Blackfin targets.
12350 2010-12-23 Mike Frysinger <vapier@gentoo.org>
12352 * .gitignore: New file.
12354 2010-11-16 Mike Frysinger <vapier@gentoo.org>
12356 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12358 2010-10-22 Jie Zhang <jie@codesourcery.com>
12360 * Makefile.in: Add FLAGS_TO_PASS variable.
12361 (install): Remove dependency of install-only and recursively
12362 invoke make for install-only.
12364 2010-10-04 Doug Evans <dje@google.com>
12366 * Makefile.in (uninstall): Use $(DESTDIR).
12368 2010-09-24 Pedro Alves <pedro@codesourcery.com>
12372 * linux-x86-low.c (compat_siginfo_from_siginfo)
12373 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12374 si_code is < 0. Check for si_code == SI_TIMER before checking for
12377 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12379 * lynx-i386-low.c: New file.
12380 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12382 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12384 * lynx-low.c (ptrace_request_to_str): Remove handling for
12385 request values that have been removed in LynxOS 5.x.
12387 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12389 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12392 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12394 * configure.ac: Add --enable-inprocess-agent option.
12395 * configure: Rebuilt.
12397 2010-09-06 Yao Qi <yao@codesourcery.com>
12399 * linux-low.c (linux_kill): Remove unused variable.
12400 (linux_stabilize_threads): Likewise.
12401 * server.c (start_inferior): Likewise.
12402 (queue_stop_reply_callback): Likewise.
12403 * tracepoint.c (do_action_at_tracepoint): Likewise.
12405 2010-09-06 Yao Qi <yao@codesourcery.com>
12407 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12410 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12412 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12414 2010-09-06 Pedro Alves <pedro@codesourcery.com>
12416 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12419 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12421 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12422 gdbserver/lynx-ppc-low.c: New files.
12423 * Makefile.in (lynx_low_h): New variable.
12424 (lynx-low.o, lynx-ppc-low.o): New rules.
12425 * configure.ac: On LynxOS, link with -lnetinet.
12426 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12427 * configure: regenerate.
12429 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12431 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12432 * configure.ac: Add check for vasprintf and vsnprintf.
12433 * configure, config.in: Regenerate.
12434 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12436 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12438 * gdbreplay.c: Move include of alloca.h up, next to include of
12440 * server.h: Add include of malloc.h.
12441 * mem-break.c: Remove include of malloc.h.
12442 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12444 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12446 * Makefile.in (memmem.o): Build with -Wno-error.
12448 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12450 * utils.c (xsnprintf): Make non-static.
12451 * server.h: Add xsnprintf declaration.
12452 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12453 replace calls to snprintf by calls to xsnprintf throughout.
12455 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12457 * configure.ac: Add configure check for alloca.
12458 * configure, config.in: Regenerate.
12459 * server.h: Include alloca.h if it exists.
12460 * gdbreplay.c: Include alloca.h if it exists.
12462 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12464 * linux-low.c (__SIGRTMIN): Define if not already defined.
12465 (linux_create_inferior): Check for __ANDROID__ rather than
12467 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12468 are already deferred.
12469 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12470 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12471 stopped and already has a pending signal to report.
12472 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12473 a pending signal to report or is moving out of a jump pad.
12474 (linux_init_signals): Check for __ANDROID__ rather than
12477 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12479 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12480 debug_threads check. Avoid a linear search when not doing debug
12483 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12485 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12486 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12487 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12488 (process_event): Change local fd's type to gdb_fildes_t.
12489 (create_file_handler): Adjust prototype.
12490 (delete_file_handler): Adjust prototype.
12491 (handle_file_event): Adjust prototype. Use pfildes.
12492 (create_file_event): Adjsut prototype.
12493 * remote-utils.c (remote_desc, listen_desc): Change type to
12495 * server.h: New gdb_fildes_t typedef.
12496 [USE_WIN32API]: Include winsock2.h.
12497 (delete_file_handler, add_file_handler): Adjust prototypes.
12498 (pfildes): Declare.
12499 * utils.c (pfildes): New.
12501 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12503 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12504 * configure: Regenerate.
12506 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12508 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12509 (linux_done_accessing_memory): ... this.
12510 (linux_target_ops): Adjust.
12511 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12512 * nto-low.c (nto_target_ops): Adjust comment.
12513 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12514 * spu-low.c (spu_target_ops): Adjust comment.
12515 * target.h (target_ops): Rename unprepare_to_access_memory field
12516 to done_accessing_memory.
12517 (unprepare_to_access_memory): Rename to ...
12518 (done_accessing_memory): ... this.
12520 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12522 * linux-low.c (linux_prepare_to_access_memory): New.
12523 (linux_unprepare_to_access_memory): New.
12524 (linux_target_ops): Install them.
12525 * server.c (read_memory): Rename to ...
12526 (gdb_read_memory): ... this. Use
12527 prepare_to_access_memory/prepare_to_access_memory.
12528 (write_memory): Rename to ...
12529 (gdb_write_memory): ... this. Use
12530 prepare_to_access_memory/prepare_to_access_memory.
12531 (handle_search_memory_1): Adjust.
12532 (process_serial_event): Adjust.
12533 * target.h (struct target_ops): New fields
12534 prepare_to_access_memory and unprepare_to_access_memory.
12535 (prepare_to_access_memory, unprepare_to_access_memory): New.
12536 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12537 prepare_to_access_memory/prepare_to_access_memory.
12538 * nto-low.c (nto_target_ops): Adjust.
12539 * spu-low.c (spu_target_ops): Adjust.
12540 * win32-low.c (win32_target_ops): Adjust.
12542 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12544 * Makefile.in (WARN_CFLAGS): Get it from configure.
12545 (WERROR_CFLAGS): New.
12546 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12547 * configure.ac: Introduce --enable-werror, which adds -Werror to
12548 the compiler command line. Enabled by default. Disable with
12549 --disable-werror. Add -Wdeclaration-after-statement
12550 Wpointer-arith and -Wformat-nonliteral to warning flags.
12551 * configure: Regenerate.
12553 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12555 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12557 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12559 * gdbreplay.c (remote_error): New.
12561 (expect): Use gdbchar. Check for error reading from GDB.
12562 Clarify sync error output.
12563 (play): Check for errors writing to GDB.
12564 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12565 * remote-utils.c (getpkt): Check for errors writing to the remote
12568 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12570 * linux-low.c (linux_wait_1): Move non-debugging code out of
12571 `debug_threads' control.
12573 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12575 * linux-low.c (linux_wait_1): Don't set last_status here.
12576 * server.c (push_event, queue_stop_reply_callback): Assert we're
12577 not pushing a TARGET_WAITKIND_IGNORE event.
12578 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12579 (myresume, handle_target_event): Set the thread's last_resume_kind
12580 and last_status from the target returned status.
12582 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12586 * linux-x86-low.c (update_debug_registers_callback): New.
12587 (i386_dr_low_set_addr): Use it.
12588 (i386_dr_low_get_addr): New.
12589 (i386_dr_low_set_control): Use update_debug_registers_callback.
12590 (i386_dr_low_get_control): New.
12591 (i386_dr_low_get_status): Adjust.
12592 * linux-low.c (linux_stop_lwp): New.
12593 * linux-low.h (linux_stop_lwp): Declare.
12595 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12596 argument instead of a i386_debug_reg_state.
12597 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12598 a i386_debug_reg_state.
12599 (i386_insert_aligned_watchpoint): Adjust.
12600 (i386_remove_aligned_watchpoint): Adjust.
12601 (i386_low_stopped_data_address): Read the debug registers from the
12602 inferior instead of from the mirrors.
12603 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12604 (i386_dr_low_get_addr): Declare.
12605 (i386_dr_low_get_control): Declare.
12606 (i386_dr_low_get_status): Change prototype.
12608 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12609 (i386_dr_low_get_addr): New.
12610 (i386_dr_low_get_control): New.
12611 (i386_dr_low_get_status): Adjust prototype. Return
12613 (i386_initial_stuff): Clear dr_status_mirror and
12615 (i386_get_thread_context): Adjust.
12616 (i386_set_thread_context): Adjust.
12617 (i386_thread_added): Adjust.
12619 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12621 * linux-low.h (linux_thread_area): Delete declaration.
12623 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12625 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12626 after its termination.
12628 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12630 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12631 (gdb_wants_all_stopped): Delete.
12632 (linux_wait_1): Don't call them.
12633 * server.c (handle_v_cont): Tag all threads as want-stopped.
12634 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12635 stopped as "client-wants-stopped".
12637 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12639 * Makefile.in (signals_h): New.
12640 (server_h): Depend on it.
12641 (server.o): Don't depend on $(signals_def).
12642 (signals.o): Depend on $(signals_def).
12644 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12646 * Makefile.in (signals_def): New.
12647 (server_h): Append include/gdb/signals.h and signals_def.
12648 (server.o): Append signals_def.
12650 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12652 * server.c (handle_target_event): Use target_signal_to_host for
12653 resume_info.sig initialization.
12654 * target.h (struct thread_resume) <sig>: New comment.
12656 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12658 * server.c (handle_query): strcpy() the returned string from paddress()
12659 instead of sprintf().
12660 * utils.c (paddress): Return phex_nz().
12662 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12664 * server.c (handle_v_cont): Call mourn_inferior if process
12666 (myresume): Likewise.
12668 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12670 Static tracepoints, and integration with UST.
12672 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12673 * mem-break.c (uninsert_all_breakpoints)
12674 (reinsert_all_breakpoints): New.
12675 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12676 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12677 (gdb_agent_ust_loaded, helper_thread_id)
12678 (gdb_agent_helper_thread_id): New macros.
12679 (struct ipa_sym_addresses): Add addr_ust_loaded,
12680 addr_helper_thread_id, addr_cmd_buf.
12681 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12682 (in_process_agent_loaded_ust): New.
12683 (write_e_ust_not_loaded): New.
12684 (maybe_write_ipa_ust_not_loaded): New.
12685 (struct collect_static_trace_data_action): New.
12686 (enum tracepoint_type) <static_tracepoint>: New.
12687 (struct tracepoint) <handle>: Mention static tracepoints.
12688 (struct static_tracepoint_ctx): New.
12689 (CMD_BUF_SIZE): New.
12690 (add_tracepoint_action): Handle static tracepoint actions.
12691 (unprobe_marker_at): New.
12692 (clear_installed_tracepoints): Handle static tracepoints.
12693 (cmd_qtdp): Handle static tracepoints.
12694 (probe_marker_at): New.
12695 (cmd_qtstart): Handle static tracepoints.
12696 (response_tracepoint): Handle static tracepoints.
12697 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12698 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12699 (get_context_regcache): Handle static tracepoints.
12700 (do_action_at_tracepoint): Handle static tracepoint actions.
12701 (traceframe_find_block_type): Handle static trace data blocks.
12702 (traceframe_read_sdata): New.
12703 (download_tracepoints): Download static tracepoint actions.
12704 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12705 (GDB_PROBE_NAME): New.
12707 (GET_UST_SYM): New.
12710 (ust_marker_to_static_tracepoint): New.
12712 (collect_ust_data_at_tracepoint): New.
12713 (gdb_ust_probe): New.
12714 (UNIX_PATH_MAX, SOCK_DIR): New.
12715 (gdb_ust_connect_sync_socket): New.
12716 (resume_thread, stop_thread): New.
12717 (run_inferior_command): New.
12718 (init_named_socket): New.
12719 (gdb_ust_socket_init): New.
12720 (cstr_to_hexstr): New.
12722 (first_marker, next_marker): New.
12723 (response_ust_marker): New.
12724 (cmd_qtfstm, cmd_qtsstm): New.
12725 (unprobe_marker_at, probe_marker_at): New.
12726 (cmd_qtstmat, gdb_ust_thread): New.
12727 (gdb_ust_init): New.
12728 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12729 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12730 (ST_REGENTRY): New.
12731 (x86_64_st_collect_regmap): New.
12732 (X86_64_NUM_ST_COLLECT_GREGS): New.
12733 (AMD64_RIP_REGNUM): New.
12734 (supply_static_tracepoint_registers): New.
12735 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12736 (ST_REGENTRY): New.
12737 (i386_st_collect_regmap): New.
12738 (i386_NUM_ST_COLLECT_GREGS): New.
12739 (supply_static_tracepoint_registers): New.
12740 * server.c (handle_query): Handle qXfer:statictrace:read.
12741 <qSupported>: Report support for StaticTracepoints, and
12742 qXfer:statictrace:read features.
12743 * server.h (traceframe_read_sdata)
12744 (supply_static_tracepoint_registers): Declare.
12745 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12746 (unpack_varlen_hex): Include in IPA build.
12747 * Makefile.in (ustlibs, ustinc): New.
12748 (IPA_OBJS): Add remote-utils-ipa.o.
12749 ($(IPA_LIB)): Link -ldl and -lpthread.
12751 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12752 * config.in, configure: Regenerate.
12754 2010-06-20 Ian Lance Taylor <iant@google.com>
12755 Pedro Alves <pedro@codesourcery.com>
12757 * linux-x86-low.c (always_true): Delete.
12758 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12759 trying to fool the compiler with always_true.
12761 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12763 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12764 conditions in gdbserver.
12766 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12768 * spu-low.c (spu_read_memory): Wrap around local store limit.
12769 (spu_write_memory): Likewise.
12771 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12773 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12774 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12776 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12778 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12779 uses with LONGEST uses.
12781 2010-06-14 Stan Shebs <stan@codesourcery.com>
12782 Pedro Alves <pedro@codesourcery.com>
12786 * linux-x86-low.c: Include limits.h.
12788 (always_true): New.
12791 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12792 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12793 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12794 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12795 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12796 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12797 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12798 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12799 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12800 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12801 (amd64_emit_void_call_2): New.
12802 (amd64_emit_ops): New.
12803 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12804 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12805 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12806 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12807 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12808 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12809 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12810 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12811 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12812 (i386_emit_stack_adjust, i386_emit_int_call_1)
12813 (i386_emit_void_call_2): New.
12814 (i386_emit_ops): New.
12815 (x86_emit_ops): New.
12816 (the_low_target): Install x86_emit_ops.
12817 * server.h (struct emit_ops): New.
12818 (get_raw_reg_func_addr): Declare.
12819 (current_insn_ptr, emit_error): Declare.
12820 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12821 (set_trace_state_variable_value): New defines.
12822 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12823 addr_get_trace_state_variable_value and
12824 addr_set_trace_state_variable_value.
12825 (symbol_list): New fields for get_raw_reg,
12826 get_trace_state_variable_value and set_trace_state_variable_value.
12827 (condfn): New typedef.
12828 (struct tracepoint): New field `compiled_cond'.
12829 (do_action_at_tracepoint): Clear compiled_cond.
12830 (get_trace_state_variable_value, set_trace_state_variable_value):
12832 (condition_true_at_tracepoint): If there's a compiled condition,
12834 (current_insn_ptr, emit_error): New globals.
12835 (struct bytecode_address): New.
12836 (get_raw_reg_func_addr): New.
12837 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12838 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12839 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12840 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12841 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12842 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12843 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12844 (compile_tracepoint_condition, compile_bytecodes): New.
12845 * target.h (emit_ops): Forward declare.
12846 (struct target_ops): New field emit_ops.
12847 (target_emit_ops): New.
12848 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12849 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12850 * linux-low.c (linux_emit_ops): New.
12851 (linux_target_ops): Install it.
12852 * linux-low.h (struct linux_target_ops): New field emit_ops.
12854 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12856 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12857 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12859 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12860 Stan Shebs <stan@codesourcery.com>
12862 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12863 (all): Depend on $(extra_libraries).
12864 (install-only): Install the IPA.
12865 (IPA_OBJS, IPA_LIB): New.
12866 (clean): Remove the IPA lib.
12867 (IPAGENT_CFLAGS): New.
12868 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12869 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12870 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12871 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12872 * configure.ac: Check for atomic builtins support in the compiler.
12873 (IPA_DEPFILES, extra_libraries): Define.
12874 * configure.srv (ipa_obj): Add description.
12875 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12876 (i[34567]86-*-linux*): Set ipa_obj.
12877 (x86_64-*-linux*): Set ipa_obj.
12878 * linux-low.c (stabilizing_threads): New.
12879 (supports_fast_tracepoints): New.
12880 (linux_detach): Stabilize threads before detaching.
12881 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12882 the lwp is either not stabilizing, or is moving out of a jump pad.
12883 (linux_fast_tracepoint_collecting): New.
12884 (maybe_move_out_of_jump_pad): New.
12885 (enqueue_one_deferred_signal): New.
12886 (dequeue_one_deferred_signal): New.
12887 (linux_wait_for_event_1): If moving out of a jump pad, defer
12888 pending signals to later.
12889 (linux_stabilize_threads): New.
12890 (linux_wait_1): Check if threads need moving out of jump pads, and
12892 (stuck_in_jump_pad_callback): New.
12893 (move_out_of_jump_pad_callback): New.
12894 (lwp_running): New.
12895 (linux_resume_one_lwp): Handle moving out of jump pads.
12896 (linux_set_resume_request): Dequeue deferred signals.
12897 (need_step_over_p): Also step over fast tracepoint jumps.
12898 (start_step_over): Also uninsert fast tracepoint jumps.
12899 (finish_step_over): Also reinsert fast tracepoint jumps.
12900 (linux_install_fast_tracepoint_jump): New.
12901 (linux_target_ops): Install linux_stabilize_threads and
12902 linux_install_fast_tracepoint_jump_pad.
12903 * linux-low.h (linux_target_ops) <get_thread_area,
12904 install_fast_tracepoint_jump_pad>: New fields.
12905 (struct lwp_info) <collecting_fast_tracepoint,
12906 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12907 (linux_get_thread_area): Declare.
12908 * linux-x86-low.c (jump_insn): New.
12909 (x86_get_thread_area): New.
12910 (append_insns): New.
12911 (push_opcode): New.
12912 (amd64_install_fast_tracepoint_jump_pad): New.
12913 (i386_install_fast_tracepoint_jump_pad): New.
12914 (x86_install_fast_tracepoint_jump_pad): New.
12915 (the_low_target): Install x86_get_thread_area and
12916 x86_install_fast_tracepoint_jump_pad.
12917 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12918 (struct fast_tracepoint_jump): New.
12919 (fast_tracepoint_jump_insn): New.
12920 (fast_tracepoint_jump_shadow): New.
12921 (find_fast_tracepoint_jump_at): New.
12922 (fast_tracepoint_jump_here): New.
12923 (delete_fast_tracepoint_jump): New.
12924 (set_fast_tracepoint_jump): New.
12925 (uninsert_fast_tracepoint_jumps_at): New.
12926 (reinsert_fast_tracepoint_jumps_at): New.
12927 (set_breakpoint_at): Use write_inferior_memory.
12928 (uninsert_raw_breakpoint): Use write_inferior_memory.
12929 (check_mem_read): Mask out fast tracepoint jumps.
12930 (check_mem_write): Mask out fast tracepoint jumps.
12931 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12932 (set_fast_tracepoint_jump): Declare.
12933 (delete_fast_tracepoint_jump)
12934 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12935 (reinsert_fast_tracepoint_jumps_at): Declare.
12936 * regcache.c: Don't compile many functions when building the
12937 in-process agent library.
12938 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12939 the register buffer in the heap.
12940 (free_register_cache): If the register buffer isn't owned by the
12941 regcache, don't free it.
12942 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12943 pre-existing register caches.
12944 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12946 (convert_ascii_to_int): : Constify `from' parameter type.
12947 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12948 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12949 the needed buffer in-place.
12950 (relocate_instruction): New.
12951 * server.c (handle_query) <qSymbols>: If the target supports
12952 tracepoints, give it a chance of looking up symbols. Report
12953 support for fast tracepoints.
12954 (handle_status): Stabilize threads.
12955 (process_serial_event): Adjust.
12956 * server.h (struct fast_tracepoint_jump): Forward declare.
12957 (struct process_info) <fast_tracepoint_jumps>: New field.
12958 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12959 (decode_X_packet, decode_M_packet): Adjust.
12960 (relocate_instruction): Declare.
12961 (in_process_agent_loaded): Declare.
12962 (tracepoint_look_up_symbols): Declare.
12963 (struct fast_tpoint_collect_status): Declare.
12964 (fast_tracepoint_collecting): Declare.
12965 (force_unlock_trace_buffer): Declare.
12966 (handle_tracepoint_bkpts): Declare.
12967 (initialize_low_tracepoint)
12968 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12969 * target.h (struct target_ops) <stabilize_threads,
12970 install_fast_tracepoint_jump_pad>: New fields.
12971 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12972 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12973 [HAVE_STDINT_H]: Include stdint.h.
12974 (trace_debug_1): Rename to ...
12975 (trace_vdebug): ... this.
12976 (trace_debug): Rename to ...
12977 (trace_debug_1): ... this. Add `level' parameter.
12978 (trace_debug): New.
12979 (ATTR_USED, ATTR_NOINLINE): New.
12980 (IP_AGENT_EXPORT): New.
12981 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12982 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12983 (about_to_request_buffer_space, trace_buffer_is_full)
12984 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12985 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12986 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12987 (traceframe_write_count, traceframes_created)
12988 (trace_state_variables)
12989 New renaming defines.
12990 (struct ipa_sym_addresses): New.
12991 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12992 (symbol_list): New.
12993 (ipa_sym_addrs): New.
12994 (all_tracepoint_symbols_looked_up): New.
12995 (in_process_agent_loaded): New.
12996 (write_e_ipa_not_loaded): New.
12997 (maybe_write_ipa_not_loaded): New.
12998 (tracepoint_look_up_symbols): New.
12999 (debug_threads) [IN_PROCESS_AGENT]: New.
13000 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
13001 (UNKNOWN_SIDE_EFFECTS): New.
13002 (stop_tracing): New.
13003 (flush_trace_buffer): New.
13004 (stop_tracing_bkpt): New.
13005 (flush_trace_buffer_bkpt): New.
13006 (read_inferior_integer): New.
13007 (read_inferior_uinteger): New.
13008 (read_inferior_data_pointer): New.
13009 (write_inferior_data_pointer): New.
13010 (write_inferior_integer): New.
13011 (write_inferior_uinteger): New.
13012 (struct collect_static_trace_data_action): Delete.
13013 (enum tracepoint_type): New.
13014 (struct tracepoint) <type>: New field `type'.
13015 <actions_str, step_actions, step_actions_str>: Only include in
13017 <orig_size, obj_addr_on_target, adjusted_insn_addr>
13018 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
13019 (tracepoints): Use IP_AGENT_EXPORT.
13020 (last_tracepoint): Don't include in the IPA.
13021 (stopping_tracepoint): Use IP_AGENT_EXPORT.
13022 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
13023 (alloced_trace_state_variables): New.
13024 (trace_state_variables): Use IP_AGENT_EXPORT.
13025 (traceframe_t): Delete unused variable.
13026 (circular_trace_buffer): Don't include in the IPA.
13027 (trace_buffer_start): Delete.
13028 (struct trace_buffer_control): New.
13029 (trace_buffer_free): Delete.
13030 (struct ipa_trace_buffer_control): New.
13031 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
13032 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
13034 (trace_buffer_ctrl): New.
13035 (TRACE_BUFFER_CTRL_CURR): New.
13036 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
13037 Reimplement as macros.
13038 (trace_buffer_wrap): Delete.
13039 (traceframe_write_count, traceframe_read_count)
13040 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
13041 (struct tracepoint_hit_ctx) <type>: New field.
13042 (struct fast_tracepoint_ctx): New.
13043 (memory_barrier): New.
13045 (record_tracepoint_error): Update atomically in the IPA.
13046 (clear_inferior_trace_buffer): New.
13047 (about_to_request_buffer_space): New.
13048 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
13049 updating the same buffer.
13050 (add_tracepoint): Default the tracepoint's type to trap
13051 tracepoint, and orig_size to -1.
13052 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
13053 internal variables.
13054 (create_trace_state_variable): New parameter `gdb'. Handle it.
13055 (clear_installed_tracepoints): Clear fast tracepoint jumps.
13056 (cmd_qtdp): Handle fast tracepoints.
13057 (cmd_qtdv): Adjust.
13058 (max_jump_pad_size): New.
13059 (gdb_jump_pad_head): New.
13060 (get_jump_space_head): New.
13061 (claim_jump_space): New.
13062 (sort_tracepoints): New.
13063 (MAX_JUMP_SIZE): New.
13064 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
13066 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
13067 support. Upload fast traceframes, and delete internal IPA
13069 (stop_tracing_handler): New.
13070 (flush_trace_buffer_handler): New.
13071 (cmd_qtstop): Upload fast tracepoints.
13072 (response_tracepoint): Handle fast tracepoints.
13073 (tracepoint_finished_step): Upload fast traceframes. Set the
13074 tracepoint hit context's tracepoint type.
13075 (handle_tracepoint_bkpts): New.
13076 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
13077 type. Add comment about fast tracepoints.
13078 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
13079 non-existing action_str field.
13080 (get_context_regcache): Handle fast tracepoints.
13081 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
13083 (fast_tracepoint_from_jump_pad_address): New.
13084 (fast_tracepoint_from_ipa_tpoint_address): New.
13085 (collecting_t): New.
13086 (force_unlock_trace_buffer): New.
13087 (fast_tracepoint_collecting): New.
13089 (gdb_collect): New.
13090 (write_inferior_data_ptr): New.
13091 (target_tp_heap): New.
13092 (target_malloc): New.
13093 (download_agent_expr): New.
13095 (download_tracepoints): New.
13096 (download_trace_state_variables): New.
13097 (upload_fast_traceframes): New.
13098 (IPA_FIRST_TRACEFRAME): New.
13099 (IPA_NEXT_TRACEFRAME_1): New.
13100 (IPA_NEXT_TRACEFRAME): New.
13101 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
13102 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
13103 (gdb_jump_pad_buffer_end): New.
13104 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
13105 (initialize_tracepoint): Adjust.
13106 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
13107 buffer. Initialize the low module.
13108 * utils.c (PREFIX, TOOLNAME): New.
13109 (malloc_failure): Use PREFIX.
13110 (error): In the IPA, an error causes an exit.
13111 (fatal, warning): Use PREFIX.
13112 (internal_error): Use TOOLNAME.
13113 (NUMCELLS): Increase to 10.
13114 * configure, config.in: Regenerate.
13116 2010-06-01 Pedro Alves <pedro@codesourcery.com>
13118 * server.c (handle_query) <qSupported>: Do two passes over the
13119 qSupported string to avoid nesting strtok.
13121 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13123 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
13125 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
13126 -Wl,--dynamic-list.
13127 * configure: Regenerate.
13128 * proc-service.list: New.
13130 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13132 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
13135 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
13137 * gdbreplay.c (remote_open): Check error return from socket() call by
13138 its equality to -1 not by it being negative.
13139 * remote-utils.c (remote_open): Likewise.
13141 2010-05-23 Pedro Alves <pedro@codesourcery.com>
13143 * config.h: Regenerate.
13145 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13147 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
13148 doesn't provide PTRACE_GET_THREAD_AREA.
13150 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13152 * linux-m68k-low.c: Include <asm/ptrace.h>
13153 (ps_get_thread_area): Implement.
13155 2010-05-03 Doug Evans <dje@google.com>
13157 * event-loop.c (struct callback_event): New struct.
13158 (callback_list): New global.
13159 (append_callback_event, delete_callback_event): New functions.
13160 (process_callback): New function.
13161 (start_event_loop): Call it.
13162 * remote-utils.c (NOT_SCHEDULED): Define.
13163 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
13164 moved out of readchar.
13165 (readchar): Rewrite. Call reschedule before returning.
13166 (reset_readchar): New function.
13167 (remote_close): Call it.
13168 (process_remaining, reschedule): New functions.
13169 * server.h (callback_handler_func): New typedef.
13170 (append_callback_event, delete_callback_event): Declare.
13172 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13174 * proc-service.c (ps_pglobal_lookup): Use
13175 thread_db_look_up_one_symbol.
13176 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
13177 parameter. Use it instead of all_symbols_looked_up.
13178 * server.h (struct process_info) <all_symbols_looked_up>: Delete
13180 (all_symbols_looked_up): Don't declare.
13181 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
13182 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
13184 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
13185 Set all_symbols_looked_up here.
13186 (thread_db_look_up_one_symbol): New.
13187 (thread_db_get_tls_address): Adjust.
13188 (thread_db_load_search, try_thread_db_load_1): Always allocate the
13189 thread_db object on the heap, and tentatively set it in the
13191 (thread_db_init): Don't set all_symbols_looked_up here.
13192 * linux-low.h (thread_db_look_up_one_symbol): Declare.
13194 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13196 * linux-low.c (linux_kill, linux_detach): Adjust.
13197 (status_pending_p_callback): Remove redundant statement. Check
13198 for !TARGET_WAITIKIND_IGNORE, instead of
13199 TARGET_WAITKIND_STOPPED.
13200 (handle_tracepoints): Make sure LWP is locked. Adjust.
13201 (linux_wait_for_event_1): Adjust.
13202 (linux_cancel_breakpoints): New.
13203 (unsuspend_one_lwp): New.
13204 (unsuspend_all_lwps): New.
13205 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
13206 (send_sigstop_callback): Change return type to int, add new
13207 `except' parameter and handle it.
13208 (suspend_and_send_sigstop_callback): New.
13209 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
13210 pass them down. If SUSPEND, also increment the lwp's suspend
13212 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
13213 (need_step_over_p): Don't consider suspended LWPs.
13214 (start_step_over): Adjust.
13215 (proceed_one_lwp): Change return type to int, add new `except'
13216 parameter and handle it.
13217 (unsuspend_and_proceed_one_lwp): New.
13218 (proceed_all_lwps): Use find_inferior instead of
13220 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
13221 also decrement the suspend count of LWPs. Pass `except' down,
13222 instead of hacking its suspend count.
13223 (linux_pause_all): Add `freeze' parameter. Adjust.
13224 (linux_unpause_all): New.
13225 (linux_target_ops): Install linux_unpause_all.
13226 * server.c (handle_status): Adjust.
13227 * target.h (struct target_ops): New fields `unpause_all' and
13228 `cancel_breakpoints'. Add new parameter to `pause_all'.
13229 (pause_all): Add new `freeze' parameter.
13230 (unpause_all): New.
13231 (cancel_breakpoints): New.
13232 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
13233 cancel breakpoints.
13234 (cmd_qtstart): Pause threads.
13235 (stop_tracing): Pause threads, and cancel breakpoints.
13236 * win32-low.c (win32_target_ops): Adjust.
13238 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13240 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13241 the inferior right away from here...
13242 (linux_wait_1): ... to here, and adjust to check the thread's
13243 last_resume_kind instead of the lwp's step or stop_expected flags.
13245 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13247 * README: Use consistent `GDB' and `GDBserver' spellings.
13249 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13251 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13252 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13253 (linux_detach_one_lwp): Assume the lwp is stopped.
13254 (any_thread_of): Delete.
13255 (linux_detach): Stop all lwps here. Don't blindly delete all
13257 (delete_lwp_callback): New.
13258 (linux_mourn): Delete all lwps of the process that is gone.
13259 (linux_wait_1): Don't delete the last lwp of the process here.
13260 * mem-break.h (mark_breakpoints_out): Declare.
13261 * mem-break.c (mark_breakpoints_out): New.
13262 (free_all_breakpoints): Use it.
13263 * server.c (handle_target_event): If the process is gone, mark
13265 * thread-db.c (struct thread_db) <create_bp>: New field.
13266 (thread_db_enable_reporting): Fix prototype. Store a thread event
13267 breakpoint reference in the thread_db struct.
13268 (thread_db_load_search): Clear the thread_db object.
13269 (try_thread_db_load_1): Ditto.
13270 (switch_to_process): New.
13271 (disable_thread_event_reporting): Use it.
13272 (remove_thread_event_breakpoints): New.
13273 (thread_db_detach, thread_db_mourn): Use it.
13275 2010-05-01 Pedro Alves <pedro@codesourcery.com>
13277 * linux-low.c (linux_enable_event_reporting): New.
13278 (linux_wait_for_event_1, handle_extended_wait): Use it.
13280 2010-04-30 Pedro Alves <pedro@codesourcery.com>
13282 * linux-low.c (linux_kill_one_lwp, linux_kill)
13283 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13284 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13285 SIGSTOP even if the LWP is stopped.
13286 (send_sigstop_callback): New.
13287 (stop_all_lwps): Use send_sigstop_callback instead.
13288 (linux_resume_one_thread): Adjust.
13289 (proceed_one_lwp): Still proceed an LWP that the client has
13290 requested to stop, if we haven't reported it as stopped yet. Make
13291 sure that LWPs the client want stopped, have a pending SIGSTOP.
13293 2010-04-26 Doug Evans <dje@google.com>
13295 * server.c (handle_general_set): Make static.
13297 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13298 Print received char after testing for error/eof instead of before.
13299 (input_interrupt): Tweak comment.
13301 2010-04-23 Doug Evans <dje@google.com>
13303 * server.c (start_inferior): Print inferior argv if --debug.
13305 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13307 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13308 * nto-x86-low.c: Include server.h
13310 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13312 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13313 be consistent with other sources of this directory.
13314 (init_registers_amd64): Correct name of source file of this function
13317 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13319 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13320 64-bit executables.
13322 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13324 * win32-i386-low.c: Add 64-bit support.
13325 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13326 (init_registers_amd64): Declare.
13327 (mappings): Add 64-bit version of array.
13328 (init_windows_x86): New function.
13329 (the_low_target): Change init_arch field to init_windows_x86.
13331 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13333 * win32-low.c: Adapt to support also 64-bit architecture.
13334 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13335 (get_image_name): Use SIZE_T type for local variable `done'.
13336 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13337 (toolhelp_get_dll_name): Idem.
13338 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13339 Use uintptr_t typecast to avoid warning.
13340 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13341 (handle_exception): Use phex_nz to avoid warning.
13342 (win32_wait): Remove unused local variable `process'.
13344 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13346 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13349 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13351 * configure.ac: Use `ws2_32' library for srv_mingw.
13352 * configure: Regenerate.
13353 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13354 * remote-utils.c: Likewise.
13356 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13358 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13359 if __x86_64__ is defined.
13361 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13363 * configure: Regenerate.
13365 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13367 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13368 * target.h (target_ops): New get_tib_address field.
13369 * win32-low.h (win32_thread_info): Add thread_local_base field.
13370 * win32-low.c (child_add_thread): Add tlb argument.
13371 Set thread_local_base field to TLB.
13372 (get_child_debug_event): Adapt to child_add_thread change.
13373 (win32_get_tib_address): New function.
13374 (win32_target_ops): Set get_tib_address field to
13375 win32_get_tib_address.
13376 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13378 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13380 * linux-low.c (linux_mourn): Also remove the process.
13381 * server.c (handle_target_event): Don't remove the process here.
13382 * nto-low.c (nto_mourn): New.
13383 (nto_target_ops): Install it.
13384 * spu-low.c (spu_mourn): New.
13385 (spu_target_ops): Install it.
13386 * win32-low.c (win32_mourn): New.
13387 (win32_target_ops): Install it.
13389 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13391 * server.h (buffer_xml_printf): Remove redundant `;'.
13393 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13395 * regcache.c (set_register_cache): Invalidate regcaches before
13396 changing the register cache layout.
13397 (regcache_invalidate_one): Allow a NULL regcache.
13398 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13399 regcaches before changing the register cache layout or the target
13402 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13404 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13405 variable warning on Linux/x86-64.
13407 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13409 GDBserver disconnected tracing support.
13411 * linux-low.c (linux_remove_process): Delete.
13412 (add_lwp): Don't set last_resume_kind here.
13413 (linux_kill): Use `mourn'.
13414 (linux_detach): Use `thread_db_detach', and `mourn'.
13415 (linux_mourn): New.
13416 (linux_attach_lwp_1): Adjust comment.
13417 (linux_attach): last_resume_kind moved the thread_info; adjust.
13418 (status_pending_p_callback): Adjust.
13419 (linux_wait_for_event_1): Adjust.
13420 (count_events_callback, select_singlestep_lwp_callback)
13421 (select_event_lwp_callback, cancel_breakpoints_callback)
13422 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13423 (proceed_one_lwp): Adjust.
13424 (linux_async): Add debug output.
13425 (linux_thread_stopped): New.
13426 (linux_pause_all): New.
13427 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13429 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13430 (thread_db_free): Delete declaration.
13431 (thread_db_detach, thread_db_mourn): Declare.
13432 * thread-db.c (thread_db_init): Use thread_db_mourn.
13433 (thread_db_free): Delete, split in two.
13434 (disable_thread_event_reporting): New.
13435 (thread_db_detach): New.
13436 (thread_db_mourn): New.
13438 * server.h (struct thread_info) <last_resume_kind>: New field.
13439 <attached>: Add comment.
13440 <gdb_detached>: New field.
13441 (handler_func): Change return type to int.
13442 (handle_serial_event, handle_target_event): Ditto.
13443 (gdb_connected): Declare.
13445 (disconnected_tracing): Declare.
13446 (stop_tracing): Declare.
13448 * server.c (handle_query) <qSupported>: Report support for
13449 disconnected tracing.
13450 (queue_stop_reply_callback): Account for running threads.
13451 (gdb_wants_thread_stopped): New.
13452 (gdb_wants_all_threads_stopped): New.
13453 (gdb_reattached_process): New.
13454 (handle_status): Clear the `gdb_detached' flag of all processes.
13455 In all-stop, stop all threads.
13456 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13457 (process_serial_event): If the remote connection breaks, or if an
13458 exit was forced with "monitor exit", force an event loop exit.
13459 Handle disconnected tracing on detach.
13460 (handle_serial_event): Adjust.
13461 (handle_target_event): If GDB isn't connected, forward events back
13462 to the inferior, unless the last process exited, in which case,
13463 exit gdbserver. Adjust interface.
13465 * remote-utils.c (remote_open): Don't block in accept. Instead
13466 register an event loop source on the listen socket file
13467 descriptor. Refactor bits into ...
13468 (listen_desc): ... this new global.
13469 (gdb_connected): ... this new function.
13470 (enable_async_notification): ... this new function.
13471 (handle_accept_event): ... this new function.
13472 (remote_close): Clear remote_desc.
13474 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13476 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13478 (mourn_inferior): Define.
13479 (target_process_qsupported): Avoid the dangling else problem.
13480 (thread_stopped): Define.
13481 (pause_all): Define.
13482 (target_waitstatus_to_string): Declare.
13483 * target.c (target_waitstatus_to_string): New.
13485 * tracepoint.c (tracing): Make extern.
13486 (disconnected_tracing): New.
13487 (stop_tracing): Make extern. Handle tracing stops due to GDB
13489 (cmd_qtdisconnected): New.
13490 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13491 (handle_tracepoint_general_set): Handle QTDisconnected.
13493 * event-loop.c (event_handler_func): Change return type to int.
13494 (process_event): Bail out if the event handler wants the event
13496 (handle_file_event): Ditto.
13497 (start_event_loop): Bail out if the event handler wants the event
13500 * nto-low.c (nto_target_ops): Adjust.
13501 * spu-low.c (spu_wait): Don't remove the process here.
13502 (spu_target_ops): Adjust.
13503 * win32-low.c (win32_wait): Don't remove the process here.
13504 (win32_target_ops): Adjust.
13506 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13508 * regcache.c (realloc_register_cache): Invalidate inferior's
13509 regcache before recreating it.
13511 2010-04-09 Pedro Alves <pedro@codesourcery.com>
13513 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13515 2010-04-09 Stan Shebs <stan@codesourcery.com>
13516 Pedro Alves <pedro@codesourcery.com>
13518 * server.h (LONGEST): New.
13519 (struct thread_info) <while_stepping>: New field.
13520 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13522 (initialize_tracepoint, handle_tracepoint_general_set)
13523 (handle_tracepoint_query, tracepoint_finished_step)
13524 (tracepoint_was_hit, release_while_stepping_state_list):
13525 (current_traceframe): Declare.
13526 * server.c (handle_general_set): Handle tracepoint packets.
13527 (read_memory): New.
13528 (write_memory): New.
13529 (handle_search_memory_1): Use read_memory.
13530 (handle_query): Report support for conditional tracepoints, trace
13531 state variables, and tracepoint sources. Handle tracepoint
13533 (main): Initialize the tracepoints module.
13534 (process_serial_event): Handle traceframe reads/writes.
13536 * linux-low.c (handle_tracepoints): New.
13537 (linux_wait_1): Call it.
13538 (linux_resume_one_lwp): Handle while-stepping.
13539 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13540 (linux_target_ops): Install them.
13541 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13543 * linux-x86-low.c (x86_supports_tracepoints): New.
13544 (the_low_target). Install it.
13546 * mem-break.h (delete_breakpoint): Declare.
13547 * mem-break.c (delete_breakpoint): Make external.
13549 * target.h (struct target_ops): Add `supports_tracepoints',
13550 `read_pc', and `write_pc' fields.
13551 (target_supports_tracepoints): Define.
13552 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13555 * regcache.h (struct regcache) <registers_owned>: New field.
13556 (init_register_cache, regcache_cpy): Declare.
13557 (regcache_read_pc, regcache_write_pc): Declare.
13558 (register_cache_size): Declare.
13559 (supply_regblock): Declare.
13560 * regcache.c (init_register_cache): New.
13561 (new_register_cache): Use it.
13562 (regcache_cpy): New.
13563 (register_cache_size): New.
13564 (supply_regblock): New.
13565 (regcache_read_pc, regcache_write_pc): New.
13567 * tracepoint.c: New.
13569 * Makefile.in (OBS): Add tracepoint.o.
13570 (tracepoint.o): New rule.
13572 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13574 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13576 (i386-mmx.c): Likewise.
13577 (i386-mmx-linux.o): Likewise.
13578 (i386-mmx-linux.c): Likewise.
13580 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13581 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13582 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13583 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13585 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13586 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13587 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13589 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13591 * Makefile.in (clean): Updated.
13593 (i386-avx.c): Likewise.
13594 (i386-avx-linux.o): Likewise.
13595 (i386-avx-linux.c): Likewise.
13596 (amd64-avx.o): Likewise.
13597 (amd64-avx.c): Likewise.
13598 (amd64-avx-linux.o): Likewise.
13599 (amd64-avx-linux.c): Likewise.
13601 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13602 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13603 (srv_amd64_regobj): Add amd64-avx.o.
13604 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13605 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13606 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13607 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13608 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13609 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13610 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13612 * i387-fp.c: Include "i386-xstate.h".
13614 (i387_cache_to_xsave): Likewise.
13615 (i387_xsave_to_cache): Likewise.
13616 (x86_xcr0): Likewise.
13618 * i387-fp.h (i387_cache_to_xsave): Likewise.
13619 (i387_xsave_to_cache): Likewise.
13620 (x86_xcr0): Likewise.
13622 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13623 * linux-crisv32-low.c (target_regsets): Likewise.
13624 * linux-m68k-low.c (target_regsets): Likewise.
13625 * linux-mips-low.c (target_regsets): Likewise.
13626 * linux-ppc-low.c (target_regsets): Likewise.
13627 * linux-s390-low.c (target_regsets): Likewise.
13628 * linux-sh-low.c (target_regsets): Likewise.
13629 * linux-sparc-low.c (target_regsets): Likewise.
13630 * linux-xtensa-low.c (target_regsets): Likewise.
13632 * linux-low.c: Include <sys/uio.h>.
13633 (regsets_fetch_inferior_registers): Support nt_type.
13634 (regsets_store_inferior_registers): Likewise.
13635 (linux_process_qsupported): New.
13636 (linux_target_ops): Add linux_process_qsupported.
13638 * linux-low.h (regset_info): Add nt_type.
13639 (linux_target_ops): Add process_qsupported.
13641 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13643 (init_registers_i386_avx_linux): New.
13644 (init_registers_amd64_avx_linux): Likewise.
13645 (xmltarget_i386_linux_no_xml): Likewise.
13646 (xmltarget_amd64_linux_no_xml): Likewise.
13647 (PTRACE_GETREGSET): Likewise.
13648 (PTRACE_SETREGSET): Likewise.
13649 (x86_fill_xstateregset): Likewise.
13650 (x86_store_xstateregset): Likewise.
13651 (use_xml): Likewise.
13652 (x86_linux_update_xmltarget): Likewise.
13653 (x86_linux_process_qsupported): Likewise.
13654 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13655 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13656 init_registers_i386_linux here. Call
13657 x86_linux_update_xmltarget.
13658 (the_low_target): Add x86_linux_process_qsupported.
13660 * server.c (handle_query): Call target_process_qsupported.
13662 * target.h (target_ops): Add process_qsupported.
13663 (target_process_qsupported): New.
13665 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13667 * inferiors.c (add_thread): Set last_status kind to
13668 TARGET_WAITKIND_IGNORE.
13669 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13670 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13671 (linux_wait_1): Move `thread' local definition to block that uses
13672 it. Don't NULL initialize `event_child'.
13673 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13674 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13675 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13677 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13679 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13680 an extended waitstatus, or by a watchpoint.
13681 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13682 thread was stepping or has been stopped by a watchpoint.
13684 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13686 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13687 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13688 of another, then delete the previous, and validate all
13690 (validate_inserted_breakpoint): New.
13691 (delete_disabled_breakpoints): New.
13692 (validate_breakpoints): New.
13693 (check_mem_read): Validate breakpoints before trusting their
13694 shadow. Delete disabled breakpoints.
13695 (check_mem_write): Validate breakpoints before trusting they
13696 should be inserted. Delete disabled breakpoints.
13697 * mem-break.h (validate_breakpoints):
13698 * server.c (handle_query): Validate breakpoints when we see a
13701 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13703 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13704 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13705 if we could tell there's a GDB breakpoint at stop_pc.
13706 (need_step_over_p): Don't do a step over if we find a GDB
13707 breakpoint at the resume PC.
13709 * mem-break.c (struct raw_breakpoint): New.
13710 (enum bkpt_type): New type `gdb_breakpoint'.
13711 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13712 fields. New field `raw'.
13713 (find_raw_breakpoint_at): New.
13714 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13715 breakpoint instead.
13716 (set_breakpoint_at): Adjust.
13717 (delete_raw_breakpoint): New.
13718 (release_breakpoint): New.
13719 (delete_breakpoint): Rename to...
13720 (delete_breakpoint_1): ... this. Add proc parameter. Use
13721 release_breakpoint. Return ENOENT.
13722 (delete_breakpoint): Reimplement.
13723 (find_breakpoint_at): Delete.
13724 (find_gdb_breakpoint_at): New.
13725 (delete_breakpoint_at): Delete.
13726 (set_gdb_breakpoint_at): New.
13727 (delete_gdb_breakpoint_at): New.
13728 (gdb_breakpoint_here): New.
13729 (set_reinsert_breakpoint): Use release_breakpoint.
13730 (uninsert_breakpoint): Rename to ...
13731 (uninsert_raw_breakpoint): ... this.
13732 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13733 (reinsert_raw_breakpoint): Change parameter type to
13735 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13737 (check_breakpoints): Adjust. Use release_breakpoint.
13738 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13739 (breakpoint_inserted_here): Ditto.
13740 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13741 Don't trust the breakpoint's shadow if it is not inserted.
13742 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13743 (delete_all_breakpoints): Adjust.
13744 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13745 use delete_breakpoint_1.
13747 * mem-break.h (breakpoints_supported): Delete declaration.
13748 (set_gdb_breakpoint_at): Declare.
13749 (gdb_breakpoint_here): Declare.
13750 (delete_breakpoint_at): Delete.
13751 (delete_gdb_breakpoint_at): Declare.
13753 * server.h (struct raw_breakpoint): Forward declare.
13754 (struct process_info): New field `raw_breakpoints'.
13756 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13759 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13761 * linux-low.c (status_pending_p_callback): Fix comment.
13762 (linux_wait_for_event_1): Move most of the internal breakpoint
13763 handling from here...
13764 (linux_wait_1): ... to here.
13765 (count_events_callback): New.
13766 (select_singlestep_lwp_callback): New.
13767 (select_event_lwp_callback): New.
13768 (cancel_breakpoints_callback): New.
13769 (select_event_lwp): New.
13770 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13771 priority to all LWPs that have had events that should be reported
13772 to the client. Cancel breakpoints when about to reporting the
13773 event to the client, not while stopping lwps. No longer cancel
13774 finished single-steps here.
13775 (cancel_finished_single_step): Delete.
13776 (cancel_finished_single_steps): Delete.
13778 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13780 * mem-break.c (enum bkpt_type): New.
13781 (struct breakpoint): New field `type'.
13782 (set_breakpoint_at): Change return type to struct breakpoint
13783 pointer. Set type to `other_breakpoint' by default.
13784 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13785 in the breakpoint list.
13786 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13787 (reinsert_breakpoint): Rename to ...
13788 (reinsert_raw_breakpoint): ... this.
13789 (reinsert_breakpoints_at): Adjust.
13790 * mem-break.h (struct breakpoint): Declare.
13791 (set_breakpoint_at): Change return type to struct breakpoint
13794 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13796 * server.c (handle_query): Assign, not compare.
13798 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13800 Teach linux gdbserver to step-over-breakpoints.
13802 * linux-low.c (can_hardware_single_step): New.
13803 (supports_breakpoints): New.
13804 (handle_extended_wait): If stopping threads, read the stop pc of
13805 the new cloned LWP.
13807 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13808 low target doesn't support retrieving the PC.
13809 (add_lwp): Set last_resume_kind to resume_continue.
13810 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13811 (linux_attach): Don't clear stop_expected. Set the lwp's
13812 last_resume_kind to resume_stop.
13813 (linux_detach_one_lwp): Don't check for removed breakpoints.
13814 (check_removed_breakpoint): Delete.
13815 (status_pending_p): Rename to ...
13816 (status_pending_p_callback): ... this. Don't check for removed
13817 breakpoints. Don't consider threads that are stopped from GDB's
13819 (linux_wait_for_lwp): Always read the stop_pc here.
13820 (cancel_breakpoint): New.
13821 (step_over_bkpt): New global.
13822 (linux_wait_for_event_1): Implement stepping over breakpoints.
13823 (gdb_wants_lwp_stopped): New.
13824 (gdb_wants_all_stopped): New.
13825 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13826 single-step traps here. Store the thread's last reported target
13828 (send_sigstop): Don't clear stop_expected. Always set it,
13830 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13831 (cancel_finished_single_step): New.
13832 (cancel_finished_single_steps): New.
13833 (wait_for_sigstop): Don't cancel finished single-step traps here.
13834 (linux_resume_one_lwp): Don't check for removed breakpoints.
13835 Don't set `step' on non-hardware step archs.
13836 (linux_set_resume_request): Ignore resume_stop requests if already
13837 stopping or stopped. Set the lwp's last_resume_kind.
13838 (resume_status_pending_p): Don't check for removed breakpoints.
13839 (need_step_over_p): New.
13840 (start_step_over): New.
13841 (finish_step_over): New.
13842 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13843 requests. Clear the thread's last reported target waitstatus.
13844 Don't use the `suspended' flag. Don't consider pending breakpoints.
13845 (linux_resume): Start a step-over if necessary.
13846 (proceed_one_lwp): New.
13847 (proceed_all_lwps): New.
13848 (unstop_all_lwps): New.
13849 * linux-low.h (struct lwp_info): Rewrite comment for the
13850 `suspended' flag. Add the `stop_pc' field. Delete the
13851 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13852 Add `'last_resume_kind' and `need_step_over' fields.
13853 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13854 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13855 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13856 (set_raw_breakpoint_at): New.
13857 (set_breakpoint_at): Rewrite to use it.
13858 (reinsert_breakpoint_handler): Delete.
13859 (set_reinsert_breakpoint): New.
13860 (reinsert_breakpoint_by_bp): Delete.
13861 (delete_reinsert_breakpoints): New.
13862 (uninsert_breakpoint): Rewrite.
13863 (uninsert_breakpoints_at): New.
13864 (reinsert_breakpoint): Rewrite.
13865 (reinsert_breakpoints_at): New.
13866 (check_breakpoints): Rewrite.
13867 (breakpoint_here): New.
13868 (breakpoint_inserted_here): New.
13869 (check_mem_read): Adjust.
13870 * mem-break.h (breakpoints_supported, breakpoint_here)
13871 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13872 (reinsert_breakpoint_by_bp): Delete declaration.
13873 (delete_reinsert_breakpoints): Declare.
13874 (reinsert_breakpoint): Delete declaration.
13875 (reinsert_breakpoints_at): Declare.
13876 (uninsert_breakpoint): Delete declaration.
13877 (uninsert_breakpoints_at): Declare.
13878 (check_breakpoints): Adjust prototype.
13879 * server.h: Adjust include order.
13880 (struct thread_info): Declare here. Add a `last_status' field.
13882 2010-03-23 Michael Snyder <msnyder@vmware.com>
13884 * server.c (crc32): New function.
13885 (handle_query): Add handling for 'qCRC:' request.
13887 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13889 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13890 lwp had been stopped by a watchpoint.
13892 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13894 * server.h (internal_error): Declare.
13895 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13896 * utils.c (internal_error): New function.
13898 2010-03-15 Andreas Schwab <schwab@redhat.com>
13900 * configure.srv: Fix typo setting srv_regobj.
13902 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13904 * linux-low.c (fetch_register): Avoid passing a non string literal
13906 (usr_store_inferior_registers): Ditto.
13908 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13910 * linux-low.c (linux_write_memory): Bail out early if peeking
13913 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13915 * linux-low.h (struct lwp_info): New fields
13916 `stopped_by_watchpoint' and `stopped_data_address'.
13917 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13918 here, and cache them in the lwp object.
13919 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13921 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13923 (linux_stopped_by_watchpoint): Rewrite.
13924 (linux_stopped_data_address): Rewrite.
13926 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13928 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13929 switching the current inferior, not before.
13931 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13933 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13934 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13935 i386-linux.c and amd64-linux.c.
13936 (reg-i386.o): Removed.
13937 (reg-i386.c): Likewise.
13938 (reg-i386-linux.o): Likewise.
13939 (reg-i386-linux.c): Likewise.
13940 (reg-x86-64.o): Likewise.
13941 (reg-x86-64.c): Likewise.
13942 (reg-x86-64-linux.o): Likewise.
13943 (reg-x86-64-linux.c): Likewise.
13945 (i386.c): Likewise.
13946 (i386-linux.o): Likewise.
13947 (i386-linux.c): Likewise.
13948 (amd64.o): Likewise.
13949 (amd64.c): Likewise.
13950 (amd64-linux.o): Likewise.
13951 (amd64-linux.c): Likewise.
13953 * configure.srv (srv_i386_regobj): New.
13954 (srv_i386_linux_regobj): Likewise.
13955 (srv_amd64_regobj): Likewise.
13956 (srv_amd64_linux_regobj): Likewise.
13957 (srv_i386_32bit_xmlfiles): Likewise.
13958 (srv_i386_64bit_xmlfiles): Likewise.
13959 (srv_i386_xmlfiles): Likewise.
13960 (srv_amd64_xmlfiles): Likewise.
13961 (srv_i386_linux_xmlfiles): Likewise.
13962 (srv_amd64_linux_xmlfiles): Likewise.
13963 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13964 srv_xmlfiles to $srv_i386_xmlfiles.
13965 (i[34567]86-*-mingw32ce*): Likewise.
13966 (i[34567]86-*-mingw*): Likewise.
13967 (i[34567]86-*-nto*): Likewise.
13968 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13969 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13970 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13971 (x86_64-*-linux*): Likewise.
13973 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13974 (init_registers_amd64_linux): New.
13975 (x86_arch_setup): Replace init_registers_x86_64_linux with
13976 init_registers_amd64_linux.
13978 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13980 * configure.ac: Check for libdl. If it is not available link against
13981 static libthread_db.
13982 * configure: Regenerate.
13984 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13988 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13989 handing a read watchpoint.
13990 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13992 2010-02-12 Doug Evans <dje@google.com>
13994 * linux-low.c (linux_supports_tracefork_flag): Document.
13995 (linux_look_up_symbols): Add comment.
13997 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13999 * regcache.c (supply_register): Clear regcache if buf is NULL.
14001 2010-02-02 Nicolas Roche <roche@sourceware.org>
14002 Joel Brobecker <brobecker@adacore.com>
14004 * inferiors.c (find_inferior): Add function documentation.
14005 (unloaded_dll): Handle the case where the unloaded dll has not
14006 been previously registered in the dll list.
14008 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
14010 * linux-arm-low.c (thumb_breakpoint_len): Delete.
14011 (thumb2_breakpoint): New.
14012 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
14014 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
14016 * linux-low.c (get_stop_pc): Check for SIGTRAP.
14017 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
14020 2010-01-21 Pedro Alves <pedro@codesourcery.com>
14022 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
14024 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
14026 * linux-s390-low.c (s390_collect_ptrace_register)
14027 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
14029 2010-01-21 Doug Evans <dje@google.com>
14031 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
14032 (PTRACE_ARG4_TYPE): New macro.
14033 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
14034 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
14035 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
14036 (usr_store_inferior_registers): Ditto.
14037 (linux_read_memory, linux_write_memory): Ditto.
14038 (linux_test_for_tracefork): Ditto.
14040 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
14041 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
14043 2010-01-21 Pedro Alves <pedro@codesourcery.com>
14045 * proc-service.c (ps_lgetregs): Don't refetch registers from the
14048 2010-01-21 Pedro Alves <pedro@codesourcery.com>
14050 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
14051 prototype to take a regcache. Adjust.
14053 2010-01-20 Pedro Alves <pedro@codesourcery.com>
14055 * regcache.h (struct thread_info): Forward declare.
14056 (struct regcache): New.
14057 (new_register_cache): Adjust prototype.
14058 (get_thread_regcache): Declare.
14059 (free_register_cache): Adjust prototype.
14060 (registers_to_string, registers_from_string): Ditto.
14061 (supply_register, supply_register_by_name, collect_register)
14062 (collect_register_as_string, collect_register_by_name): Ditto.
14063 * regcache.c (struct inferior_regcache_data): Delete.
14064 (get_regcache): Rename to ...
14065 (get_thread_regcache): ... this. Adjust. Switch inferior before
14066 fetching registers.
14067 (regcache_invalidate_one): Adjust.
14068 (regcache_invalidate): Fix prototype.
14069 (new_register_cache): Return the new register cache.
14070 (free_register_cache): Change prototype.
14071 (realloc_register_cache): Adjust.
14072 (registers_to_string): Change prototype to take a regcache. Adjust.
14073 (registers_from_string): Ditto.
14074 (register_data): Ditto.
14075 (supply_register): Ditto.
14076 (supply_register_by_name): Ditto.
14077 (collect_register): Ditto.
14078 (collect_register_as_string): Ditto.
14079 (collect_register_by_name): Ditto.
14080 * server.c (process_serial_event): Adjust.
14081 * linux-low.h (regset_fill_func, regset_store_func): Change
14083 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
14085 * linux-low.c (get_stop_pc): Adjust.
14086 (check_removed_breakpoint): Adjust.
14087 (linux_wait_for_event): Adjust.
14088 (linux_resume_one_lwp): Adjust.
14089 (fetch_register): Add regcache parameter. Adjust.
14090 (usr_store_inferior_registers): Ditto.
14091 (regsets_fetch_inferior_registers): Ditto.
14092 (regsets_store_inferior_registers): Ditto.
14093 (linux_fetch_registers, linux_store_registers): Ditto.
14094 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
14096 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
14098 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
14099 prototype to take a regcache.
14100 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
14101 * remote-utils.c (convert_ascii_to_int, outreg)
14102 (prepare_resume_reply): Change prototype to take a regcache.
14104 * target.h (struct target_ops) <fetch_registers, store_registers>:
14105 Change prototype to take a regcache.
14106 (fetch_inferior_registers, store_inferior_registers): Change
14107 prototype to take a regcache. Adjust.
14108 * proc-service.c (ps_lgetregs): Adjust.
14109 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
14110 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
14111 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
14112 take a regcache. Adjust.
14113 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
14114 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
14115 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
14116 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
14117 * linux-cris-low.c (cris_get_pc, cris_set_pc)
14118 (cris_cannot_fetch_register):
14119 (cris_breakpoint_at): Change prototype to take a regcache.
14121 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
14122 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
14123 to take a regcache. Adjust.
14124 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
14126 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
14127 take a regcache. Adjust.
14128 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
14129 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
14130 (m68k_set_pc): Change prototype to take a regcache. Adjust.
14131 * linux-mips-low.c (mips_get_pc):
14132 (mips_set_pc): Change prototype to take a regcache. Adjust.
14133 (mips_reinsert_addr): Adjust.
14134 (mips_collect_register): Change prototype to take a regcache.
14136 (mips_supply_register):
14137 (mips_collect_register_32bit, mips_supply_register_32bit)
14138 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
14139 (mips_store_fpregset): Ditto.
14140 * linux-ppc-low.c (ppc_supply_ptrace_register)
14141 (ppc_supply_ptrace_register): Ditto.
14142 (parse_spufs_run): Adjust.
14143 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
14144 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
14145 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
14146 take a regcache. Adjust.
14147 * linux-s390-low.c (s390_collect_ptrace_register)
14148 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
14149 (s390_set_pc): Change prototype to take a regcache. Adjust.
14150 (s390_arch_setup): Adjust.
14151 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
14152 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
14153 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14154 (sparc_fill_gregset, sparc_store_gregset_from_stack)
14155 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
14157 (sparc_breakpoint_at): Adjust.
14158 * linux-xtensa-low.c (xtensa_fill_gregset):
14159 (xtensa_store_gregset):
14160 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
14161 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
14162 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
14163 prototype to take a regcache. Adjust.
14164 * win32-arm-low.c (arm_fetch_inferior_register)
14165 (arm_store_inferior_register): Change prototype to take a
14167 * win32-i386-low.c (i386_fetch_inferior_register)
14168 (i386_store_inferior_register): Change prototype to take a
14170 * win32-low.c (child_fetch_inferior_registers)
14171 (child_store_inferior_registers): Change prototype to take a
14173 (win32_wait): Adjust.
14174 (win32_fetch_inferior_registers): Change prototype to take a
14176 (win32_store_inferior_registers): Adjust.
14177 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
14178 store_inferior_register>: Change prototype to take a regcache.
14180 2010-01-20 Doug Evans <dje@google.com>
14182 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
14184 (linux_wait_for_event1, linux_init_signals): Ditto.
14185 (W_STOPCODE): Provide definition if missing.
14187 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
14189 * linux-low.c (linux_core_of_thread): New.
14190 (compare_ints, show_process, list_threads): New.
14191 (linux_qxfer_osdata): Report threads and cores.
14192 (linux_target_op): Register linux_core_of_thread.
14193 * remote-utils.c (prepare_resume_reply): Report the core.
14194 (buffer_xml_printf): Support %d specifier.
14195 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
14197 (handle_query): Handle qXfer:threads. Announce availability
14199 * target.h (struct target_ops): New field core_of_thread.
14201 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
14203 * Makefile.in (clean): Remove new generated files.
14204 (reg-s390.o, reg-s390.c): Remove rules.
14205 (reg-s390x.o, reg-s390x.c): Likewise.
14206 (s390-linux32.o, s390-linux32.c): Add rules.
14207 (s390-linux64.o, s390-linux64.c): Likewise.
14208 (s390x-linux64.o, s390x-linux64.c): Likewise.
14209 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
14210 * linux-s390-low.c: Include <elf.h>.
14211 (HWCAP_S390_HIGH_GPRS): Define if undefined.
14212 (init_registers_s390): Remove prototype.
14213 (init_registers_s390x): Likewise.
14214 (init_registers_s390_linux32): Add prototype.
14215 (init_registers_s390_linux64): Likewise.
14216 (init_registers_s390x_linux64): Likewise.
14217 (s390_num_regs_3264): New define.
14218 (s390_regmap_3264): New global variable.
14219 (s390_cannot_fetch_register): Remove obsolete check.
14220 (s390_cannot_store_register): Likewise.
14221 (s390_collect_ptrace_register): Handle upper/lower register halves.
14222 (s390_supply_ptrace_register): Likewise.
14223 (s390_fill_gregset): Update to register number changes.
14224 (s390_get_hwcap): New routine.
14225 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
14226 Install appropriate regmap and register set.
14228 2010-01-01 Joel Brobecker <brobecker@adacore.com>
14230 * server.c (gdbserver_version): Update copyright year to 2010.
14231 * gdbreplay.c (gdbreplay_version): Likewise.
14233 2009-12-28 Doug Evans <dje@google.com>
14235 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
14236 elf/external.h. Include <elf.h> instead but only if necessary.
14238 2009-12-28 Pedro Alves <pedro@codesourcery.com>
14240 * linux-low.c (linux_remove_process): Remove `detaching'
14241 parameter. Don't release/detach from thread_db here.
14242 (linux_kill): Release/detach from thread_db here, ...
14243 (linux_detach): ... and here, before actually detaching.
14244 (linux_wait_1): ... and here, when a process exits.
14245 * thread-db.c (any_thread_of): New.
14246 (thread_db_free): Switch the current inferior to a thread of the
14249 2009-12-21 Doug Evans <dje@google.com>
14251 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14253 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14254 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14255 warning ifndef __NR_tkill. Move setting of errno there too.
14256 Delete unnecessary resetting of errno after syscall.
14257 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14259 * configure.ac: Check for dladdr.
14260 * config.in: Regenerate.
14261 * configure: Regenerate.
14262 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14263 (try_thread_db_load): Update.
14265 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14267 2009-12-18 Doug Evans <dje@google.com>
14269 * event-loop.c: Include unistd.h if it exists.
14271 * linux-low.c (my_waitpid): Move definition away from being in
14272 between linux_tracefork_child/linux_test_for_tracefork.
14274 * gdb_proc_service.h (psaddr_t): Fix type.
14275 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14276 signature to match glibc.
14278 2009-12-16 Doug Evans <dje@google.com>
14280 * linux-low.c (linux_read_memory): Fix argument to read.
14282 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14284 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14285 events, don't leave current_inferior pointing at null.
14287 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14289 * win32-low.c (LOG): Delete.
14290 (OUTMSG): Output to stderr.
14291 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14292 on compile time LOG macro.
14293 (win32_wait): Fix debug output.
14295 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14297 * win32-low.c (win32_add_one_solib): If the dll name is
14298 "ntdll.dll", prepend the system directory to the dll path.
14300 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14302 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14304 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
14305 Vladimir Prus <vladimir@codesourcery.com>
14307 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14308 * configure.ac: Check for __mcoldfire__ and set
14309 gdb_cv_m68k_is_coldfire.
14310 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14311 reg-cf.o and reg-m68k.o.
14312 * configure: Regenerated.
14314 2009-11-16 Pedro Alves <pedro@codesourcery.com>
14316 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14317 Pass it to thread_db_free.
14318 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14319 proper `detaching' argument to linux_remove_process.
14320 * linux-low.h (thread_db_free): Add `detaching' parameter.
14321 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14323 (thread_db_free): Add `detaching' parameter. Only
14324 call td_ta_clear_event if detaching from process.
14326 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14328 * thread-db.c (thread_db_free): Fix typo.
14330 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14333 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14335 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14337 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14338 with an i686 compiler.
14339 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14341 * configure: Rebuilt.
14343 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14347 * server.c (handle_search_memory_1): Correct read_addr initialization
14348 in loop for searching subsequent chunks.
14350 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14352 * configure.ac: New --with-libthread-db option.
14353 * thread-db.c: Allow direct dependence on libthread_db.
14354 (thread_db_free): Adjust.
14355 * config.in: Regenerate.
14356 * configure: Likewise.
14358 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14361 * thread-db.c (attach_thread): New function.
14362 (maybe_attach_thread): Return success/failure.
14363 (find_new_threads_callback): Adjust.
14364 (thread_db_find_new_threads): Loop until no new threads.
14366 2009-10-13 Pedro Alves <pedro@codesourcery.com>
14368 * proc-service.c (ps_lgetregs): Formatting.
14370 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14372 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14373 * configure.ac: Adjust.
14374 * linux-low.h (struct process_info_private): Move members to struct
14376 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14377 * linux-low.c (linux_remove_process): Adjust.
14378 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14379 * server.c (handle_query): Move code ...
14380 (handle_monitor_command): ... here. New function.
14381 * target.h (struct target_ops): New member.
14382 * thread-db.c (struct thread_db): New.
14383 (libthread_db_search_path): New variable.
14384 (thread_db_create_event, thread_db_enable_reporting)
14385 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14386 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14387 (try_thread_db_load_1, dladdr_to_soname): New functions.
14388 (try_thread_db_load, thread_db_load_search): New functions.
14389 (thread_db_init): Search for libthread_db.
14390 (thread_db_free): New function.
14391 (thread_db_handle_monitor_command): Likewise.
14392 * config.in: Regenerate.
14393 * configure: Regenerate.
14395 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14397 * spu-low.c (spu_kill): Wait for inferior to terminate.
14398 Call clear_inferiors.
14399 (spu_detach): Call clear_inferiors.
14401 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14403 * aclocal.m4: Regenerate.
14404 * config.in: Likewise.
14405 * configure: Likewise.
14407 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14409 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14410 (parse_spufs_run): New function.
14411 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14412 (ppc_breakpoint_at): Handle SPU breakpoints.
14414 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14416 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14417 (SPUFS_MAGIC): Define.
14418 (spu_enumerate_spu_ids): New function.
14419 (linux_qxfer_spu): New function.
14420 (linux_target_ops): Install linux_qxfer_spu.
14422 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14424 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14425 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14426 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14427 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14428 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14429 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14430 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14431 (init_registers_powerpc_cell32l): Add prototype.
14432 (init_registers_powerpc_cell64l): Likewise.
14433 (ppc_arch_setup): Detect Cell/B.E. architecture.
14435 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14437 * Makefile.in (datarootdir): New variable.
14439 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14441 * linux-low.c (linux_write_memory): Update debugging output.
14442 * Makefile.in (clean): Add new descriptions.
14443 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14444 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14445 * configure.srv: Add new files for arm*-*-linux*.
14446 * linux-arm-low.c: Add new declarations.
14447 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14448 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14449 (HWCAP_VFPv3D16): New.
14450 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14451 instead of __IWMMXT__.
14452 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14453 (arm_arch_setup): New.
14454 (target_regsets): Remove #ifdef. Add VFP regset.
14455 (the_low_target): Use arm_arch_setup.
14457 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14459 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14460 the main thread again.
14462 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14464 Adding Neutrino gdbserver.
14465 * configure: Regenerated.
14466 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14467 * configure.srv (i[34567]86-*-nto*): New target.
14468 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14469 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14470 (nto_comctrl) [__QNX__]: New function.
14471 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14473 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
14475 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14478 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14479 Pedro Alves <pedro@codesourcery.com>
14481 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14482 don't support CONTEXT_EXTENDED_REGISTERS.
14483 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14484 (the_low_target): Install them.
14485 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14486 failing with ERROR_PIPE_NOT_CONNECTED.
14488 2009-06-30 Doug Evans <dje@google.com>
14489 Pierre Muller <muller@ics.u-strasbg.fr>
14491 Add h/w watchpoint support to x86-linux, win32-i386.
14492 * Makefile.in (SFILES): Add i386-low.c
14493 (i386_low_h): Define.
14494 (i386-low.o): Add dependencies.
14495 (linux-x86-low.o): Add i386-low.h dependency.
14496 (win32-i386-low.o): Ditto.
14497 * i386-low.c: New file.
14498 * i386-low.h: New file.
14499 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14500 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14501 * linux-low.c (linux_add_process): Initialize arch_private.
14502 (linux_remove_process): Free arch_private.
14503 (add_lwp): Initialize arch_private.
14504 (delete_lwp): Free arch_private.
14505 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14507 * linux-low.h (process_info_private): New member arch_private.
14508 (lwp_info): New member arch_private.
14509 (linux_target_ops): New members new_process, new_thread,
14511 (ptid_of): New macro.
14512 * linux-x86-low.c: Include stddef.h, i386-low.h.
14513 (arch_process_info): New struct.
14514 (arch_lwp_info): New struct.
14515 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14516 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14517 (i386_dr_low_get_status): New function.
14518 (x86_insert_point, x86_remove_point): New functions.
14519 (x86_stopped_by_watchpoint): New function.
14520 (x86_stopped_data_address): New function.
14521 (x86_linux_new_process, x86_linux_new_thread): New functions.
14522 (x86_linux_prepare_to_resume): New function.
14523 (the_low_target): Add entries for insert_point, remove_point,
14524 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14526 * server.c (debug_hw_points): New global.
14527 (monitor_show_help): Document set debug-hw-points.
14528 (handle_query): Process "set debug-hw-points".
14529 * server.h (debug_hw_points): Declare.
14530 (paddress): Declare.
14531 * utils.c (NUMCELLS, CELLSIZE): New macros.
14532 (get_sell, xsnprintf, paddress): New functions.
14533 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14534 remove_point, stopped_by_watchpoint, stopped_data_address.
14535 * win32-i386-low.c: Include i386-low.h.
14536 (debug_reg_state): Replaces dr.
14537 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14538 (i386_dr_low_get_status): New function.
14539 (i386_insert_point, i386_remove_point): New functions.
14540 (i386_stopped_by_watchpoint): New function.
14541 (i386_stopped_data_address): New function.
14542 (i386_initial_stuff): Update.
14543 (get_thread_context,set_thread_context,i386_thread_added): Update.
14544 (the_low_target): Add entries for insert_point,
14545 remove_point, stopped_by_watchpoint, stopped_data_address.
14546 * win32-low.c (win32_insert_watchpoint): New function.
14547 (win32_remove_watchpoint): New function.
14548 (win32_stopped_by_watchpoint): New function.
14549 (win32_stopped_data_address): New function.
14550 (win32_target_ops): Add entries for insert_watchpoint,
14551 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14552 * win32-low.h (win32_target_ops): New members insert_point,
14553 remove_point, stopped_by_watchpoint, stopped_data_address.
14555 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14557 * server.c (process_serial_event): Re-return unsupported, not
14558 error, if the type isn't recognized. Re-allow supporting only
14559 insert or remove packets. Also call require_running for
14560 breakpoints. Add missing break statement to default case. Tidy.
14561 * target.h (struct target_ops): Rename insert_watchpoint to
14562 insert_point, and remove_watchpoint to remove_point.
14564 * linux-low.h (struct linux_target_ops): Likewise.
14565 * linux-low.c (linux_insert_watchpoint): Rename to ...
14566 (linux_insert_point): ... this. Adjust.
14567 (linux_remove_watchpoint): Rename to ...
14568 (linux_remove_point): ... this. Adjust.
14569 (linux_target_ops): Adjust.
14570 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14571 (cris_insert_point): ... this.
14572 (cris_remove_watchpoint): Rename to ...
14573 (cris_remove_point): ... this.
14574 (the_low_target): Adjust.
14576 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14578 * server.c (handle_v_kill): Pass signal_pid to
14579 kill_inferior if multi_process is zero.
14581 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14583 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14584 * target.h (target_ops): Comment for *_watchpoint to make it clear
14585 the functions can get types '0' and '1'.
14587 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14589 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14590 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14591 * regcache.c (get_regcache): Likewise.
14592 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14593 * win32-low.c (child_fetch_inferior_registers): Remove check for
14596 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14597 Pedro Alves <pedro@codesourcery.com>
14599 * target.h (struct target_ops) <supports_multi_process>: New
14601 (target_supports_multi_process): New.
14602 * server.c (handle_query): Even if GDB reports support, only
14603 enable multi-process if the target also supports it. Report
14604 multi-process support only if the target backend supports it.
14605 * linux-low.c (linux_supports_multi_process): New function.
14606 (linux_target_ops): Install it as target_supports_multi_process
14609 2009-05-24 Doug Evans <dje@google.com>
14611 Global renaming of find_thread_pid to find_thread_ptid.
14612 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14613 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14614 All callers updated.
14616 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14617 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14620 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14621 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14622 (linux_resume_one_lwp): Ditto.
14624 2009-05-23 Doug Evans <dje@google.com>
14626 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14627 from struct inferior_list_entry * to struct lwp_info *.
14628 All callers updated.
14630 2009-05-13 Doug Evans <dje@google.com>
14632 * linux-x86-low.c: Don't include assert.h.
14633 (x86_siginfo_fixup): Use fatal, not assert.
14634 (x86_arch_setup): Fix comment.
14636 2009-05-12 Doug Evans <dje@google.com>
14638 Biarch support for i386/amd64 gdbserver.
14639 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14640 Add linux-x86-low.c.
14641 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14642 (linux-x86-low.o): Add.
14643 * linux-x86-64-low.c: Delete.
14644 * linux-i386-low.c: Delete.
14645 * linux-x86-low.c: New file.
14646 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14648 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14650 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14651 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14652 (linux_child_pid_to_exec_file): New function.
14653 (elf_64_header_p, elf_64_file_p): New functions.
14654 (siginfo_fixup): New function.
14655 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14656 give target a chance to convert layout.
14657 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14658 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14660 2009-05-07 Doug Evans <dje@google.com>
14662 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14663 (regsets_store_inferior_registers): Ditto.
14665 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14669 * linux-low.c (must_set_ptrace_flags): Delete.
14670 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14672 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14673 `lwp->must_set_ptrace_flags' instead.
14674 (linux_wait_for_event_1): Set ptrace options here.
14675 (linux_wait_1): ... not here.
14677 2009-04-30 Doug Evans <dje@google.com>
14679 * inferiors.c (started_inferior_callback): New function.
14680 (attached_inferior_callback): New function.
14681 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14682 * server.c (print_started_pid, print_attached_pid): New functions.
14683 (detach_or_kill_for_exit): New function.
14684 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14685 * server.h (have_started_inferiors_p): Declare.
14686 (have_attached_inferiors_p): Declare.
14688 * inferiors.c (remove_process): Fix memory leak, free process.
14689 * linux-low.c (linux_remove_process): New function.
14690 (linux_kill): Call it instead of remove_process.
14691 (linux_detach, linux_wait_1): Ditto.
14693 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14695 * configure.srv: Add x86 Windows CE target.
14697 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14699 * inferiors.c (get_thread_process): Make global.
14700 * server.h (get_thread_process): Add prototype.
14701 * thread-db.c (find_one_thread): Use get_thread_process
14702 instead of current_process.
14703 (thread_db_get_tls_address): Do not crash if called when
14704 thread layer is not yet initialized.
14706 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14708 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14709 * spu-low.c (current_tid): Rename to ...
14710 (current_ptid): ... this.
14711 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14712 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14713 ptid_get_lwp (current_ptid) instead of current_tid.
14714 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14715 instead of current_tid. Use find_process_pid to verify pid
14716 argument is valid. Pass proper argument to remove_process.
14717 (spu_thread_alive): Compare current_ptid instead of current_tid.
14718 (spu_resume): Likewise.
14720 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14722 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14725 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14727 Implement the multiprocess extensions, and add linux multiprocess
14730 * server.h (ULONGEST): Declare.
14731 (struct ptid, ptid_t): New.
14732 (minus_one_ptid, null_ptid): Declare.
14733 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14734 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14735 (struct inferior_list_entry): Change `id' type from unsigned from
14737 (struct sym_cache, struct breakpoint, struct
14738 process_info_private): Forward declare.
14739 (struct process_info): Declare.
14740 (current_process): Declare.
14741 (all_processes): Declare.
14742 (initialize_inferiors): Declare.
14743 (add_thread): Adjust to use ptid_t.
14744 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14745 (add_process, remove_process, find_thread_pid): Declare.
14746 (find_inferior_id): Adjust to use ptid_t.
14747 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14748 (multi_process): Declare.
14749 (push_event): Adjust to use ptid_t.
14750 (read_ptid, write_ptid): Declare.
14751 (prepare_resume_reply): Adjust to use ptid_t.
14752 (clear_symbol_cache): Declare.
14753 * inferiors.c (all_processes): New.
14754 (null_ptid, minus_one_ptid): New.
14755 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14756 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14757 (add_thread): Change unsigned long to ptid. Remove gdb_id
14759 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14760 (gdb_id_to_thread): Rename to ...
14761 (find_thread_pid): ... this. Change unsigned long to ptid.
14762 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14763 (loaded_dll, pull_pid_from_list): Adjust.
14764 (add_process, remove_process, find_process_pid)
14765 (get_thread_process, current_process, initialize_inferiors): New.
14766 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14767 (struct target_waitstatus) <related_pid>: Ditto.
14768 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14769 return type to int.
14770 (struct target_ops) <join>: Add `pid' argument.
14771 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14772 (struct target_ops) <wait>: Add `ptid' field. Change return type
14774 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14775 (mywait): Add `ptid' argument. Change return type to ptid_t.
14776 (target_pid_to_str): Declare.
14777 * target.c (set_desired_inferior): Adjust to use ptids.
14778 (mywait): Add new `ptid' argument. Adjust.
14779 (target_pid_to_str): New.
14780 * mem-break.h (free_all_breakpoints): Declare.
14781 * mem-break.c (breakpoints): Delelete.
14782 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14783 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14784 to use per-process breakpoint list.
14785 (free_all_breakpoints): New.
14786 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14787 (symbol_cache, all_symbols_looked_up): Delete.
14789 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14791 (prepare_resume_reply): Change ptid argument's type from unsigned
14792 long to ptid_t. Adjust. Implement W;process and X;process.
14793 (free_sym_cache, clear_symbol_cache): New.
14794 (look_up_one_symbol): Adjust to per-process symbol cache. *
14795 * server.c (cont_thread, general_thread, step_thread): Change type
14797 (attached): Delete.
14798 (multi_process): New.
14799 (last_ptid): Change type to ptid_t.
14800 (struct vstop_notif) <ptid>: Change type to ptid_t.
14801 (queue_stop_reply, push_event): Change `ptid' argument's type to
14803 (discard_queued_stop_replies): Add `pid' argument.
14804 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14805 changes. Don't reference the `attached' global.
14806 (attach_inferior): Adjust to mywait interface changes.
14807 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14808 features. Handle and report "multiprocess+". Handle
14810 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14812 (handle_v_kill): New.
14813 (handle_v_stopped): Adjust to use target_pid_to_str.
14814 (handle_v_requests): Allow multiple attaches and runs when
14815 multiprocess extensions are in effect. Handle "vKill".
14816 (myresume): Adjust to use ptids.
14817 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14818 (handle_status): Adjust to discard_queued_stop_replies interface
14820 (first_thread_of, kill_inferior_callback)
14821 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14822 (main): Call initialize_inferiors. Adjust to use ptids, killing
14823 and detaching from all inferiors. Handle multiprocess packet
14825 * linux-low.h: Include gdb_proc_service.h.
14826 (struct process_info_private): New.
14827 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14828 <lwpid_of>: Use ptid_get_lwp.
14829 (get_lwp_thread): Adjust.
14830 (struct lwp_info): Add `dead' member.
14831 (find_lwp_pid): Declare.
14832 * linux-low.c (thread_db_active): Delete.
14833 (new_inferior): Adjust comment.
14834 (inferior_pid): Delete.
14835 (linux_add_process): New.
14836 (handle_extended_wait): Adjust.
14837 (add_lwp): Change unsigned long to ptid.
14838 (linux_create_inferior): Add process to processes table. Adjust
14839 to use ptids. Don't set new_inferior here.
14840 (linux_attach_lwp): Rename to ...
14841 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14842 it. Adjust to use ptids.
14843 (linux_attach_lwp): New.
14844 (linux_attach): Add process to processes table. Don't set
14846 (struct counter): New.
14847 (second_thread_of_pid_p, last_thread_of_process_p): New.
14848 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14849 multiple processes.
14850 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14851 processes. Remove process from process table.
14852 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14853 to multiple processes.
14854 (any_thread_of): New.
14855 (linux_detach): Add `pid' argument, and handle it. Remove process
14856 from processes table.
14857 (linux_join): Add `pid' argument. Handle it.
14858 (linux_thread_alive): Change unsighed long argument to ptid_t.
14859 Consider dead lwps as not being alive.
14860 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14861 threads we're not interested in.
14862 (same_lwp, find_lwp_pid): New.
14863 (linux_wait_for_lwp): Change `pid' argument's type from int to
14865 (linux_wait_for_event): Rename to ...
14866 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14867 from int to ptid_t. Adjust.
14868 (linux_wait_for_event): New.
14869 (linux_wait_1): Add `ptid' argument. Change return type to
14870 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14871 that exit from the process table.
14872 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14874 (mark_lwp_dead): New.
14875 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14876 stopping all threads, mark its main lwp as dead.
14877 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14879 (fetch_register, usr_store_inferior_registers)
14880 (regsets_fetch_inferior_registers)
14881 (regsets_store_inferior_registers, linux_read_memory)
14882 (linux_write_memory): Inline `inferior_pid'.
14883 (linux_look_up_symbols): Adjust to use per-process
14884 `thread_db_active'.
14885 (linux_request_interrupt): Adjust to use ptids.
14886 (linux_read_auxv): Inline `inferior_pid'.
14887 (initialize_low): Don't reference thread_db_active.
14888 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14889 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14890 (ps_getpid): Return the pid of the current inferior.
14891 * thread-db.c (proc_handle, thread_agent): Delete.
14892 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14894 (find_one_thread): Change argument type to ptid_t. Adjust to
14896 (maybe_attach_thread): Adjust to per-process data and ptids.
14897 (thread_db_find_new_threads): Ditto.
14898 (thread_db_init): Ditto.
14899 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14900 processes table. Adjust to use ptids.
14901 (spu_kill, spu_detach): Adjust interface. Remove process from
14903 (spu_join, spu_thread_alive): Adjust interface.
14904 (spu_wait): Adjust interface. Remove process from processes
14905 table. Adjust to use ptids.
14906 * win32-low.c (current_inferior_tid): Delete.
14907 (current_inferior_ptid): New.
14908 (debug_event_ptid): New.
14909 (thread_rec): Take a ptid. Adjust.
14910 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14911 (child_delete_thread): Ditto.
14912 (do_initial_child_stuff): Add `attached' argument. Add process to
14914 (child_fetch_inferior_registers, child_store_inferior_registers):
14916 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14917 (win32_attach): Pass 1 to do_initial_child_stuff.
14918 (win32_kill): Adjust interface. Remove process from processes
14920 (win32_detach): Ditto.
14921 (win32_join): Adjust interface.
14922 (win32_thread_alive): Take a ptid.
14923 (win32_resume): Adjust to use ptids.
14924 (get_child_debug_event): Ditto.
14925 (win32_wait): Adjust interface. Remove exiting process from
14928 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14930 Non-stop mode support.
14932 * server.h (non_stop): Declare.
14933 (gdb_client_data, handler_func): Declare.
14934 (delete_file_handler, add_file_handler, start_event_loop):
14936 (handle_serial_event, handle_target_event, push_event)
14937 (putpkt_notif): Declare.
14938 * target.h (enum resume_kind): New.
14939 (struct thread_resume): Replace `step' field by `kind' field.
14940 (TARGET_WNOHANG): Define.
14941 (struct target_ops) <wait>: Add `options' argument.
14942 <supports_non_stop, async, start_non_stop>: New fields.
14943 (target_supports_non_stop, target_async): New.
14944 (start_non_stop): Declare.
14945 (mywait): Add `options' argument.
14946 * target.c (mywait): Add `options' argument. Print child exit
14947 notifications here.
14948 (start_non_stop): New.
14949 * server.c (non_stop, own_buf, mem_buf): New globals.
14950 (struct vstop_notif): New.
14951 (notif_queue): New global.
14952 (queue_stop_reply, push_event, discard_queued_stop_replies)
14953 (send_next_stop_reply): New.
14954 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14956 (attach_inferior): In non-stop mode, don't wait for the target
14958 (handle_general_set): Handle QNonStop.
14959 (handle_query): When handling qC, return the current general
14960 thread, instead of the first thread of the list.
14961 (handle_query): If the backend supports non-stop mode, include
14962 QNonStop+ in the qSupported query response.
14963 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14965 (handle_v_attach, handle_v_run): Handle non-stop mode.
14966 (handle_v_stopped): New.
14967 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14968 (myresume): Adjust to use resume_kind. Handle non-stop.
14969 (queue_stop_reply_callback): New.
14970 (handle_status): Handle non-stop mode.
14971 (main): Clear non_stop flag on reconnection. Use the event-loop.
14972 Refactor serial protocol handling from here ...
14973 (process_serial_event): ... to this new function. When GDB
14974 selects any thread, select one here. In non-stop mode, wait until
14975 GDB acks all pending events before exiting.
14976 (handle_serial_event, handle_target_event): New.
14977 * remote-utils.c (remote_open): Install remote_desc in the event
14979 (remote_close): Remove remote_desc from the event loop.
14980 (putpkt_binary): Rename to...
14981 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14982 (putpkt_binary): New as wrapper around putpkt_binary_1.
14983 (putpkt_notif): New.
14984 (prepare_resume_reply): In non-stop mode, don't change the
14986 * event-loop.c: New.
14987 * Makefile.in (OBJ): Add event-loop.o.
14988 (event-loop.o): New rule.
14990 * linux-low.h (pid_of): Moved here.
14992 (get_lwp_thread): Use lwpid_of.
14993 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14994 * linux-low.c (pid_of): Delete.
14995 (inferior_pid): Use lwpid_of.
14996 (linux_event_pipe): New.
14997 (target_is_async_p): New.
14999 (handle_extended_wait): Use lwpid_of.
15000 (add_lwp): Don't set lwpid field.
15001 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
15002 (linux_kill_one_lwp): If killing a running lwp, stop it first.
15003 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
15004 (linux_detach_one_lwp): If detaching from a running lwp, stop it
15005 first. Adjust to linux_wait_for_event interface changes. Use
15007 (linux_detach): Don't delete the main lwp here.
15008 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
15009 (status_pending_p): Don't consider explicitly suspended lwps.
15010 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
15011 pointer. Add OPTIONS argument. Change return type to int. Use
15012 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
15013 (linux_wait_for_event): Take an integer pid instead of a lwp_info
15014 pointer. Add status pointer argument. Return a pid instead of a
15015 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
15016 changes. In non-stop mode, don't switch to a random thread.
15017 (linux_wait): Rename to...
15018 (linux_wait_1): ... this. Add target_options argument, and handle
15019 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
15020 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
15021 clean exit and signal exit code. Don't stop all threads in
15022 non-stop mode. In all-stop mode, only stop all threads when
15023 reporting a stop to GDB. Handle explicit thread stop requests.
15024 (async_file_flush, async_file_mark): New.
15026 (send_sigstop): Use lwpid_of.
15027 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
15028 interface changes. In non-stop mode, don't switch to a random
15030 (linux_resume_one_lwp): Use lwpid_of.
15031 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
15032 (linux_resume_one_thread): ... this. Handle resume_stop. In
15033 non-stop mode, don't look for pending flag in all threads.
15034 (resume_status_pending_p): Don't consider explicitly suspended
15036 (my_waitpid): Reimplement. Emulate __WALL.
15037 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15039 (sigchld_handler, linux_supports_non_stop, linux_async)
15040 (linux_start_non_stop): New.
15041 (linux_target_ops): Register linux_supports_non_stop, linux_async
15042 and linux_start_non_stop.
15043 (initialize_low): Install SIGCHLD handler.
15044 * thread-db.c (thread_db_create_event, find_one_thread)
15045 (thread_db_get_tls_address): Use lwpid_of.
15046 * win32-low.c (win32_detach): Adjust to use resume_kind.
15047 (win32_wait): Add `options' argument.
15048 * spu-low.c (spu_resume): Adjust to use resume_kind.
15049 (spu_wait): Add `options' argument.
15051 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15053 Decouple target code from remote protocol.
15055 * target.h (enum target_waitkind): New.
15056 (struct target_waitstatus): New.
15057 (struct target_ops) <wait>: Return an unsigned long. Take a
15058 target_waitstatus pointer instead of a char pointer.
15059 (mywait): Likewise.
15060 * target.c (mywait): Change prototype to return an unsigned long.
15061 Take a target_waitstatus pointer instead of a char pointer. Adjust.
15062 * server.h (thread_from_wait, old_thread_from_wait): Delete
15064 (prepare_resume_reply): Change prototype to take a
15066 * server.c (thread_from_wait, old_thread_from_wait): Delete.
15067 (last_status, last_ptid): New.
15068 (start_inferior): Remove "statusptr" argument. Adjust. Return a
15069 pid instead of a signal.
15070 (attach_inferior): Remove "status" and "signal" parameters.
15072 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
15074 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
15075 (handle_v_requests, myresume): Remove "status" and "signal"
15076 parameters. Adjust.
15077 (handle_status): New.
15078 (main): Delete local `status'. Adjust.
15079 * remote-utils.c: Include target.h.
15080 (prepare_resume_reply): Change prototype to take a
15081 target_waitstatus. Adjust.
15083 * linux-low.c (linux_wait): Adjust to new target_ops->wait
15085 * spu-low.c (spu_wait): Adjust.
15086 * win32-low.c (enum target_waitkind, struct target_waitstatus):
15088 (win32_wait): Adjust.
15090 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15092 * target.h (struct thread_resume): Delete leave_stopped member.
15093 (struct target_ops): Add a `n' argument to the `resume' callback.
15094 * server.c (start_inferior): Adjust.
15095 (handle_v_cont, myresume): Adjust.
15096 * linux-low.c (check_removed_breakpoint): Adjust to resume
15097 interface change, and to removed leave_stopped field.
15098 (resume_ptr): Delete.
15099 (struct thread_resume_array): New.
15100 (linux_set_resume_request): Add new `arg' parameter. Adjust to
15101 resume interface change.
15102 (linux_continue_one_thread, linux_queue_one_thread)
15103 (resume_status_pending_p): Check if the resume field is NULL
15104 instead of checking the leave_stopped member.
15105 (linux_resume): Adjust to the target resume interface change.
15106 * spu-low.c (spu_resume): Adjust to the target resume interface
15108 * win32-low.c (win32_detach, win32_resume): Ditto.
15110 2009-04-01 Pedro Alves <pedro@codesourcery.com>
15112 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
15114 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
15116 (linux_continue_one_thread): Only preserve the stepping flag if
15117 there's a pending breakpoint.
15119 2009-03-31 Pedro Alves <pedro@codesourcery.com>
15121 * server.c (main): After the inferior having exited, call
15122 remote_close before exiting gdbserver.
15124 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
15126 Fix size of FPSCR in Power 7 processors.
15127 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
15128 (PPC_FEATURE_HAS_DFP): New #define.
15129 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
15132 2009-03-23 Pedro Alves <pedro@codesourcery.com>
15134 * server.c (handle_query) Whitespace and formatting.
15136 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15138 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
15139 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
15140 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
15141 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
15142 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
15143 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
15144 Makefile.in, configure.ac: Fix whitespace throughout.
15145 * configure: Regenerate.
15147 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15149 * inferiors.c (find_inferior): Make it safe for the callback
15150 function to delete the currently iterated inferior.
15152 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15154 * Makefile.in (linuw_low_h): Move higher.
15155 (thread-db.o): Depend on $(linux_low_h).
15157 2009-03-17 Pedro Alves <pedro@codesourcery.com>
15159 Rename "process" to "lwp" throughout.
15161 * linux-low.c (all_processes): Rename to...
15162 (all_lwps): ... this.
15163 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
15164 (add_process): Rename to ...
15165 (add_lwp): ... this. Adjust.
15166 (linux_create_inferior): Adjust.
15167 (linux_attach_lwp): Adjust.
15168 (linux_attach): Adjust.
15169 (linux_kill_one_process): Rename to ...
15170 (linux_kill_one_lwp): ... this. Adjust.
15171 (linux_kill): Adjust.
15172 (linux_detach_one_process): Rename to ...
15173 (linux_detach_one_lwp): ... this. Adjust.
15174 (linux_detach): Adjust.
15175 (check_removed_breakpoint): Adjust.
15176 (status_pending_p): Adjust.
15177 (linux_wait_for_process): Rename to ...
15178 (linux_wait_for_lwp): ... this. Adjust.
15179 (linux_wait_for_event): Adjust.
15180 (send_sigstop): Adjust.
15181 (wait_for_sigstop): Adjust.
15182 (stop_all_processes): Rename to ...
15183 (stop_all_lwps): ... this.
15184 (linux_resume_one_process): Rename to ...
15185 (linux_resume_one_lwp): ... this. Adjust.
15186 (linux_set_resume_request, linux_continue_one_thread)
15187 (linux_queue_one_thread, resume_status_pending_p)
15188 (usr_store_inferior_registers, regsets_store_inferior_registers)
15189 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15191 * linux-low.h (get_process): Rename to ...
15192 (get_lwp): ... this. Adjust.
15193 (get_thread_process): Rename to ...
15194 (get_thread_lwp): ... this. Adjust.
15195 (get_process_thread): Rename to ...
15196 (get_lwp_thread): ... this. Adjust.
15197 (struct process_info): Rename to ...
15198 (struct lwp_info): ... this.
15199 (all_processes): Rename to ...
15200 (all_lwps): ... this.
15201 * proc-service.c (ps_lgetregs): Adjust.
15202 * thread-db.c (thread_db_create_event, find_one_thread)
15203 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
15205 2009-03-14 Pedro Alves <pedro@codesourcery.com>
15207 * server.c (handle_query): Handle "qAttached".
15209 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
15211 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
15212 GPLv3, update license URL.
15214 2009-03-01 Doug Evans <dje@google.com>
15216 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
15217 (server_h): Add gdb_signals.h.
15218 (signals.o): Update.
15219 * server.h (target_signal_from_host,target_signal_to_host_p)
15220 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
15222 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
15224 * remote-utils.c (getpkt): Also generate remote-debug
15225 information if noack_mode is set.
15227 2009-02-06 Pedro Alves <pedro@codesourcery.com>
15229 * server.c (handle_query): Report qXfer:siginfo:read and
15230 qXfer:siginfo:write as supported and handle them.
15231 * target.h (struct target_ops) <qxfer_siginfo>: New field.
15232 * linux-low.c (linux_xfer_siginfo): New.
15233 (linux_target_ops): Set it.
15235 2009-01-26 Pedro Alves <pedro@codesourcery.com>
15237 * server.c (gdbserver_usage): Mention --remote-debug.
15238 (main): Accept '--remote-debug' switch.
15240 2009-01-18 Doug Evans <dje@google.com>
15242 * regcache.c (new_register_cache): No need to check result of xcalloc.
15243 * server.c (handle_search_memory): Back out calls to xmalloc,
15244 result is checked and error is returned to user upon failure.
15245 (handle_query): Ditto. Add more checks for result of malloc.
15246 (handle_v_cont): Check result of malloc, report error back to
15248 (handle_v_run): Ditto. Call freeargv.
15249 * server.h (freeargv): Declare.
15250 * utils.c (freeargv): New fn.
15252 2009-01-15 Doug Evans <dje@google.com>
15254 * gdbreplay.c (perror_with_name): Make arg const char *.
15255 * server.h (target_signal_to_name): Make return type const char *.
15256 * thread-db.c (thread_db_err_str): Make return type const char *.
15257 * utils.c (perror_with_name): Make arg const char *.
15259 2009-01-14 Pedro Alves <pedro@codesourcery.com>
15261 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15262 when handling a EXIT_PROCESS_DEBUG_EVENT.
15264 2009-01-06 Joel Brobecker <brobecker@adacore.com>
15266 * gdbreplay.c (gdbreplay_version): Update copyright year.
15267 * server.c (gdbserver_version): Likewise.
15269 2009-01-05 Doug Evans <dje@google.com>
15271 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
15272 (handle_extended_wait): Improve comment.
15274 2008-12-13 Doug Evans <dje@google.com>
15276 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15277 * server.h (ATTR_MALLOC): New macro.
15278 (xmalloc,xcalloc,xstrdup): Declare.
15279 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15280 * inferiors.c: Ditto.
15281 * linux-low.c: Ditto.
15282 * mem-break.c: Ditto.
15283 * regcache.c: Ditto.
15284 * remote-utils.c: Ditto.
15287 * win32-low.c: Ditto.
15289 2008-12-12 Doug Evans <dje@google.com>
15291 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15292 in debugging printf.
15294 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15296 2008-12-09 Doug Evans <dje@google.com>
15298 * linux-low.h (struct process_info): Delete member tid, unused.
15299 * thread-db.c (find_one_thread): Update.
15300 (maybe_attach_thread): Update.
15302 2008-12-02 Pedro Alves <pedro@codesourcery.com>
15304 * target.h (struct target_ops): Add qxfer_osdata member.
15305 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15307 (linux_qxfer_osdata): New functions.
15308 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15310 * server.c (handle_query): Handle "qXfer:osdata:read:".
15311 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15312 (buffer_xml_printf): New functions.
15313 * server.h (struct buffer): New.
15314 (buffer_grow_str, buffer_grow_str0): New macros.
15315 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15316 (buffer_xml_printf): Declare.
15318 2008-11-24 Doug Evans <dje@google.com>
15320 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15322 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15324 * server.c (handle_v_run): Always use the supplied argument list.
15326 2008-11-19 Bob Wilson <bob.wilson@acm.org>
15328 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15329 (xtensa_regmap_table): Add entry for scompare1.
15331 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15333 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15334 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15335 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15336 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15337 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15338 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15339 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15340 XML target descriptions.
15341 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15342 when inferior is running on an ISA 2.05 or later processor. Add
15343 special case to return offset for full 64-bit slot of FPSCR when
15346 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15348 * Makefile.in (SFILES, clean): Added sparc64 files.
15349 (reg-sparc64.o, reg-sparc64.c): New.
15350 * configure.srv (sparc*-*-linux*): New configuration.
15351 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15352 syscall arguments for SPARC.
15353 (regsets_store_inferior_registers): Likewise.
15354 * linux-sparc-low.c: New file.
15356 2008-10-21 Doug Evans <dje@google.com>
15358 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15359 (READLINE_DIR,READLINE_DEP): Delete.
15360 (INTERNAL_CFLAGS): Update.
15361 (LINTFLAGS): Update.
15363 2008-10-10 Pedro Alves <pedro@codesourcery.com>
15365 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15366 whole argv from the last run, not just argv[0].
15368 2008-09-08 Pedro Alves <pedro@codesourcery.com>
15370 * regcache.c (new_register_cache): Return NULL if the register
15371 cache size isn't known yet.
15372 (free_register_cache): Avoid dereferencing a NULL regcache.
15374 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15376 * configure.srv: Merge MIPS and MIPS64.
15378 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15380 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15382 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
15384 * Makefile.in: Add required vsx dependencies.
15386 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15387 Declare init_registers_powerpc_vsx32l.
15388 Declare init_registers_powerpc_vsx64l.
15389 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15390 (ppc_arch_setup): Check for VSX in hwcap.
15391 (ppc_fill_vsxregset): New function.
15392 (ppc_store_vsxregset): New function.
15393 Add new VSX entry in regset_info target_regsets.
15395 * configure.srv: Add new VSX dependencies.
15397 2008-08-12 Pedro Alves <pedro@codesourcery.com>
15399 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15400 (remote_open): Set or clear transport_is_reliable.
15401 (putpkt_binary): Don't expect acks in noack mode.
15402 (getpkt): Don't send ack/nac in noack mode.
15403 * server.c (handle_general_set): Handle QStartNoAckMode.
15404 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15406 (main): Reset noack_mode on every connection.
15407 * server.h (noack_mode): Declare.
15409 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15411 * Makefile.in (GDBREPLAY_OBS): New variable.
15412 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15414 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15415 Daniel Jacobowitz <dan@codesourcery.com>
15417 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15418 (usr_store_inferior_registers): Likewise.
15419 (regsets_store_inferior_registers): Likewise.
15421 2008-07-31 Rolf Jansen <rj@surtec.com>
15422 Pedro Alves <pedro@codesourcery.com>
15424 * configure.ac: Check for memmem declaration.
15425 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15426 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15427 (disable_packet_qfThreadInfo): Unconditionally compile.
15428 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15429 * configure, config.in: Regenerate.
15431 2008-07-28 Doug Kwan <dougkwan@google.com>
15433 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15434 (linux_write_memory): Remove declaration of errno.
15436 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15438 * linux-low.c (handle_extended_wait): Do not use "status"
15439 variable uninitialized.
15441 2008-07-07 Pedro Alves <pedro@codesourcery.com>
15443 * server.c (handle_v_attach): Inhibit reporting dll changes.
15445 2008-06-27 Pedro Alves <pedro@codesourcery.com>
15447 * remote-utils.c (prepare_resume_reply): If requested, don't
15448 output "thread:TID" in the T stop reply.
15450 * server.c (disable_packet_vCont, disable_packet_Tthread)
15451 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15452 (handle_query): If requested, disable support for qC, qfThreadInfo
15454 (handle_v_requests): If requested, disable support for vCont.
15455 (gdbserver_show_disableable): New.
15456 (main): Handle --disable-packet and --disable-packet=LIST.
15458 * server.h (disable_packet_vCont, disable_packet_Tthread)
15459 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15461 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15463 * server.c (gdbserver_usage): Mention --version.
15465 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15467 * Makefile.in (gdbreplay.o): New rule.
15469 2008-06-06 Joseph Myers <joseph@codesourcery.com>
15471 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15472 message, not gdbserver.
15474 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
15475 Nathan Sidwell <nathan@codesourcery.com>
15476 Joseph Myers <joseph@codesourcery.com>
15478 * acinclude.m4: Include ../../config/acx.m4.
15479 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15480 * configure, config.in: Regenerate.
15481 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15482 * server.c (gdbserver_version): Print PKGVERSION.
15483 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15484 (main): Adjust gdbserver_usage calls.
15485 * gdbreplay.c (version, host_name): Add declarations.
15486 (gdbreplay_version, gdbreplay_usage): New.
15487 (main): Accept --version and --help options.
15489 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15491 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15492 (arm_breakpoint_at): Handle Thumb.
15493 (the_low_target): Add comment.
15495 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15497 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15499 2008-05-09 Doug Evans <dje@google.com>
15501 * server.h (decode_search_memory_packet): Declare.
15502 * remote-utils.c (decode_search_memory_packet): New fn.
15503 * server.c (handle_search_memory_1): New fn.
15504 (handle_search_memory): New fn.
15505 (handle_query): Process qSearch:memory packets.
15507 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15509 * regcache.c (registers_length): Remove.
15510 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15511 full register packet.
15512 * regcache.h (registers_length): Remove prototype.
15513 * server.h (PBUFSIZ): Define to 16384.
15515 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15517 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15518 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15519 powerpc-64l.o, and powerpc-altivec64l.o.
15520 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15521 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15522 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15523 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15524 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15527 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15528 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15529 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15530 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15531 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15532 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15533 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15534 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15535 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15536 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15539 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15540 (init_registers_powerpc_32l): ... this new prototype.
15541 (init_registers_powerpc_32): Remove, replace by ...
15542 (init_registers_powerpc_altivec32l): ... this new prototype.
15543 (init_registers_powerpc_e500): Remove, replace by ...
15544 (init_registers_powerpc_e500l): ... this new prototype.
15545 (init_registers_ppc64): Remove, replace by ...
15546 (init_registers_powerpc_64l): ... this new prototype.
15547 (init_registers_powerpc_64): Remove, replace by ...
15548 (init_registers_powerpc_altivec64l): ... this new prototype.
15549 (ppc_num_regs): Set to 73.
15550 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15551 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15552 (ppc_cannot_store_register): Handle orig_r3 and trap.
15553 (ppc_arch_setup): Update init_registers_... calls.
15554 (ppc_fill_gregset): Handle orig_r3 and trap.
15556 * inferiors.c (clear_inferiors): Reset current_inferior.
15558 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15560 * acinclude.m4: Add override.m4.
15561 * configure: Regenerate.
15563 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15565 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15566 initial call to init_register_ppc64.
15568 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15570 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15571 single powerpc*-*-linux* case.
15572 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15574 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15576 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15577 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15579 * linux-ppc-low.c: Include <elf.h>.
15580 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15581 (ppc_hwcap): New global variable.
15582 (ppc_regmap): Remove __SPE__ #ifdef sections.
15583 (ppc_regmap_e500): New global variable.
15584 (ppc_cannot_store_register): Update __SPE__ special case.
15585 (ppc_get_hwcap): New function.
15586 (ppc_arch_setup): Use it to determine whether inferior supports
15587 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15588 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15589 Do not access registers if target does not support AltiVec.
15590 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15591 Do not access registers if target does not support SPE.
15592 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15594 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15596 * linux-low.c (disabled_regsets, num_regsets): New.
15597 (use_regsets_p): Delete.
15598 (linux_wait_for_process): Clear disabled_regsets.
15599 (regsets_fetch_inferior_registers): Check and set it.
15600 (regsets_store_inferior_registers): Likewise.
15601 (linux_fetch_registers, linux_store_registers): Do not use
15603 (initialize_low): Allocate disabled_regsets.
15605 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15607 * Makefile.in (LIBOBJS): New.
15608 (OBS): Use LIBOBJS.
15609 (memmem.o): New rule.
15610 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15611 * configure: Regenerated.
15613 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15615 * server.c (handle_query): Never return "unsupported" for
15616 qXfer:features:read queries.
15618 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15620 * server.c (get_features_xml): Fix inverted condition.
15621 (handle_query): Always support qXfer:feature:read.
15623 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15625 * server.c (wrapper_argv): New.
15626 (start_inferior): Handle wrapper_argv. If set, expect an extra
15628 (gdbserver_usage): Document --wrapper.
15629 (main): Parse --wrapper.
15631 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15633 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15634 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15635 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15636 (ppc_set_pc): Likewise.
15637 (ppc_arch_setup): New function.
15638 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15639 of collect_register.
15640 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15642 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15644 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15645 instead of linux-ppc64-low.o.
15646 * linux-ppc64-low.c: Remove file.
15647 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15648 (linux-ppc64-low.o): Remove rule.
15650 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15651 (init_registers_powerpc_64): Likewise.
15652 (ppc_regmap): Conditionally define depending on __powerpc64__.
15653 (ppc_cannot_store_register): Do not special-case "fpscr" when
15654 compiled on __powerpc64__.
15655 (ppc_collect_ptrace_register): New function.
15656 (ppc_supply_ptrace_register): New function.
15657 (ppc_breakpoint): Change type to "unsigned int".
15658 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15659 (the_low_target): Conditionally provide initializers for the
15660 arch_setup member depending on __powerpc64__. Install
15661 collect_ptrace_register and supply_ptrace_register members.
15663 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15665 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15666 * server.c (gdbserver_xmltarget): Define.
15667 (get_features_xml): Use it to replace "target.xml" and arch_string.
15669 * configure.srv: Remove srv_xmltarget. Add XML files that were
15670 mentioned there to srv_xmlfiles instead. Remove conditional tests
15671 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15672 srv_xmlfiles and srv_regobj to include all possible choices.
15673 * configure.ac (srv_xmltarget): Remove.
15674 (srv_xmlfiles): Do not add "target.xml".
15675 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15676 checks for supplementary target information.
15677 * configure: Regenerate.
15678 * Makefile.in (XML_TARGET): Remove.
15679 (target.xml): Remove rule.
15680 (clean): Do not clean up target.xml.
15681 (.PRECIOUS): Do not mention target.xml.
15683 * target.h (struct target_ops): Remove arch_string member.
15684 * linux-low.c (linux_arch_string): Remove.
15685 (linux_target_ops): Remove arch_string initializer.
15686 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15687 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15688 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15689 * spu-low.c (spu_arch_string): Remove.
15690 (spu_target_ops): Remove arch_string initializer.
15691 * win32-low.c (win32_arch_string): Remove.
15692 (win32_target_ops): Remove arch_string initializer.
15693 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15694 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15695 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15697 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15699 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15700 by collect_ptrace_register and supply_ptrace_register hooks.
15701 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15702 instead of checking for the_low_target.left_pad_xfer.
15703 (usr_store_inferior_registers): Use collect_ptrace_register callback
15704 instead of checking for the_low_target.left_pad_xfer.
15706 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15707 (s390_supply_ptrace_register): Likewise.
15708 (s390_fill_gregset): Call s390_collect_ptrace_register.
15709 (the_low_target): Update.
15711 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15712 (ppc_supply_ptrace_register): Likewise.
15713 (the_low_target): Update.
15715 * linux-i386-low.c (the_low_target): Update.
15716 * linux-x86-64-low.c (the_low_target): Update.
15718 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15720 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15721 reg-s390.o and reg-s390x.o.
15723 * linux-low.c (new_inferior): New global variable.
15724 (linux_create_inferior, linux_attach): Set it.
15725 (linux_wait_for_process): Call the_low_target.arch_setup after the
15726 target has stopped for the first time.
15727 (initialize_low): Do not call the_low_target.arch_setup.
15729 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15730 (s390_set_pc): Likewise.
15731 (s390_arch_setup): New function.
15732 (the_low_target): Use s390_arch_setup as arch_setup routine.
15734 * regcache.c (realloc_register_cache): New function.
15735 (set_register_cache): Call it for each existing regcache.
15737 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15739 * server.h (init_registers): Remove prototype.
15741 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15742 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15743 instead of init_registers ().
15744 * linux-arm-low.c (init_registers_arm): Add prototype.
15745 (init_registers_arm_with_iwmmxt): Likewise.
15746 (the_low_target): Add initializer for arch_setup field.
15747 * linux-cris-low.c (init_registers_cris): Add prototype.
15748 (the_low_target): Add initializer for arch_setup field.
15749 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15750 (the_low_target): Add initializer for arch_setup field.
15751 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15752 (the_low_target): Add initializer for arch_setup field.
15753 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15754 (the_low_target): Add initializer for arch_setup field.
15755 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15756 (the_low_target): Add initializer for arch_setup field.
15757 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15758 (the_low_target): Add initializer for arch_setup field.
15759 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15760 (init_registers_mips64_linux): Likewise.
15761 (the_low_target): Add initializer for arch_setup field.
15762 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15763 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15764 (the_low_target): Add initializer for arch_setup field.
15765 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15766 (init_registers_powerpc_64): Likewise.
15767 (the_low_target): Add initializer for arch_setup field.
15768 * linux-s390-low.c (init_registers_s390): Add prototype.
15769 (init_registers_s390x): Likewise.
15770 (the_low_target): Add initializer for arch_setup field.
15771 * linux-sh-low.c (init_registers_sh): Add prototype.
15772 (the_low_target): Add initializer for arch_setup field.
15773 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15774 (the_low_target): Add initializer for arch_setup field.
15775 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15776 (the_low_target): Add initializer for arch_setup field.
15778 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15779 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15780 instead of init_registers ().
15781 * win32-arm-low.c (init_registers_arm): Add prototype.
15782 (the_low_target): Add initializer for arch_setup field.
15783 * win32-i386-low.c (init_registers_i386): Add prototype.
15784 (the_low_target): Add initializer for arch_setup field.
15786 * spu-low.c (init_registers_spu): Add prototype.
15787 (initialize_low): Call initialie_registers_spu () instead of
15788 initialize_registers ().
15790 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15792 * server.c (handle_v_requests): When handling the vRun and vAttach
15793 packets, if already debugging a process, don't kill it. Return an
15796 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15798 * server.c (handle_query): Correct length check.
15800 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15802 * win32-low.c (do_initial_child_stuff): Add process handle
15803 parameter. Set current_process_handle and current_process_id from the
15804 parameters. Clear globals.
15805 (win32_create_inferior): Don't set current_process_handle and
15806 current_process_id here. Instead pass them on the call to
15807 do_initial_child_stuff.
15808 (win32_attach): Likewise.
15809 (win32_clear_inferiors): New.
15810 (win32_kill): Don't close the current process handle or the
15811 current thread handle here. Instead call win32_clear_inferiors.
15812 (win32_detach): Don't open a new handle to the process. Call
15813 win32_clear_inferiors.
15814 (win32_join): Don't rely on current_process_handle; open a new
15815 handle using the process id.
15816 (win32_wait): Call win32_clear_inferiors when the inferior process
15819 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15821 * server.c (monitor_show_help): Add "exit".
15823 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15825 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15826 (clean): Add reg-xtensa.c.
15827 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15828 * configure.srv (xtensa*-*-linux*) New target.
15829 * linux-xtensa-low.c: New.
15830 * xtensa-xtregs.c: New.
15832 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15834 * hostio.c: Don't include errno.h.
15835 (errno_to_fileio_errno): Move to hostio-errno.
15836 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15837 error number outputting to the target->hostio_last_error callback.
15838 (hostio_packet_error): Use FILEIO_EINVAL directly.
15839 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15840 calls to hostio_error.
15841 * hostio-errno.c: New.
15842 * server.h (hostio_last_error_from_errno): Declare.
15843 * target.h (target_ops): Add hostio_last_error member.
15844 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15845 as hostio_last_error handler.
15846 * spu-low.c (spu_target_ops): Likewise.
15847 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15848 (wince_hostio_last_error): New functions.
15849 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15850 as hostio_last_error handler.
15851 (win32_target_ops) [!_WIN32_WCE]: Register
15852 hostio_last_error_from_errno as hostio_last_error handler.
15853 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15854 (hostio-errno.o): New rule.
15855 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15856 * configure.srv (srv_hostio_err_objs): New variable. Default to
15858 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15859 * configure: Regenerate.
15861 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15863 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15864 (linux_kill, linux_detach): Clean up the process list.
15865 * remote-utils.c (remote_open): Improve port number parsing.
15866 (putpkt_binary, input_interrupt): Only send interrupts if the target
15868 * server.c (extended_protocol): Make static.
15869 (attached): Define earlier.
15870 (exit_requested, response_needed, program_argv): New variables.
15871 (target_running): New.
15872 (start_inferior): Clear attached here.
15873 (attach_inferior): Set attached here.
15874 (require_running): Define.
15875 (handle_query): Use require_running and target_running. Implement
15877 (handle_v_attach, handle_v_run): New.
15878 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15879 (gdbserver_usage): Update.
15880 (main): Redo argument parsing. Handle --debug and --multi. Handle
15881 --attach along with other options or after the port. Save
15882 program_argv. Support no initial program. Resynchronize
15883 communication with GDB after an error. Handle "monitor exit".
15884 Use require_running and target_running. Always allow the extended
15885 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15886 restart in extended mode.
15887 * README: Refer to the GDB manual. Update --attach usage.
15889 2007-12-20 Andreas Schwab <schwab@suse.de>
15891 * linux-low.c (STACK_SIZE): Define.
15892 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15893 (linux_test_for_tracefork): Likewise.
15895 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15897 * linux-low.c (linux_wait_for_event): Update messages. Do not
15898 reinsert auto-delete breakpoints.
15899 * mem-break.c (struct breakpoint): Change return type of handler to
15901 (set_breakpoint_at): Update handler type.
15902 (reinsert_breakpoint_handler): Return 1 instead of calling
15904 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15906 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15907 * mem-break.h (set_breakpoint_at): Update handler type.
15908 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15909 * win32-low.c (auto_delete_breakpoint): New.
15910 (get_child_debug_event): Use it.
15912 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15914 * configure.ac: Check for pread and pwrite.
15915 * hostio.c (handle_pread): Fall back to lseek and read.
15916 (handle_pwrite): Fall back to lseek and write.
15917 * config.in, configure: Regenerated.
15919 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15921 * server.c (myresume): Add own_buf argument.
15922 (main): Update calls.
15924 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15926 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15927 * remote-utils.c (remote_open): Do not call disable_async_io.
15928 (block_async_io): Delete.
15929 (unblock_async_io): Make static.
15930 (initialize_async_io): New.
15931 * server.c (handle_v_cont): Handle async I/O here.
15932 (myresume): Likewise. Move other common resume tasks here...
15933 (main): ... from here. Call initialize_async_io. Disable async
15934 I/O before the main loop.
15935 * server.h (initialize_async_io): Declare.
15936 (block_async_io, unblock_async_io): Delete prototypes.
15937 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15939 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15941 * remote-utils.c (readchar): Allow binary data in received messages.
15943 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15945 * win32-low.c (attaching): New global.
15946 (win32_create_inferior): Clear the `attaching' global.
15947 (win32_attach): Set the `attaching' global.
15948 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15949 attaching. Only set a breakpoint at the entry point if not
15952 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15954 * server.c (main): Don't report dll events on the initial
15955 connection on attaches.
15957 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15959 * server.c (main): Relax numerical bases supported for the pid of
15960 the --attach command line argument.
15962 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15964 * win32-low.c (win32_attach): Call OpenProcess before
15965 DebugActiveProcess, not after. Add last error output to error
15968 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15970 * win32-low.c (win32_get_thread_context)
15971 (win32_set_thread_context): New functions.
15972 (thread_rec): Use win32_get_thread_context.
15973 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15974 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15977 2007-12-03 Leo Zayas
15978 Pedro Alves <pedro_alves@portugalmail.pt>
15980 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15982 (child_add_thread): Minor cleanup.
15983 (child_continue): Resume artificially suspended threads before
15984 calling ContinueDebugEvent.
15985 (suspend_one_thread): New.
15986 (fake_breakpoint_event): New.
15987 (get_child_debug_event): Change return type to int. Check here if
15988 gdb sent an interrupt request. If a soft interrupt was requested,
15989 fake a breakpoint event. Return 0 if there is no event to handle,
15991 (win32_wait): Don't check here if gdb sent an interrupt request.
15992 Ensure there is a valid event to handle.
15993 (win32_request_interrupt): Add soft interruption method as last
15996 2007-12-03 Leo Zayas
15997 Pedro Alves <pedro_alves@portugalmail.pt>
15999 * win32-low.h (win32_thread_info): Add descriptions to the
16000 structure members. Replace `suspend_count' counter by a
16002 * win32-low.c (thread_rec): Update condition of when to get the
16003 context from the inferior. Rely on ContextFlags being set if it
16004 has already been retrieved. Only suspend the inferior thread if
16005 we haven't already. Warn if that fails.
16006 (continue_one_thread): s/suspend_count/suspended/. Only call
16007 ResumeThread once. Warn if that fails.
16009 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
16011 * win32-low.c (win32_wait): Don't read from the inferior when it
16012 has already exited.
16014 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
16016 * Makefile.in (win32_low_h): New variable.
16017 (win32-low.o): Add dependency on $(win32_low_h).
16018 (win32-arm-low.o, win32-i386-low.o): New rules.
16020 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
16022 * hostio.c: Correct copyright year.
16024 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
16026 * Makefile.in (OBS): Add hostio.o.
16027 (hostio.o): New rule.
16028 * server.h (handle_vFile): Declare.
16029 * hostio.c: New file.
16030 * server.c (handle_v_requests): Take packet_len and new_packet_len
16031 for binary packets. Call handle_vFile.
16032 (main): Update call to handle_v_requests.
16034 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
16036 * linux-low.c: Include <sched.h>.
16038 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
16040 * linux-low.c (linux_tracefork_grandchild): New.
16041 (linux_tracefork_child): Use clone.
16042 (linux_test_for_tracefork): Use clone; allocate and free a stack.
16044 2007-10-31 Joel Brobecker <brobecker@adacore.com>
16046 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
16048 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
16050 * linux-low.c (handle_extended_wait): Handle unexpected signals.
16052 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
16054 * inferiors.c (change_inferior_id): Delete.
16055 (add_pid_to_list, pull_pid_from_list): New.
16056 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
16057 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
16058 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
16059 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
16060 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
16061 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
16062 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
16063 (using_threads): Always set to 1.
16064 (handle_extended_wait): New.
16065 (add_process): Do not set TID.
16066 (linux_create_inferior): Set must_set_ptrace_flags.
16067 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
16068 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
16069 (linux_thread_alive): Rename TID argument to LWPID.
16070 (linux_wait_for_process): Handle unknown processes. Do not use TID.
16071 (linux_wait_for_event): Do not use TID or check using_threads. Update
16072 call to dead_thread_notify. Call handle_extended_wait.
16073 (linux_create_inferior): Use PTRACE_SETOPTIONS.
16074 (send_sigstop): Delete sigstop_sent.
16075 (wait_for_sigstop): Avoid TID.
16076 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
16077 (linux_test_for_tracefork): New.
16078 (linux_lookup_signals): Use thread_db_active and
16079 linux_supports_tracefork_flag.
16080 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
16081 * linux-low.h (get_process_thread): Avoid TID.
16082 (struct process_ifo): Move thread_known and tid to the end. Remove
16084 (linux_attach_lwp, thread_db_init): Update prototypes.
16085 * server.h (change_inferior_id): Delete prototype.
16086 (add_pid_to_list, pull_pid_from_list): New prototypes.
16087 * thread-db.c (thread_db_use_events): New.
16088 (find_first_thread): Rename to...
16089 (find_one_thread): ...this. Update callers and messages. Do not
16090 call fatal. Check thread_db_use_events. Do not call
16091 change_inferior_id or new_thread_notify.
16092 (maybe_attach_thread): Update. Do not call new_thread_notify.
16093 (thread_db_init): Set thread_db_use_events. Check use_events.
16094 * utils.c (fatal, warning): Correct message prefix.
16096 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
16098 * Makefile.in (clean): Remove new files.
16099 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
16100 (powerpc-64.o, powerpc-64.c): New rules.
16101 * configure.srv: Use alternate register sets for powerpc64-*-linux*
16102 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
16104 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
16106 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
16107 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
16108 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
16109 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
16110 (target_regsets): Add AltiVec and SPE register sets.
16111 * configure.ac: Check for AltiVec and SPE.
16112 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
16113 (ppc_fill_vrregset, ppc_store_vrregset): New.
16114 (target_regsets): Add AltiVec register set.
16115 * configure: Regenerated.
16117 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
16119 * linux-low.c (O_LARGEFILE): Define.
16120 (linux_read_memory): Use /proc/PID/mem.
16121 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
16122 * configure, config.in: Regenerated.
16124 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16126 * linux-low.c (linux_wait_for_event): Do not pass signals while
16129 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16131 * win32-low.c (create_process): New.
16132 (win32_create_inferior): Use create_process instead of
16133 CreateProcess. If create_process failed retry appending an ".exe"
16134 suffix. Store the GetLastError result immediatelly after
16135 create_process calls and use it on the call to error.
16137 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16139 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
16141 2007-08-23 Joel Brobecker <brobecker@adacore.com>
16143 * configure.ac: Switch license to GPLv3.
16145 2007-08-01 Michael Snyder <msnyder@access-company.com>
16147 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
16149 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
16151 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
16153 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
16154 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
16155 CloseToolhelp32Snapshot.
16156 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
16157 CloseToolhelp32Snapshot.
16159 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
16161 * server.c (main): Check for inferior exit before main loop.
16163 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
16165 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
16166 instead of on tmp_desc.
16168 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
16169 Daniel Jacobowitz <dan@codesourcery.com>
16171 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
16172 (add_thread): Minor cleanups.
16173 (clear_inferiors): Move lower in the file. Clear the DLL
16175 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
16176 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
16177 (xml_escape_text): New.
16178 * server.c (handle_query): Handle qXfer:libraries:read. Report it
16180 (handle_v_cont): Report errors.
16181 (gdbserver_version): Update.
16182 (main): Correct size of own_buf. Do not report initial DLL events.
16183 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
16184 (unloaded_dll, xml_escape_text): New.
16185 * win32-low.c (enum target_waitkind): Update comments.
16186 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
16187 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
16188 (win32_EnumProcessModules, win32_GetModuleInformation)
16189 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
16190 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
16191 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
16192 (win32_Module32First, win32_Module32Next, load_toolhelp)
16193 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
16194 (get_child_debug_event): Handle DLL events.
16195 (win32_wait): Likewise.
16197 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16199 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
16200 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
16202 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16204 * win32-low.c (handle_output_debug_string): Ignore event if not
16207 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16209 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
16211 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
16213 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
16215 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
16217 * inferiors.c (change_inferior_id): Add comment.
16218 * linux-low.c (check_removed_breakpoint): Add an early
16219 prototype. Improve debug output.
16220 (linux_attach): Doc update.
16221 (linux_detach_one_process, linux_detach): Clean up before releasing
16223 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
16224 * linux-low.h (struct process_info): Doc improvement.
16225 * mem-break.c (delete_all_breakpoints): New.
16226 * mem-break.h (delete_all_breakpoints): New prototype.
16227 * thread-db.c (find_first_thread): New.
16228 (thread_db_create_event): Call it instead of
16229 thread_db_find_new_threads. Clean up unused variables.
16230 (maybe_attach_thread): Remove first thread handling.
16231 (thread_db_find_new_threads): Use find_first_thread.
16232 (thread_db_get_tls_address): Likewise.
16234 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
16236 * thread-db.c (thread_db_find_new_threads): Add prototype.
16237 (thread_db_create_event): Check for the main thread before adding
16239 (maybe_attach_thread): Only enable event reporting if TID == 0.
16240 (thread_db_get_tls_address): Check for new threads.
16242 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16244 * linux-low.c (linux_create_inferior): Try execv before execvp.
16245 * spu-low.c (spu_create_inferior): Likewise.
16247 2007-06-13 Mike Frysinger <vapier@gentoo.org>
16249 * linux-low.c (linux_create_inferior): Change execv to execvp.
16250 * spu-low.c (spu_create_inferior): Likewies.
16252 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16254 * Makefile.in (clean): Clean new files instead of deleted ones.
16255 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16256 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16258 * configure.srv: Specify XML files and new regformats for MIPS and
16260 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16261 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16262 an entry for the restart register.
16263 (mips_cannot_fetch_register, mips_cannot_store_register)
16264 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16265 register names to match the XML descriptions.
16266 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16267 restart register instead of $0.
16269 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16270 Markus Deuling <deuling@de.ibm.com>
16272 * remote-utils.c (decode_xfer_write): New function.
16273 * server.h (decode_xfer_write): Add prototype.
16274 * server.c (handle_query): Add PACKET_LEN argument. Support
16275 qXfer:spu:read and qXfer:spu:write packets.
16276 (main): Pass packet_len to handle_query.
16277 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16278 * target.h (target_ops): Add qxfer_spu.
16280 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16282 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16283 accessing non-seekable spufs files.
16285 2007-05-16 Markus Deuling <deuling@de.ibm.com>
16287 * server.c (handle_query): Add reply for qC packet.
16289 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16290 Leo Zayas <lerele@champenstudios@com>
16292 * server.h (check_remote_input_interrupt_request): New function.
16293 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16294 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16295 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16296 (check_remote_input_interrupt_request): New function.
16297 * server.h (check_remote_input_interrupt_request): Declare.
16298 * win32-low.c (winapi_DebugBreakProcess,
16299 winapi_GenerateConsoleCtrlEvent): New typedefs.
16300 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16302 (win32_wait): Check for remote interrupt request
16303 with check_remote_input_interrupt_request.
16304 (win32_request_interrupt): New function.
16305 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16307 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16309 * win32-low.c (debug_registers_changed,
16310 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16311 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16312 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16313 (thread_rec): Get context using the low target.
16314 (child_add_thread): Call thread_added on the low target,
16315 which does the same thing.
16317 (do_initial_child_stuff): Remove debug registers references.
16318 Set context using the low target. Resume threads after
16319 setting the contexts.
16320 (child_continue): Remove dead variable. Remove debug
16321 registers references.
16322 (child_fetch_inferior_registers): Go through the low target.
16323 (do_child_store_inferior_registers): Remove.
16324 (child_store_inferior_registers): Go through the low target.
16325 (win32_resume): Remove debug registers references.
16326 Set context using the low target.
16327 (handle_exception): Change return type to void. Don't record
16328 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16329 first chance exception.
16330 (get_child_debug_event): Change return type to void. Remove
16331 goto loop. Always return after waiting for debug event.
16332 (win32_wait): Convert to switch statement. Handle spurious
16335 * win32-i386-low.c (debug_registers_changed,
16336 debug_registers_used): New.
16337 (initial_stuff): Rename to ...
16338 (i386_initial_stuff): ... this. Clear debug registers
16340 (store_debug_registers): Delete.
16341 (i386_get_thread_context): New.
16342 (load_debug_registers): Delete.
16343 (i386_set_thread_context): New.
16344 (i386_thread_added): New.
16345 (single_step): Rename to ...
16346 (i386_single_step): ... this.
16347 (do_fetch_inferior_registers): Rename to ...
16348 (i386_fetch_inferior_register): ... this.
16349 (i386_store_inferior_register): New.
16350 (the_low_target): Adapt to new interface.
16352 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16353 (arm_get_thread_context): New.
16354 (arm_set_thread_context): New.
16356 (do_fetch_inferior_registers): Rename to ...
16357 (arm_fetch_inferior_register): ... this.
16358 (arm_store_inferior_register): New.
16359 (arm_wince_breakpoint): Reimplement as unsigned long.
16360 (arm_wince_breakpoint_len): Define.
16361 (the_low_target): Adapt to new interface.
16363 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16364 load_debug_registers. Add get_thread_context, set_thread_context,
16365 thread_added and store_inferior_register. Rename
16366 fetch_inferior_registers to fetch_inferior_register.
16367 (regptr): Remove declaration.
16369 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16371 * linux-low.c (linux_detach): Change return type to int. Return 0.
16372 * spu-low.c (spu_detach): Likewise.
16374 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16376 * target.h (target_ops): Change return type of detach to int.
16378 (join_inferior): New.
16379 * server.c (main): Don't skip detach support on mingw32.
16380 If the inferior doesn't support detaching return error.
16381 Call join_inferior instead of using waitpid.
16382 * linux-low.c (linux_join): New.
16383 (linux_target_op): Add linux_join.
16384 * spu-low.c (spu_join): New.
16385 (spu_target_ops): Add spu_join.
16386 * win32-low.c (win32_detach): Adapt to new interface.
16387 Reopen current_process_handle before detaching. Issue a child
16388 resume before detaching.
16390 (win32_target_op): Add win32_join.
16392 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16394 * win32-low.c (win32-attach): Fix return value.
16395 * target.h (target_ops): Describe ATTACH return values.
16397 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16399 * win32-low.c (GETPROCADDRESS): Define.
16400 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16401 (winapi_DebugSetProcessKillOnExit): Likewise.
16402 (win32_create_inferior): Force usage of ansi CreateProcessA.
16403 (win32_attach): Use GETPROCADDRESS.
16404 (win32_detach): Likewise.
16406 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16408 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16410 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16412 * win32-low.c: Commit leftover changes from 2007-03-29.
16414 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16416 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16417 fields short instead of int. Add explicit padding.
16418 (i387_cache_to_fsave): Remove unnecessary casts.
16419 (i387_fsave_to_cache): Doc fix.
16420 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16422 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16424 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16425 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16427 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16429 * configure.srv (arm*-*-mingw32ce*): Move near the other
16432 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16434 * configure.ac: Add errno checking.
16435 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16436 sys/file.h and malloc.h.
16437 (AC_CHECK_DECLS): Add perror.
16438 (srv_mingwce): Handle.
16439 * configure.srv (i[34567]86-*-cygwin*): Add
16440 win32-i386-low.o to srv_tgtobj.
16441 (i[34567]86-*-mingw*): Likewise.
16442 (arm*-*-mingw32ce*): Add case.
16443 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16444 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16445 [__MINGW32CE__] (strerror): New function.
16446 [__MINGW32CE__] (errno): Define to GetLastError.
16447 [__MINGW32CE__] (COUNTOF): New macro.
16448 (remote_open): Remove extra close call.
16449 * mem-break.c (delete_breakpoint_at): New function.
16450 * mem-break.h (delete_breakpoint_at): Declare.
16451 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16452 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16453 [USE_WIN32API] (read, write): Add char* casts.
16454 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16455 * server.h: Include wincecompat.h on Windows CE.
16456 [HAVE_ERRNO_H]: Check.
16457 (perror): Declare if not declared.
16458 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16459 (perror_with_name): Remove errno declaration.
16460 * wincecompat.h: New.
16461 * wincecompat.c: New.
16462 * win32-low.h: New.
16463 * win32-arm-low.c: New.
16464 * win32-i386-low.c: New.
16465 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16466 (OUTMSG2): Make it safe.
16468 (COUNTOF): New macro.
16469 (NUM_REGS): Get it from the low target.
16470 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16471 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16472 (thread_rec): Let low target handle debug registers.
16473 (child_add_thread): Likewise.
16474 (child_init_thread_list): Likewise.
16475 (continue_one_thread): Likewise.
16477 (do_child_fetch_inferior_registers): Move to ...
16478 * win32-i386-low.c: ... here, and rename to ...
16479 (do_fetch_inferior_registers): ... this.
16480 * win32-low.c (child_fetch_inferior_registers):
16481 Go through the low target.
16482 (do_child_store_inferior_registers): Use regptr.
16483 (strwinerror): New function.
16484 (win32_create_inferior): Handle Windows CE.
16485 Use strwinerror instead of strerror on Windows error
16486 codes. Add program to the error output.
16487 Don't close the main thread handle on Windows CE.
16488 (win32_attach): Use coredll.dll on Windows CE.
16489 (win32_kill): Close current process and current
16491 (win32_detach): Use coredll.dll on Windows CE.
16492 (win32_resume): Let low target handle debug registers, and
16494 (handle_exception): Add/Remove initial breakpoint. Avoid
16495 non-existant WSTOPSIG on Windows CE.
16496 (win32_read_inferior_memory): Cast to remove warning.
16497 (win32_arch_string): Go through the low target.
16498 (initialize_low): Call set_breakpoint_data with the low
16499 target's breakpoint.
16500 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16501 FOP_REGNUM, mappings): Move to ...
16502 * win32-i386-low.c: ... here.
16503 * win32-low.c (win32_thread_info): Move to ...
16504 * win32-low.h: ... here.
16505 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16506 win32-arm-low.c and wincecompat.c.
16507 (all:): Add $EXEEXT.
16508 (install-only:): Likewise.
16509 (gdbserver:): Likewise.
16510 (gdbreplay:): Likewise.
16511 * config.in: Regenerate.
16512 * configure: Regenerate.
16514 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16516 * win32-low.c: Rename typedef thread_info to
16517 win32_thread_info throughout.
16519 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16521 * win32-i386-low.c: Rename to ...
16522 * win32-low.c: ... this.
16523 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16524 * Makefile.in: Likewise.
16526 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16528 * remote-utils.c (monitor_output): Constify msg parameter.
16529 * server.h (monitor_output): Likewise.
16530 * win32-i386-low.c (handle_output_debug_string): New.
16531 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16532 handle_output_debug_string.
16533 (get_child_debug_event): Likewise.
16535 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16537 * server.c (main): Correct strtoul check.
16539 2007-03-27 Jon Ringle <jon@ringle.org>
16541 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16543 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16545 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16547 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16549 * terminal.h: Check HAVE_SGTTY_H.
16551 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16553 * remote-utils.c (remote_open): Print out the assigned port number.
16555 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16557 * remote-utils.c (monitor_output): New function.
16558 * server.c (debug_threads): Define here.
16559 (monitor_show_help): New function.
16560 (handle_query): Handle qRcmd.
16561 (main): Do not handle 'd' packet.
16562 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16563 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16566 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16568 * Makefile.in (EXEEXT): New.
16569 (clean): Use $(EXEEXT).
16571 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16573 * target.h (target_ops): Rename send_signal to request_interrupt,
16574 and remove enum target_signal parameter.
16575 * linux-low.c (linux_request_interrupt): Rename from
16576 linux_send_signal, and always send SIGINT.
16577 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16578 and always send SIGINT.
16579 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16581 (input_interrupt): Likewise.
16583 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16585 * server.c (get_features_xml): Check if target implemented
16587 * win32-i386-low.c (win32_arch_string): New.
16588 (win32_target_ops): Add win32_arch_string as arch_string member.
16590 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16592 * spu-low.c (spu_arch_string): New.
16593 (spu_target_ops): Add spu_arch_string.
16595 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16597 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16598 * configure.ac: Do not check for terminal.h.
16599 * configure, config.in: Regenerated.
16601 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16603 * Makefile.in (OBS): Add $(XML_BUILTIN).
16604 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16606 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16607 (arm-with-iwmmxt.c): New.
16608 * config.in, configure: Regenerate.
16609 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16610 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16611 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16612 (arm*-*-linux*): Add iWMMXt and regset support.
16613 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16614 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16615 (arm_store_wmmxregset, target_regsets): New.
16616 * server.c (get_features_xml): Take annex argument. Check builtin
16618 (handle_query): Handle multiple annexes.
16620 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16622 * remote-utils.c [USE_WIN32API] (read, write): Define.
16623 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16626 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16628 * linux-i386-low.c (the_low_target): Set arch_string.
16629 * linux-x86-64-low.c (the_low_target): Likewise.
16630 * linux-low.c (linux_arch_string): New.
16631 (linux_target_ops): Add it.
16632 * linux-low.h (struct linux_target_ops): Add arch_string.
16633 * server.c (write_qxfer_response): Use const void * for DATA.
16634 (get_features_xml): New.
16635 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16636 * target.h (struct target_ops): Add arch_string method.
16638 2007-01-03 Denis Pilat <denis.pilat@st.com>
16639 Daniel Jacobowitz <dan@codesourcery.com>
16641 * linux-low.c (linux_kill): Handle being called with no threads.
16642 * win32-i386-low.c (win32_kill): Likewise.
16643 (get_child_debug_event): Clear current_process_handle.
16645 2006-12-30 Denis PILAT <denis.pilat@st.com>
16646 Daniel Jacobowitz <dan@codesourcery.com>
16648 * remote-utils.c (remote_open): Check the type of specified
16649 serial port devices before opening them.
16650 * server.c (main): Kill the inferior if an error occurs during
16651 the first remote_open.
16653 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16655 * README: Update supported targets.
16657 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16659 * Makefile.in (clean): Remove reg-mips64.c.
16660 (reg-mips64.c, reg-mips64.o): New rules.
16661 * configure.srv: Handle mips64. Include regset support for mips.
16662 * linux-mips-low.c (union mips_register): New.
16663 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16664 (mips_breakpoint, mips_breakpoint_at): Use int.
16665 (mips_collect_register, mips_supply_register)
16666 (mips_collect_register_32bit, mips_supply_register_32bit)
16667 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16668 (mips_store_fpregset, target_regsets): New.
16669 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16671 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16673 * configure.srv: Add target "spu*-*-*".
16674 * Makefile.in (clean): Remove reg-spu.c.
16675 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16676 * spu-low.c: New file.
16678 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16680 * configure.ac: Correct td_thr_tls_get_addr test.
16681 * configure: Regenerated.
16683 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16685 * linux-low.c (linux_wait_for_event): Reformat. Use the
16686 pass_signals array.
16687 * remote-utils.c (decode_address_to_semicolon): New.
16688 * server.c (pass_signals, handle_general_set): New.
16689 (handle_query): Mention QPassSignals for qSupported.
16690 (main): Call handle_general_set.
16691 * server.h (pass_signals, decode_address_to_semicolon): New.
16693 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16695 * server.c (handle_query): Correct error handling for read_auxv.
16697 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16699 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16700 and srv_linux_thread_db to yes.
16701 * linux-s390-low.c (s390_fill_gregset): New function.
16702 (target_regsets): Define data structure.
16704 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16706 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16707 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16708 * config.in, configure: Regenerated.
16709 * inferiors.c (gdb_id_to_thread): New function.
16710 (gdb_id_to_thread_id): Use it.
16711 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16712 * linux-low.h (struct process_info): Add th member.
16713 (thread_db_get_tls_address): New prototype.
16714 * remote-utils.c (decode_address): Make non-static.
16715 * server.c (handle_query): Handle qGetTLSAddr.
16716 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16717 * target.h (struct target_ops): Add get_tls_address.
16718 * thread-db.c (maybe_attach_thread): Save the thread handle.
16719 (thread_db_get_tls_address): New.
16721 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16723 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16724 (linux_resume_one_process): Take a siginfo_t *. Update all
16725 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16726 (struct pending_signals): Add a siginfo_t.
16727 (linux_wait_for_process): Always set last_status.
16728 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16729 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16730 * linux-low.h (struct process_info): Add last_status.
16732 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16734 * remote-utils.c (try_rle): New function.
16735 (putpkt_binary): Use it.
16737 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16739 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16740 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16741 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16742 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16743 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16746 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16748 * server.c (terminal_fd): New variable.
16749 (old_foreground_pgrp): Likewise.
16750 (restore_old_foreground_pgrp): New function.
16751 (start_inferior): Record the terminal file descriptor in terminal_fd
16752 and its original foreground group in old_foreground_pgrp. Register
16753 restore_old_foreground_pgrp with atexit().
16755 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16757 * server.c (handle_query): Correct qPart to qXfer.
16759 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16761 * configure.ac: Check for more headers which are missing on
16762 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16763 * configure.srv: Add Cygwin and mingw32.
16764 * remote-utils.c: Don't include headers unconditionally which
16765 are missing on mingw32. Include <winsock.h> for mingw32.
16766 (remote_open): Adjust for mingw32 support. Flush
16767 standard error after writing to it.
16768 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16769 (unblock_async_io, enable_async_io, disable_async_io)
16770 (readchar, getpkt): Update for Winsock support.
16771 (prepare_resume_reply): Expect a protocol signal number.
16772 * server.c: Disable <sys/wait.h> on mingw32.
16773 (start_inferior): Adjust for mingw32 support. Flush
16774 standard error after writing to it.
16775 (attach_inferior): Likewise. Use protocol signal
16777 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16779 * win32-i386-low.c: New file.
16780 * Makefile.in (XM_CLIBS): Set.
16781 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16782 (win32-i386-low.o): New dependency rule.
16783 * linux-low.c (linux_wait): Use target signal numbers.
16784 * target.h (struct target_ops): Doc fix.
16785 * server.h (target_signal_to_name): New prototype.
16786 * gdbreplay.c: Don't include headers unconditionally which
16787 are missing on mingw32. Include <winsock.h> for mingw32.
16788 (remote_close, remote_open): Adjust for Winsock support.
16789 * configure, config.in: Regenerated.
16791 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16793 * server.c (decode_xfer_read, write_qxfer_response): New.
16794 (handle_query): Take a packet length argument. Handle
16795 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16796 the qSupported response.
16797 (main): Update call to handle_query.
16799 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16801 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16802 (putpkt_binary): Renamed from putpkt and adjusted for binary
16804 (putpkt): New wrapper for putpkt_binary.
16805 (readchar): Don't mask off the high bit.
16806 (decode_X_packet): New function.
16807 * server.c (main): Call putpkt_binary if a handler sets the packet
16808 length. Save the length of the incoming packet. Handle 'X'.
16809 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16811 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16813 * server.c (handle_query): Handle qSupported.
16815 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16817 * remote-utils.c (all_symbols_looked_up): New variable.
16818 (look_up_one_symbol): Check it.
16819 * server.h (look_up_one_symbol): New declaration.
16820 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16822 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16824 * Makefile.in (linux-arm-low.o): Update dependencies.
16825 * linux-arm-low.c: Include "gdb_proc_service.h".
16826 (PTRACE_GET_THREAD_AREA): Define.
16827 (ps_get_thread_area): New function.
16829 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16831 * configure.srv (m68k*-*-uclinux*): New target.
16832 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16833 (linux_resume_one_process): Remove extraneous cast.
16834 (linux_read_offsets): New.
16835 (linux_target_op): Add linux_read_offsets on mmuless systems.
16836 * server.c (handle_query): Add qOffsets logic.
16837 * target.h (struct target_ops): Add read_offsets.
16839 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16841 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16842 (PTRACE_GET_THREAD_AREA): Define.
16843 (ps_get_thread_area): New function.
16844 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16845 (linux-x86-64-low.o): Update.
16847 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16849 * configure.ac: Remove checks for prfpregset_t.
16850 * gdb_proc_service.h: New file.
16851 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16852 new "gdb_proc_service.h".
16853 * proc-service.c: Likewise.
16854 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16855 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16856 * Makefile.in (gdb_proc_service_h): Updated.
16857 * configure, config.in: Regenerated.
16859 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16861 * remote-utils.c (prepare_resume_reply): Move declaration
16862 of gdb_id_from_wait to the top of the block.
16864 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16866 * linux-low.c (regsets_store_inferior_registers): Read the regset
16867 from the target before filling it.
16869 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16871 * server.c (attach_inferior): Return SIGTRAP for a successful
16874 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16876 * Makefile.in (OBS): Add version.o.
16877 (STAGESTUFF): Delete.
16878 (version.o): Add dependencies.
16879 (version.c): Replace rule.
16880 (clean): Remove version.c.
16881 * server.c (gdbserver_version): New.
16882 (gdbserver_usage): Use printf.
16883 (main): Handle --version and --help.
16884 * server.h (version, host_name): Add declarations.
16886 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16898 * linux-x86-64-low.c:
16900 * linux-s390-low.c:
16901 * linux-ppc64-low.c:
16903 * linux-mips-low.c:
16904 * linux-m68k-low.c:
16905 * linux-m32r-low.c:
16908 * linux-ia64-low.c:
16909 * linux-i386-low.c:
16910 * linux-crisv32-low.c:
16922 * gdbserver.1: Add (C) after Copyright. Update the FSF
16925 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16927 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16928 (arm_breakpoint_at): Recognize both breakpoints.
16929 (the_low_target): Use the correct breakpoint instruction.
16931 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16933 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16934 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16935 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16936 (the_low_target): Update.
16938 2005-10-25 Andreas Schwab <schwab@suse.de>
16940 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16942 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16943 (ia64_num_regs): Reduce to 462.
16945 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16947 * acinclude.m4: Correct quoting.
16948 * aclocal.m4: Regenerated.
16950 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16951 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16952 (thread_db_init): Call thread_db_err_str.
16953 * configure.ac: Check for TD_VERSION.
16954 * config.in, configure: Regenerated.
16956 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16958 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16960 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16962 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16963 is not available. Define HAVE_PTRACE_GETREGS if it is.
16964 * config.in, configure: Regenerated.
16965 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16966 * linux-i386-low.c, linux-m68k-low.c: Update to use
16967 HAVE_PTRACE_GETREGS.
16968 * linux-low.c (regsets_fetch_inferior_registers)
16969 (regsets_store_inferior_registers): Only return 0 if we processed
16971 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16972 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16974 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16976 * inferiors.c (struct thread_info): Add gdb_id.
16977 (add_thread): Add gdb_id argument.
16978 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16979 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16980 calls to add_thread.
16981 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16982 * server.c (handle_query): Use thread_to_gdb_id.
16983 (handle_v_cont, main): Use gdb_id_to_thread_id.
16984 * server.h (add_thread): Update prototype.
16985 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16988 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16990 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16991 left-padded registers.
16992 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16993 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16995 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16997 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16998 * configure: Regenerate.
16999 * config.in: Regenerate.
17000 * server.h (NEED_DECLARATION_STRERROR):
17001 Replace with !HAVE_DECL_STRERROR.
17003 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
17005 * linux-low.c (linux_wait, linux_send_signal): Don't test
17006 an unsigned long variable for > 0 if it could be MAX_ULONG.
17007 * server.c (myresume): Likewise.
17008 * target.c (set_desired_inferior): Likewise.
17010 2005-06-13 Mark Kettenis <kettenis@gnu.org>
17012 * configure.ac: Simplify and improve check for socklen_t.
17013 * configure, config.in: Regenerate.
17015 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
17017 * acconfig.h: Remove.
17018 * configure.ac: Add a test for socklen_t. Use three-argument
17019 AC_DEFINE throughout.
17020 * config.in: Regenerated using autoheader 2.59.
17021 * configure: Regenerated.
17023 * gdbreplay.c (socklen_t): Provide a default.
17024 (remote_open): Use socklen_t.
17025 * remote-utils.c (socklen_t): Provide a default.
17026 (remote_open): Use socklen_t.
17027 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
17030 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
17032 * linux-low.c (linux_read_memory, linux_write_memory)
17033 (linux_read_auxv): Likewise.
17034 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
17035 (check_mem_write): Likewise.
17036 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
17038 * regcache.c (struct inferior_rgcache_data, registers_to_string)
17039 (registers_from_string, register_data): Likewise.
17040 * server.c (handle_query, main): Likewise.
17041 * server.h (convert_ascii_to_int, convert_int_to_ascii)
17042 (decode_M_packet): Likewise.
17043 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
17044 * target.h (struct target_ops): Update read_memory, write_memory,
17046 (read_inferior_memory, write_inferior_memory): Update.
17047 * linux-low.h (struct linux_target_ops): Change type of breakpoint
17048 to unsigned char *.
17049 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
17050 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
17051 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
17052 linux-s390-low.c, linux-sh-low.c: Update for changes in
17053 read_inferior_memory and the_low_target->breakpoint.
17055 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
17057 * Makefile.in (SFILES): Add linux-ppc64-low.c.
17058 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
17059 * configure.srv: Add powerpc64-*-linux*.
17060 * linux-ppc64-low.c: New file.
17062 2005-05-23 Orjan Friberg <orjanf@axis.com>
17064 * linux-cris-low.c: New file with support for CRIS.
17065 * linux-crisv32-low.c: Ditto for CRISv32.
17066 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
17067 (clean): Add reg-cris.c and reg-crisv32.c.
17068 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
17069 reg-crisv32.o, and reg-crisv32.c to make rules.
17070 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
17071 recognized targets.
17073 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
17075 * linux-low.c (fetch_register): Ensure buffer size is a multiple
17076 of sizeof (PTRACE_XFER_TYPE).
17077 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
17079 2005-05-12 Orjan Friberg <orjanf@axis.com>
17081 * target.h (struct target_ops): Add insert_watchpoint,
17082 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
17083 pointers for hardware watchpoint support.
17084 * linux-low.h (struct linux_target_ops): Ditto.
17085 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
17086 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
17087 to linux_target_ops.
17088 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
17090 * server.c (main): Recognize 'Z' and 'z' packets.
17092 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
17094 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
17095 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
17096 (the_low_target): Add new members.
17098 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
17100 * proc-service.c (ps_lgetregs): Search all_processes instead of
17103 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
17105 * server.c (start_inferior): Change return type to int.
17106 (attach_inferior): Change sigptr to int *.
17107 (handle_v_cont, handle_v_requests): Change signal to int *.
17108 (main): Change signal to int.
17110 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
17112 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
17113 * configure.srv: Add m32r*-*-linux*.
17114 * linux-m32r-low.c: New file.
17116 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
17118 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
17120 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17122 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
17123 Take unsigned long arguments for PIDs.
17124 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
17125 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
17126 (wait_for_sigstop, linux_resume_one_process)
17127 (regsets_fetch_inferior_registers, linux_send_signal)
17128 (linux_read_auxv): Likewise. Update the types of variables holding
17129 PIDs. Update format string specifiers.
17130 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
17131 * remote-utils.c (prepare_resume_reply): Likewise.
17132 * server.c (cont_thread, general_thread, step_thread)
17133 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
17135 (handle_query): Update format specifiers.
17136 (handle_v_cont, main): Use strtoul for thread IDs.
17137 * server.h (struct inferior_list_entry): Use unsigned long for ID.
17138 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
17139 (general_thread, step_thread, thread_from_wait)
17140 (old_thread_from_wait): Update.
17141 * target.h (struct thread_resume): Use unsigned long for THREAD.
17142 (struct target_ops): Use unsigned long for arguments to attach and
17145 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
17147 * acinclude.m4: Include bfd/bfd.m4 directly.
17148 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
17149 <agriffis@toolchain.org>.
17150 * aclocal.m4, configure: Regenerated.
17152 2005-01-07 Andrew Cagney <cagney@gnu.org>
17154 * configure.ac: Rename configure.in, require autoconf 2.59.
17155 * configure: Re-generate.
17157 2004-12-08 Daniel Jacobowitz <dan@debian.org>
17159 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
17160 LIBS when finished.
17161 * aclocal.m4: Regenerated.
17162 * configure: Regenerated.
17164 2004-11-21 Andreas Schwab <schwab@suse.de>
17166 * linux-m68k-low.c (m68k_num_gregs): Define.
17167 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
17168 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
17169 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
17170 (m68k_breakpoint_at): New. Add to the_low_target.
17172 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
17173 srv_linux_thread_db to yes.
17175 2004-10-20 Joel Brobecker <brobecker@gnat.com>
17177 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
17178 (ARCH_SET_FS): Likewise.
17179 (ARCH_GET_FS): Likewise.
17180 (ARCH_GET_GS): Likewise.
17182 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17184 * linux-i386-low.c (ps_get_thread_area): New.
17185 * linux-x86-64-low.c (ps_get_thread_area): New.
17186 * linux-low.c: Include <sys/syscall.h>.
17187 (linux_kill_one_process): Don't kill the first thread here.
17188 (linux_kill): Kill the first thread here.
17189 (kill_lwp): New function.
17190 (send_sigstop, linux_send_signal): Use it.
17191 * proc-service.c: Clean up #ifdefs.
17192 (fpregset_info): Delete.
17193 (ps_lgetregs): Update and enable implementation.
17194 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
17196 * remote-utils.c (struct sym_cache, symbol_cache): New.
17197 (input_interrupt): Print a clearer message.
17198 (async_io_enabled): New variable.
17199 (enable_async_io, disable_async_io): Use it. Update comments.
17200 (look_up_one_symbol): Use the symbol cache.
17201 * thread-db.c (thread_db_look_up_symbols): New function.
17202 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
17204 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17206 * configure.in: Test for -rdynamic.
17207 * configure: Regenerated.
17208 * Makefile (INTERNAL_LDFLAGS): New.
17209 (gdbserver, gdbreplay): Use it.
17211 2004-09-02 Andrew Cagney <cagney@gnu.org>
17213 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
17215 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
17217 * linux-low.c (linux_wait): Clear all_processes list also.
17219 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17221 * linux-low.c: Include <errno.h>. Remove extern declaration of
17224 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17226 * gdbreplay.c, server.h, utils.c: Update copyright years.
17228 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17230 * server.c (main): Print child status or termination signal from
17231 variable 'signal', not 'sig'.
17233 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17235 * linux-low.c (linux_read_memory): Change return type to
17236 int. Check for and return error from ptrace().
17237 * target.c (read_inferior_memory): Change return type to int. Pass
17238 back return status from the_target->read_memory().
17239 * target.h (struct target_ops): Adapt *read_memory() prototype.
17241 (read_inferior_memory): Adapt prototype.
17242 * server.c (main): Return an error packet if
17243 read_inferior_memory() returns an error.
17245 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
17247 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17248 Unify with other clean targets.
17250 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17252 * server.c (handle_v_cont): Call set_desired_inferior.
17254 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17256 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17258 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17260 * linux-low.c (linux_wait): Unblock async I/O.
17261 (linux_resume): Block and enable async I/O.
17262 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17263 * server.h (block_async_io, unblock_async_io): Add prototypes.
17265 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17267 * remote-utils.c (remote_open): Print a status notice after
17268 opening a TCP port.
17269 * server.c (attach_inferior): Print a status notice after
17272 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17274 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17276 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
17278 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17280 * server.c, target.h: Update copyright years.
17282 2004-02-25 Roland McGrath <roland@redhat.com>
17284 * target.h (struct target_ops): New member `read_auxv'.
17285 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17286 * linux-low.c (linux_read_auxv): New function.
17287 (linux_target_ops): Initialize `read_auxv' member to that.
17289 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17291 Committed by Jim Blandy <jimb@redhat.com>.
17293 * linux-s390-low.c (s390_num_regs): Update.
17294 (s390_regmap): Remove control registers. Use __s390x__ predefine
17295 instead of GPR_SIZE to distiguish s390 and s390x targets.
17297 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
17299 * linux-low.c: Update copyright year.
17300 (check_removed_breakpoint): Clear pending_is_breakpoint.
17301 (linux_set_resume_request, linux_queue_one_thread)
17302 (resume_status_pending_p): New functions.
17303 (linux_continue_one_thread): Use process->resume.
17304 (linux_resume): Only resume threads if there are no pending events.
17305 * linux-low.h (struct process_info): Add resume request
17308 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
17310 * regcache.c (new_register_cache): Clear the allocated register
17311 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17313 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
17315 * linux-low.c (linux_resume): Take a struct thread_resume *
17317 (linux_wait): Update call.
17318 (resume_ptr): New static variable.
17319 (linux_continue_one_thread): Renamed from
17320 linux_continue_one_process. Use resume_ptr.
17321 (linux_resume): Use linux_continue_one_thread.
17322 * server.c (handle_v_cont, handle_v_requests): New functions.
17323 (myresume): New function.
17324 (main): Handle 'v' case.
17325 * target.h (struct thread_resume): New type.
17326 (struct target_ops): Change argument of "resume" to struct
17328 (myresume): Delete macro.
17330 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17332 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17333 (uninstall): Support DESTDIR.
17335 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17337 * configure.srv: Add xscale*linux copy of arm*linux entry.
17339 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
17341 * linux-arm-low.c (arm_reinsert_addr): New function.
17342 (the_low_target): Add arm_reinsert_addr.
17344 2003-07-08 Mark Kettenis <kettenis@gnu.org>
17346 * mem-break.c: Remove whitespace at end of file.
17348 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17350 * configure.in: Check whether we need to prototype strerror.
17351 * server.h: Optionally prototype strerror.
17352 * gdbreplay.c (perror_with_name): Use strerror.
17353 * linux-low.c (linux_attach_lwp): Use strerror.
17354 * utils.c (perror_with_name): Use strerror.
17355 * config.in, configure: Regenerated.
17357 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17359 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17360 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17362 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
17364 * Makefile.in (SFILES): Update.
17365 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17366 low-sun3.c: Remove files.
17368 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
17370 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17371 (linux_detach_one_process, linux_detach): New functions.
17372 (linux_target_ops): Add linux_detach.
17373 * server.c (main): Handle 'D' packet.
17374 * target.h (struct target_ops): Add "detach" member.
17375 (detach_inferior): Define.
17377 2003-06-13 Mark Kettenis <kettenis@gnu.org>
17379 From Kelley Cook <kelleycook@wideopenwest.com>:
17380 * configure.srv: Accept i[34567]86 variants.
17382 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
17384 * linux-low.c (linux_wait_for_event): Correct comment typos.
17385 (linux_resume_one_process): Call check_removed_breakpoint.
17386 (linux_send_signal): New function.
17387 (linux_target_ops): Add linux_send_signal.
17388 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17390 * target.h (struct target_ops): Add send_signal.
17392 2003-05-29 Jim Blandy <jimb@redhat.com>
17394 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17395 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17396 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17397 away part of the register's value.
17399 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
17401 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17402 (linux_wait_for_event, linux_init_signals): Likewise.
17404 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
17406 * configure.in: Check for stdlib.h.
17407 * configure: Regenerated.
17408 * config.in: Regenerated.
17410 2003-01-04 Andreas Schwab <schwab@suse.de>
17412 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17414 2003-01-02 Andrew Cagney <ac131313@redhat.com>
17416 * Makefile.in: Remove obsolete code.
17418 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
17420 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17421 defined(PT_FPR0_HI).
17423 2002-11-17 Stuart Hughes <seh@zee2.com>
17425 * linux-arm-low.c (arm_num_regs): Increase.
17426 (arm_regmap): Include status register.
17428 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
17430 * linux-low.c (register_addr): Remove incorrect -1 check.
17432 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
17434 * linux-low.c (linux_create_inferior): Call setpgid. Return
17436 (unstopped_p, linux_signal_pid): Remove.
17437 (linux_target_ops): Remove linux_signal_pid.
17438 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17439 global instead of target method.
17440 * target.h (struct target_ops): Remove signal_pid. Update comment
17441 for create_inferior.
17442 * server.c (signal_pid): New variable.
17443 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
17444 gdbserver. Set the child to be the foreground process group.
17445 (attach_inferior): Set signal_pid.
17447 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
17449 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17451 2002-08-20 Jim Blandy <jimb@redhat.com>
17453 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17456 2002-08-01 Andrew Cagney <cagney@redhat.com>
17458 * Makefile.in: Make chill references obsolete.
17460 2002-07-24 Kevin Buettner <kevinb@redhat.com>
17462 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17463 * configure: Regenerate.
17464 * config.in: Regenerate.
17466 2002-07-09 David O'Brien <obrien@FreeBSD.org>
17468 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17469 (perror_with_name, remote_close, remote_open, expect, play): Static.
17471 2002-07-04 Michal Ludvig <mludvig@suse.cz>
17473 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17474 byte offsets instead of an array of indexes.
17475 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17477 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
17479 * regcache.c: Add comment.
17481 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
17483 * thread-db.c: New file.
17484 * proc-service.c: New file.
17485 * acinclude.m4: New file.
17486 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17487 proc-service.o, and thread-db.o.
17488 (linux-low.o): Add USE_THREAD_DB.
17489 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17490 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17491 * aclocal.m4: Regenerated.
17492 * config.in: Regenerated.
17493 * configure: Regenerated.
17494 * configure.in: Check for proc_service.h, sys/procfs.h,
17495 thread_db.h, and linux/elf.h headrs.
17496 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17497 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17498 Check for -lthread_db and thread support.
17499 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17500 PowerPC, and SuperH.
17501 * i387-fp.c: Constify arguments.
17502 * i387-fp.h: Likewise.
17503 * inferiors.c: (struct thread_info): Renamed from
17504 `struct inferior_info'. Remove PID member. Use generic inferior
17505 list header. All uses updated.
17506 (inferiors, signal_pid): Removed.
17507 (all_threads): New variable.
17508 (get_thread): Define.
17509 (add_inferior_to_list): New function.
17510 (for_each_inferior): New function.
17511 (change_inferior_id): New function.
17512 (add_inferior): Removed.
17513 (remove_inferior): New function.
17514 (add_thread): New function.
17515 (free_one_thread): New function.
17516 (remove_thread): New function.
17517 (clear_inferiors): Use for_each_inferior and free_one_thread.
17518 (find_inferior): New function.
17519 (find_inferior_id): New function.
17520 (inferior_target_data): Update argument type.
17521 (set_inferior_target_data): Likewise.
17522 (inferior_regcache_data): Likewise.
17523 (set_inferior_regcache_data): Likewise.
17524 * linux-low.c (linux_bp_reinsert): Remove.
17525 (all_processes, stopping_threads, using_thrads)
17526 (struct pending_signals, debug_threads, pid_of): New.
17527 (inferior_pid): Replace with macro.
17528 (struct inferior_linux_data): Remove.
17529 (get_stop_pc, add_process): New functions.
17530 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17531 Use add_process and add_thread.
17532 (linux_attach_lwp): New function, based on old linux_attach. Use
17533 add_process and add_thread. Set stop_expected for new threads.
17534 (linux_attach): New function.
17535 (linux_kill_one_process): New function.
17536 (linux_kill): Kill all LWPs.
17537 (linux_thread_alive): Use find_inferior_id.
17538 (check_removed_breakpoints, status_pending_p): New functions.
17539 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17540 Update. Use WNOHANG. Wait for cloned processes also. Update process
17541 struct for the found process.
17542 (linux_wait_for_event): New function.
17543 (linux_wait): Use it. Support LWPs.
17544 (send_sigstop, wait_for_sigstop, stop_all_processes)
17545 (linux_resume_one_process, linux_continue_one_process): New functions.
17546 (linux_resume): Support LWPs.
17547 (REGISTER_RAW_SIZE): Remove.
17548 (fetch_register): Use register_size instead. Call supply_register.
17549 (usr_store_inferior_registers): Likewise. Call collect_register.
17550 Fix recursive case.
17551 (regsets_fetch_inferior_registers): Improve error message.
17552 (regsets_store_inferior_registers): Add debugging.
17553 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17554 (unstopped_p, linux_signal_pid): New functions.
17555 (linux_target_ops): Add linux_signal_pid.
17556 (linux_init_signals): New function.
17557 (initialize_low): Call it. Initialize using_threads.
17558 * regcache.c (inferior_regcache_data): Add valid
17560 (get_regcache): Fetch registers lazily. Add fetch argument
17561 and update all callers.
17562 (regcache_invalidate_one, regcache_invalidate): New
17564 (new_register_cache): Renamed from create_register_cache.
17565 Return the new regcache.
17566 (free_register_cache): Change argument to a void *.
17567 (registers_to_string, registers_from_string): Call get_regcache
17568 with fetch flag set.
17569 (register_data): Make static. Pass fetch flag to get_regcache.
17570 (supply_register): Call get_regcache with fetch flag clear.
17571 (collect_register): Call get_regcache with fetch flag set.
17572 (collect_register_as_string): New function.
17573 * regcache.h: Update.
17574 * remote-utils.c (putpkt): Flush after debug output and use
17576 Handle input interrupts while waiting for an ACK.
17577 (input_interrupt): Use signal_pid method.
17578 (getpkt): Flush after debug output and use stderr.
17579 (outreg): Use collect_register_as_string.
17580 (new_thread_notify, dead_thread_notify): New functions.
17581 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17582 and general_thread.
17583 (look_up_one_symbol): Flush after debug output.
17584 * server.c (step_thread, server_waiting): New variables.
17585 (start_inferior): Don't use signal_pid. Update call to mywait.
17586 (attach_inferior): Update call to mywait.
17587 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17588 (main): Don't fetch/store registers explicitly. Use
17589 set_desired_inferior. Support proposed ``Hs'' packet. Update
17591 * server.h: Update.
17592 (struct inferior_list, struct_inferior_list_entry): New.
17593 * target.c (set_desired_inferior): New.
17594 (write_inferior_memory): Constify.
17595 (mywait): New function.
17596 * target.h: Update.
17597 (struct target_ops): New signal_pid method.
17598 (mywait): Removed macro, added prototype.
17600 * linux-low.h (regset_func): Removed.
17601 (regset_fill_func, regset_store_func): New.
17602 (enum regset_type): New.
17603 (struct regset_info): Add type field. Use new operation types.
17604 (struct linux_target_ops): stop_pc renamed to get_pc.
17605 Add decr_pc_after_break and breakpoint_at.
17606 (get_process, get_thread_proess, get_process_thread)
17607 (strut process_info, all_processes, linux_attach_lwp)
17608 (thread_db_init): New.
17610 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17611 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17612 (the_low_target): Add new members.
17613 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17614 (i386_store_fpxregset): Constify.
17615 (target_regsets): Add new kind identifier.
17616 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17617 (i386_set_pc): Add debugging.
17618 (i386_breakpoint_at): New function.
17619 (the_low_target): Add new members.
17620 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17621 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17622 (mips_breakpoint_at): New.
17623 (the_low_target): Add new members.
17624 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17625 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17626 (the_low_target): Add new members.
17627 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17628 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17629 (the_low_target): Add new members.
17630 * linux-x86-64-low.c (target_regsets): Add new kind
17633 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17635 From Martin Pool <mbp@samba.org>:
17636 * server.c (gdbserver_usage): New function.
17639 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17641 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17642 stop_at -> stop_pc.
17644 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17646 * Makefile.in: Remove obsolete code.
17648 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17650 * linux-low.c (regsets_fetch_inferior_registers),
17651 (regsets_store_inferior_registers): Removed cast to int from
17653 * regcache.h: Added declaration of struct inferior_info.
17655 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17657 * inferiors.c (struct inferior_info): Add regcache_data.
17658 (add_inferior): Call create_register_cache.
17659 (clear_inferiors): Call free_register_cache.
17660 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17661 * regcache.c (struct inferior_regcache_data): New.
17662 (registers): Remove.
17663 (get_regcache): New function.
17664 (create_register_cache, free_register_cache): New functions.
17665 (set_register_cache): Don't initialize the register cache here.
17666 (registers_to_string, registers_from_string, register_data): Call
17668 * regcache.h: Add prototypes.
17669 * server.h: Likewise.
17671 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17673 * mem-break.c: New file.
17674 * mem-break.h: New file.
17675 * Makefile.in: Add mem-break.o rule; update server.h
17677 * inferiors.c (struct inferior_info): Add target_data
17679 (clear_inferiors): Free target_data member if set.
17680 (inferior_target_data, set_inferior_target_data): New functions.
17681 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17682 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17683 * linux-low.c (linux_bp_reinsert): New variable.
17684 (struct inferior_linux_data): New.
17685 (linux_create_inferior): Use set_inferior_target_data.
17686 (linux_attach): Likewise. Call add_inferior.
17687 (linux_wait_for_one_inferior): New function.
17688 (linux_wait): Call it.
17689 (linux_write_memory): Add const.
17690 (initialize_low): Call set_breakpoint_data.
17691 * linux-low.h (struct linux_target_ops): Add breakpoint
17693 * server.c (attach_inferior): Remove extra add_inferior
17695 * server.h: Include mem-break.h. Update inferior.c
17697 * target.c (read_inferior_memory)
17698 (write_inferior_memory): New functions.
17699 * target.h (read_inferior_memory)
17700 (write_inferior_memory): Change macros to prototypes.
17701 (struct target_ops): Update comments. Add const to write_memory
17704 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17706 * linux-low.c (usr_store_inferior_registers): Support
17707 registers which are allowed to fail to store.
17708 * linux-low.h (linux_target_ops): Likewise.
17709 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17710 (ppc_cannot_store_register): FPSCR may not be storable.
17712 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17714 * server.h: Include <string.h> if HAVE_STRING_H.
17715 * ChangeLog: Correct paths in last ChangeLog entry.
17717 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17719 * linux-low.h: Remove obsolete prototypes.
17720 (struct linux_target_ops): New.
17721 (extern the_low_target): New.
17722 * linux-low.c (num_regs, regmap): Remove declarations.
17723 (register_addr): Use the_low_target explicitly.
17724 (fetch_register): Likewise.
17725 (usr_fetch_inferior_registers): Likewise.
17726 (usr_store_inferior_registers): Likewise.
17727 * linux-arm-low.c (num_regs): Remove.
17728 (arm_num_regs): Define.
17729 (arm_regmap): Renamed from regmap, made static.
17730 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17732 (arm_cannot_store_register): Renamed from cannot_store_register,
17734 (the_low_target): New.
17735 * linux-i386-low.c (num_regs): Remove.
17736 (i386_num_regs): Define.
17737 (i386_regmap): Renamed from regmap, made static.
17738 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17740 (i386_cannot_store_register): Renamed from cannot_store_register,
17742 (the_low_target): New.
17743 * linux-ia64-low.c (num_regs): Remove.
17744 (ia64_num_regs): Define.
17745 (ia64_regmap): Renamed from regmap, made static.
17746 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17748 (ia64_cannot_store_register): Renamed from cannot_store_register,
17750 (the_low_target): New.
17751 * linux-m68k-low.c (num_regs): Remove.
17752 (m68k_num_regs): Define.
17753 (m68k_regmap): Renamed from regmap, made static.
17754 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17756 (m68k_cannot_store_register): Renamed from cannot_store_register,
17758 (the_low_target): New.
17759 * linux-mips-low.c (num_regs): Remove.
17760 (mips_num_regs): Define.
17761 (mips_regmap): Renamed from regmap, made static.
17762 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17764 (mips_cannot_store_register): Renamed from cannot_store_register,
17766 (the_low_target): New.
17767 * linux-ppc-low.c (num_regs): Remove.
17768 (ppc_num_regs): Define.
17769 (ppc_regmap): Renamed from regmap, made static.
17770 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17772 (ppc_cannot_store_register): Renamed from cannot_store_register,
17774 (the_low_target): New.
17775 * linux-s390-low.c (num_regs): Remove.
17776 (s390_num_regs): Define.
17777 (s390_regmap): Renamed from regmap, made static.
17778 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17780 (s390_cannot_store_register): Renamed from cannot_store_register,
17782 (the_low_target): New.
17783 * linux-sh-low.c (num_regs): Remove.
17784 (sh_num_regs): Define.
17785 (sh_regmap): Renamed from regmap, made static.
17786 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17788 (sh_cannot_store_register): Renamed from cannot_store_register,
17790 (the_low_target): New.
17791 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17792 (the_low_target): New.
17794 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17796 * Makefile.in: Add stamp-h target.
17797 * configure.in: Create stamp-h.
17798 * configure: Regenerated.
17800 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17802 * inferiors.c: New file.
17803 * target.c: New file.
17804 * target.h: New file.
17805 * Makefile.in: Add target.o and inferiors.o. Update
17807 * linux-low.c (inferior_pid): New static variable,
17808 moved from server.c.
17809 (linux_create_inferior): Renamed from create_inferior.
17810 Call add_inferior. Return 0 on success instead of a PID.
17811 (linux_attach): Renamed from myattach.
17812 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17813 (linux_thread_alive): Renamed from mythread_alive.
17814 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17816 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17817 (regsets_store_inferior_registers): Correct error message.
17818 Add missing ``return 0''.
17819 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17820 (linux_store_registers): Renamed from store_inferior_registers.
17821 (linux_read_memory): Renamed from read_inferior_memory.
17822 (linux_write_memory): Renamed from write_inferior_memory.
17823 (linux_target_ops): New structure.
17824 (initialize_low): Call set_target_ops ().
17825 * remote-utils.c (unhexify): New function.
17826 (hexify): New function.
17827 (input_interrupt): Send signals to ``signal_pid''.
17828 * server.c (inferior_pid): Remove.
17829 (start_inferior): Update create_inferior call.
17830 (attach_inferior): Call add_inferior.
17831 (handle_query): New function.
17832 (main): Call handle_query for `q' packets.
17833 * server.h: Include "target.h". Remove obsolete prototypes.
17834 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17836 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17838 * Makefile.in: Add WARN_CFLAGS. Update configury
17840 * configure.in: Check for <string.h>
17841 * configure: Regenerate.
17842 * config.in: Regenerate.
17843 * gdbreplay.c: Include needed system headers.
17844 (remote_open): Remove strchr prototype.
17845 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17846 * regcache.c (supply_register): Change buf argument to const void *.
17847 (supply_register_by_name): Likewise.
17848 (collect_register): Change buf argument to void *.
17849 (collect_register_by_name): Likewise.
17850 * regcache.h: Add missing prototypes.
17851 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17852 * server.c (handle_query): New function.
17853 (attached): New static variable, moved out of main.
17854 (main): Quiet longjmp clobber warnings.
17855 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17856 * utils.c (error): Remove NORETURN.