fde6abbecb3bbf15fc3eccce29df9e949856636d
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2
3 * Makefile.in: Add safe-strerror.c.
4 * configure: Regenerate.
5 * configure.ac: Don't source common.host.
6
7 2019-11-15 Christian Biesinger <cbiesinger@google.com>
8
9 * config.in: Regenerate.
10 * configure: Regenerate.
11
12 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
13
14 * ax.c (ax_printf): Handle size_t_arg.
15
16 2019-11-06 Christian Biesinger <cbiesinger@google.com>
17
18 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
19 * mi/mi-main.c (output_cores): Likewise.
20 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
21 (linux_xfer_osdata_modules): Likewise.
22 * remote.c (register_remote_support_xml): Likewise.
23 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
24 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
25
26 2019-11-01 Christian Biesinger <cbiesinger@google.com>
27
28 * configure: Regenerate.
29 * configure.ac: Remove check for strerror_r.
30
31 2019-10-31 Christian Biesinger <cbiesinger@google.com>
32
33 * config.in: Regenerate.
34 * configure: Regenerate.
35 * configure.ac: Also check for strerror_r.
36
37 2019-10-31 Christian Biesinger <cbiesinger@google.com>
38
39 * ax.h (debug_agent): Remove duplicate declaration.
40
41 2019-10-26 Tom de Vries <tdevries@suse.de>
42
43 * linux-aarch64-low.c: Fix typos in comments.
44 * linux-arm-low.c: Same.
45 * linux-low.c: Same.
46 * linux-ppc-low.c: Same.
47 * proc-service.c: Same.
48 * regcache.h: Same.
49 * server.c: Same.
50 * tracepoint.c: Same.
51 * win32-low.c: Same.
52
53 2019-10-25 Tom Tromey <tromey@adacore.com>
54
55 * utils.c (xstrdup): Remove.
56
57 2019-10-23 Tom Tromey <tom@tromey.com>
58
59 * configure, config.in: Rebuild.
60
61 2019-10-23 Tom Tromey <tom@tromey.com>
62
63 * configure: Rebuild.
64 * acinclude.m4: Use m4_include, not sinclude.
65
66 2019-10-17 Tom Tromey <tromey@adacore.com>
67
68 * configure: Rebuild.
69 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
70 in AC_CONFIG_FILES invocation.
71 * Makefile.in (stamp-h, Makefile): Use new-style config.status
72 invocation.
73
74 2019-10-16 Christian Biesinger <cbiesinger@google.com>
75
76 * server.c: Include xml-builtin.h.
77 (get_xml_features): Don't declare xml_builtins here.
78
79 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
80
81 * Makefile.in: Remove references to vec-ipa.o.
82
83 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
84
85 * Makefile.in: Remove references to vec.c.
86
87 2019-10-02 Christian Biesinger <cbiesinger@google.com>
88
89 * server.c (server_waiting): Change to bool.
90 (extended_protocol): Likewise.
91 (response_needed): Likewise.
92 (exit_requested): Likewise.
93 (run_once): Likewise.
94 (report_no_resumed): Likewise.
95 (non_stop): Likewise.
96 (disable_packet_vCont): Likewise.
97 (disable_packet_Tthread): Likewise.
98 (disable_packet_qC): Likewise.
99 (disable_packet_qfThreadInfo): Likewise.
100 (handle_general_set): Update.
101 (handle_detach): Update.
102 (handle_monitor_command): Update.
103 (handle_query): Update.
104 (captured_main): Update.
105 (process_serial_event): Update.
106 * server.h (server_waiting): Change to bool.
107 (disable_packet_vCont): Likewise.
108 (disable_packet_Tthread): Likewise.
109 (disable_packet_qC): Likewise.
110 (disable_packet_qfThreadInfo): Likewise.
111 (run_once): Likewise.
112 (non_stop): Likewise.
113 * target.c (target_stop_and_wait): Update.
114
115 2019-10-02 Tom Tromey <tromey@adacore.com>
116
117 * Makefile.in (SFILES): Add common-inferior.c.
118 (OBS): Add common-inferior.o.
119 * server.c (startup_with_shell): Don't define.
120
121 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
122
123 * linux-low.c (linux_low_read_btrace): Update for change to
124 std::vector.
125
126 2019-09-20 Christian Biesinger <cbiesinger@google.com>
127
128 * debug.c (debug_threads): Remove comment in favor of the header.
129 * debug.h (using_threads): Add declaration.
130 (debug_threads): Add comment.
131 * linux-aarch64-low.c: Include debug.h and remove declaration of
132 debug_threads.
133 * nto-low.c: Likewise.
134 * remote-utils.c: Likewise.
135 * thread-db.c: Likewise.
136
137 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
138
139 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
140 and powerpc-cell64l-ipa.o.
141 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
142 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
143 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
144 (spu*-*-*): Remove.
145
146 * spu-low.c: Remove file.
147
148 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
149 (parse_spufs_run): Remove.
150 (ppc_get_pc): Remove Cell/B.E. support.
151 (ppc_set_pc): Likewise.
152 (ppc_breakpoint_at): Likewise.
153 (ppc_arch_setup): Likewise.
154 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
155 tdesc_powerpc_cell32l.
156 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
157 or init_registers_powerpc_cell32l.
158 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
159 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
160 or init_registers_powerpc_cell32l.
161 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
162 (init_registers_powerpc_cell32l): Remove prototype.
163 (init_registers_powerpc_cell64l): Likewise.
164
165 * target.h (struct target_ops): Remove qxfer_spu member.
166 * server.c (handle_qxfer_spu): Remove.
167 (qxfer_packets): Remove entry for "spu".
168 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
169 * linux-low.c (SPUFS_MAGIC): Remove.
170 (spu_enumerate_spu_ids): Remove.
171 (linux_qxfer_spu): Remove.
172 (linux_target_ops): Remove qxfer_spu member.
173 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
174 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
175 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
176
177 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
178
179 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
180 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
181 * config.in: Regenerate.
182 * configure: Regenerate.
183
184 2019-08-15 Tom Tromey <tromey@adacore.com>
185
186 * target.c (target_write_memory): Use gdb::byte_vector.
187
188 2019-08-15 Tom Tromey <tromey@adacore.com>
189
190 * tracepoint.c (write_inferior_data_pointer)
191 (write_inferior_integer, write_inferior_int8)
192 (write_inferior_uinteger, m_tracepoint_action_download)
193 (r_tracepoint_action_download, x_tracepoint_action_download)
194 (l_tracepoint_action_download, clear_inferior_trace_buffer)
195 (download_agent_expr, download_tracepoint_1)
196 (download_trace_state_variables, upload_fast_traceframes): Update.
197 * server.c (gdb_write_memory): Update.
198 * remote-utils.c (relocate_instruction): Update.
199 * proc-service.c (ps_pdwrite): Update.
200 * mem-break.c (remove_memory_breakpoint)
201 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
202 (uninsert_fast_tracepoint_jumps_at)
203 (reinsert_fast_tracepoint_jumps_at): Update.
204 * linux-x86-low.c (append_insns)
205 (i386_install_fast_tracepoint_jump_pad)
206 (amd64_write_goto_address, i386_write_goto_address): Update.
207 * linux-s390-low.c (append_insns, s390_write_goto_address):
208 Update.
209 * linux-ppc-low.c (ppc_relocate_instruction)
210 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
211 (ppc_write_goto_address): Update.
212 * linux-aarch64-low.c (append_insns): Update.
213 * target.h (struct target_ops): Update.
214 (write_inferior_memory): Don't declare.
215 * target.c (target_write_memory): Rename from
216 write_inferior_memory. Remove old target_write_memory.
217
218 2019-08-15 Tom Tromey <tromey@adacore.com>
219
220 * target.c (write_inferior_memory): Use std::vector.
221
222 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
223
224 PR build/24886
225 * configure.ac: Drop enable-libmcheck support.
226 * configure, config.in: Rebuild.
227 * acinclude.m4: Don't include it.
228
229 2019-07-19 Alan Hayward <alan.hayward@arm.com>
230
231 * configure.srv: Remove Arm xml files.
232
233 2019-07-19 Alan Hayward <alan.hayward@arm.com>
234
235 * configure.srv: Add new files. Remove xml generated files.
236 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
237 registers.
238 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
239 * linux-aarch32-tdesc.c: New file.
240 * linux-aarch32-tdesc.h: New file.
241 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
242 * linux-arm-low.c (init_registers_arm, tdesc_arm)
243 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
244 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
245 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
246 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
247 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
248 (arm_read_description): Call arm_linux_read_description.
249 (initialize_low_arch): Don't init registers.
250 * linux-arm-tdesc.c: New file.
251 * linux-arm-tdesc.h: New file.
252
253 2019-07-10 Alan Hayward <alan.hayward@arm.com>
254
255 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
256 Move counter inside for.
257 (arm_read_description): Check ptrace earlier.
258 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
259
260 2019-07-09 Tom Tromey <tom@tromey.com>
261
262 * configure: Rebuild.
263 * configure.ac: Change common to gdbsupport.
264 * acinclude.m4: Change common to gdbsupport.
265 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
266 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
267 common to gdbsupport.
268 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
269 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
270 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
271 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
272 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
273 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
274 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
275 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
276 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
277 common to gdbsupport.
278
279 2019-07-04 Alan Hayward <alan.hayward@arm.com>
280
281 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
282 defines.
283 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
284
285 2019-07-04 Alan Hayward <alan.hayward@arm.com>
286
287 * configure.srv: Remove legacy xml.
288 * linux-aarch64-low.c (initialize_low_arch): Remove
289 initialize_low_tdesc call.
290 * linux-aarch64-tdesc-selftest.c: Remove file.
291 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
292 * linux-x86-low.c (initialize_low_arch): Remove
293 initialize_low_tdesc call.
294 * linux-x86-tdesc-selftest.c: Remove file.
295 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
296
297 2019-06-20 Tom de Vries <tdevries@suse.de>
298
299 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
300 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
301
302 2019-06-19 Tom de Vries <tdevries@suse.de>
303
304 * debug.h (debug_write): Change return type to ssize_t.
305 * debug.c (debug_write): Same.
306
307 2019-06-14 Tom Tromey <tom@tromey.com>
308
309 * configure.ac: Use new path to gnulib.
310 * configure: Rebuild.
311 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
312 to gnulib.
313
314 2019-06-11 Tom Tromey <tom@tromey.com>
315
316 * Makefile.in (SFILES): Add alloc.c.
317 (OBS): Add alloc.o.
318 (IPA_OBJS): Add alloc-ipa.o.
319 (alloc-ipa.o): New target.
320 (%.o: ../%.c): New pattern rule.
321
322 2019-06-10 Tom Tromey <tromey@adacore.com>
323
324 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
325 end warning with a newline.
326 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
327 newline.
328 * thread-db.c (attach_thread): Don't end warning with a newline.
329 (thread_db_notice_clone): Likewise.
330 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
331 newline.
332 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
333 end warning with a newline.
334
335 2019-06-04 Pedro Alves <palves@redhat.com>
336
337 * server.c (captured_main): Use make_unique_xstrdup.
338
339 2019-06-02 Tom Tromey <tom@tromey.com>
340
341 * gdbreplay.c (fromhex): Remove.
342 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
343
344 2019-05-29 Tom Tromey <tromey@adacore.com>
345
346 * configure: Rebuild.
347
348 2019-05-06 Kevin Buettner <kevinb@redhat.com>
349
350 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
351 sign extension code on 32-bit builds.
352
353 2019-05-03 Eli Zaretskii <eliz@gnu.org>
354
355 * remote-utils.c:
356 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
357
358 2019-04-19 Tom Tromey <tom@tromey.com>
359
360 * server.c (struct vstop_notif): Derive from notif_event.
361 <base>: Remove.
362 (queue_stop_reply): Update.
363 (remove_all_on_match_ptid): Change type. Rewrite.
364 (discard_queued_stop_replies): Rewrite.
365 (in_queued_stop_replies_ptid): Change type.
366 (in_queued_stop_replies): Rewrite.
367 (notif_stop): Update.
368 (queue_stop_reply_callback): Update.
369 (captured_main): Don't call initialize_notif.
370 (push_stop_notification): Update.
371 * notif.c (notif_write_event, handle_notif_ack)
372 (notif_event_enque, notif_push): Update.
373 (notif_event_xfree, initialize_notif): Remove.
374 * notif.h (struct notif_event): Include <list>, not
375 "common/queue.h".
376 (struct notif_server) <queue>: Now a std::list.
377 (notif_event_p): Remove typedef.
378 (initialize_notif): Don't declare.
379 (struct notif_event): Add virtual destructor.
380
381 2019-04-17 Alan Hayward <alan.hayward@arm.com>
382
383 * ax.c (ax_vdebug): Call debug_printf.
384 * debug.c (debug_write): New function.
385 * debug.h (debug_write): New declaration.
386 * linux-low.c (sigchld_handler): Call debug_write.
387
388 2019-04-17 Alan Hayward <alan.hayward@arm.com>
389
390 * debug.c (debug_set_output): New function.
391 (debug_vprintf): Send output to debug_file.
392 (debug_flush): Likewise.
393 * debug.h (debug_set_output): New declaration.
394 * server.c (handle_monitor_command): Add debug-file option.
395 (captured_main): Likewise.
396
397 2019-04-17 Alan Hayward <alan.hayward@arm.com>
398
399 * debug.c (remote_debug): Add definition.
400 * debug.h (remote_debug): Add declaration.
401 * hostio.c (remote_debug): Remove declaration.
402 * remote-utils.c (struct ui_file): Likewise.
403 (remote_debug): Likewise.
404 * remote-utils.h (remote_debug): Likewise,
405 * server.c (remote_debug): Remove definition.
406
407 2019-04-10 Kevin Buettner <kevinb@redhat.com>
408
409 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
410 when using a 64-bit gdbserver.
411
412 2019-04-09 Tom Tromey <tromey@adacore.com>
413
414 * linux-low.c (select_event_lwp): Use find_thread_in_random.
415
416 2019-04-08 Tom Tromey <tom@tromey.com>
417
418 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
419 throw.
420 (linux_resume_one_lwp): Likewise.
421
422 2019-04-08 Tom Tromey <tom@tromey.com>
423
424 * gdbreplay.c: Update.
425 * linux-low.c: Update.
426 * server.c: Update.
427
428 2019-04-08 Tom Tromey <tom@tromey.com>
429
430 * server.c: Use C++ exception handling.
431 * linux-low.c: Use C++ exception handling.
432 * gdbreplay.c: Use C++ exception handling.
433
434 2019-04-08 Tom Tromey <tom@tromey.com>
435
436 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
437 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
438 (captured_main, main): Update.
439 * gdbreplay.c (main): Update.
440
441 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
442
443 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
444 value in argument pointer, return 1 if the entry is found and 0
445 otherwise. Move comment.
446 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
447 * linux-low.h (linux_get_auxv): Declare.
448 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
449
450 2019-04-05 Tom Tromey <tromey@adacore.com>
451
452 * server.c (gdbserver_usage): Use upper-case for metasyntactic
453 variables.
454
455 2019-03-28 Alan Hayward <alan.hayward@arm.com>
456
457 * linux-low.c (AT_HWCAP2): Add define if not already included.
458
459 2019-03-26 Alan Hayward <alan.hayward@arm.com>
460
461 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
462 (aarch64_arch_setup): Call linux_get_hwcap.
463 * linux-arm-low.c (arm_get_hwcap): Remove function.
464 (arm_read_description): Call linux_get_hwcap.
465 * linux-low.c (linux_get_auxv): New function.
466 (linux_get_hwcap): Likewise.
467 (linux_get_hwcap2): Likewise.
468 * linux-low.h (linux_get_hwcap): New declaration.
469 (linux_get_hwcap2): Likewise.
470 * linux-ppc-low.c (ppc_get_auxv): Remove function.
471 (ppc_arch_setup): Call linux_get_hwcap.
472 * linux-s390-low.c (s390_get_hwcap): Remove function.
473 (s390_arch_setup): Call linux_get_hwcap.
474
475 2019-03-22 Alan Hayward <alan.hayward@arm.com>
476 Jiong Wang <jiong.wang@arm.com>
477
478 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
479 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
480 to fail.
481 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
482
483 2019-03-22 Alan Hayward <alan.hayward@arm.com>
484 Jiong Wang <jiong.wang@arm.com>
485
486 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
487 (aarch64_get_hwcap): New function.
488 (aarch64_arch_setup): Read APIA hwcap.
489
490 2019-03-22 Alan Hayward <alan.hayward@arm.com>
491 Jiong Wang <jiong.wang@arm.com>
492
493 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
494 (initialize_low_tracepoint): Likewise.
495 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
496 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
497 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
498 (aarch64_linux_read_description): Likewise.
499 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
500
501 2019-03-12 John Baldwin <jhb@FreeBSD.org>
502
503 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
504 i386_create_target_description for 'segments' parameter.
505 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
506 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
507 * win32-i386-low.c (i386_arch_setup): Likewise.
508
509 2019-03-12 Tom Tromey <tromey@adacore.com>
510
511 * linux-low.c (iterate_over_lwps): Update.
512
513 2019-03-06 Tom Tromey <tom@tromey.com>
514
515 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
516 (captured_main): Use SCOPE_EXIT.
517
518 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
519
520 * configure.srv: Use '$enable_unittest' instead of '$development'
521 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
522 case.
523
524 2019-02-27 Tom Tromey <tromey@adacore.com>
525
526 * gdbreplay.c (logchar): Handle \r\n.
527
528 2019-02-07 Alan Hayward <alan.hayward@arm.com>
529
530 * linux-low.c (linux_attach): Add process before lwp.
531 * server.c (attach_inferior): Check if already attached.
532
533 2019-02-07 Tom Tromey <tom@tromey.com>
534
535 * x86-tdesc.h: Rename include guard.
536 * x86-low.h: Add include guard.
537 * wincecompat.h: Rename include guard.
538 * win32-low.h: Add include guard.
539 * utils.h: Rename include guard.
540 * tracepoint.h: Rename include guard.
541 * tdesc.h: Rename include guard.
542 * target.h: Rename include guard.
543 * server.h: Rename include guard.
544 * remote-utils.h: Rename include guard.
545 * regcache.h: Rename include guard.
546 * nto-low.h: Rename include guard.
547 * notif.h: Add include guard.
548 * mem-break.h: Rename include guard.
549 * lynx-low.h: Add include guard.
550 * linux-x86-tdesc.h: Add include guard.
551 * linux-s390-tdesc.h: Add include guard.
552 * linux-ppc-tdesc-init.h: Add include guard.
553 * linux-low.h: Add include guard.
554 * linux-aarch64-tdesc.h: Add include guard.
555 * linux-aarch32-low.h: Add include guard.
556 * inferiors.h: Rename include guard.
557 * i387-fp.h: Rename include guard.
558 * hostio.h: Rename include guard.
559 * gdbthread.h: Rename include guard.
560 * gdb_proc_service.h: Rename include guard.
561 * event-loop.h: Rename include guard.
562 * dll.h: Rename include guard.
563 * debug.h: Rename include guard.
564 * ax.h: Rename include guard.
565
566 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
567
568 PR gdb/23985
569 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
570 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
571
572 2019-01-25 Tom Tromey <tom@tromey.com>
573
574 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
575
576 2019-01-25 Tom Tromey <tom@tromey.com>
577
578 * win32-low.c: Fix common/ includes.
579 * win32-i386-low.c: Fix common/ includes.
580 * tracepoint.c: Fix common/ includes.
581 * thread-db.c: Fix common/ includes.
582 * target.h: Fix common/ includes.
583 * symbol.c: Fix common/ includes.
584 * spu-low.c: Fix common/ includes.
585 * server.h: Fix common/ includes.
586 * server.c: Fix common/ includes.
587 * remote-utils.c: Fix common/ includes.
588 * regcache.h: Fix common/ includes.
589 * regcache.c: Fix common/ includes.
590 * nto-x86-low.c: Fix common/ includes.
591 * notif.h: Fix common/ includes.
592 * mem-break.h: Fix common/ includes.
593 * lynx-low.c: Fix common/ includes.
594 * lynx-i386-low.c: Fix common/ includes.
595 * linux-x86-tdesc-selftest.c: Fix common/ includes.
596 * linux-x86-low.c: Fix common/ includes.
597 * linux-low.c: Fix common/ includes.
598 * inferiors.h: Fix common/ includes.
599 * i387-fp.c: Fix common/ includes.
600 * hostio.c: Fix common/ includes.
601 * hostio-errno.c: Fix common/ includes.
602 * gdbthread.h: Fix common/ includes.
603 * gdbreplay.c: Fix common/ includes.
604 * fork-child.c: Fix common/ includes.
605 * event-loop.c: Fix common/ includes.
606 * ax.c:
607 (enum gdb_agent_op): Fix common/ includes.
608
609 2019-01-21 Tom Tromey <tom@tromey.com>
610
611 * tracepoint.c: Fix includes.
612 * remote-utils.c: Fix includes.
613 * linux-x86-low.c: Fix includes.
614
615 2019-01-01 Joel Brobecker <brobecker@adacore.com>
616
617 * gdbreplay.c (gdbreplay_version): Update copyright year in
618 version message.
619 * server.c (gdbserver_version): Likewise.
620
621 2018-12-05 Alan Hayward <alan.hayward@arm.com>
622
623 * linux-low.c (add_lwp): Switch ordering.
624
625 2018-11-29 Tom Tromey <tom@tromey.com>
626
627 * win32-low.c (win32_join): Take pid, not process.
628 * target.h (struct target_ops) <join>: Change argument type.
629 (join_inferior): Change argument name.
630 * spu-low.c (spu_join): Take pid, not process.
631 * server.c (handle_detach): Preserve pid before destroying
632 process.
633 * lynx-low.c (lynx_join): Take pid, not process.
634 * linux-low.c (linux_join): Take pid, not process.
635
636 2018-11-23 Alan Hayward <alan.hayward@arm.com>
637
638 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
639 (aarch64_cannot_fetch_register): Likewise.
640 (struct linux_target_ops): Update references.
641
642 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
643
644 * linux-ppc-low.c: Include nat/linux-ptrace.h.
645
646 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
647
648 * configure.srv (ipa_ppc_linux_regobj): Add
649 powerpc-isa207-htm-vsx32l-ipa.o and
650 powerpc-isa207-htm-vsx64l-ipa.o.
651 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
652 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
653 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
654 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
655 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
656 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
657 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
658 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
659 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
660 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
661 (init_registers_powerpc_isa207_htm_vsx32l)
662 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
663 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
664 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
665 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
666 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
667 (ppc_store_tm_ctarregset): New functions.
668 (ppc_regsets): Add entries for HTM regsets.
669 (ppc_arch_setup): Set htm in features struct when needed. Set
670 sizes for the HTM regsets.
671 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
672 (initialize_low_arch): Call
673 init_registers_powerpc_isa207_htm_vsx32l and
674 init_registers_powerpc_isa207_htm_vsx64l.
675 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
676 PPC_TDESC_ISA207_HTM_VSX.
677 (initialize_low_tracepoint): Call
678 init_registers_powerpc_isa207_htm_vsx32l and
679 init_registers_powerpc_isa207_htm_vsx64l.
680
681 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
682
683 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
684 rs6000/power-linux-pmu.xml to srv_xmlfiles.
685 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
686 (ppc_store_pmuregset): New functions.
687 (ppc_regsets): Add entries for ebb and pmu regsets.
688 (ppc_arch_setup): Set isa207 in features struct if the ebb and
689 pmu regsets are available. Set sizes for these regsets.
690
691 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
692
693 * configure.srv (ipa_ppc_linux_regobj): Add
694 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
695 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
696 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
697 rs6000/powerpc-isa207-vsx32l.xml, and
698 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
699 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
700 <PPC_TDESC_ISA207_VSX>: New enum value.
701 (init_registers_powerpc_isa207_vsx32l): Declare.
702 (init_registers_powerpc_isa207_vsx64l): Declare.
703 * linux-ppc-low.c (ppc_fill_tarregset): New function.
704 (ppc_store_tarregset): New function.
705 (ppc_regsets): Add entry for the TAR regset.
706 (ppc_arch_setup): Set isa207 in features struct when needed. Set
707 size for the TAR regsets.
708 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
709 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
710 and init_registers_powerpc_isa207_vsx64l.
711 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
712 (initialize_low_tracepoint): Call
713 init_registers_powerpc_isa207_vsx32l and
714 init_registers_powerpc_isa207_vsx64l.
715
716 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
717 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
718
719 * configure.srv (ipa_ppc_linux_regobj): Add
720 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
721 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
722 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
723 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
724 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
725 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
726 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
727 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
728 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
729 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
730 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
731 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
732 (ppc_hwcap): Add comment.
733 (ppc_hwcap2): New global.
734 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
735 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
736 (ppc_regsets): Add entries for the DSCR and PPR regsets.
737 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
738 when needed. Set sizes for the the DSCR and PPR regsets.
739 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
740 (initialize_low_arch): Call
741 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
742 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
743 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
744 PPC_TDESC_ISA205_PPR_DSCR_VSX.
745 (initialize_low_tracepoint): Call
746 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
747 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
748
749 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
750
751 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
752
753 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
754 Simon Marchi <simark@simark.ca>
755
756 * acinclude.m4: Include "../selftest.m4".
757 * configure: Regenerate.
758 * configure.ac: Use "GDB_AC_SELFTEST".
759 * configure.srv: Use "$enable_unittests" instead of
760 "$development" when checking whether unit tests have been
761 enabled.
762 * server.c (captured_main): Update message informing that
763 selftests have been disabled.
764
765 2018-10-04 Tom Tromey <tom@tromey.com>
766
767 * configure: Rebuild.
768
769 2018-10-04 Tom Tromey <tom@tromey.com>
770
771 * server.c (handle_status): Rename inner "thread".
772 (process_serial_event): Declare "res" in 'm' case.
773 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
774 (iterate_over_lwps): Rename inner "thread".
775 (linux_qxfer_libraries_svr4): Rename inner "len".
776 * gdbthread.h (find_thread_in_random): Rename inner "thread".
777
778 2018-10-01 Gary Benson <gbenson@redhat.com>
779
780 * gdb_proc_service.h: Moved common code to
781 common/gdb_proc_service.h.
782
783 2018-10-01 Gary Benson <gbenson@redhat.com>
784
785 * gdb_proc_service.h: Synchronize comments and whitespace with
786 GDB's version of this file.
787
788 2018-09-25 Tom Tromey <tom@tromey.com>
789
790 * configure: Rebuild.
791 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
792
793 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
794
795 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
796 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
797 ($(IPA_LIB)): Sort IPA_OBJS.
798
799 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
800
801 * Makefile.in: Remove references to $(ADD_DEPS).
802
803 2018-09-16 Tom Tromey <tom@tromey.com>
804
805 * remote-utils.c (remote_open): Use GNU style for metasyntactic
806 variables.
807 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
808 variables.
809
810 2018-09-05 Tom Tromey <tom@tromey.com>
811
812 * configure: Rebuild.
813
814 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
815
816 PR build/23399
817 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
818
819 2018-08-27 Tom Tromey <tom@tromey.com>
820
821 PR build/23087:
822 * configure: Rebuild.
823
824 2018-08-27 Tom Tromey <tom@tromey.com>
825
826 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
827 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
828 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
829 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
830 (s390x_emit_stack_adjust): Add casts to unsigned char.
831
832 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
833
834 PR gdb/23374
835 PR gdb/23375
836 * server.h (struct client_state) <disable_randomization>:
837 Initialize to 1.
838
839 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
840
841 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
842 variable.
843 (mips_supply_ptrace_register): Likewise.
844
845 2018-07-22 Tom Tromey <tom@tromey.com>
846
847 * configure: Rebuild.
848
849 2018-07-22 Tom Tromey <tom@tromey.com>
850
851 * win32-low.c (win32_create_inferior): Remove unused variables.
852 * gdbreplay.c (remote_open): Remove unused variable.
853 * remote-utils.c (remote_prepare): Remove unused variable.
854 * x86-tdesc.h (X86_TDESC_H): Define.
855 (amd64_expedite_regs): Define conditionally.
856 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
857 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
858 * remote-utils.c (readchar): Remove unused variable.
859
860 2018-07-13 Pedro Alves <palves@redhat.com>
861
862 * linux-low.c (linux_kill): Change parameter to process_info
863 pointer instead of pid. Adjust.
864 * lynx-low.c (lynx_kill): Likewise.
865 * nto-low.c (nto_kill): Likewise.
866 * spu-low.c (spu_kill): Likewise.
867 * win32-low.c (win32_kill): Likewise.
868 * server.c (handle_v_kill, kill_inferior_callback)
869 (detach_or_kill_for_exit): Adjust.
870 * target.c (kill_inferior): Change parameter to process_info
871 pointer instead of pid. Adjust.
872 * target.h (struct target_ops) <kill>: Change parameter to
873 process_info pointer instead of pid. Adjust all implementations
874 and callers.
875 (kill_inferior): Likewise.
876
877 2018-07-13 Pedro Alves <palves@redhat.com>
878
879 * linux-low.c (linux_detach, linux_join): Change parameter to
880 process_info pointer instead of pid. Adjust.
881 * lynx-low.c (lynx_detach, lynx_join): Likewise.
882 * nto-low.c (nto_detach): Likewise.
883 * spu-low.c (spu_detach, spu_join): Likewise.
884 * win32-low.c (win32_detach, win32_join): Likewise.
885 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
886 * target.h (struct target_ops) <detach, join>: Change parameter to
887 process_info pointer instead of pid. Adjust all implementations
888 and callers.
889 (detach_inferior, join_inferior): Rename 'pid' parameter to
890 'proc'.
891
892 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
893 Jan Kratochvil <jan.kratochvil@redhat.com>
894 Paul Fertser <fercerpav@gmail.com>
895 Tsutomu Seki <sekiriki@gmail.com>
896
897 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
898 (OBS): Add 'common/netstuff.o'.
899 (GDBREPLAY_OBS): Likewise.
900 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
901 (remote_open): Implement support for IPv6
902 connections.
903 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
904 and 'wspiapi.h'.
905 (handle_accept_event): Accept connections from IPv6 sources.
906 (remote_prepare): Handle IPv6-style hostnames; implement
907 support for IPv6 connections.
908 (remote_open): Implement support for printing connections from
909 IPv6 sources.
910
911 2018-07-11 Pedro Alves <palves@redhat.com>
912
913 PR gdb/23377
914 * mem-break.c (any_persistent_commands): Add process_info
915 parameter and use it instead of relying on the current process.
916 Change return type to bool.
917 * mem-break.h (any_persistent_commands): Add process_info
918 parameter and change return type to bool.
919 * server.c (handle_detach): Remove require_running_or_return call.
920 Look up the process_info for the process we're about to detach.
921 If not found, return back error to GDB. Adjust
922 any_persistent_commands call to pass down a process pointer.
923
924 2018-07-11 Pedro Alves <palves@redhat.com>
925
926 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
927 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
928 instead of collect_register_by_name.
929 * regcache.c (regcache_raw_get_unsigned_by_name): New.
930 * regcache.h (regcache_raw_get_unsigned_by_name): New.
931
932 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
933 Pedro Alves <palves@redhat.com>
934
935 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
936
937 2018-07-03 Tom Tromey <tom@tromey.com>
938
939 * linux-low.c: Update.
940 * lynx-low.c: Update.
941 * mem-break.c: Update.
942 * nto-low.c: Update.
943 * remote-utils.c: Update.
944 * server.c: Update.
945 * spu-low.c: Update.
946 * target.c: Update.
947 * win32-low.c: Update.
948
949 2018-07-03 Tom Tromey <tom@tromey.com>
950
951 * server.c: Update.
952
953 2018-07-03 Tom Tromey <tom@tromey.com>
954
955 * linux-low.c: Update.
956
957 2018-07-03 Tom Tromey <tom@tromey.com>
958
959 * target.c: Update.
960
961 2018-07-03 Tom Tromey <tom@tromey.com>
962
963 * linux-low.c: Update.
964 * linux-mips-low.c: Update.
965 * lynx-low.c: Update.
966 * nto-low.c: Update.
967 * remote-utils.c: Update.
968 * server.c: Update.
969 * spu-low.c: Update.
970 * target.c: Update.
971 * thread-db.c: Update.
972
973 2018-07-03 Tom Tromey <tom@tromey.com>
974
975 * linux-low.c: Update.
976 * linux-mips-low.c: Update.
977 * lynx-low.c: Update.
978 * mem-break.c: Update.
979 * nto-low.c: Update.
980 * remote-utils.c: Update.
981 * server.c: Update.
982 * spu-low.c: Update.
983 * target.c: Update.
984 * tracepoint.c: Update.
985
986 2018-07-03 Tom Tromey <tom@tromey.com>
987
988 * linux-low.c: Update.
989 * linux-ppc-low.c: Update.
990 * linux-x86-low.c: Update.
991 * proc-service.c: Update.
992 * server.c: Update.
993 * spu-low.c: Update.
994 * thread-db.c: Update.
995 * win32-low.c: Update.
996
997 2018-07-03 Tom Tromey <tom@tromey.com>
998
999 * linux-low.c: Update.
1000 * lynx-low.c: Update.
1001 * nto-low.c: Update.
1002 * remote-utils.c: Update.
1003 * spu-low.c: Update.
1004 * thread-db.c: Update.
1005 * win32-low.c: Update.
1006
1007 2018-06-29 Joel Brobecker <brobecker@adacore.com>
1008
1009 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
1010 parameter in call to 'amd64_create_target_description'.
1011
1012 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
1013
1014 * x86-tdesc.h: Remove executable permission flag.
1015
1016 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1017
1018 * configure.ac: Remove AC_PREREQ, add missing quoting.
1019 * configure: Re-generate.
1020 * config.in: Re-generate.
1021 * aclocal.m4: Re-generate.
1022
1023 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
1024
1025 * tracepoint.h (current_traceframe): Remove declaration.
1026
1027 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1028
1029 * linux-aarch64-low.c (is_sve_tdesc): New function.
1030 (aarch64_sve_regs_copy_to_regcache): Likewise.
1031 (aarch64_sve_regs_copy_from_regcache): Likewise.
1032 (aarch64_regs_info): Add SVE checks.
1033 (initialize_low_arch): Initialize SVE.
1034
1035 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1036
1037 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
1038
1039 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1040
1041 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
1042 (initialize_low_tracepoint): Likewise
1043 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
1044 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
1045 param.
1046 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
1047 checks.
1048 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
1049
1050 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1051
1052 * server.h (PBUFSIZ): Increase size
1053
1054 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1055
1056 * regcache.c (regcache::raw_compare): New function.
1057 * regcache.h (regcache::raw_compare): New declaration.
1058
1059 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1060
1061 * regcache.c (new_register_cache): Use new.
1062 (free_register_cache): Use delete.
1063 (register_data): Use const.
1064 (supply_register): Move body inside regcache.
1065 (regcache::raw_supply): New override function.
1066 (collect_register): Move body inside regcache.
1067 (regcache::raw_collect): New override function.
1068 (regcache::get_register_status): New override function.
1069 * regcache.h (struct regcache): Inherit from reg_buffer_common.
1070
1071 2018-06-09 Tom Tromey <tom@tromey.com>
1072
1073 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
1074 declare queue.
1075 (event_queue): Use std::queue.
1076 (gdb_event_xfree): Remove.
1077 (initialize_event_loop, process_event, wait_for_event): Update.
1078
1079 2018-06-08 Stan Cox <scox@redhat.com>
1080
1081 * win32-low.c (win32_create_inferior): last_ptid and last_status
1082 moved to client_state.
1083
1084 2018-06-08 Pedro Alves <palves@redhat.com>
1085
1086 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
1087 common/common-exceptions.o, common/common-utils.o,
1088 common/errors.o, common/print-utils.o and utils.o.
1089 * gdbreplay.c: Include "common-defs.h" instead of the two
1090 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
1091 string.h or alloca.h.
1092 (perror_with_name): Delete.
1093 (remote_open): Use xstrdup instead of strdup.
1094 (main): Rename to ...
1095 (captured_main): ... this.
1096 (main): New.
1097
1098 2018-06-08 Tom Tromey <tom@tromey.com>
1099
1100 * linux-low.c (linux_low_read_btrace): Update.
1101
1102 2018-06-04 Stan Cox <scox@redhat.com>
1103
1104 * server.h (struct client_state): New.
1105 * server.c (cont_thread, general_thread, multi_process)
1106 (report_fork_events, report_vfork_events, report_exec_events)
1107 (report_thread_events, swbreak_feature, hwbreak_feature)
1108 (vCont_supported, disable_randomization, pass_signals)
1109 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
1110 Moved to client_state.
1111 * remote-utils.c (remote_debug, noack_mode)
1112 (transport_is_reliable): Moved to client_state.
1113 * tracepoint.c (current_traceframe): Moved to client_state.
1114
1115 Update all callers.
1116 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
1117 linux-low.c, remote-utils.h, target.c: Use client_state.
1118
1119 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1120
1121 * configure.srv: Add new c/h file.
1122
1123 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1124
1125 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1126 null VQ.
1127
1128 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1129
1130 * gdb.arch/mips-fpregset-core.exp: New test.
1131 * gdb.arch/mips-fpregset-core.c: New test source.
1132
1133 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1134
1135 PR server/23198
1136 * hostio.c (require_int): Do not report overflow for integers
1137 between 0xfffffff and 0x7fffffff.
1138
1139 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1140
1141 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1142 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1143 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1144 functions.
1145 (the_low_target): Wire them.
1146
1147 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1148
1149 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1150 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1151 mode. Call collect_register_by_name with vscr using
1152 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1153 (ppc_store_vrregset): Add and set vscr_offset variable as in
1154 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1155 vscr_offset.
1156
1157 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1158
1159 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1160 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1161 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1162
1163 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1164
1165 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1166 (ppc_store_vsxregset): Likewise.
1167 (ppc_fill_vrregset): Likewise.
1168 (ppc_store_vrregset): Likewise.
1169 (ppc_fill_evrregset): Likewise.
1170 (ppc_store_evrregset): Likewise.
1171 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1172 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1173 needed.
1174
1175 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1176
1177 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1178 wordsize of the inferior. Call ppc_linux_target_wordsize.
1179
1180 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1181
1182 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1183 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1184 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1185 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1186 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1187 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1188 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1189 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1190 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1191 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1192 (tdesc_powerpc_e500l): Remove.
1193 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1194 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1195 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1196 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1197 linux-ppc-tdesc.h.
1198 (ppc_arch_setup): Remove target description matching code. Fill a
1199 ppc_linux_features struct and call ppc_linux_match_description
1200 with it.
1201
1202 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1203
1204 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1205 width of the requested register exceeds the width of the
1206 `ptrace' data type.
1207 (mips_cannot_store_register): Likewise.
1208
1209 2018-05-21 Maciej W. Rozycki <macro@mips.com>
1210
1211 * linux-mips-low.c (mips_fetch_register): New function. Update
1212 preceding comment.
1213 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1214 (the_low_target): Wire `mips_fetch_register'.
1215
1216 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1217
1218 * lynx-i386-low.c (LYNXOS_178): New macro.
1219 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1220 the layout on LynxOS-178.
1221 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1222 handle floating point registers that are not supported by
1223 LynxOS-178.
1224
1225 2018-05-10 Tom Tromey <tom@tromey.com>
1226
1227 * configure: Rebuild.
1228
1229 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1230
1231 PR server/23158:
1232 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1233 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1234 Use it to set the expedite_regs field in the given tdesc.
1235 * x86-tdesc.h: New file.
1236 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1237 Adjust following the addition of the new expedite_regs parameter
1238 to init_target_desc.
1239 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1240 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1241 (i386_linux_read_description, amd64_linux_read_description):
1242 Adjust following the addition of the new expedite_regs parameter
1243 to init_target_desc.
1244 * lynx-i386-low.c: #include "x86-tdesc.h".
1245 (lynx_i386_arch_setup): Adjust following the addition of the new
1246 expedite_regs parameter to init_target_desc.
1247 * nto-x86-low.c: #include "x86-tdesc.h".
1248 (nto_x86_arch_setup): Adjust following the addition of the new
1249 expedite_regs parameter to init_target_desc.
1250 * win32-i386-low.c: #include "x86-tdesc.h".
1251 (i386_arch_setup): Adjust following the addition of the new
1252 expedite_regs parameter to init_target_desc.
1253
1254 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1255
1256 PR server/23158:
1257 * win32-low.c (win32_create_inferior): Add call to my_wait
1258 setting last_status global.
1259
1260 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1261
1262 PR server/23158:
1263 * win32-low.c (create_process): Only call gdb_tilde_expand if
1264 inferior_cwd is not NULL.
1265
1266 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1267
1268 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1269 registers to the cache if their values have changed.
1270 (i387_xsave_to_cache): Provide default values for x87 control
1271 registers when these features are available, but disabled.
1272 * regcache.c (supply_register_by_name_zeroed): New function.
1273 * regcache.h (supply_register_by_name_zeroed): Declare new
1274 function.
1275
1276 2018-05-07 Tom Tromey <tom@tromey.com>
1277
1278 * configure: Rebuild.
1279
1280 2018-05-04 Tom Tromey <tom@tromey.com>
1281
1282 * configure: Rebuild.
1283
1284 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1285 Pedro Alves <palves@redhat.com>
1286
1287 * linux-aarch64-low.c (aarch64_stopped_data_address):
1288 Likewise.
1289
1290 2018-04-27 Tom Tromey <tom@tromey.com>
1291
1292 * configure: Rebuild.
1293
1294 2018-04-23 Tom Tromey <tom@tromey.com>
1295
1296 * configure: Rebuild.
1297
1298 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1299
1300 * Makefile.in (depcomp): Add "..".
1301 (all_deps_files): New and use it.
1302
1303 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1304
1305 * configure.srv (aarch64*-*-linux*): Don't include xml.
1306 (i[34567]86-*-cygwin*): Likewise.
1307 (i[34567]86-*-linux*): Likewise.
1308 (i[34567]86-*-lynxos*): Likewise.
1309 (i[34567]86-*-mingw32ce*): Likewise.
1310 (i[34567]86-*-mingw*): Likewise.
1311 (i[34567]86-*-nto*): Likewise.
1312 (tic6x-*-uclinux): Likewise.
1313 (x86_64-*-linux*): Likewise.
1314 (x86_64-*-mingw*): Likewise.
1315 (x86_64-*-cygwin*): Likewise.
1316
1317 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1318
1319 * tdesc.c: Remove xml parameter.
1320
1321 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1322
1323 * server.c (get_features_xml): Remove cast.
1324 * tdesc.c (void target_desc::accept): Fill in function.
1325 (tdesc_get_features_xml): Remove old xml creation.
1326 (print_xml_feature::visit_pre): Add xml vistor.
1327 * tdesc.h (struct target_desc): Make xmltarget mutable.
1328 (tdesc_get_features_xml): Remove declaration.
1329
1330 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1331
1332 * tdesc.c (tdesc_architecture_name): Add new function.
1333 (tdesc_osabi_name): Likewise.
1334 (tdesc_get_features_xml): Use new functions.
1335
1336 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1337
1338 * tdesc.c (tdesc_create_flags): Remove.
1339 (tdesc_add_flag): Likewise.
1340 (tdesc_named_type): Likewise.
1341 (tdesc_create_union): Likewise.
1342 (tdesc_create_struct): Likewise.
1343 (tdesc_create_vector): Likewise.
1344 (tdesc_add_bitfield): Likewise.
1345 (tdesc_add_field): Likewise.
1346 (tdesc_set_struct_size): Likewise.
1347
1348 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1349
1350 * tdesc.c (~target_desc): Remove implictly deleted items.
1351 (init_target_desc): Iterate all features.
1352 (tdesc_get_features_xml): Use vector.
1353 (tdesc_create_feature): Create feature.
1354 * tdesc.h (tdesc_feature) Remove
1355 (target_desc): Add features.
1356
1357 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1358
1359 * Makefile.in: Add common/tdesc.c
1360 * tdesc.c (init_target_desc): init all reg_defs from register
1361 vector.
1362 (tdesc_create_reg): Create tdesc_reg.
1363 * tdesc.h (tdesc_feature): Add register vector.
1364
1365 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1366
1367 * tdesc.h (struct target_desc) <features>: Change type to
1368 std::vector<std::string>.
1369 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1370 changes.
1371 (tdesc_get_features_xml): Likewise.
1372 (tdesc_create_feature): Likewise.
1373
1374 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1375
1376 * regcache.c (find_register_by_number): Return a ref.
1377 (find_regno): Use references.
1378 (register_size): Likewise.
1379 (register_data): Likewise.
1380 * tdesc.c (target_desc::~target_desc): Remove free calls.
1381 (target_desc::operator==): Use std::vector compare.
1382 (init_target_desc): Use reference.
1383 (tdesc_create_reg): Use reg constructors.
1384 * tdesc.h (struct target_desc): Replace pointer with object.
1385
1386 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1387
1388 * regcache.c (find_register_by_number): Make static.
1389 (find_regno): Use find_register_by_number
1390 * regcache.h (struct reg): Remove declaration.
1391
1392 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1393
1394 * tdesc.c (target_desc::~target_desc): Move to here.
1395 (target_desc::operator==): Likewise.
1396 * tdesc.h (target_desc::~target_desc): Move from here.
1397 (target_desc::operator==): Likewise.
1398
1399 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1400
1401 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1402
1403 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1404
1405 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1406 S390_TDESC_GS.
1407 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1408 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1409 and init_registers_s390_gs_linux64.
1410
1411 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1412
1413 * linux-s390-low.c (s390_fill_gs): Remove function.
1414 (s390_fill_gsbc): Remove function.
1415 (s390_regsets): Set fill functions for the guarded storage regsets
1416 to NULL.
1417
1418 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1419
1420 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1421 the word size. Add comment.
1422 (s390_get_wordsize): New function.
1423 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1424 pswm with it. Instead, use s390_get_wordsize to determine the
1425 word size first and derive the correct tdesc from that directly.
1426
1427 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1428
1429 * Makefile.in: Include silent-rules.mk.
1430 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1431 (COMPILE): Add ECHO_CXX.
1432 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1433 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1434 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1435 (version-generated.c): Add ECHO_GEN.
1436 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1437 (IPAGENT_COMPILE): Add ECHO_CXX.
1438 (%-generated.c): Add ECHO_REGDAT.
1439
1440 2018-03-14 Tom Tromey <tom@tromey.com>
1441
1442 PR cli/14977:
1443 * ax.c (ax_printf): Special case for NULL.
1444
1445 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1446
1447 * linux-low.c (linux_qxfer_libraries_svr4): Use
1448 xml_escape_text_append.
1449
1450 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1451
1452 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1453
1454 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1455
1456 * server.c (handle_general_set): Remove unnecessary xstrdup.
1457
1458 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1459
1460 * server.c (parse_debug_format_options): Adjust to
1461 delim_string_to_char_ptr_vec changes.
1462 * thread-db.c (thread_db_load_search): Adjust to
1463 dirnames_to_char_ptr_vec changes.
1464
1465 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1466
1467 * target.h (target_enable_btrace, target_disable_btrace)
1468 (target_read_btrace, target_read_btrace_conf): Turn macro into
1469 inline function. Throw error if target method is not defined.
1470 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1471 check for btrace target method. Be prepared to handle exceptions
1472 from btrace target methods.
1473
1474 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1475
1476 * server.c (captured_main): Change order of error message printed
1477 when the current working directory cannot be found.
1478
1479 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1480
1481 * server.c: Include "filenames.h" and "pathstuff.h".
1482 (program_name): Delete variable.
1483 (program_path): New anonymous class.
1484 (get_exec_wrapper): Use "program_path" instead of
1485 "program_name".
1486 (handle_v_run): Likewise.
1487 (captured_main): Likewise.
1488 (process_serial_event): Likewise.
1489
1490 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1491
1492 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1493 (OBJS): Add "pathstuff.o".
1494 * server.c (current_directory): New global variable.
1495 (captured_main): Initialize "current_directory".
1496
1497 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1498
1499 * tdesc.c: Use common/tdesc.h.
1500 * tdesc.h: Likewise.
1501
1502 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1503 Simon Marchi <simon.marchi@ericsson.com>
1504
1505 * Makefile.in: Switch order of make rules.
1506
1507 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1508
1509 * Makefile.in: Add common directory in build.
1510 * configure.ac: Add common reference.
1511 * configure: Regenerate.
1512
1513 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1514
1515 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1516 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1517 * spu-low.c (spu_target_ops): Likewise.
1518 * win32-low.c (win32_target_ops): Likewise.
1519 * server.c (supported_btrace_packets): Report packets unconditionally.
1520 * target.h (target_ops) <supports_btrace>: Remove.
1521 (target_supports_btrace): Remove.
1522
1523 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1524
1525 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1526 (handle_btrace_disable): Change return type to void. Use exceptions
1527 to report errors.
1528 (handle_btrace_general_set): Catch exception and copy message to
1529 return message.
1530
1531 2018-02-08 Tom Tromey <tom@tromey.com>
1532
1533 * linux-low.c (install_software_single_step_breakpoints): Use
1534 make_scoped_restore.
1535 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1536 (do_restore_current_thread_cleanup): Remove.
1537 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1538 declare.
1539
1540 2018-02-08 Tom Tromey <tom@tromey.com>
1541
1542 * mem-break.c (set_raw_breakpoint_at): Use
1543 gdb::unique_xmalloc_ptr.
1544
1545 2018-01-30 Pedro Alves <palves@redhat.com>
1546
1547 PR gdb/13211
1548 * target.c (target_terminal::terminal_state): Rename to ...
1549 (target_terminal::m_terminal_state): ... this.
1550
1551 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1552
1553 * linux-low.c (handle_extended_wait): Surround call to
1554 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1555
1556 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1557
1558 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1559 linux_ptrace_attach_fail_reason_string now returning an
1560 std::string.
1561 (linux_attach): Likewise.
1562 * thread-db.c (attach_thread): Likewise.
1563
1564 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1565
1566 PR gdb/21559
1567 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1568 checking for fs_base/gs_base fields in struct user_regs_struct.
1569 * configure: Regenerate.
1570
1571 2018-01-16 Yao Qi <yao.qi@linaro.org>
1572
1573 PR gdb/18749
1574 * linux-low.c (fetch_register): Call supply_register instead of
1575 error.
1576
1577 2018-01-08 Yao Qi <yao.qi@linaro.org>
1578 Simon Marchi <simon.marchi@ericsson.com>
1579
1580 * Makefile.in (OBS): Remove selftest.o.
1581 * configure.ac: Set srv_selftest_objs if $development is true.
1582 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1583 * configure: Re-generated.
1584 * server.c (captured_main): Wrap variable selftest_filter with
1585 GDB_SELF_TEST.
1586
1587 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1588
1589 * server.c (parse_debug_format_options): Return std::string.
1590 (handle_monitor_command, captured_main): Adjust.
1591
1592 2018-01-05 Pedro Alves <palves@redhat.com>
1593
1594 PR gdb/18653
1595 * server.c (captured_main): Pass quiet=false to
1596 save_original_signals_state.
1597
1598 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1599
1600 * gdbreplay.c (gdbreplay_version): Update copyright year in
1601 version message.
1602 * server.c (gdbserver_version): Likewise.
1603
1604 2017-12-08 Tom Tromey <tom@tromey.com>
1605
1606 * ax.c (ax_printf): Update.
1607
1608 2017-12-07 Yao Qi <yao.qi@linaro.org>
1609
1610 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1611 aarch64_linux_read_description.
1612 * linux-amd64-ipa.c (idx2mask): New array.
1613 (get_ipa_tdesc): Move idx2mask out.
1614 (initialize_low_tracepoint): Initialize target descriptions.
1615 * linux-i386-ipa.c (idx2mask): New array.
1616 (get_ipa_tdesc): Move idx2mask out.
1617 (initialize_low_tracepoint): Initialize target descriptions.
1618
1619 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1620
1621 * tdesc.c (struct tdesc_type): Change return type.
1622 (tdesc_add_flag): Change parameter type.
1623 (tdesc_add_bitfield): Likewise.
1624 (tdesc_add_field): Likewise.
1625 (tdesc_set_struct_size): Likewise.
1626
1627 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1628
1629 * regcache.c (registers_to_string): Remove unused variable.
1630
1631 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1632
1633 * inferiors.c (for_each_inferior_with_data): Remove.
1634 * inferiors.h (for_each_inferior_with_data): Remove.
1635 * server.c (handle_qxfer_threads_worker): Change parameter type.
1636 (handle_qxfer_threads_proper): Use for_each_thread.
1637
1638 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1639
1640 * inferiors.c (for_each_inferior): Remove.
1641 (clear_inferiors): Use for_each_thread.
1642 * inferiors.h (for_each_inferior): Remove.
1643 * linux-low.c (linux_wait_for_event_filtered): Use
1644 for_each_thread.
1645 (linux_stabilize_threads): Likewise.
1646 * regcache.c (regcache_release): Likewise.
1647 * server.c (gdb_wants_all_threads_stopped): Likewise.
1648 (clear_pending_status_callback): Remove.
1649 (handle_status): Use for_each_thread.
1650 (captured_main): Likewise.
1651 * win32-low.c (child_init_thread_list): Likewise.
1652 (win32_clear_inferiors): Likewise.
1653 (fake_breakpoint_event): Likewise.
1654
1655 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1656
1657 * inferiors.h (find_inferior): Remove.
1658 * inferiors.c (find_inferior): Remove.
1659
1660 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1661
1662 * linux-low.c (resume_status_pending_p): Update comment.
1663 (need_step_over_p): Update comment.
1664
1665 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1666
1667 * linux-low.c (proceed_one_lwp): Return void, change parameter
1668 type.
1669 (unsuspend_and_proceed_one_lwp): Likewise.
1670 (proceed_all_lwps): Use for_each_thread.
1671 (unstop_all_lwps): Likewise.
1672
1673 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1674
1675 * linux-low.c (linux_resume_one_thread): Return void, take
1676 parameter directly.
1677 (linux_resume): Use for_each_thread.
1678
1679 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1680
1681 * linux-low.c (send_sigstop_callback): Return void, change
1682 parameter type. Rename to...
1683 (send_sigstop): ... this.
1684 (suspend_and_send_sigstop_callback): Return void, change parameter
1685 type. Rename to...
1686 (suspend_and_send_sigstop): ... this.
1687 (stop_all_lwps): Use for_each_thread.
1688
1689 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1690
1691 * linux-low.c (lwp_running): Return bool, remove unused
1692 argument.
1693 (linux_stabilize_threads): Use find_thread.
1694
1695 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1696
1697 * linux-low.c (select_singlestep_lwp_callback): Remove.
1698 (count_events_callback): Remove.
1699 (select_event_lwp_callback): Remove.
1700 (select_event_lwp): Use find_thread/for_each_thread.
1701
1702 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1703
1704 * linux-low.c (not_stopped_callback): Return bool, take filter
1705 argument directly.
1706 (linux_wait_for_event_filtered): Use find_thread.
1707 (linux_wait_1): Likewise.
1708
1709 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1710
1711 * linux-low.c (same_lwp): Remove.
1712 (find_lwp_pid): Use find_thread.
1713
1714 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1715
1716 * linux-low.c (delete_lwp_callback): Remove.
1717 (linux_mourn): Use for_each_thread.
1718
1719 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1720
1721 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1722 args parameter, don't check for pid.
1723 (linux_detach): Use for_each_thread.
1724
1725 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1726
1727 * linux-low.c (struct counter): Remove.
1728 (second_thread_of_pid_p): Remove.
1729 (last_thread_of_process_p): Use find_thread.
1730
1731 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1732
1733 * inferiors.c (find_inferior_in_random): Remove.
1734 * inferiors.h (find_inferior_in_random): Remove.
1735 * linux-low.c (status_pending_p_callback): Return bool, accept
1736 parameter ptid directly.
1737 (linux_wait_for_event_filtered): Use find_thread_in_random.
1738 (linux_wait_1): Likewise.
1739
1740 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1741
1742 * inferiors.c (find_inferior_id): Remove.
1743 (find_thread_ptid): Move implemention from find_inferior_id to
1744 here.
1745 * inferiors.h (find_inferior_id): Remove.
1746 * server.c (handle_status): Use find_thread_ptid.
1747 (process_serial_event): Likewise.
1748 * thread-db.c (find_one_thread): Likewise.
1749 (thread_db_thread_handle): Likewise.
1750 * win32-low.c (thread_rec): Likewise.
1751 (child_delete_thread): Likewise.
1752 (win32_thread_alive): Likewise.
1753 (get_child_debug_event): Likewise.
1754
1755 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1756
1757 * linux-mips-low.c (update_watch_registers_callback): Return
1758 void, remove pid_p parameter, don't check for pid.
1759 (mips_insert_point, mips_remove_point): Use for_each_thread.
1760
1761 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1762
1763 * lynx.low (lynx_delete_thread_callback): Remove.
1764 (lynx_mourn): Use for_each_thread.
1765
1766 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1767
1768 * regcache.c (regcache_invalidate_one): Remove.
1769 (regcache_invalidate_pid): use for_each_thread.
1770
1771 2017-11-26 Tom Tromey <tom@tromey.com>
1772
1773 * linux-low.c (linux_create_inferior): Update.
1774
1775 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1776
1777 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1778
1779 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1780
1781 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1782 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1783 * linux-aarch64-tdesc-selftest.c: New file.
1784 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1785
1786 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1787
1788 * configure.srv: Add new file.
1789 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1790 * linux-aarch64-tdesc-selftest.c: New file.
1791 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1792
1793 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1794
1795 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1796 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1797 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1798
1799 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1800
1801 * configure.srv: Add new files.
1802 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1803 aarch64_linux_read_description.
1804 * linux-aarch64-low.c (aarch64_linux_read_description):
1805 Merge with aarch64_arch_setup.
1806 (aarch64_arch_setup): Call aarch64_linux_read_description.
1807 * linux-aarch64-tdesc.c: New file.
1808 * linux-aarch64-tdesc.h: New file.
1809
1810 2017-11-24 Yao Qi <yao.qi@linaro.org>
1811
1812 * configure.srv: Set $srv_regobj for tic6x-linux.
1813 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1814 (tic6x_read_description): Move some code to tic6x_arch_setup.
1815 (tic6x_tdesc_test): New function.
1816 (initialize_low_arch): Call selftests::register_test.
1817
1818 2017-11-22 Yao Qi <yao.qi@linaro.org>
1819
1820 * remote-utils.c (prepare_resume_reply): Use memcpy.
1821
1822 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1823
1824 * linux-low.c (kill_one_lwp_callback): Return void, take
1825 argument directly, don't filter on pid.
1826 (linux_kill): Use for_each_thread.
1827
1828 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1829
1830 * linux-low.c (need_step_over_p): Return bool, remove dummy
1831 argument.
1832 (linux_resume, proceed_all_lwps): Use find_thread.
1833
1834 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1835
1836 * linux-low.c (resume_status_pending_p): Return bool, remove
1837 flag_p argument.
1838 (linux_resume): Use find_thread.
1839
1840 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1841
1842 * linux-low.c (struct thread_resume_array): Remove.
1843 (linux_set_resume_request): Return void, take arguments
1844 directly.
1845 (linux_resume): Use for_each_thread.
1846
1847 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1848
1849 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1850 return bool, remove data argument.
1851 (linux_stabilize_threads): Use find_thread.
1852
1853 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1854
1855 * linux-low.c (unsuspend_one_lwp): Remove.
1856 (unsuspend_all_lwps): Use for_each_thread, inline code from
1857 unsuspend_one_lwp.
1858
1859 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1860
1861 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1862 * linux-low.c (struct iterate_over_lwps_args): Remove.
1863 (iterate_over_lwps_filter): Remove.
1864 (iterate_over_lwps): Use find_thread.
1865
1866 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1867
1868 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1869 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1870 code from reset_lwp_ptrace_options_callback.
1871
1872 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1873
1874 * linux-arm-low.c (struct update_registers_data): Remove.
1875 (update_registers_callback): Return void, take arguments
1876 directly, don't check thread's pid.
1877 (arm_insert_point, arm_remove_point): Use for_each_thread.
1878
1879 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1880
1881 * win32-low.c (continue_one_thread): Return void, take argument
1882 directly.
1883 (child_continue): Use for_each_thread.
1884
1885 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1886
1887 * win32-i386-low.c (update_debug_registers_callback): Rename
1888 to ...
1889 (update_debug_registers): ... this, return void, remove pid_p arg.
1890 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1891
1892 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1893
1894 * inferiors.h (struct process_info): Add constructor, initialize
1895 fields..
1896 <syscalls_to_catch>: Change type to std::vector<int>.
1897 * inferiors.c (add_process): Allocate process_info with new.
1898 (remove_process): Free process_info with delete.
1899 * linux-low.c (handle_extended_wait): Adjust.
1900 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1901 * server.c (handle_general_set): Adjust.
1902
1903 2017-11-16 Pedro Alves <palves@redhat.com>
1904
1905 * remote-utils.c (remote_close): Block SIGIO signals instead of
1906 uninstalling the SIGIO handler.
1907
1908 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1909
1910 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1911
1912 2017-11-16 Yao Qi <yao.qi@linaro.org>
1913
1914 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1915 (tic6x_store_gregset): Likewise.
1916 (tic6x_usrregs_info): Move it up.
1917
1918 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1919
1920 * Makefile.in: Update arch rules.
1921 * configure.srv: Explicitly mark arch/ files.
1922
1923 2017-11-13 Andreas Schwab <schwab@suse.de>
1924
1925 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1926 function.
1927 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1928
1929 2017-11-06 Pedro Alves <palves@redhat.com>
1930
1931 * config.in, configure: Regenerate.
1932
1933 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1934
1935 * target.c (struct thread_search): Remove.
1936 (thread_search_callback): Remove.
1937 (prepare_to_access_memory): Use for_each_thread instead of
1938 find_inferior. Inline code from thread_search_callback.
1939
1940 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1941
1942 * server.c (struct visit_actioned_threads_data): Remove.
1943 (visit_actioned_threads): Change prototype to take arguments
1944 directly.
1945 (resume): Use find_thread instead of find_inferior.
1946
1947 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1948
1949 * server.c (queue_stop_reply_callback): Change prototype, return
1950 void.
1951 (find_status_pending_thread_callback): Remove.
1952 (handle_status): Replace find_inferior with find_thread and
1953 for_each_thread.
1954
1955 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1956
1957 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1958 with REGNO.
1959 (aarch64_store_gregset): Likewise.
1960 (aarch64_fill_fpregset): Likewise.
1961 (aarch64_store_fpregset): Likewise.
1962
1963 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1964
1965 * gdbthread.h (find_thread, for_each_thread): New functions.
1966 * inferiors.c (thread_of_pid): Remove.
1967 (find_any_thread_of_pid): Use find_thread.
1968 * linux-low.c (num_lwps): Use for_each_thread.
1969
1970 2017-10-17 Yao Qi <yao.qi@linaro.org>
1971
1972 * Makefile.in: Remove one rule.
1973 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1974
1975 2017-10-17 Yao Qi <yao.qi@linaro.org>
1976
1977 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1978 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1979
1980 2017-10-17 Yao Qi <yao.qi@linaro.org>
1981
1982 * configure.srv: Rename arm.o with arch/arm.o.
1983
1984 2017-10-17 Yao Qi <yao.qi@linaro.org>
1985
1986 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1987 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1988 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1989 (arch-i386.o, arch-amd64.o): Remove rules.
1990 (arch/%.o): New rule.
1991 Update POSTCOMPILE and COMPILE.pre.
1992 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1993 * configure: Re-generated.
1994 * configure.srv: Replace arch-i386.o with arch/i386.o.
1995 Replace arch-amd64.o with arch/amd64.o.
1996
1997 2017-10-16 Yao Qi <yao.qi@linaro.org>
1998
1999 * configure: Regenerated.
2000
2001 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2002
2003 * inferiors.h: (struct inferior_list): Remove.
2004 (struct inferior_list_entry); Remove.
2005 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
2006 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
2007 get_first_inferior): Remove.
2008 (for_each_inferior, for_each_inferior_with_data, find_inferior,
2009 find_inferior_id, find_inferior_in_random): Change signature.
2010 * inferiors.c (all_threads): Change type to
2011 std::list<thread_info *>.
2012 (get_thread): Remove macro.
2013 (find_inferior, find_inferior_id): Change signature, implement
2014 using find_thread.
2015 (find_inferior_in_random): Change signature, implement using
2016 find_thread_in_random.
2017 (for_each_inferior, for_each_inferior_with_data): Change
2018 signature, implement using for_each_thread.
2019 (add_inferior_to_list, remove_inferior): Remove.
2020 (add_thread, get_first_thread, thread_of_pid,
2021 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
2022 (get_first_inferior, one_inferior_p, clear_inferior_list):
2023 Remove.
2024 (clear_inferiors, get_thread_process): Update.
2025 * gdbthread.h: Include <list>.
2026 (struct thread_info) <entry>: Remove field.
2027 <id>: New field.
2028 (all_threads): Change type to std::list<thread_info *>.
2029 (get_first_inferior): Add doc.
2030 (find_thread, for_each_thread, find_thread_in_random): New
2031 functions.
2032 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
2033 * linux-arm-low.c (update_registers_callback): Update.
2034 * linux-low.c (second_thread_of_pid_p): Update.
2035 (kill_one_lwp_callback, linux_detach_lwp_callback,
2036 delete_lwp_callback, status_pending_p_callback, same_lwp,
2037 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
2038 iterate_over_lwps, not_stopped_callback,
2039 resume_stopped_resumed_lwps, count_events_callback,
2040 select_singlestep_lwp_callback, select_event_lwp_callback,
2041 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
2042 suspend_and_send_sigstop_callback, wait_for_sigstop,
2043 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
2044 lwp_running, linux_set_resume_request, resume_status_pending_p,
2045 need_step_over_p, start_step_over, linux_resume_one_thread,
2046 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
2047 reset_lwp_ptrace_options_callback): Update.
2048 * linux-mips-low.c (update_watch_registers_callback): Update.
2049 * regcache.c (regcache_invalidate_one, regcache_invalidate):
2050 Update.
2051 (free_register_cache_thread_one): Remove.
2052 (regcache_release): Update.
2053 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
2054 handle_qxfer_threads_worker): Update.
2055 (handle_query): Update, use list iterator.
2056 (visit_actioned_threads, handle_pending_status,
2057 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
2058 clear_pending_status_callback, set_pending_status_callback,
2059 find_status_pending_thread_callback, handle_status,
2060 process_serial_event): Update.
2061 * target.c (thread_search_callback): Update.
2062 * thread-db.c (thread_db_get_tls_address): Update.
2063 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
2064 Update.
2065 * win32-i386-low.c (update_debug_registers_callback): Update.
2066 * win32-low.c (delete_thread_info, child_delete_thread,
2067 continue_one_thread, suspend_one_thread,
2068 get_child_debug_event): Adjust.
2069
2070 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2071
2072 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
2073 * inferiors.h: Include <list>.
2074 (struct process_info) <entry>: Remove field.
2075 <pid>: New field.
2076 (pid_of): Change macro to function.
2077 (ptid_of, lwpid_of): Remove macro.
2078 (all_processes): Change type to std::list<process_info *>.
2079 (ALL_PROCESSES): Remove macro.
2080 (for_each_process, find_process): New function.
2081 * inferiors.c (all_processes): Change type to
2082 std::list<process_info *>.
2083 (find_thread_process): Adjust.
2084 (add_process): Likewise.
2085 (remove_process): Likewise.
2086 (find_process_pid): Likewise.
2087 (get_first_process): Likewise.
2088 (started_inferior_callback): Remove.
2089 (have_started_inferiors_p): Adjust.
2090 (attached_inferior_callback): Remove.
2091 (have_attached_inferiors_p): Adjust.
2092 * linux-low.c (check_zombie_leaders): Likewise.
2093 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
2094 (x86_linux_update_xmltarget): Adjust.
2095 * server.c (handle_query): Likewise.
2096 (gdb_reattached_process): Remove.
2097 (handle_status): Adjust.
2098 (kill_inferior_callback): Likewise.
2099 (detach_or_kill_inferior): Remove.
2100 (print_started_pid): Likewise.
2101 (print_attached_pid): Likewise.
2102 (detach_or_kill_for_exit): Update.
2103 (process_serial_event): Likewise.
2104 * linux-arm-low.c (arm_new_fork): Likewise.
2105
2106 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2107
2108 * dll.h: Include <list>.
2109 (struct dll_info): Add constructor.
2110 <entry>: Remove field.
2111 (all_dlls): Change type to std::list<dll_info>.
2112 * dll.c: Include <algorithm>.
2113 (get_dll): Remove macro.
2114 (all_dlls): Change type to std::list<dll_info *>.
2115 (free_one_dll): Remove.
2116 (match_dll): Likewise.
2117 (loaded_dll): Adjust.
2118 (unloaded_dll): Adjust to all_dlls type change, use
2119 std::find_if. Inline code from match_dll.
2120 (clear_dlls): Adjust to all_dlls type change.
2121 * server.c (emit_dll_description): Remove.
2122 (handle_qxfer_libraries): Adjust to all_dlls type change,
2123 integrate emit_dll_description's functionality.
2124
2125 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2126
2127 * linux-low.h (struct linux_target_ops) <delete_process>: New
2128 field.
2129 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2130 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2131 (struct linux_target_ops): Add delete_process callback.
2132 * linux-arm-low.c (arm_delete_process): New.
2133 (struct linux_target_ops): Add delete_process callback.
2134 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2135 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2136 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2137 * linux-mips-low.c (mips_linux_delete_process): New.
2138 (struct linux_target_ops): Add delete_process callback.
2139 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2140 * linux-s390-low.c (struct linux_target_ops): Likewise.
2141 * linux-sh-low.c (struct linux_target_ops): Likewise.
2142 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2143 * linux-tile-low.c (struct linux_target_ops): Likewise.
2144 * linux-x86-low.c (x86_linux_delete_process): New.
2145 (struct linux_target_ops): Add delete_process callback.
2146 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2147
2148 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2149
2150 * linux-aarch64-low.c (the_low_target): Add thread delete
2151 callback.
2152 * linux-arm-low.c (arm_delete_thread): New function.
2153 (the_low_target): Add thread delete callback.
2154 * linux-bfin-low.c (the_low_target): Likewise.
2155 * linux-crisv32-low.c (the_low_target): Likewise.
2156 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2157 set.
2158 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2159 field.
2160 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2161 * linux-mips-low.c (mips_linux_delete_thread): New function.
2162 (the_low_target): Add thread delete callback.
2163 * linux-ppc-low.c (the_low_target): Likewise.
2164 * linux-s390-low.c (the_low_target): Likewise.
2165 * linux-sh-low.c (the_low_target): Likewise.
2166 * linux-tic6x-low.c (the_low_target): Likewise.
2167 * linux-tile-low.c (the_low_target): Likewise.
2168 * linux-x86-low.c (the_low_target): Likewise.
2169 * linux-xtensa-low.c (the_low_target): Likewise.
2170
2171 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2172
2173 * win32-low.c: Include "common-inferior.h".
2174
2175 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2176
2177 * inferiors.c (set_inferior_cwd): New function.
2178 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2179 (handle_query): Inform that QSetWorkingDir is supported.
2180 * win32-low.c (create_process): Pass the inferior's cwd to
2181 CreateProcess.
2182
2183 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2184
2185 * inferiors.c (current_inferior_cwd): New global variable.
2186 (get_inferior_cwd): New function.
2187 * inferiors.h (struct process_info) <cwd>: New field.
2188
2189 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2190
2191 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2192 (OBS): Add gdb_tilde_expand.o.
2193
2194 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2195
2196 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2197 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2198
2199 2017-09-29 Pedro Alves <palves@redhat.com>
2200
2201 * ax.c (gdb_parse_agent_expr): Constify.
2202 * ax.h (gdb_parse_agent_expr): Constify.
2203 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2204 Constify.
2205 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2206 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2207 * remote-utils.h (read_ptid): Constify.
2208 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2209 (process_point_options, process_serial_event): Constify.
2210 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2211 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2212 (cmd_qtbuffer): Constify.
2213
2214 2017-09-29 Pedro Alves <palves@redhat.com>
2215
2216 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2217 fails.
2218
2219 2017-09-29 Pedro Alves <palves@redhat.com>
2220
2221 * linux-low.c (handle_extended_wait): Pass parent thread instead
2222 of process to thread_db_notice_clone.
2223 * linux-low.h (thread_db_notice_clone): Replace parent process
2224 parameter with parent thread parameter.
2225 * thread-db.c (find_one_thread): Add comment.
2226 (thread_db_notice_clone): Replace parent process parameter with
2227 parent thread parameter. Temporarily switch to the parent thread.
2228
2229 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2230
2231 * gdbthread.h: Include "common-gdbthread.h".
2232 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2233 "if" when validating the ptid.
2234 * remote-utils.c: Include "gdbthread.h".
2235 (prepare_resume_reply): Use "switch_to_thread".
2236 * target.c (done_accessing_memory): Likewise.
2237
2238 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2239
2240 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2241 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2242 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2243 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2244 s390x-gs-linux64-ipa.o to ipa_obj.
2245 * linux-s390-low.c (HWCAP_S390_GS): New define.
2246 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2247 New functions.
2248 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2249 (s390_arch_setup): Check for guarded-storage support and choose
2250 appropriate tdesc.
2251 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2252 init_registers_s390x_gs_linux64.
2253 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2254 enum value.
2255 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2256 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2257
2258 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2259
2260 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2261
2262 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2263
2264 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2265 (thread_db_thread_handle): Declare.
2266 * linux-low.c (linux_target_ops): Initialize thread_handle.
2267 * server.c (handle_qxfer_threads_worker): Add support for
2268 "handle" attribute.
2269 * target.h (struct target_ops): Add new function pointer,
2270 thread_handle.
2271 (target_thread_handle): Define.
2272 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2273 field in lwp.
2274 (thread_db_thread_handle): New function.
2275
2276 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2277
2278 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2279 * linux-low.h (thread_db_notice_clone): Declare.
2280 * thread-db.c (thread_db_notice_clone): New function.
2281
2282 2017-09-21 Pedro Alves <palves@redhat.com>
2283
2284 * server.c (gdb_read_memory, handle_status, process_serial_event)
2285 (handle_serial_event, handle_target_event): Adjust to
2286 set_desired_thread prototype change.
2287 * target.c (set_desired_thread): Remove 'use_general' parameter
2288 and adjust.
2289 * target.h (set_desired_thread): Remove 'use_general' parameter.
2290
2291 2017-09-20 Tom Tromey <tom@tromey.com>
2292
2293 * target.c (target_terminal::terminal_state): Define.
2294 (target_terminal::init): Rename from target_terminal_init.
2295 (target_terminal::inferior): Rename from
2296 target_terminal_inferior.
2297 (target_terminal::ours): Rename from target_terminal_ours.
2298 (target_terminal::ours_for_output, target_terminal::info): New.
2299
2300 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2301
2302 * server.c (accumulate_file_name_length): Remove.
2303 (emit_dll_description): Adjust to std::string change.
2304 (handle_qxfer_libraries): Use std::string to hold document.
2305
2306 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2307
2308 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2309 return type of xml_escape_text.
2310 * server.c (emit_dll_description): Likewise.
2311
2312 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2313
2314 * server.c (captured_main): Accept argument for --selftest.
2315 Update run_tests call.
2316 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2317 when registering selftests.
2318
2319 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2320
2321 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2322 instead of "VEC" for "target_desc.reg_defs".
2323 (regcache_cpy): Likewise.
2324 (registers_to_string): Likewise.
2325 (registers_from_string): Likewise.
2326 (find_regno): Likewise.
2327 (supply_regblock): Likewise.
2328 (regcache_raw_read_unsigned): Likewise.
2329 * tdesc.c (init_target_desc): Likewise.
2330 (tdesc_create_reg): Likewise.
2331 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2332 (struct target_desc) <reg_defs>: Convert to "std::vector".
2333 (target_desc): Do not initialize "reg_defs".
2334 (~target_desc): Update code to use "std::vector" instead of "VEC"
2335 for "target_desc.reg_defs".
2336 (operator==): Likewise.
2337
2338 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2339
2340 * inferiors.h (thread_to_gdb_id): Remove.
2341 * inferiors.c (thread_to_gdb_id): Remove.
2342 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2343 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2344 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2345 Likewise.
2346 * nto-low.c (nto_fetch_registers, nto_store_registers,
2347 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2348
2349 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2350
2351 * inferiors.h (gdb_id_to_thread_id): Remove.
2352 * inferiors.c (gdb_id_to_thread_id): Remove.
2353 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2354 removal. Move pid declaration closer to where it's used.
2355
2356 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2357
2358 * server.c (handle_detach): New function.
2359 (process_serial_event): Move code out, call handle_detach.
2360
2361 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2362
2363 * server.c (require_running): Rename to ...
2364 (require_running_or_return): ... this ...
2365 (require_running_or_break): ... and this.
2366 (handle_query, process_serial_event): Adjust.
2367
2368 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2369
2370 * linux-low.c (linux_set_resume_request): Remove unused
2371 variables.
2372
2373 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2374
2375 * server.c (first_thread_of): Remove.
2376 (process_serial_event): Replace usage of first_thread_of with
2377 find_any_thread_of_pid.
2378 * tracepoint.c (same_process_p): Remove.
2379 (gdb_agent_about_to_close): Replace usage of same_process_p with
2380 find_any_thread_of_pid.
2381 * linux-x86-low.c (same_process_callback): Remove.
2382 (x86_arch_setup_process_callback): Replace usage of
2383 same_process_callback with find_any_thread_of_pid.
2384 * thread-db.c (any_thread_of): Remove.
2385 (switch_to_process): Replace usage of any_thread_of with
2386 find_any_thread_of_pid.
2387 * inferiors.c (thread_pid_matches_callback): Remove.
2388 (find_thread_process): Adjust to use find_any_thread_of_pid.
2389
2390 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2391
2392 * regcache.c (get_thread_regcache): Guard calls to "memset"
2393 with "!VEC_empty".
2394
2395 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2396
2397 * linux-low.c (handle_extended_wait): Use
2398 "allocate_target_description" instead of "XNEW".
2399 * linux-x86-low.c (initialize_low_arch): Likewise.
2400
2401 2017-09-05 Yao Qi <yao.qi@linaro.org>
2402
2403 * configure.srv (srv_i386_regobj): Remove.
2404 (srv_amd64_regobj): Remove.
2405 (srv_regobj): Set it to "" for x86 non-linux targets.
2406 * linux-x86-tdesc.c (i386_linux_read_description):
2407 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2408 (init_registers_i386): Remove the declaration.
2409 (tdesc_i386): Remove the declaration.
2410 (lynx_i386_arch_setup): Call i386_create_target_description.
2411 * nto-x86-low.c: Likewise.
2412 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2413 [!__x86_64__]: include arch/i386.h.
2414 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2415
2416 2017-09-05 Yao Qi <yao.qi@linaro.org>
2417
2418 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2419 i386/amd64-XXX-linux from it.
2420
2421 2017-09-05 Yao Qi <yao.qi@linaro.org>
2422
2423 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2424 false.
2425 (ipa_amd64_linux_regobj): Remove.
2426 (ipa_x32_linux_regobj): Remove.
2427
2428 2017-09-05 Yao Qi <yao.qi@linaro.org>
2429
2430 * Makefile.in (arch-amd64.o): New rule.
2431 * configure.srv: Append arch-amd64.o.
2432 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2433 (get_ipa_tdesc): Call amd64_linux_read_description.
2434 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2435 and init_registers_amd64_XXX.
2436 * linux-x86-low.c (x86_linux_read_description): Call
2437 amd64_linux_read_description.
2438 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2439 (initialize_low_arch): Don't call init_registers_x32_XXX and
2440 init_registers_amd64_XXX.
2441 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2442 and tdesc_amd64_XXX.
2443 [__x86_64__] (amd64_tdesc_test): New function.
2444 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2445 and init_registers_amd64_XXX.
2446 * linux-x86-tdesc.c: Include arch/amd64.h.
2447 (xcr0_to_tdesc_idx): New function.
2448 (i386_linux_read_description): New function.
2449 (amd64_get_ipa_tdesc_idx): New function.
2450 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2451 (amd64_get_ipa_tdesc): Declare.
2452
2453 2017-09-05 Yao Qi <yao.qi@linaro.org>
2454
2455 * configure.srv (srv_i386_linux_xmlfiles): Remove
2456 i386/i386-XXX-linux.xml from it.
2457
2458 2017-09-05 Yao Qi <yao.qi@linaro.org>
2459
2460 * configure.srv: Set srv_i386_linux_regobj empty if $development
2461 is false.
2462 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2463 initialize_low_tdesc.
2464 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2465 with #if initialize_low_tdesc.
2466 * linux-x86-tdesc-selftest.c: New file.
2467 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2468
2469 2017-09-05 Yao Qi <yao.qi@linaro.org>
2470
2471 * Makefile.in (arch-i386.o): New rule.
2472 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2473 (x86_64-*-linux*): Likewise.
2474 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2475 include arch/i386.h.
2476 (i386_linux_read_description): Remove code and call
2477 i386_create_target_description.
2478 * tdesc.c (allocate_target_description): New function.
2479 * tdesc.h (set_tdesc_architecture): Remove declaration.
2480 (set_tdesc_osabi): Likewise.
2481
2482 2017-09-05 Yao Qi <yao.qi@linaro.org>
2483
2484 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2485 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2486 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2487 .xmltarget.
2488 * server.c (get_features_xml): Call tdesc_get_features_xml.
2489 * tdesc.c (set_tdesc_architecture): New function.
2490 (set_tdesc_osabi): New function.
2491 (tdesc_get_features_xml): New function.
2492 (tdesc_create_feature): Add an argument.
2493 * tdesc.h (struct target_desc) <features>: New field.
2494 <arch, osabi>: New field.
2495 (~target_desc): xfree features, arch, and osabi.
2496 (target_desc::oerator==): Don't compare .xmltarget.
2497 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2498 (set_tdesc_osabi): Likewise.
2499 (tdesc_get_features_xml): Likewise.
2500
2501 2017-09-05 Yao Qi <yao.qi@linaro.org>
2502
2503 * linux-x86-tdesc.c: Include selftest.h.
2504 (i386_tdesc_test): New function.
2505 (initialize_low_tdesc): Call selftests::register_test.
2506 * tdesc.h: Include regdef.h.
2507 (target_desc): Override operator == and !=.
2508
2509 2017-09-05 Yao Qi <yao.qi@linaro.org>
2510
2511 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2512 (ipa_obj): Likewise.
2513 * linux-i386-ipa.c: Include common/x86-xstate.h
2514 (get_ipa_tdesc): Call i386_linux_read_description.
2515 (initialize_low_tracepoint): Don't call init_registers_XXX
2516 functions, call initialize_low_tdesc instead.
2517 * linux-x86-low.c (x86_linux_read_description): Call
2518 i386_linux_read_description.
2519 (initialize_low_arch): Don't call init_registers_i386_XXX
2520 functions, call initialize_low_tdesc.
2521 * linux-x86-tdesc.c: New file.
2522 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2523 (i386_get_ipa_tdesc_idx): Declare.
2524 (i386_get_ipa_tdesc): Declare.
2525 (initialize_low_tdesc): Declare.
2526
2527 2017-09-05 Yao Qi <yao.qi@linaro.org>
2528
2529 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2530 instead of 0.
2531
2532 2017-09-05 Yao Qi <yao.qi@linaro.org>
2533
2534 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2535 * regcache.c (get_thread_regcache): Use VEC_length.
2536 (init_register_cache): Likewise.
2537 (regcache_cpy): Likewise.
2538 (registers_to_string): Iterate reg_defs via VEC_iterate.
2539 (find_regno): Likewise.
2540 (find_register_by_number): Use VEC_index.
2541 (register_size): Call find_register_by_number.
2542 (register_data): Call find_register_by_number.
2543 (supply_regblock): Use VEC_length.
2544 (regcache_raw_read_unsigned): Likewise.
2545 * tdesc.c (init_target_desc): Iterate reg_defs via
2546 VEC_iterate.
2547 (default_description): Update initializer.
2548 (copy_target_description): Don't update field num_registers.
2549 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2550 <num_registers>: Remove.
2551
2552 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2553
2554 * Makefile.in (.SECONDARY): Define target.
2555
2556 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2557
2558 * linux-low.c (linux_wait_1): Adjust.
2559 * server.c (queue_stop_reply_callback): Adjust.
2560
2561 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2562
2563 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2564 QEnvironmentUnset and QEnvironmentReset packets.
2565 (handle_query): Inform remote that QEnvironmentHexEncoded,
2566 QEnvironmentUnset and QEnvironmentReset are supported.
2567
2568 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2569
2570 * inferiors.h (inferior_target_data): Rename to ...
2571 (thread_target_data): ... this.
2572 (inferior_regcache_data): Rename to ...
2573 (thread_regcache_data): ... this.
2574 (set_inferior_regcache_data): Rename to ...
2575 (set_thread_regcache_data): ... this.
2576 * inferiors.c (inferior_target_data): Rename to ...
2577 (thread_target_data): ... this.
2578 (inferior_regcache_data): Rename to ...
2579 (thread_regcache_data): ... this.
2580 (set_inferior_regcache_data): Rename to ...
2581 (set_thread_regcache_data): ... this.
2582 (free_one_thread): Update.
2583 * linux-low.h (get_thread_lwp): Update.
2584 * regcache.c (get_thread_regcache): Update.
2585 (regcache_invalidate_thread): Update.
2586 (free_register_cache_thread): Update.
2587 * win32-i386-low.c (update_debug_registers_callback): Update.
2588 (win32_get_current_dr): Update.
2589 * win32-low.c (thread_rec): Update.
2590 (delete_thread_info): Update.
2591 (continue_one_thread): Update.
2592 (suspend_one_thread): Update.
2593
2594 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2595
2596 * inferiors.c (set_inferior_target_data): Remove.
2597 * inferiors.h (set_inferior_target_data): Remove.
2598
2599 2017-08-18 Yao Qi <yao.qi@linaro.org>
2600
2601 * Makefile.in (OBS): Add selftest.o.
2602 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2603 * configure, config.in: Re-generated.
2604 * server.c: Include common/sefltest.h.
2605 (captured_main): Handle option --selftest.
2606
2607 2017-08-09 Yao Qi <yao.qi@linaro.org>
2608
2609 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2610 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2611 i386-avx-mpx.o and i386-mmx.o.
2612 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2613 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2614 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2615 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2616 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2617 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2618 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2619 i386/amd64-avx-mpx.xml.
2620
2621 2017-08-09 Yao Qi <yao.qi@linaro.org>
2622
2623 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2624 and x32-avx-avx512.o.
2625 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2626 i386/x32-avx-avx512.xml.
2627
2628 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2629
2630 * tracepoint.h (enum class fast_tpoint_collect_result): New
2631 enumeration.
2632 (fast_tracepoint_collecting): Change return type to
2633 fast_tpoint_collect_result.
2634 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2635 * linux-low.h: Include tracepoint.h.
2636 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2637 fast_tpoint_collect_result.
2638 * linux-low.c (handle_tracepoints): Adjust.
2639 (linux_fast_tracepoint_collecting): Change return type to
2640 fast_tpoint_collect_result.
2641 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2642 linux_wait_1, stuck_in_jump_pad_callback,
2643 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2644 proceed_one_lwp): Adjust to type change.
2645
2646 2017-07-10 Yao Qi <yao.qi@linaro.org>
2647
2648 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2649
2650 2017-06-29 Yao Qi <yao.qi@linaro.org>
2651
2652 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2653 Remove.
2654 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2655
2656 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2657
2658 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2659
2660 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2661
2662 * linux-low.c (linux_create_inferior): Adjust code to access the
2663 environment information via 'gdb_environ' class.
2664 * lynx-low.c (lynx_create_inferior): Likewise.
2665 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2666 (get_environ): Return a pointer to 'our_environ'.
2667 (captured_main): Initialize 'our_environ'.
2668 * server.h (get_environ): Adjust prototype.
2669 * spu-low.c (spu_create_inferior): Adjust code to access the
2670 environment information via 'gdb_environ' class.
2671
2672 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2673
2674 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2675 usage of "register" keyword.
2676
2677 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2678
2679 * configure: Re-generate.
2680
2681 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2682
2683 * configure: Re-generate.
2684
2685 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2686
2687 * Makefile.in (COMPILE.pre): Add "-x c++".
2688
2689 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2690
2691 * fork-child.c: Conditionally include <signal.h>.
2692
2693 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2694
2695 * server.c (handle_general_set): Handle new packet
2696 "QStartupWithShell".
2697 (handle_query): Add "QStartupWithShell" to the list of supported
2698 packets.
2699 (gdbserver_usage): Add help text explaining the
2700 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2701 options.
2702 (captured_main): Recognize and act upon the presence of the new
2703 CLI options.
2704
2705 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2706 Pedro Alves <palves@redhat.com>
2707
2708 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2709 * configure: Regenerate.
2710 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2711 "fork-inferior.o".
2712 (i[34567]86-*-lynxos*): Likewise.
2713 (spu*-*-*): Likewise.
2714 * fork-child.c: New file.
2715 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2716 and "environ.h".
2717 (linux_ptrace_fun): New function.
2718 (linux_create_inferior): Adjust function prototype to reflect
2719 change on "target.h". Adjust function code to use
2720 "fork_inferior".
2721 (linux_request_interrupt): Delete "signal_pid".
2722 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2723 (lynx_ptrace_fun): New function.
2724 (lynx_create_inferior): Adjust function prototype to reflect
2725 change on "target.h". Adjust function code to use
2726 "fork_inferior".
2727 * nto-low.c (nto_create_inferior): Adjust function prototype and
2728 code to reflect change on "target.h". Update comments.
2729 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2730 "common-terminal.h" and "environ.h".
2731 (terminal_fd): Moved to fork-child.c.
2732 (old_foreground_pgrp): Likewise.
2733 (restore_old_foreground_pgrp): Likewise.
2734 (last_status): Make it global.
2735 (last_ptid): Likewise.
2736 (our_environ): New variable.
2737 (startup_with_shell): Likewise.
2738 (program_name): Likewise.
2739 (program_argv): Rename to...
2740 (program_args): ...this.
2741 (wrapper_argv): New variable.
2742 (start_inferior): Delete function.
2743 (get_exec_wrapper): New function.
2744 (get_exec_file): Likewise.
2745 (get_environ): Likewise.
2746 (prefork_hook): Likewise.
2747 (post_fork_inferior): Likewise.
2748 (postfork_hook): Likewise.
2749 (postfork_child_hook): Likewise.
2750 (handle_v_run): Update code to deal with arguments coming from the
2751 remote host. Update calls from "start_inferior" to
2752 "create_inferior".
2753 (captured_main): Likewise. Initialize environment variable. Call
2754 "have_job_control".
2755 * server.h (post_fork_inferior): New prototype.
2756 (get_environ): Likewise.
2757 (last_status): Declare.
2758 (last_ptid): Likewise.
2759 (signal_pid): Likewise.
2760 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2761 (spu_ptrace_fun): New function.
2762 (spu_create_inferior): Adjust function prototype to reflect change
2763 on "target.h". Adjust function code to use "fork_inferior".
2764 * target.c (target_terminal_init): New function.
2765 (target_terminal_inferior): Likewise.
2766 (target_terminal_ours): Likewise.
2767 * target.h: Include <vector>.
2768 (struct target_ops) <create_inferior>: Update prototype.
2769 (create_inferior): Update macro.
2770 * utils.c (gdb_flush_out_err): New function.
2771 * win32-low.c (win32_create_inferior): Adjust function prototype
2772 and code to reflect change on "target.h".
2773
2774 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2775
2776 * inferiors.c (switch_to_thread): New function.
2777
2778 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2779
2780 * Makefile.in (SFILE): Add "common/job-control.c".
2781 (OBS): Add "job-control.o".
2782
2783 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2784
2785 * Makefile: Remove "@host_makefile_frag@".
2786
2787 2017-05-05 Pedro Alves <palves@redhat.com>
2788
2789 * configure: Regenerate.
2790
2791 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2792
2793 * configure: Regenerate.
2794
2795 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2796
2797 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2798 software_single_step change of return type to
2799 std::vector<CORE_ADDR>.
2800 * linux-low.c (install_software_single_step_breakpoints):
2801 Likewise.
2802 * linux-low.h (install_software_single_step_breakpoints):
2803 Likewise.
2804
2805 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2806
2807 * remote-utils.c: Include "gdb_termios.h" instead of
2808 "terminal.h".
2809 * terminal.h: Delete file.
2810
2811 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2812
2813 * server.c: Include <vector>.
2814 <program_argv, wrapper_argv>: Convert to std::vector.
2815 (start_inferior): Rewrite function to use C++.
2816 (handle_v_run): Likewise. Update code that calculates the argv
2817 based on the vRun packet; use C++.
2818 (captured_main): Likewise.
2819
2820 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2821
2822 * server.c (handle_v_cont): Initialize thread_resume::thread
2823 with null_ptid.
2824
2825 2017-04-05 Pedro Alves <palves@redhat.com>
2826
2827 * configure: Regenerate.
2828
2829 2017-04-05 Pedro Alves <palves@redhat.com>
2830
2831 * gdbreplay.c (sync_error): Constify.
2832 * linux-x86-low.c (push_opcode): Constify.
2833
2834 2017-04-05 Pedro Alves <palves@redhat.com>
2835
2836 * win32-low.c (get_child_debug_event)
2837 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2838 Report TARGET_WAITKIND_SPURIOUS instead.
2839
2840 2017-04-05 Pedro Alves <palves@redhat.com>
2841
2842 * remote-utils.c (remote_prepare, remote_open): Constify.
2843 * remote-utils.h (remote_prepare, remote_open): Constify.
2844 * server.c (captured_main): Constify 'port' handling.
2845
2846 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2847
2848 * Makefile.in (clean): Clear .deps.
2849
2850 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2851
2852 * .gitignore: Remove generated files, replace with wildcard.
2853 * (clean): Replace removal of generated files with wildcard.
2854 (version.c): Replace with...
2855 (version-generated.c): ...this.
2856 (xml-builtin.c): Replace with...
2857 (xml-builtin-generated.c): ...this.
2858 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2859 (%.c: *regformats*): Replace with...
2860 (%-generated.c: *regformats*): ...this.
2861
2862 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2863
2864 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2865 (xtensa_fill_gregset): Call collect_register_by_name for
2866 threadptr register.
2867 (xtensa_store_gregset): Call supply_register_by_name for
2868 threadptr register.
2869
2870 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2871
2872 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2873 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2874 (xtensa_store_gregset): Call supply_register for all registers in
2875 a0_regnum..a0_regnum + C0_NREGS range.
2876
2877 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2878
2879 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2880 (ax-ipa.o: ax.c): Remove.
2881 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2882 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2883 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2884 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2885 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2886
2887 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2888
2889 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2890 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2891 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2892 (errors-ipa.o: ../common/errors.c): Remove.
2893 (format-ipa.o: ../common/format.c): Remove.
2894 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2895
2896 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2897
2898 * Makefile.in (%-ipa.o: %.c): New rule.
2899 (tracepoint-ipa.o: tracepoint.c): Remove.
2900 (utils-ipa.o: utils.c): Remove.
2901 (remote-utils-ipa.o: remote-utils.c): Remove.
2902 (regcache-ipa.o: regcache.c): Remove.
2903 (i386-linux-ipa.o: i386-linux.c): Remove.
2904 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2905 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2906 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2907 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2908 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2909 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2910 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2911 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2912 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2913 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2914 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2915 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2916 (aarch64-ipa.o: aarch64.c): Remove.
2917 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2918 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2919 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2920 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2921 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2922 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2923 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2924 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2925 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2926 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2927 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2928 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2929 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2930 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2931 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2932 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2933 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2934 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2935 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2936 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2937 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2938 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2939 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2940 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2941 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2942 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2943 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2944 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2945 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2946 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2947 (tdesc-ipa.o: tdesc.c): Remove.
2948 (x32-linux-ipa.o: x32-linux.c): Remove.
2949 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2950 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2951
2952 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2953
2954 * Makefile.in (%.o: ../arch/%.c): New rule.
2955 (arm.o: ../arch/arm.c): Remove.
2956 (arm-linux.o: ../arch/arm-linux.c): Remove.
2957 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2958 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2959
2960 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2961
2962 * Makefile.in (%.o: ../nat/%.c): New rule.
2963 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2964 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2965 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2966 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2967 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2968 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2969 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2970 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2971 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2972 (linux-personality.o: ../nat/linux-personality.c): Remove.
2973 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2974 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2975 (x86-linux.o: ../nat/x86-linux.c): Remove.
2976 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2977 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2978
2979 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2980
2981 * Makefile.in (%.o: ../common/%.c): New rule.
2982 (signals.o: ../common/signals.c): Remove.
2983 (print-utils.o: ../common/print-utils.c): Remove.
2984 (rsp-low.o: ../common/rsp-low.c): Remove.
2985 (common-utils.o: ../common/common-utils.c): Remove.
2986 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2987 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2988 (vec.o: ../common/vec.c): Remove.
2989 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2990 (xml-utils.o: ../common/xml-utils.c): Remove.
2991 (ptid.o: ../common/ptid.c): Remove.
2992 (buffer.o: ../common/buffer.c): Remove.
2993 (format.o: ../common/format.c): Remove.
2994 (filestuff.o: ../common/filestuff.c): Remove.
2995 (agent.o: ../common/agent.c): Remove.
2996 (errors.o: ../common/errors.c): Remove.
2997 (environ.o: ../common/environ.c): Remove.
2998 (common-debug.o: ../common/common-debug.c): Remove.
2999 (cleanups.o: ../common/cleanups.c): Remove.
3000 (common-exceptions.o: ../common/common-exceptions.c): Remove.
3001 (fileio.o: ../common/fileio.c): Remove.
3002 (common-regcache.o: ../common/common-regcache.c): Remove.
3003 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
3004 (new-op.o: ../common/new-op.c): Remove.
3005 (btrace-common.o: ../common/btrace-common.c): Remove.
3006
3007 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3008
3009 * Makefile.in (%.o: ../target/%.c): New rule.
3010 (waitstatus.o: ../target/waitstatus.c): Remove.
3011
3012 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3013
3014 * Makefile.in
3015 (%.c: ../regformats/%.dat,
3016 (%.c: ../regformats/arm/%.dat,
3017 (%.c: ../regformats/i386/%.dat,
3018 (%.c: ../regformats/rs6000/%.dat): New rules.
3019 (aarch64.c): Remove.
3020 (reg-arm.c): Remove.
3021 (arm-with-iwmmxt.c): Remove.
3022 (arm-with-vfpv2.c): Remove.
3023 (arm-with-vfpv3.c): Remove.
3024 (arm-with-neon.c): Remove.
3025 (reg-bfin.c): Remove.
3026 (reg-cris.c): Remove.
3027 (reg-crisv32.c): Remove.
3028 (i386.c): Remove.
3029 (i386-linux.c): Remove.
3030 (i386-avx.c): Remove.
3031 (i386-avx-linux.c): Remove.
3032 (i386-avx-avx512.c): Remove.
3033 (i386-avx-avx512-linux.c): Remove.
3034 (i386-mpx.c): Remove.
3035 (i386-mpx-linux.c): Remove.
3036 (i386-avx-mpx-avx512-pku.c): Remove.
3037 (i386-avx-mpx-avx512-pku-linux.c): Remove.
3038 (i386-avx-mpx.c): Remove.
3039 (i386-avx-mpx-linux.c): Remove.
3040 (i386-mmx.c): Remove.
3041 (i386-mmx-linux.c): Remove.
3042 (reg-ia64.c): Remove.
3043 (reg-m32r.c): Remove.
3044 (reg-m68k.c): Remove.
3045 (reg-cf.c): Remove.
3046 (mips-linux.c): Remove.
3047 (mips-dsp-linux.c): Remove.
3048 (mips64-linux.c): Remove.
3049 (mips64-dsp-linux.c): Remove.
3050 (nios2-linux.c): Remove.
3051 (powerpc-32.c): Remove.
3052 (powerpc-32l.c): Remove.
3053 (powerpc-altivec32l.c): Remove.
3054 (powerpc-cell32l.c): Remove.
3055 (powerpc-vsx32l.c): Remove.
3056 (powerpc-isa205-32l.c): Remove.
3057 (powerpc-isa205-altivec32l.c): Remove.
3058 (powerpc-isa205-vsx32l.c): Remove.
3059 (powerpc-e500l.c): Remove.
3060 (powerpc-64l.c): Remove.
3061 (powerpc-altivec64l.c): Remove.
3062 (powerpc-cell64l.c): Remove.
3063 (powerpc-vsx64l.c): Remove.
3064 (powerpc-isa205-64l.c): Remove.
3065 (powerpc-isa205-altivec64l.c): Remove.
3066 (powerpc-isa205-vsx64l.c): Remove.
3067 (s390-linux32.c): Remove.
3068 (s390-linux32v1.c): Remove.
3069 (s390-linux32v2.c): Remove.
3070 (s390-linux64.c): Remove.
3071 (s390-linux64v1.c): Remove.
3072 (s390-linux64v2.c): Remove.
3073 (s390-te-linux64.c): Remove.
3074 (s390-vx-linux64.c): Remove.
3075 (s390-tevx-linux64.c): Remove.
3076 (s390x-linux64.c): Remove.
3077 (s390x-linux64v1.c): Remove.
3078 (s390x-linux64v2.c): Remove.
3079 (s390x-te-linux64.c): Remove.
3080 (s390x-vx-linux64.c): Remove.
3081 (s390x-tevx-linux64.c): Remove.
3082 (tic6x-c64xp-linux.c): Remove.
3083 (tic6x-c64x-linux.c): Remove.
3084 (tic6x-c62x-linux.c): Remove.
3085 (reg-sh.c): Remove.
3086 (reg-sparc64.c): Remove.
3087 (reg-spu.c): Remove.
3088 (amd64.c): Remove.
3089 (amd64-linux.c): Remove.
3090 (amd64-avx.c): Remove.
3091 (amd64-avx-linux.c): Remove.
3092 (amd64-avx-avx512.c): Remove.
3093 (amd64-avx-avx512-linux.c): Remove.
3094 (amd64-mpx.c): Remove.
3095 (amd64-mpx-linux.c): Remove.
3096 (amd64-avx-mpx-avx512-pku.c): Remove.
3097 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
3098 (amd64-avx-mpx.c): Remove.
3099 (amd64-avx-mpx-linux.c): Remove.
3100 (x32.c): Remove.
3101 (x32-linux.c): Remove.
3102 (x32-avx.c): Remove.
3103 (x32-avx-linux.c): Remove.
3104 (x32-avx-avx512.c): Remove.
3105 (x32-avx-avx512-linux.c): Remove.
3106 (reg-xtensa.c): Remove.
3107 (reg-tilegx.c): Remove.
3108 (reg-tilegx32.c): Remove.
3109
3110 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
3111
3112 * Makefile.in (SFILES): Add "common/environ.c".
3113 (OBJS): Add "common/environ.h".
3114
3115 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
3116
3117 * configure.ac: Check if the fs_base and gs_base members of
3118 `struct user_regs_struct' exist.
3119 * config.in: Regenerated.
3120 * configure: Likewise.
3121
3122 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
3123
3124 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3125 target_read_memory.
3126 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3127 (get_next_pcs_syscall_next_pc): Likewise.
3128
3129 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
3130
3131 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3132 * nto-x86-low.c: Likewise.
3133
3134 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3135
3136 * Makefile.in: Include disable-implicit-rules.mk.
3137
3138 2016-11-23 Pedro Alves <palves@redhat.com>
3139
3140 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3141 (debug_vprintf): Use std::chrono::steady_clock instead of
3142 gettimeofday. Use '.' instead of ':'.
3143 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3144 (get_timestamp): Use std::chrono::steady_clock instead of
3145 gettimeofday.
3146
3147 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3148
3149 * Makefile.in: Fix whitespace formatting.
3150
3151 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3152
3153 * Makefile.in (SFILES, OBS): Flatten list and order
3154 alphabetically.
3155
3156 2016-11-23 Pedro Alves <palves@redhat.com>
3157
3158 * event-loop.c (handle_file_event): Use warning.
3159 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3160 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3161 Use warning.
3162
3163 2016-11-23 Pedro Alves <palves@redhat.com>
3164
3165 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3166 output.
3167 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3168 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3169 debug_printf and debug_flush for debug output.
3170 * server.c (handle_general_set): Likewise.
3171 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3172 output.
3173
3174 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3175
3176 * Makefile.in (.c.o): Replace rule with ...
3177 (%.o: %.c): ... this one.
3178
3179 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3180
3181 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3182 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3183 make.
3184 * configure.ac: Remove checks for the make program.
3185 * configure: Re-generate.
3186
3187 2016-10-28 Pedro Alves <palves@redhat.com>
3188
3189 * Makefile.in (CXX_DIALECT): Get from configure.
3190 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3191 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3192 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3193 * config.in: Regenerate.
3194 * configure: Regenerate.
3195
3196 2016-10-27 Yao Qi <yao.qi@linaro.org>
3197
3198 * linux-low.c (linux_supports_range_stepping): Return true if
3199 can_software_single_step return true.
3200
3201 2016-10-27 Yao Qi <yao.qi@linaro.org>
3202
3203 * inferiors.c (find_inferior_in_random): New function.
3204 * inferiors.h (find_inferior_in_random): Declare.
3205 * linux-low.c (linux_wait_for_event_filtered): Call
3206 find_inferior_in_random instead of find_inferior.
3207
3208 2016-10-27 Yao Qi <yao.qi@linaro.org>
3209
3210 * linux-low.c (linux_wait_1): If single-step breakpoints are
3211 inserted, remove them.
3212
3213 2016-10-26 Pedro Alves <palves@redhat.com>
3214
3215 * linux-low.c (handle_extended_wait): Link parent/child fork
3216 threads.
3217 (linux_wait_1): Unlink them.
3218 (linux_set_resume_request): Ignore resume requests for
3219 already-resumed and unhandled fork child threads.
3220 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3221 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3222 New functions.
3223 (handle_v_requests) <vCont>: Don't call require_running.
3224 * server.h (in_queued_stop_replies): New declaration.
3225
3226 2016-10-24 Yao Qi <yao.qi@linaro.org>
3227
3228 PR server/20733
3229 * linux-aarch64-low.c (append_insns): Cast the return value to
3230 'uint32_t *'.
3231
3232 2016-10-10 Yao Qi <yao.qi@linaro.org>
3233
3234 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3235
3236 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3237
3238 * target.c (target_supports_multi_process): New function, moved
3239 from...
3240 * target.h (target_supports_multi_process): ... here. Remove
3241 macro.
3242
3243 2016-10-05 Tom Tromey <tom@tromey.com>
3244
3245 PR remote/20655:
3246 * tracepoint.c (handle_tracepoint_bkpts): Check
3247 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3248
3249 2016-10-05 Yao Qi <yao.qi@linaro.org>
3250
3251 * configure.srv: Update the path of arm-*.xml files.
3252
3253 2016-10-05 Terry Guo <terry.guo@arm.com>
3254 Yao Qi <yao.qi@linaro.org>
3255
3256 * Makefile.in: Adjust the path of rules.
3257 * configure.srv: Update the path of xml files.
3258 * regformats/arm-with-iwmmxt.dat: Regenerated.
3259 * regformats/arm-with-neon.dat: Likewise.
3260 * regformats/arm-with-vfpv2.dat: Likewise.
3261 * regformats/arm-with-vfpv3.dat Likewise.
3262
3263 2016-09-30 Yao Qi <yao.qi@linaro.org>
3264
3265 PR gdbserver/20627
3266 * target.c (target_stop_and_wait): Don't call
3267 target_continue_no_signal, use resume_stop instead.
3268
3269 2016-09-26 Yao Qi <yao.qi@linaro.org>
3270
3271 * linux-low.c (linux_wait_1): Call debug_exit.
3272
3273 2016-09-23 Pedro Alves <palves@redhat.com>
3274
3275 * Makefile.in (SFILES): Add common/new-op.c.
3276 (OBS): Add common/new-op.o.
3277 (new-op.o): New rule.
3278
3279 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3280
3281 * .gitinore: Ignore more files.
3282
3283 2016-09-21 Yao Qi <yao.qi@linaro.org>
3284
3285 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3286 23.
3287
3288 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3289
3290 * server.c (start_inferior): Call target_mourn_inferior instead of
3291 mourn_inferior; pass ptid_t argument to it.
3292 (resume): Likewise.
3293 (handle_target_event): Likewise.
3294 * target.c (target_mourn_inferior): New function.
3295 * target.h (mourn_inferior): Delete macro.
3296
3297 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3298
3299 * linux-low.c (lwp_is_stepping): New function.
3300
3301 2016-09-06 Carl Love <cel@us.ibm.com>
3302
3303 * server.c (start_inferior): Fixed comment, requested comment change
3304 didn't get updated correctly. Removed reference to ptrace () call as
3305 it is only true on Linux systems.
3306
3307 2016-09-06 Carl Love <cel@us.ibm.com>
3308
3309 * server.c (start_inferior): Do not call
3310 function target_post_create_inferior () if the
3311 inferior process has already exited.
3312
3313 2016-09-05 Pedro Alves <palves@redhat.com>
3314
3315 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3316 (COMPILE.pre, CC_LD): Use CXX directly.
3317 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3318 * acinclude.m4: Don't include build-with-cxx.m4.
3319 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3320 * configure: Regenerate.
3321
3322 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3323
3324 PR gdb/19495
3325 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3326 call writing data to own_buf.
3327
3328 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3329
3330 * target.c (mywait): Call target_wait instead of
3331 the_target->wait.
3332 (target_wait): New function.
3333
3334 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3335
3336 * server.c (start_inferior): New variable 'ptid'. Replace calls
3337 to the_target->resume by target_continue{,_no_signal}, depending
3338 on the case.
3339 * target.c (target_stop_and_wait): Call target_continue_no_signal
3340 instead of the_target->resume.
3341 (target_continue): New function.
3342
3343 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3344
3345 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3346
3347 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3348
3349 PR server/20491
3350 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3351 ps_prochandle.
3352 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3353 * linux-arm-low.c (ps_get_thread_area): Likewise.
3354 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3355 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3356 * linux-mips-low.c (ps_get_thread_area): Likewise.
3357 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3358 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3359 * linux-x86-low.c (ps_get_thread_area): Likewise.
3360 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3361
3362 2016-08-19 Pedro Alves <palves@redhat.com>
3363
3364 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3365
3366 2016-08-19 Pedro Alves <palves@redhat.com>
3367
3368 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3369 comment. Use memcpy instead of casting through unsigned long.
3370
3371 2016-08-19 Pedro Alves <palves@redhat.com>
3372
3373 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3374 allocating around 0x80000000.
3375
3376 2016-08-19 Pedro Alves <palves@redhat.com>
3377
3378 PR gdb/20415
3379 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3380 (x32-avx512-linux-ipa.o): New rules.
3381 * configure.ac (x86_64-*-linux*): New x32 check.
3382 * configure.srv (ipa_x32_linux_regobj): New.
3383 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3384 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3385 descriptions.
3386 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3387 descriptions.
3388 * configure: Regenerate.
3389
3390 2016-08-09 Pedro Alves <palves@redhat.com>
3391
3392 PR gdb/18653
3393 * Makefile.in (OBS): Add signals-state-save-restore.o.
3394 (signals-state-save-restore.o): New rule.
3395 * config.in: Regenerate.
3396 * configure: Regenerate.
3397 * linux-low.c: Include "signals-state-save-restore.h".
3398 (linux_create_inferior): Call
3399 restore_original_signals_state.
3400 * server.c: Include "dispositions-save-restore.h".
3401 (captured_main): Call save_original_signals_state.
3402
3403 2016-08-05 Pedro Alves <palves@redhat.com>
3404
3405 * configure: Regenerate.
3406
3407 2016-08-04 Yao Qi <yao.qi@linaro.org>
3408
3409 * linux-low.c (regsets_fetch_inferior_registers): Check
3410 errno is ESRCH or not.
3411
3412 2016-08-02 Yao Qi <yao.qi@linaro.org>
3413
3414 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3415 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3416 (thread_db_load_search): Update.
3417 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3418 td_ta_set_event and td_ta_event_getmsg.
3419
3420 2016-07-26 Pedro Alves <palves@redhat.com>
3421
3422 PR server/20414
3423 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3424 of unsigned long for 64-bit registers and use uint32_t instead of
3425 unsigned int for 32-bit registers.
3426
3427 2016-07-26 Pedro Alves <palves@redhat.com>
3428
3429 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3430 to 'ptrace'.
3431
3432 2016-07-21 Tom Tromey <tom@tromey.com>
3433
3434 * configure: Rebuild.
3435
3436 2016-07-21 Yao Qi <yao.qi@linaro.org>
3437
3438 * mem-break.c (find_gdb_breakpoint): Cast bp to
3439 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3440
3441 2016-07-21 Yao Qi <yao.qi@linaro.org>
3442
3443 * server.c (handle_v_requests): Support s and S actions
3444 if target_supports_software_single_step return true.
3445
3446 2016-07-21 Yao Qi <yao.qi@linaro.org>
3447
3448 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3449 is resume_step, call maybe_hw_step.
3450 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3451 and unstop them.
3452 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3453 breakpoints or not.
3454 (proceed_one_lwp): If resume request is resume_step, install
3455 reinsert breakpoints and call maybe_hw_step.
3456
3457 2016-07-21 Yao Qi <yao.qi@linaro.org>
3458
3459 * linux-low.c (proceed_one_lwp): Declare.
3460 (linux_resume_one_thread): Remove local variable 'step'.
3461 Lift code enqueue signal. Call proceed_one_lwp instead of
3462 linux_resume_one_lwp.
3463
3464 2016-07-21 Yao Qi <yao.qi@linaro.org>
3465
3466 * linux-low.c (linux_resume_one_thread): Call
3467 enqueue_pending_signal.
3468
3469 2016-07-21 Yao Qi <yao.qi@linaro.org>
3470
3471 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3472 * inferiors.c (do_restore_current_thread_cleanup): New function.
3473 (make_cleanup_restore_current_thread): Likewise.
3474 * linux-low.c (install_software_single_step_breakpoints): Call
3475 make_cleanup_restore_current_thread. Switch current_thread to
3476 thread.
3477
3478 2016-07-21 Yao Qi <yao.qi@linaro.org>
3479
3480 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3481 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3482 (clone_one_breakpoint): Likewise.
3483 (delete_reinsert_breakpoints): Change parameter to thread.
3484 Callers updated.
3485 (has_reinsert_breakpoints): Likewise.
3486 (uninsert_reinsert_breakpoints): Likewise.
3487 (reinsert_reinsert_breakpoints): Likewise.
3488 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3489 (delete_reinsert_breakpoints): Likewise.
3490 (reinsert_reinsert_breakpoints): Likewise.
3491 (uninsert_reinsert_breakpoints): Likewise.
3492 (has_reinsert_breakpoints): Likewise.
3493
3494 2016-07-21 Yao Qi <yao.qi@linaro.org>
3495
3496 * inferiors.c (get_thread_process): Make parameter const.
3497 * inferiors.h (get_thread_process): Update declaration.
3498 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3499 Add new parameters child_thread and parent_thread. Callers
3500 updated.
3501 * mem-break.h (clone_all_breakpoints): Update declaration.
3502
3503 2016-07-21 Yao Qi <yao.qi@linaro.org>
3504
3505 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3506 <command_list, handler>: Remove.
3507 (struct gdb_breakpoint): New.
3508 (struct other_breakpoint): New.
3509 (struct reinsert_breakpoint): New.
3510 (is_gdb_breakpoint): New function.
3511 (any_persistent_commands): Update command_list if
3512 is_gdb_breakpoint returns true.
3513 (set_breakpoint): Create breakpoints according to their types.
3514 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3515 (set_gdb_breakpoint_1): Likewise.
3516 (set_gdb_breakpoint): Likewise.
3517 (clear_breakpoint_conditions): Change parameter type to
3518 'struct gdb_breakpoint *'.
3519 (clear_breakpoint_commands): Likewise.
3520 (clear_breakpoint_conditions_and_commands): Likewise.
3521 (add_condition_to_breakpoint): Likewise.
3522 (add_breakpoint_condition): Likewise.
3523 (add_commands_to_breakpoint): Likewise.
3524 (check_breakpoints): Check other_breakpoint.
3525 (clone_one_breakpoint): Clone breakpopint according to its type.
3526 * mem-break.h (struct gdb_breakpoint): Declare.
3527 (set_gdb_breakpoint): Update declaration.
3528 (clear_breakpoint_conditions_and_commands): Likewise.
3529 (add_breakpoint_condition): Likewise.
3530 (add_breakpoint_commands): Likewise.
3531 * server.c (process_point_options): Change parameter type to
3532 'struct gdb_breakpoint *'.
3533
3534 2016-07-21 Yao Qi <yao.qi@linaro.org>
3535
3536 * mem-break.c (set_breakpoint_at): Rename it to ...
3537 (set_breakpoint_type_at): ... it.
3538 (set_breakpoint_at): Call set_breakpoint_type_at.
3539 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3540 * mem-break.h (set_breakpoint_at): Update comments.
3541
3542 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3543
3544 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3545 to buf parameter.
3546 (nios2_store_gregset): Likewise.
3547
3548 2016-07-01 Pedro Alves <palves@redhat.com>
3549 Antoine Tremblay <antoine.tremblay@ericsson.com>
3550
3551 * linux-low.c: Change interface to take the target lwp_info
3552 pointer directly and return void. Handle detaching from a zombie
3553 thread.
3554 (linux_detach_lwp_callback): New function.
3555 (linux_detach): Detach from the leader thread after detaching from
3556 the clone threads.
3557
3558 2016-06-28 Yao Qi <yao.qi@linaro.org>
3559
3560 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3561 for variable new_offset.
3562 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3563 (aarch64_ftrace_insn_reloc_cb): Likewise.
3564 (aarch64_ftrace_insn_reloc_tb): Likewise.
3565 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3566 PRIx64 instead of PRIx32.
3567
3568 2016-06-28 Yao Qi <yao.qi@linaro.org>
3569
3570 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3571 (the_low_target): Install arm_get_syscall_trapinfo.
3572
3573 2016-06-28 Yao Qi <yao.qi@linaro.org>
3574
3575 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3576 function.
3577 (the_low_target): Install aarch64_get_syscall_trapinfo.
3578
3579 2016-06-28 Yao Qi <yao.qi@linaro.org>
3580
3581 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3582 Callers updated.
3583 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3584 Remove parameter sysno.
3585 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3586 sysret.
3587
3588 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3589
3590 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3591 (s390_emit_ne_goto): Likewise.
3592 (s390_emit_lt_goto): Likewise.
3593 (s390_emit_le_goto): Likewise.
3594 (s390_emit_gt_goto): Likewise.
3595 (s390_emit_ge_goto): Likewise.
3596 (s390x_emit_eq_goto): Likewise.
3597 (s390x_emit_ne_goto): Likewise.
3598 (s390x_emit_lt_goto): Likewise.
3599 (s390x_emit_le_goto): Likewise.
3600 (s390x_emit_gt_goto): Likewise.
3601 (s390x_emit_ge_goto): Likewise.
3602 (s390_emit_ops_impl): Mark variable static.
3603 (s390x_emit_ops): Likewise.
3604
3605 2016-06-17 Yao Qi <yao.qi@linaro.org>
3606
3607 * linux-low.c (handle_extended_wait): Call
3608 uninsert_reinsert_breakpoints for the parent process. Remove
3609 reinsert breakpoints from the child process. Reinsert them to
3610 the parent process when vfork is done.
3611 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3612 (reinsert_reinsert_breakpoints): New function.
3613 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3614 (reinsert_reinsert_breakpoints): Declare.
3615
3616 2016-06-17 Yao Qi <yao.qi@linaro.org>
3617
3618 * linux-low.c (handle_extended_wait): If the parent is doing
3619 step-over, remove the reinsert breakpoints from the forked child.
3620
3621 2016-06-17 Yao Qi <yao.qi@linaro.org>
3622
3623 * linux-low.c (unsuspend_all_lwps): Declare.
3624 (linux_low_filter_event): If thread exited, call finish_step_over.
3625 If step-over is finished, unsuspend other threads.
3626
3627 2016-06-17 Yao Qi <yao.qi@linaro.org>
3628
3629 * linux-low.c (linux_resume_one_lwp_throw): Assert
3630 has_reinsert_breakpoints returns false.
3631 * mem-break.c (delete_disabled_breakpoints): Assert
3632 bp type isn't reinsert_breakpoint.
3633
3634 2016-06-17 Yao Qi <yao.qi@linaro.org>
3635
3636 * linux-low.c (maybe_hw_step): New function.
3637 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3638 (finish_step_over): Switch current_thread to lwp temporarily,
3639 and assert has_reinsert_breakpoints returns true.
3640 (proceed_one_lwp): Call maybe_hw_step.
3641 * mem-break.c (has_reinsert_breakpoints): New function.
3642 * mem-break.h (has_reinsert_breakpoints): Declare.
3643
3644 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3645
3646 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3647
3648 2016-05-17 Yao Qi <yao.qi@linaro.org>
3649
3650 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3651 instead of find_inferior.
3652
3653 2016-05-05 Yao Qi <yao.qi@linaro.org>
3654
3655 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3656 Initialize res to zero.
3657
3658 2016-05-05 Yao Qi <yao.qi@linaro.org>
3659
3660 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3661 to uint32_t.
3662
3663 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3664
3665 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3666 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3667 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3668
3669 2016-04-28 Par Olsson <par.olsson@windriver.com>
3670 Simon Marchi <simon.marchi@ericsson.com>
3671
3672 * tracepoint.c (write_inferior_int8): New function.
3673 (cmd_qtenable_disable): Write enable flag using
3674 write_inferior_int8.
3675
3676 2016-04-25 Yao Qi <yao.qi@linaro.org>
3677
3678 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3679 (need_step_over_p): Return zero if the LWP has pending signals
3680 can be delivered on software single step target.
3681
3682 2016-04-25 Yao Qi <yao.qi@linaro.org>
3683
3684 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3685 return instead of error.
3686
3687 2016-04-22 Yao Qi <yao.qi@linaro.org>
3688
3689 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3690 to 23.
3691
3692 2016-04-22 Yao Qi <yao.qi@linaro.org>
3693
3694 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3695 signal when stepping over breakpoint with software single
3696 step.
3697
3698 2016-04-21 Pedro Alves <palves@redhat.com>
3699
3700 * linux-s390-low.c (s390_collect_ptrace_register)
3701 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3702 add casts.
3703 (s390_check_regset): Use void * instead of gdb_byte *.
3704
3705 2016-04-20 Pedro Alves <palves@redhat.com>
3706
3707 * configure: Renegerate.
3708
3709 2016-04-20 Yao Qi <yao.qi@linaro.org>
3710
3711 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3712 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3713 number 16.
3714 (arm_store_gregset): Likewise.
3715
3716 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3717
3718 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3719 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3720 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3721 (amd64-avx-mpx-linux.c): New rules.
3722 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3723 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3724 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3725 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3726 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3727 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3728 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3729 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3730 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3731 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3732 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3733 * linux-x86-low.c (x86_linux_read_description): Add case for
3734 X86_XSTATE_AVX_MPX_MASK.
3735 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3736 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3737 init_registers_i386_avx_mpx_linux.
3738 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3739 (initialize_low_tracepoint): Call
3740 init_registers_i386_avx_mpx_linux.
3741 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3742 (initialize_low_tracepoint): Call
3743 init_registers_amd64_avx_mpx_linux.
3744 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3745 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3746 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3747 declarations.
3748
3749 2016-04-18 Pedro Alves <palves@redhat.com>
3750
3751 * configure: Regenerate.
3752
3753 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3754
3755 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3756 (aarch64_emit_sub): Likewise.
3757
3758 2016-04-12 Pedro Alves <palves@redhat.com>
3759
3760 * utils.c (prepare_to_throw_exception): Delete.
3761
3762 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3763
3764 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3765
3766 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3767
3768 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3769
3770 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3771
3772 * linux-aarch64-ipa.c: Add <elf.h> include.
3773 * linux-ppc-ipa.c: Add <elf.h> include.
3774 * linux-s390-ipa.c: Add <elf.h> include.
3775
3776 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3777
3778 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3779 (get_raw_reg_ptr): Likewise.
3780 (get_trace_state_variable_value_ptr): Likewise.
3781 (set_trace_state_variable_value_ptr): Likewise.
3782 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3783 char *.
3784
3785 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3786 Marcin Kościelnicki <koriakin@0x04.net>
3787
3788 PR/17221
3789 * linux-ppc-low.c (emit_insns): New function.
3790 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3791 (ppc_emit_prologue): New function.
3792 (ppc_emit_epilogue): New function.
3793 (ppc_emit_add): New function.
3794 (ppc_emit_sub): New function.
3795 (ppc_emit_mul): New function.
3796 (ppc_emit_lsh): New function.
3797 (ppc_emit_rsh_signed): New function.
3798 (ppc_emit_rsh_unsigned): New function.
3799 (ppc_emit_ext): New function.
3800 (ppc_emit_zero_ext): New function.
3801 (ppc_emit_log_not): New function.
3802 (ppc_emit_bit_and): New function.
3803 (ppc_emit_bit_or): New function.
3804 (ppc_emit_bit_xor): New function.
3805 (ppc_emit_bit_not): New function.
3806 (ppc_emit_equal): New function.
3807 (ppc_emit_less_signed): New function.
3808 (ppc_emit_less_unsigned): New function.
3809 (ppc_emit_ref): New function.
3810 (ppc_emit_const): New function.
3811 (ppc_emit_reg): New function.
3812 (ppc_emit_pop): New function.
3813 (ppc_emit_stack_flush): New function.
3814 (ppc_emit_swap): New function.
3815 (ppc_emit_stack_adjust): New function.
3816 (ppc_emit_call): New function.
3817 (ppc_emit_int_call_1): New function.
3818 (ppc_emit_void_call_2): New function.
3819 (ppc_emit_if_goto): New function.
3820 (ppc_emit_goto): New function.
3821 (ppc_emit_eq_goto): New function.
3822 (ppc_emit_ne_goto): New function.
3823 (ppc_emit_lt_goto): New function.
3824 (ppc_emit_le_goto): New function.
3825 (ppc_emit_gt_goto): New function.
3826 (ppc_emit_ge_goto): New function.
3827 (ppc_write_goto_address): New function.
3828 (ppc_emit_ops_impl): New static variable.
3829 (ppc64v1_emit_prologue): New function.
3830 (ppc64v2_emit_prologue): New function.
3831 (ppc64_emit_epilogue): New function.
3832 (ppc64_emit_add): New function.
3833 (ppc64_emit_sub): New function.
3834 (ppc64_emit_mul): New function.
3835 (ppc64_emit_lsh): New function.
3836 (ppc64_emit_rsh_signed): New function.
3837 (ppc64_emit_rsh_unsigned): New function.
3838 (ppc64_emit_ext): New function.
3839 (ppc64_emit_zero_ext): New function.
3840 (ppc64_emit_log_not): New function.
3841 (ppc64_emit_bit_and): New function.
3842 (ppc64_emit_bit_or): New function.
3843 (ppc64_emit_bit_xor): New function.
3844 (ppc64_emit_bit_not): New function.
3845 (ppc64_emit_equal): New function.
3846 (ppc64_emit_less_signed): New function.
3847 (ppc64_emit_less_unsigned): New function.
3848 (ppc64_emit_ref): New function.
3849 (ppc64_emit_const): New function.
3850 (ppc64v1_emit_reg): New function.
3851 (ppc64v2_emit_reg): New function.
3852 (ppc64_emit_pop): New function.
3853 (ppc64_emit_stack_flush): New function.
3854 (ppc64_emit_swap): New function.
3855 (ppc64v1_emit_call): New function.
3856 (ppc64v2_emit_call): New function.
3857 (ppc64v1_emit_int_call_1): New function.
3858 (ppc64v2_emit_int_call_1): New function.
3859 (ppc64v1_emit_void_call_2): New function.
3860 (ppc64v2_emit_void_call_2): New function.
3861 (ppc64_emit_if_goto): New function.
3862 (ppc64_emit_eq_goto): New function.
3863 (ppc64_emit_ne_goto): New function.
3864 (ppc64_emit_lt_goto): New function.
3865 (ppc64_emit_le_goto): New function.
3866 (ppc64_emit_gt_goto): New function.
3867 (ppc64_emit_ge_goto): New function.
3868 (ppc64v1_emit_ops_impl): New static variable.
3869 (ppc64v2_emit_ops_impl): New static variable.
3870 (ppc_emit_ops): New function.
3871 (linux_low_target): Wire in ppc_emit_ops.
3872
3873 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3874 Marcin Kościelnicki <koriakin@0x04.net>
3875
3876 PR/17221
3877 * Makefile.in: Add powerpc-*-ipa.o
3878 * configure.srv: Add ipa_obj for powerpc*-linux.
3879 * linux-ppc-ipa.c: New file.
3880 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3881 includes.
3882 (PPC_FIELD): New macro.
3883 (PPC_SEXT): New macro.
3884 (PPC_OP6): New macro.
3885 (PPC_BO): New macro.
3886 (PPC_LI): New macro.
3887 (PPC_BD): New macro.
3888 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3889 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3890 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3891 (ppc_get_thread_area): New function.
3892 (is_elfv2_inferior): New function.
3893 (gen_ds_form): New function.
3894 (GEN_STD): New macro.
3895 (GEN_STDU): New macro.
3896 (GEN_LD): New macro.
3897 (GEN_LDU): New macro.
3898 (gen_d_form): New function.
3899 (GEN_ADDI): New macro.
3900 (GEN_ADDIS): New macro.
3901 (GEN_LI): New macro.
3902 (GEN_LIS): New macro.
3903 (GEN_ORI): New macro.
3904 (GEN_ORIS): New macro.
3905 (GEN_LWZ): New macro.
3906 (GEN_STW): New macro.
3907 (GEN_STWU): New macro.
3908 (gen_xfx_form): New function.
3909 (GEN_MFSPR): New macro.
3910 (GEN_MTSPR): New macro.
3911 (GEN_MFCR): New macro.
3912 (GEN_MTCR): New macro.
3913 (GEN_SYNC): New macro.
3914 (GEN_LWSYNC): New macro.
3915 (gen_x_form): New function.
3916 (GEN_OR): New macro.
3917 (GEN_MR): New macro.
3918 (GEN_LWARX): New macro.
3919 (GEN_STWCX): New macro.
3920 (GEN_CMPW): New macro.
3921 (gen_md_form): New function.
3922 (GEN_RLDICL): New macro.
3923 (GEN_RLDICR): New macro.
3924 (gen_i_form): New function.
3925 (GEN_B): New macro.
3926 (GEN_BL): New macro.
3927 (gen_b_form): New function.
3928 (GEN_BNE): New macro.
3929 (GEN_LOAD): New macro.
3930 (GEN_STORE): New macro.
3931 (gen_limm): New function.
3932 (gen_atomic_xchg): New function.
3933 (gen_call): New function.
3934 (ppc_relocate_instruction): New function.
3935 (ppc_install_fast_tracepoint_jump_pad): New function.
3936 (ppc_get_min_fast_tracepoint_insn_len): New function.
3937 (ppc_get_ipa_tdesc_idx): New function.
3938 (the_low_target): Wire in the new functions.
3939 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3940 tdescs.
3941 * linux-ppc-tdesc.h: New file.
3942
3943 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3944
3945 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3946 (alloc_jump_pad_buffer): New function.
3947 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3948 (alloc_jump_pad_buffer): New function.
3949 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3950 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3951 (alloc_jump_pad_buffer): New function.
3952 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3953 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3954 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3955 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3956
3957 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3958
3959 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3960 * linux-amd64-ipa.c: Likewise.
3961 * linux-i386-ipa.c: Likewise.
3962 * linux-s390-ipa.c: Likewise.
3963 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3964 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3965 set_trace_state_variable_value_ptr.
3966 (struct ipa_sym_addresses): Likewise.
3967 (symbol_list): Likewise.
3968 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3969 accessing gdb_collect directly.
3970 (gdb_collect_ptr_type): New typedef.
3971 (get_raw_reg_ptr_type): New typedef.
3972 (get_trace_state_variable_value_ptr_type): New typedef.
3973 (set_trace_state_variable_value_ptr_type): New typedef.
3974 (gdb_collect_ptr): New global.
3975 (get_raw_reg_ptr): New global.
3976 (get_trace_state_variable_value_ptr): New global.
3977 (set_trace_state_variable_value_ptr): New global.
3978 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3979 accessing get_raw_reg directly.
3980 (get_get_tsv_func_addr): Likewise for
3981 get_trace_state_variable_value_ptr.
3982 (get_set_tsv_func_addr): Likewise for
3983 set_trace_state_variable_value_ptr.
3984 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3985
3986 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3987
3988 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3989
3990 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3991
3992 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3993 packets.
3994 (relocate_instruction): Remove own_buf.
3995 * server.c (own_buf): Make global.
3996 (handle_v_requests): Make global.
3997 * server.h (own_buf): New declaration.
3998 (handle_v_requests): New prototype.
3999
4000 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4001
4002 PR 18377
4003 * linux-s390-low.c (add_insns): New function.
4004 (s390_emit_prologue): New function.
4005 (s390_emit_epilogue): New function.
4006 (s390_emit_add): New function.
4007 (s390_emit_sub): New function.
4008 (s390_emit_mul): New function.
4009 (s390_emit_lsh): New function.
4010 (s390_emit_rsh_signed): New function.
4011 (s390_emit_rsh_unsigned): New function.
4012 (s390_emit_ext): New function.
4013 (s390_emit_log_not): New function.
4014 (s390_emit_bit_and): New function.
4015 (s390_emit_bit_or): New function.
4016 (s390_emit_bit_xor): New function.
4017 (s390_emit_bit_not): New function.
4018 (s390_emit_equal): New function.
4019 (s390_emit_less_signed): New function.
4020 (s390_emit_less_unsigned): New function.
4021 (s390_emit_ref): New function.
4022 (s390_emit_if_goto): New function.
4023 (s390_emit_goto): New function.
4024 (s390_write_goto_address): New function.
4025 (s390_emit_litpool): New function.
4026 (s390_emit_const): New function.
4027 (s390_emit_call): New function.
4028 (s390_emit_reg): New function.
4029 (s390_emit_pop): New function.
4030 (s390_emit_stack_flush): New function.
4031 (s390_emit_zero_ext): New function.
4032 (s390_emit_swap): New function.
4033 (s390_emit_stack_adjust): New function.
4034 (s390_emit_set_r2): New function.
4035 (s390_emit_int_call_1): New function.
4036 (s390_emit_void_call_2): New function.
4037 (s390_emit_eq_goto): New function.
4038 (s390_emit_ne_goto): New function.
4039 (s390_emit_lt_goto): New function.
4040 (s390_emit_le_goto): New function.
4041 (s390_emit_gt_goto): New function.
4042 (s390_emit_ge_goto): New function.
4043 (s390x_emit_prologue): New function.
4044 (s390x_emit_epilogue): New function.
4045 (s390x_emit_add): New function.
4046 (s390x_emit_sub): New function.
4047 (s390x_emit_mul): New function.
4048 (s390x_emit_lsh): New function.
4049 (s390x_emit_rsh_signed): New function.
4050 (s390x_emit_rsh_unsigned): New function.
4051 (s390x_emit_ext): New function.
4052 (s390x_emit_log_not): New function.
4053 (s390x_emit_bit_and): New function.
4054 (s390x_emit_bit_or): New function.
4055 (s390x_emit_bit_xor): New function.
4056 (s390x_emit_bit_not): New function.
4057 (s390x_emit_equal): New function.
4058 (s390x_emit_less_signed): New function.
4059 (s390x_emit_less_unsigned): New function.
4060 (s390x_emit_ref): New function.
4061 (s390x_emit_if_goto): New function.
4062 (s390x_emit_const): New function.
4063 (s390x_emit_call): New function.
4064 (s390x_emit_reg): New function.
4065 (s390x_emit_pop): New function.
4066 (s390x_emit_stack_flush): New function.
4067 (s390x_emit_zero_ext): New function.
4068 (s390x_emit_swap): New function.
4069 (s390x_emit_stack_adjust): New function.
4070 (s390x_emit_int_call_1): New function.
4071 (s390x_emit_void_call_2): New function.
4072 (s390x_emit_eq_goto): New function.
4073 (s390x_emit_ne_goto): New function.
4074 (s390x_emit_lt_goto): New function.
4075 (s390x_emit_le_goto): New function.
4076 (s390x_emit_gt_goto): New function.
4077 (s390x_emit_ge_goto): New function.
4078 (s390_emit_ops): New function.
4079 (struct linux_target_ops): Fill in emit_ops hook.
4080
4081 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4082
4083 PR 18377
4084 * Makefile.in: Add s390 IPA files.
4085 * configure.srv: Build IPA for s390.
4086 * linux-s390-ipa.c: New file.
4087 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
4088 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
4089 (tdesc_s390_linux32): Likewise.
4090 (init_registers_s390_linux32v1): Likewise.
4091 (tdesc_s390_linux32v1): Likewise.
4092 (init_registers_s390_linux32v2): Likewise.
4093 (tdesc_s390_linux32v2): Likewise.
4094 (init_registers_s390_linux64): Likewise.
4095 (tdesc_s390_linux64): Likewise.
4096 (init_registers_s390_linux64v1): Likewise.
4097 (tdesc_s390_linux64v1): Likewise.
4098 (init_registers_s390_linux64v2): Likewise.
4099 (tdesc_s390_linux64v2): Likewise.
4100 (init_registers_s390_te_linux64): Likewise.
4101 (tdesc_s390_te_linux64): Likewise.
4102 (init_registers_s390_vx_linux64): Likewise.
4103 (tdesc_s390_vx_linux64): Likewise.
4104 (init_registers_s390_tevx_linux64): Likewise.
4105 (tdesc_s390_tevx_linux64): Likewise.
4106 (init_registers_s390x_linux64): Likewise.
4107 (tdesc_s390x_linux64): Likewise.
4108 (init_registers_s390x_linux64v1): Likewise.
4109 (tdesc_s390x_linux64v1): Likewise.
4110 (init_registers_s390x_linux64v2): Likewise.
4111 (tdesc_s390x_linux64v2): Likewise.
4112 (init_registers_s390x_te_linux64): Likewise.
4113 (tdesc_s390x_te_linux64): Likewise.
4114 (init_registers_s390x_vx_linux64): Likewise.
4115 (tdesc_s390x_vx_linux64): Likewise.
4116 (init_registers_s390x_tevx_linux64): Likewise.
4117 (tdesc_s390x_tevx_linux64): Likewise.
4118 (have_hwcap_s390_vx): New static variable.
4119 (s390_arch_setup): Fill have_hwcap_s390_vx.
4120 (s390_get_thread_area): New function.
4121 (s390_ft_entry_gpr_esa): New const.
4122 (s390_ft_entry_gpr_zarch): New const.
4123 (s390_ft_entry_misc): New const.
4124 (s390_ft_entry_fr): New const.
4125 (s390_ft_entry_vr): New const.
4126 (s390_ft_main_31): New const.
4127 (s390_ft_main_64): New const.
4128 (s390_ft_exit_fr): New const.
4129 (s390_ft_exit_vr): New const.
4130 (s390_ft_exit_misc): New const.
4131 (s390_ft_exit_gpr_esa): New const.
4132 (s390_ft_exit_gpr_zarch): New const.
4133 (append_insns): New function.
4134 (s390_relocate_instruction): New function.
4135 (s390_install_fast_tracepoint_jump_pad): New function.
4136 (s390_get_min_fast_tracepoint_insn_len): New function.
4137 (s390_get_ipa_tdesc_idx): New function.
4138 (struct linux_target_ops): Wire in the above functions.
4139 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4140 * linux-s390-tdesc.h: New file.
4141
4142 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4143
4144 * linux-s390-low.c (s390_supports_tracepoints): New function.
4145 (struct linux_target_ops): Fill supports_tracepoints hook.
4146
4147 2016-03-18 Yao Qi <yao.qi@linaro.org>
4148
4149 * linux-low.c (lwp_signal_can_be_delivered): New function.
4150 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4151
4152 2016-03-18 Yao Qi <yao.qi@linaro.org>
4153
4154 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4155 0 if signal is enqueued. Remove 'signal' from one debugging
4156 message. Move one debugging message to some lines below.
4157 Remove code setting 'signal' to 0.
4158
4159 2016-03-18 Yao Qi <yao.qi@linaro.org>
4160
4161 * linux-low.c (linux_low_filter_event): Remove redundant
4162 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4163
4164 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4165
4166 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4167 (struct linux_target_ops): Wire in the above.
4168
4169 2016-03-03 Yao Qi <yao.qi@linaro.org>
4170
4171 * linux-low.c: Update comments to start_step_over.
4172
4173 2016-03-03 Yao Qi <yao.qi@linaro.org>
4174
4175 PR server/19736
4176 * linux-low.c (handle_extended_wait): Set child suspended
4177 if event_lwp->bp_reinsert isn't zero.
4178
4179 2016-03-02 Yao Qi <yao.qi@linaro.org>
4180
4181 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4182 enqueue_pending_signal.
4183
4184 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4185
4186 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4187 is actually loaded.
4188
4189 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4190
4191 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4192 (s390_regmap_3264) [!__s390x__]: New global.
4193 (s390_collect_ptrace_register): Skip map entries containing -1.
4194 (s390_supply_ptrace_register): Ditto.
4195 (s390_fill_gprs_high): New function.
4196 (s390_store_gprs_high): New function.
4197 (s390_regsets): Add NT_S390_HIGH_GPRS.
4198 (s390_get_hwcap): Enable on 31-bit.
4199 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4200 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4201 Detect NT_S390_HIGH_GPRS.
4202 (s390_usrregs_info_3264): Enable on 31-bit.
4203 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4204 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4205
4206 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4207
4208 PR gdb/13808
4209 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4210 * configure.srv: Ditto.
4211 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4212 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4213 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4214 (init_registers_amd64_linux): Remove prototype.
4215 (tdesc_amd64_linux): Remove declaration.
4216 (get_ipa_tdesc): New function.
4217 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4218 initialize remaining tdescs.
4219 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4220 (init_registers_i386_linux): Remove prototype.
4221 (tdesc_i386_linux): Remove declaration.
4222 (get_ipa_tdesc): New function.
4223 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4224 initialize remaining tdescs.
4225 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4226 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4227 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4228 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4229 (x86_get_ipa_tdesc_idx): New function.
4230 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4231 * linux-x86-tdesc.h: New file.
4232 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4233 (target_get_ipa_tdesc_idx): New macro.
4234 * tracepoint.c (ipa_tdesc_idx): New macro.
4235 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4236 (symbol_list): Add ipa_tdesc_idx.
4237 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4238 (ipa_tdesc): Remove.
4239 (ipa_tdesc_idx): New variable.
4240 (get_context_regcache): Use get_ipa_tdesc.
4241 (gdb_collect): Ditto.
4242 (gdb_probe): Ditto.
4243 * tracepoint.h (get_ipa_tdesc): New prototype.
4244 (ipa_tdesc): Remove.
4245
4246 2016-02-24 Pedro Alves <palves@redhat.com>
4247
4248 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4249 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4250 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4251 Factor out common code between the USE_SIGTRAP_SIGINFO and
4252 !USE_SIGTRAP_SIGINFO blocks.
4253 (linux_low_filter_event): Call save_stop_reason instead of
4254 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4255 Update comments.
4256 (linux_wait_1): Update comments.
4257
4258 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
4259
4260 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4261 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4262 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4263 ppc_insert_point, ppc_remove_point.
4264
4265 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4266
4267 * linux-s390-low.c (s390_supports_z_point_type): New function.
4268 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4269
4270 2016-02-16 Yao Qi <yao.qi@linaro.org>
4271
4272 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4273 PC. Get pc from regcache_read_pc.
4274
4275 2016-02-12 Yao Qi <yao.qi@linaro.org>
4276
4277 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4278 or linux_get_pc_32bit.
4279 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4280
4281 2016-02-12 Yao Qi <yao.qi@linaro.org>
4282
4283 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4284 arm_linux_get_next_pcs_fixup.
4285
4286 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4287
4288 * tracepoint.c (x_tracepoint_action_download): Change
4289 write_inferior_data_ptr to write_inferior_data_pointer.
4290 (cmd_qtstart): Likewise.
4291 (write_inferior_data_ptr): Remove.
4292 (download_agent_expr): Change write_inferior_data_ptr to
4293 write_inferior_data_pointer.
4294 (download_tracepoint_1): Likewise.
4295 (download_tracepoint): Likewise.
4296 (download_trace_state_variables): Likewise.
4297
4298 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
4299 Marcin Kościelnicki <koriakin@0x04.net>
4300
4301 * tracepoint.c (struct tracepoint_action_ops): Remove.
4302 (struct tracepoint_action): Remove ops.
4303 (m_tracepoint_action_download, r_tracepoint_action_download)
4304 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4305 size and offset accordingly.
4306 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4307 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4308 (tracepoint_action_send, tracepoint_action_download): New functions.
4309 Helpers for trace action handlers.
4310 (add_tracepoint_action): Remove setup actions ops.
4311 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4312
4313 2016-02-10 Yao Qi <yao.qi@linaro.org>
4314
4315 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4316
4317 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4318
4319 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4320 to AC_OUTPUT.
4321 * configure: Regenerate.
4322
4323 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4324
4325 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4326 void * to gdb_byte *.
4327 * linux-low.c (siginfo_fixup): Likewise.
4328 (linux_xfer_siginfo): Likewise.
4329 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4330 Likewise.
4331 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4332
4333 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4334
4335 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4336 to srv_tgtobj.
4337 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4338 to srv_tgtobj.
4339 * linux-x86-low.c [__x86_64__]: Include
4340 "nat/amd64-linux-siginfo.h".
4341 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4342 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4343 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4344 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4345 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4346 (cpt_si_fd, si_timerid, si_overrun): Move from
4347 nat/amd64-linux-siginfo.c.
4348 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4349
4350 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4351
4352 * server.c (skip_to_semicolon): Remove.
4353 (process_point_options): Use strchrnul instead of
4354 skip_to_semicolon.
4355
4356 2016-01-26 Yao Qi <yao.qi@linaro.org>
4357
4358 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4359 * linux-low.c (install_software_single_step_breakpoints): Don't
4360 call regcache_read_pc.
4361 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4362 argument pc.
4363
4364 2016-01-26 Yao Qi <yao.qi@linaro.org>
4365
4366 * linux-low.c (install_software_single_step_breakpoints): Call
4367 regcache_read_pc instead of get_pc.
4368
4369 2016-01-26 Yao Qi <yao.qi@linaro.org>
4370
4371 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4372 (unblock_async_io): Rename to ...
4373 (block_unblock_async_io): ... it. New function.
4374 (enable_async_io): Don't install SIGIO handler. Unblock it
4375 instead.
4376 (disable_async_io): Don't ignore SIGIO. Block it instead.
4377 (initialize_async_io): Install SIGIO handler. Don't call
4378 unblock_async_io.
4379
4380 2016-01-26 Yao Qi <yao.qi@linaro.org>
4381
4382 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4383 first character is '\003', call *the_target->request_interrupt.
4384
4385 2016-01-25 Yao Qi <yao.qi@linaro.org>
4386
4387 * remote-utils.c (new_thread_notify): Remove.
4388 (dead_thread_notify): Likewise.
4389 * remote-utils.h (new_thread_notify): Remove declaration.
4390 (dead_thread_notify): Likewise.
4391
4392 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4393
4394 * gdb.trace/pending.exp: Fix expected message on continue.
4395
4396 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4397
4398 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4399 it works properly on big-endian machines where sizeof (CORE_ADDR)
4400 != sizeof (void *).
4401
4402 2016-01-21 Pedro Alves <palves@redhat.com>
4403
4404 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4405 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4406 * configure: Regenerate.
4407
4408 2016-01-21 Yao Qi <yao.qi@linaro.org>
4409
4410 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4411 is_thumb and set it according to CPSR saved on the stack.
4412 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4413 arm_sigreturn_next_pc.
4414
4415 2016-01-18 Yao Qi <yao.qi@linaro.org>
4416
4417 * linux-low.c (linux_set_pc_64bit): New function.
4418 (linux_get_pc_64bit): New function.
4419 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4420 Declare.
4421 * linux-sparc-low.c (debug_threads): Remove declaration.
4422 (sparc_get_pc): Remove.
4423 (the_low_target): Use linux_get_pc_64bit instead of
4424 sparc_get_pc.
4425 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4426 (the_low_target): Use linux_get_pc_64bit and
4427 linux_set_pc_64bit.
4428
4429 2016-01-18 Yao Qi <yao.qi@linaro.org>
4430
4431 * linux-arm-low.c (debug_threads): Remove declaration.
4432 (arm_get_pc, arm_set_pc): Remove.
4433 (the_low_target): Use linux_get_pc_32bit and
4434 linux_set_pc_32bit.
4435 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4436 (the_low_target): Use linux_get_pc_32bit and
4437 linux_set_pc_32bit.
4438 * linux-cris-low.c (debug_threads): Remove declaration.
4439 (cris_get_pc, cris_set_pc,): Remove.
4440 (the_low_target): Use linux_get_pc_32bit and
4441 linux_set_pc_32bit.
4442 * linux-crisv32-low.c (debug_threads): Remove declaration.
4443 (cris_get_pc, cris_set_pc): Remove.
4444 (the_low_target): Use linux_get_pc_32bit and
4445 linux_set_pc_32bit.
4446 * linux-low.c: Include inttypes.h.
4447 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4448 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4449 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4450 (the_low_target): Use linux_get_pc_32bit and
4451 linux_set_pc_32bit.
4452 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4453 (the_low_target): Use linux_get_pc_32bit and
4454 linux_set_pc_32bit.
4455 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4456 (the_low_target): Use linux_get_pc_32bit and
4457 linux_set_pc_32bit.
4458 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4459 (the_low_target): Use linux_get_pc_32bit and
4460 linux_set_pc_32bit.
4461 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4462 (the_low_target): Use linux_get_pc_32bit and
4463 linux_set_pc_32bit.
4464
4465 2016-01-18 Gary Benson <gbenson@redhat.com>
4466
4467 * configure.ac (AC_FUNC_FORK): New check.
4468 * config.in: Regenerate.
4469 * configure: Likewise.
4470
4471 2016-01-14 Yao Qi <yao.qi@linaro.org>
4472
4473 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4474 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4475 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4476 arm_get_next_pcs_ctor.
4477
4478 2016-01-12 Josh Stone <jistone@redhat.com>
4479 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4480
4481 * inferiors.h: Include "gdb_vecs.h".
4482 (struct process_info): Add syscalls_to_catch.
4483 * inferiors.c (remove_process): Free syscalls_to_catch.
4484 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4485 syscall_return stops.
4486 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4487 * server.c (handle_general_set): Handle QCatchSyscalls.
4488 (handle_query): Report support for QCatchSyscalls.
4489 * target.h (struct target_ops): Add supports_catch_syscall.
4490 (target_supports_catch_syscall): New macro.
4491 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4492 (struct lwp_info): Add syscall_state.
4493 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4494 Maintain syscall_state and syscalls_to_catch across exec.
4495 (get_syscall_trapinfo): New function, proxy to the_low_target.
4496 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4497 (linux_low_filter_event): Toggle syscall_state entry/return for
4498 syscall traps, and set it ignored for all others.
4499 (gdb_catching_syscalls_p): New function.
4500 (gdb_catch_this_syscall_p): New function.
4501 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4502 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4503 (linux_supports_catch_syscall): New function.
4504 (linux_target_ops): Install it.
4505 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4506 (the_low_target): Install it.
4507
4508 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4509
4510 * acinclude.m4: Include new ../warning.m4 file.
4511 * configure: Regenerated.
4512 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4513
4514 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4515
4516 * ax.c (is_goto_target): Mark static.
4517 * linux-low.c (register_addr): Likewise.
4518 (linux_fetch_registers, linux_store_registers): Likewise.
4519 * mem-break.c (any_persistent_commands): Fix old prototype.
4520 (add_commands_to_breakpoint): Mark static.
4521 * regcache.c (find_register_by_name): Delete unused func.
4522 * remote-utils.c (hex_or_minus_one): Mark static.
4523 * server.c (monitor_show_help): Mark static.
4524 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4525 handle_v_requests): Likewise.
4526
4527 2016-01-12 Pedro Alves <palves@redhat.com>
4528
4529 Remove use of the registered trademark symbol throughout.
4530
4531 2016-01-08 Yao Qi <yao.qi@linaro.org>
4532
4533 * remote-utils.c (getpkt): If c is '\003', call target hook
4534 request_interrupt.
4535
4536 2016-01-06 Yao Qi <yao.qi@linaro.org>
4537
4538 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4539 linux-aarch32-low.c.
4540 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4541 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4542 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4543 (thumb2_breakpoint): Declare.
4544 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4545 linux-aarch32-low.h.
4546 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4547 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4548 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4549
4550 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4551
4552 * gdbreplay.c (gdbreplay_version): Change copyright year in
4553 version message.
4554 * server.c (gdbserver_version): Likewise.
4555
4556 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4557
4558 * server.c (crc32_table): Delete.
4559 (crc32): Use libiberty's xcrc32 function.
4560
4561 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4562
4563 * lynx-low.c (lynx_delete_thread_callback): New function.
4564 (lynx_mourn): Properly delete our process and all of its
4565 threads. Remove call to clear_inferiors.
4566
4567 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4568
4569 * target.c (thread_search_callback): Add check that
4570 the thread_stopped target callback is not NULL before
4571 calling it.
4572
4573 2015-12-21 Yao Qi <yao.qi@linaro.org>
4574
4575 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4576 arm breakpoint.
4577
4578 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4579
4580 * server.c (handle_query): Call target_supports_software_single_step.
4581
4582 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4583
4584 * linux-low.c (single_step): New function.
4585 (linux_resume_one_lwp_throw): Call single_step.
4586 (start_step_over): Likewise.
4587
4588 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4589
4590 * Makefile.in (SFILES): Append arch/arm-linux.c,
4591 arch/arm-get-next-pcs.c.
4592 (arm-linux.o): New rule.
4593 (arm-get-next-pcs.o): New rule.
4594 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4595 arm-linux.o.
4596 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4597 to linux-aarch32-low.c.
4598 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4599 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4600 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4601 (thumb2_breakpoint_len): Likewise.
4602 (arm_is_thumb_mode): Make non-static.
4603 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4604 from linux-aarch32-low.c.
4605 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4606 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4607 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4608 (thumb2_breakpoint_len): Likewise.
4609 (arm_is_thumb_mode): New declaration.
4610 * linux-arm-low.c: Include arch/arm-linux.h
4611 aarch/arm-get-next-pcs.h, sys/syscall.h.
4612 (get_next_pcs_ops): New struct.
4613 (get_next_pcs_addr_bits_remove): New function.
4614 (get_next_pcs_is_thumb): New function.
4615 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4616 (arm_sigreturn_next_pc): Likewise.
4617 (get_next_pcs_syscall_next_pc): Likewise.
4618 (arm_gdbserver_get_next_pcs): Likewise.
4619 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4620 Initialize.
4621 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4622 * server.h: Include gdb_vecs.h.
4623
4624 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4625
4626 * Makefile.in (SFILES): Append common/common-regcache.c.
4627 (OBS): Append common-regcache.o.
4628 (common-regcache.o): New rule.
4629 * regcache.c (init_register_cache): Initialize cache to
4630 REG_UNAVAILABLE.
4631 (regcache_raw_read_unsigned): New function.
4632 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4633 register_status enum.
4634
4635 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4636
4637 * linux-aarch64-low.c (the_low_targets): Rename
4638 breakpoint_reinsert_addr to get_next_pcs.
4639 * linux-arm-low.c (the_low_targets): Likewise.
4640 * linux-bfin-low.c (the_low_targets): Likewise.
4641 * linux-cris-low.c (the_low_targets): Likewise.
4642 * linux-crisv32-low.c (the_low_targets): Likewise.
4643 * linux-low.c (can_software_single_step): Likewise.
4644 (install_software_single_step_breakpoints): New function.
4645 (start_step_over): Use install_software_single_step_breakpoints.
4646 * linux-low.h: New CORE_ADDR vector.
4647 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4648 get_next_pcs.
4649 * linux-mips-low.c (the_low_targets): Likewise.
4650 * linux-nios2-low.c (the_low_targets): Likewise.
4651 * linux-sparc-low.c (the_low_targets): Likewise.
4652
4653 2015-12-17 Pedro Alves <palves@redhat.com>
4654
4655 * linux-low.c (linux_kill_one_lwp): Remove references to
4656 LinuxThreads.
4657 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4658 to 'kill'.
4659 (linux_init_signals): Delete.
4660 (initialize_low): Adjust.
4661 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4662
4663 2015-12-16 Pedro Alves <palves@redhat.com>
4664
4665 * configure.ac (compiler warning flags): When testing a
4666 -Wno-foo option, check whether -Wfoo works instead.
4667 * configure: Regenerate.
4668
4669 2015-12-11 Don Breazeal <donb@codesourcery.com>
4670
4671 * server.c (process_serial_event): Don't exit from gdbserver
4672 in remote mode if there are still active inferiors.
4673
4674 2015-12-11 Yao Qi <yao.qi@linaro.org>
4675
4676 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4677 arm_breakpoint_at if the process is 32-bit.
4678
4679 2015-12-11 Yao Qi <yao.qi@linaro.org>
4680
4681 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4682 arm breakpoint.
4683
4684 2015-12-07 Yao Qi <yao.qi@linaro.org>
4685
4686 * configure.srv: Append arm.o to srv_tgtobj for
4687 aarch64*-*-linux* target.
4688 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4689 from linux-arm-low.c.
4690 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4691 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4692 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4693 (thumb2_breakpoint_len): Likewise.
4694 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4695 (arm_breakpoint_kinds): Likewise.
4696 (arm_breakpoint_kind_from_pc): Likewise.
4697 (arm_sw_breakpoint_from_kind): Likewise.
4698 (arm_breakpoint_kind_from_current_state): Likewise.
4699 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4700 (arm_sw_breakpoint_from_kind): Declare.
4701 (arm_breakpoint_kind_from_current_state): Declare.
4702 (arm_breakpoint_at): Declare.
4703 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4704 arm_sw_breakpoint_from_kind if process is 32-bit.
4705 (aarch64_breakpoint_kind_from_pc): New function.
4706 (aarch64_breakpoint_kind_from_current_state): New function.
4707 (the_low_target): Initialize fields breakpoint_kind_from_pc
4708 and breakpoint_kind_from_current_state.
4709 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4710 linux-aarch32-low.c.
4711 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4712 (arm_breakpoint, arm_breakpoint_len): Likewise.
4713 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4714 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4715 (arm_is_thumb_mode): Likewise.
4716 (arm_breakpoint_at): Likewise.
4717 (arm_breakpoint_kind_from_pc): Likewise.
4718 (arm_sw_breakpoint_from_kind): Likewise.
4719 (arm_breakpoint_kind_from_current_state): Likewise.
4720
4721 Revert:
4722 2015-08-04 Yao Qi <yao.qi@linaro.org>
4723
4724 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4725 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4726 * server.c (extended_protocol): Remove "static".
4727 * server.h (extended_protocol): Declare it.
4728
4729 2015-12-04 Josh Stone <jistone@redhat.com>
4730
4731 * target.h (struct target_ops) <arch_setup>: Rename to ...
4732 (struct target_ops) <post_create_inferior>: ... this.
4733 (target_arch_setup): Rename to ...
4734 (target_post_create_inferior): ... this, calling post_create_inferior.
4735 * server.c (start_inferior): Update target_arch_setup calls to
4736 target_post_create_inferior.
4737 * linux-low.c (linux_low_ptrace_options): Forward declare.
4738 (linux_arch_setup): Update its comment for general use.
4739 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4740 (struct linux_target_ops): Use linux_post_create_inferior.
4741 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4742 to post_create_inferior.
4743 * nto-low.c (struct nto_target_ops): Likewise.
4744 * spu-low.c (struct spu_target_ops): Likewise.
4745 * win32-low.c (struct win32_target_ops): Likewise.
4746
4747 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4748
4749 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4750
4751 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4752
4753 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4754 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4755 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4756 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4757 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4758 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4759 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4760 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4761 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4762 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4763 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4764 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4765
4766 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4767
4768 * linux-low.c (linux_look_up_symbols): Don't call
4769 linux_supports_traceclone.
4770 * linux-low.h (thread_db_init): Remove use_events argument.
4771 * thread-db.c (thread_db_use_event): Remove global variable.
4772 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4773 (struct thread_db) <td_create_bp>: Remove field.
4774 (thread_db_create_event): Remove function.
4775 (thread_db_enable_reporting): Likewise.
4776 (find_one_thread): Don't check for thread_db_use_events.
4777 (attach_thread): Likewise.
4778 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4779 (try_thread_db_load_1): Don't check for thread_db_use_events.
4780 (thread_db_init): Remove use_events argument and thread events
4781 handling.
4782 (remove_thread_event_breakpoints): Remove function.
4783 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4784
4785 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4786
4787 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4788 New function.
4789 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4790 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4791 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4792 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4793 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4794 Initialize.
4795 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4796 New function.
4797 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4798 * linux-low.c (can_hardware_single_step): Use
4799 supports_hardware_single_step.
4800 (can_software_single_step): New function.
4801 (start_step_over): Call can_software_single_step.
4802 (linux_supports_hardware_single_step): New function.
4803 (struct target_ops) <supports_software_single_step>: Initialize.
4804 * linux-low.h (struct linux_target_ops)
4805 <supports_hardware_single_step>: Initialize.
4806 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4807 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4808 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4809 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4810 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4811 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4812 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4813 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4814 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4815 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4816 Initialize.
4817 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4818 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4819 Initialize.
4820 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4821 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4822 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4823 New function.
4824 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4825 * target.h (struct target_ops): <supports_software_single_step>:
4826 New field.
4827 (target_supports_software_single_step): New macro.
4828
4829 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4830
4831 * linux-low.c (linux_wait_1): Fix pc advance condition.
4832 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4833 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4834
4835 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4836
4837 * linux-arm-low.c (arm_is_thumb_mode): New function.
4838 (arm_breakpoint_at): Use arm_is_thumb_mode.
4839 (arm_breakpoint_kind_from_current_state): New function.
4840 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4841 Initialize.
4842 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4843 (linux_breakpoint_kind_from_current_state): New function.
4844 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4845 * linux-low.h (struct linux_target_ops)
4846 <breakpoint_kind_from_current_state>: New field.
4847 * target.h (struct target_ops): Likewise.
4848 (target_breakpoint_kind_from_current_state): New macro.
4849
4850 2015-11-30 Pedro Alves <palves@redhat.com>
4851
4852 * linux-low.c (linux_resume): Wake up the event loop before
4853 returning.
4854
4855 2015-11-30 Pedro Alves <palves@redhat.com>
4856
4857 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4858 check.
4859 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4860 to -1.
4861 * target.c (struct thread_search): New structure.
4862 (thread_search_callback): New function.
4863 (prev_general_thread): New global.
4864 (prepare_to_access_memory, done_accessing_memory): New functions.
4865 * target.h (prepare_to_access_memory, done_accessing_memory):
4866 Replace macros with function declarations.
4867
4868 2015-11-30 Pedro Alves <palves@redhat.com>
4869
4870 PR 14618
4871 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4872 report TARGET_WAITKIND_NO_RESUMED.
4873 * remote-utils.c (prepare_resume_reply): Handle
4874 TARGET_WAITKIND_NO_RESUMED.
4875 * server.c (report_no_resumed): New global.
4876 (handle_query) <qSupported>: Handle "no-resumed+". Report
4877 "no-resumed+" support.
4878 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4879 return error if the client doesn't support no-resumed events.
4880 (push_stop_notification): New function.
4881 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4882 events if the client supports them.
4883
4884 2015-11-30 Pedro Alves <palves@redhat.com>
4885
4886 * linux-low.c (thread_still_has_status_pending_p): Don't check
4887 vCont;t here.
4888 (lwp_resumed): New function.
4889 (status_pending_p_callback): Return early if the LWP is not
4890 supposed to be resumed.
4891
4892 2015-11-30 Pedro Alves <palves@redhat.com>
4893
4894 * linux-low.c (handle_extended_wait): Assert that the LWP's
4895 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4896 thread create events, leave the new child's status pending.
4897 (linux_low_filter_event): If GDB wants to hear about thread exit
4898 events, leave the LWP marked dead and don't delete it.
4899 (linux_wait_for_event_filtered): Don't check for thread exit.
4900 (filter_exit_event): New function.
4901 (linux_wait_1): Use it, when returning an exit event.
4902 (linux_resume_one_lwp_throw): Assert that the LWP's
4903 waitstatus is TARGET_WAITKIND_IGNORE.
4904 * remote-utils.c (prepare_resume_reply): Handle
4905 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4906 * server.c (report_thread_events): New global.
4907 (handle_general_set): Handle QThreadEvents.
4908 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4909 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4910 TARGET_WAITKIND_THREAD_EXITED.
4911 * server.h (report_thread_events): Declare.
4912
4913 2015-11-30 Pedro Alves <palves@redhat.com>
4914
4915 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4916 the thread's last_resume_kind was resume_stop.
4917
4918 2015-11-30 Pedro Alves <palves@redhat.com>
4919
4920 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4921 before returning.
4922
4923 2015-11-30 Pedro Alves <palves@redhat.com>
4924
4925 * server.c (handle_v_requests): Handle vCtrlC.
4926
4927 2015-11-30 Pedro Alves <palves@redhat.com>
4928
4929 * gdbthread.h (find_any_thread_of_pid): Declare.
4930 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4931 functions.
4932 * server.c (handle_query): If current_thread is NULL, look for
4933 another thread of the selected process.
4934
4935 2015-11-26 Daniel Colascione <dancol@dancol.org>
4936 Simon Marchi <simon.marchi@ericsson.com>
4937
4938 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4939 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4940 name in reply.
4941 * target.h (struct target_ops) <thread_name>: New field.
4942 (target_thread_name): New macro.
4943
4944 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4945
4946 * regcache.h (regcache_invalidate_pid): Add declaration.
4947 * regcache.c (regcache_invalidate_pid): New function, extracted
4948 from regcache_invalidate.
4949 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4950 Add trivial documentation comment.
4951 * lynx-low.c: Use regcache_invalidate_pid instead of
4952 regcache_invalidate.
4953
4954 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4955
4956 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4957 and Elf64_auxv_t if the target is Android.
4958
4959 2015-11-22 Doug Evans <xdje42@gmail.com>
4960
4961 * target.h: #include <sys/types.h>.
4962
4963 2015-11-19 Pedro Alves <palves@redhat.com>
4964
4965 * linux-low.c (linux_process_qsupported): Change prototype.
4966 Adjust.
4967 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4968 Change prototype.
4969 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4970 and adjust to loop over all features.
4971 * server.c (handle_query) <qSupported>: Adjust to call
4972 target_process_qsupported once, passing it a vector of unprocessed
4973 features.
4974 * target.h (struct target_ops) <process_qsupported>: Change
4975 prototype.
4976 (target_process_qsupported): Adjust.
4977
4978 2015-11-19 Pedro Alves <palves@redhat.com>
4979
4980 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4981 mode.
4982 * configure: Regenerate.
4983
4984 2015-11-19 Pedro Alves <palves@redhat.com>
4985
4986 * configure: Regenerate.
4987
4988 2015-11-19 Yao Qi <yao.qi@linaro.org>
4989
4990 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4991 type to uint32_t.
4992
4993 2015-11-19 Yao Qi <yao.qi@linaro.org>
4994
4995 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4996 (struct aarch64_operand): Move enum out.
4997
4998 2015-11-19 Yao Qi <yao.qi@linaro.org>
4999
5000 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
5001 struct user_fpsimd_state *.
5002 (aarch64_store_fpregset): Likewise.
5003
5004 2015-11-19 Yao Qi <yao.qi@linaro.org>
5005
5006 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
5007 struct user_pt_regs *.
5008 (aarch64_store_gregset): Likewise.
5009
5010 2015-11-18 Pedro Alves <palves@redhat.com>
5011
5012 * Makefile.in (all_object_files): Add $IPA_OBJS.
5013
5014 2015-11-17 Pedro Alves <palves@redhat.com>
5015
5016 * win32-low.c (win32_resume): Use gdb_signal_from_host,
5017 GDB_SIGNAL_0 and gdb_signal_to_string.
5018
5019 2015-11-17 Pedro Alves <palves@redhat.com>
5020
5021 * win32-low.c (handle_output_debug_string): Remove parameter.
5022 (win32_kill): Remove our_status local and adjust call to
5023 handle_output_debug_string.
5024 (get_child_debug_event): Adjust call to
5025 handle_output_debug_string.
5026
5027 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5028
5029 * linux-mips-low.c (mips_fill_gregset): Add cast.
5030 (mips_store_gregset): Likewise.
5031 (mips_fill_fpregset): Likewise.
5032 (mips_store_fpregset): Likewise.
5033
5034 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5035
5036 * linux-mips-low.c (mips_add_watchpoint): Rename private to
5037 priv.
5038
5039 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5040
5041 * linux-mips-low.c (mips_linux_new_thread): Change type of
5042 watch_type to enum target_hw_bp_type.
5043
5044 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5045
5046 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
5047 Change return type to arm_hwbp_type.
5048
5049 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5050
5051 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
5052 (arm_store_gregset): Likewise.
5053 * linux-arm-low.c (arm_get_hwcap): Likewise.
5054 (arm_read_description): Likewise.
5055
5056 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5057
5058 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
5059
5060 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5061
5062 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
5063 (ppc_fill_vsxregset): Likewise.
5064 (ppc_store_vsxregset): Likewise.
5065 (ppc_fill_vrregset): Likewise.
5066 (ppc_store_vrregset): Likewise.
5067 (ppc_fill_evrregset): Likewise.
5068 (ppc_store_evrregset): Likewise.
5069
5070 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5071
5072 * linux-ppc-low.c (ppc_usrregs_info): Remove
5073 forward-declaration.
5074 (ppc_arch_setup): Move lower in file.
5075
5076 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
5077
5078 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
5079 (ps_pdwrite): Likewise.
5080
5081 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
5082
5083 * linux-arm-low.c (arm_new_thread): Move pointer dereference
5084 to after assert checks.
5085
5086 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
5087
5088 * proc-service.c (ps_pdread): Add/adjust casts.
5089 (ps_pdwrite): Add/adjust casts.
5090
5091 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5092
5093 * server.c (handle_search_memory_1): Cast return value of
5094 memmem.
5095
5096 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5097
5098 * server.c (write_qxfer_response): Change type of data to
5099 gdb_byte *.
5100
5101 2015-10-29 Pedro Alves <palves@redhat.com>
5102
5103 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
5104
5105 2015-10-29 Pedro Alves <palves@redhat.com>
5106
5107 * tracepoint.c (clear_installed_tracepoints): Add casts.
5108
5109 2015-10-29 Pedro Alves <palves@redhat.com>
5110
5111 * server.c (handle_v_cont, process_serial_event): Add enum
5112 gdb_signal casts to signal parsing code.
5113
5114 2015-10-29 Pedro Alves <palves@redhat.com>
5115
5116 * linux-low.h (NULL_REGSET): Define.
5117 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5118 * linux-arm-low.c (arm_regsets): Likewise.
5119 * linux-crisv32-low.c (cris_regsets): Likewise.
5120 * linux-m68k-low.c (m68k_regsets): Likewise.
5121 * linux-mips-low.c (mips_regsets): Likewise.
5122 * linux-nios2-low.c (nios2_regsets): Likewise.
5123 * linux-ppc-low.c (ppc_regsets): Likewise.
5124 * linux-s390-low.c (s390_regsets): Likewise.
5125 * linux-sh-low.c (sh_regsets): Likewise.
5126 * linux-sparc-low.c (sparc_regsets): Likewise.
5127 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5128 * linux-tile-low.c (tile_regsets): Likewise.
5129 * linux-x86-low.c (x86_regsets): Likewise.
5130 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5131
5132 2015-10-29 Pedro Alves <palves@redhat.com>
5133
5134 * linux-low.h (NULL_REGSET): Define.
5135 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5136 * linux-arm-low.c (arm_regsets): Likewise.
5137 * linux-crisv32-low.c (cris_regsets): Likewise.
5138 * linux-m68k-low.c (m68k_regsets): Likewise.
5139 * linux-mips-low.c (mips_regsets): Likewise.
5140 * linux-nios2-low.c (nios2_regsets): Likewise.
5141 * linux-ppc-low.c (ppc_regsets): Likewise.
5142 * linux-s390-low.c (s390_regsets): Likewise.
5143 * linux-sh-low.c (sh_regsets): Likewise.
5144 * linux-sparc-low.c (sparc_regsets): Likewise.
5145 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5146 * linux-tile-low.c (tile_regsets): Likewise.
5147 * linux-x86-low.c (x86_regsets): Likewise.
5148 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5149
5150 2015-10-26 Doug Evans <dje@google.com>
5151
5152 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5153
5154 2015-10-26 Doug Evans <dje@google.com>
5155
5156 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5157
5158 2015-10-26 Doug Evans <dje@google.com>
5159
5160 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5161 for debug_printf.
5162 (attach_thread, find_new_threads_callback): Ditto.
5163
5164 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5165
5166 * mem-break.h (set_breakpoint_data): Remove.
5167
5168 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5169
5170 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5171 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5172 (initialize_low): Remove set_breakpoint_data call.
5173 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5174 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5175 (initialize_low): Remove set_breakpoint_data call.
5176 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5177 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5178 (initialize_low): Remove set_breakpoint_data call.
5179
5180 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5181
5182 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5183 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5184 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5185 * target.h (target_breakpoint_kind_from_pc): New macro.
5186
5187 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5188
5189 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5190 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5191 the default breakpoint kind.
5192
5193 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5194
5195 * linux-arm-low.c (arm_supports_z_point_type): Add software
5196 breakpoint support.
5197
5198 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5199
5200 * linux-arm-low.c: Refactor breakpoint definitions.
5201 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5202 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5203
5204 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5205
5206 * Makefile.in: Add arm.c/o.
5207 * configure.srv: Likewise.
5208 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5209 (arm_breakpoint_kind_from_pc): New function.
5210 (arm_sw_breakpoint_from_kind): Return proper kind.
5211 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5212
5213 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5214
5215 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5216 removal.
5217 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5218 (struct raw_breakpoint) <size>: Remove.
5219 (struct raw_breakpoint) <kind>: Add.
5220 (bp_size): New function.
5221 (bp_opcode): Likewise.
5222 (find_raw_breakpoint_at): Adjust for kind.
5223 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5224 (remove_memory_breakpoint): Adjust for kind call bp_size.
5225 (set_raw_breakpoint_at): Adjust for kind.
5226 (set_breakpoint): Likewise.
5227 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5228 (delete_raw_breakpoint): Adjust for kind.
5229 (delete_breakpoint): Likewise.
5230 (find_gdb_breakpoint): Likewise.
5231 (set_gdb_breakpoint_1): Likewise.
5232 (set_gdb_breakpoint): Likewise.
5233 (delete_gdb_breakpoint_1): Likewise.
5234 (delete_gdb_breakpoint): Likewise.
5235 (uninsert_raw_breakpoint): Likewise.
5236 (reinsert_raw_breakpoint): Likewise.
5237 (set_breakpoint_data): Remove.
5238 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5239 (check_mem_read): Adjust for kind call bp_size.
5240 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5241 (clone_one_breakpoint): Adjust for kind.
5242 * mem-break.h (set_gdb_breakpoint): Likewise.
5243 (delete_gdb_breakpoint): Likewise.
5244 * server.c (process_serial_event): Likewise.
5245
5246 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5247
5248 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5249 (struct linux_target_ops) <breakpoint>: Remove.
5250 (struct linux_target_ops) <breakpoint_len>: Remove.
5251 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5252 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5253 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5254 (arm_sw_breakpoint_from_kind): New function.
5255 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
5256 (struct linux_target_ops) <breakpoint>: Remove.
5257 (struct linux_target_ops) <breakpoint_len>: Remove.
5258 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5259 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5260 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
5261 (struct linux_target_ops) <breakpoint>: Remove.
5262 (struct linux_target_ops) <breakpoint_len>: Remove.
5263 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5264 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5265 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5266 (struct linux_target_ops) <breakpoint>: Remove.
5267 (struct linux_target_ops) <breakpoint_len>: Remove.
5268 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5269 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5270 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5271 and sw_breakpoint_from_kind to increment the pc.
5272 (linux_breakpoint_kind_from_pc): New function.
5273 (linux_sw_breakpoint_from_kind): New function.
5274 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5275 (initialize_low): Call breakpoint_kind_from_pc and
5276 sw_breakpoint_from_kind to replace breakpoint_data/len.
5277 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5278 New field.
5279 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5280 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
5281 (struct linux_target_ops) <breakpoint>: Remove.
5282 (struct linux_target_ops) <breakpoint_len>: Remove.
5283 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5284 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5285 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
5286 (struct linux_target_ops) <breakpoint>: Remove.
5287 (struct linux_target_ops) <breakpoint_len>: Remove.
5288 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5289 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5290 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
5291 (struct linux_target_ops) <breakpoint>: Remove.
5292 (struct linux_target_ops) <breakpoint_len>: Remove.
5293 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5294 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5295 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
5296 (struct linux_target_ops) <breakpoint>: Remove.
5297 (struct linux_target_ops) <breakpoint_len>: Remove.
5298 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5299 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5300 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
5301 (struct linux_target_ops) <breakpoint>: Remove.
5302 (struct linux_target_ops) <breakpoint_len>: Remove.
5303 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5304 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5305 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
5306 (struct linux_target_ops) <breakpoint>: Remove.
5307 (struct linux_target_ops) <breakpoint_len>: Remove.
5308 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5309 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5310 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
5311 (struct linux_target_ops) <breakpoint>: Remove.
5312 (struct linux_target_ops) <breakpoint_len>: Remove.
5313 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5314 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5315 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
5316 (struct linux_target_ops) <breakpoint>: Remove.
5317 (struct linux_target_ops) <breakpoint_len>: Remove.
5318 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5319 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5320 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
5321 (struct linux_target_ops) <breakpoint>: Remove.
5322 (struct linux_target_ops) <breakpoint_len>: Remove.
5323 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5324 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5325 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5326 * linux-x86-low.c (x86_sw_breakpoint_from_kind): New function.
5327 (struct linux_target_ops) <breakpoint>: Remove.
5328 (struct linux_target_ops) <breakpoint_len>: Remove.
5329 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5330 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5331 * linux-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5332 (struct linux_target_ops) <breakpoint>: Remove.
5333 (struct linux_target_ops) <breakpoint_len>: Remove.
5334 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5335 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5336
5337 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5338
5339 * linux-cris-low.c (cris_get_pc): Remove void arg.
5340
5341 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5342
5343 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5344 variable name.
5345
5346 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5347
5348 * inferiors.c (thread_pid_matches_callback): New function.
5349 (find_thread_process): New function.
5350 (remove_thread): Reset current_thread.
5351 (remove_process): Assert threads have been removed first.
5352
5353 2015-10-15 Yao Qi <yao.qi@linaro.org>
5354
5355 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5356 if it is 3.
5357 (aarch64_remove_point): Likewise.
5358 * regcache.c (regcache_register_size): New function.
5359
5360 2015-10-12 Yao Qi <yao.qi@linaro.org>
5361
5362 * linux-aarch64-low.c: Update all callers as emit_load_store
5363 is renamed to aarch64_emit_load_store.
5364
5365 2015-10-12 Yao Qi <yao.qi@linaro.org>
5366
5367 * linux-aarch64-low.c: Update all callers of function renaming
5368 from emit_insn to aarch64_emit_insn.
5369
5370 2015-10-12 Yao Qi <yao.qi@linaro.org>
5371
5372 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5373 arch/aarch64-insn.h.
5374 (struct aarch64_memory_operand): Likewise.
5375 (ENCODE): Likewise.
5376 (emit_insn): Move to arch/aarch64-insn.c.
5377 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5378 (emit_load_store): Move to arch/aarch64-insn.c.
5379 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5380 (can_encode_int32): Remove.
5381
5382 2015-10-12 Yao Qi <yao.qi@linaro.org>
5383
5384 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5385 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5386 (aarch64_relocate_instruction): Likewise.
5387 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5388 (struct aarch64_insn_visitor): Likewise.
5389
5390 2015-10-12 Yao Qi <yao.qi@linaro.org>
5391
5392 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5393 (struct aarch64_insn_visitor): New.
5394 (struct aarch64_insn_relocation_data): New.
5395 (aarch64_ftrace_insn_reloc_b): New function.
5396 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5397 (aarch64_ftrace_insn_reloc_cb): Likewise.
5398 (aarch64_ftrace_insn_reloc_tb): Likewise.
5399 (aarch64_ftrace_insn_reloc_adr): Likewise.
5400 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5401 (aarch64_ftrace_insn_reloc_others): Likewise.
5402 (visitor): New.
5403 (aarch64_relocate_instruction): Use visitor.
5404
5405 2015-10-12 Yao Qi <yao.qi@linaro.org>
5406
5407 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5408 int. Add argument buf.
5409 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5410 aarch64_relocate_instruction.
5411
5412 2015-10-12 Yao Qi <yao.qi@linaro.org>
5413
5414 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5415 argument insn. Remove local variable insn. Don't call
5416 target_read_uint32.
5417 (aarch64_install_fast_tracepoint_jump_pad): Call
5418 target_read_uint32.
5419
5420 2015-09-30 Yao Qi <yao.qi@linaro.org>
5421
5422 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5423 (emit_load_store_pair): Likewise.
5424
5425 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5426
5427 * dll.c (match_dll): Add cast(s).
5428 (unloaded_dll): Likewise.
5429 * linux-low.c (second_thread_of_pid_p): Likewise.
5430 (delete_lwp_callback): Likewise.
5431 (count_events_callback): Likewise.
5432 (select_event_lwp_callback): Likewise.
5433 (linux_set_resume_request): Likewise.
5434 * server.c (accumulate_file_name_length): Likewise.
5435 (emit_dll_description): Likewise.
5436 (handle_qxfer_threads_worker): Likewise.
5437 (visit_actioned_threads): Likewise.
5438 * thread-db.c (any_thread_of): Likewise.
5439 * tracepoint.c (same_process_p): Likewise.
5440 (match_blocktype): Likewise.
5441 (build_traceframe_info_xml): Likewise.
5442
5443 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5444
5445 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5446 assignment.
5447 (gdb_unparse_agent_expr): Likewise.
5448 * hostio.c (require_data): Likewise.
5449 (handle_pread): Likewise.
5450 * linux-low.c (disable_regset): Likewise.
5451 (fetch_register): Likewise.
5452 (store_register): Likewise.
5453 (get_dynamic): Likewise.
5454 (linux_qxfer_libraries_svr4): Likewise.
5455 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5456 (set_fast_tracepoint_jump): Likewise.
5457 (uninsert_fast_tracepoint_jumps_at): Likewise.
5458 (reinsert_fast_tracepoint_jumps_at): Likewise.
5459 (validate_inserted_breakpoint): Likewise.
5460 (clone_agent_expr): Likewise.
5461 * regcache.c (init_register_cache): Likewise.
5462 * remote-utils.c (putpkt_binary_1): Likewise.
5463 (decode_M_packet): Likewise.
5464 (decode_X_packet): Likewise.
5465 (look_up_one_symbol): Likewise.
5466 (relocate_instruction): Likewise.
5467 (monitor_output): Likewise.
5468 * server.c (handle_search_memory): Likewise.
5469 (handle_qxfer_exec_file): Likewise.
5470 (handle_qxfer_libraries): Likewise.
5471 (handle_qxfer): Likewise.
5472 (handle_query): Likewise.
5473 (handle_v_cont): Likewise.
5474 (handle_v_run): Likewise.
5475 (captured_main): Likewise.
5476 * target.c (write_inferior_memory): Likewise.
5477 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5478 * tracepoint.c (init_trace_buffer): Likewise.
5479 (add_tracepoint_action): Likewise.
5480 (add_traceframe): Likewise.
5481 (add_traceframe_block): Likewise.
5482 (cmd_qtdpsrc): Likewise.
5483 (cmd_qtdv): Likewise.
5484 (cmd_qtstatus): Likewise.
5485 (response_source): Likewise.
5486 (response_tsv): Likewise.
5487 (cmd_qtnotes): Likewise.
5488 (gdb_collect): Likewise.
5489 (initialize_tracepoint): Likewise.
5490
5491 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5492
5493 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5494 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5495 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5496 <NOP>: New.
5497 (enum aarch64_condition_codes): New enum.
5498 (w0): New static global.
5499 (fp): Likewise.
5500 (lr): Likewise.
5501 (struct aarch64_memory_operand) <type>: New
5502 MEMORY_OPERAND_POSTINDEX type.
5503 (postindex_memory_operand): New helper function.
5504 (emit_ret): New function.
5505 (emit_load_store_pair): New function, factored out of emit_stp
5506 with support for MEMORY_OPERAND_POSTINDEX.
5507 (emit_stp): Rewrite using emit_load_store_pair.
5508 (emit_ldp): New function.
5509 (emit_load_store): Likewise.
5510 (emit_ldr): Mention post-index instruction in comment.
5511 (emit_ldrh): New function.
5512 (emit_ldrb): New function.
5513 (emit_ldrsw): Mention post-index instruction in comment.
5514 (emit_str): Likewise.
5515 (emit_subs): New function.
5516 (emit_cmp): Likewise.
5517 (emit_and): Likewise.
5518 (emit_orr): Likewise.
5519 (emit_orn): Likewise.
5520 (emit_eor): Likewise.
5521 (emit_mvn): Likewise.
5522 (emit_lslv): Likewise.
5523 (emit_lsrv): Likewise.
5524 (emit_asrv): Likewise.
5525 (emit_mul): Likewise.
5526 (emit_sbfm): Likewise.
5527 (emit_sbfx): Likewise.
5528 (emit_ubfm): Likewise.
5529 (emit_ubfx): Likewise.
5530 (emit_csinc): Likewise.
5531 (emit_cset): Likewise.
5532 (emit_nop): Likewise.
5533 (emit_ops_insns): New helper function.
5534 (emit_pop): Likewise.
5535 (emit_push): Likewise.
5536 (aarch64_emit_prologue): New function.
5537 (aarch64_emit_epilogue): Likewise.
5538 (aarch64_emit_add): Likewise.
5539 (aarch64_emit_sub): Likewise.
5540 (aarch64_emit_mul): Likewise.
5541 (aarch64_emit_lsh): Likewise.
5542 (aarch64_emit_rsh_signed): Likewise.
5543 (aarch64_emit_rsh_unsigned): Likewise.
5544 (aarch64_emit_ext): Likewise.
5545 (aarch64_emit_log_not): Likewise.
5546 (aarch64_emit_bit_and): Likewise.
5547 (aarch64_emit_bit_or): Likewise.
5548 (aarch64_emit_bit_xor): Likewise.
5549 (aarch64_emit_bit_not): Likewise.
5550 (aarch64_emit_equal): Likewise.
5551 (aarch64_emit_less_signed): Likewise.
5552 (aarch64_emit_less_unsigned): Likewise.
5553 (aarch64_emit_ref): Likewise.
5554 (aarch64_emit_if_goto): Likewise.
5555 (aarch64_emit_goto): Likewise.
5556 (aarch64_write_goto_address): Likewise.
5557 (aarch64_emit_const): Likewise.
5558 (aarch64_emit_call): Likewise.
5559 (aarch64_emit_reg): Likewise.
5560 (aarch64_emit_pop): Likewise.
5561 (aarch64_emit_stack_flush): Likewise.
5562 (aarch64_emit_zero_ext): Likewise.
5563 (aarch64_emit_swap): Likewise.
5564 (aarch64_emit_stack_adjust): Likewise.
5565 (aarch64_emit_int_call_1): Likewise.
5566 (aarch64_emit_void_call_2): Likewise.
5567 (aarch64_emit_eq_goto): Likewise.
5568 (aarch64_emit_ne_goto): Likewise.
5569 (aarch64_emit_lt_goto): Likewise.
5570 (aarch64_emit_le_goto): Likewise.
5571 (aarch64_emit_gt_goto): Likewise.
5572 (aarch64_emit_ge_got): Likewise.
5573 (aarch64_emit_ops_impl): New static global variable.
5574 (aarch64_emit_ops): New target function, return
5575 &aarch64_emit_ops_impl.
5576 (struct linux_target_ops): Install it.
5577
5578 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5579
5580 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5581 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5582 aarch64-ipa.o.
5583 * linux-aarch64-ipa.c: New file.
5584 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5585 and endian.h.
5586 (aarch64_get_thread_area): New target method.
5587 (extract_signed_bitfield): New helper function.
5588 (aarch64_decode_ldr_literal): New function.
5589 (enum aarch64_opcodes): New enum.
5590 (struct aarch64_register): New struct.
5591 (struct aarch64_operand): New struct.
5592 (x0): New static global.
5593 (x1): Likewise.
5594 (x2): Likewise.
5595 (x3): Likewise.
5596 (x4): Likewise.
5597 (w2): Likewise.
5598 (ip0): Likewise.
5599 (sp): Likewise.
5600 (xzr): Likewise.
5601 (aarch64_register): New helper function.
5602 (register_operand): Likewise.
5603 (immediate_operand): Likewise.
5604 (struct aarch64_memory_operand): New struct.
5605 (offset_memory_operand): New helper function.
5606 (preindex_memory_operand): Likewise.
5607 (enum aarch64_system_control_registers): New enum.
5608 (ENCODE): New macro.
5609 (emit_insn): New helper function.
5610 (emit_b): New function.
5611 (emit_bcond): Likewise.
5612 (emit_cb): Likewise.
5613 (emit_tb): Likewise.
5614 (emit_blr): Likewise.
5615 (emit_stp): Likewise.
5616 (emit_ldp_q_offset): Likewise.
5617 (emit_stp_q_offset): Likewise.
5618 (emit_load_store): Likewise.
5619 (emit_ldr): Likewise.
5620 (emit_ldrsw): Likewise.
5621 (emit_str): Likewise.
5622 (emit_ldaxr): Likewise.
5623 (emit_stxr): Likewise.
5624 (emit_stlr): Likewise.
5625 (emit_data_processing_reg): Likewise.
5626 (emit_data_processing): Likewise.
5627 (emit_add): Likewise.
5628 (emit_sub): Likewise.
5629 (emit_mov): Likewise.
5630 (emit_movk): Likewise.
5631 (emit_mov_addr): Likewise.
5632 (emit_mrs): Likewise.
5633 (emit_msr): Likewise.
5634 (emit_sevl): Likewise.
5635 (emit_wfe): Likewise.
5636 (append_insns): Likewise.
5637 (can_encode_int32_in): New helper function.
5638 (aarch64_relocate_instruction): New function.
5639 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5640 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5641 (struct linux_target_ops): Install aarch64_get_thread_area,
5642 aarch64_install_fast_tracepoint_jump_pad and
5643 aarch64_get_min_fast_tracepoint_insn_len.
5644
5645 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5646
5647 * Makefile.in (aarch64-insn.o): New rule.
5648 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5649
5650 2015-09-21 Yao Qi <yao.qi@linaro.org>
5651
5652 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5653
5654 2015-09-21 Yao Qi <yao.qi@linaro.org>
5655
5656 * tracepoint.c (max_jump_pad_size): Remove.
5657
5658 2015-09-18 Yao Qi <yao.qi@linaro.org>
5659
5660 * linux-aarch64-low.c: Don't include sys/uio.h.
5661 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5662
5663 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5664
5665 * tracepoint.c (eval_result_type): Change prototype.
5666 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5667
5668 2015-09-15 Pedro Alves <palves@redhat.com>
5669
5670 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5671 Check whether to report exec events instead of checking whether
5672 multiprocess is enabled.
5673
5674 2015-09-15 Pedro Alves <palves@redhat.com>
5675
5676 PR remote/18965
5677 * remote-utils.c (prepare_resume_reply): Merge
5678 TARGET_WAITKIND_VFORK_DONE switch case with the
5679 TARGET_WAITKIND_FORKED case.
5680
5681 2015-09-15 Yao Qi <yao.qi@linaro.org>
5682
5683 * server.c (handle_query): Check string comparison using
5684 "else if" instead of "if".
5685
5686 2015-09-15 Yao Qi <yao.qi@linaro.org>
5687
5688 * server.c (vCont_supported): New global variable.
5689 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5690 matches. Append ";vContSupported+" to own_buf.
5691 (handle_v_requests): Append ";s;S" to own_buf if target supports
5692 hardware single step or vCont_supported is false.
5693 (capture_main): Set vCont_supported to zero.
5694
5695 2015-09-15 Yao Qi <yao.qi@linaro.org>
5696
5697 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5698 it to ...
5699 (linux_supports_hardware_single_step): ... New function.
5700 (linux_target_ops): Update.
5701 * lynx-low.c (lynx_target_ops): Set field
5702 supports_hardware_single_step to target_can_do_hardware_single_step.
5703 * nto-low.c (nto_target_ops): Likewise.
5704 * spu-low.c (spu_target_ops): Likewise.
5705 * win32-low.c (win32_target_ops): Likewise.
5706 * target.c (target_can_do_hardware_single_step): New function.
5707 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5708 Remove. <supports_hardware_single_step>: New field.
5709 (target_supports_conditional_breakpoints): Remove.
5710 (target_supports_hardware_single_step): New macro.
5711 (target_can_do_hardware_single_step): Declare.
5712 * server.c (handle_query): Use target_supports_hardware_single_step
5713 instead of target_supports_conditional_breakpoints.
5714
5715 2015-09-15 Yao Qi <yao.qi@linaro.org>
5716
5717 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5718 function.
5719 (struct linux_target_ops the_low_target): Install
5720 aarch64_linux_siginfo_fixup.
5721
5722 2015-09-11 Don Breazeal <donb@codesourcery.com>
5723 Luis Machado <lgustavo@codesourcery.com>
5724
5725 * linux-low.c (linux_mourn): Static declaration.
5726 (linux_arch_setup): Move in front of
5727 handle_extended_wait.
5728 (linux_arch_setup_thread): New function.
5729 (handle_extended_wait): Handle exec events. Call
5730 linux_arch_setup_thread. Make event_lwp argument a
5731 pointer-to-a-pointer.
5732 (check_zombie_leaders): Do not check stopped threads.
5733 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5734 (linux_low_filter_event): Add lwp and thread for exec'ing
5735 non-leader thread if leader thread has been deleted.
5736 Refactor code into linux_arch_setup_thread and call it.
5737 Pass child lwp pointer by reference to handle_extended_wait.
5738 (linux_wait_for_event_filtered): Update comment.
5739 (linux_wait_1): Prevent clobbering exec event status.
5740 (linux_supports_exec_events): New function.
5741 (linux_target_ops) <supports_exec_events>: Initialize new member.
5742 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5743 new member.
5744 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5745 * server.c (report_exec_events): New global variable.
5746 (handle_query): Handle qSupported query for exec-events feature.
5747 (captured_main): Initialize report_exec_events.
5748 * server.h (report_exec_events): Declare new global variable.
5749 * target.h (struct target_ops) <supports_exec_events>: New
5750 member.
5751 (target_supports_exec_events): New macro.
5752 * win32-low.c (win32_target_ops) <supports_exec_events>:
5753 Initialize new member.
5754
5755 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5756
5757 * linux-low.c (linux_low_enable_btrace): Remove.
5758 (linux_target_ops): Replace linux_low_enable_btrace with
5759 linux_enable_btrace.
5760
5761 2015-09-03 Yao Qi <yao.qi@linaro.org>
5762
5763 * linux-aarch64-low.c (aarch64_insert_point): Call
5764 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5765 returns true.
5766
5767 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5768
5769 * linux-low.c (check_stopped_by_breakpoint): Use
5770 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5771
5772 2015-08-27 Pedro Alves <palves@redhat.com>
5773
5774 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5775
5776 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5777
5778 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5779 the XNEW-family equivalent.
5780 (compile_bytecodes): Likewise.
5781 * dll.c (loaded_dll): Likewise.
5782 * event-loop.c (append_callback_event): Likewise.
5783 (create_file_handler): Likewise.
5784 (create_file_event): Likewise.
5785 * hostio.c (handle_open): Likewise.
5786 * inferiors.c (add_thread): Likewise.
5787 (add_process): Likewise.
5788 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5789 * linux-arm-low.c (arm_new_process): Likewise.
5790 (arm_new_thread): Likewise.
5791 * linux-low.c (add_to_pid_list): Likewise.
5792 (linux_add_process): Likewise.
5793 (handle_extended_wait): Likewise.
5794 (add_lwp): Likewise.
5795 (enqueue_one_deferred_signal): Likewise.
5796 (enqueue_pending_signal): Likewise.
5797 (linux_resume_one_lwp_throw): Likewise.
5798 (linux_resume_one_thread): Likewise.
5799 (linux_read_memory): Likewise.
5800 (linux_write_memory): Likewise.
5801 * linux-mips-low.c (mips_linux_new_process): Likewise.
5802 (mips_linux_new_thread): Likewise.
5803 (mips_add_watchpoint): Likewise.
5804 * linux-x86-low.c (initialize_low_arch): Likewise.
5805 * lynx-low.c (lynx_add_process): Likewise.
5806 * mem-break.c (set_raw_breakpoint_at): Likewise.
5807 (set_breakpoint): Likewise.
5808 (add_condition_to_breakpoint): Likewise.
5809 (add_commands_to_breakpoint): Likewise.
5810 (clone_agent_expr): Likewise.
5811 (clone_one_breakpoint): Likewise.
5812 * regcache.c (new_register_cache): Likewise.
5813 * remote-utils.c (look_up_one_symbol): Likewise.
5814 * server.c (queue_stop_reply): Likewise.
5815 (start_inferior): Likewise.
5816 (queue_stop_reply_callback): Likewise.
5817 (handle_target_event): Likewise.
5818 * spu-low.c (fetch_ppc_memory): Likewise.
5819 (store_ppc_memory): Likewise.
5820 * target.c (set_target_ops): Likewise.
5821 * thread-db.c (thread_db_load_search): Likewise.
5822 (try_thread_db_load_1): Likewise.
5823 * tracepoint.c (add_tracepoint): Likewise.
5824 (add_tracepoint_action): Likewise.
5825 (create_trace_state_variable): Likewise.
5826 (cmd_qtdpsrc): Likewise.
5827 (cmd_qtro): Likewise.
5828 (add_while_stepping_state): Likewise.
5829 * win32-low.c (child_add_thread): Likewise.
5830 (get_image_name): Likewise.
5831
5832 2015-08-25 Yao Qi <yao.qi@linaro.org>
5833
5834 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5835
5836 2015-08-25 Yao Qi <yao.qi@linaro.org>
5837
5838 * Makefile.in (aarch64-linux.o): New rule.
5839 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5840 srv_tgtobj.
5841 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5842 (aarch64_init_debug_reg_state): Make it extern.
5843 (aarch64_linux_prepare_to_resume): Remove.
5844
5845 2015-08-25 Yao Qi <yao.qi@linaro.org>
5846
5847 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5848 lwp_arch_private_info and ptid_of_lwp.
5849
5850 2015-08-25 Yao Qi <yao.qi@linaro.org>
5851
5852 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5853 Find proc_info by find_process_pid. All callers updated.
5854
5855 2015-08-25 Yao Qi <yao.qi@linaro.org>
5856
5857 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5858 Remove.
5859 (debug_reg_change_callback): Remove.
5860 (aarch64_notify_debug_reg_change): Remove.
5861
5862 2015-08-25 Yao Qi <yao.qi@linaro.org>
5863
5864 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5865 Call current_lwp_ptid.
5866
5867 2015-08-25 Yao Qi <yao.qi@linaro.org>
5868
5869 * linux-aarch64-low.c (debug_reg_change_callback): Use
5870 debug_printf.
5871
5872 2015-08-25 Yao Qi <yao.qi@linaro.org>
5873
5874 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5875
5876 2015-08-25 Yao Qi <yao.qi@linaro.org>
5877
5878 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5879
5880 2015-08-25 Yao Qi <yao.qi@linaro.org>
5881
5882 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5883 the code.
5884
5885 2015-08-25 Yao Qi <yao.qi@linaro.org>
5886
5887 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5888 Remove.
5889 (debug_reg_change_callback): Remove argument entry and add argument
5890 lwp. Remove local variable thread. Don't print thread id in the
5891 debugging output. Don't check whether pid of thread equals to pid.
5892 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5893 iterate_over_lwps instead find_inferior.
5894
5895 2015-08-24 Pedro Alves <palves@redhat.com>
5896
5897 * inferiors.c (get_first_process): New function.
5898 * inferiors.h (get_first_process): New declaration.
5899 * remote-utils.c (read_ptid): Default to the first process in the
5900 list, instead of to the current thread's process.
5901
5902 2015-08-24 Pedro Alves <palves@redhat.com>
5903
5904 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5905 * event-loop.c: Likewise.
5906 * remote-utils.c: Likewise.
5907 * tracepoint.c: Likewise.
5908
5909 2015-08-24 Pedro Alves <palves@redhat.com>
5910
5911 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5912 ptid_get_lwp.
5913
5914 2015-08-21 Pedro Alves <palves@redhat.com>
5915
5916 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5917 instead of literal 1.
5918
5919 2015-08-21 Pedro Alves <palves@redhat.com>
5920
5921 * tdesc.c (default_description): Explicitly zero-initialize.
5922
5923 2015-08-21 Pedro Alves <palves@redhat.com>
5924
5925 PR gdb/18749
5926 * inferiors.c (remove_thread): Discard any pending stop reply for
5927 this thread.
5928 * server.c (remove_all_on_match_pid): Rename to ...
5929 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5930 instead of a pid.
5931 (discard_queued_stop_replies): Change parameter to a ptid. Now
5932 extern.
5933 (handle_v_kill, kill_inferior_callback, captured_main)
5934 (process_serial_event): Adjust.
5935 * server.h (discard_queued_stop_replies): Declare.
5936
5937 2015-08-21 Pedro Alves <palves@redhat.com>
5938
5939 * linux-low.c (wait_for_sigstop): Always switch to no thread
5940 selected if the previously current thread dies.
5941 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5942 process instead of the current thread's.
5943 * remote-utils.c (input_interrupt): Don't check if there's no
5944 current thread.
5945 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5946 current thread to the general thread fails, error out.
5947 (handle_qxfer_auxv, handle_qxfer_libraries)
5948 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5949 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5950 (handle_query): Check if there's a thread selected instead of
5951 checking whether there's any thread in the thread list.
5952 (handle_qxfer_threads, handle_qxfer_btrace)
5953 (handle_qxfer_btrace_conf): Don't error out early if there's no
5954 thread in the thread list.
5955 (handle_v_cont, myresume): Don't set the current thread to the
5956 continue thread.
5957 (process_serial_event) <Hg handling>: Also set thread_id if the
5958 previous general thread is still alive.
5959 (process_serial_event) <g/G handling>: If setting the current
5960 thread to the general thread fails, error out.
5961 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5962 thread's lwp instead of the current thread's.
5963 * target.c (set_desired_thread): If the desired thread was not
5964 found, leave the current thread pointing to NULL. Return an int
5965 (boolean) indicating success.
5966 * target.h (set_desired_thread): Change return type to int.
5967
5968 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5969
5970 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5971 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5972 #includes.
5973 (ps_get_thread_area): New function.
5974
5975 2015-08-19 Gary Benson <gbenson@redhat.com>
5976
5977 * hostio.c (handle_pread): Do not attempt to read more data
5978 than hostio_reply_with_data can fit in a packet.
5979
5980 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5981
5982 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5983
5984 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5985
5986 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5987
5988 2015-08-06 Pedro Alves <palves@redhat.com>
5989
5990 * tracepoint.c (expr_eval_result): Now an int.
5991
5992 2015-08-06 Pedro Alves <palves@redhat.com>
5993
5994 * gdbthread.h (struct regcache): Forward declare.
5995 (struct thread_info) <regcache_data>: Now a struct regcache
5996 pointer.
5997 * inferiors.c (inferior_regcache_data)
5998 (set_inferior_regcache_data): Now work with struct regcache
5999 pointers.
6000 * inferiors.h (struct regcache): Forward declare.
6001 (inferior_regcache_data, set_inferior_regcache_data): Now work
6002 with struct regcache pointers.
6003 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
6004 (free_register_cache_thread): Remove struct regcache pointer
6005 casts.
6006
6007 2015-08-06 Pedro Alves <palves@redhat.com>
6008
6009 * server.c (captured_main): On error, print the exception message
6010 to stderr, and if run_once is set, throw a quit.
6011
6012 2015-08-06 Pedro Alves <palves@redhat.com>
6013
6014 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
6015 the current thread.
6016
6017 2015-08-06 Pedro Alves <palves@redhat.com>
6018
6019 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
6020 reading beyond the passed in buffer length.
6021
6022 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
6023
6024 * tracepoint.c (symbol_list) <required>: Remove.
6025
6026 2015-08-06 Pedro Alves <palves@redhat.com>
6027
6028 * linux-low.c (handle_extended_wait): Set the fork child's suspend
6029 count if stopping and suspending threads.
6030 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
6031 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
6032 (linux_detach): Complete an ongoing step-over.
6033 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
6034 throughout.
6035 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
6036 (linux_wait_1): If passing a signal to the inferior after
6037 finishing a step-over, unsuspend and re-resume all lwps. If we
6038 see a single-step event but the thread should be continuing, don't
6039 pass the trap to gdb.
6040 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
6041 internal_error instead of gdb_assert.
6042 (enqueue_pending_signal): New function.
6043 (check_ptrace_stopped_lwp_gone): Add debug output.
6044 (start_step_over): Use internal_error instead of gdb_assert.
6045 (complete_ongoing_step_over): New function.
6046 (linux_resume_one_thread): Don't resume a suspended thread.
6047 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
6048 it stepping.
6049
6050 2015-08-06 Pedro Alves <palves@redhat.com>
6051
6052 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
6053 (linux_thread_alive): Use lwp_is_marked_dead.
6054 (extended_event_reported): Delete.
6055 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
6056 instead of extended_event_reported.
6057 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
6058 as well.
6059 (lwp_is_marked_dead): New function.
6060 (lwp_running): Use lwp_is_marked_dead.
6061 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
6062 comment.
6063
6064 2015-08-06 Pedro Alves <palves@redhat.com>
6065
6066 * linux-low.c (linux_wait_1): Move fork event output out of the
6067 !report_to_gdb check. Pass event_child->waitstatus to
6068 target_waitstatus_to_string instead of ourstatus.
6069
6070 2015-08-04 Yao Qi <yao.qi@linaro.org>
6071
6072 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
6073 if current_thread is 32 bit.
6074
6075 2015-08-04 Yao Qi <yao.qi@linaro.org>
6076
6077 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6078 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6079 * server.c (extended_protocol): Remove "static".
6080 * server.h (extended_protocol): Declare it.
6081
6082 2015-08-04 Yao Qi <yao.qi@linaro.org>
6083
6084 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
6085 both aarch64 and aarch32.
6086 (aarch64_set_pc): Likewise.
6087
6088 2015-08-04 Yao Qi <yao.qi@linaro.org>
6089
6090 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
6091 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
6092 arm-with-neon.xml to srv_xmlfiles.
6093 * linux-aarch64-low.c: Include linux-aarch32-low.h.
6094 (is_64bit_tdesc): New function.
6095 (aarch64_linux_read_description): New function.
6096 (aarch64_arch_setup): Call aarch64_linux_read_description.
6097 (regs_info): Rename to regs_info_aarch64.
6098 (aarch64_regs_info): Return right regs_info.
6099 (initialize_low_arch): Call initialize_low_arch_aarch32.
6100
6101 2015-08-04 Yao Qi <yao.qi@linaro.org>
6102
6103 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
6104 * linux-aarch32-low.c: New file.
6105 * linux-aarch32-low.h: New file.
6106 * linux-arm-low.c (arm_fill_gregset): Move it to
6107 linux-aarch32-low.c.
6108 (arm_store_gregset): Likewise.
6109 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
6110 (arm_store_vfpregset): Call arm_store_vfpregset_num.
6111 (arm_arch_setup): Check if PTRACE_GETREGSET works.
6112 (regs_info): Rename to regs_info_arm.
6113 (arm_regs_info): Return regs_info_aarch32 if
6114 have_ptrace_getregset is 1 and target description is
6115 arm_with_neon or arm_with_vfpv3.
6116 (initialize_low_arch): Don't call init_registers_arm_with_neon.
6117 Call initialize_low_arch_aarch32 instead.
6118
6119 2015-08-04 Yao Qi <yao.qi@linaro.org>
6120
6121 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
6122 * linux-low.c: ... here.
6123 * linux-low.h (have_ptrace_getregset): Declare it.
6124
6125 2015-08-04 Pedro Alves <palves@redhat.com>
6126
6127 * thread-db.c (struct thread_db): Use new typedefs.
6128 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6129 CHK calls.
6130 (disable_thread_event_reporting): Cast result of dlsym to
6131 destination function pointer type.
6132 (thread_db_mourn): Use td_ta_delete_ftype.
6133
6134 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6135
6136 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6137 arch variant.
6138 (CDX_BREAKPOINT): Define for R2.
6139 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6140 (the_low_target): Add comments.
6141
6142 2015-07-30 Yao Qi <yao.qi@linaro.org>
6143
6144 * linux-arm-low.c (arm_hwcap): Remove it.
6145 (arm_read_description): New local variable arm_hwcap. Don't
6146 set arm_hwcap to zero.
6147
6148 2015-07-30 Yao Qi <yao.qi@linaro.org>
6149
6150 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6151 Use regcache->tdesc instead.
6152 (arm_store_wmmxregset): Likewise.
6153 (arm_fill_vfpregset): Likewise.
6154 (arm_store_vfpregset): Likewise.
6155
6156 2015-07-30 Yao Qi <yao.qi@linaro.org>
6157
6158 * linux-arm-low.c: Include arch/arm.h.
6159 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6160 (arm_store_gregset): Likewise.
6161
6162 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6163
6164 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6165 ptrace's 4th parameter.
6166
6167 2015-07-27 Yao Qi <yao.qi@linaro.org>
6168
6169 * configure.srv (case aarch64*-*-linux*): Don't set
6170 srv_linux_usrregs.
6171
6172 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6173
6174 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6175 sys/ptrace.h.
6176 * linux-arm-low.c: Likewise.
6177 * linux-cris-low.c: Likewise.
6178 * linux-crisv32-low.c: Likewise.
6179 * linux-low.c: Likewise.
6180 * linux-m68k-low.c: Likewise.
6181 * linux-mips-low.c: Likewise.
6182 * linux-nios2-low.c: Likewise.
6183 * linux-s390-low.c: Likewise.
6184 * linux-sparc-low.c: Likewise.
6185 * linux-tic6x-low.c: Likewise.
6186 * linux-tile-low.c: Likewise.
6187 * linux-x86-low.c: Likewise.
6188
6189 2015-07-24 Pedro Alves <palves@redhat.com>
6190
6191 * config.in: Regenerate.
6192 * configure: Regenerate.
6193
6194 2015-07-24 Pedro Alves <palves@redhat.com>
6195
6196 * acinclude.m4: Include ../ptrace.m4.
6197 * configure.ac: Call GDB_AC_PTRACE.
6198 * config.in, configure: Regenerate.
6199
6200 2015-07-24 Yao Qi <yao.qi@linaro.org>
6201
6202 * linux-low.c (linux_create_inferior): Remove setting to
6203 proc->priv->new_inferior.
6204 (linux_attach): Likewise.
6205 (linux_low_filter_event): Likewise.
6206 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6207
6208 2015-07-24 Yao Qi <yao.qi@linaro.org>
6209
6210 * linux-low.c (linux_arch_setup): New function.
6211 (linux_low_filter_event): If proc->tdesc is NULL and
6212 proc->attached is true, call the_low_target.arch_setup.
6213 Otherwise, keep status pending, and return.
6214 (linux_resume_one_lwp_throw): Don't call get_pc if
6215 thread->while_stepping isn't NULL. Don't call
6216 get_thread_regcache if proc->tdesc is NULL.
6217 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6218 (linux_target_ops): Install arch_setup.
6219 * server.c (start_inferior): Call the_target->arch_setup.
6220 * target.h (struct target_ops) <arch_setup>: New field.
6221 (target_arch_setup): New marco.
6222 * lynx-low.c (lynx_target_ops): Update.
6223 * nto-low.c (nto_target_ops): Update.
6224 * spu-low.c (spu_target_ops): Update.
6225 * win32-low.c (win32_target_ops): Update.
6226
6227 2015-07-24 Yao Qi <yao.qi@linaro.org>
6228
6229 * linux-low.c (linux_add_process): Don't set
6230 proc->priv->new_inferior.
6231 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6232 (linux_attach): Likewise.
6233
6234 2015-07-24 Yao Qi <yao.qi@linaro.org>
6235
6236 * server.c (start_inferior): Code refactor.
6237
6238 2015-07-24 Yao Qi <yao.qi@linaro.org>
6239
6240 * server.c (process_serial_event): Set general_thread.
6241
6242 2015-07-21 Yao Qi <yao.qi@linaro.org>
6243
6244 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6245 aarch64_linux_get_debug_reg_capacity.
6246
6247 2015-07-17 Yao Qi <yao.qi@linaro.org>
6248
6249 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6250 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6251 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6252 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6253 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6254 (AARCH64_HWP_ALIGNMENT): Likewise.
6255 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6256 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6257 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6258 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6259 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6260 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6261 (struct aarch64_debug_reg_state): Likewise.
6262 (struct arch_lwp_info): Likewise.
6263 (aarch64_align_watchpoint): Likewise.
6264 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6265 (aarch64_watchpoint_length): Likewise.
6266 (aarch64_point_encode_ctrl_reg): Likewise
6267 (aarch64_point_is_aligned): Likewise.
6268 (aarch64_align_watchpoint): Likewise.
6269 (aarch64_linux_set_debug_regs):
6270 (aarch64_dr_state_insert_one_point): Likewise.
6271 (aarch64_dr_state_remove_one_point): Likewise.
6272 (aarch64_handle_breakpoint): Likewise.
6273 (aarch64_handle_aligned_watchpoint): Likewise.
6274 (aarch64_handle_unaligned_watchpoint): Likewise.
6275 (aarch64_handle_watchpoint): Likewise.
6276
6277 2015-07-17 Yao Qi <yao.qi@linaro.org>
6278
6279 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6280 and don't aarch64_get_debug_reg_state. All callers update.
6281 (aarch64_handle_aligned_watchpoint): Likewise.
6282 (aarch64_handle_unaligned_watchpoint): Likewise.
6283 (aarch64_handle_watchpoint): Likewise.
6284 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6285 (aarch64_remove_point): Likewise.
6286
6287 2015-07-17 Yao Qi <yao.qi@linaro.org>
6288
6289 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6290 debug_printf.
6291 (aarch64_handle_unaligned_watchpoint): Likewise.
6292
6293 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6294
6295 Revert the previous 3 commits:
6296 Move gdb_regex* to common/
6297 Move linux_find_memory_regions_full & co.
6298 gdbserver build-id attribute generator
6299
6300 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6301 Jan Kratochvil <jan.kratochvil@redhat.com>
6302
6303 gdbserver build-id attribute generator.
6304 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6305 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6306 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6307 (find_phdr): New.
6308 (get_dynamic): Use find_pdhr to traverse program headers.
6309 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6310 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6311 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6312 (get_hex_build_id): New.
6313 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6314 to reply XML document.
6315
6316 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6317 Jan Kratochvil <jan.kratochvil@redhat.com>
6318
6319 * target.c: Include target/target-utils.h and fcntl.h.
6320 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6321 (target_fileio_read_stralloc): New functions.
6322
6323 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6324
6325 * Makefile.in (OBS): Add gdb_regex.o.
6326 (gdb_regex.o): New.
6327 * config.in: Rebuilt.
6328 * configure: Rebuilt.
6329
6330 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6331 Jan Kratochvil <jan.kratochvil@redhat.com>
6332
6333 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6334 * Makefile.in (OBS): Add target-utils.o.
6335 (linux-maps.o, target-utils.o): New.
6336 * configure.srv (srv_linux_obj): Add linux-maps.o.
6337
6338 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6339
6340 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6341 function, return 1.
6342 (the_low_target): Install it.
6343
6344 2015-07-14 Pedro Alves <palves@redhat.com>
6345
6346 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6347 Instead, ignore ECHILD, and throw an error for other errnos.
6348
6349 2015-07-10 Pedro Alves <palves@redhat.com>
6350
6351 * event-loop.c (struct callback_event) <data>: Change type to
6352 gdb_client_data instance instead of gdb_client_data pointer.
6353 (append_callback_event): Adjust.
6354
6355 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6356
6357 * linux-aarch64-low.c: Add comments for each linux_target_ops
6358 method. Remove comments already covered in target_ops and
6359 linux_target_ops definitions.
6360 (the_low_target): Add comments for each unimplemented method.
6361
6362 2015-07-09 Yao Qi <yao.qi@linaro.org>
6363
6364 * linux-aarch64-low.c (aarch64_regmap): Remove.
6365 (aarch64_usrregs_info): Remove.
6366 (regs_info): Set field usrregs to NULL.
6367
6368 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6369
6370 * linux-low.c: Include "rsp-low.h"
6371 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6372 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6373 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6374 (handle_btrace_enable_pt): New.
6375 (handle_btrace_general_set): Support "pt".
6376 (handle_btrace_conf_general_set): Support "pt:size".
6377
6378 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6379
6380 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6381 Z_PACKET_SW_BP.
6382
6383 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6384
6385 * linux-aarch64-low.c: Remove comment about endianness.
6386 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6387 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6388 memcmp.
6389
6390 2015-06-24 Gary Benson <gbenson@redhat.com>
6391
6392 * linux-i386-ipa.c (stdint.h): Do not include.
6393 * lynx-i386-low.c (stdint.h): Likewise.
6394 * lynx-ppc-low.c (stdint.h): Likewise.
6395 * mem-break.c (stdint.h): Likewise.
6396 * thread-db.c (stdint.h): Likewise.
6397 * tracepoint.c (stdint.h): Likewise.
6398 * win32-low.c (stdint.h): Likewise.
6399
6400 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6401
6402 * server.c (write_qxfer_response): Update call to
6403 remote_escape_output.
6404
6405 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6406 Jan Kratochvil <jan.kratochvil@redhat.com>
6407
6408 Merge multiple hex conversions.
6409 * gdbreplay.c (tohex): Rename to 'fromhex'.
6410 (logchar): Use fromhex.
6411
6412 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6413
6414 * server.c (handle_qxfer_libraries): Set `version' attribute for
6415 <library-list>.
6416
6417 2015-06-10 Gary Benson <gbenson@redhat.com>
6418
6419 * target.h (struct target_ops) <multifs_open>: New field.
6420 <multifs_unlink>: Likewise.
6421 <multifs_readlink>: Likewise.
6422 * linux-low.c (nat/linux-namespaces.h): New include.
6423 (linux_target_ops): Initialize the_target->multifs_open,
6424 the_target->multifs_unlink and the_target->multifs_readlink.
6425 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6426 * hostio.c (hostio_fs_pid): New static variable.
6427 (hostio_handle_new_gdb_connection): New function.
6428 (handle_setfs): Likewise.
6429 (handle_open): Use the_target->multifs_open as appropriate.
6430 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6431 (handle_readlink): Use the_target->multifs_readlink as
6432 appropriate.
6433 (handle_vFile): Handle vFile:setfs packets.
6434 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6435 after target_handle_new_gdb_connection.
6436
6437 2015-06-10 Gary Benson <gbenson@redhat.com>
6438
6439 * configure.ac (AC_CHECK_FUNCS): Add setns.
6440 * config.in: Regenerate.
6441 * configure: Likewise.
6442 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6443 (linux-namespaces.o): New rule.
6444 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6445
6446 2015-06-09 Gary Benson <gbenson@redhat.com>
6447
6448 * hostio.c (handle_open): Process mode argument with
6449 fileio_to_host_mode.
6450
6451 2015-06-01 Yao Qi <yao.qi@linaro.org>
6452
6453 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6454 * linux-x86-low.c: Likewise.
6455
6456 2015-05-28 Don Breazeal <donb@codesourcery.com>
6457
6458 * linux-low.c (handle_extended_wait): Initialize
6459 thread_info.last_resume_kind for new fork children.
6460
6461 2015-05-15 Pedro Alves <palves@redhat.com>
6462
6463 * target.h (target_handle_new_gdb_connection): Rewrite using if
6464 wrapped in do/while.
6465
6466 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6467
6468 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6469 * configure, config.in: Regenerate.
6470 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6471 Declare typedef.
6472
6473 2015-05-12 Don Breazeal <donb@codesourcery.com>
6474
6475 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6476 PTRACE_EVENT_VFORK_DONE.
6477 (linux_low_ptrace_options, extended_event_reported): Add vfork
6478 events.
6479 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6480 and "vforkdone" for RSP 'T' Stop Reply Packet.
6481 * server.h (report_vfork_events): Declare
6482 global variable.
6483
6484 2015-05-12 Don Breazeal <donb@codesourcery.com>
6485
6486 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6487 (the_low_target) <new_fork>: Initialize new member.
6488 * linux-arm-low.c (arm_new_fork): New function.
6489 (the_low_target) <new_fork>: Initialize new member.
6490 * linux-low.c (handle_extended_wait): Call new target function
6491 new_fork.
6492 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6493 * linux-mips-low.c (mips_add_watchpoint): New function
6494 extracted from mips_insert_point.
6495 (the_low_target) <new_fork>: Initialize new member.
6496 (mips_linux_new_fork): New function.
6497 (mips_insert_point): Call mips_add_watchpoint.
6498 * linux-x86-low.c (x86_linux_new_fork): New function.
6499 (the_low_target) <new_fork>: Initialize new member.
6500
6501 2015-05-12 Don Breazeal <donb@codesourcery.com>
6502
6503 * linux-low.c (handle_extended_wait): Implement return value,
6504 rename argument 'event_child' to 'event_lwp', handle
6505 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6506 (linux_low_ptrace_options): New function.
6507 (linux_low_filter_event): Call linux_low_ptrace_options,
6508 use different argument fo linux_enable_event_reporting,
6509 use return value from handle_extended_wait.
6510 (extended_event_reported): New function.
6511 (linux_wait_1): Call extended_event_reported and set
6512 status to report fork events.
6513 (linux_write_memory): Add pid to debug message.
6514 (reset_lwp_ptrace_options_callback): New function.
6515 (linux_handle_new_gdb_connection): New function.
6516 (linux_target_ops): Initialize new structure member.
6517 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6518 * lynx-low.c: Initialize new structure member.
6519 * remote-utils.c (prepare_resume_reply): Implement stop reason
6520 "fork" for "T" stop message.
6521 * server.c (handle_query): Call handle_new_gdb_connection.
6522 * server.h (report_fork_events): Declare global flag.
6523 * target.h (struct target_ops) <handle_new_gdb_connection>:
6524 New member.
6525 (target_handle_new_gdb_connection): New macro.
6526 * win32-low.c: Initialize new structure member.
6527
6528 2015-05-12 Don Breazeal <donb@codesourcery.com>
6529
6530 * mem-break.c (APPEND_TO_LIST): Define macro.
6531 (clone_agent_expr): New function.
6532 (clone_one_breakpoint): New function.
6533 (clone_all_breakpoints): New function.
6534 * mem-break.h: Declare new functions.
6535
6536 2015-05-12 Don Breazeal <donb@codesourcery.com>
6537
6538 * linux-low.c (linux_supports_fork_events): New function.
6539 (linux_supports_vfork_events): New function.
6540 (linux_target_ops): Initialize new structure members.
6541 (initialize_low): Call linux_check_ptrace_features.
6542 * lynx-low.c (lynx_target_ops): Initialize new structure
6543 members.
6544 * server.c (report_fork_events, report_vfork_events):
6545 New global flags.
6546 (handle_query): Add new features to qSupported packet and
6547 response.
6548 (captured_main): Initialize new global variables.
6549 * target.h (struct target_ops) <supports_fork_events>:
6550 New member.
6551 <supports_vfork_events>: New member.
6552 (target_supports_fork_events): New macro.
6553 (target_supports_vfork_events): New macro.
6554 * win32-low.c (win32_target_ops): Initialize new structure
6555 members.
6556
6557 2015-05-12 Gary Benson <gbenson@redhat.com>
6558
6559 * server.c (handle_qxfer_exec_file): Use current process
6560 if annex is empty.
6561
6562 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6563
6564 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6565 Remove HAVE_PTRACE_GETREGS conditionals.
6566 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6567 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6568
6569 2015-05-08 Yao Qi <yao.qi@linaro.org>
6570
6571 * linux-low.c (linux_supports_conditional_breakpoints): New
6572 function.
6573 (linux_target_ops): Install new target method.
6574 * lynx-low.c (lynx_target_ops): Install NULL hook for
6575 supports_conditional_breakpoints.
6576 * nto-low.c (nto_target_ops): Likewise.
6577 * spu-low.c (spu_target_ops): Likewise.
6578 * win32-low.c (win32_target_ops): Likewise.
6579 * server.c (handle_query): Check
6580 target_supports_conditional_breakpoints.
6581 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6582 New field.
6583 (target_supports_conditional_breakpoints): New macro.
6584
6585 2015-05-06 Pedro Alves <palves@redhat.com>
6586
6587 PR server/18081
6588 * server.c (start_inferior): If the process exits, mourn it.
6589
6590 2015-04-21 Gary Benson <gbenson@redhat.com>
6591
6592 * hostio.c (fileio_open_flags_to_host): Factored out to
6593 fileio_to_host_openflags in common/fileio.c. Single use
6594 updated.
6595
6596 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6597
6598 * linux-xtensa-low.c (xtensa_fill_gregset)
6599 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6600 XCHAL_HAVE_LOOP.
6601
6602 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6603
6604 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6605 (regs_info): Replace usrregs pointer with NULL.
6606
6607 2015-04-17 Gary Benson <gbenson@redhat.com>
6608
6609 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6610 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6611 * server.c (handle_qxfer_exec_file): New function.
6612 (qxfer_packets): Add exec-file entry.
6613 (handle_query): Report qXfer:exec-file:read as supported packet.
6614
6615 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6616
6617 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6618
6619 2015-04-09 Gary Benson <gbenson@redhat.com>
6620
6621 * hostio-errno.c (errno_to_fileio_error): Remove function.
6622 Update caller to use remote_fileio_to_fio_error.
6623
6624 2015-04-09 Yao Qi <yao.qi@linaro.org>
6625
6626 * linux-low.c (linux_insert_point): Call
6627 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6628 (linux_remove_point): Call remove_memory_breakpoint if type is
6629 raw_bkpt_type_sw.
6630 * linux-x86-low.c (x86_insert_point): Don't call
6631 insert_memory_breakpoint.
6632 (x86_remove_point): Don't call remove_memory_breakpoint.
6633
6634 2015-04-01 Pedro Alves <palves@redhat.com>
6635 Cleber Rosa <crosa@redhat.com>
6636
6637 * server.c (gdbserver_usage): Reorganize and extend the usage
6638 message.
6639
6640 2015-03-24 Pedro Alves <palves@redhat.com>
6641
6642 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6643 output. Also dump TRAP_TRACE.
6644 (linux_low_filter_event): In debug output, distinguish a
6645 resume_stop SIGSTOP from a delayed SIGSTOP.
6646
6647 2015-03-24 Gary Benson <gbenson@redhat.com>
6648
6649 * linux-x86-low.c (x86_linux_new_thread): Moved to
6650 nat/x86-linux.c.
6651 (x86_linux_prepare_to_resume): Likewise.
6652
6653 2015-03-24 Gary Benson <gbenson@redhat.com>
6654
6655 * Makefile.in (x86-linux-dregs.o): New rule.
6656 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6657 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6658 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6659 (x86_linux_dr_get): Likewise.
6660 (x86_linux_dr_set): Likewise.
6661 (update_debug_registers_callback): Likewise.
6662 (x86_linux_dr_set_addr): Likewise.
6663 (x86_linux_dr_get_addr): Likewise.
6664 (x86_linux_dr_set_control): Likewise.
6665 (x86_linux_dr_get_control): Likewise.
6666 (x86_linux_dr_get_status): Likewise.
6667 (x86_linux_update_debug_registers): Likewise.
6668
6669 2015-03-24 Gary Benson <gbenson@redhat.com>
6670
6671 * linux-x86-low.c (x86_linux_update_debug_registers):
6672 New function, factored out from...
6673 (x86_linux_prepare_to_resume): ...this.
6674
6675 2015-03-24 Gary Benson <gbenson@redhat.com>
6676
6677 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6678 (x86_linux_dr_set): Likewise.
6679 (update_debug_registers_callback): Likewise.
6680 (x86_linux_dr_set_addr): Likewise.
6681 (x86_linux_dr_get_addr): Likewise.
6682 (x86_linux_dr_set_control): Likewise.
6683 (x86_linux_dr_get_control): Likewise.
6684 (x86_linux_dr_get_status): Likewise.
6685 (x86_linux_prepare_to_resume): Likewise.
6686
6687 2015-03-24 Gary Benson <gbenson@redhat.com>
6688
6689 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6690 Use perror_with_name. Pass string through gettext.
6691 (x86_linux_dr_set): Likewise.
6692
6693 2015-03-24 Gary Benson <gbenson@redhat.com>
6694
6695 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6696 (x86_linux_dr_set_addr): ...this.
6697 (x86_dr_low_get_addr): Rename to...
6698 (x86_linux_dr_get_addr): ...this.
6699 (x86_dr_low_set_control): Rename to...
6700 (x86_linux_dr_set_control): ...this.
6701 (x86_dr_low_get_control): Rename to...
6702 (x86_linux_dr_get_control): ...this.
6703 (x86_dr_low_get_status): Rename to...
6704 (x86_linux_dr_get_status): ...this.
6705 (x86_dr_low): Update with new function names.
6706
6707 2015-03-24 Gary Benson <gbenson@redhat.com>
6708
6709 * Makefile.in (x86-linux.o): New rule.
6710 * configure.srv: Add x86-linux.o to relevant targets.
6711 * linux-low.c (lwp_set_arch_private_info): New function.
6712 (lwp_arch_private_info): Likewise.
6713 * linux-x86-low.c: Include nat/x86-linux.h.
6714 (arch_lwp_info): Removed structure.
6715 (update_debug_registers_callback):
6716 Use lwp_set_debug_registers_changed.
6717 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6718 and lwp_set_debug_registers_changed.
6719 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6720
6721 2015-03-24 Gary Benson <gbenson@redhat.com>
6722
6723 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6724 * linux-arm-low.c (arm_new_thread): Likewise.
6725 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6726 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6727 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6728 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6729
6730 2015-03-24 Gary Benson <gbenson@redhat.com>
6731
6732 * linux-low.c (ptid_of_lwp): New function.
6733 (lwp_is_stopped): Likewise.
6734 (lwp_stop_reason): Likewise.
6735 * linux-x86-low.c (update_debug_registers_callback):
6736 Use lwp_is_stopped.
6737 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6738 lwp_stop_reason.
6739
6740 2015-03-24 Gary Benson <gbenson@redhat.com>
6741
6742 * linux-low.h (linux_stop_lwp): Remove declaration.
6743
6744 2015-03-24 Gary Benson <gbenson@redhat.com>
6745
6746 * linux-low.h: Include nat/linux-nat.h.
6747 * linux-low.c (iterate_over_lwps_args): New structure.
6748 (iterate_over_lwps_filter): New function.
6749 (iterate_over_lwps): Likewise.
6750 * linux-x86-low.c (update_debug_registers_callback):
6751 Update signature to what iterate_over_lwps expects.
6752 Remove PID check that iterate_over_lwps now performs.
6753 (x86_dr_low_set_addr): Use iterate_over_lwps.
6754 (x86_dr_low_set_control): Likewise.
6755
6756 2015-03-24 Gary Benson <gbenson@redhat.com>
6757
6758 * linux-x86-low.c (x86_debug_reg_state): New function.
6759 (x86_linux_prepare_to_resume): Use the above.
6760
6761 2015-03-24 Gary Benson <gbenson@redhat.com>
6762
6763 * linux-low.c (current_lwp_ptid): New function.
6764 * linux-x86-low.c: Include nat/linux-nat.h.
6765 (x86_dr_low_get_addr): Use current_lwp_ptid.
6766 (x86_dr_low_get_control): Likewise.
6767 (x86_dr_low_get_status): Likewise.
6768
6769 2015-03-20 Pedro Alves <palves@redhat.com>
6770
6771 * tracepoint.c (cmd_qtstatus): Make "str" const.
6772
6773 2015-03-20 Pedro Alves <palves@redhat.com>
6774
6775 * server.c (handle_general_set): Make "req_str" const.
6776
6777 2015-03-19 Pedro Alves <palves@redhat.com>
6778
6779 * linux-low.c (linux_resume_one_lwp): Rename to ...
6780 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6781 instead call perror_with_name.
6782 (check_ptrace_stopped_lwp_gone): New function.
6783 (linux_resume_one_lwp): Reimplement as wrapper around
6784 linux_resume_one_lwp_throw that swallows errors if the LWP is
6785 gone.
6786
6787 2015-03-19 Pedro Alves <palves@redhat.com>
6788
6789 * linux-low.c (count_events_callback, select_event_lwp_callback):
6790 No longer check whether the thread has resume_stop as last resume
6791 kind.
6792
6793 2015-03-19 Pedro Alves <palves@redhat.com>
6794
6795 * linux-low.c (count_events_callback, select_event_lwp_callback):
6796 Use the lwp's status_pending_p field, not the thread's.
6797
6798 2015-03-19 Pedro Alves <palves@redhat.com>
6799
6800 * linux-low.c (select_event_lwp_callback): Update comments to
6801 no longer mention SIGTRAP.
6802
6803 2015-03-18 Gary Benson <gbenson@redhat.com>
6804
6805 * server.c (handle_query): Do not report vFile:fstat as supported.
6806
6807 2015-03-11 Gary Benson <gbenson@redhat.com>
6808
6809 * hostio.c (sys/types.h): New include.
6810 (sys/stat.h): Likewise.
6811 (common-remote-fileio.h): Likewise.
6812 (handle_fstat): New function.
6813 (handle_vFile): Handle vFile:fstat packets.
6814
6815 2015-03-11 Gary Benson <gbenson@redhat.com>
6816
6817 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6818 struct stat.st_blocks and struct stat.st_blksize.
6819 * configure: Regenerate.
6820 * config.in: Likewise.
6821 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6822 (OBS): Add common-remote-fileio.o.
6823 (common-remote-fileio.o): New rule.
6824
6825 2015-03-09 Pedro Alves <palves@redhat.com>
6826
6827 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6828 'struct sockaddr' pointer in 'accept' call.
6829
6830 2015-03-09 Pedro Alves <palves@redhat.com>
6831
6832 Revert:
6833 2015-03-07 Pedro Alves <palves@redhat.com>
6834 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6835 or <winsock2.h> here. Instead include "gdb_socket.h".
6836 (remote_open): Use union gdb_sockaddr_u.
6837 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6838 or <winsock2.h> here. Instead include "gdb_socket.h".
6839 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6840 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6841 or <sys/un.h>.
6842 (init_named_socket, gdb_agent_helper_thread): Use union
6843 gdb_sockaddr_u.
6844
6845 2015-03-07 Pedro Alves <palves@redhat.com>
6846
6847 * configure.ac (build_warnings): Move
6848 -Wdeclaration-after-statement to the C-specific set.
6849 * configure: Regenerate.
6850
6851 2015-03-07 Pedro Alves <palves@redhat.com>
6852
6853 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6854 or <winsock2.h> here. Instead include "gdb_socket.h".
6855 (remote_open): Use union gdb_sockaddr_u.
6856 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6857 or <winsock2.h> here. Instead include "gdb_socket.h".
6858 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6859 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6860 or <sys/un.h>.
6861 (init_named_socket, gdb_agent_helper_thread): Use union
6862 gdb_sockaddr_u.
6863
6864 2015-03-07 Pedro Alves <palves@redhat.com>
6865
6866 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6867 instead.
6868
6869 2015-03-06 Yao Qi <yao.qi@linaro.org>
6870
6871 * linux-aarch64-low.c (aarch64_insert_point): Use
6872 show_debug_regs as a boolean.
6873 (aarch64_remove_point): Likewise.
6874
6875 2015-03-05 Pedro Alves <palves@redhat.com>
6876
6877 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6878 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6879 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6880 * nto-low.c (nto_target_ops): Likewise.
6881 * spu-low.c (spu_target_ops): Likewise.
6882 * win32-low.c (win32_target_ops): Likewise.
6883
6884 2015-03-04 Pedro Alves <palves@redhat.com>
6885
6886 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6887 Decide whether a breakpoint triggered based on the SIGTRAP's
6888 siginfo.si_code.
6889 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6890 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6891 (linux_low_filter_event): Check for breakpoints before checking
6892 watchpoints.
6893 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6894 siginfo.si_code.
6895 (linux_stopped_by_sw_breakpoint)
6896 (linux_supports_stopped_by_sw_breakpoint)
6897 (linux_stopped_by_hw_breakpoint)
6898 (linux_supports_stopped_by_hw_breakpoint): New functions.
6899 (linux_target_ops): Install new target methods.
6900
6901 2015-03-04 Pedro Alves <palves@redhat.com>
6902
6903 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6904 * server.c (swbreak_feature, hwbreak_feature): New globals.
6905 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6906 (captured_main): Clear swbreak_feature and hwbreak_feature.
6907 * server.h (swbreak_feature, hwbreak_feature): Declare.
6908 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6909 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6910 supports_stopped_by_hw_breakpoint>: New fields.
6911 (target_supports_stopped_by_sw_breakpoint)
6912 (target_stopped_by_sw_breakpoint)
6913 (target_supports_stopped_by_hw_breakpoint)
6914 (target_stopped_by_hw_breakpoint): Declare.
6915
6916 2015-03-04 Pedro Alves <palves@redhat.com>
6917
6918 enum lwp_stop_reason -> enum target_stop_reason
6919 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6920 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6921 (linux_wait_1, stuck_in_jump_pad_callback)
6922 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6923 (linux_stopped_by_watchpoint):
6924 * linux-low.h (enum lwp_stop_reason): Delete.
6925 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6926 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6927
6928 2015-03-04 Yao Qi <yao.qi@linaro.org>
6929
6930 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6931
6932 2015-03-03 Gary Benson <gbenson@redhat.com>
6933
6934 * hostio.c (handle_vFile): Fix prefix lengths.
6935
6936 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6937
6938 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6939 ptr_bits.
6940
6941 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6942
6943 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6944 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6945 (clean): Add "rm -f" for above C files.
6946 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6947 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6948 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6949 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6950 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6951 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6952 (init_registers_s390x_vx_linux64)
6953 (init_registers_s390x_tevx_linux64)
6954 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6955 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6956 declarations.
6957 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6958 (s390_store_vxrs_high): New functions.
6959 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6960 NT_S390_VXRS_HIGH.
6961 (s390_arch_setup): Add logic for selecting one of the new target
6962 descriptions. Activate the new vector regsets if applicable.
6963 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6964 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6965 and init_registers_s390x_tevx_linux64.
6966
6967 2015-03-01 Pedro Alves <palves@redhat.com>
6968
6969 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6970 parameter.
6971
6972 2015-02-27 Pedro Alves <palves@redhat.com>
6973
6974 * linux-x86-low.c (u_debugreg_offset): New function.
6975 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6976
6977 2015-02-27 Pedro Alves <palves@redhat.com>
6978
6979 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6980 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6981 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6982 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6983 (ps_lsetfpregs, ps_getpid)
6984 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6985 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6986 (ps_lsetxregs, ps_plog): Declare.
6987
6988 2015-02-27 Pedro Alves <palves@redhat.com>
6989
6990 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6991 IP_AGENT_EXPORT_FUNC.
6992 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6993 IP_AGENT_EXPORT_FUNC.
6994 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6995 (IP_AGENT_EXPORT): Delete.
6996 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6997 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6998 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6999 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
7000 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
7001 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
7002 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
7003 (traceframe_read_count, traceframe_write_count)
7004 (traceframes_created, trace_state_variables, get_raw_reg)
7005 (get_trace_state_variable_value, set_trace_state_variable_value)
7006 (ust_loaded, helper_thread_id, cmd_buf): Use
7007 IPA_SYM_EXPORTED_NAME.
7008 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
7009 (tracepoints) Use IP_AGENT_EXPORT_VAR.
7010 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
7011 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7012 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
7013 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
7014 EXTERN_C_PUSH/EXTERN_C_POP.
7015 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
7016 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
7017 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7018 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
7019 (traceframe_write_count, traceframe_read_count)
7020 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
7021 (about_to_request_buffer_space, get_trace_state_variable_value)
7022 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
7023 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
7024 EXTERN_C_PUSH/EXTERN_C_POP.
7025 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
7026 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
7027 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
7028 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7029 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7030 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7031 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
7032 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
7033 Define.
7034 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
7035 (IP_AGENT_EXPORT_VAR_DECL): Define.
7036 (tracing): Declare.
7037 (gdb_agent_get_raw_reg): Declare.
7038
7039 2015-02-27 Tom Tromey <tromey@redhat.com>
7040 Pedro Alves <palves@redhat.com>
7041
7042 Rename symbols whose names are reserved C++ keywords throughout.
7043
7044 2015-02-27 Pedro Alves <palves@redhat.com>
7045
7046 * Makefile.in (COMPILER): New, get it from autoconf.
7047 (CXX): Get from autoconf instead.
7048 (COMPILE.pre): Use COMPILER.
7049 (CC-LD): Rename to ...
7050 (CC_LD): ... this. Use COMPILER.
7051 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
7052 (CXX_FOR_TARGET): Default to g++ instead of gcc.
7053 * acinclude.m4: Include build-with-cxx.m4.
7054 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
7055 Disable -Werror by default if building in C++ mode.
7056 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
7057 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
7058 the C++ compiler. Save/restore CXXFLAGS too.
7059 * configure: Regenerate.
7060
7061 2015-02-27 Pedro Alves <palves@redhat.com>
7062
7063 * acinclude.m4: Include libiberty.m4.
7064 * configure.ac: Call libiberty_INIT.
7065 * config.in, configure: Regenerate.
7066
7067 2015-02-26 Pedro Alves <palves@redhat.com>
7068
7069 * linux-low.c (linux_wait_1): When incrementing the PC past a
7070 program breakpoint always use the_low_target.breakpoint_len as
7071 increment, rather than the maximum between that and
7072 the_low_target.decr_pc_after_break.
7073
7074 2015-02-23 Pedro Alves <palves@redhat.com>
7075
7076 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
7077 thread was doing a step-over; always adjust the PC if
7078 we stepped over a permanent breakpoint.
7079 (linux_wait_1): If we stepped over breakpoint that was on top of a
7080 permanent breakpoint, manually advance the PC past it.
7081
7082 2015-02-23 Pedro Alves <palves@redhat.com>
7083
7084 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
7085 modes.
7086 (x86_fill_gregset, x86_store_gregset): Use it when handling
7087 $orig_eax.
7088
7089 2015-02-20 Pedro Alves <palves@redhat.com>
7090
7091 * thread-db.c: Include "nat/linux-procfs.h".
7092 (thread_db_init): Skip listing new threads if the kernel supports
7093 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
7094
7095 2015-02-20 Pedro Alves <palves@redhat.com>
7096
7097 * linux-low.c (status_pending_p_callback): Use ptid_match.
7098
7099 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
7100
7101 PR breakpoints/16812
7102 * linux-low.c (wstatus_maybe_breakpoint): Remove.
7103 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
7104 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
7105
7106 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
7107
7108 PR breakpoints/15956
7109 * tracepoint.c (cmd_qtinit): Add check for current_thread.
7110
7111 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7112
7113 * linux-low.c (linux_low_btrace_conf): Print size.
7114 * server.c (handle_btrace_conf_general_set): New.
7115 (hanle_general_set): Call handle_btrace_conf_general_set.
7116 (handle_query): Report Qbtrace-conf:bts:size as supported.
7117
7118 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7119
7120 * linux-low.c (linux_low_enable_btrace): Update parameters.
7121 (linux_low_btrace_conf): New.
7122 (linux_target_ops)<to_btrace_conf>: Initialize.
7123 * server.c (current_btrace_conf): New.
7124 (handle_btrace_enable): Rename to ...
7125 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
7126 to target_enable_btrace. Update comment. Update users.
7127 (handle_qxfer_btrace_conf): New.
7128 (qxfer_packets): Add btrace-conf entry.
7129 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7130 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7131 (target_ops)<read_btrace_conf>: New.
7132 (target_enable_btrace): Update parameters.
7133 (target_read_btrace_conf): New.
7134
7135 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7136
7137 * server.c (handle_btrace_general_set): Remove call to
7138 target_supports_btrace.
7139 (supported_btrace_packets): New.
7140 (handle_query): Call supported_btrace_packets.
7141 * target.h: include btrace-common.h.
7142 (btrace_target_info): Removed.
7143 (supports_btrace, target_supports_btrace): Update parameters.
7144
7145 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7146
7147 * Makefile.in (SFILES): Add common/btrace-common.c.
7148 (OBS): Add common/btrace-common.o.
7149 (btrace-common.o): Add build rules.
7150 * linux-low: Include btrace-common.h.
7151 (linux_low_read_btrace): Use struct btrace_data. Call
7152 btrace_data_init and btrace_data_fini.
7153
7154 2015-02-06 Pedro Alves <palves@redhat.com>
7155
7156 * thread-db.c (find_new_threads_callback): Add debug output.
7157
7158 2015-02-04 Pedro Alves <palves@redhat.com>
7159
7160 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7161 (resume_stopped_resumed_lwps): New function.
7162 (linux_wait_for_event_filtered): Use it.
7163
7164 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7165
7166 * Makefile.in (SFILES): Add linux-personality.c.
7167 (linux-personality.o): New rule.
7168 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7169 list of objects to be built.
7170 * linux-low.c: Include nat/linux-personality.h.
7171 (linux_create_inferior): Remove code to disable address space
7172 randomization (moved to ../nat/linux-personality.c). Create
7173 cleanup to disable address space randomization.
7174
7175 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7176
7177 * Makefile.in (posix-strerror.o): New rule.
7178 (mingw-strerror.o): Likewise.
7179 * configure: Regenerated.
7180 * configure.ac: Source file ../common/common.host. Initialize new
7181 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7182
7183 2015-01-14 Yao Qi <yao@codesourcery.com>
7184
7185 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7186 (ppc-linux.o): New rule.
7187 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7188 * configure.ac: AC_CHECK_FUNCS(getauxval).
7189 * config.in: Re-generated.
7190 * configure: Re-generated.
7191 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7192 ppc64_64bit_inferior_p
7193
7194 2015-01-14 Yao Qi <yao@codesourcery.com>
7195
7196 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7197 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7198 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7199 (PT_ORIG_R3, PT_TRAP): Likewise.
7200 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7201 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7202 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7203
7204 2015-01-10 Joel Brobecker <brobecker@adacore.com>
7205
7206 * i387-fp.c (i387_cache_to_xsave): In look over
7207 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7208 zmmh_low_space field by use of zmmh_high_space.
7209
7210 2015-01-09 Pedro Alves <palves@redhat.com>
7211
7212 * linux-low.c (step_over_bkpt): Move higher up in the file.
7213 (handle_extended_wait): Don't store the stop_pc here.
7214 (get_stop_pc): Adjust comments and rename to ...
7215 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7216 stopped for a software breakpoint or hardware breakpoint.
7217 (thread_still_has_status_pending_p): New function.
7218 (status_pending_p_callback): Use
7219 thread_still_has_status_pending_p. If the event is no longer
7220 interesting, resume the LWP.
7221 (handle_tracepoints): Add assert.
7222 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7223 (wstatus_maybe_breakpoint): New function.
7224 (cancel_breakpoint): Delete function.
7225 (check_stopped_by_watchpoint): New function, factored out from
7226 linux_low_filter_event.
7227 (lp_status_maybe_breakpoint): Delete function.
7228 (linux_low_filter_event): Remove filter_ptid argument.
7229 Leave thread group exits pending here. Store the LWP's stop PC.
7230 Always leave events pending.
7231 (linux_wait_for_event_filtered): Pull all events out of the
7232 kernel, and leave them all pending.
7233 (count_events_callback, select_event_lwp_callback): Consider all
7234 events.
7235 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7236 (select_event_lwp): Only give preference to the stepping LWP in
7237 all-stop mode. Adjust comments.
7238 (ignore_event): New function.
7239 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7240 references to cancel_breakpoints. Adjust to renames. Also give
7241 equal priority to all LWPs that have had events in non-stop mode.
7242 If reporting a software breakpoint event, unadjust the LWP's PC.
7243 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7244 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7245 Adjust.
7246 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7247 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7248 (linux_stopped_by_watchpoint): Adjust.
7249 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7250 * linux-low.h (enum lwp_stop_reason): New.
7251 (struct lwp_info) <stop_pc>: Adjust comment.
7252 <stopped_by_watchpoint>: Delete field.
7253 <stop_reason>: New field.
7254 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7255 * mem-break.c (software_breakpoint_inserted_here)
7256 (hardware_breakpoint_inserted_here): New function.
7257 * mem-break.h (software_breakpoint_inserted_here)
7258 (hardware_breakpoint_inserted_here): Declare.
7259 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7260 (cancel_breakpoints): Delete.
7261 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7262 (upload_fast_traceframes): Remove references to
7263 cancel_breakpoints.
7264
7265 2015-01-09 Pedro Alves <palves@redhat.com>
7266
7267 * thread-db.c (find_new_threads_callback): Ignore thread if the
7268 kernel thread ID is -1.
7269
7270 2015-01-09 Pedro Alves <palves@redhat.com>
7271
7272 * linux-low.c (linux_attach_fail_reason_string): Move to
7273 nat/linux-ptrace.c, and rename.
7274 (linux_attach_lwp): Update comment.
7275 (attach_proc_task_lwp_callback): New function.
7276 (linux_attach): Adjust to rename and use
7277 linux_proc_attach_tgid_threads.
7278 (linux_attach_fail_reason_string): Delete declaration.
7279
7280 2015-01-01 Joel Brobecker <brobecker@adacore.com>
7281
7282 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7283 * server.c (gdbserver_version): Likewise.
7284
7285 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7286
7287 * remote-utils.c: Include ctype.h.
7288 (input_interrupt): Explicitly handle the case when the char
7289 received is the NUL byte. Improve the printing of non-ASCII
7290 characters.
7291
7292 2014-12-16 Joel Brobecker <brobecker@adacore.com>
7293
7294 * linux-low.c (linux_low_filter_event): Update call to
7295 linux_enable_event_reporting following the addition of
7296 a new parameter to that function.
7297
7298 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
7299
7300 PR server/17457
7301 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7302 (AARCH64_FPCR_REGNO): Likewise.
7303 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7304 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7305 (aarch64_store_fpregset): Likewise.
7306
7307 2014-12-15 Joel Brobecker <brobecker@adacore.com>
7308
7309 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7310 Remove FIXME comment about assumption about N.
7311
7312 2014-12-13 Joel Brobecker <brobecker@adacore.com>
7313
7314 * configure.ac: If large-file support is disabled in GDBserver,
7315 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7316 * configure: Regenerate.
7317
7318 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7319
7320 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7321 warning upon ENODATA from ptrace.
7322 * linux-s390-low.c (s390_store_tdb): New.
7323 (s390_regsets): Add regset for NT_S390_TDB.
7324
7325 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7326
7327 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7328 without a fill_function.
7329 * linux-s390-low.c (s390_fill_last_break): Remove.
7330 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7331 (s390_arch_setup): Use regset's size instead of fill_function for
7332 loop end condition.
7333
7334 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7335
7336 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7337 the regset's store function when ptrace returned an error.
7338 * regcache.c (get_thread_regcache): Invalidate register cache
7339 before fetching inferior's registers.
7340
7341 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7342
7343 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7344 while-loop as for-loop.
7345 (regsets_store_inferior_registers): Likewise.
7346
7347 2014-11-28 Yao Qi <yao@codesourcery.com>
7348
7349 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7350 * config.in, configure: Re-generate.
7351 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7352 is defined.
7353
7354 2014-11-21 Yao Qi <yao@codesourcery.com>
7355
7356 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7357 (AC_CHECK_HEADERS): Remove malloc.h.
7358 * configure: Re-generated.
7359 * config.in: Re-generated.
7360 * server.h: Don't include alloca.h and malloc.h.
7361 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7362 Don't include malloc.h.
7363
7364 2014-11-17 Joel Brobecker <brobecker@adacore.com>
7365
7366 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7367 corresponding ERRNO check in same block.
7368
7369 2014-11-12 Pedro Alves <palves@redhat.com>
7370
7371 * server.c (cont_thread): Update comment.
7372 (start_inferior, attach_inferior): No longer clear cont_thread.
7373 (handle_v_cont): No longer set cont_thread.
7374 (captured_main): Clear cont_thread each time a GDB connects.
7375
7376 2014-11-12 Pedro Alves <palves@redhat.com>
7377
7378 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7379 thread, and don't resume all threads if the Hc thread has exited.
7380
7381 2014-11-12 Pedro Alves <palves@redhat.com>
7382
7383 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7384 the process group instead of to a specific LWP.
7385
7386 2014-10-15 Pedro Alves <palves@redhat.com>
7387
7388 PR server/17487
7389 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7390 parameter.
7391 (arm_set_thread_context): Delete.
7392 (the_low_target): Adjust.
7393 * win32-i386-low.c (debug_registers_changed)
7394 (debug_registers_used): Delete.
7395 (update_debug_registers_callback): New function.
7396 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7397 needing to update their debug registers.
7398 (win32_get_current_dr): New function.
7399 (x86_dr_low_get_addr, x86_dr_low_get_control)
7400 (x86_dr_low_get_status): Fetch the debug register from the thread
7401 record's context.
7402 (i386_initial_stuff): Adjust.
7403 (i386_get_thread_context): Remove current_event parameter. Don't
7404 clear debug_registers_changed nor copy DR values to
7405 debug_reg_state.
7406 (i386_set_thread_context): Delete.
7407 (i386_prepare_to_resume): New function.
7408 (i386_thread_added): Mark the thread as needing to update irs
7409 debug registers.
7410 (the_low_target): Remove i386_set_thread_context and install
7411 i386_prepare_to_resume.
7412 * win32-low.c (win32_get_thread_context): Adjust.
7413 (win32_set_thread_context): Use SetThreadContext
7414 directly.
7415 (win32_prepare_to_resume): New function.
7416 (win32_require_context): New function, factored out from ...
7417 (thread_rec): ... this.
7418 (continue_one_thread): Call win32_prepare_to_resume on each thread
7419 we're about to continue.
7420 (win32_resume): Call win32_prepare_to_resume on the event thread.
7421 * win32-low.h (struct win32_thread_info)
7422 <debug_registers_changed>: New field.
7423 (struct win32_target_ops): Change prototype of set_thread_context,
7424 delete set_thread_context and add prepare_to_resume.
7425 (win32_require_context): New declaration.
7426
7427 2014-10-08 Gary Benson <gbenson@redhat.com>
7428
7429 * server.h: Do not include common-exceptions.h.
7430
7431 2014-10-08 Gary Benson <gbenson@redhat.com>
7432
7433 * server.h: Do not include cleanups.h.
7434
7435 2014-09-30 James Hogan <james.hogan@imgtec.com>
7436
7437 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7438 mips64-dsp-linux.c.
7439
7440 2014-09-23 Yao Qi <yao@codesourcery.com>
7441
7442 * linux-low.c (lp_status_maybe_breakpoint): New function.
7443 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7444 (count_events_callback): Likewise.
7445 (select_event_lwp_callback): Likewise.
7446 (cancel_breakpoints_callback): Likewise.
7447
7448 2014-09-19 Don Breazeal <donb@codesourcery.com>
7449
7450 * linux-low.c (handle_extended_wait): Call
7451 linux_ptrace_get_extended_event.
7452 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7453 linux_is_extended_waitstatus.
7454
7455 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7456
7457 * Makefile.in (CPPFLAGS): Define.
7458 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7459 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7460
7461 2014-09-16 Gary Benson <gbenson@redhat.com>
7462
7463 * inferiors.h (current_inferior): Renamed as...
7464 (current_thread): New variable. All uses updated.
7465 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7466 (maybe_move_out_of_jump_pad): Likewise.
7467 (cancel_breakpoint): Likewise.
7468 (linux_low_filter_event): Likewise.
7469 (wait_for_sigstop): Likewise.
7470 (linux_resume_one_lwp): Likewise.
7471 (need_step_over_p): Likewise.
7472 (start_step_over): Likewise.
7473 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7474 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7475 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7476 and save_inferior as saved_thread.
7477 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7478 saved_thread.
7479 (regcache_invalidate_thread): Likewise.
7480 * remote-utils.c (prepare_resume_reply): Likewise.
7481 * thread-db.c (thread_db_get_tls_address): Likewise.
7482 (disable_thread_event_reporting): Likewise.
7483 (remove_thread_event_breakpoints): Likewise.
7484 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7485 as saved_thread.
7486 * target.h (set_desired_inferior): Renamed as...
7487 (set_desired_thread): New declaration. All uses updated.
7488 * server.c (myresume): Updated comment to reference thread instead
7489 of inferior.
7490 (handle_serial_event): Likewise.
7491 (handle_target_event): Likewise.
7492
7493 2014-09-12 Tom Tromey <tromey@redhat.com>
7494 Gary Benson <gbenson@redhat.com>
7495
7496 * regcache.h: Include common-regcache.h.
7497 (regcache_read_pc): Don't declare.
7498 * regcache.c (get_thread_regcache_for_ptid): New function.
7499
7500 2014-09-11 Tom Tromey <tromey@redhat.com>
7501 Gary Benson <gbenson@redhat.com>
7502
7503 * symbol.c: New file.
7504 * Makefile.in (SFILES): Add symbol.c.
7505 (OBS): Add symbol.o.
7506
7507 2014-09-11 Gary Benson <gbenson@redhat.com>
7508
7509 * target.c (target_stop_ptid, target_continue_ptid): New
7510 functions.
7511
7512 2014-09-11 Tom Tromey <tromey@redhat.com>
7513 Gary Benson <gbenson@redhat.com>
7514
7515 * target.h: Include target/target.h.
7516 * target.c (target_read_memory, target_read_uint32)
7517 (target_write_memory): New functions.
7518
7519 2014-09-11 Gary Benson <gbenson@redhat.com>
7520
7521 * server.h (debug_hw_points): Don't declare.
7522 * server.c (debug_hw_points): Don't define. Replace all uses
7523 with show_debug_regs.
7524 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7525 all uses with show_debug_regs.
7526
7527 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7528
7529 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7530 endianness into account.
7531 (ppc_supply_ptrace_register): Likewise.
7532
7533 2014-09-03 James Hogan <james.hogan@imgtec.com>
7534
7535 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7536 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7537
7538 2014-09-03 Gary Benson <gbenson@redhat.com>
7539
7540 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7541 ALL_DEBUG_ADDRESS_REGISTERS.
7542
7543 2014-09-02 Gary Benson <gbenson@redhat.com>
7544
7545 * i386-low.h: Renamed as...
7546 * x86-low.h: New file. All type, function and variable name
7547 prefixes changed from "i386_" to "x86_". All references updated.
7548 * i386-low.c: Renamed as...
7549 * x86-low.c: New file. All type, function and variable name
7550 prefixes changed from "i386_" to "x86_". All references updated.
7551
7552 2014-09-02 Gary Benson <gbenson@redhat.com>
7553
7554 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7555 (x86_linux_new_thread): Likewise.
7556
7557 2014-08-29 Gary Benson <gbenson@redhat.com>
7558
7559 * server.h (setjmp.h): Do not include.
7560 (toplevel): Do not declare.
7561 (common-exceptions.h): Include.
7562 (cleanups.h): Likewise.
7563 * server.c (toplevel): Do not define.
7564 (exit_code): New static global.
7565 (detach_or_kill_for_exit_cleanup): New function.
7566 (main): New function. Original main renamed to...
7567 (captured_main): New function.
7568 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7569
7570 2014-08-29 Gary Benson <gbenson@redhat.com>
7571
7572 * Makefile.in (SFILES): Add common/common-exceptions.c.
7573 (OBS): Add common-exceptions.o.
7574 (common-exceptions.o): New rule.
7575 * utils.c (prepare_to_throw_exception): New function.
7576
7577 2014-08-29 Gary Benson <gbenson@redhat.com>
7578
7579 * config.in: Regenerate.
7580 * configure: Likewise.
7581
7582 2014-08-29 Gary Benson <gbenson@redhat.com>
7583
7584 * Makefile.in (SFILES): Add common/cleanups.c.
7585 (OBS): cleanups.o.
7586 (cleanups.o): New rule.
7587
7588 2014-08-29 Gary Benson <gbenson@redhat.com>
7589
7590 * utils.c (internal_vwarning): New function.
7591
7592 2014-08-28 Gary Benson <gbenson@redhat.com>
7593
7594 * utils.h (fatal): Remove declaration.
7595 * utils.c (fatal): Remove function.
7596
7597 2014-08-28 Gary Benson <gbenson@redhat.com>
7598
7599 * tracepoint.c (gdb_agent_init): Replace fatal with
7600 perror_with_name.
7601 (initialize_tracepoint): Likewise.
7602
7603 2014-08-28 Gary Benson <gbenson@redhat.com>
7604
7605 * remote-utils.c (remote_prepare): Replace fatal with error.
7606
7607 2014-08-28 Gary Benson <gbenson@redhat.com>
7608
7609 * linux-low.c (linux_async): Replace fatal with warning.
7610 Tidy up and return.
7611 (linux_start_non_stop): Return -1 if linux_async failed.
7612
7613 2014-08-28 Gary Benson <gbenson@redhat.com>
7614
7615 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7616 gdb_assert.
7617 (i386_dr_low_get_addr): Remove vague comment.
7618 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7619 gdb_assert.
7620
7621 2014-08-28 Gary Benson <gbenson@redhat.com>
7622
7623 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7624 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7625 internal_error.
7626 (linux_resume_one_lwp): Likewise.
7627 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7628 gdb_assert.
7629 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7630 with internal_error.
7631 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7632 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7633 (find_register_by_name): Replace fatal with internal_error.
7634 (find_regno): Likewise.
7635 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7636 * thread-db.c (thread_db_create_event): Likewise.
7637 (thread_db_load_search): Likewise.
7638 (try_thread_db_load_1): Likewise.
7639 * tracepoint.c (get_jump_space_head): Replace fatal with
7640 internal_error.
7641 (claim_trampoline_space): Likewise.
7642 (have_fast_tracepoint_trampoline_buffer): Likewise.
7643 (cmd_qtstart): Likewise.
7644 (stop_tracing): Likewise.
7645 (fast_tracepoint_collecting): Likewise.
7646 (target_malloc): Likewise.
7647 (download_tracepoint): Likewise.
7648 (download_trace_state_variables): Replace check with gdb_assert.
7649 (upload_fast_traceframes): Replace fatal with internal_error.
7650
7651 2014-08-19 Tom Tromey <tromey@redhat.com>
7652 Gary Benson <gbenson@redhat.com>
7653
7654 * Makefile.in (SFILES): Add common/common-debug.c.
7655 (OBS): Add common-debug.o.
7656 (common-debug.o): New rule.
7657 * debug.h (debug_printf): Don't declare.
7658 * debug.c (debug_printf): Renamed and rewritten as...
7659 (debug_vprintf): New function.
7660
7661 2014-08-19 Gary Benson <gbenson@redhat.com>
7662
7663 * utils.h: Do not include print-utils.h.
7664
7665 2014-08-19 Tom Tromey <tromey@redhat.com>
7666 Gary Benson <gbenson@redhat.com>
7667
7668 * server.h: Add static assertion.
7669 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7670
7671 2014-08-19 Tom Tromey <tromey@redhat.com>
7672 Gary Benson <gbenson@redhat.com>
7673
7674 * Makefile.in (SFILES): Add common/errors.c.
7675 (OBS): Add errors.o.
7676 (IPA_OBS): Add errors-ipa.o.
7677 (errors.o): New rule.
7678 (errors-ipa.o): Likewise.
7679 * utils.h (perror_with_name, error, warning): Don't declare.
7680 * utils.c (warning): Renamed and rewritten as...
7681 (vwarning): New function.
7682 (error): Renamed and rewritten as...
7683 (verror): New function.
7684 (internal_error): Renamed and rewritten as...
7685 (internal_verror): New function.
7686
7687 2014-08-07 Gary Benson <gbenson@redhat.com>
7688
7689 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7690 * configure: Regenerate.
7691 * config.in: Likewise.
7692 * server.h: Do not include errno.h.
7693 * event-loop.c: Likewise.
7694 * hostio-errno.c: Likewise.
7695 * linux-low.c: Likewise.
7696 * remote-utils.c: Likewise.
7697 * spu-low.c: Likewise.
7698 * utils.c: Likewise.
7699 * gdbreplay.c: Unconditionally include errno.h.
7700
7701 2014-08-07 Gary Benson <gbenson@redhat.com>
7702
7703 * server.h: Do not include string.h.
7704 * event-loop.c: Likewise.
7705 * linux-low.c: Likewise.
7706 * regcache.c: Likewise.
7707 * remote-utils.c: Likewise.
7708 * spu-low.c: Likewise.
7709 * utils.c: Likewise.
7710
7711 2014-08-07 Gary Benson <gbenson@redhat.com>
7712
7713 * server.h: Do not include gdb_assert.h.
7714
7715 2014-08-07 Gary Benson <gbenson@redhat.com>
7716
7717 * server.h: Do not include common-utils.h.
7718
7719 2014-08-07 Gary Benson <gbenson@redhat.com>
7720
7721 * server.h: Do not include ptid.h.
7722 * notif.h: Likewise.
7723
7724 2014-08-07 Gary Benson <gbenson@redhat.com>
7725
7726 * server.h: Do not include gdb_locale.h.
7727
7728 2014-08-07 Gary Benson <gbenson@redhat.com>
7729
7730 * server.h: Do not include gdb/signals.h.
7731 * win32-low.c: Likewise.
7732
7733 2014-08-07 Gary Benson <gbenson@redhat.com>
7734
7735 * server.h: Do not include pathmax.h.
7736
7737 2014-08-07 Gary Benson <gbenson@redhat.com>
7738
7739 * server.h: Do not include libiberty.h.
7740 * linux-bfin-low.c: Likewise.
7741
7742 2014-08-07 Gary Benson <gbenson@redhat.com>
7743
7744 * server.h: Do not include ansidecl.h.
7745
7746 2014-08-07 Gary Benson <gbenson@redhat.com>
7747
7748 * linux-x86-low.c: Do not include stddef.h.
7749 * lynx-ppc-low.c: Likewise.
7750 * tracepoint.c: Likewise.
7751
7752 2014-08-07 Gary Benson <gbenson@redhat.com>
7753
7754 * server.h: Do not include stdarg.h.
7755 * nto-low.c: Likewise.
7756
7757 2014-08-07 Gary Benson <gbenson@redhat.com>
7758
7759 * server.h: Do not include stdlib.h.
7760 * inferiors.c: Likewise.
7761 * linux-low.c: Likewise.
7762 * regcache.c: Likewise.
7763 * spu-low.c: Likewise.
7764 * tracepoint.c: Likewise.
7765 * utils.c: Likewise.
7766
7767 2014-08-07 Gary Benson <gbenson@redhat.com>
7768
7769 * server.h: Do not include stdio.h.
7770 * linux-low.c: Likewise.
7771 * remote-utils.c: Likewise.
7772 * spu-low.c: Likewise.
7773 * utils.c: Likewise.
7774 * wincecompat.c: Likewise.
7775
7776 2014-08-06 Gary Benson <gbenson@redhat.com>
7777
7778 * regcache.c (init_register_cache): Move conditionals inside if.
7779
7780 2014-08-06 Gary Benson <gbenson@redhat.com>
7781
7782 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7783
7784 2014-07-31 Gary Benson <gbenson@redhat.com>
7785
7786 * ax.h: Do not include server.h.
7787 * gdbthread.h: Likewise.
7788 * lynx-low.h: Likewise.
7789 * notif.h: Likewise.
7790
7791 2014-07-30 Gary Benson <gbenson@redhat.com>
7792
7793 * server.h: Include common-defs.h.
7794 Do not include config.h or build-gnulib-gdbserver/config.h.
7795
7796 2014-07-30 Gary Benson <gbenson@redhat.com>
7797
7798 * hostio-errno.c: Move server.h to top of includes list.
7799 * inferiors.c: Likewise.
7800 * linux-x86-low.c: Likewise.
7801 * notif.c: Include server.h.
7802
7803 2014-07-24 Tom Tromey <tromey@redhat.com>
7804 Gary Benson <gbenson@redhat.com>
7805
7806 * server.h (CORE_ADDR): Now unsigned.
7807
7808 2014-07-16 Pedro Alves <palves@redhat.com>
7809
7810 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7811
7812 2014-07-15 Pedro Alves <palves@redhat.com>
7813
7814 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7815 copy.
7816
7817 2014-07-11 Pedro Alves <palves@redhat.com>
7818
7819 * linux-low.c (kill_wait_lwp): New function, based on
7820 kill_one_lwp_callback, but use my_waitpid directly.
7821 (kill_one_lwp_callback, linux_kill): Use it.
7822
7823 2014-06-23 Pedro Alves <palves@redhat.com>
7824
7825 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7826 before setting DR0..DR3.
7827
7828 2014-06-20 Gary Benson <gbenson@redhat.com>
7829
7830 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7831 * configure: Regenerated.
7832 * config.in: Likewise.
7833
7834 2014-06-20 Gary Benson <gbenson@redhat.com>
7835
7836 * Makefile.in (SFILES): Update locations for files moved
7837 from common to nat.
7838 (object file files): Reordered.
7839
7840 2014-06-20 Gary Benson <gbenson@redhat.com>
7841
7842 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7843 (i386_dr_low_set_addr): Likewise.
7844 (i386_dr_low_get_addr): Likewise.
7845 (i386_dr_low_can_set_control): Likewise.
7846 (i386_dr_low_set_control): Likewise.
7847 (i386_dr_low_get_control): Likewise.
7848 (i386_dr_low_get_status): Likewise.
7849 (i386_get_debug_register_length): Likewise.
7850 * linux-x86-low.c (i386_dr_low_set_addr):
7851 Changed signature. Made static.
7852 (i386_dr_low_get_addr): Likewise.
7853 (i386_dr_low_set_control): Likewise.
7854 (i386_dr_low_get_control): Likewise.
7855 (i386_dr_low_get_status): Likewise.
7856 (i386_dr_low): New global variable.
7857 * win32-i386-low.c (i386_dr_low_set_addr):
7858 Changed signature. Made static.
7859 (i386_dr_low_get_addr): Likewise.
7860 (i386_dr_low_set_control): Likewise.
7861 (i386_dr_low_get_control): Likewise.
7862 (i386_dr_low_get_status): Likewise.
7863 (i386_dr_low): New global variable.
7864
7865 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7866
7867 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7868 * Makefile.in (AR, AR_FLAGS): Define.
7869 * configure: Regenerate.
7870
7871 2014-06-19 Gary Benson <gbenson@redhat.com>
7872
7873 * Makefile.in (i386-dregs.o): New rule.
7874 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7875 * i386-low.c (target.h): Remove include.
7876 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7877 (DR_CONTROL_SHIFT): Likewise.
7878 (DR_CONTROL_SIZE): Likewise.
7879 (DR_RW_EXECUTE): Likewise.
7880 (DR_RW_WRITE): Likewise.
7881 (DR_RW_READ): Likewise.
7882 (DR_RW_IORW): Likewise.
7883 (DR_LEN_1): Likewise.
7884 (DR_LEN_2): Likewise.
7885 (DR_LEN_4): Likewise.
7886 (DR_LEN_8): Likewise.
7887 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7888 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7889 (DR_ENABLE_SIZE): Likewise.
7890 (DR_LOCAL_SLOWDOWN): Likewise.
7891 (DR_GLOBAL_SLOWDOWN): Likewise.
7892 (DR_CONTROL_RESERVED): Likewise.
7893 (I386_DR_CONTROL_MASK): Likewise.
7894 (I386_DR_VACANT): Likewise.
7895 (I386_DR_LOCAL_ENABLE): Likewise.
7896 (I386_DR_GLOBAL_ENABLE): Likewise.
7897 (I386_DR_DISABLE): Likewise.
7898 (I386_DR_SET_RW_LEN): Likewise.
7899 (I386_DR_GET_RW_LEN): Likewise.
7900 (I386_DR_WATCH_HIT): Likewise.
7901 (i386_wp_op_t): Likewise.
7902 (i386_show_dr): Likewise.
7903 (i386_length_and_rw_bits): Likewise.
7904 (i386_insert_aligned_watchpoint): Likewise.
7905 (i386_remove_aligned_watchpoint): Likewise.
7906 (i386_handle_nonaligned_watchpoint): Likewise.
7907 i386_update_inferior_debug_regs(): Likewise.
7908 (i386_dr_insert_watchpoint): Likewise.
7909 (i386_dr_remove_watchpoint): Likewise.
7910 (i386_dr_region_ok_for_watchpoint): Likewise.
7911 (i386_dr_stopped_data_address): Likewise.
7912 (i386_dr_stopped_by_watchpoint): Likewise.
7913
7914 2014-06-19 Gary Benson <gbenson@redhat.com>
7915
7916 * i386-low.c (i386_dr_show): Renamed to
7917 i386_show_dr and made static. All uses updated.
7918 (i386_dr_length_and_rw_bits): Renamed to
7919 i386_length_and_rw_bits and made static.
7920 All uses updated.
7921 (i386_dr_insert_aligned_watchpoint): Renamed to
7922 i386_insert_aligned_watchpoint and made static.
7923 All uses updated.
7924 (i386_dr_remove_aligned_watchpoint): Renamed to
7925 i386_remove_aligned_watchpoint and made static.
7926 All uses updated.
7927 (i386_dr_update_inferior_debug_regs): Renamed to
7928 i386_update_inferior_debug_regs and made static.
7929 All uses updated.
7930
7931 2014-06-18 Gary Benson <gbenson@redhat.com>
7932
7933 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7934 (i386_dr_low_can_set_control): Likewise.
7935 (i386_get_debug_register_length): Likewise.
7936 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7937 (i386_dr_low_can_set_control): Likewise.
7938 (i386_get_debug_register_length): Likewise.
7939
7940 2014-06-17 Gary Benson <gbenson@redhat.com>
7941
7942 * i386-low.h (i386-dregs.h): New include.
7943 (DR_FIRSTADDR): Now in i386-dregs.h.
7944 (DR_LASTADDR): Likewise.
7945 (DR_NADDR): Likewise.
7946 (DR_STATUS): Likewise.
7947 (DR_CONTROL): Likewise.
7948 (i386_debug_reg_state): Likewise.
7949 (i386_dr_insert_watchpoint): Likewise.
7950 (i386_dr_remove_watchpoint): Likewise.
7951 (i386_dr_region_ok_for_watchpoint): Likewise.
7952 (i386_dr_stopped_data_address): Likewise.
7953 (i386_dr_stopped_by_watchpoint): Likewise.
7954 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7955
7956 2014-06-18 Gary Benson <gbenson@redhat.com>
7957
7958 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7959 i386_dr_insert_watchpoint.
7960 (i386_low_remove_watchpoint): Renamed to
7961 i386_dr_remove_watchpoint.
7962 (i386_low_region_ok_for_watchpoint): Renamed to
7963 i386_dr_region_ok_for_watchpoint.
7964 (i386_low_stopped_data_address): Renamed to
7965 i386_dr_stopped_data_address.
7966 (i386_low_stopped_by_watchpoint): Renamed to
7967 i386_dr_stopped_by_watchpoint.
7968 * i386-low.c (i386_show_dr): Renamed to
7969 i386_dr_show and made nonstatic. All uses updated.
7970 (i386_length_and_rw_bits): Renamed to
7971 i386_dr_length_and_rw_bits and made nonstatic.
7972 All uses updated.
7973 (i386_insert_aligned_watchpoint): Renamed to
7974 i386_dr_insert_aligned_watchpoint and made nonstatic.
7975 All uses updated.
7976 (i386_remove_aligned_watchpoint): Renamed to
7977 i386_dr_remove_aligned_watchpoint and made nonstatic.
7978 All uses updated.
7979 (i386_update_inferior_debug_regs): Renamed to
7980 i386_dr_update_inferior_debug_regs and made nonstatic.
7981 All uses updated.
7982 (i386_low_insert_watchpoint): Renamed to
7983 i386_dr_insert_watchpoint. All uses updated.
7984 (i386_low_remove_watchpoint): Renamed to
7985 i386_dr_remove_watchpoint. All uses updated.
7986 (i386_low_region_ok_for_watchpoint): Renamed to
7987 i386_dr_region_ok_for_watchpoint. All uses updated.
7988 (i386_low_stopped_data_address): Renamed to
7989 i386_dr_stopped_data_address. All uses updated.
7990 (i386_low_stopped_by_watchpoint): Renamed to
7991 i386_dr_stopped_by_watchpoint. All uses updated.
7992
7993 2014-06-18 Gary Benson <gbenson@redhat.com>
7994
7995 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7996 (i386_dr_low_can_set_control): Likewise.
7997 (i386_insert_aligned_watchpoint): New check.
7998
7999 2014-06-18 Gary Benson <gbenson@redhat.com>
8000
8001 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
8002 Renamed to state.
8003
8004 2014-06-18 Gary Benson <gbenson@redhat.com>
8005
8006 * i386-low.c (i386_length_and_rw_bits): Use internal_error
8007 instead of fatal and error.
8008 (i386_handle_nonaligned_watchpoint): Likewise.
8009
8010 2014-06-18 Gary Benson <gbenson@redhat.com>
8011
8012 * i386-low.c (i386_get_debug_register_length): New macro.
8013 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
8014 (i386_show_dr): Use debug_printf instead of fprintf. Use
8015 phex to format values.
8016
8017 2014-06-18 Gary Benson <gbenson@redhat.com>
8018
8019 * i386-low.h: Comment changes.
8020 * i386-low.c: Likewise.
8021
8022 2014-06-18 Gary Benson <gbenson@redhat.com>
8023
8024 * i386-low.c: Whitespace changes.
8025
8026 2014-06-12 Tom Tromey <tromey@redhat.com>
8027
8028 * utils.c (freeargv): Remove.
8029
8030 2014-06-12 Tom Tromey <tromey@redhat.com>
8031
8032 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
8033 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
8034 (parse_debug_format_options): Likewise.
8035 (gdbserver_usage): Likewise.
8036 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
8037 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
8038 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
8039 against libiberty.
8040 ($(LIBGNU)): Depend on libiberty.
8041 (all-lib): Recurse into all subdirs.
8042 (install-only): Invoke "install" target in subdirs.
8043 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
8044 targets.
8045 * configure: Rebuild.
8046 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
8047 for vasprintf, vsnprintf, or gettimeofday.
8048 * configure.srv: Don't add safe-ctype.o or lbasename.o to
8049 srv_tgtobj.
8050
8051 2014-06-05 Joel Brobecker <brobecker@adacore.com>
8052
8053 * development.sh: Delete.
8054 * Makefile.in (config.status): Adjust dependency on development.sh.
8055 * configure.ac: Adjust development.sh source call.
8056 * configure: Regenerate.
8057
8058 2014-06-02 Pedro Alves <palves@redhat.com>
8059
8060 * ax.c (gdb_free_agent_expr): New function.
8061 * ax.h (gdb_free_agent_expr): New declaration.
8062 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
8063 list.
8064 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
8065 static.
8066 (clear_breakpoint_conditions_and_commands): New function.
8067 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
8068 (clear_breakpoint_conditions_and_commands): New declaration.
8069
8070 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8071
8072 * linux-aarch64-low.c (asm/ptrace.h): Include.
8073
8074 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8075
8076 Fix TLS access for -static -pthread.
8077 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
8078 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
8079 (thread_db_load_search, try_thread_db_load_1): Initialize it.
8080
8081 2014-05-20 Pedro Alves <palves@redhat.com>
8082
8083 * linux-aarch64-low.c (aarch64_insert_point)
8084 (aarch64_remove_point): No longer check whether the type is
8085 supported here. Adjust to new interface.
8086 (the_low_target): Install aarch64_supports_z_point_type as
8087 supports_z_point_type method.
8088 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
8089 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
8090 instead of a Z packet char. Adjust.
8091 (arm_supports_z_point_type): New function.
8092 (arm_insert_point, arm_remove_point): Adjust to new interface.
8093 (the_low_target): Install arm_supports_z_point_type.
8094 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
8095 (cris_insert_point, cris_remove_point): Adjust to new interface.
8096 Don't check whether the type is supported here.
8097 (the_low_target): Install cris_supports_z_point_type.
8098 * linux-low.c (linux_supports_z_point_type): New function.
8099 (linux_insert_point, linux_remove_point): Adjust to new interface.
8100 * linux-low.h (struct linux_target_ops) <insert_point,
8101 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
8102 raw_breakpoint pointer parameter.
8103 <supports_z_point_type>: New method.
8104 * linux-mips-low.c (mips_supports_z_point_type): New function.
8105 (mips_insert_point, mips_remove_point): Adjust to new interface.
8106 Use mips_supports_z_point_type.
8107 (the_low_target): Install mips_supports_z_point_type.
8108 * linux-ppc-low.c (the_low_target): Install NULL as
8109 supports_z_point_type method.
8110 * linux-s390-low.c (the_low_target): Install NULL as
8111 supports_z_point_type method.
8112 * linux-sparc-low.c (the_low_target): Install NULL as
8113 supports_z_point_type method.
8114 * linux-x86-low.c (x86_supports_z_point_type): New function.
8115 (x86_insert_point): Adjust to new insert_point interface. Use
8116 insert_memory_breakpoint. Adjust to new
8117 i386_low_insert_watchpoint interface.
8118 (x86_remove_point): Adjust to remove_point interface. Use
8119 remove_memory_breakpoint. Adjust to new
8120 i386_low_remove_watchpoint interface.
8121 (the_low_target): Install x86_supports_z_point_type.
8122 * lynx-low.c (lynx_target_ops): Install NULL as
8123 supports_z_point_type callback.
8124 * nto-low.c (nto_supports_z_point_type): New.
8125 (nto_insert_point, nto_remove_point): Adjust to new interface.
8126 (nto_target_ops): Install nto_supports_z_point_type.
8127 * mem-break.c: Adjust intro comment.
8128 (struct raw_breakpoint) <raw_type, size>: New fields.
8129 <inserted>: Update comment.
8130 <shlib_disabled>: Delete field.
8131 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8132 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8133 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8134 (raw_bkpt_type_to_target_hw_bp_type): New function.
8135 (find_enabled_raw_code_breakpoint_at): New function.
8136 (find_raw_breakpoint_at): New type and size parameters. Use them.
8137 (insert_memory_breakpoint): New function, based off
8138 set_raw_breakpoint_at.
8139 (remove_memory_breakpoint): New function.
8140 (set_raw_breakpoint_at): Reimplement.
8141 (set_breakpoint): New, based on set_breakpoint_at.
8142 (set_breakpoint_at): Reimplement.
8143 (delete_raw_breakpoint): Go through the_target->remove_point
8144 instead of assuming memory breakpoints.
8145 (find_gdb_breakpoint_at): Delete.
8146 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8147 (find_gdb_breakpoint): New function.
8148 (set_gdb_breakpoint_at): Delete.
8149 (z_type_supported): New function.
8150 (set_gdb_breakpoint_1): New function, loosely based off
8151 set_gdb_breakpoint_at.
8152 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8153 (delete_gdb_breakpoint_at): Delete.
8154 (delete_gdb_breakpoint_1): New function, loosely based off
8155 delete_gdb_breakpoint_at.
8156 (delete_gdb_breakpoint): New function.
8157 (clear_gdb_breakpoint_conditions): Rename to ...
8158 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8159 breakpoint.
8160 (add_condition_to_breakpoint): Make static.
8161 (add_breakpoint_condition): Take a struct breakpoint pointer
8162 instead of an address. Adjust.
8163 (gdb_condition_true_at_breakpoint): Rename to ...
8164 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8165 z_type parameter.
8166 (gdb_condition_true_at_breakpoint): Reimplement.
8167 (add_breakpoint_commands): Take a struct breakpoint pointer
8168 instead of an address. Adjust.
8169 (gdb_no_commands_at_breakpoint): Rename to ...
8170 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8171 parameter. Return true if no breakpoint was found. Change debug
8172 output.
8173 (gdb_no_commands_at_breakpoint): Reimplement.
8174 (run_breakpoint_commands): Rename to ...
8175 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8176 and change return type to boolean.
8177 (run_breakpoint_commands): New function.
8178 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8179 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8180 breakpoint. Go through the_target->remove_point instead of
8181 assuming memory breakpoint.
8182 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8183 software and hardware breakpoints.
8184 (reinsert_raw_breakpoint): Go through the_target->insert_point
8185 instead of assuming memory breakpoint.
8186 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8187 software and hardware breakpoints.
8188 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8189 Check both software and hardware breakpoints.
8190 (validate_inserted_breakpoint): Assert the breakpoint is a
8191 software breakpoint. Set the inserted flag to -1 instead of
8192 setting shlib_disabled.
8193 (delete_disabled_breakpoints): Adjust.
8194 (validate_breakpoints): Only validate software breakpoints.
8195 Adjust to inserted flag change.
8196 (check_mem_read, check_mem_write): Skip breakpoint types other
8197 than software breakpoints. Adjust to inserted flag change.
8198 * mem-break.h (enum raw_bkpt_type): New enum.
8199 (raw_breakpoint, struct process_info): Forward declare.
8200 (Z_packet_to_target_hw_bp_type): Delete declaration.
8201 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8202 (set_gdb_breakpoint, delete_gdb_breakpoint)
8203 (clear_breakpoint_conditions): New declarations.
8204 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8205 (breakpoint_inserted_here): Update comment.
8206 (add_breakpoint_condition, add_breakpoint_commands): Replace
8207 address parameter with a breakpoint pointer parameter.
8208 (gdb_breakpoint_here): Update comment.
8209 (delete_gdb_breakpoint_at): Delete.
8210 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8211 * server.c (process_point_options): Take a struct breakpoint
8212 pointer instead of an address. Adjust.
8213 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8214 delete_gdb_breakpoint.
8215 * spu-low.c (spu_target_ops): Install NULL as
8216 supports_z_point_type method.
8217 * target.h: Include mem-break.h.
8218 (struct target_ops) <prepare_to_access_memory>: Update comment.
8219 <supports_z_point_type>: New field.
8220 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8221 instead of a char. Also take a raw breakpoint pointer.
8222 * win32-arm-low.c (the_low_target): Install NULL as
8223 supports_z_point_type.
8224 * win32-i386-low.c (i386_supports_z_point_type): New function.
8225 (i386_insert_point, i386_remove_point): Adjust to new interface.
8226 (the_low_target): Install i386_supports_z_point_type.
8227 * win32-low.c (win32_supports_z_point_type): New function.
8228 (win32_insert_point, win32_remove_point): Adjust to new interface.
8229 (win32_target_ops): Install win32_supports_z_point_type.
8230 * win32-low.h (struct win32_target_ops):
8231 <supports_z_point_type>: New method.
8232 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8233 instead of a char. Also take a raw breakpoint pointer.
8234
8235 2014-05-20 Pedro Alves <palves@redhat.com>
8236
8237 * mem-break.h: Include break-common.h.
8238 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8239 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8240 (Z_packet_to_target_hw_bp_type): New declaration.
8241 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8242 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8243 (Z_PACKET_ACCESS_WP): Delete macros.
8244 (Z_packet_to_hw_type): Delete function.
8245 * i386-low.h: Don't include break-common.h here.
8246 (Z_packet_to_hw_type): Delete declaration.
8247 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8248 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8249 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8250 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8251 * linux-aarch64-low.c: Don't include break-common.h here.
8252 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8253 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8254 (Z_packet_to_target_hw_bp_type): Delete function.
8255 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8256 function.
8257 (mips_insert_point, mips_remove_point): Use
8258 Z_packet_to_target_hw_bp_type.
8259
8260 2014-05-20 Pedro Alves <palves@redhat.com>
8261
8262 * linux-aarch64-low.c: Include break-common.h.
8263 (enum target_point_type): Delete.
8264 (Z_packet_to_point_type): Rename to ...
8265 (Z_packet_to_target_hw_bp_type): ... this, and return a
8266 target_hw_bp_type instead.
8267 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8268 instead of an enum target_point_type.
8269 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8270 breakpoint type.
8271 (aarch64_dr_state_insert_one_point)
8272 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8273 (aarch64_handle_aligned_watchpoint)
8274 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8275 Take an enum target_hw_bp_type instead of an enum
8276 target_point_type.
8277 (aarch64_supports_z_point_type): New function.
8278 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8279 use Z_packet_to_target_hw_bp_type.
8280
8281 2014-05-20 Joel Brobecker <brobecker@adacore.com>
8282
8283 * configure.ac: Only use -Werror by default when DEVELOPMENT
8284 is true.
8285 * configure: Regenerate.
8286
8287 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8288
8289 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8290 * linux-x86-low.c (X86_64_USER_REGS): New.
8291 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8292
8293 2014-04-28 Yao Qi <yao@codesourcery.com>
8294
8295 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8296 name.
8297
8298 2014-04-25 Pedro Alves <palves@redhat.com>
8299
8300 PR server/16255
8301 * linux-low.c (linux_attach_fail_reason_string): New function.
8302 (linux_attach_lwp): Delete.
8303 (linux_attach_lwp_1): Rename to ...
8304 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8305 argument. Remove "initial" parameter. Return int instead of
8306 void. Don't error or warn here.
8307 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8308 failure to attach to the tgid. Call warning when failing to
8309 attach to an lwp.
8310 * linux-low.h (linux_attach_lwp): Take a ptid instead of a pid as
8311 argument. Remove "initial" parameter. Return int instead of
8312 void. Don't error or warn here.
8313 (linux_attach_fail_reason_string): New declaration.
8314 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8315 interface change. Use linux_attach_fail_reason_string.
8316
8317 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
8318 Walfred Tedeschi <walfred.tedeschi@intel.com>
8319
8320 * Makefile.in: Added rules to handle new files
8321 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8322 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8323 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8324 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8325 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8326 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8327 x32-avx512-linux.o.
8328 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8329 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8330 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8331 i386/x32-avx512.xml.
8332 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8333 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8334 i386/x32-avx512-linux.xml.
8335 * i387-fp.c (num_avx512_k_registers): New constant for number
8336 of K registers.
8337 (num_avx512_zmmh_low_registers): New constant for number of
8338 lower ZMM registers (0-15).
8339 (num_avx512_zmmh_high_registers): New constant for number of
8340 higher ZMM registers (16-31).
8341 (num_avx512_ymmh_registers): New contant for number of higher
8342 YMM registers (ymm16-31 added by avx521 on x86_64).
8343 (num_avx512_xmm_registers): New constant for number of higher
8344 XMM registers (xmm16-31 added by AVX512 on x86_64).
8345 (struct i387_xsave): Add space for AVX512 registers.
8346 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8347 Add code to handle AVX512 registers.
8348 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8349 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8350 prototypei from generated file.
8351 (tdesc_amd64_avx512_linux): Likewise.
8352 (init_registers_x32_avx512_linux): Likewise.
8353 (tdesc_x32_avx512_linux): Likewise.
8354 (init_registers_i386_avx512_linux): Likewise.
8355 (tdesc_i386_avx512_linux): Likewise.
8356 (x86_64_regmap): Add AVX512 registers.
8357 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8358 mask.
8359 (initialize_low_arch): Add code to initialize AVX512 registers.
8360
8361 2014-04-23 Pedro Alves <palves@redhat.com>
8362
8363 * mem-break.c (find_gdb_breakpoint_at): Make static.
8364 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8365
8366 2014-04-23 Pedro Alves <palves@redhat.com>
8367
8368 * i386-low.c: Don't include break-common.h here.
8369 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8370 prototype to take target_hw_bp_type as argument instead of a Z
8371 packet char.
8372 * i386-low.h: Include break-common.h here.
8373 (Z_packet_to_hw_type): Declare.
8374 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8375 prototypes.
8376 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8377 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8378 (x86_remove_point): Convert the packet number to a
8379 target_hw_bp_type before calling i386_low_remove_watchpoint.
8380 * win32-i386-low.c (i386_insert_point): Convert the packet number
8381 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8382 (i386_remove_point): Convert the packet number to a
8383 target_hw_bp_type before calling i386_low_remove_watchpoint.
8384
8385 2014-04-23 Pedro Alves <palves@redhat.com>
8386
8387 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8388
8389 2014-04-10 Pedro Alves <palves@redhat.com>
8390
8391 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8392 Check if the condition or command is NULL before checking if the
8393 breakpoint is known. On success, return true.
8394 * mem-break.h (add_breakpoint_condition): Document return.
8395 (add_breakpoint_commands): Add describing comment.
8396 * server.c (skip_to_semicolon): New function.
8397 (process_point_options): Use it.
8398
8399 2014-04-09 Pedro Alves <palves@redhat.com>
8400
8401 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8402 to lwpid_of.
8403
8404 2014-02-27 Pedro Alves <palves@redhat.com>
8405
8406 PR 12702
8407 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8408 macros.
8409 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8410 output.
8411 (last_thread_of_process_p): Take a PID argument instead of a
8412 thread pointer.
8413 (linux_wait_for_lwp): Delete.
8414 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8415 functions.
8416 (linux_low_filter_event): New function, party factored out from
8417 linux_wait_for_event.
8418 (linux_wait_for_event): Rename to ...
8419 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8420 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8421 sigsuspend. Check for zombie leaders.
8422 (linux_wait_for_event): Reimplement as wrapper around
8423 linux_wait_for_event_filtered.
8424 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8425 a normal or signal exit is seen, it's the whole process exiting.
8426 (wait_for_sigstop): No longer a for_each_inferior callback.
8427 Rewrite on top of linux_wait_for_event_filtered.
8428 (stop_all_lwps): Call wait_for_sigstop directly.
8429 * server.c (resume, handle_target_event): Handle
8430 TARGET_WAITKIND_NO_RESUMED.
8431
8432 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8433
8434 * win32-low.c (psapi_get_dll_name,
8435 * win32_CreateToolhelp32Snapshot): Delete.
8436 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8437 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8438 Delete.
8439 (handle_load_dll): Add function description.
8440 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8441
8442 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8443
8444 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8445 Add comment.
8446 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8447 base address when calling win32_add_one_solib.
8448 (handle_load_dll): Delete local variable load_addr.
8449 Remove 0x1000 offset applied to DLL base address when calling
8450 win32_add_one_solib.
8451 (handle_unload_dll): Add comment.
8452
8453 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8454
8455 * win32-low.c (win32_add_all_dlls): Renames
8456 win32_ensure_ntdll_loaded. Rewrite function documentation.
8457 Adjust implementation to always load all DLLs.
8458 Add 0x1000 offset to DLL base address when calling
8459 win32_add_one_solib.
8460 (child_initialization_done): New static global.
8461 (do_initial_child_stuff): Set child_initialization_done to
8462 zero during child initialization, and 1 after. Replace call
8463 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8464 Add comment.
8465 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8466 (handle_unload_dll): Add function documentation.
8467 (get_child_debug_event): Ignore load and unload DLL events
8468 during child initialization.
8469
8470 2014-02-20 Doug Evans <dje@google.com>
8471
8472 Remove global all_lwps.
8473 * inferiors.h (ptid_of): Move here from linux-low.h.
8474 (pid_of, lwpid_of): Ditto.
8475 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8476 parameter is a struct thread_info * now.
8477 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8478 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8479 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8480 directly.
8481 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8482 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8483 * linux-arm-low.c (update_registers_callback): Update, "entry"
8484 parameter is a struct thread_info * now.
8485 Fetch lwpid from current_inferior directly.
8486 (arm_insert_point): Pass &all_threads to find_inferior instead of
8487 &all_lwps.
8488 (arm_remove_point): Ditto.
8489 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8490 (arm_prepare_to_resume): Fetch pid from thread.
8491 (arm_read_description): Fetch lwpid from current_inferior directly.
8492 * linux-low.c (all_lwps): Delete.
8493 (delete_lwp): Delete call to remove_inferior.
8494 (handle_extended_wait): Fetch lwpid from thread.
8495 (add_lwp): Don't set lwp->entry.id. Remove call to
8496 add_inferior_to_list.
8497 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8498 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8499 (kill_one_lwp_callback): Ditto.
8500 (linux_kill): Don't dereference NULL pointer.
8501 Fetch ptid,lwpid from thread.
8502 (get_detach_signal): Fetch ptid from thread.
8503 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8504 Simplify call to regcache_invalidate_thread.
8505 (delete_lwp_callback): Update, "entry" parameter is a
8506 struct thread_info * now. Fetch pid from thread.
8507 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8508 (status_pending_p_callback): Update, "entry" parameter is a
8509 struct thread_info * now. Fetch ptid from thread.
8510 (find_lwp_pid): Update, "entry" parameter is a
8511 struct thread_info * now.
8512 (linux_wait_for_lwp): Fetch pid from thread.
8513 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8514 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8515 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8516 (dequeue_one_deferred_signal): Ditto.
8517 (cancel_breakpoint): Fetch ptid from current_inferior.
8518 (linux_wait_for_event): Pass &all_threads to find_inferior,
8519 not &all_lwps. Fetch ptid, lwpid from thread.
8520 (count_events_callback): Update, "entry" parameter is a
8521 struct thread_info * now.
8522 (select_singlestep_lwp_callback): Ditto.
8523 (select_event_lwp_callback): Ditto.
8524 (cancel_breakpoints_callback): Ditto.
8525 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8526 not &all_lwps.
8527 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8528 (unsuspend_one_lwp): Update, "entry" parameter is a
8529 struct thread_info * now.
8530 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8531 not &all_lwps.
8532 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8533 Fetch lwpid from thread, not lwp.
8534 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8535 Pass &all_threads to find_inferior, not &all_lwps.
8536 (send_sigstop): Fetch lwpid from thread, not lwp.
8537 (send_sigstop_callback): Update, "entry" parameter is a
8538 struct thread_info * now.
8539 (suspend_and_send_sigstop_callback): Ditto.
8540 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8541 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8542 struct thread_info * now.
8543 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8544 from thread, lwp.
8545 (lwp_running): Update, "entry" parameter is a
8546 struct thread_info * now.
8547 (stop_all_lwps): Fetch ptid from thread.
8548 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8549 (linux_resume_one_lwp): Fetch lwpid from thread.
8550 (linux_set_resume_request): Update, "entry" parameter is a
8551 struct thread_info * now. Fetch pid, lwpid from thread.
8552 (resume_status_pending_p): Update, "entry" parameter is a
8553 struct thread_info * now.
8554 (need_step_over_p): Ditto. Fetch lwpid from thread.
8555 (start_step_over): Fetch lwpid from thread.
8556 (linux_resume_one_thread): Update, "entry" parameter is a
8557 struct thread_info * now. Fetch lwpid from thread.
8558 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8559 (proceed_one_lwp): Update, "entry" parameter is a
8560 struct thread_info * now. Fetch lwpid from thread.
8561 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8562 struct thread_info * now.
8563 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8564 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8565 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8566 directly.
8567 (regsets_store_inferior_registers): Ditto.
8568 (fetch_register, store_register): Ditto.
8569 (linux_read_memory, linux_write_memory): Ditto.
8570 (linux_request_interrupt): Ditto.
8571 (linux_read_auxv): Ditto.
8572 (linux_xfer_siginfo): Ditto.
8573 (linux_qxfer_spu): Ditto.
8574 (linux_qxfer_libraries_svr4): Ditto.
8575 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8576 moved to inferiors.h.
8577 (get_lwp): Delete.
8578 (get_thread_lwp): Update.
8579 (struct lwp_info): Delete member "entry". Simplify comment for
8580 member "thread".
8581 (all_lwps): Delete.
8582 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8583 current_inferior directly.
8584 (update_watch_registers_callback): Update, "entry" parameter is a
8585 struct thread_info * now. Fetch pid from thread.
8586 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8587 (mips_insert_point): Fetch lwpid from current_inferior.
8588 Pass &all_threads to find_inferior, not &all_lwps.
8589 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8590 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8591 directly.
8592 (mips_stopped_data_address): Ditto.
8593 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8594 directly.
8595 * linux-tile-low.c (tile_arch_setup): Ditto.
8596 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8597 (update_debug_registers_callback): Update, "entry" parameter is a
8598 struct thread_info * now. Fetch pid from thread.
8599 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8600 Pass &all_threads to find_inferior, not &all_lwps.
8601 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8602 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8603 Pass &all_threads to find_inferior, not &all_lwps.
8604 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8605 (i386_dr_low_get_status): Ditto.
8606 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8607 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8608 (x86_linux_read_description): Ditto.
8609 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8610
8611 2014-02-20 Doug Evans <dje@google.com>
8612
8613 * inferiors.c (get_first_inferior): Fix buglet.
8614
8615 2014-02-19 Doug Evans <dje@google.com>
8616
8617 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8618 * inferiors.c (add_thread): Change result type to struct thread_info *.
8619 All callers updated.
8620 (add_lwp): Call add_thread here instead of in callers.
8621 All callers updated.
8622 * linux-low.h (get_lwp_thread): Rewrite.
8623 (struct lwp_info): New member "thread".
8624
8625 2014-02-19 Doug Evans <dje@google.com>
8626
8627 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8628 All callers updated.
8629
8630 2014-02-19 Doug Evans <dje@google.com>
8631
8632 * inferiors.c (add_thread): Fix whitespace.
8633
8634 2014-02-19 Doug Evans <dje@google.com>
8635
8636 * dll.c (clear_dlls): Replace accessing list implemention details
8637 with API function.
8638 * gdbthread.h (get_first_thread): Declare.
8639 * inferiors.c (for_each_inferior_with_data): New function.
8640 (get_first_thread): New function.
8641 (find_thread_ptid): Simplify.
8642 (get_first_inferior): New function.
8643 (clear_list): Delete.
8644 (one_inferior_p): New function.
8645 (clear_inferior_list): New function.
8646 (clear_inferiors): Update.
8647 * inferiors.h (for_each_inferior_with_data): Declare.
8648 (clear_inferior_list): Declare.
8649 (one_inferior_p): Declare.
8650 (get_first_inferior): Declare.
8651 * linux-low.c (linux_wait_for_event): Replace accessing list
8652 implemention details with API function.
8653 * server.c (target_running): Ditto.
8654 (accumulate_file_name_length): New function.
8655 (emit_dll_description): New function.
8656 (handle_qxfer_libraries): Replace accessing list implemention
8657 details with API function.
8658 (handle_qxfer_threads_worker): New function.
8659 (handle_qxfer_threads_proper): Replace accessing list implemention
8660 details with API function.
8661 (handle_query): Ditto.
8662 (visit_actioned_threads_callback_ftype): New typedef.
8663 (visit_actioned_threads_data): New struct.
8664 (visit_actioned_threads): Rewrite to be find_inferior callback.
8665 (resume): Call find_inferior.
8666 (handle_status): Replace accessing list implemention
8667 details with API function.
8668 (process_serial_event): Replace accessing list implemention details
8669 with API function.
8670 * target.c (set_desired_inferior): Replace accessing list implemention
8671 details with API function.
8672 * tracepoint.c (same_process_p): New function.
8673 (gdb_agent_about_to_close): Replace accessing list implemention
8674 details with API function.
8675 * win32-low.c (child_delete_thread): Replace accessing list
8676 implemention details with API function.
8677 (match_dll_by_basename): New function.
8678 (dll_is_loaded_by_basename): New function.
8679 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8680 details call to dll_is_loaded_by_basename.
8681
8682 2014-02-19 Doug Evans <dje@google.com>
8683
8684 * dll.h (struct dll_info): Add comment.
8685 * gdbthread.h (struct thread_info): Add comment.
8686 (current_ptid): Simplify.
8687 * inferiors.c (add_process): Update.
8688 (remove_process): Update.
8689 * inferiors.h (struct process_info): Rename member "head" to "entry".
8690 * linux-low.c (delete_lwp): Update.
8691 (add_lwp): Update.
8692 (last_thread_of_process_p): Update.
8693 (kill_one_lwp_callback, linux_kill): Update.
8694 (status_pending_p_callback): Update.
8695 (wait_for_sigstop): Update. Simplify read of ptid.
8696 (start_step_over): Update.
8697 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8698 (get_lwp_thread): Update.
8699 (struct lwp_info): Rename member "head" to "entry".
8700 * regcache.h (inferior_list_entry): Delete.
8701 * server.c (kill_inferior_callback): Update.
8702 (detach_or_kill_inferior_callback): Update.
8703 (print_started_pid): Update.
8704 (print_attached_pid): Update.
8705 (process_serial_event): Simplify read of ptid.
8706 * thread-db.c (thread_db_create_event): Update.
8707 (thread_db_get_tls_address): Update.
8708 * win32-low.c (current_inferior_ptid): Simplify.
8709
8710 2014-02-19 Tom Tromey <tromey@redhat.com>
8711
8712 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8713 argument.
8714 (target_supports_btrace): Update.
8715
8716 2014-02-14 Yao Qi <yao@codesourcery.com>
8717
8718 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8719 (rsp-low-ipa.o): New target.
8720
8721 2014-02-12 Tom Tromey <tromey@redhat.com>
8722
8723 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8724 convert_ascii_to_int.
8725 * regcache.c (registers_to_string): Likewise.
8726 * remote-utils.c (decode_M_packet): Likewise.
8727 * server.c (process_serial_event): Likewise.
8728
8729 2014-02-12 Tom Tromey <tromey@redhat.com>
8730
8731 * server.c (handle_query, handle_v_run): Use hex2bin, not
8732 unhexify.
8733 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8734
8735 2014-02-12 Tom Tromey <tromey@redhat.com>
8736
8737 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8738 convert_int_to_ascii.
8739 * regcache.c (registers_to_string, collect_register_as_string):
8740 Likewise.
8741 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8742 Likewise.
8743 * server.c (process_serial_event): Likewise.
8744 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8745 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8746
8747 2014-02-12 Tom Tromey <tromey@redhat.com>
8748
8749 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8750 bin2hex, not hexify.
8751 * tracepoint.c (cmd_qtstatus): Likewise.
8752
8753 2014-02-12 Tom Tromey <tromey@redhat.com>
8754
8755 * remote-utils.c (monitor_output): Pass explicit length to
8756 hexify.
8757
8758 2014-02-12 Tom Tromey <tromey@redhat.com>
8759
8760 * tracepoint.c: Include rsp-low.h.
8761 * server.c: Include rsp-low.h.
8762 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8763 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8764 declare.
8765 * remote-utils.c: Include rsp-low.h.
8766 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8767 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8768 (convert_int_to_ascii, convert_ascii_to_int): Move to
8769 common/rsp-low.c.
8770 * regcache.c: Include rsp-low.h.
8771 * ax.c: Include rsp-low.h.
8772 * Makefile.in (SFILES): Add common/rsp-low.c.
8773 (OBS): Add rsp-low.o.
8774 (rsp-low.o): New target.
8775
8776 2014-02-12 Tom Tromey <tromey@redhat.com>
8777
8778 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8779 Include print-utils.h.
8780 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8781 (plongest, thirty_two, phex_nz): Remove.
8782 * Makefile.in (SFILES): Add common/print-utils.c.
8783 (OBS): Add print-utils.o.
8784 (print-utils-ipa.o): New target.
8785 (print-utils.o): New target.
8786 (IPA_OBJS): Add print-utils-ipa.o.
8787
8788 2014-02-06 Tom Tromey <tromey@redhat.com>
8789
8790 * Makefile.in (SFILES): Fix indentation.
8791
8792 2014-02-05 Doug Evans <dje@google.com>
8793
8794 * linux-low.c (linux_wait_for_event): Improve comment.
8795 (linux_wait_1): Keep current_inferior in sync with event_child.
8796
8797 2014-01-22 Doug Evans <dje@google.com>
8798
8799 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8800
8801 2014-01-22 Doug Evans <dje@google.com>
8802
8803 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8804 * configure: Regenerate.
8805 * config.in: Regenerate.
8806 * Makefile.in (SFILES): Add debug.c.
8807 (OBS): Add debug.o.
8808 * debug.c: New file.
8809 * debug.h: New file.
8810 * linux-aarch64-low.c (*): Update all debugging printfs to use
8811 debug_printf instead of fprintf.
8812 * linux-arm-low.c (*): Ditto.
8813 * linux-cris-low.c (*): Ditto.
8814 * linux-crisv32-low.c (*): Ditto.
8815 * linux-m32r-low.c (*): Ditto.
8816 * linux-sparc-low.c (*): Ditto.
8817 * linux-x86.c (*): Ditto.
8818 * linux-low.c (*): Ditto.
8819 (linux_wait_1): Add calls to debug_enter, debug_exit.
8820 (linux_wait): Remove redundant debugging printf.
8821 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8822 (linux_resume, unstop_all_lwps): Ditto.
8823 * mem-break.c (*): Update all debugging printfs to use
8824 debug_printf instead of fprintf.
8825 * remote-utils.c (*): Ditto.
8826 * thread-db.c (*): Ditto.
8827 * server.c #include <ctype.h>, "gdb_vecs.h".
8828 (debug_threads): Moved to debug.c.
8829 (*): Update all debugging printfs to use debug_printf instead of
8830 fprintf.
8831 (start_inferior): Replace call to fflush with call to debug_flush.
8832 (monitor_show_help): Mention set debug-format.
8833 (parse_debug_format_options): New function.
8834 (handle_monitor_command): Handle "monitor set debug-format".
8835 (gdbserver_usage): Mention --debug-format.
8836 (main): Parse --debug-format.
8837 * server.h (debug_threads): Declaration moved to debug.h.
8838 #include "debug.h".
8839 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8840 trace_debug_1 that uses debug_printf.
8841 (tracepoint_look_up_symbols): Update all debugging printfs to use
8842 debug_printf instead of fprintf.
8843
8844 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8845
8846 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8847 sys/ptrace.h.
8848
8849 2014-01-17 Pedro Alves <palves@redhat.com>
8850
8851 PR build/16445
8852 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8853 defined after including gdb_proc_service.h.
8854
8855 2014-01-16 Doug Evans <dje@google.com>
8856
8857 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8858 (match_dll): Use it.
8859
8860 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8861
8862 * target.h (target_ops) <read_btrace>: Change parameters and
8863 return type to allow error reporting.
8864 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8865 trace reading errors on.
8866 * linux-low.c (linux_low_read_btrace): Pass trace reading
8867 errors on.
8868 (linux_low_disable_btrace): New.
8869
8870 2014-01-15 Doug Evans <dje@google.com>
8871
8872 * inferiors.c (thread_id_to_gdb_id): Delete.
8873 * inferiors.h (thread_id_to_gdb_id): Delete.
8874
8875 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8876
8877 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8878 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8879 versions.
8880
8881 2014-01-08 Pedro Alves <palves@redhat.com>
8882
8883 * server.c (handle_status): Don't discard previous queued stop
8884 replies or thread's pending status here.
8885 (main) <disconnection>: Do it here instead.
8886
8887 2014-01-08 Pedro Alves <palves@redhat.com>
8888
8889 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8890 * server.c (visit_actioned_threads, handle_pending_status): New
8891 function.
8892 (handle_v_cont): Factor out parts to ...
8893 (resume): ... this new function. If in all-stop, and a thread
8894 being resumed has a pending status, report it without actually
8895 resuming.
8896 (myresume): Adjust to use the new 'resume' function.
8897 (clear_pending_status_callback, set_pending_status_callback)
8898 (find_status_pending_thread_callback): New functions.
8899 (handle_status): Handle the case of multiple threads having
8900 interesting statuses to report. Report threads' real last signal
8901 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8902 with an interesting thread to report the status for, instead of
8903 always reporting the status of the first thread.
8904
8905 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8906
8907 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8908 * gdbreplay.c (gdbreplay_version): Likewise.
8909
8910 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8911
8912 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8913 iov.iov_len with the real length in use.
8914
8915 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8916
8917 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8918 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8919 for all targets that use win32-low.c.
8920 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8921 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8922
8923 2013-12-13 Pedro Alves <palves@redhat.com>
8924
8925 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8926 if equal to TARGET_WAITKIND_LOADED.
8927 * win32-low.c (cached_status): New static global.
8928 (win32_wait): Add declaration.
8929 (do_initial_child_stuff): Flush all initial pending debug events
8930 up to the initial breakpoint.
8931 (win32_wait): If CACHED_STATUS was set, return that instead
8932 of doing a real wait. Remove the code resuming the execution
8933 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8934 during the initial phase. Also remove the code changing
8935 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8936 TARGET_WAITKIND_STOPPED.
8937
8938 2013-12-11 Yao Qi <yao@codesourcery.com>
8939
8940 * notif.c (handle_notif_ack): Return 0 if no notification
8941 matches.
8942
8943 2013-11-20 Doug Evans <dje@google.com>
8944
8945 * linux-low.c (linux_set_resume_request): Fix comment.
8946
8947 2013-11-20 Doug Evans <dje@google.com>
8948
8949 * linux-low.c (resume_status_pending_p): Tweak comment.
8950
8951 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8952
8953 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8954 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8955 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8956 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8957 (srv_amd64_regobj): Add amd64-mpx.o.
8958 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8959 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8960 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8961 * i387-fp.c (num_pl_bnd_register) Added constant.
8962 (num_pl_bnd_cfg_registers) Added constant.
8963 (struct i387_xsave) Added reserved area and MPX fields.
8964 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8965 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8966 function.
8967 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8968 (init_registers_amd64_mpx_linux): Declare new function.
8969 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8970 (x86_64_regmap): Add MPX registers.
8971 (x86_linux_read_description): Add MPX case.
8972 (initialize_low_arch): Initialize MPX targets.
8973
8974 2013-11-18 Tom Tromey <tromey@redhat.com>
8975
8976 * configure: Rebuild.
8977 * configure.ac: Don't check for stdlib.h.
8978 * gdbreplay.c: Unconditionally include stdlib.h.
8979
8980 2013-11-18 Tom Tromey <tromey@redhat.com>
8981
8982 * config.in: Rebuild.
8983 * configure: Rebuild.
8984 * configure.ac: Don't use AC_HEADER_DIRENT.
8985
8986 2013-11-18 Tom Tromey <tromey@redhat.com>
8987
8988 * server.h: Don't check HAVE_STRING_H.
8989 * gdbreplay.c: Don't check HAVE_STRING_H.
8990 * configure: Rebuild.
8991
8992 2013-11-18 Tom Tromey <tromey@redhat.com>
8993
8994 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8995 LIBGNU.
8996
8997 2013-11-08 Tom Tromey <tromey@redhat.com>
8998
8999 * configure, config.in: Rebuild.
9000 * configure.ac: Remove unused configury.
9001
9002 2013-11-08 Tom Tromey <tromey@redhat.com>
9003
9004 * acinclude.m4: Include common.m4, codeset.m4.
9005 * configure, config.in: Rebuild.
9006 * configure.ac: Use GDB_AC_COMMON.
9007
9008 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
9009
9010 * linux-s390-low.c (HWCAP_S390_TE): New define.
9011 (s390_arch_setup): Consider the TE field in the HWCAP for
9012 determining 'have_regset_tdb'.
9013
9014 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
9015
9016 PR gdb/16014
9017 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
9018 call to sizeof.
9019
9020 2013-10-02 Pedro Alves <palves@redhat.com>
9021
9022 * server.c (process_serial_event): Don't output "GDBserver
9023 exiting" if GDB is connected through stdio.
9024 * target.c (mywait): Likewise, be silent if GDB is connected
9025 through stdio.
9026
9027 2013-10-01 Joel Brobecker <brobecker@adacore.com>
9028
9029 * lynx-low.c (lynx_add_threads_after_attach): New function.
9030 (lynx_attach): Remove call to add_thread. Add call to
9031 lynx_add_threads_after_attach instead.
9032
9033 2013-09-28 Mike Frysinger <vapier@gentoo.org>
9034
9035 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
9036 * config.in, configure: Regenerated.
9037
9038 2013-09-18 Yao Qi <yao@codesourcery.com>
9039
9040 PR server/15959
9041 * server.c (start_inferior): Clear 'resume_info'.
9042
9043 2013-09-16 Jiong Wang <jiwang@tilera.com>
9044
9045 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
9046 for each register.
9047
9048 2013-09-16 Jiong Wang <jiwang@tilera.com>
9049
9050 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
9051 linux-tile-low.o to srv_tgtobj.
9052
9053 2013-09-16 Will Newton <will.newton@linaro.org>
9054
9055 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
9056 out regs.
9057
9058 2013-09-06 Pedro Alves <palves@redhat.com>
9059
9060 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
9061 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
9062 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
9063 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
9064 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
9065 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
9066
9067 2013-09-06 Pedro Alves <palves@redhat.com>
9068
9069 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
9070 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
9071
9072 2013-09-06 Pedro Alves <palves@redhat.com>
9073
9074 * linux-amd64-ipa.c: Include tracepoint.h.
9075 * linux-i386-ipa.c: Include tracepoint.h.
9076
9077 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9078
9079 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
9080 (ps_get_thread_area): New function.
9081
9082 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9083
9084 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
9085 (initialize_low_arch): Call init_registers_crisv32 rather than
9086 init_register_crisv32.
9087
9088 2013-09-05 Pedro Alves <palves@redhat.com>
9089
9090 * server.h (handle_vFile, hostio_last_error_from_errno): Move
9091 to ...
9092 * hostio.h: ... this new file.
9093 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
9094 win32-low.c: Include hostio.h.
9095
9096 2013-09-05 Pedro Alves <palves@redhat.com>
9097
9098 * server.h (gdb_client_data, handler_func, callback_handler_func)
9099 (delete_file_handler, add_file_handler, append_callback_event)
9100 (delete_callback_event, start_event_loop, initialize_event_loop):
9101 Move to event-loop.h and include it.
9102 * event-loop.h: New file.
9103
9104 2013-09-05 Pedro Alves <palves@redhat.com>
9105
9106 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
9107 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
9108 (loaded_dll, unloaded_dll): Move to ...
9109 * dll.h: ... this new file.
9110 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
9111
9112 2013-09-05 Pedro Alves <palves@redhat.com>
9113
9114 * server.h (current_process, get_thread_process, all_processes)
9115 (add_inferior_to_list, for_each_inferior, current_inferior)
9116 (remove_inferior, add_process, remove_process, find_process_pid)
9117 (have_started_inferiors_p, have_attached_inferiors_p)
9118 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
9119 (clear_inferiors, find_inferior, find_inferior_id)
9120 (inferior_target_data, set_inferior_target_data)
9121 (inferior_regcache_data, set_inferior_regcache_data): Move to
9122 inferiors.h, and include it.
9123 * inferiors.h: New file.
9124
9125 2013-09-05 Pedro Alves <palves@redhat.com>
9126
9127 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9128 Move ...
9129 * ax.h: ... here.
9130
9131 2013-09-05 Pedro Alves <palves@redhat.com>
9132
9133 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9134 tracepoint.h.
9135 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9136 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9137 (handle_tracepoint_general_set, handle_tracepoint_query)
9138 (tracepoint_finished_step, tracepoint_was_hit)
9139 (release_while_stepping_state_list, current_traceframe)
9140 (in_readonly_region, traceframe_read_mem)
9141 (fetch_traceframe_registers, traceframe_read_sdata)
9142 (traceframe_read_info, struct fast_tpoint_collect_status)
9143 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9144 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9145 (supply_fast_tracepoint_registers)
9146 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9147 (ipa_tdesc, claim_trampoline_space)
9148 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9149 (agent_mem_read, agent_get_trace_state_variable_value)
9150 (agent_set_trace_state_variable_value, agent_tsv_read)
9151 (agent_mem_read_string, get_raw_reg_func_addr)
9152 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9153 * tracepoint.h: ... this new file.
9154
9155 2013-09-05 Pedro Alves <palves@redhat.com>
9156
9157 * server.h (perror_with_name, error, fatal, warning, paddress)
9158 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9159 include it.
9160 * utils.h: New file.
9161
9162 2013-09-05 Pedro Alves <palves@redhat.com>
9163
9164 * server.h (remote_debug, noack_mode, transport_is_reliable)
9165 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9166 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9167 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9168 (write_enn, initialize_async_io, enable_async_io)
9169 (disable_async_io, check_remote_input_interrupt_request)
9170 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9171 (dead_thread_notify, prepare_resume_reply)
9172 (decode_address_to_semicolon, decode_address, decode_m_packet)
9173 (decode_M_packet, decode_X_packet, decode_xfer_write)
9174 (decode_search_memory_packet, unhexify, hexify)
9175 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9176 (look_up_one_symbol, relocate_instruction)
9177 (monitor_output): Move to remote-utils.h, and include it.
9178 * remote-utils.h: New file.
9179
9180 2013-09-05 Pedro Alves <palves@redhat.com>
9181
9182 * server.h (_): Delete.
9183
9184 2013-09-02 Pedro Alves <palves@redhat.com>
9185
9186 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9187 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9188 allocated.
9189 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9190
9191 2013-09-02 Pierre Muller <muller@sourceware.org>
9192
9193 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9194 or WriteProcessMemory complete successfully and handle
9195 ERROR_PARTIAL_COPY error.
9196
9197 2013-09-02 Pedro Alves <palves@redhat.com>
9198
9199 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9200 error instead of EIO.
9201
9202 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9203
9204 PR server/15604
9205 * linux-low.c: Include filestuff.h.
9206 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9207 * lynx-low.c: Include filestuff.h.
9208 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9209 * server.c: Include filestuff.h.
9210 (main): Call notice_open_fds.
9211 * spu-low.c: Include filestuff.h.
9212 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9213
9214 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
9215
9216 * Makefile.in: Explain why ../target and ../nat are not
9217 listed as include file search paths.
9218 (linux-waitpid.o): New object file rule.
9219 * configure.srv (srv_native_linux_obj): New variable.
9220 Replace all occurrences of linux native object files with
9221 $srv_native_linux_obj.
9222 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9223 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9224 (linux_enable_event_reporting): Remove declaration.
9225 (my_waitpid): Moved to common/linux-waitpid.c.
9226 (linux_wait_for_event): Pass ptid when calling
9227 linux_enable_event_reporting.
9228 (linux_supports_tracefork_flag): Remove.
9229 (linux_enable_event_reporting): Likewise.
9230 (linux_tracefork_grandchild): Remove.
9231 (STACK_SIZE): Moved to common/linux-ptrace.c.
9232 (linux_tracefork_child): Remove.
9233 (linux_test_for_tracefork): Remove.
9234 (linux_look_up_symbols): Call linux_supports_traceclone.
9235 (initialize_low): Remove call to linux_test_for_tracefork.
9236 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9237 common/linux-ptrace.h.
9238 (PTRACE_TYPE_ARG4): Likewise.
9239 Include linux-ptrace.h.
9240
9241 2013-08-21 Pedro Alves <palves@redhat.com>
9242
9243 * config.in: Renegerate.
9244
9245 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
9246
9247 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9248 (SFILES): Remove $(srcdir)/common/target-common.c and
9249 add $(srcdir)/target/waitstatus.c.
9250 (OBS): Remove target-common.o and add waitstatus.o.
9251 (server_h): Remove $(srcdir)/../common/target-common.h and
9252 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9253 and $(srcdir)/../target/waitstatus.h.
9254 (target-common.o): Remove.
9255 (waitstatus.o): New target object file.
9256 * target.h: Do not include target-common.h and
9257 include target/resume.h, target/wait.h and
9258 target/waitstatus.h.
9259
9260 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
9261
9262 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9263 to PTRACE_TYPE_ARG3.
9264 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9265 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9266 PTRACE_TYPE_ARG4.
9267 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9268 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9269
9270 2013-07-27 Jie Zhang <jie@codesourcery.com>
9271 Daniel Jacobowitz <dan@codesourcery.com>
9272 Yao Qi <yao@codesourcery.com>
9273
9274 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9275 (mips-linux-watch.o): New rule.
9276 (mips_linux_watch_h): New variable.
9277 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9278 srv_tgtobj.
9279 * linux-mips-low.c: Include mips-linux-watch.h.
9280 (struct arch_process_info, struct arch_lwp_info): New.
9281 (update_watch_registers_callback): New function.
9282 (mips_linux_new_process, mips_linux_new_thread) New functions.
9283 (mips_linux_prepare_to_resume, mips_insert_point): New
9284 functions.
9285 (mips_remove_point, mips_stopped_by_watchpoint): New
9286 functions.
9287 (rsp_bp_type_to_target_hw_bp_type): New function.
9288 (mips_stopped_data_address): New function.
9289 (the_low_target): Add watchpoint support functions.
9290
9291 2013-07-27 Yao Qi <yao@codesourcery.com>
9292
9293 * i386-low.c: Include break-common.h.
9294 (enum target_hw_bp_type): Remove.
9295
9296 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
9297
9298 * Makefile.in (SFILES): /common/target-common.c.
9299 (OBS): Add target-common.o.
9300 (server_h): Add $(srcdir)/../common/target-common.h.
9301 (target-common.o): New target.
9302 * server.c (queue_stop_reply_callback): Free
9303 status string after use.
9304 * target.c (target_waitstatus_to_string): Remove.
9305 * target.h: Include target-common.h.
9306 (resume_kind): Likewise.
9307 (target_waitkind): Likewise.
9308 (target_waitstatus): Likewise.
9309 (TARGET_WNOHANG): Likewise.
9310
9311 2013-07-04 Yao Qi <yao@codesourcery.com>
9312
9313 * Makefile.in (host_alias): Use @host_noncanonical@.
9314 (target_alias): Use @target_noncanonical@.
9315 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9316 ACX_NONCANONICAL_HOST.
9317 * configure: Regenerated.
9318
9319 Revert:
9320 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9321
9322 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9323 * configure: Rebuild.
9324 * Makefile.in (version_host, version_target): Get from configure.
9325 (version.c): Use $(version_host) and $(version_target).
9326
9327 2013-07-03 Pedro Alves <palves@redhat.com>
9328
9329 * Makefile.in (config.status): Depend on development.sh.
9330 * acinclude.m4: Include libmcheck.m4.
9331 * configure: Regenerate.
9332
9333 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9334
9335 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9336 attribute inside the parentheses.
9337 (winapi_DebugSetProcessKillOnExit): Ditto.
9338 (winapi_DebugBreakProcess): Ditto.
9339 (winapi_GenerateConsoleCtrlEvent): Ditto.
9340
9341 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9342
9343 * notif.h (notif_event): Add a dummy member to avoid compiler
9344 errors.
9345
9346 2013-07-01 Pedro Alves <palves@redhat.com>
9347
9348 * hostio.c (HOSTIO_PATH_MAX): Define.
9349 (require_filename, handle_open, handle_unlink, handle_readlink):
9350 Use it.
9351
9352 2013-07-01 Pedro Alves <palves@redhat.com>
9353
9354 * server.h: Include "pathmax.h".
9355 * linux-low.c: Don't include sys/param.h.
9356 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9357 MAXPATHLEN.
9358 * win32-low.c: Don't include sys/param.h.
9359 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9360
9361 2013-07-01 Pedro Alves <palves@redhat.com>
9362
9363 * event-loop.c: Don't check HAVE_UNISTD_H before including
9364 <unistd.h>.
9365 * gdbreplay.c: Likewise.
9366 * remote-utils.c: Likewise.
9367 * server.c: Likewise.
9368 * configure.ac: Don't check for unistd.h.
9369 * configure: Regenerate.
9370
9371 2013-06-28 Tom Tromey <tromey@redhat.com>
9372
9373 * Makefile.in (version.c): Use version.in, not
9374 common/version.in.
9375
9376 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9377
9378 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9379 * configure: Rebuild.
9380 * Makefile.in (version_host, version_target): Get from configure.
9381 (version.c): Use $(version_host) and $(version_target).
9382
9383 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9384
9385 Fix trace-status to output user name without trailing colon.
9386 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9387
9388 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9389
9390 Fix trace-status to output proper start-time and stop-time.
9391 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9392 output start time and stop time in hex as gdb expects.
9393
9394 2013-06-26 Pedro Alves <pedro@codesourcery.com>
9395
9396 * tracepoint.c (build_traceframe_info_xml): Output trace state
9397 variables present in the trace buffer.
9398
9399 2013-06-24 Tom Tromey <tromey@redhat.com>
9400
9401 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9402 create-version.sh.
9403 (version.o): Remove.
9404 * gdbreplay.c: Include version.h.
9405 (version, host_name): Don't declare.
9406 * server.h: Include version.h.
9407 (version, host_name): Don't declare.
9408
9409 2013-06-12 Pedro Alves <palves@redhat.com>
9410
9411 * linux-x86-low.c (linux_is_elf64): Delete global.
9412 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9413 with local linux_pid_exe_is_elf_64_file use.
9414
9415 2013-06-11 Pedro Alves <palves@redhat.com>
9416
9417 * linux-low.c (regset_disabled, disable_regset): New functions.
9418 (regsets_fetch_inferior_registers)
9419 (regsets_store_inferior_registers): Use them.
9420 (initialize_regsets_info); Don't allocate the disabled_regsets
9421 array here.
9422 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9423 comment.
9424
9425 2013-06-11 Pedro Alves <palves@redhat.com>
9426
9427 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9428 xmalloc.
9429
9430 2013-06-11 Pedro Alves <palves@redhat.com>
9431
9432 * linux-x86-low.c (initialize_low_arch): Call
9433 init_registers_x32_avx_linux.
9434
9435 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9436
9437 Fix compatibility with Android Bionic.
9438 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9439 it is not empty.
9440
9441 2013-06-07 Pedro Alves <palves@redhat.com>
9442
9443 PR server/14823
9444 * Makefile.in (OBS): Add tdesc.o.
9445 (IPA_OBJS): Add tdesc-ipa.o.
9446 (tdesc-ipa.o): New rule.
9447 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9448 interface.
9449 * linux-low.c (new_inferior): Delete.
9450 (disabled_regsets, num_regsets): Delete.
9451 (linux_add_process): Adjust to set the new per-process
9452 new_inferior flag.
9453 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9454 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9455 was a stop. When calling arch_setup, switch the current inferior
9456 to the thread that got an event.
9457 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9458 (regsets_fetch_inferior_registers)
9459 (regsets_store_inferior_registers): New regsets_info parameter.
9460 Adjust to use it.
9461 (linux_register_in_regsets): New regs_info parameter. Adjust to
9462 use it.
9463 (register_addr, fetch_register, store_register): New usrregs_info
9464 parameter. Adjust to use it.
9465 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9466 parameter regs_info. Adjust to use it.
9467 (linux_fetch_registers): Get the current inferior's regs_info, and
9468 adjust to use it.
9469 (linux_store_registers): Ditto.
9470 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9471 (initialize_low): Don't initialize the target_regsets here. Call
9472 initialize_low_arch.
9473 * linux-low.h (target_regsets): Delete declaration.
9474 (struct regsets_info): New.
9475 (struct usrregs_info): New.
9476 (struct regs_info): New.
9477 (struct process_info_private) <new_inferior>: New field.
9478 (struct linux_target_ops): Delete the num_regs, regmap, and
9479 regset_bitmap fields. New field regs_info.
9480 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9481 * i387-fp.c (num_xmm_registers): Delete.
9482 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9483 calls to new interface.
9484 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9485 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9486 Infer the number of xmm registers from the regcache's target
9487 description.
9488 * i387-fp.h (num_xmm_registers): Delete.
9489 * inferiors.c (add_thread): Don't install the thread's regcache
9490 here.
9491 * proc-service.c (gregset_info): Fetch the current inferior's
9492 regs_info. Adjust to use it.
9493 * regcache.c: Include tdesc.h.
9494 (register_bytes, reg_defs, num_registers)
9495 (gdbserver_expedite_regs): Delete.
9496 (get_thread_regcache): If the thread doesn't have a regcache yet,
9497 create one, instead of aborting gdbserver.
9498 (regcache_invalidate_one): Rename to ...
9499 (regcache_invalidate_thread): ... this.
9500 (regcache_invalidate_one): New.
9501 (regcache_invalidate): Only invalidate registers of the current
9502 process.
9503 (init_register_cache): Add target_desc parameter, and use it.
9504 (new_register_cache): Ditto. Assert the target description has a
9505 non zero registers_size.
9506 (regcache_cpy): Add assertions. Adjust.
9507 (realloc_register_cache, set_register_cache): Delete.
9508 (registers_to_string, registers_from_string): Adjust.
9509 (find_register_by_name, find_regno, find_register_by_number)
9510 (register_cache_size): Add target_desc parameter, and use it.
9511 (free_register_cache_thread, free_register_cache_thread_one)
9512 (regcache_release, register_cache_size): New.
9513 (register_size): Add target_desc parameter, and use it.
9514 (register_data, supply_register, supply_register_zeroed)
9515 (supply_regblock, supply_register_by_name, collect_register)
9516 (collect_register_as_string, collect_register_by_name): Adjust.
9517 * regcache.h (struct target_desc): Forward declare.
9518 (struct regcache) <tdesc>: New field.
9519 (init_register_cache, new_register_cache): Add target_desc
9520 parameter.
9521 (regcache_invalidate_thread): Declare.
9522 (regcache_invalidate_one): Delete declaration.
9523 (regcache_release): Declare.
9524 (find_register_by_number, register_cache_size, register_size)
9525 (find_regno): Add target_desc parameter.
9526 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9527 declarations.
9528 * remote-utils.c: Include tdesc.h.
9529 (outreg, prepare_resume_reply): Adjust.
9530 * server.c: Include tdesc.h.
9531 (gdbserver_xmltarget): Delete declaration.
9532 (get_features_xml, process_serial_event): Adjust.
9533 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9534 declare.
9535 (struct process_info) <tdesc>: New field.
9536 (ipa_tdesc): Declare.
9537 * tdesc.c: New file.
9538 * tdesc.h: New file.
9539 * tracepoint.c: Include tdesc.h.
9540 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9541 (get_context_regcache): Adjust to pass ipa_tdesc down.
9542 (do_action_at_tracepoint): Adjust to get the register cache size
9543 from the context regcache's description.
9544 (traceframe_walk_blocks): Adjust to get the register cache size
9545 from the current trace frame's description.
9546 (traceframe_get_pc): Adjust to get current trace frame's
9547 description and pass it down.
9548 (gdb_collect): Adjust to get the register cache size from the
9549 IPA's description.
9550 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9551 (gdbserver_xmltarget): Delete.
9552 (initialize_low_tracepoint): Set the ipa's target description.
9553 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9554 (initialize_low_tracepoint): Set the ipa's target description.
9555 * linux-x86-low.c: Include tdesc.h.
9556 [__x86_64__] (is_64bit_tdesc): New.
9557 (ps_get_thread_area, x86_get_thread_area): Use it.
9558 (i386_cannot_store_register): Rename to ...
9559 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9560 (i386_cannot_fetch_register): Rename to ...
9561 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9562 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9563 to new interface.
9564 (target_regsets): Rename to ...
9565 (x86_regsets): ... this.
9566 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9567 interface.
9568 (x86_siginfo_fixup): Use is_64bit_tdesc.
9569 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9570 (tdesc_x32_avx_linux, tdesc_x32_linux)
9571 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9572 Declare.
9573 (x86_linux_update_xmltarget): Delete.
9574 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9575 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9576 (AMD64_LINUX_USER64_CS): New.
9577 (x86_linux_read_description): New, based on
9578 x86_linux_update_xmltarget.
9579 (same_process_callback): New.
9580 (x86_arch_setup_process_callback): New.
9581 (x86_linux_update_xmltarget): New.
9582 (x86_regsets_info): New.
9583 (amd64_linux_regs_info): New.
9584 (i386_linux_usrregs_info): New.
9585 (i386_linux_regs_info): New.
9586 (x86_linux_regs_info): New.
9587 (x86_arch_setup): Reimplement.
9588 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9589 (x86_emit_ops): Ditto.
9590 (the_low_target): Adjust. Install x86_linux_regs_info,
9591 x86_cannot_fetch_register, and x86_cannot_store_register.
9592 (initialize_low_arch): New.
9593 * linux-ia64-low.c (tdesc_ia64): Declare.
9594 (ia64_fetch_register): Adjust.
9595 (ia64_usrregs_info, regs_info): New globals.
9596 (ia64_regs_info): New function.
9597 (the_low_target): Adjust.
9598 (initialize_low_arch): New function.
9599 * linux-sparc-low.c (tdesc_sparc64): Declare.
9600 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9601 Adjust.
9602 (sparc_arch_setup): New function.
9603 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9604 (the_low_target): Adjust.
9605 (initialize_low_arch): New function.
9606 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9607 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9608 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9609 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9610 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9611 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9612 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9613 (tdesc_powerpc_isa205_vsx64l): Declare.
9614 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9615 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9616 (ppc_set_pc, ppc_get_hwcap): Adjust.
9617 (ppc_usrregs_info): Forward declare.
9618 (!__powerpc64__) ppc_regmap_adjusted: New global.
9619 (ppc_arch_setup): Adjust to the current process'es target
9620 description.
9621 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9622 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9623 (ppc_store_evrregset): Adjust.
9624 (target_regsets): Rename to ...
9625 (ppc_regsets): ... this, and make static.
9626 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9627 (ppc_regs_info): New function.
9628 (the_low_target): Adjust.
9629 (initialize_low_arch): New function.
9630 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9631 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9632 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9633 (tdesc_s390x_linux64v2): Declare.
9634 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9635 (s390_fill_gregset, s390_store_last_break): Adjust.
9636 (target_regsets): Rename to ...
9637 (s390_regsets): ... this, and make static.
9638 (s390_get_pc, s390_set_pc): Adjust.
9639 (s390_get_hwcap): New target_desc parameter, and use it.
9640 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9641 (s390_arch_setup): Adjust to set the current process'es target
9642 description. Don't adjust the regmap.
9643 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9644 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9645 (regs_info_3264): New globals.
9646 (s390_regs_info): New function.
9647 (the_low_target): Adjust.
9648 (initialize_low_arch): New function.
9649 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9650 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9651 [__mips64] (init_registers_mips_linux)
9652 (init_registers_mips_dsp_linux): Delete defines.
9653 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9654 (have_dsp): New global.
9655 (mips_read_description): New, based on mips_arch_setup.
9656 (mips_arch_setup): Reimplement.
9657 (get_usrregs_info): New function.
9658 (mips_cannot_fetch_register, mips_cannot_store_register)
9659 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9660 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9661 (target_regsets): Rename to ...
9662 (mips_regsets): ... this, and make static.
9663 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9664 (dsp_regs_info, regs_info): New globals.
9665 (mips_regs_info): New function.
9666 (the_low_target): Adjust.
9667 (initialize_low_arch): New function.
9668 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9669 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9670 Declare.
9671 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9672 (arm_read_description): New, with bits factored from
9673 arm_arch_setup.
9674 (arm_arch_setup): Reimplement.
9675 (target_regsets): Rename to ...
9676 (arm_regsets): ... this, and make static.
9677 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9678 (arm_regs_info): New function.
9679 (the_low_target): Adjust.
9680 (initialize_low_arch): New function.
9681 * linux-m68k-low.c (tdesc_m68k): Declare.
9682 (target_regsets): Rename to ...
9683 (m68k_regsets): ... this, and make static.
9684 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9685 (m68k_regs_info): New function.
9686 (m68k_arch_setup): New function.
9687 (the_low_target): Adjust.
9688 (initialize_low_arch): New function.
9689 * linux-sh-low.c (tdesc_sharch): Declare.
9690 (target_regsets): Rename to ...
9691 (sh_regsets): ... this, and make static.
9692 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9693 (sh_regs_info, sh_arch_setup): New functions.
9694 (the_low_target): Adjust.
9695 (initialize_low_arch): New function.
9696 * linux-bfin-low.c (tdesc_bfin): Declare.
9697 (bfin_arch_setup): New function.
9698 (bfin_usrregs_info, regs_info): New globals.
9699 (bfin_regs_info): New function.
9700 (the_low_target): Adjust.
9701 (initialize_low_arch): New function.
9702 * linux-cris-low.c (tdesc_cris): Declare.
9703 (cris_arch_setup): New function.
9704 (cris_usrregs_info, regs_info): New globals.
9705 (cris_regs_info): New function.
9706 (the_low_target): Adjust.
9707 (initialize_low_arch): New function.
9708 * linux-cris-low.c (tdesc_crisv32): Declare.
9709 (cris_arch_setup): New function.
9710 (cris_regsets_info, cris_usrregs_info, regs_info): New globals.
9711 (cris_regs_info): New function.
9712 (the_low_target): Adjust.
9713 (initialize_low_arch): New function.
9714 * linux-m32r-low.c (tdesc_m32r): Declare.
9715 (m32r_arch_setup): New function.
9716 (m32r_usrregs_info, regs_info): New globals.
9717 (m32r_regs_info): Adjust.
9718 (initialize_low_arch): New function.
9719 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9720 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9721 (tic6x_usrregs_info): Forward declare.
9722 (tic6x_read_description): New function, based on ...
9723 (tic6x_arch_setup): ... this. Reimplement.
9724 (target_regsets): Rename to ...
9725 (tic6x_regsets): ... this, and make static.
9726 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9727 (tic6x_regs_info): New function.
9728 (the_low_target): Adjust.
9729 (initialize_low_arch): New function.
9730 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9731 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9732 (target_regsets): Rename to ...
9733 (xtensa_regsets): ... this, and make static.
9734 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9735 globals.
9736 (xtensa_arch_setup, xtensa_regs_info): New functions.
9737 (the_low_target): Adjust.
9738 (initialize_low_arch): New function.
9739 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9740 (nios2_arch_setup): Set the current process'es tdesc.
9741 (target_regsets): Rename to ...
9742 (nios2_regsets): ... this.
9743 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9744 (nios2_regs_info): New function.
9745 (the_low_target): Adjust.
9746 (initialize_low_arch): New function.
9747 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9748 (aarch64_arch_setup): Set the current process'es tdesc.
9749 (target_regsets): Rename to ...
9750 (aarch64_regsets): ... this.
9751 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9752 (aarch64_regs_info): New function.
9753 (the_low_target): Adjust.
9754 (initialize_low_arch): New function.
9755 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9756 globals.
9757 (target_regsets): Rename to ...
9758 (tile_regsets): ... this.
9759 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9760 (tile_regs_info): New function.
9761 (tile_arch_setup): Set the current process'es tdesc.
9762 (the_low_target): Adjust.
9763 (initialize_low_arch): New function.
9764 * spu-low.c (tdesc_spu): Declare.
9765 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9766 * win32-arm-low.c (tdesc_arm): Declare.
9767 (arm_arch_setup): New function.
9768 (the_low_target): Install arm_arch_setup instead of
9769 init_registers_arm.
9770 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9771 (init_windows_x86): Rename to ...
9772 (i386_arch_setup): ... this. Set `win32_tdesc'.
9773 (the_low_target): Adjust.
9774 * win32-low.c (win32_tdesc): New global.
9775 (child_add_thread): Don't create the thread cache here.
9776 (do_initial_child_stuff): Set the new process'es tdesc.
9777 * win32-low.h (struct target_desc): Forward declare.
9778 (win32_tdesc): Declare.
9779 * lynx-i386-low.c (tdesc_i386): Declare global.
9780 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9781 * lynx-low.c (lynx_tdesc): New global.
9782 (lynx_add_process): Set the new process'es tdesc.
9783 * lynx-low.h (struct target_desc): Forward declare.
9784 (lynx_tdesc): Declare global.
9785 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9786 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9787 * nto-low.c (nto_tdesc): New global.
9788 (do_attach): Set the new process'es tdesc.
9789 * nto-low.h (struct target_desc): Forward declare.
9790 (nto_tdesc): Declare.
9791 * nto-x86-low.c (tdesc_i386): Declare.
9792 (nto_x86_arch_setup): Set `nto_tdesc'.
9793
9794 2013-06-04 Gary Benson <gbenson@redhat.com>
9795
9796 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9797 to qSupported response when appropriate.
9798 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9799 with nonzero-length annex.
9800 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9801 arguments supplied in annex.
9802
9803 2013-05-31 Doug Evans <dje@google.com>
9804
9805 PR server/15594
9806 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9807 64 bits in 64-cross-32 environment.
9808
9809 2013-05-28 Pedro Alves <palves@redhat.com>
9810
9811 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9812 (aarch64-without-fpu.c): Delete rule.
9813 * configure.srv (aarch64*-*-linux*): Remove references to
9814 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9815 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9816 declaration.
9817
9818 2013-05-24 Pedro Alves <palves@redhat.com>
9819
9820 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9821 instead of strchr/decode_address. Error if the range isn't split
9822 with a ','. Don't assume there's be a ':' in the action.
9823
9824 2013-05-23 Yao Qi <yao@codesourcery.com>
9825 Pedro Alves <palves@redhat.com>
9826
9827 * linux-low.c (lwp_in_step_range): New function.
9828 (linux_wait_1): If the thread was range stepping and stopped
9829 outside the stepping range, report the stop to GDB. Otherwise,
9830 continue stepping. Add range stepping debug output.
9831 (linux_set_resume_request): Copy the step range from the resume
9832 request to the lwp.
9833 (linux_supports_range_stepping): New.
9834 (linux_target_ops) <supports_range_stepping>: Set to
9835 linux_supports_range_stepping.
9836 * linux-low.h (struct linux_target_ops)
9837 <supports_range_stepping>: New field.
9838 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9839 * linux-x86-low.c (x86_supports_range_stepping): New.
9840 (the_low_target) <supports_range_stepping>: Set to
9841 x86_supports_range_stepping.
9842 * server.c (handle_v_cont): Handle 'r' action.
9843 (handle_v_requests): Append ";r" if the target supports range
9844 stepping.
9845 * target.h (struct thread_resume) <step_range_start,
9846 step_range_end>: New fields.
9847 (struct target_ops) <supports_range_stepping>:
9848 New field.
9849 (target_supports_range_stepping): New macro.
9850
9851 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9852
9853 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9854 confusion in comment.
9855
9856 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9857
9858 * lynx-low.c (struct process_info_private): New type.
9859 (lynx_add_process): New function.
9860 (lynx_create_inferior, lynx_attach): Replace calls to
9861 add_process by calls to lynx_add_process.
9862 (lynx_resume): If PTID is null, then try using
9863 current_process()->private->last_wait_event_ptid.
9864 Add comments.
9865 (lynx_clear_inferiors): Delete. The contents of that function
9866 has been inlined in lynx_mourn;
9867 (lynx_wait_1): Save the ptid in the process's private data.
9868 (lynx_mourn): Free the process' private data. Replace call
9869 to lynx_clear_inferiors by call to clear_inferiors.
9870
9871 2013-05-17 Yao Qi <yao@codesourcery.com>
9872
9873 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9874 the right place.
9875
9876 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9877
9878 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9879 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9880 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9881 PT_TEXT_END_ADDR guards. Update comments.
9882 (linux_target_op) <read_offsets>: Conditionally define to
9883 linux_read_offsets if the target is UCLIBC and if it defines
9884 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9885
9886 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9887 Andrew Jenner <andrew@codesourcery.com>
9888
9889 * Makefile.in (SFILES): Add linux-nios2-low.c.
9890 (clean): Add action to delete nios2-linux.c.
9891 (nios2-linux.c): New rule.
9892 * configure.srv: Add nios2*-*-linux*.
9893 * linux-nios2-low.c: New.
9894
9895 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9896
9897 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9898
9899 2013-04-25 Hui Zhu <hui@codesourcery.com>
9900
9901 PR gdb/15186
9902 * ax.c (ax_printf): Add fflush.
9903
9904 2013-04-22 Tom Tromey <tromey@redhat.com>
9905
9906 * Makefile.in (SFILES): Add filestuff.c.
9907 (OBS): Add filestuff.o.
9908 (filestuff.o): New target.
9909 * config.in, configure: Rebuild.
9910 * configure.ac: Check for fdwalk, pipe2.
9911
9912 2013-04-17 Pedro Alves <palves@redhat.com>
9913
9914 * configure.ac (USE_THREAD_DB): Delete variable.
9915 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9916 Don't AC_SUBST USE_THREAD_DB.
9917 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9918 * config.in, configure: Regenerate.
9919
9920 2013-04-16 Pedro Alves <palves@redhat.com>
9921
9922 * linux-low.h (struct lwp_info) <thread_known>: Move under
9923 the USE_THREAD_DB #ifdef.
9924
9925 2013-04-16 Pedro Alves <palves@redhat.com>
9926
9927 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9928 (linux-low.o): Delete rule.
9929 * linux-low.h: Always include "gdb_thread_db.h" instead of
9930 conditionally including thread_db.h.
9931 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9932 HAVE_THREAD_DB_H.
9933
9934 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9935
9936 * Makefile.in (install-only): Fix make install regression.
9937
9938 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9939
9940 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9941 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9942 installation.
9943 * gdbserver.1: Remove.
9944
9945 2013-03-22 Pedro Alves <palves@redhat.com>
9946
9947 * linux-low.c (handle_extended_wait): Don't call
9948 linux_enable_event_reporting.
9949
9950 2013-03-15 Tony Theodore <tonyt@logyst.com>
9951
9952 PR build/9098:
9953 * Makefile.in (SHELL): Use @SHELL@.
9954
9955 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9956
9957 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9958 compiler warning.
9959
9960 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9961
9962 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9963 Remove extraneous NULL element.
9964
9965 2013-03-13 Yao Qi <yao@codesourcery.com>
9966
9967 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9968 'V' block in trace frame.
9969
9970 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9971
9972 * target.h (struct target_ops): Add btrace ops.
9973 (target_supports_btrace): New macro.
9974 (target_enable_btrace): New macro.
9975 (target_disable_btrace): New macro.
9976 (target_read_btrace): New macro.
9977 * gdbthread.h (struct thread_info): Add btrace field.
9978 * server.c: Include btrace-common.h.
9979 (handle_btrace_general_set): New function.
9980 (handle_btrace_enable): New function.
9981 (handle_btrace_disable): New function.
9982 (handle_general_set): Call handle_btrace_general_set.
9983 (handle_qxfer_btrace): New function.
9984 (struct qxfer qxfer_packets[]): Add btrace entry.
9985 * inferiors.c (remove_thread): Disable btrace.
9986 * linux-low: Include linux-btrace.h.
9987 (linux_low_enable_btrace): New function.
9988 (linux_low_read_btrace): New function.
9989 (linux_target_ops): Add btrace ops.
9990 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9991 Add srv_linux_btrace=yes.
9992 (x86_64-*-linux*): Add linux-btrace.o.
9993 Add srv_linux_btrace=yes.
9994 * configure.ac: Define HAVE_LINUX_BTRACE.
9995 * config.in: Regenerated.
9996 * configure: Regenerated.
9997
9998 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9999
10000 * server.c (handle_qxfer): Preserve error message if -3 is
10001 returned.
10002 (qxfer): Document the -3 return value.
10003
10004 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
10005
10006 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
10007 (linux_btrace_h): New variable.
10008 (linux-btrace.o): New rule.
10009
10010 2013-03-08 Stan Shebs <stan@codesourcery.com>
10011 Hafiz Abid Qadeer <abidh@codesourcery.com>
10012
10013 * tracepoint.c (trace_buffer_size): New global.
10014 (DEFAULT_TRACE_BUFFER_SIZE): New define.
10015 (init_trace_buffer): Change to one-argument function. Allocate
10016 trace buffer memory.
10017 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
10018 handle QTBuffer:size packet.
10019 (cmd_bigqtbuffer_size): New function.
10020 (initialize_tracepoint): Call init_trace_buffer with
10021 DEFAULT_TRACE_BUFFER_SIZE.
10022 * server.c (handle_query): Add QTBuffer:size in the
10023 supported packets.
10024
10025 2013-03-07 Yao Qi <yao@codesourcery.com>
10026
10027 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
10028 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
10029 of -1.
10030 (cmd_qtsp): Adjust condition. Do post increment.
10031 Set cur_action and cur_step_action back to 0.
10032
10033 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
10034
10035 PR server/15236
10036 * linux-low.c (linux_write_memory): Return early success if LEN is
10037 zero.
10038
10039 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
10040
10041 * configure.srv: Add x86_64-*-cygwin* as target.
10042
10043 2013-02-28 Tom Tromey <tromey@redhat.com>
10044
10045 * configure.ac: Invoke AC_SYS_LARGEFILE.
10046 * configure, config.in: Rebuild.
10047
10048 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
10049
10050 * win32-low.c: Throughout, fix format strings and casts of
10051 printf-like functions to avoid type related warnings on all
10052 platforms.
10053 (get_child_debug_event): Print dwDebugEventCode as hex since
10054 that's how it's usually documented.
10055
10056 2013-02-28 Yao Qi <yao@codesourcery.com>
10057
10058 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
10059 pulongest.
10060
10061 2013-02-27 Jiong Wang <jiwang@tilera.com>
10062
10063 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
10064 (reg-tilegx32.c): New rule.
10065 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
10066 * linux-tile-low.c (tile_arch_setup): New function. Invoke
10067 different register info initializer according to elf class.
10068 (init_registers_tilgx32): New function. The tilegx32 register info
10069 initializer.
10070 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
10071 (tile_store_gregset): Likewise.
10072
10073 2013-02-27 Yao Qi <yao@codesourcery.com>
10074
10075 * server.c (process_point_options): Print debug message when
10076 debug_threads is true.
10077
10078 2013-02-26 Yao Qi <yao@codesourcery.com>
10079
10080 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
10081
10082 2013-02-19 Pedro Alves <palves@redhat.com>
10083 Kai Tietz <ktietz@redhat.com>
10084
10085 PR gdb/15161
10086
10087 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
10088 instead of strtoul to extract address from packet.
10089 (process_serial_event) <'z'>: Likewise.
10090
10091 2013-02-18 Yao Qi <yao@codesourcery.com>
10092
10093 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
10094
10095 2013-02-14 Pedro Alves <palves@redhat.com>
10096
10097 Plug memory leak.
10098
10099 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
10100 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
10101
10102 2013-02-14 Pedro Alves <palves@redhat.com>
10103
10104 * tracepoint.c (cmd_qtdpsrc): Use savestring.
10105
10106 2013-02-14 Pedro Alves <palves@redhat.com>
10107
10108 * tracepoint.c (save_string): Delete.
10109 (add_tracepoint_action): Use savestring instead of save_string.
10110
10111 2013-02-12 Pedro Alves <palves@redhat.com>
10112
10113 * linux-xtensa-low.c: Ditto.
10114 * xtensa-xtregs.c: Ditto.
10115
10116 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
10117
10118 * thread-db.c (thread_db_get_tls_address): NULL pointer check
10119 thread_db.
10120
10121 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10122
10123 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
10124 aarch64_num_wp_regs and aarch64_num_bp_regs to
10125 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10126
10127 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10128
10129 * linux-aarch64-low.c (ps_get_thread_area): Replace
10130 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10131
10132 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10133 Marcus Shawcroft <marcus.shawcroft@arm.com>
10134 Nigel Stephens <nigel.stephens@arm.com>
10135 Yufeng Zhang <yufeng.zhang@arm.com>
10136
10137 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10138 (aarch64.c, aarch64-without-fpu.c): New targets.
10139 * configure.srv (aarch64*-*-linux*): New.
10140 * linux-aarch64-low.c: New file.
10141
10142 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10143
10144 * linux-low.c (handle_extended_wait, linux_create_inferior)
10145 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10146 (dequeue_one_deferred_signal, linux_resume_one_thread)
10147 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10148 (linux_tracefork_grandchild, linux_test_for_tracefork)
10149 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10150 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10151 where the argument is 0.
10152
10153 2013-01-25 Yao Qi <yao@codesourcery.com>
10154
10155 * event-loop.c: Include "queue.h".
10156 (gdb_event_p): New typedef.
10157 (struct gdb_event) <next_event>: Remove.
10158 (event_queue): Change to QUEUE(gdb_event_p).
10159 (async_queue_event): Remove.
10160 (gdb_event_xfree): New.
10161 (initialize_event_loop): New.
10162 (process_event): Use API from QUEUE.
10163 (wait_for_event): Likewise.
10164 * server.c (main): Call initialize_event_loop.
10165 * server.h (initialize_event_loop): Declare.
10166
10167 2013-01-18 Yao Qi <yao@codesourcery.com>
10168
10169 * ax.h (struct eval_agent_expr_context): New.
10170 (gdb_eval_agent_expr): Update declaration.
10171 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10172 TFRAME. Add new argument CTX.
10173 * server.h (struct eval_agent_expr_context): Declare.
10174 (agent_mem_read, agent_tsv_read): Update declaration.
10175 (agent_mem_read_string): Likewise.
10176 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10177 (add_traceframe_block): Add new argument TPOINT.
10178 Increase TPOINT->traceframe_usage.
10179 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10180 eval_tracepoint_agent_expr.
10181 (condition_true_at_tracepoint): Likewise.
10182 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10183 (agent_mem_read_string, agent_tsv_read): Likewise.
10184
10185 2013-01-16 Yao Qi <yao@codesourcery.com>
10186
10187 * linux-low.c (linux_resume_one_lwp): Don't check
10188 'lwp->bp_reinsert != 0'.
10189
10190 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10191 Pedro Alves <palves@redhat.com>
10192
10193 * lynx-low.c (ptrace_request_to_str): Define a temporary
10194 macro and use it to simplify this function's implementation.
10195
10196 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10197
10198 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10199 sets errno.
10200
10201 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10202
10203 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10204
10205 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10206
10207 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10208
10209 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10210
10211 * lynx-low.c (lynx_resume): Use the resume_info parameter
10212 to determine the ptid for the lynx_ptrace call, unless
10213 it is equal to minus_one_ptid, in which case we use the
10214 ptid of the current_inferior.
10215 (lynx_wait_1): After having received a thread create/exit
10216 event, resume the inferior's execution using the signaling
10217 thread's ptid, rather than the old ptid.
10218
10219 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10220
10221 * lynx-low.c (lynx_resume): Delete variable ret.
10222
10223 2013-01-01 Joel Brobecker <brobecker@adacore.com>
10224
10225 * gdbreplay.c (gdbreplay_version): Update copyright year.
10226 * server.c (gdbserver_version): Likewise.
10227
10228 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10229
10230 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10231 new thread.
10232
10233 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10234
10235 * lynx-low.c (ptrace_request_to_str): Add handling for
10236 PTRACE_GETTRACESIG.
10237
10238 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10239
10240 * lynx-low.c (lynx_attach): Delete variable new_process.
10241
10242 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10243
10244 * lynx-low.c (lynx_create_inferior): Delete variable
10245 new_process.
10246
10247 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10248
10249 * lynx-low.c (ptrace_request_to_str): Do not handle
10250 PTRACE_GETTHREADLIST if this macro does not exist.
10251
10252 2012-12-15 Yao Qi <yao@codesourcery.com>
10253
10254 * Makefile.in (OBS): Add notif.o.
10255 * notif.c, notif.h: New.
10256 * server.c: Include "notif.h".
10257 (struct vstop_notif) <next>: Remove.
10258 <base>: New field.
10259 (queue_stop_reply): Update.
10260 (push_event, send_next_stop_reply): Remove.
10261 (discard_queued_stop_replies): Update.
10262 (notif_stop): New variable.
10263 (handle_v_stopped): Remove.
10264 (handle_v_requests): Don't call handle_v_stopped. Call
10265 handle_ack_notif instead.
10266 (queue_stop_reply_callback): Call notif_event_enque instead
10267 of queue_stop_reply.
10268 (handle_status): Don't call send_next_stop_reply, call
10269 notif_write_event instead.
10270 (kill_inferior_callback): Likewise.
10271 (detach_or_kill_inferior_callback): Likewise.
10272 (main): Call initialize_notif.
10273 (process_serial_event): Call QUEUE_is_empty.
10274 (handle_target_event): Call notif_push instead of push event.
10275 * server.h (push_event): Remove declaration.
10276
10277 2012-12-10 Tom Tromey <tromey@redhat.com>
10278
10279 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10280 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10281 macros.
10282 (.c.o): Rewrite.
10283 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10284 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10285 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10286 (amd64-linux-ipa.o, ax.o): Rewrite.
10287 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10288 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10289 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10290 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10291 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10292 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10293 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10294 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10295 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10296 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10297 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10298 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10299 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10300 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10301 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10302 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10303 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10304 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10305 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10306 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10307 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10308 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10309 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10310 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10311 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10312 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10313 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10314 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10315 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10316 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10317 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10318 (reg-tilegx.o): Remove.
10319 (all_object_files): New macro.
10320 Include .deps files.
10321 * aclocal.m4, configure: Rebuild.
10322 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10323 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10324 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10325
10326 2012-12-05 Tom Tromey <tromey@redhat.com>
10327
10328 PR gdb/14917:
10329 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10330
10331 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
10332
10333 * configure.ac: Check for linux/perf_event.h.
10334 * config.in: Regenerated.
10335 * configure: Regenerated.
10336
10337 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10338
10339 * hostio.c (handle_readlink): Decrease buffer size
10340 parameter passed to readlink by one byte.
10341
10342 2012-11-26 Yao Qi <yao@codesourcery.com>
10343
10344 * configure.ac (build_warnings): Append '-Wempty-body'.
10345 * configure: Regenerated.
10346 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10347 body.
10348
10349 2012-11-15 Pierre Muller <muller@sourceware.org>
10350
10351 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10352 * config.in: Regenerate.
10353 * configure: Regenerate.
10354 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10355 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10356 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10357 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10358 header.
10359 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10360 instead of <sys/wait.h> header.
10361 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10362
10363 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
10364
10365 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10366 (various make rules): Remove -DGDBSERVER
10367
10368 2012-11-09 Yao Qi <yao@codesourcery.com>
10369
10370 * spu-low.c (current_ptid): Move it to ..
10371 * gdbthread.h: ... here. New.
10372 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10373 * server.c (myresume, process_serial_event): Likewise.
10374 * thread-db.c (thread_db_find_new_threads): Likewise.
10375 * tracepoint.c (run_inferior_command): Likewise.
10376
10377 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
10378
10379 * server.c (handle_search_memory_1): Include access length in
10380 warning message.
10381
10382 2012-09-05 Michael Brandt <michael.brandt@axis.com>
10383
10384 * linux-crisv32-low.c: Fix compile errors.
10385
10386 2012-09-04 Yao Qi <yao@codesourcery.com>
10387
10388 * tracepoint.c (cmd_qtsv): Adjust debug message.
10389 Don't check CUR_TPOINT.
10390
10391 2012-08-28 Yao Qi <yao@codesourcery.com>
10392
10393 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10394 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10395 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10396 Remove declarations of xmalloc, xreallloc, xstrdup and
10397 freeargv.
10398 * Makefile.in (libiberty_h): New.
10399 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10400 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10401
10402 2012-08-23 Yao Qi <yao@codesourcery.com>
10403
10404 * server.h: Remove declaration of 'xsnprintf'.
10405
10406 2012-08-22 Keith Seitz <keiths@redhat.com>
10407
10408 * server.h: Include build-gnulib-gbserver/config.h.
10409 * gdbreplay.c: Likewise.
10410
10411 2012-08-08 Doug Evans <dje@google.com>
10412
10413 * Makefile.in (SFILES): Add gdb_vecs.c.
10414 (OBS): Add gdb_vecs.o.
10415 (gdb_vecs_h, host_defs_h): New variables.
10416 (thread-db.o): Add $(gdb_vecs_h) dependency.
10417 (gdb_vecs.o): New rule.
10418 * thread-db.c: #include "gdb_vecs.h".
10419 (thread_db_load_search): Use a vector to iterate over path elements.
10420 Handle text appearing after "$pdir".
10421
10422 * configure.ac: Add check for strstr.
10423 * config.in: Regenerate.
10424 * configure: Regenerate.
10425
10426 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10427
10428 * hostio.c (handle_pread): If pread fails, fall back to attempting
10429 lseek/read.
10430 (handle_pwrite): Likewise for pwrite.
10431
10432 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10433
10434 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10435 between unsupported TYPE and unimplementable ADDR/LEN combination.
10436 (arm_insert_point): Act on new return value.
10437
10438 2012-07-31 Pedro Alves <palves@redhat.com>
10439
10440 * server.c (process_point_options): Only skip tokens if we find
10441 one that is unrecognized. Don't treat 'X' specially while
10442 skipping unrecognized tokens.
10443
10444 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10445
10446 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10447 to 4-byte-align HW breakpoint addresses for Thumb.
10448
10449 2012-07-27 Yao Qi <yao@codesourcery.com>
10450
10451 PR remote/14161.
10452
10453 * server.h: Declare gdb_agent_about_to_close.
10454 * target.c (kill_inferior): Include "agent.h".
10455 New. Send command 'kill'.
10456 * target.h (kill_inferior): Removed macro.
10457 * tracepoint.c (gdb_agent_about_to_close): New.
10458 (gdb_agent_helper_thread): Handle command 'close'.
10459 Wait endlessly until the inferior stops.
10460 Install gdb_agent_remove_socket to atexit hook.
10461 (agent_socket_name): New static variable.
10462 (gdb_agent_socket_init): Replace local variable 'name' with
10463 'agent_socket_name'.
10464 (gdb_agent_remove_socket): New.
10465
10466 2012-07-27 Yao Qi <yao@codesourcery.com>
10467
10468 * server.c (process_point_options): Stop at 'X' when parsing.
10469
10470 2012-07-19 Michael Eager <eager@eagercon.com>
10471
10472 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10473 to hw_execute.
10474 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10475 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10476 hardware breakpoint.
10477
10478 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10479
10480 * gdbserver/linux-low.c (initialize_low): Call
10481 linux_ptrace_init_warnings.
10482
10483 2012-07-02 Doug Evans <dje@google.com>
10484
10485 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10486 pointer to int.
10487
10488 2012-07-02 Stan Shebs <stan@codesourcery.com>
10489
10490 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10491 (ax.o): Add it to build rule.
10492 (ax-ipa.o): Ditto.
10493 (OBS): Add format.o.
10494 (IPA_OBS): Add format.o.
10495 * server.c (handle_query): Claim support for breakpoint commands.
10496 (process_point_options): Add command case.
10497 (process_serial_event): Leave running if there are printfs in
10498 effect.
10499 * mem-break.h (any_persistent_commands): Declare.
10500 (add_breakpoint_commands): Declare.
10501 (gdb_no_commands_at_breakpoint): Declare.
10502 (run_breakpoint_commands): Declare.
10503 * mem-break.c (struct point_command_list): New struct.
10504 (struct breakpoint): New field command_list.
10505 (any_persistent_commands): New function.
10506 (add_commands_to_breakpoint): New function.
10507 (add_breakpoint_commands): New function.
10508 (gdb_no_commands_at_breakpoint): New function.
10509 (run_breakpoint_commands): New function.
10510 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10511 locally.
10512 * ax.c: Include format.h.
10513 (ax_printf): New function.
10514 (gdb_eval_agent_expr): Add printf opcode.
10515
10516 2012-06-13 Yao Qi <yao@codesourcery.com>
10517
10518 * server.c (start_inferior): Remove duplicated writes to fields
10519 'last_resume_kind' and 'last_status' of 'current_inferior'.
10520
10521 2012-06-12 Yao Qi <yao@codesourcery.com>
10522 Pedro Alves <palves@redhat.com>
10523
10524 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10525 comment.
10526 * server.c (handle_v_cont): Extend comment.
10527
10528 2012-06-11 Yao Qi <yao@codesourcery.com>
10529
10530 * linux-low.c (linux_attach): Add 'static'.
10531
10532 2012-06-06 Yao Qi <yao@codesourcery.com>
10533
10534 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10535
10536 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10537
10538 Fix gcc -flto compilation warning.
10539 * server.c (main): Make variable multi_mode and attach volatile.
10540
10541 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10542
10543 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10544 if the platform doesn't know about it.
10545
10546 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10547
10548 * Makefile.in (SFILES): Add linux-tile-low.c.
10549 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10550 * configure.srv: Handle tilegx-*-linux*.
10551 * linux-tile-low.c: New file.
10552
10553 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10554
10555 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10556
10557 2012-05-24 Pedro Alves <palves@redhat.com>
10558
10559 PR gdb/7205
10560
10561 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
10562
10563 2012-05-24 Pedro Alves <palves@redhat.com>
10564
10565 PR gdb/7205
10566
10567 Replace target_signal with gdb_signal throughout.
10568
10569 2012-05-22 Maciej W. Rozycki <macro@codesourcery.com>
10570
10571 * linux-low.c (linux_store_registers): Avoid the copying sequence
10572 when no data has been retrieved by ptrace.
10573
10574 2012-05-22 Will Deacon <will.deacon@arm.com>
10575
10576 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10577 Include asm/ptrace.h.
10578 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10579 already defined.
10580
10581 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10582
10583 * linux-low.c (linux_store_registers): Don't re-retrieve data
10584 with ptrace that has already been obtained from /proc. Always
10585 copy any data retrieved with ptrace to the buffer supplied.
10586
10587 2012-05-11 Yao Qi <yao@codesourcery.com>
10588 Pedro Alves <palves@redhat.com>
10589
10590 * linux-low.c (enum stopping_threads_kind): New.
10591 (stopping_threads): Change type to `enum stopping_threads_kind'.
10592 (handle_extended_wait): If stopping and suspending threads, leave
10593 the new_lwp suspended too.
10594 (linux_wait_for_event): Adjust.
10595 (stop_all_lwps): Set `stopping_threads' to
10596 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10597 whether we're suspending threads or just stopping them. Assert no
10598 recursion happens.
10599
10600 2012-04-29 Yao Qi <yao@codesourcery.com>
10601
10602 * server.h: Move some code to ...
10603 * gdbthread.h: ... here. New.
10604 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10605 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10606 (nto-low.o, win32-low.o): Likewise.
10607 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10608 * regcache.c, remote-utils.c, server.c: Likewise.
10609 * target.c, tracepoint.c, win32-low.c: Likewise.
10610
10611 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10612
10613 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10614 (PTRACE_ARG4_TYPE): Likewise.
10615 (PTRACE_XFER_TYPE): Likewise.
10616 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10617 ptrace to PTRACE_ARG3_TYPE.
10618 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10619 (PTRACE_ARG4_TYPE): Likewise.
10620 (PTRACE_XFER_TYPE): Likewise.
10621 (linux_detach_one_lwp): Cast fourth argument of
10622 ptrace to long then PTRACE_ARG4_TYPE.
10623 (regsets_fetch_inferior_registers): Cast third argument of
10624 ptrace to long then PTRACE_ARG3_TYPE.
10625 (regsets_store_inferior_registers): Likewise.
10626
10627 2012-04-20 Pedro Alves <palves@redhat.com>
10628
10629 * configure: Regenerate.
10630
10631 2012-04-19 Pedro Alves <palves@redhat.com>
10632
10633 * Makefile.in (GNULIB_BUILDDIR): New.
10634 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10635 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10636 (all, install-only, uninstall, clean-info, all-lib, clean): No
10637 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10638 (maintainer-clean realclean distclean): Use subdir_do.
10639 (subdir_do): New.
10640 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10641 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10642 * acinclude.m4: Include acx_configure_dir.m4.
10643 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10644 calls. Call AC_PROG_RANLIB. Configure gnulib using
10645 ACX_CONFIGURE_DIR.
10646 (GNULIB): New.
10647 (GNULIB_STDINT_H): Adjust.
10648 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10649 * gdbreplay.c: Include build-gnulib/config.h.
10650 * server.h: Likewise.
10651 * aclocal.m4: Regenerate.
10652 * config.in: Regenerate.
10653 * configure: Regenerate.
10654
10655 2012-04-19 Pedro Alves <palves@redhat.com>
10656
10657 * Makefile.in (LIBGNU, INCGNU): Adjust.
10658 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10659 (all, install-only, uninstall, clean-info, all-lib, clean)
10660 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10661 * configure.ac: Adjust AC_OUTPUT output.
10662 * aclocal.m4: Regenerate.
10663 * configure: Regenerate.
10664
10665 2012-04-19 Pedro Alves <palves@redhat.com>
10666
10667 * Makefile.in (generated_files): New.
10668 (server_h): Remove the explicit dependency on config.h, and depend
10669 on $generated_files.
10670
10671 2012-04-19 Pedro Alves <palves@redhat.com>
10672
10673 * Makefile.in (INCGNU): Add -Ignulib.
10674
10675 2012-04-19 Pedro Alves <palves@redhat.com>
10676
10677 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10678 (INCGNU): ... this, and spell out -I here.
10679 (GNULIB_LIB): Rename to ...
10680 (LIBGNU): ... this.
10681 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10682
10683 2012-04-19 Pedro Alves <palves@redhat.com>
10684
10685 * config.in: Regenerate.
10686
10687 2012-04-19 Pedro Alves <palves@redhat.com>
10688
10689 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10690 * server.h (memmem): Remove declaration.
10691 * config.in: Regenerate.
10692 * configure: Regenerate.
10693
10694 2012-04-19 Yao Qi <yao@codesourcery.com>
10695
10696 * Makefile.in (SFILES): Add common/vec.c.
10697 (OBS): Add vec.o.
10698 (vec.o): New rule.
10699
10700 2012-04-19 Yao Qi <yao@codesourcery.com>
10701
10702 * remote-utils.c (prepare_resume_reply): Replace with macro
10703 target_core_of_thread.
10704 * server.c (handle_qxfer_threads_proper): Likewise.
10705 * target.h (traget_core_of_thread): New macro.
10706
10707 2012-04-18 Pedro Alves <palves@redhat.com>
10708
10709 * aclocal.m4: Regenerate.
10710 * configure: Regenerate.
10711
10712 2012-04-16 Yao Qi <yao@codesourcery.com>
10713
10714 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10715 duplicated on address.
10716
10717 2012-04-16 Yao Qi <yao@codesourcery.com>
10718
10719 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10720 (struct tracepoint_action_ops) <send>: New field.
10721 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10722 (agent_expr_send, x_tracepoint_action_send): New.
10723 (l_tracepoint_action_send): New.
10724 (cmd_qtdp): Download and install tracepoint
10725 according to `use_agent'.
10726 (run_inferior_command): Add one more parameter `len'.
10727 Update callers.
10728 (tracepoint_send_agent): New.
10729 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10730
10731 2012-04-16 Yao Qi <yao@codesourcery.com>
10732
10733 * tracepoint.c (download_tracepoints): Moved to ...
10734 (cmd_qtstart): ... here.
10735
10736 2012-04-14 Yao Qi <yao@codesourcery.com>
10737
10738 * tracepoint.c: Include inttypes.h.
10739 (struct collect_memory_action): Use sized types.
10740 (struct tracepoint): Likewise.
10741 (cmd_qtdp, stop_tracing): Update print specifiers.
10742 (cmd_qtp, response_tracepoint): Likewise.
10743 (collect_data_at_tracepoint): Likewise.
10744 (collect_data_at_step): Likewise.
10745
10746 2012-04-14 Yao Qi <yao@codesourcery.com>
10747
10748 Import gnulib module inttypes.
10749 * aclocal.m4, config.in, configure: Regenerated.
10750
10751 2012-04-14 Yao Qi <yao@codesourcery.com>
10752
10753 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10754 Makefile and config.status at last.
10755
10756 2012-04-13 Yao Qi <yao@codesourcery.com>
10757
10758 * tracepoint.c: Include stdint.h unconditionally.
10759
10760 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10761
10762 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10763 on BFD_HAVE_SYS_PROCFS_TYPE.
10764 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10765 * configure: Regenerate.
10766 * config.in: Likewise.
10767
10768 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10769
10770 * Makefile.in (clean): Also remove x32.c x32-linux.c
10771 x32-avx.c x32-avx-linux.c.
10772 (x32.o): New target.
10773 (x32.c): Likewise.
10774 (x32-linux.o): Likewise.
10775 (x32-linux.c): Likewise.
10776 (x32-avx.o): Likewise.
10777 (x32-avx.c): Likewise.
10778 (x32-avx-linux.o): Likewise.
10779 (x32-avx-linux.c): Likewise.
10780
10781 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10782 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10783 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10784 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10785 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10786 i386/x32-avx-linux.xml.
10787
10788 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10789 (init_registers_x32_avx_linux): Likwise.
10790 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10791 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10792
10793 2012-04-13 Pedro Alves <palves@redhat.com>
10794
10795 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10796 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10797 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10798 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10799 the sub-make.
10800
10801 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10802
10803 * linux-x86-low.c (compat_x32_clock_t): New.
10804 (compat_x32_siginfo_t): Likewise.
10805 (compat_x32_siginfo_from_siginfo): Likewise.
10806 (siginfo_from_compat_x32_siginfo): Likewise.
10807 (linux_is_elf64): Likewise.
10808 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10809 and siginfo_from_compat_x32_siginfo for x32.
10810 (x86_arch_setup): Set linux_is_elf64.
10811
10812 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10813
10814 PR gdb/13969
10815 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10816 e_machine field.
10817 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10818 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10819 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10820 compatible with process.
10821
10822 2012-04-12 Yao Qi <yao@codesourcery.com>
10823
10824 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10825 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10826 (install-only, install-info, clean): Handle sub dir gnulib.
10827 (all-lib, am--refresh): New targets.
10828 (memmem.o): Remove target.
10829 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10830 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10831 (AC_REPLACE_FUNCS): Remove memmem.
10832 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10833 (AC_OUTPUT): Generate Makefile in gnulib/.
10834 * aclocal.m4, config.in, configure: Regenerated.
10835
10836 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10837
10838 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10839
10840 2012-04-05 Pedro Alves <palves@redhat.com>
10841
10842 -Werror=strict-aliasing
10843
10844 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10845 pointer.
10846
10847 2012-04-04 Pedro Alves <palves@redhat.com>
10848
10849 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10850 (sparc_store_gregset_from_stack, sparc_store_gregset)
10851 (sparc_breakpoint_at): Fix formatting.
10852
10853 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10854
10855 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10856 are available.
10857 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10858 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10859 * config.in: Regenerate.
10860 * configure: Likewise.
10861
10862 2012-03-29 Pedro Alves <palves@redhat.com>
10863
10864 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10865 Correct ptrace arguments.
10866
10867 2012-03-28 Pedro Alves <palves@redhat.com>
10868
10869 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10870 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10871 (IA64_FR1_REGNUM): New defines.
10872 (ia64_fetch_register): New.
10873 (the_low_target): Install it.
10874 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10875 field.
10876 * linux-low.c (linux_fetch_registers): Try the
10877 the_low_target.fetch_register hook first.
10878
10879 * linux-arm-low.c (the_low_target): Adjust.
10880 * linux-bfin-low.c (the_low_target): Adjust.
10881 * linux-cris-low.c (the_low_target): Adjust.
10882 * linux-crisv32-low.c (the_low_target): Adjust.
10883 * linux-m32r-low.c (the_low_target): Adjust.
10884 * linux-m68k-low.c (the_low_target): Adjust.
10885 * linux-mips-low.c (the_low_target): Adjust.
10886 * linux-ppc-low.c (the_low_target): Adjust.
10887 * linux-s390-low.c (the_low_target): Adjust.
10888 * linux-sh-low.c (the_low_target): Adjust.
10889 * linux-sparc-low.c (the_low_target): Adjust.
10890 * linux-tic6x-low.c (the_low_target): Adjust.
10891 * linux-x86-low.c (the_low_target): Adjust.
10892 * linux-xtensa-low.c (the_low_target): Adjust.
10893
10894 2012-03-26 Pedro Alves <palves@redhat.com>
10895
10896 * server.c (handle_qxfer_libraries): Don't bail early if
10897 the_target->qxfer_libraries_svr4 is not NULL.
10898
10899 2012-03-26 Pedro Alves <palves@redhat.com>
10900
10901 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10902
10903 2012-03-23 Pedro Alves <palves@redhat.com>
10904
10905 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10906 "library-list-svr4" element's start tag when the the DSO list is
10907 empty.
10908
10909 2012-03-23 Pedro Alves <palves@redhat.com>
10910
10911 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10912 a variable whose type size is the same as the inferior's pointer
10913 size.
10914
10915 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10916
10917 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10918 struct siginfo.
10919 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10920 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10921 * linux-low.h: Include <signal.h>.
10922 (struct siginfo): Remove forward declaration.
10923 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10924 struct siginfo.
10925
10926 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10927
10928 * .gitignore: Ignore more files.
10929
10930 2012-03-19 Pedro Alves <palves@redhat.com>
10931 Jan Kratochvil <jan.kratochvil@redhat.com>
10932
10933 * server.c (cont_thread, general_thread): Add describing comments.
10934 (start_inferior): Clear `cont_thread'.
10935 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10936 of a process.
10937
10938 2012-03-15 Yao Qi <yao@codesourcery.com>
10939
10940 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10941 handling to ...
10942 (cmd_qtdp): ... here.
10943
10944 2012-03-15 Yao Qi <yao@codesourcery.com>
10945
10946 * tracepoint.c (struct tracepoint_action_ops): New.
10947 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10948 (m_tracepoint_action_download): New.
10949 (r_tracepoint_action_download): New.
10950 (x_tracepoint_action_download): New.
10951 (l_tracepoint_action_download): New.
10952 (add_tracepoint_action): Install `action->ops' according type.
10953 (download_tracepoint_1): Move code `download' function pointer
10954 of various tracepoint_action_ops.
10955
10956 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10957
10958 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10959 linux_ptrace_attach_warnings.
10960
10961 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10962
10963 * Makefile.in (linux-ptrace.o): New.
10964 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10965 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10966 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10967 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10968 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10969 of these targets.
10970 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10971
10972 2012-03-08 Yao Qi <yao@codesourcery.com>
10973 Pedro Alves <palves@redhat.com>
10974
10975 Fix PR server/13392.
10976 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10977 offset of JMP insn.
10978 * tracepoint.c (remove_tracepoint): New.
10979 (cmd_qtdp): Call remove_tracepoint when failed to install.
10980
10981 2012-03-07 Pedro Alves <palves@redhat.com>
10982
10983 * linux-low.c (get_detach_signal): New.
10984 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10985 Pass on pending signals to PTRACE_DETACH. Check the result of the
10986 ptrace call.
10987 * server.c (program_signals, program_signals_p): New.
10988 (handle_general_set): Handle QProgramSignals.
10989 * server.h (program_signals, program_signals_p): Declare.
10990
10991 2012-03-05 Pedro Alves <palves@redhat.com>
10992 Jan Kratochvil <jan.kratochvil@redhat.com>
10993
10994 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10995 New comment why.
10996
10997 2012-03-03 Yao Qi <yao@codesourcery.com>
10998
10999 * tracepoint.c (tracepoint_look_up_symbols): Update call to
11000 agent_look_up_symbols.
11001
11002 2012-03-03 Yao Qi <yao@codesourcery.com>
11003
11004 * Makefile.in (linux-low.o): Keep dependence on agent.h.
11005 (linux-x86-low.o): Likewise.
11006 * server.h: Remove in_process_agent_loaded.
11007 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
11008 common/agent.c.
11009 Update callers.
11010
11011 2012-03-03 Yao Qi <yao@codesourcery.com>
11012
11013 * tracepoint.c (gdb_agent_capability): New global.
11014 (in_process_agent_loaded_ust): Renamed to
11015 `in_process_agent_supports_ust'.
11016 Update callers.
11017 (in_process_agent_supports_ust): Call agent_capability_check.
11018 (clear_installed_tracepoints): Assert that agent supports
11019 agent.
11020
11021 2012-03-03 Yao Qi <yao@codesourcery.com>
11022
11023 * linux-low.c (linux_supports_agent): New.
11024 (linux_target_ops): Initialize field `supports_agent' with
11025 linux_supports_agent.
11026 * target.h (struct target_ops) <supports_agent>: New.
11027 (target_supports_agent): New macro.
11028 * server.c (handle_general_set): Handle packet 'QAgent'.
11029 (handle_query): Send `QAgent+'.
11030 * Makefile.in (server.o): Depends on agent.h.
11031
11032 2012-03-03 Yao Qi <yao@codesourcery.com>
11033
11034 * Makefile.in (OBS): Add agent.o.
11035 Add new rule for agent.o.
11036 Track dependence of tracepoint.c on agent.h.
11037 * tracepoint.c (run_inferior_command_1):
11038 (run_inferior_command): Call agent_run_command.
11039 (gdb_ust_connect_sync_socket): Deleted. Move it to
11040 common/agent.c.
11041 (resume_thread, stop_thread): Likewise.
11042 (gdb_ust_socket_init): Renamed to ...
11043 (gdb_agent_socket_init): ... New.
11044 (gdb_ust_thread): Renamed to ...
11045 (gdb_agent_helper_thread): ... New.
11046 (gdb_ust_init): Move some code to ...
11047 (gdb_agent_init): ... here. New.
11048 [HAVE_UST]: Call gdb_ust_init.
11049 (initialize_tracepoint_ftlib): Call gdb_agent_init.
11050 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
11051 * config.in, configure: Regenerated.
11052
11053 2012-03-02 Pedro Alves <palves@redhat.com>
11054
11055 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
11056 * linux-low.c (struct simple_pid_list): New.
11057 (stopped_pids): New a struct simple_pid_list pointer.
11058 (add_to_pid_list, pull_pid_from_list): New.
11059 (handle_extended_wait): Don't assume the first signal new children
11060 report is SIGSTOP. Adjust call to pull_pid_from_list.
11061 (linux_wait_for_lwp): Adjust.
11062
11063 2012-03-02 Yao Qi <yao@codesourcery.com>
11064
11065 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
11066 debug log.
11067
11068 2012-03-02 Yao Qi <yao@codesourcery.com>
11069
11070 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
11071 `stop_pc' and `tpoint'. Update caller.
11072
11073 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
11074
11075 * linux-low.h (linux_target_ops): Add regset_bitmap member.
11076 * linux-low.c (use_linux_regsets): New macro.
11077 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
11078 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
11079 (linux_register_in_regsets): New function.
11080 (usr_fetch_inferior_registers): Skip registers covered by
11081 regsets.
11082 (usr_store_inferior_registers): Likewise.
11083 (usr_fetch_inferior_registers): New macro.
11084 (usr_store_inferior_registers): Likewise.
11085 (linux_fetch_registers): Handle mixed regset/non-regset targets.
11086 (linux_store_registers): Likewise.
11087 * linux-mips-low.c (init_registers_mips_dsp_linux): New
11088 prototype.
11089 (init_registers_mips64_dsp_linux): Likewise.
11090 (init_registers_mips_linux): New macro.
11091 (init_registers_mips_dsp_linux): Likewise.
11092 (mips_dsp_num_regs): Likewise.
11093 (DSP_BASE, DSP_CONTROL): New fallback macros.
11094 (mips_base_regs): New macro.
11095 (mips_regmap): Use it. Fix the size.
11096 (mips_dsp_regmap): New variable.
11097 (mips_dsp_regset_bitmap): Likewise.
11098 (mips_arch_setup): New function.
11099 (mips_cannot_fetch_register): Use the_low_target.regmap rather
11100 than mips_regmap.
11101 (mips_cannot_store_register): Likewise.
11102 (the_low_target): Update .arch_setup, .num_regs and .regmap
11103 initializers. Add .regset_bitmap initializer.
11104 * linux-arm-low.c (the_low_target): Add .regset_bitmap
11105 initializer.
11106 * linux-bfin-low.c (the_low_target): Likewise.
11107 * linux-cris-low.c (the_low_target): Likewise.
11108 * linux-crisv32-low.c (the_low_target): Likewise.
11109 * linux-ia64-low.c (the_low_target): Likewise.
11110 * linux-m32r-low.c (the_low_target): Likewise.
11111 * linux-m68k-low.c (the_low_target): Likewise.
11112 * linux-ppc-low.c (the_low_target): Likewise.
11113 * linux-s390-low.c (the_low_target): Likewise.
11114 * linux-sh-low.c (the_low_target): Likewise.
11115 * linux-sparc-low.c (the_low_target): Likewise.
11116 * linux-tic6x-low.c (the_low_target): Likewise.
11117 * linux-x86-low.c (the_low_target): Likewise.
11118 * linux-xtensa-low.c (the_low_target): Likewise.
11119 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
11120 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
11121 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
11122 srv_xmlfiles.
11123 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
11124 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11125
11126 2012-02-29 Yao Qi <yao@codesourcery.com>
11127 Pedro Alves <palves@redhat.com>
11128
11129 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11130 `step_over_finished' is true.
11131
11132 2012-02-27 Pedro Alves <palves@redhat.com>
11133
11134 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11135 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11136
11137 2012-02-27 Pedro Alves <palves@redhat.com>
11138
11139 PR server/9684
11140 * linux-low.c (pid_is_stopped): New.
11141 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11142
11143 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
11144
11145 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11146 of conditions.
11147
11148 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11149
11150 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11151
11152 2012-02-24 Luis Machado <lgustavo@codesourcery>
11153
11154 * server.c (handle_query): Advertise support for target-side
11155 breakpoint condition evaluation.
11156 (process_point_options): New function.
11157 (process_serial_event): When inserting a breakpoint, check for
11158 a target-side condition that should be evaluated.
11159
11160 * mem-break.c: Include regcache.h and ax.h.
11161 (point_cond_list_t): New data structure.
11162 (breakpoint) <cond_list>: New field.
11163 (find_gdb_breakpoint_at): Make non-static.
11164 (delete_gdb_breakpoint_at): Clear any target-side
11165 conditions.
11166 (clear_gdb_breakpoint_conditions): New function.
11167 (add_condition_to_breakpoint): Likewise.
11168 (add_breakpoint_condition): Likewise.
11169 (gdb_condition_true_at_breakpoint): Likewise.
11170 (gdb_breakpoint_here): Return result directly instead
11171 of going through a local variable.
11172
11173 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11174 (clear_gdb_breakpoint_conditions): Likewise.
11175 (add_breakpoint_condition): Likewise.
11176 (gdb_condition_true_at_breakpoint): Likewise.
11177
11178 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11179 (need_step_over_p): Take target-side breakpoint condition into
11180 consideration.
11181
11182 2012-02-24 Luis Machado <lgustavo@codesourcery>
11183
11184 * server.h: Include tracepoint.h.
11185 (agent_mem_read, agent_get_trace_state_variable_value,
11186 agent_set_trace_state_variable_value,
11187 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11188 get_set_tsv_func_addr): New prototypes.
11189
11190 * ax.h: New include file.
11191 * ax.c: New source file.
11192
11193 * tracepoint.c: Include ax.h.
11194 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11195 agent_expr, eval_result_type): Move to ax.h.
11196 (parse_agent_expr): Rename to ...
11197 (gdb_parse_agent_expr): ... this, make it non-static and move
11198 to ax.h.
11199 (unparse_agent_expr) Rename to ...
11200 (gdb_unparse_agent_expr): ... this, make it non-static and move
11201 to ax.h.
11202 (eval_agent_expr): Rename to ...
11203 (eval_tracepoint_agent_expr): ... this.
11204 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11205 forward declarations.
11206 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11207 (agent_get_trace_state_variable_value): New function.
11208 (agent_set_trace_state_variable_value): New function.
11209 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11210 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11211 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11212 (condition_true_at_tracepoint): Likewise.
11213 (parse_agent_expr): Rename to ...
11214 (gdb_parse_agent_expr): ... this and move to ax.c.
11215 (unparse_agent_expr): Rename to ...
11216 (gdb_unparse_agent_expr): ... this and move to ax.c.
11217 (gdb_agent_op_name): Move to ax.c.
11218 (eval_agent_expr): Rename to ...
11219 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11220 and move to ax.c.
11221 (eval_tracepoint_agent_expr): New function.
11222 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
11223 non-static.
11224 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11225 ax.c.
11226 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11227 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11228 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11229 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11230 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11231 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11232 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11233 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11234 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11235 (compile_bytecodes): Remove forward declaration.
11236 (is_goto_target): Move to ax.c.
11237 (compile_bytecodes): Move to ax.c and call
11238 agent_get_trace_state_variable_value (...) and
11239 agent_set_trace_state_variable_value (...).
11240
11241 * Makefile.in: Update ax.c and IPA dependencies.
11242
11243 2012-02-24 Pedro Alves <palves@redhat.com>
11244
11245 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11246 (cmd_bigqtbuffer_circular): ... this. Only handle
11247 'QTBuffer:circular:'.
11248 (handle_tracepoint_general_set): Adjust.
11249
11250 2012-02-16 Yao Qi <yao@codesourcery.com>
11251
11252 * inferiors.c: Move code to ...
11253 * dll.c: .... here. New.
11254 * server.h: Declare clear_dlls.
11255 * Makefile.in (SFILES): Add dll.c.
11256 (OBS): Add dll.o
11257 (dll.o): New rule.
11258
11259 2012-02-11 Yao Qi <yao@codesourcery.com>
11260
11261 * server.c: (handle_monitor_command): Add a new parameter
11262 `own_buf'.
11263 (handle_query): Update caller.
11264
11265 2012-02-09 Joel Brobecker <brobecker@adacore.com>
11266
11267 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11268 * configure, config.in: Regenerate.
11269 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11270 is not defined.
11271
11272 2012-02-02 Pedro Alves <palves@redhat.com>
11273
11274 Try SIGKILL first, then PTRACE_KILL.
11275 * linux-low.c (linux_kill_one_lwp): New.
11276 (linux_kill_one_lwp): Rename to ...
11277 (kill_one_lwp_callback): ... this. Use the new
11278 linux_kill_one_lwp.
11279
11280 2012-02-02 Pedro Alves <palves@redhat.com>
11281
11282 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11283 inferior.
11284
11285 2012-01-27 Pedro Alves <palves@redhat.com>
11286
11287 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11288 (elf_64_file_p): Make static.
11289 (linux_pid_exe_is_elf_64_file): New.
11290 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11291 Delete declarations.
11292 (linux_pid_exe_is_elf_64_file): Declare.
11293 * linux-x86-low.c (x86_arch_setup): Use
11294 linux_pid_exe_is_elf_64_file.
11295
11296 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11297
11298 * linux-low.c (linux_wait_for_event_1): Rename to ...
11299 (linux_wait_for_event): ... here and merge it with former
11300 linux_wait_for_event - new variable wait_ptid, use it.
11301 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11302
11303 2012-01-23 Pedro Alves <palves@redhat.com>
11304
11305 * server.c (main): Avoid yet another case of infinite loop while
11306 detaching/killing after a longjmp.
11307
11308 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11309
11310 Code cleanup.
11311 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11312
11313 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11314
11315 * hostio.c (handle_readlink): New function.
11316 (handle_vFile): Call it to handle "vFile:readlink" packets.
11317
11318 2012-01-20 Pedro Alves <palves@redhat.com>
11319 Ulrich Weigand <ulrich.weigand@linaro.org>
11320
11321 * server.c (handle_v_requests): Only support vAttach and vRun to
11322 start multiple processes when in extended protocol mode.
11323
11324 2012-01-17 Pedro Alves <palves@redhat.com>
11325
11326 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11327 memalign plus mprotect to allocate the scratch buffer.
11328
11329 2012-01-13 Pedro Alves <palves@redhat.com>
11330
11331 * server.c (attach_inferior): Clear `cont_thread'.
11332
11333 2012-01-13 Pedro Alves <palves@redhat.com>
11334
11335 * server.c (main): Avoid infinite loop while detaching/killing
11336 after a longjmp.
11337
11338 2012-01-09 Doug Evans <dje@google.com>
11339
11340 * server.c (start_inferior): Set last_ptid in --wrapper case.
11341
11342 2012-01-06 Yao Qi <yao@codesourcery.com>
11343
11344 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11345 defined.
11346 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11347
11348 2012-01-04 Yao Qi <yao@codesourcery.com>
11349
11350 * tracepoint.c (cmd_qtdp): Print debug message
11351 for static tracepoint.
11352
11353 2012-01-04 Yao Qi <yao@codesourcery.com>
11354
11355 * tracepoint.c (trace_vdebug): Differentiate debug message
11356 between gdbserver and IPA.
11357
11358 2012-01-03 Yao Qi <yao@codesourcery.com>
11359
11360 * tracepoint.c (tracepoint_was_hit): Don't collect for
11361 static tracepoint.
11362
11363 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11364
11365 * terminal.h: Reformat copyright header.
11366
11367 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11368
11369 * server.c (gdbserver_version): Update copyright year.
11370 * gdbreplay.c (gdbreplay_version): Likewise.
11371
11372 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11373
11374 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11375
11376 Revert:
11377 2011-12-18 Hui Zhu <teawater@gmail.com>
11378 * linux-low.c (linux_create_inferior): Save return value to ret.
11379
11380 2011-12-18 Hui Zhu <teawater@gmail.com>
11381
11382 * linux-low.c (linux_create_inferior): Save return value to ret.
11383
11384 2011-12-16 Doug Evans <dje@google.com>
11385
11386 * linux-low.c (linux_create_inferior): If stdio connection,
11387 redirect stdin from /dev/null, stdout to stderr.
11388 * remote-utils.c (remote_is_stdio): New static global.
11389 (remote_connection_is_stdio): New function.
11390 (remote_prepare): Handle stdio connection.
11391 (remote_open): Ditto.
11392 (remote_close): Don't close stdin for stdio connections.
11393 (read_prim,write_prim): New functions. Replace all calls to
11394 read/write to these.
11395 * server.c (main): Watch for "-" argument. Move call to
11396 remote_prepare before start_inferior.
11397 * server.h (STDIO_CONNECTION_NAME): New macro.
11398 (remote_connection_is_stdio): Declare.
11399
11400 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11401 in debugging output.
11402
11403 2011-12-15 Yao Qi <yao@codesourcery.com>
11404
11405 * tracepoint.c: Include sys/syscall.h.
11406 (gdb_ust_thread): Remove preprocessor conditional.
11407
11408 2011-12-14 Pedro Alves <pedro@codesourcery.com>
11409
11410 * linux-low.c (linux_detach_one_lwp): Call
11411 the_low_target.prepare_to_resume before detaching.
11412
11413 2011-12-14 Yao Qi <yao@codesourcery.com>
11414
11415 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11416 of write.
11417
11418 2011-12-14 Yao Qi <yao@codesourcery.com>
11419
11420 * i386-low.c (i386_low_stopped_data_address): Initialize local
11421 variable `control'.
11422
11423 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11424
11425 PR remote/13492
11426
11427 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11428 DR_CONTROL unless necessary. Extend comments.
11429 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11430 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11431
11432 2011-12-13 Yao Qi <yao@codesourcery.com>
11433
11434 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11435 macros.
11436 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11437
11438 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11439
11440 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11441 Print new debug message for such case.
11442
11443 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11444
11445 Fix overlapping memcpy.
11446 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11447 the read_inferior_memory transfer.
11448 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11449 write_inferior_memory transfer.
11450 (set_fast_tracepoint_jump): New variable buf. Use it for the
11451 read_inferior_memory and write_inferior_memory transfers.
11452 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11453 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11454 Use it for the write_inferior_memory transfer.
11455 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11456 buffers.
11457
11458 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11459
11460 * linux-low.c (fetch_register, store_register): Make code
11461 consistent, fix formatting.
11462
11463 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11464
11465 * linux-low.c (usr_store_inferior_registers): Factor out code
11466 to handle individual registers into...
11467 (store_register): ... this new function.
11468
11469 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11470
11471 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11472 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11473 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11474 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11475 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11476 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11477 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11478 (srv_xmlfiles): Add new XML files.
11479
11480 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11481 and <sys/uio.h>.
11482 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11483 (init_registers_s390_linux32v1): Add prototype.
11484 (init_registers_s390_linux32v2): Likewise.
11485 (init_registers_s390_linux64v1): Likewise.
11486 (init_registers_s390_linux64v2): Likewise.
11487 (init_registers_s390x_linux64v1): Likewise.
11488 (init_registers_s390x_linux64v2): Likewise.
11489 (s390_num_regs): Increment to 52.
11490 (s390_regmap): Add orig_r2 register.
11491 (s390_num_regs_3264): Increment to 68.
11492 (s390_regmap_3264): Add orig_r2 register.
11493 (s390_collect_ptrace_register): Handle orig_r2 register.
11494 (s390_supply_ptrace_register): Likewise.
11495 (s390_fill_last_break): New function.
11496 (s390_store_last_break): Likewise.
11497 (s390_fill_system_call): New function.
11498 (s390_store_system_call): Likewise.
11499 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11500 register sets.
11501 (s390_check_regset): New function.
11502 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11503 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11504 Update target_regsets for available register sets.
11505
11506 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11507 Jan Kratochvil <jan.kratochvil@redhat.com>
11508
11509 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11510 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11511 New.
11512 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11513 * linux-low.h (struct process_info_private): New member r_debug.
11514 * server.c (handle_qxfer_libraries): Call
11515 the_target->qxfer_libraries_svr4.
11516 (handle_qxfer_libraries_svr4): New function.
11517 (qxfer_packets): New entry "libraries-svr4".
11518 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11519 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11520 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11521 PACKET_qXfer_libraries_svr4.
11522
11523 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11524
11525 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11526 PSW address/mask between 8-byte and 16-byte formats.
11527 (s390_supply_ptrace_register): Likewise.
11528 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11529 basic addressing mode bit.
11530
11531 2011-11-24 Stan Shebs <stan@codesourcery.com>
11532
11533 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11534
11535 2011-11-17 Stan Shebs <stan@codesourcery.com>
11536
11537 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11538 (tracing_start_time): New global.
11539 (tracing_stop_time): New global.
11540 (tracing_user_name): New global.
11541 (tracing_notes): New global.
11542 (tracing_stop_note): New global.
11543 (cmd_qtstart): Set traceframe_usage, start_time.
11544 (stop_tracing): Set stop_time.
11545 (cmd_qtstatus): Report additional status.
11546 (cmd_qtp): New function.
11547 (handle_tracepoint_query): Call it.
11548 (cmd_qtnotes): New function.
11549 (handle_tracepoint_general_set): Call it.
11550 (get_timestamp): Rename from tsv_get_timestamp.
11551
11552 2011-11-14 Stan Shebs <stan@codesourcery.com>
11553 Kwok Cheung Yeung <kcy@codesourcery.com>
11554
11555 * linux-x86-low.c (small_jump_insn): New.
11556 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11557 trampoline and error message, build a trampoline and issue a small
11558 jump instruction to it.
11559 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11560 trampoline and error message.
11561 (x86_get_min_fast_tracepoint_insn_len): New.
11562 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11563 * linux-low.h (struct linux_target_ops): Add arguments to
11564 install_fast_tracepoint_jump_pad operation, add new operation.
11565 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11566 arguments.
11567 (linux_get_min_fast_tracepoint_insn_len): New function.
11568 (linux_target_op): Add new operation.
11569 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11570 (gdb_trampoline_buffer_end): Ditto.
11571 (gdb_trampoline_buffer_error): Ditto.
11572 (struct ipa_sym_addresses): Add fields for new IPA variables.
11573 (symbol_list): Add entries for new IPA variables.
11574 (struct tracepoint): Add fields to hold the address range of the
11575 trampoline used by the tracepoint.
11576 (trampoline_buffer_head): New static variable.
11577 (trampoline_buffer_tail): Ditto.
11578 (claim_trampoline_space): New function.
11579 (have_fast_tracepoint_trampoline_buffer): New function.
11580 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11581 structure.
11582 (install_fast_tracepoint): Ditto, also add error buffer argument.
11583 (cmd_qtminftpilen): New function.
11584 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11585 (fast_tracepoint_from_trampoline_address): New function.
11586 (fast_tracepoint_collecting): Handle trampoline as part of jump
11587 pad space.
11588 (set_trampoline_buffer_space): New function.
11589 (initialize_tracepoint): Initialize new IPA variables.
11590 * target.h (struct target_ops): Add arguments to
11591 install_fast_tracepoint_jump_pad operation, add new
11592 get_min_fast_tracepoint_insn_len operation.
11593 (target_get_min_fast_tracepoint_insn_len): New.
11594 (install_fast_tracepoint_jump_pad): Add arguments.
11595 * server.h (IPA_BUFSIZ): Define.
11596 * linux-i386-ipa.c: Include extra header files.
11597 (initialize_fast_tracepoint_trampoline_buffer): New function.
11598 (initialize_low_tracepoint): Call it.
11599 * server.h (set_trampoline_buffer_space): Declare.
11600 (claim_trampoline_space): Ditto.
11601 (have_fast_tracepoint_trampoline_buffer): Ditto.
11602
11603 2011-11-14 Yao Qi <yao@codesourcery.com>
11604
11605 * server.c (handle_query): Handle InstallInTrace for qSupported.
11606 * tracepoint.c (add_tracepoint): Sort list.
11607 (install_tracepoint, download_tracepoint): New.
11608 (cmd_qtdp): Call them to install and download tracepoints.
11609 (sort_tracepoints): Removed.
11610 (cmd_qtstart): Update.
11611
11612 2011-11-14 Yao Qi <yao@codesourcery.com>
11613
11614 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11615 * mem-break.h: Declare.
11616 * tracepoint.c (cmd_qtstart): Move some code to ...
11617 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11618 New.
11619 (download_tracepoints): Move some code to ...
11620 (download_tracepoint_1): ... here. New.
11621
11622 2011-11-08 Yao Qi <yao@codesourcery.com>
11623
11624 * remote-utils.c (relocate_instruction): A comment fix.
11625
11626 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11627
11628 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11629 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11630 dr_status_mirror and dr_control_mirror from debug_reg_state.
11631 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11632 (i386_initial_stuff): Remove use of deleted globals.
11633 (i386_get_thread_context, i386_set_thread_context,
11634 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11635 from debug_reg_state.
11636
11637 2011-11-05 Yao Qi <yao@codesourcery.com>
11638
11639 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11640 address as TPOINT's.
11641
11642 2011-11-02 Stan Shebs <stan@codesourcery.com>
11643
11644 * tracepoint.c (agent_mem_read_string): New function.
11645 (eval_agent_expr): Call it for tracenz.
11646 * server.c (handle_query): Report support for tracenz.
11647
11648 2011-11-02 Yao Qi <yao@codesourcery.com>
11649
11650 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11651
11652 2011-11-02 Yao Qi <yao@codesourcery.com>
11653
11654 * target.h: Fix a typo in comment.
11655
11656 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11657
11658 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11659 clobber the breakpoints' shadows with fast tracepoint jumps.
11660 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11661 * target.c (write_inferior_memory): Also pass MYADDR down to
11662 check_mem_write.
11663
11664 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11665
11666 * configure.ac: Check support for personality routine.
11667 * configure: Regenerate.
11668 * config.in: Likewise.
11669 * linux-low.c: Include <sys/personality.h>.
11670 Define ADDR_NO_RANDOMIZE if necessary.
11671 (linux_create_inferior): Disable address space randomization when
11672 forking inferior, if requested.
11673 (linux_supports_disable_randomization): New function.
11674 (linux_target_ops): Install it.
11675 * server.h (disable_randomization): Declare.
11676 * server.c (disable_randomization): New global variable.
11677 (handle_general_set): Handle QDisableRandomization.
11678 (handle_query): Likewise for qSupported.
11679 (main): Support --disable-randomization and --no-disable-randomization
11680 command line arguments.
11681 * target.h (struct target_ops): Add supports_disable_randomization.
11682 (target_supports_disable_randomization): New macro.
11683
11684 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11685
11686 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11687 ifdef check.
11688 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11689 [!PT_GETDSBT] (target_loadmap): New definition.
11690 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11691 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11692 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11693 and PT_GETDSBT to LINUX_LOADMAP.
11694 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11695 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11696
11697 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11698
11699 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11700 (arm_linux_hwbp_cap): New static variable.
11701 (arm_linux_get_hwbp_cap): Replace by ...
11702 (arm_linux_init_hwbp_cap): ... this new function.
11703 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11704 (arm_linux_get_hw_watchpoint_count): Likewise.
11705 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11706 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11707 (arm_prepare_to_resume): Use perror_with_name instead of error.
11708
11709 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11710
11711 * linux-arm-low.c: Include <signal.h>.
11712 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11713 (struct arm_linux_hwbp_cap): New data type.
11714 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11715 (struct arm_linux_hw_breakpoint): New data type.
11716 (MAX_BPTS, MAX_WPTS): Define.
11717 (struct arch_process_info, struct arch_lwp_info): New data types.
11718 (arm_linux_get_hwbp_cap): New function.
11719 (arm_linux_get_hw_breakpoint_count): Likewise.
11720 (arm_linux_get_hw_watchpoint_count): Likewise.
11721 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11722 (arm_hwbp_control_initialize): Likewise.
11723 (arm_hwbp_control_is_enabled): Likewise.
11724 (arm_hwbp_control_is_initialized): Likewise.
11725 (arm_hwbp_control_disable): Likewise.
11726 (arm_linux_hw_breakpoint_equal): Likewise.
11727 (arm_linux_hw_point_initialize): Likewise.
11728 (struct update_registers_data): New data structure.
11729 (update_registers_callback: New function.
11730 (arm_insert_point): Likewise.
11731 (arm_remove_point): Likewise.
11732 (arm_stopped_by_watchpoint): Likewise.
11733 (arm_stopped_data_address): Likewise.
11734 (arm_new_process): Likewise.
11735 (arm_new_thread): Likewise.
11736 (arm_prepare_to_resume): Likewise.
11737 (the_low_target): Register arm_insert_point, arm_remove_point,
11738 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11739 arm_new_thread, and arm_prepare_to_resume.
11740
11741 2011-09-15 Stan Shebs <stan@codesourcery.com>
11742
11743 * server.h (struct emit_ops): Add compare-goto fields.
11744 * tracepoint.c (gdb_agent_op_sizes): New table.
11745 (emit_eq_goto): New function.
11746 (emit_ne_goto): New function.
11747 (emit_lt_goto): New function.
11748 (emit_le_goto): New function.
11749 (emit_gt_goto): New function.
11750 (emit_ge_goto): New function.
11751 (is_goto_target): New function.
11752 (compile_bytecodes): Recognize special cases of compare-goto
11753 combinations and call specialized emitters for them.
11754 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11755 (amd64_emit_ne_goto): New function.
11756 (amd64_emit_lt_goto): New function.
11757 (amd64_emit_le_goto): New function.
11758 (amd64_emit_gt_goto): New function.
11759 (amd64_emit_ge_goto): New function.
11760 (amd64_emit_ops): Add the new functions.
11761 (i386_emit_eq_goto): New function.
11762 (i386_emit_ne_goto): New function.
11763 (i386_emit_lt_goto): New function.
11764 (i386_emit_le_goto): New function.
11765 (i386_emit_gt_goto): New function.
11766 (i386_emit_ge_goto): New function.
11767 (i386_emit_ops): Add the new functions.
11768
11769 2011-09-08 Stan Shebs <stan@codesourcery.com>
11770
11771 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11772 (i386_emit_epilogue): Restore %ebx.
11773
11774 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11775
11776 * server.c (step_thread): Remove definition.
11777 (process_serial_event): Don't handle Hs.
11778 * server.h (step_thread): Remove declaration.
11779 * target.c (set_desired_inferior): Remove use of step_thread.
11780
11781 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11782
11783 * linux-low.c: Include linux-procfs.h.
11784 (linux_attach_lwp_1): Update comments.
11785 (linux_attach): Scan for existing threads when attaching to a
11786 process that is the tgid.
11787 * Makefile.in: Update dependencies.
11788
11789 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11790
11791 * configure.srv: Add linux-procfs.o dependencies.
11792
11793 2011-08-14 Yao Qi <yao@codesourcery.com>
11794
11795 * target.h (struct target_ops): Fix indent.
11796 * win32-low.c (win32_target_ops): Fix comment.
11797
11798 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11799 Yao Qi <yao@codesourcery.com>
11800
11801 * Makefile.in (clean): Remove tic6x-*.c files.
11802 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11803 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11804 (tic6x-c64xp-linux.c): Likewise.
11805 * configure.srv: Add support for tic6x-*-uclinux.
11806 * linux-tic6x-low.c: New.
11807 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11808
11809 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11810 Yao Qi <yao@codesourcery.com>
11811
11812 * target.h (struct target_ops): Add read_loadmap.
11813 * linux-low.c (struct target_loadseg): New type.
11814 (struct target_loadmap): New type.
11815 (linux_read_loadmap): New function.
11816 (linux_target_ops): Add linux_read_loadmap.
11817 * server.c (handle_query): Support qXfer:fdpic:read packet.
11818 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11819 to NULL.
11820
11821 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11822
11823 * win32-low.c: Include <stdint.h>.
11824
11825 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11826
11827 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11828 to the inferior here.
11829 (i386_remove_aligned_watchpoint): Ditto.
11830 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11831 fit part of the watchpoint in the debug registers.
11832 (i386_update_inferior_debug_regs): New.
11833 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11834 registers, and only update the inferior on success.
11835 (i386_low_remove_watchpoint): Ditto.
11836
11837 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11838
11839 * linux-low.c (compare_ints, unique, list_threads, show_process,
11840 linux_core_of_thread): Delete.
11841 (linux_target_ops): Change linux_core_of_thread to
11842 linux_common_core_of_thread.
11843 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11844 * utils.c (malloc_failure): Change type of argument.
11845 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11846 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11847 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11848 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11849 (IPA_OBJS): Add common-utils-ipa.o.
11850 (ptid_h, linux_osdata_h): New macros.
11851 (server_h): Add common/common-utils.h, common/xml-utils.h,
11852 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11853 common/ptid.h.
11854 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11855 ptid.o, buffer.o): New rules.
11856 (linux-low.o): Add common/linux-osdata.h as a dependency.
11857 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11858 * configure.ac: Add AC_HEADER_DIRENT check.
11859 * config.in: Regenerate.
11860 * configure: Regenerate.
11861 * remote-utils.c (xml_escape_text): Delete.
11862 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11863 buffer_xml_printf): Move to common/buffer.c.
11864 * server.c (main): Remove call to initialize_inferiors.
11865 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11866 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11867 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11868 internal_error, gdb_assert, gdb_assert_fail): Delete.
11869 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11870 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11871 common/buffer.h.
11872 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11873 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11874 initialize_inferiors): Delete.
11875
11876 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11877
11878 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11879 symbol error.
11880
11881 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11882
11883 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11884 assertion.
11885 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11886
11887 2011-05-26 Yao Qi <yao@codesourcery.com>
11888
11889 * Makefile.in (thread-db.o): Track dependence to
11890 common/gdb_thread_db.h.
11891 * thread-db.c: include gdb_thread_db.h from right place.
11892
11893 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11894
11895 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11896 __FILE__ and __LINE__ to internal_error.
11897
11898 2011-05-13 Doug Evans <dje@google.com>
11899
11900 * thread-db.c (try_thread_db_load_from_sdir): New function.
11901 (try_thread_db_load_from_dir): New function.
11902 (thread_db_load_search): Handle $sdir, ignore $pdir.
11903 Remove trying of system directories if search of
11904 libthread-db-search-path fails, that is now done via $sdir.
11905
11906 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11907
11908 * server.c (handle_query): Add EnableDisableTracepoints to the list
11909 of supported features.
11910 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11911 tracepoints.
11912 (cmd_qtenable_disable): New.
11913 (cmd_qtstart): Install tracepoints even if disabled.
11914 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11915 receiving a QTEnable or QTDisable packet.
11916 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11917 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11918 tracepoints.
11919 (gdb_probe): Skip data collection if static tracepoint is disabled.
11920
11921 2011-05-10 Doug Evans <dje@google.com>
11922
11923 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11924
11925 2011-05-04 Doug Evans <dje@google.com>
11926
11927 * linux-low.c (linux_join): Skip process lookup.
11928 * spu-low.c (spu_join): Ditto.
11929 * server.c (join_inferiors_callback): Delete.
11930 (process_serial_event): For 'D' packet (detach) call join_inferior
11931 directly.
11932
11933 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11934
11935 * README: Don't mention xscale*-*-linux*.
11936 * configure.srv (xscale*-*-linux*): Don't handle target.
11937
11938 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11939
11940 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11941 casting pointers.
11942 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11943 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11944 (i386_emit_void_call_2): Likewise.
11945
11946 2011-04-26 Yao Qi <yao@codesourcery.com>
11947
11948 * linux-low.c: Move common macros to linux-ptrace.h.
11949 Include linux-ptrace.h.
11950 * Makefile.in (linux_ptrace_h): New.
11951 (linux-low.o): Depends on linux-ptrace.h.
11952
11953 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11954
11955 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11956 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11957 (remote_prepare): New function with most of the TCP code from ...
11958 (remote_open): ... here. Detect PORT here unconditionally. Move also
11959 setting transport_is_reliable.
11960 * server.c (run_once): New variable.
11961 (gdbserver_usage): Document it.
11962 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11963 the first run if RUN_ONCE.
11964 * server.h (run_once, remote_prepare): New declarations.
11965
11966 2011-04-19 Tom Tromey <tromey@redhat.com>
11967
11968 * win32-low.c (handle_load_dll): Remove duplicate "the".
11969
11970 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11971
11972 Remove support for old Cygwin 1.5 versions.
11973 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11974 function to avoid warning.
11975 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11976 warning.
11977
11978 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11979
11980 * gdbserver/server.h (Macro _): Define it if not available.
11981
11982 2011-03-14 Michael Snyder <msnyder@vmware.com>
11983
11984 * hostio.c (handle_close): Remove unnecessary null test.
11985
11986 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11987
11988 * Makefile.in (maintainer-clean realclean distclean): Remove
11989 "make ... subdir_do" command.
11990
11991 2011-03-10 Michael Snyder <msnyder@vmware.com>
11992
11993 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11994
11995 * server.c (handle_v_run): Free alloced buffer on early return.
11996
11997 2011-03-09 Yao Qi <yao@codesourcery.com>
11998
11999 Revert:
12000 2011-03-04 Yao Qi <yao@codesourcery.com>
12001
12002 * Makefile.in: Remove GNU make feature --directory.
12003
12004 2011-03-05 Yao Qi <yao@codesourcery.com>
12005
12006 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12007 (subdir_do): New make target. Copied from gdb/Makefile.
12008 (maintainer-clean, realclean, distclean, clean): Call corresponding
12009 make targets in common/Makefile.
12010
12011 2011-02-11 Yao Qi <yao@codesourcery.com>
12012
12013 * configure.ac: Call AC_PROG_RANLIB.
12014 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12015 * configure: Regenerate.
12016
12017 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12018
12019 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
12020
12021 2011-03-06 Yao Qi <yao@codesourcery.com>
12022
12023 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
12024
12025 2011-03-05 Yao Qi <yao@codesourcery.com>
12026
12027 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12028 (subdir_do): New make target. Copied from gdb/Makefile.
12029 (maintainer-clean, realclean, distclean, clean): Call corresponding
12030 make targets in common/Makefile.
12031
12032 2011-03-04 Yao Qi <yao@codesourcery.com>
12033
12034 * Makefile.in: Remove GNU make feature --directory.
12035
12036 2011-03-04 Michael Snyder <msnyder@vmware.com>
12037
12038 * server.c (queue_stop_reply): Call xmalloc not malloc.
12039
12040 2011-03-02 Michael Snyder <msnyder@vmware.com>
12041
12042 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
12043
12044 2011-02-28 Michael Snyder <msnyder@vmware.com>
12045
12046 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
12047 (cmd_qtframe): Ditto.
12048 (cmd_qtbuffer): Ditto.
12049 (cmd_bigqtbuffer): Ditto.
12050
12051 * utils.c (decimal2str): Initialize 'width' to nine, then
12052 don't mess with it.
12053
12054 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
12055
12056 * hostio.c (require_data): Free *data, not data.
12057
12058 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12059
12060 * hostio.c (require_data): Use free, not xfree.
12061
12062 2011-02-27 Michael Snyder <msnyder@vmware.com>
12063
12064 * server.c (handle_query): Discard unused value.
12065
12066 * hostio.c (require_data): Free malloc memory before returning
12067 error.
12068
12069 2011-02-26 Michael Snyder <msnyder@vmware.com>
12070
12071 * linux-low.c (list_threads): Call closedir for dirent.
12072
12073 2011-02-27 Michael Snyder <msnyder@vmware.com>
12074
12075 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
12076 a case statement falls through.
12077
12078 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
12079
12080 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
12081 in comparison.
12082
12083 2011-02-26 Michael Snyder <msnyder@vmware.com>
12084
12085 * utils.c (decimal2str): Eliminate dead code and dead param.
12086 (pulongest): Drop dead param from call to decimal2str.
12087 (plongest): Ditto.
12088
12089 2011-02-24 Joel Brobecker <brobecker@adacore.com>
12090
12091 Revert the following patch (not approved yet):
12092 2011-02-21 Hui Zhu <teawater@gmail.com>
12093 * tracepoint.c (tp_printf): New function.
12094 (eval_agent_expr): Handle gdb_agent_op_printf.
12095
12096 2011-02-21 Hui Zhu <teawater@gmail.com>
12097
12098 * tracepoint.c (tp_printf): New function.
12099 (eval_agent_expr): Handle gdb_agent_op_printf.
12100
12101 2011-02-18 Tom Tromey <tromey@redhat.com>
12102
12103 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
12104 (tracepoint.o): Likewise.
12105 * tracepoint.c (enum gdb_agent_op): Use ax.def.
12106 (gdb_agent_op_names): Likewise.
12107
12108 2011-02-18 Tom Tromey <tromey@redhat.com>
12109
12110 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
12111 gdb_agent_op_rot>: New constants.
12112 (gdb_agent_op_names): Add pick and roll.
12113 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
12114 cases.
12115
12116 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
12117
12118 * aclocal.m4: Regenerated with aclocal-1.11.1.
12119
12120 2011-02-14 Pedro Alves <pedro@codesourcery.com>
12121
12122 * server.c (handle_qxfer_traceframe_info): New.
12123 (qxfer_packets): Register "traceframe-info".
12124 (handle_query): Report support for qXfer:traceframe-info:read+.
12125 * tracepoint.c (match_blocktype): New.
12126 (traceframe_find_block_type): Rename to ...
12127 (traceframe_walk_blocks): ... this. Add callback filter argument,
12128 and use it.
12129 (traceframe_find_block_type): New, reimplemented on top of
12130 traceframe_walk_blocks.
12131 (build_traceframe_info_xml): New.
12132 (traceframe_read_info): New.
12133 * server.h (traceframe_read_info): Declare.
12134
12135 2011-02-11 Yao Qi <yao@codesourcery.com>
12136
12137 * configure.ac: Call AC_PROG_RANLIB.
12138 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12139 * configure: Regenerate.
12140
12141 2011-02-07 Pedro Alves <pedro@codesourcery.com>
12142
12143 * server.c (gdb_read_memory): Change return semantics to allow
12144 partial transfers.
12145 (handle_search_memory_1): Adjust.
12146 (process_serial_event) <'m' packet>: Handle partial transfers.
12147 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12148
12149 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12150
12151 * regcache.c (init_register_cache): Initialize
12152 regcache->register_status.
12153 (free_register_cache): Release regcache->register_status.
12154 (regcache_cpy): Copy register_status.
12155 (registers_to_string): Print 'x's for unavailable registers.
12156 (supply_register): Mark the register's status valid or
12157 unavailable, depending on whether a buffer was passed in or not.
12158 (supply_register_zeroed): New.
12159 (supply_regblock): Mark the registers' status valid or
12160 unavailable, depending on whether a buffer was passed in or not.
12161 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12162 (struct regcache): New `register_status' field.
12163 (supply_register_zeroed): Declare.
12164 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12165 supply_register_zeroed, rather than passing a NULL buffer to
12166 supply_register.
12167 * tracepoint.c (fetch_traceframe_registers): Update comment.
12168
12169 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12170
12171 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12172 buffer explicit.
12173
12174 2011-01-25 Pedro Alves <pedro@codesourcery.com>
12175
12176 * server.h (decode_xfer_write): Change prototype.
12177 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12178 and don't extract the annex here.
12179 * server.c (decode_xfer_read): Remove `annex' parameter,
12180 and don't extract the annex here.
12181 (decode_xfer): New.
12182 (struct qxfer): New.
12183 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12184 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12185 (handle_qxfer_statictrace): New functions, abstracted out from
12186 handle_query, and made to use the struct qxfer interface.
12187 (handle_threads_qxfer_proper): Rename to ...
12188 (handle_qxfer_threads_proper): ... this.
12189 (handle_threads_qxfer): Rename to ...
12190 (handle_qxfer_threads): ... this. Adjust.
12191 (qxfer_packets): New array.
12192 (handle_qxfer): New function.
12193 (handle_query): Use handle_qxfer.
12194
12195 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12196
12197 * gdbreplay.c: Shorten lines of >= 80 columns.
12198 * linux-low.c: Ditto.
12199 * linux-ppc-low.c: Ditto.
12200 * linux-s390-low.c: Ditto.
12201 * linux-sparc-low.c: Ditto.
12202 * linux-x86-low.c: Ditto.
12203 * linux-xtensa-low.c: Ditto.
12204 * mem-break.c: Ditto.
12205 * nto-low.c: Ditto.
12206 * regcache.h: Ditto.
12207 * remote-utils.c: Ditto.
12208 * server.c: Ditto.
12209 * server.h: Ditto.
12210 * thread-db.c: Ditto.
12211 * tracepoint.c: Ditto.
12212 * utils.c: Ditto.
12213 * win32-low.h: Ditto.
12214
12215 2011-01-05 Joel Brobecker <brobecker@adacore.com>
12216
12217 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12218 update.
12219
12220 2011-01-01 Joel Brobecker <brobecker@adacore.com>
12221
12222 * server.c (gdbserver_version): Update copyright year in version
12223 output.
12224 * gdbreplay.c (gdbreplay_version): Ditto.
12225
12226 2010-12-29 Jie Zhang <jie.zhang@analog.com>
12227
12228 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12229 * linux-bfin-low.c: New file.
12230 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12231 PT_DATA_ADDR for BFIN targets.
12232 * Makefile.in (SFILES): Add linux-bfin-low.c.
12233 (clean): Remove reg-bfin.c.
12234 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12235 * README: Mention supported Blackfin targets.
12236
12237 2010-12-23 Mike Frysinger <vapier@gentoo.org>
12238
12239 * .gitignore: New file.
12240
12241 2010-11-16 Mike Frysinger <vapier@gentoo.org>
12242
12243 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12244
12245 2010-10-22 Jie Zhang <jie@codesourcery.com>
12246
12247 * Makefile.in: Add FLAGS_TO_PASS variable.
12248 (install): Remove dependency of install-only and recursively
12249 invoke make for install-only.
12250
12251 2010-10-04 Doug Evans <dje@google.com>
12252
12253 * Makefile.in (uninstall): Use $(DESTDIR).
12254
12255 2010-09-24 Pedro Alves <pedro@codesourcery.com>
12256
12257 PR gdb/11842
12258
12259 * linux-x86-low.c (compat_siginfo_from_siginfo)
12260 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12261 si_code is < 0. Check for si_code == SI_TIMER before checking for
12262 si_code < 0.
12263
12264 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12265
12266 * lynx-i386-low.c: New file.
12267 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12268
12269 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12270
12271 * lynx-low.c (ptrace_request_to_str): Remove handling for
12272 request values that have been removed in LynxOS 5.x.
12273
12274 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12275
12276 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12277 <ptrace.h>
12278
12279 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12280
12281 * configure.ac: Add --enable-inprocess-agent option.
12282 * configure: Rebuilt.
12283
12284 2010-09-06 Yao Qi <yao@codesourcery.com>
12285
12286 * linux-low.c (linux_kill): Remove unused variable.
12287 (linux_stabilize_threads): Likewise.
12288 * server.c (start_inferior): Likewise.
12289 (queue_stop_reply_callback): Likewise.
12290 * tracepoint.c (do_action_at_tracepoint): Likewise.
12291
12292 2010-09-06 Yao Qi <yao@codesourcery.com>
12293
12294 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12295 on return.
12296
12297 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12298
12299 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12300
12301 2010-09-06 Pedro Alves <pedro@codesourcery.com>
12302
12303 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12304 "$(IPA_DEPFILES)".
12305
12306 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12307
12308 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12309 gdbserver/lynx-ppc-low.c: New files.
12310 * Makefile.in (lynx_low_h): New variable.
12311 (lynx-low.o, lynx-ppc-low.o): New rules.
12312 * configure.ac: On LynxOS, link with -lnetinet.
12313 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12314 * configure: regenerate.
12315
12316 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12317
12318 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12319 * configure.ac: Add check for vasprintf and vsnprintf.
12320 * configure, config.in: Regenerate.
12321 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12322
12323 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12324
12325 * gdbreplay.c: Move include of alloca.h up, next to include of
12326 malloc.h.
12327 * server.h: Add include of malloc.h.
12328 * mem-break.c: Remove include of malloc.h.
12329 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12330
12331 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12332
12333 * Makefile.in (memmem.o): Build with -Wno-error.
12334
12335 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12336
12337 * utils.c (xsnprintf): Make non-static.
12338 * server.h: Add xsnprintf declaration.
12339 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12340 replace calls to snprintf by calls to xsnprintf throughout.
12341
12342 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12343
12344 * configure.ac: Add configure check for alloca.
12345 * configure, config.in: Regenerate.
12346 * server.h: Include alloca.h if it exists.
12347 * gdbreplay.c: Include alloca.h if it exists.
12348
12349 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12350
12351 * linux-low.c (__SIGRTMIN): Define if not already defined.
12352 (linux_create_inferior): Check for __ANDROID__ rather than
12353 __SIGRTMIN.
12354 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12355 are already deferred.
12356 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12357 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12358 stopped and already has a pending signal to report.
12359 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12360 a pending signal to report or is moving out of a jump pad.
12361 (linux_init_signals): Check for __ANDROID__ rather than
12362 __SIGRTMIN.
12363
12364 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12365
12366 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12367 debug_threads check. Avoid a linear search when not doing debug
12368 output.
12369
12370 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12371
12372 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12373 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12374 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12375 (process_event): Change local fd's type to gdb_fildes_t.
12376 (create_file_handler): Adjust prototype.
12377 (delete_file_handler): Adjust prototype.
12378 (handle_file_event): Adjust prototype. Use pfildes.
12379 (create_file_event): Adjsut prototype.
12380 * remote-utils.c (remote_desc, listen_desc): Change type to
12381 gdb_fildes_t.
12382 * server.h: New gdb_fildes_t typedef.
12383 [USE_WIN32API]: Include winsock2.h.
12384 (delete_file_handler, add_file_handler): Adjust prototypes.
12385 (pfildes): Declare.
12386 * utils.c (pfildes): New.
12387
12388 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12389
12390 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12391 * configure: Regenerate.
12392
12393 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12394
12395 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12396 (linux_done_accessing_memory): ... this.
12397 (linux_target_ops): Adjust.
12398 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12399 * nto-low.c (nto_target_ops): Adjust comment.
12400 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12401 * spu-low.c (spu_target_ops): Adjust comment.
12402 * target.h (target_ops): Rename unprepare_to_access_memory field
12403 to done_accessing_memory.
12404 (unprepare_to_access_memory): Rename to ...
12405 (done_accessing_memory): ... this.
12406
12407 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12408
12409 * linux-low.c (linux_prepare_to_access_memory): New.
12410 (linux_unprepare_to_access_memory): New.
12411 (linux_target_ops): Install them.
12412 * server.c (read_memory): Rename to ...
12413 (gdb_read_memory): ... this. Use
12414 prepare_to_access_memory/prepare_to_access_memory.
12415 (write_memory): Rename to ...
12416 (gdb_write_memory): ... this. Use
12417 prepare_to_access_memory/prepare_to_access_memory.
12418 (handle_search_memory_1): Adjust.
12419 (process_serial_event): Adjust.
12420 * target.h (struct target_ops): New fields
12421 prepare_to_access_memory and unprepare_to_access_memory.
12422 (prepare_to_access_memory, unprepare_to_access_memory): New.
12423 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12424 prepare_to_access_memory/prepare_to_access_memory.
12425 * nto-low.c (nto_target_ops): Adjust.
12426 * spu-low.c (spu_target_ops): Adjust.
12427 * win32-low.c (win32_target_ops): Adjust.
12428
12429 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12430
12431 * Makefile.in (WARN_CFLAGS): Get it from configure.
12432 (WERROR_CFLAGS): New.
12433 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12434 * configure.ac: Introduce --enable-werror, which adds -Werror to
12435 the compiler command line. Enabled by default. Disable with
12436 --disable-werror. Add -Wdeclaration-after-statement
12437 Wpointer-arith and -Wformat-nonliteral to warning flags.
12438 * configure: Regenerate.
12439
12440 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12441
12442 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12443
12444 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12445
12446 * gdbreplay.c (remote_error): New.
12447 (gdbchar): New.
12448 (expect): Use gdbchar. Check for error reading from GDB.
12449 Clarify sync error output.
12450 (play): Check for errors writing to GDB.
12451 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12452 * remote-utils.c (getpkt): Check for errors writing to the remote
12453 descriptor.
12454
12455 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12456
12457 * linux-low.c (linux_wait_1): Move non-debugging code out of
12458 `debug_threads' control.
12459
12460 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12461
12462 * linux-low.c (linux_wait_1): Don't set last_status here.
12463 * server.c (push_event, queue_stop_reply_callback): Assert we're
12464 not pushing a TARGET_WAITKIND_IGNORE event.
12465 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12466 (myresume, handle_target_event): Set the thread's last_resume_kind
12467 and last_status from the target returned status.
12468
12469 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12470
12471 PR threads/10729
12472
12473 * linux-x86-low.c (update_debug_registers_callback): New.
12474 (i386_dr_low_set_addr): Use it.
12475 (i386_dr_low_get_addr): New.
12476 (i386_dr_low_set_control): Use update_debug_registers_callback.
12477 (i386_dr_low_get_control): New.
12478 (i386_dr_low_get_status): Adjust.
12479 * linux-low.c (linux_stop_lwp): New.
12480 * linux-low.h (linux_stop_lwp): Declare.
12481
12482 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12483 argument instead of a i386_debug_reg_state.
12484 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12485 a i386_debug_reg_state.
12486 (i386_insert_aligned_watchpoint): Adjust.
12487 (i386_remove_aligned_watchpoint): Adjust.
12488 (i386_low_stopped_data_address): Read the debug registers from the
12489 inferior instead of from the mirrors.
12490 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12491 (i386_dr_low_get_addr): Declare.
12492 (i386_dr_low_get_control): Declare.
12493 (i386_dr_low_get_status): Change prototype.
12494
12495 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12496 (i386_dr_low_get_addr): New.
12497 (i386_dr_low_get_control): New.
12498 (i386_dr_low_get_status): Adjust prototype. Return
12499 dr_status_mirror.
12500 (i386_initial_stuff): Clear dr_status_mirror and
12501 dr_control_mirror.
12502 (i386_get_thread_context): Adjust.
12503 (i386_set_thread_context): Adjust.
12504 (i386_thread_added): Adjust.
12505
12506 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12507
12508 * linux-low.h (linux_thread_area): Delete declaration.
12509
12510 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12511
12512 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12513 after its termination.
12514
12515 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12516
12517 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12518 (gdb_wants_all_stopped): Delete.
12519 (linux_wait_1): Don't call them.
12520 * server.c (handle_v_cont): Tag all threads as want-stopped.
12521 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12522 stopped as "client-wants-stopped".
12523
12524 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12525
12526 * Makefile.in (signals_h): New.
12527 (server_h): Depend on it.
12528 (server.o): Don't depend on $(signals_def).
12529 (signals.o): Depend on $(signals_def).
12530
12531 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12532
12533 * Makefile.in (signals_def): New.
12534 (server_h): Append include/gdb/signals.h and signals_def.
12535 (server.o): Append signals_def.
12536
12537 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12538
12539 * server.c (handle_target_event): Use target_signal_to_host for
12540 resume_info.sig initialization.
12541 * target.h (struct thread_resume) <sig>: New comment.
12542
12543 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12544
12545 * server.c (handle_query): strcpy() the returned string from paddress()
12546 instead of sprintf().
12547 * utils.c (paddress): Return phex_nz().
12548
12549 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12550
12551 * server.c (handle_v_cont): Call mourn_inferior if process
12552 just exited.
12553 (myresume): Likewise.
12554
12555 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12556
12557 Static tracepoints, and integration with UST.
12558
12559 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12560 * mem-break.c (uninsert_all_breakpoints)
12561 (reinsert_all_breakpoints): New.
12562 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12563 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12564 (gdb_agent_ust_loaded, helper_thread_id)
12565 (gdb_agent_helper_thread_id): New macros.
12566 (struct ipa_sym_addresses): Add addr_ust_loaded,
12567 addr_helper_thread_id, addr_cmd_buf.
12568 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12569 (in_process_agent_loaded_ust): New.
12570 (write_e_ust_not_loaded): New.
12571 (maybe_write_ipa_ust_not_loaded): New.
12572 (struct collect_static_trace_data_action): New.
12573 (enum tracepoint_type) <static_tracepoint>: New.
12574 (struct tracepoint) <handle>: Mention static tracepoints.
12575 (struct static_tracepoint_ctx): New.
12576 (CMD_BUF_SIZE): New.
12577 (add_tracepoint_action): Handle static tracepoint actions.
12578 (unprobe_marker_at): New.
12579 (clear_installed_tracepoints): Handle static tracepoints.
12580 (cmd_qtdp): Handle static tracepoints.
12581 (probe_marker_at): New.
12582 (cmd_qtstart): Handle static tracepoints.
12583 (response_tracepoint): Handle static tracepoints.
12584 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12585 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12586 (get_context_regcache): Handle static tracepoints.
12587 (do_action_at_tracepoint): Handle static tracepoint actions.
12588 (traceframe_find_block_type): Handle static trace data blocks.
12589 (traceframe_read_sdata): New.
12590 (download_tracepoints): Download static tracepoint actions.
12591 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12592 (GDB_PROBE_NAME): New.
12593 (ust_ops): New.
12594 (GET_UST_SYM): New.
12595 (USTF): New.
12596 (dlsym_ust): New.
12597 (ust_marker_to_static_tracepoint): New.
12598 (gdb_probe): New.
12599 (collect_ust_data_at_tracepoint): New.
12600 (gdb_ust_probe): New.
12601 (UNIX_PATH_MAX, SOCK_DIR): New.
12602 (gdb_ust_connect_sync_socket): New.
12603 (resume_thread, stop_thread): New.
12604 (run_inferior_command): New.
12605 (init_named_socket): New.
12606 (gdb_ust_socket_init): New.
12607 (cstr_to_hexstr): New.
12608 (next_st): New.
12609 (first_marker, next_marker): New.
12610 (response_ust_marker): New.
12611 (cmd_qtfstm, cmd_qtsstm): New.
12612 (unprobe_marker_at, probe_marker_at): New.
12613 (cmd_qtstmat, gdb_ust_thread): New.
12614 (gdb_ust_init): New.
12615 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12616 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12617 (ST_REGENTRY): New.
12618 (x86_64_st_collect_regmap): New.
12619 (X86_64_NUM_ST_COLLECT_GREGS): New.
12620 (AMD64_RIP_REGNUM): New.
12621 (supply_static_tracepoint_registers): New.
12622 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12623 (ST_REGENTRY): New.
12624 (i386_st_collect_regmap): New.
12625 (i386_NUM_ST_COLLECT_GREGS): New.
12626 (supply_static_tracepoint_registers): New.
12627 * server.c (handle_query): Handle qXfer:statictrace:read.
12628 <qSupported>: Report support for StaticTracepoints, and
12629 qXfer:statictrace:read features.
12630 * server.h (traceframe_read_sdata)
12631 (supply_static_tracepoint_registers): Declare.
12632 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12633 (unpack_varlen_hex): Include in IPA build.
12634 * Makefile.in (ustlibs, ustinc): New.
12635 (IPA_OBJS): Add remote-utils-ipa.o.
12636 ($(IPA_LIB)): Link -ldl and -lpthread.
12637 (UST_CFLAGS): New.
12638 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12639 * config.in, configure: Regenerate.
12640
12641 2010-06-20 Ian Lance Taylor <iant@google.com>
12642 Pedro Alves <pedro@codesourcery.com>
12643
12644 * linux-x86-low.c (always_true): Delete.
12645 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12646 trying to fool the compiler with always_true.
12647
12648 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12649
12650 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12651 conditions in gdbserver.
12652
12653 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12654
12655 * spu-low.c (spu_read_memory): Wrap around local store limit.
12656 (spu_write_memory): Likewise.
12657
12658 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12659
12660 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12661 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12662 LONGEST uses.
12663 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12664 uses.
12665 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12666 uses with LONGEST uses.
12667
12668 2010-06-14 Stan Shebs <stan@codesourcery.com>
12669 Pedro Alves <pedro@codesourcery.com>
12670
12671 Bytecode compiler.
12672
12673 * linux-x86-low.c: Include limits.h.
12674 (add_insns): New.
12675 (always_true): New.
12676 (EMIT_ASM): New.
12677 (EMIT_ASM32): New.
12678 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12679 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12680 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12681 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12682 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12683 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12684 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12685 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12686 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12687 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12688 (amd64_emit_void_call_2): New.
12689 (amd64_emit_ops): New.
12690 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12691 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12692 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12693 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12694 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12695 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12696 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12697 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12698 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12699 (i386_emit_stack_adjust, i386_emit_int_call_1)
12700 (i386_emit_void_call_2): New.
12701 (i386_emit_ops): New.
12702 (x86_emit_ops): New.
12703 (the_low_target): Install x86_emit_ops.
12704 * server.h (struct emit_ops): New.
12705 (get_raw_reg_func_addr): Declare.
12706 (current_insn_ptr, emit_error): Declare.
12707 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12708 (set_trace_state_variable_value): New defines.
12709 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12710 addr_get_trace_state_variable_value and
12711 addr_set_trace_state_variable_value.
12712 (symbol_list): New fields for get_raw_reg,
12713 get_trace_state_variable_value and set_trace_state_variable_value.
12714 (condfn): New typedef.
12715 (struct tracepoint): New field `compiled_cond'.
12716 (do_action_at_tracepoint): Clear compiled_cond.
12717 (get_trace_state_variable_value, set_trace_state_variable_value):
12718 Export in the IPA.
12719 (condition_true_at_tracepoint): If there's a compiled condition,
12720 run that.
12721 (current_insn_ptr, emit_error): New globals.
12722 (struct bytecode_address): New.
12723 (get_raw_reg_func_addr): New.
12724 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12725 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12726 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12727 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12728 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12729 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12730 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12731 (compile_tracepoint_condition, compile_bytecodes): New.
12732 * target.h (emit_ops): Forward declare.
12733 (struct target_ops): New field emit_ops.
12734 (target_emit_ops): New.
12735 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12736 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12737 * linux-low.c (linux_emit_ops): New.
12738 (linux_target_ops): Install it.
12739 * linux-low.h (struct linux_target_ops): New field emit_ops.
12740
12741 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12742
12743 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12744 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12745
12746 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12747 Stan Shebs <stan@codesourcery.com>
12748
12749 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12750 (all): Depend on $(extra_libraries).
12751 (install-only): Install the IPA.
12752 (IPA_OBJS, IPA_LIB): New.
12753 (clean): Remove the IPA lib.
12754 (IPAGENT_CFLAGS): New.
12755 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12756 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12757 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12758 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12759 * configure.ac: Check for atomic builtins support in the compiler.
12760 (IPA_DEPFILES, extra_libraries): Define.
12761 * configure.srv (ipa_obj): Add description.
12762 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12763 (i[34567]86-*-linux*): Set ipa_obj.
12764 (x86_64-*-linux*): Set ipa_obj.
12765 * linux-low.c (stabilizing_threads): New.
12766 (supports_fast_tracepoints): New.
12767 (linux_detach): Stabilize threads before detaching.
12768 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12769 the lwp is either not stabilizing, or is moving out of a jump pad.
12770 (linux_fast_tracepoint_collecting): New.
12771 (maybe_move_out_of_jump_pad): New.
12772 (enqueue_one_deferred_signal): New.
12773 (dequeue_one_deferred_signal): New.
12774 (linux_wait_for_event_1): If moving out of a jump pad, defer
12775 pending signals to later.
12776 (linux_stabilize_threads): New.
12777 (linux_wait_1): Check if threads need moving out of jump pads, and
12778 do it if so.
12779 (stuck_in_jump_pad_callback): New.
12780 (move_out_of_jump_pad_callback): New.
12781 (lwp_running): New.
12782 (linux_resume_one_lwp): Handle moving out of jump pads.
12783 (linux_set_resume_request): Dequeue deferred signals.
12784 (need_step_over_p): Also step over fast tracepoint jumps.
12785 (start_step_over): Also uninsert fast tracepoint jumps.
12786 (finish_step_over): Also reinsert fast tracepoint jumps.
12787 (linux_install_fast_tracepoint_jump): New.
12788 (linux_target_ops): Install linux_stabilize_threads and
12789 linux_install_fast_tracepoint_jump_pad.
12790 * linux-low.h (linux_target_ops) <get_thread_area,
12791 install_fast_tracepoint_jump_pad>: New fields.
12792 (struct lwp_info) <collecting_fast_tracepoint,
12793 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12794 (linux_get_thread_area): Declare.
12795 * linux-x86-low.c (jump_insn): New.
12796 (x86_get_thread_area): New.
12797 (append_insns): New.
12798 (push_opcode): New.
12799 (amd64_install_fast_tracepoint_jump_pad): New.
12800 (i386_install_fast_tracepoint_jump_pad): New.
12801 (x86_install_fast_tracepoint_jump_pad): New.
12802 (the_low_target): Install x86_get_thread_area and
12803 x86_install_fast_tracepoint_jump_pad.
12804 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12805 (struct fast_tracepoint_jump): New.
12806 (fast_tracepoint_jump_insn): New.
12807 (fast_tracepoint_jump_shadow): New.
12808 (find_fast_tracepoint_jump_at): New.
12809 (fast_tracepoint_jump_here): New.
12810 (delete_fast_tracepoint_jump): New.
12811 (set_fast_tracepoint_jump): New.
12812 (uninsert_fast_tracepoint_jumps_at): New.
12813 (reinsert_fast_tracepoint_jumps_at): New.
12814 (set_breakpoint_at): Use write_inferior_memory.
12815 (uninsert_raw_breakpoint): Use write_inferior_memory.
12816 (check_mem_read): Mask out fast tracepoint jumps.
12817 (check_mem_write): Mask out fast tracepoint jumps.
12818 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12819 (set_fast_tracepoint_jump): Declare.
12820 (delete_fast_tracepoint_jump)
12821 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12822 (reinsert_fast_tracepoint_jumps_at): Declare.
12823 * regcache.c: Don't compile many functions when building the
12824 in-process agent library.
12825 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12826 the register buffer in the heap.
12827 (free_register_cache): If the register buffer isn't owned by the
12828 regcache, don't free it.
12829 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12830 pre-existing register caches.
12831 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12832 type.
12833 (convert_ascii_to_int): : Constify `from' parameter type.
12834 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12835 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12836 the needed buffer in-place.
12837 (relocate_instruction): New.
12838 * server.c (handle_query) <qSymbols>: If the target supports
12839 tracepoints, give it a chance of looking up symbols. Report
12840 support for fast tracepoints.
12841 (handle_status): Stabilize threads.
12842 (process_serial_event): Adjust.
12843 * server.h (struct fast_tracepoint_jump): Forward declare.
12844 (struct process_info) <fast_tracepoint_jumps>: New field.
12845 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12846 (decode_X_packet, decode_M_packet): Adjust.
12847 (relocate_instruction): Declare.
12848 (in_process_agent_loaded): Declare.
12849 (tracepoint_look_up_symbols): Declare.
12850 (struct fast_tpoint_collect_status): Declare.
12851 (fast_tracepoint_collecting): Declare.
12852 (force_unlock_trace_buffer): Declare.
12853 (handle_tracepoint_bkpts): Declare.
12854 (initialize_low_tracepoint)
12855 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12856 * target.h (struct target_ops) <stabilize_threads,
12857 install_fast_tracepoint_jump_pad>: New fields.
12858 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12859 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12860 [HAVE_STDINT_H]: Include stdint.h.
12861 (trace_debug_1): Rename to ...
12862 (trace_vdebug): ... this.
12863 (trace_debug): Rename to ...
12864 (trace_debug_1): ... this. Add `level' parameter.
12865 (trace_debug): New.
12866 (ATTR_USED, ATTR_NOINLINE): New.
12867 (IP_AGENT_EXPORT): New.
12868 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12869 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12870 (about_to_request_buffer_space, trace_buffer_is_full)
12871 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12872 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12873 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12874 (traceframe_write_count, traceframes_created)
12875 (trace_state_variables)
12876 New renaming defines.
12877 (struct ipa_sym_addresses): New.
12878 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12879 (symbol_list): New.
12880 (ipa_sym_addrs): New.
12881 (all_tracepoint_symbols_looked_up): New.
12882 (in_process_agent_loaded): New.
12883 (write_e_ipa_not_loaded): New.
12884 (maybe_write_ipa_not_loaded): New.
12885 (tracepoint_look_up_symbols): New.
12886 (debug_threads) [IN_PROCESS_AGENT]: New.
12887 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12888 (UNKNOWN_SIDE_EFFECTS): New.
12889 (stop_tracing): New.
12890 (flush_trace_buffer): New.
12891 (stop_tracing_bkpt): New.
12892 (flush_trace_buffer_bkpt): New.
12893 (read_inferior_integer): New.
12894 (read_inferior_uinteger): New.
12895 (read_inferior_data_pointer): New.
12896 (write_inferior_data_pointer): New.
12897 (write_inferior_integer): New.
12898 (write_inferior_uinteger): New.
12899 (struct collect_static_trace_data_action): Delete.
12900 (enum tracepoint_type): New.
12901 (struct tracepoint) <type>: New field `type'.
12902 <actions_str, step_actions, step_actions_str>: Only include in
12903 GDBserver.
12904 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12905 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12906 (tracepoints): Use IP_AGENT_EXPORT.
12907 (last_tracepoint): Don't include in the IPA.
12908 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12909 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12910 (alloced_trace_state_variables): New.
12911 (trace_state_variables): Use IP_AGENT_EXPORT.
12912 (traceframe_t): Delete unused variable.
12913 (circular_trace_buffer): Don't include in the IPA.
12914 (trace_buffer_start): Delete.
12915 (struct trace_buffer_control): New.
12916 (trace_buffer_free): Delete.
12917 (struct ipa_trace_buffer_control): New.
12918 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12919 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12920 New.
12921 (trace_buffer_ctrl): New.
12922 (TRACE_BUFFER_CTRL_CURR): New.
12923 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12924 Reimplement as macros.
12925 (trace_buffer_wrap): Delete.
12926 (traceframe_write_count, traceframe_read_count)
12927 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12928 (struct tracepoint_hit_ctx) <type>: New field.
12929 (struct fast_tracepoint_ctx): New.
12930 (memory_barrier): New.
12931 (cmpxchg): New.
12932 (record_tracepoint_error): Update atomically in the IPA.
12933 (clear_inferior_trace_buffer): New.
12934 (about_to_request_buffer_space): New.
12935 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12936 updating the same buffer.
12937 (add_tracepoint): Default the tracepoint's type to trap
12938 tracepoint, and orig_size to -1.
12939 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12940 internal variables.
12941 (create_trace_state_variable): New parameter `gdb'. Handle it.
12942 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12943 (cmd_qtdp): Handle fast tracepoints.
12944 (cmd_qtdv): Adjust.
12945 (max_jump_pad_size): New.
12946 (gdb_jump_pad_head): New.
12947 (get_jump_space_head): New.
12948 (claim_jump_space): New.
12949 (sort_tracepoints): New.
12950 (MAX_JUMP_SIZE): New.
12951 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12952 IPA.
12953 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12954 support. Upload fast traceframes, and delete internal IPA
12955 breakpoints.
12956 (stop_tracing_handler): New.
12957 (flush_trace_buffer_handler): New.
12958 (cmd_qtstop): Upload fast tracepoints.
12959 (response_tracepoint): Handle fast tracepoints.
12960 (tracepoint_finished_step): Upload fast traceframes. Set the
12961 tracepoint hit context's tracepoint type.
12962 (handle_tracepoint_bkpts): New.
12963 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12964 type. Add comment about fast tracepoints.
12965 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12966 non-existing action_str field.
12967 (get_context_regcache): Handle fast tracepoints.
12968 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12969 to the regcache.
12970 (fast_tracepoint_from_jump_pad_address): New.
12971 (fast_tracepoint_from_ipa_tpoint_address): New.
12972 (collecting_t): New.
12973 (force_unlock_trace_buffer): New.
12974 (fast_tracepoint_collecting): New.
12975 (collecting): New.
12976 (gdb_collect): New.
12977 (write_inferior_data_ptr): New.
12978 (target_tp_heap): New.
12979 (target_malloc): New.
12980 (download_agent_expr): New.
12981 (UALIGN): New.
12982 (download_tracepoints): New.
12983 (download_trace_state_variables): New.
12984 (upload_fast_traceframes): New.
12985 (IPA_FIRST_TRACEFRAME): New.
12986 (IPA_NEXT_TRACEFRAME_1): New.
12987 (IPA_NEXT_TRACEFRAME): New.
12988 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12989 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12990 (gdb_jump_pad_buffer_end): New.
12991 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12992 (initialize_tracepoint): Adjust.
12993 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12994 buffer. Initialize the low module.
12995 * utils.c (PREFIX, TOOLNAME): New.
12996 (malloc_failure): Use PREFIX.
12997 (error): In the IPA, an error causes an exit.
12998 (fatal, warning): Use PREFIX.
12999 (internal_error): Use TOOLNAME.
13000 (NUMCELLS): Increase to 10.
13001 * configure, config.in: Regenerate.
13002
13003 2010-06-01 Pedro Alves <pedro@codesourcery.com>
13004
13005 * server.c (handle_query) <qSupported>: Do two passes over the
13006 qSupported string to avoid nesting strtok.
13007
13008 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13009
13010 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
13011 (CDEPS): New.
13012 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
13013 -Wl,--dynamic-list.
13014 * configure: Regenerate.
13015 * proc-service.list: New.
13016
13017 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13018
13019 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
13020 New comment.
13021
13022 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
13023
13024 * gdbreplay.c (remote_open): Check error return from socket() call by
13025 its equality to -1 not by it being negative.
13026 * remote-utils.c (remote_open): Likewise.
13027
13028 2010-05-23 Pedro Alves <pedro@codesourcery.com>
13029
13030 * config.h: Regenerate.
13031
13032 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13033
13034 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
13035 doesn't provide PTRACE_GET_THREAD_AREA.
13036
13037 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13038
13039 * linux-m68k-low.c: Include <asm/ptrace.h>
13040 (ps_get_thread_area): Implement.
13041
13042 2010-05-03 Doug Evans <dje@google.com>
13043
13044 * event-loop.c (struct callback_event): New struct.
13045 (callback_list): New global.
13046 (append_callback_event, delete_callback_event): New functions.
13047 (process_callback): New function.
13048 (start_event_loop): Call it.
13049 * remote-utils.c (NOT_SCHEDULED): Define.
13050 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
13051 moved out of readchar.
13052 (readchar): Rewrite. Call reschedule before returning.
13053 (reset_readchar): New function.
13054 (remote_close): Call it.
13055 (process_remaining, reschedule): New functions.
13056 * server.h (callback_handler_func): New typedef.
13057 (append_callback_event, delete_callback_event): Declare.
13058
13059 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13060
13061 * proc-service.c (ps_pglobal_lookup): Use
13062 thread_db_look_up_one_symbol.
13063 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
13064 parameter. Use it instead of all_symbols_looked_up.
13065 * server.h (struct process_info) <all_symbols_looked_up>: Delete
13066 field.
13067 (all_symbols_looked_up): Don't declare.
13068 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
13069 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
13070 field.
13071 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
13072 Set all_symbols_looked_up here.
13073 (thread_db_look_up_one_symbol): New.
13074 (thread_db_get_tls_address): Adjust.
13075 (thread_db_load_search, try_thread_db_load_1): Always allocate the
13076 thread_db object on the heap, and tentatively set it in the
13077 process structure.
13078 (thread_db_init): Don't set all_symbols_looked_up here.
13079 * linux-low.h (thread_db_look_up_one_symbol): Declare.
13080
13081 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13082
13083 * linux-low.c (linux_kill, linux_detach): Adjust.
13084 (status_pending_p_callback): Remove redundant statement. Check
13085 for !TARGET_WAITIKIND_IGNORE, instead of
13086 TARGET_WAITKIND_STOPPED.
13087 (handle_tracepoints): Make sure LWP is locked. Adjust.
13088 (linux_wait_for_event_1): Adjust.
13089 (linux_cancel_breakpoints): New.
13090 (unsuspend_one_lwp): New.
13091 (unsuspend_all_lwps): New.
13092 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
13093 (send_sigstop_callback): Change return type to int, add new
13094 `except' parameter and handle it.
13095 (suspend_and_send_sigstop_callback): New.
13096 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
13097 pass them down. If SUSPEND, also increment the lwp's suspend
13098 count.
13099 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
13100 (need_step_over_p): Don't consider suspended LWPs.
13101 (start_step_over): Adjust.
13102 (proceed_one_lwp): Change return type to int, add new `except'
13103 parameter and handle it.
13104 (unsuspend_and_proceed_one_lwp): New.
13105 (proceed_all_lwps): Use find_inferior instead of
13106 for_each_inferior.
13107 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
13108 also decrement the suspend count of LWPs. Pass `except' down,
13109 instead of hacking its suspend count.
13110 (linux_pause_all): Add `freeze' parameter. Adjust.
13111 (linux_unpause_all): New.
13112 (linux_target_ops): Install linux_unpause_all.
13113 * server.c (handle_status): Adjust.
13114 * target.h (struct target_ops): New fields `unpause_all' and
13115 `cancel_breakpoints'. Add new parameter to `pause_all'.
13116 (pause_all): Add new `freeze' parameter.
13117 (unpause_all): New.
13118 (cancel_breakpoints): New.
13119 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
13120 cancel breakpoints.
13121 (cmd_qtstart): Pause threads.
13122 (stop_tracing): Pause threads, and cancel breakpoints.
13123 * win32-low.c (win32_target_ops): Adjust.
13124
13125 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13126
13127 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13128 the inferior right away from here...
13129 (linux_wait_1): ... to here, and adjust to check the thread's
13130 last_resume_kind instead of the lwp's step or stop_expected flags.
13131
13132 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13133
13134 * README: Use consistent `GDB' and `GDBserver' spellings.
13135
13136 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13137
13138 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13139 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13140 (linux_detach_one_lwp): Assume the lwp is stopped.
13141 (any_thread_of): Delete.
13142 (linux_detach): Stop all lwps here. Don't blindly delete all
13143 breakpoints.
13144 (delete_lwp_callback): New.
13145 (linux_mourn): Delete all lwps of the process that is gone.
13146 (linux_wait_1): Don't delete the last lwp of the process here.
13147 * mem-break.h (mark_breakpoints_out): Declare.
13148 * mem-break.c (mark_breakpoints_out): New.
13149 (free_all_breakpoints): Use it.
13150 * server.c (handle_target_event): If the process is gone, mark
13151 breakpoints out.
13152 * thread-db.c (struct thread_db) <create_bp>: New field.
13153 (thread_db_enable_reporting): Fix prototype. Store a thread event
13154 breakpoint reference in the thread_db struct.
13155 (thread_db_load_search): Clear the thread_db object.
13156 (try_thread_db_load_1): Ditto.
13157 (switch_to_process): New.
13158 (disable_thread_event_reporting): Use it.
13159 (remove_thread_event_breakpoints): New.
13160 (thread_db_detach, thread_db_mourn): Use it.
13161
13162 2010-05-01 Pedro Alves <pedro@codesourcery.com>
13163
13164 * linux-low.c (linux_enable_event_reporting): New.
13165 (linux_wait_for_event_1, handle_extended_wait): Use it.
13166
13167 2010-04-30 Pedro Alves <pedro@codesourcery.com>
13168
13169 * linux-low.c (linux_kill_one_lwp, linux_kill)
13170 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13171 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13172 SIGSTOP even if the LWP is stopped.
13173 (send_sigstop_callback): New.
13174 (stop_all_lwps): Use send_sigstop_callback instead.
13175 (linux_resume_one_thread): Adjust.
13176 (proceed_one_lwp): Still proceed an LWP that the client has
13177 requested to stop, if we haven't reported it as stopped yet. Make
13178 sure that LWPs the client want stopped, have a pending SIGSTOP.
13179
13180 2010-04-26 Doug Evans <dje@google.com>
13181
13182 * server.c (handle_general_set): Make static.
13183
13184 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13185 Print received char after testing for error/eof instead of before.
13186 (input_interrupt): Tweak comment.
13187
13188 2010-04-23 Doug Evans <dje@google.com>
13189
13190 * server.c (start_inferior): Print inferior argv if --debug.
13191
13192 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13193
13194 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13195 * nto-x86-low.c: Include server.h
13196
13197 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13198
13199 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13200 be consistent with other sources of this directory.
13201 (init_registers_amd64): Correct name of source file of this function
13202 in the comment.
13203
13204 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13205
13206 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13207 64-bit executables.
13208
13209 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13210
13211 * win32-i386-low.c: Add 64-bit support.
13212 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13213 (init_registers_amd64): Declare.
13214 (mappings): Add 64-bit version of array.
13215 (init_windows_x86): New function.
13216 (the_low_target): Change init_arch field to init_windows_x86.
13217
13218 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13219
13220 * win32-low.c: Adapt to support also 64-bit architecture.
13221 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13222 (get_image_name): Use SIZE_T type for local variable `done'.
13223 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13224 (toolhelp_get_dll_name): Idem.
13225 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13226 Use uintptr_t typecast to avoid warning.
13227 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13228 (handle_exception): Use phex_nz to avoid warning.
13229 (win32_wait): Remove unused local variable `process'.
13230
13231 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13232
13233 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13234 `amd64-avx.o'.
13235
13236 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13237
13238 * configure.ac: Use `ws2_32' library for srv_mingw.
13239 * configure: Regenerate.
13240 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13241 * remote-utils.c: Likewise.
13242
13243 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13244
13245 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13246 if __x86_64__ is defined.
13247
13248 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13249
13250 * configure: Regenerate.
13251
13252 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13253
13254 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13255 * target.h (target_ops): New get_tib_address field.
13256 * win32-low.h (win32_thread_info): Add thread_local_base field.
13257 * win32-low.c (child_add_thread): Add tlb argument.
13258 Set thread_local_base field to TLB.
13259 (get_child_debug_event): Adapt to child_add_thread change.
13260 (win32_get_tib_address): New function.
13261 (win32_target_ops): Set get_tib_address field to
13262 win32_get_tib_address.
13263 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13264
13265 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13266
13267 * linux-low.c (linux_mourn): Also remove the process.
13268 * server.c (handle_target_event): Don't remove the process here.
13269 * nto-low.c (nto_mourn): New.
13270 (nto_target_ops): Install it.
13271 * spu-low.c (spu_mourn): New.
13272 (spu_target_ops): Install it.
13273 * win32-low.c (win32_mourn): New.
13274 (win32_target_ops): Install it.
13275
13276 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13277
13278 * server.h (buffer_xml_printf): Remove redundant `;'.
13279
13280 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13281
13282 * regcache.c (set_register_cache): Invalidate regcaches before
13283 changing the register cache layout.
13284 (regcache_invalidate_one): Allow a NULL regcache.
13285 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13286 regcaches before changing the register cache layout or the target
13287 regsets.
13288
13289 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13290
13291 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13292 variable warning on Linux/x86-64.
13293
13294 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13295
13296 GDBserver disconnected tracing support.
13297
13298 * linux-low.c (linux_remove_process): Delete.
13299 (add_lwp): Don't set last_resume_kind here.
13300 (linux_kill): Use `mourn'.
13301 (linux_detach): Use `thread_db_detach', and `mourn'.
13302 (linux_mourn): New.
13303 (linux_attach_lwp_1): Adjust comment.
13304 (linux_attach): last_resume_kind moved the thread_info; adjust.
13305 (status_pending_p_callback): Adjust.
13306 (linux_wait_for_event_1): Adjust.
13307 (count_events_callback, select_singlestep_lwp_callback)
13308 (select_event_lwp_callback, cancel_breakpoints_callback)
13309 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13310 (proceed_one_lwp): Adjust.
13311 (linux_async): Add debug output.
13312 (linux_thread_stopped): New.
13313 (linux_pause_all): New.
13314 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13315 linux_pause_all.
13316 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13317 (thread_db_free): Delete declaration.
13318 (thread_db_detach, thread_db_mourn): Declare.
13319 * thread-db.c (thread_db_init): Use thread_db_mourn.
13320 (thread_db_free): Delete, split in two.
13321 (disable_thread_event_reporting): New.
13322 (thread_db_detach): New.
13323 (thread_db_mourn): New.
13324
13325 * server.h (struct thread_info) <last_resume_kind>: New field.
13326 <attached>: Add comment.
13327 <gdb_detached>: New field.
13328 (handler_func): Change return type to int.
13329 (handle_serial_event, handle_target_event): Ditto.
13330 (gdb_connected): Declare.
13331 (tracing): Delete.
13332 (disconnected_tracing): Declare.
13333 (stop_tracing): Declare.
13334
13335 * server.c (handle_query) <qSupported>: Report support for
13336 disconnected tracing.
13337 (queue_stop_reply_callback): Account for running threads.
13338 (gdb_wants_thread_stopped): New.
13339 (gdb_wants_all_threads_stopped): New.
13340 (gdb_reattached_process): New.
13341 (handle_status): Clear the `gdb_detached' flag of all processes.
13342 In all-stop, stop all threads.
13343 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13344 (process_serial_event): If the remote connection breaks, or if an
13345 exit was forced with "monitor exit", force an event loop exit.
13346 Handle disconnected tracing on detach.
13347 (handle_serial_event): Adjust.
13348 (handle_target_event): If GDB isn't connected, forward events back
13349 to the inferior, unless the last process exited, in which case,
13350 exit gdbserver. Adjust interface.
13351
13352 * remote-utils.c (remote_open): Don't block in accept. Instead
13353 register an event loop source on the listen socket file
13354 descriptor. Refactor bits into ...
13355 (listen_desc): ... this new global.
13356 (gdb_connected): ... this new function.
13357 (enable_async_notification): ... this new function.
13358 (handle_accept_event): ... this new function.
13359 (remote_close): Clear remote_desc.
13360
13361 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13362
13363 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13364 New fields.
13365 (mourn_inferior): Define.
13366 (target_process_qsupported): Avoid the dangling else problem.
13367 (thread_stopped): Define.
13368 (pause_all): Define.
13369 (target_waitstatus_to_string): Declare.
13370 * target.c (target_waitstatus_to_string): New.
13371
13372 * tracepoint.c (tracing): Make extern.
13373 (disconnected_tracing): New.
13374 (stop_tracing): Make extern. Handle tracing stops due to GDB
13375 disconnecting.
13376 (cmd_qtdisconnected): New.
13377 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13378 (handle_tracepoint_general_set): Handle QTDisconnected.
13379
13380 * event-loop.c (event_handler_func): Change return type to int.
13381 (process_event): Bail out if the event handler wants the event
13382 loop to stop.
13383 (handle_file_event): Ditto.
13384 (start_event_loop): Bail out if the event handler wants the event
13385 loop to stop.
13386
13387 * nto-low.c (nto_target_ops): Adjust.
13388 * spu-low.c (spu_wait): Don't remove the process here.
13389 (spu_target_ops): Adjust.
13390 * win32-low.c (win32_wait): Don't remove the process here.
13391 (win32_target_ops): Adjust.
13392
13393 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13394
13395 * regcache.c (realloc_register_cache): Invalidate inferior's
13396 regcache before recreating it.
13397
13398 2010-04-09 Pedro Alves <pedro@codesourcery.com>
13399
13400 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13401
13402 2010-04-09 Stan Shebs <stan@codesourcery.com>
13403 Pedro Alves <pedro@codesourcery.com>
13404
13405 * server.h (LONGEST): New.
13406 (struct thread_info) <while_stepping>: New field.
13407 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13408 Declare.
13409 (initialize_tracepoint, handle_tracepoint_general_set)
13410 (handle_tracepoint_query, tracepoint_finished_step)
13411 (tracepoint_was_hit, release_while_stepping_state_list):
13412 (current_traceframe): Declare.
13413 * server.c (handle_general_set): Handle tracepoint packets.
13414 (read_memory): New.
13415 (write_memory): New.
13416 (handle_search_memory_1): Use read_memory.
13417 (handle_query): Report support for conditional tracepoints, trace
13418 state variables, and tracepoint sources. Handle tracepoint
13419 queries.
13420 (main): Initialize the tracepoints module.
13421 (process_serial_event): Handle traceframe reads/writes.
13422
13423 * linux-low.c (handle_tracepoints): New.
13424 (linux_wait_1): Call it.
13425 (linux_resume_one_lwp): Handle while-stepping.
13426 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13427 (linux_target_ops): Install them.
13428 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13429 New field.
13430 * linux-x86-low.c (x86_supports_tracepoints): New.
13431 (the_low_target). Install it.
13432
13433 * mem-break.h (delete_breakpoint): Declare.
13434 * mem-break.c (delete_breakpoint): Make external.
13435
13436 * target.h (struct target_ops): Add `supports_tracepoints',
13437 `read_pc', and `write_pc' fields.
13438 (target_supports_tracepoints): Define.
13439 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13440 (phex_nz): New.
13441
13442 * regcache.h (struct regcache) <registers_owned>: New field.
13443 (init_register_cache, regcache_cpy): Declare.
13444 (regcache_read_pc, regcache_write_pc): Declare.
13445 (register_cache_size): Declare.
13446 (supply_regblock): Declare.
13447 * regcache.c (init_register_cache): New.
13448 (new_register_cache): Use it.
13449 (regcache_cpy): New.
13450 (register_cache_size): New.
13451 (supply_regblock): New.
13452 (regcache_read_pc, regcache_write_pc): New.
13453
13454 * tracepoint.c: New.
13455
13456 * Makefile.in (OBS): Add tracepoint.o.
13457 (tracepoint.o): New rule.
13458
13459 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13460
13461 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13462 (i386-mmx.o): New.
13463 (i386-mmx.c): Likewise.
13464 (i386-mmx-linux.o): Likewise.
13465 (i386-mmx-linux.c): Likewise.
13466
13467 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13468 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13469 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13470 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13471
13472 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13473 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13474 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13475
13476 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13477
13478 * Makefile.in (clean): Updated.
13479 (i386-avx.o): New.
13480 (i386-avx.c): Likewise.
13481 (i386-avx-linux.o): Likewise.
13482 (i386-avx-linux.c): Likewise.
13483 (amd64-avx.o): Likewise.
13484 (amd64-avx.c): Likewise.
13485 (amd64-avx-linux.o): Likewise.
13486 (amd64-avx-linux.c): Likewise.
13487
13488 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13489 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13490 (srv_amd64_regobj): Add amd64-avx.o.
13491 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13492 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13493 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13494 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13495 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13496 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13497 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13498
13499 * i387-fp.c: Include "i386-xstate.h".
13500 (i387_xsave): New.
13501 (i387_cache_to_xsave): Likewise.
13502 (i387_xsave_to_cache): Likewise.
13503 (x86_xcr0): Likewise.
13504
13505 * i387-fp.h (i387_cache_to_xsave): Likewise.
13506 (i387_xsave_to_cache): Likewise.
13507 (x86_xcr0): Likewise.
13508
13509 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13510 * linux-crisv32-low.c (target_regsets): Likewise.
13511 * linux-m68k-low.c (target_regsets): Likewise.
13512 * linux-mips-low.c (target_regsets): Likewise.
13513 * linux-ppc-low.c (target_regsets): Likewise.
13514 * linux-s390-low.c (target_regsets): Likewise.
13515 * linux-sh-low.c (target_regsets): Likewise.
13516 * linux-sparc-low.c (target_regsets): Likewise.
13517 * linux-xtensa-low.c (target_regsets): Likewise.
13518
13519 * linux-low.c: Include <sys/uio.h>.
13520 (regsets_fetch_inferior_registers): Support nt_type.
13521 (regsets_store_inferior_registers): Likewise.
13522 (linux_process_qsupported): New.
13523 (linux_target_ops): Add linux_process_qsupported.
13524
13525 * linux-low.h (regset_info): Add nt_type.
13526 (linux_target_ops): Add process_qsupported.
13527
13528 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13529 and <sys/uio.h>.
13530 (init_registers_i386_avx_linux): New.
13531 (init_registers_amd64_avx_linux): Likewise.
13532 (xmltarget_i386_linux_no_xml): Likewise.
13533 (xmltarget_amd64_linux_no_xml): Likewise.
13534 (PTRACE_GETREGSET): Likewise.
13535 (PTRACE_SETREGSET): Likewise.
13536 (x86_fill_xstateregset): Likewise.
13537 (x86_store_xstateregset): Likewise.
13538 (use_xml): Likewise.
13539 (x86_linux_update_xmltarget): Likewise.
13540 (x86_linux_process_qsupported): Likewise.
13541 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13542 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13543 init_registers_i386_linux here. Call
13544 x86_linux_update_xmltarget.
13545 (the_low_target): Add x86_linux_process_qsupported.
13546
13547 * server.c (handle_query): Call target_process_qsupported.
13548
13549 * target.h (target_ops): Add process_qsupported.
13550 (target_process_qsupported): New.
13551
13552 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13553
13554 * inferiors.c (add_thread): Set last_status kind to
13555 TARGET_WAITKIND_IGNORE.
13556 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13557 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13558 (linux_wait_1): Move `thread' local definition to block that uses
13559 it. Don't NULL initialize `event_child'.
13560 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13561 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13562 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13563
13564 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13565
13566 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13567 an extended waitstatus, or by a watchpoint.
13568 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13569 thread was stepping or has been stopped by a watchpoint.
13570
13571 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13572
13573 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13574 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13575 of another, then delete the previous, and validate all
13576 breakpoints.
13577 (validate_inserted_breakpoint): New.
13578 (delete_disabled_breakpoints): New.
13579 (validate_breakpoints): New.
13580 (check_mem_read): Validate breakpoints before trusting their
13581 shadow. Delete disabled breakpoints.
13582 (check_mem_write): Validate breakpoints before trusting they
13583 should be inserted. Delete disabled breakpoints.
13584 * mem-break.h (validate_breakpoints):
13585 * server.c (handle_query): Validate breakpoints when we see a
13586 qSymbol query.
13587
13588 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13589
13590 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13591 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13592 if we could tell there's a GDB breakpoint at stop_pc.
13593 (need_step_over_p): Don't do a step over if we find a GDB
13594 breakpoint at the resume PC.
13595
13596 * mem-break.c (struct raw_breakpoint): New.
13597 (enum bkpt_type): New type `gdb_breakpoint'.
13598 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13599 fields. New field `raw'.
13600 (find_raw_breakpoint_at): New.
13601 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13602 breakpoint instead.
13603 (set_breakpoint_at): Adjust.
13604 (delete_raw_breakpoint): New.
13605 (release_breakpoint): New.
13606 (delete_breakpoint): Rename to...
13607 (delete_breakpoint_1): ... this. Add proc parameter. Use
13608 release_breakpoint. Return ENOENT.
13609 (delete_breakpoint): Reimplement.
13610 (find_breakpoint_at): Delete.
13611 (find_gdb_breakpoint_at): New.
13612 (delete_breakpoint_at): Delete.
13613 (set_gdb_breakpoint_at): New.
13614 (delete_gdb_breakpoint_at): New.
13615 (gdb_breakpoint_here): New.
13616 (set_reinsert_breakpoint): Use release_breakpoint.
13617 (uninsert_breakpoint): Rename to ...
13618 (uninsert_raw_breakpoint): ... this.
13619 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13620 (reinsert_raw_breakpoint): Change parameter type to
13621 raw_breakpoint.
13622 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13623 instead.
13624 (check_breakpoints): Adjust. Use release_breakpoint.
13625 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13626 (breakpoint_inserted_here): Ditto.
13627 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13628 Don't trust the breakpoint's shadow if it is not inserted.
13629 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13630 (delete_all_breakpoints): Adjust.
13631 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13632 use delete_breakpoint_1.
13633
13634 * mem-break.h (breakpoints_supported): Delete declaration.
13635 (set_gdb_breakpoint_at): Declare.
13636 (gdb_breakpoint_here): Declare.
13637 (delete_breakpoint_at): Delete.
13638 (delete_gdb_breakpoint_at): Declare.
13639
13640 * server.h (struct raw_breakpoint): Forward declare.
13641 (struct process_info): New field `raw_breakpoints'.
13642
13643 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13644 breakpoints.
13645
13646 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13647
13648 * linux-low.c (status_pending_p_callback): Fix comment.
13649 (linux_wait_for_event_1): Move most of the internal breakpoint
13650 handling from here...
13651 (linux_wait_1): ... to here.
13652 (count_events_callback): New.
13653 (select_singlestep_lwp_callback): New.
13654 (select_event_lwp_callback): New.
13655 (cancel_breakpoints_callback): New.
13656 (select_event_lwp): New.
13657 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13658 priority to all LWPs that have had events that should be reported
13659 to the client. Cancel breakpoints when about to reporting the
13660 event to the client, not while stopping lwps. No longer cancel
13661 finished single-steps here.
13662 (cancel_finished_single_step): Delete.
13663 (cancel_finished_single_steps): Delete.
13664
13665 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13666
13667 * mem-break.c (enum bkpt_type): New.
13668 (struct breakpoint): New field `type'.
13669 (set_breakpoint_at): Change return type to struct breakpoint
13670 pointer. Set type to `other_breakpoint' by default.
13671 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13672 in the breakpoint list.
13673 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13674 (reinsert_breakpoint): Rename to ...
13675 (reinsert_raw_breakpoint): ... this.
13676 (reinsert_breakpoints_at): Adjust.
13677 * mem-break.h (struct breakpoint): Declare.
13678 (set_breakpoint_at): Change return type to struct breakpoint
13679 pointer.
13680
13681 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13682
13683 * server.c (handle_query): Assign, not compare.
13684
13685 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13686
13687 Teach linux gdbserver to step-over-breakpoints.
13688
13689 * linux-low.c (can_hardware_single_step): New.
13690 (supports_breakpoints): New.
13691 (handle_extended_wait): If stopping threads, read the stop pc of
13692 the new cloned LWP.
13693 (get_pc): New.
13694 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13695 low target doesn't support retrieving the PC.
13696 (add_lwp): Set last_resume_kind to resume_continue.
13697 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13698 (linux_attach): Don't clear stop_expected. Set the lwp's
13699 last_resume_kind to resume_stop.
13700 (linux_detach_one_lwp): Don't check for removed breakpoints.
13701 (check_removed_breakpoint): Delete.
13702 (status_pending_p): Rename to ...
13703 (status_pending_p_callback): ... this. Don't check for removed
13704 breakpoints. Don't consider threads that are stopped from GDB's
13705 perspective.
13706 (linux_wait_for_lwp): Always read the stop_pc here.
13707 (cancel_breakpoint): New.
13708 (step_over_bkpt): New global.
13709 (linux_wait_for_event_1): Implement stepping over breakpoints.
13710 (gdb_wants_lwp_stopped): New.
13711 (gdb_wants_all_stopped): New.
13712 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13713 single-step traps here. Store the thread's last reported target
13714 wait status.
13715 (send_sigstop): Don't clear stop_expected. Always set it,
13716 instead.
13717 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13718 (cancel_finished_single_step): New.
13719 (cancel_finished_single_steps): New.
13720 (wait_for_sigstop): Don't cancel finished single-step traps here.
13721 (linux_resume_one_lwp): Don't check for removed breakpoints.
13722 Don't set `step' on non-hardware step archs.
13723 (linux_set_resume_request): Ignore resume_stop requests if already
13724 stopping or stopped. Set the lwp's last_resume_kind.
13725 (resume_status_pending_p): Don't check for removed breakpoints.
13726 (need_step_over_p): New.
13727 (start_step_over): New.
13728 (finish_step_over): New.
13729 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13730 requests. Clear the thread's last reported target waitstatus.
13731 Don't use the `suspended' flag. Don't consider pending breakpoints.
13732 (linux_resume): Start a step-over if necessary.
13733 (proceed_one_lwp): New.
13734 (proceed_all_lwps): New.
13735 (unstop_all_lwps): New.
13736 * linux-low.h (struct lwp_info): Rewrite comment for the
13737 `suspended' flag. Add the `stop_pc' field. Delete the
13738 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13739 Add `'last_resume_kind' and `need_step_over' fields.
13740 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13741 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13742 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13743 (set_raw_breakpoint_at): New.
13744 (set_breakpoint_at): Rewrite to use it.
13745 (reinsert_breakpoint_handler): Delete.
13746 (set_reinsert_breakpoint): New.
13747 (reinsert_breakpoint_by_bp): Delete.
13748 (delete_reinsert_breakpoints): New.
13749 (uninsert_breakpoint): Rewrite.
13750 (uninsert_breakpoints_at): New.
13751 (reinsert_breakpoint): Rewrite.
13752 (reinsert_breakpoints_at): New.
13753 (check_breakpoints): Rewrite.
13754 (breakpoint_here): New.
13755 (breakpoint_inserted_here): New.
13756 (check_mem_read): Adjust.
13757 * mem-break.h (breakpoints_supported, breakpoint_here)
13758 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13759 (reinsert_breakpoint_by_bp): Delete declaration.
13760 (delete_reinsert_breakpoints): Declare.
13761 (reinsert_breakpoint): Delete declaration.
13762 (reinsert_breakpoints_at): Declare.
13763 (uninsert_breakpoint): Delete declaration.
13764 (uninsert_breakpoints_at): Declare.
13765 (check_breakpoints): Adjust prototype.
13766 * server.h: Adjust include order.
13767 (struct thread_info): Declare here. Add a `last_status' field.
13768
13769 2010-03-23 Michael Snyder <msnyder@vmware.com>
13770
13771 * server.c (crc32): New function.
13772 (handle_query): Add handling for 'qCRC:' request.
13773
13774 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13775
13776 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13777 lwp had been stopped by a watchpoint.
13778
13779 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13780
13781 * server.h (internal_error): Declare.
13782 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13783 * utils.c (internal_error): New function.
13784
13785 2010-03-15 Andreas Schwab <schwab@redhat.com>
13786
13787 * configure.srv: Fix typo setting srv_regobj.
13788
13789 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13790
13791 * linux-low.c (fetch_register): Avoid passing a non string literal
13792 format to `error'.
13793 (usr_store_inferior_registers): Ditto.
13794
13795 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13796
13797 * linux-low.c (linux_write_memory): Bail out early if peeking
13798 memory failed.
13799
13800 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13801
13802 * linux-low.h (struct lwp_info): New fields
13803 `stopped_by_watchpoint' and `stopped_data_address'.
13804 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13805 here, and cache them in the lwp object.
13806 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13807 directly.
13808 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13809 field.
13810 (linux_stopped_by_watchpoint): Rewrite.
13811 (linux_stopped_data_address): Rewrite.
13812
13813 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13814
13815 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13816 switching the current inferior, not before.
13817
13818 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13819
13820 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13821 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13822 i386-linux.c and amd64-linux.c.
13823 (reg-i386.o): Removed.
13824 (reg-i386.c): Likewise.
13825 (reg-i386-linux.o): Likewise.
13826 (reg-i386-linux.c): Likewise.
13827 (reg-x86-64.o): Likewise.
13828 (reg-x86-64.c): Likewise.
13829 (reg-x86-64-linux.o): Likewise.
13830 (reg-x86-64-linux.c): Likewise.
13831 (i386.o): New.
13832 (i386.c): Likewise.
13833 (i386-linux.o): Likewise.
13834 (i386-linux.c): Likewise.
13835 (amd64.o): Likewise.
13836 (amd64.c): Likewise.
13837 (amd64-linux.o): Likewise.
13838 (amd64-linux.c): Likewise.
13839
13840 * configure.srv (srv_i386_regobj): New.
13841 (srv_i386_linux_regobj): Likewise.
13842 (srv_amd64_regobj): Likewise.
13843 (srv_amd64_linux_regobj): Likewise.
13844 (srv_i386_32bit_xmlfiles): Likewise.
13845 (srv_i386_64bit_xmlfiles): Likewise.
13846 (srv_i386_xmlfiles): Likewise.
13847 (srv_amd64_xmlfiles): Likewise.
13848 (srv_i386_linux_xmlfiles): Likewise.
13849 (srv_amd64_linux_xmlfiles): Likewise.
13850 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13851 srv_xmlfiles to $srv_i386_xmlfiles.
13852 (i[34567]86-*-mingw32ce*): Likewise.
13853 (i[34567]86-*-mingw*): Likewise.
13854 (i[34567]86-*-nto*): Likewise.
13855 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13856 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13857 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13858 (x86_64-*-linux*): Likewise.
13859
13860 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13861 (init_registers_amd64_linux): New.
13862 (x86_arch_setup): Replace init_registers_x86_64_linux with
13863 init_registers_amd64_linux.
13864
13865 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13866
13867 * configure.ac: Check for libdl. If it is not available link against
13868 static libthread_db.
13869 * configure: Regenerate.
13870
13871 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13872
13873 PR9605
13874
13875 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13876 handing a read watchpoint.
13877 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13878
13879 2010-02-12 Doug Evans <dje@google.com>
13880
13881 * linux-low.c (linux_supports_tracefork_flag): Document.
13882 (linux_look_up_symbols): Add comment.
13883
13884 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13885
13886 * regcache.c (supply_register): Clear regcache if buf is NULL.
13887
13888 2010-02-02 Nicolas Roche <roche@sourceware.org>
13889 Joel Brobecker <brobecker@adacore.com>
13890
13891 * inferiors.c (find_inferior): Add function documentation.
13892 (unloaded_dll): Handle the case where the unloaded dll has not
13893 been previously registered in the dll list.
13894
13895 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13896
13897 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13898 (thumb2_breakpoint): New.
13899 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13900
13901 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13902
13903 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13904 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13905 breakpoints.
13906
13907 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13908
13909 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13910
13911 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13912
13913 * linux-s390-low.c (s390_collect_ptrace_register)
13914 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13915
13916 2010-01-21 Doug Evans <dje@google.com>
13917
13918 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13919 (PTRACE_ARG4_TYPE): New macro.
13920 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13921 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13922 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13923 (usr_store_inferior_registers): Ditto.
13924 (linux_read_memory, linux_write_memory): Ditto.
13925 (linux_test_for_tracefork): Ditto.
13926
13927 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13928 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13929
13930 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13931
13932 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13933 target.
13934
13935 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13936
13937 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13938 prototype to take a regcache. Adjust.
13939
13940 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13941
13942 * regcache.h (struct thread_info): Forward declare.
13943 (struct regcache): New.
13944 (new_register_cache): Adjust prototype.
13945 (get_thread_regcache): Declare.
13946 (free_register_cache): Adjust prototype.
13947 (registers_to_string, registers_from_string): Ditto.
13948 (supply_register, supply_register_by_name, collect_register)
13949 (collect_register_as_string, collect_register_by_name): Ditto.
13950 * regcache.c (struct inferior_regcache_data): Delete.
13951 (get_regcache): Rename to ...
13952 (get_thread_regcache): ... this. Adjust. Switch inferior before
13953 fetching registers.
13954 (regcache_invalidate_one): Adjust.
13955 (regcache_invalidate): Fix prototype.
13956 (new_register_cache): Return the new register cache.
13957 (free_register_cache): Change prototype.
13958 (realloc_register_cache): Adjust.
13959 (registers_to_string): Change prototype to take a regcache. Adjust.
13960 (registers_from_string): Ditto.
13961 (register_data): Ditto.
13962 (supply_register): Ditto.
13963 (supply_register_by_name): Ditto.
13964 (collect_register): Ditto.
13965 (collect_register_as_string): Ditto.
13966 (collect_register_by_name): Ditto.
13967 * server.c (process_serial_event): Adjust.
13968 * linux-low.h (regset_fill_func, regset_store_func): Change
13969 prototype.
13970 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13971 Change prototype.
13972 * linux-low.c (get_stop_pc): Adjust.
13973 (check_removed_breakpoint): Adjust.
13974 (linux_wait_for_event): Adjust.
13975 (linux_resume_one_lwp): Adjust.
13976 (fetch_register): Add regcache parameter. Adjust.
13977 (usr_store_inferior_registers): Ditto.
13978 (regsets_fetch_inferior_registers): Ditto.
13979 (regsets_store_inferior_registers): Ditto.
13980 (linux_fetch_registers, linux_store_registers): Ditto.
13981 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13982 regcache. Adjust.
13983 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13984 Ditto.
13985 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13986 prototype to take a regcache.
13987 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13988 * remote-utils.c (convert_ascii_to_int, outreg)
13989 (prepare_resume_reply): Change prototype to take a regcache.
13990 Adjust.
13991 * target.h (struct target_ops) <fetch_registers, store_registers>:
13992 Change prototype to take a regcache.
13993 (fetch_inferior_registers, store_inferior_registers): Change
13994 prototype to take a regcache. Adjust.
13995 * proc-service.c (ps_lgetregs): Adjust.
13996 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13997 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13998 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13999 take a regcache. Adjust.
14000 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
14001 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
14002 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
14003 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
14004 * linux-cris-low.c (cris_get_pc, cris_set_pc)
14005 (cris_cannot_fetch_register):
14006 (cris_breakpoint_at): Change prototype to take a regcache.
14007 Adjust.
14008 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
14009 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
14010 to take a regcache. Adjust.
14011 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
14012 Adjust.
14013 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
14014 take a regcache. Adjust.
14015 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
14016 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
14017 (m68k_set_pc): Change prototype to take a regcache. Adjust.
14018 * linux-mips-low.c (mips_get_pc):
14019 (mips_set_pc): Change prototype to take a regcache. Adjust.
14020 (mips_reinsert_addr): Adjust.
14021 (mips_collect_register): Change prototype to take a regcache.
14022 Adjust.
14023 (mips_supply_register):
14024 (mips_collect_register_32bit, mips_supply_register_32bit)
14025 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
14026 (mips_store_fpregset): Ditto.
14027 * linux-ppc-low.c (ppc_supply_ptrace_register)
14028 (ppc_supply_ptrace_register): Ditto.
14029 (parse_spufs_run): Adjust.
14030 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
14031 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
14032 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
14033 take a regcache. Adjust.
14034 * linux-s390-low.c (s390_collect_ptrace_register)
14035 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
14036 (s390_set_pc): Change prototype to take a regcache. Adjust.
14037 (s390_arch_setup): Adjust.
14038 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
14039 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
14040 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14041 (sparc_fill_gregset, sparc_store_gregset_from_stack)
14042 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
14043 regcache. Adjust.
14044 (sparc_breakpoint_at): Adjust.
14045 * linux-xtensa-low.c (xtensa_fill_gregset):
14046 (xtensa_store_gregset):
14047 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
14048 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
14049 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
14050 prototype to take a regcache. Adjust.
14051 * win32-arm-low.c (arm_fetch_inferior_register)
14052 (arm_store_inferior_register): Change prototype to take a
14053 regcache. Adjust.
14054 * win32-i386-low.c (i386_fetch_inferior_register)
14055 (i386_store_inferior_register): Change prototype to take a
14056 regcache. Adjust.
14057 * win32-low.c (child_fetch_inferior_registers)
14058 (child_store_inferior_registers): Change prototype to take a
14059 regcache. Adjust.
14060 (win32_wait): Adjust.
14061 (win32_fetch_inferior_registers): Change prototype to take a
14062 regcache. Adjust.
14063 (win32_store_inferior_registers): Adjust.
14064 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
14065 store_inferior_register>: Change prototype to take a regcache.
14066
14067 2010-01-20 Doug Evans <dje@google.com>
14068
14069 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
14070 #ifdef.
14071 (linux_wait_for_event1, linux_init_signals): Ditto.
14072 (W_STOPCODE): Provide definition if missing.
14073
14074 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
14075
14076 * linux-low.c (linux_core_of_thread): New.
14077 (compare_ints, show_process, list_threads): New.
14078 (linux_qxfer_osdata): Report threads and cores.
14079 (linux_target_op): Register linux_core_of_thread.
14080 * remote-utils.c (prepare_resume_reply): Report the core.
14081 (buffer_xml_printf): Support %d specifier.
14082 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
14083 New.
14084 (handle_query): Handle qXfer:threads. Announce availability
14085 thereof.
14086 * target.h (struct target_ops): New field core_of_thread.
14087
14088 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
14089
14090 * Makefile.in (clean): Remove new generated files.
14091 (reg-s390.o, reg-s390.c): Remove rules.
14092 (reg-s390x.o, reg-s390x.c): Likewise.
14093 (s390-linux32.o, s390-linux32.c): Add rules.
14094 (s390-linux64.o, s390-linux64.c): Likewise.
14095 (s390x-linux64.o, s390x-linux64.c): Likewise.
14096 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
14097 * linux-s390-low.c: Include <elf.h>.
14098 (HWCAP_S390_HIGH_GPRS): Define if undefined.
14099 (init_registers_s390): Remove prototype.
14100 (init_registers_s390x): Likewise.
14101 (init_registers_s390_linux32): Add prototype.
14102 (init_registers_s390_linux64): Likewise.
14103 (init_registers_s390x_linux64): Likewise.
14104 (s390_num_regs_3264): New define.
14105 (s390_regmap_3264): New global variable.
14106 (s390_cannot_fetch_register): Remove obsolete check.
14107 (s390_cannot_store_register): Likewise.
14108 (s390_collect_ptrace_register): Handle upper/lower register halves.
14109 (s390_supply_ptrace_register): Likewise.
14110 (s390_fill_gregset): Update to register number changes.
14111 (s390_get_hwcap): New routine.
14112 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
14113 Install appropriate regmap and register set.
14114
14115 2010-01-01 Joel Brobecker <brobecker@adacore.com>
14116
14117 * server.c (gdbserver_version): Update copyright year to 2010.
14118 * gdbreplay.c (gdbreplay_version): Likewise.
14119
14120 2009-12-28 Doug Evans <dje@google.com>
14121
14122 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
14123 elf/external.h. Include <elf.h> instead but only if necessary.
14124
14125 2009-12-28 Pedro Alves <pedro@codesourcery.com>
14126
14127 * linux-low.c (linux_remove_process): Remove `detaching'
14128 parameter. Don't release/detach from thread_db here.
14129 (linux_kill): Release/detach from thread_db here, ...
14130 (linux_detach): ... and here, before actually detaching.
14131 (linux_wait_1): ... and here, when a process exits.
14132 * thread-db.c (any_thread_of): New.
14133 (thread_db_free): Switch the current inferior to a thread of the
14134 passed in process.
14135
14136 2009-12-21 Doug Evans <dje@google.com>
14137
14138 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14139
14140 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14141 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14142 warning ifndef __NR_tkill. Move setting of errno there too.
14143 Delete unnecessary resetting of errno after syscall.
14144 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14145
14146 * configure.ac: Check for dladdr.
14147 * config.in: Regenerate.
14148 * configure: Regenerate.
14149 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14150 (try_thread_db_load): Update.
14151
14152 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14153
14154 2009-12-18 Doug Evans <dje@google.com>
14155
14156 * event-loop.c: Include unistd.h if it exists.
14157
14158 * linux-low.c (my_waitpid): Move definition away from being in
14159 between linux_tracefork_child/linux_test_for_tracefork.
14160
14161 * gdb_proc_service.h (psaddr_t): Fix type.
14162 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14163 signature to match glibc.
14164
14165 2009-12-16 Doug Evans <dje@google.com>
14166
14167 * linux-low.c (linux_read_memory): Fix argument to read.
14168
14169 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14170
14171 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14172 events, don't leave current_inferior pointing at null.
14173
14174 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14175
14176 * win32-low.c (LOG): Delete.
14177 (OUTMSG): Output to stderr.
14178 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14179 on compile time LOG macro.
14180 (win32_wait): Fix debug output.
14181
14182 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14183
14184 * win32-low.c (win32_add_one_solib): If the dll name is
14185 "ntdll.dll", prepend the system directory to the dll path.
14186
14187 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14188
14189 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14190
14191 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
14192 Vladimir Prus <vladimir@codesourcery.com>
14193
14194 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14195 * configure.ac: Check for __mcoldfire__ and set
14196 gdb_cv_m68k_is_coldfire.
14197 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14198 reg-cf.o and reg-m68k.o.
14199 * configure: Regenerated.
14200
14201 2009-11-16 Pedro Alves <pedro@codesourcery.com>
14202
14203 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14204 Pass it to thread_db_free.
14205 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14206 proper `detaching' argument to linux_remove_process.
14207 * linux-low.h (thread_db_free): Add `detaching' parameter.
14208 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14209 to thread_db_free.
14210 (thread_db_free): Add `detaching' parameter. Only
14211 call td_ta_clear_event if detaching from process.
14212
14213 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14214
14215 * thread-db.c (thread_db_free): Fix typo.
14216
14217 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14218
14219 PR gdb/10838
14220 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14221
14222 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14223
14224 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14225 with an i686 compiler.
14226 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14227 needed.
14228 * configure: Rebuilt.
14229
14230 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14231
14232 PR gdb/10783
14233
14234 * server.c (handle_search_memory_1): Correct read_addr initialization
14235 in loop for searching subsequent chunks.
14236
14237 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14238
14239 * configure.ac: New --with-libthread-db option.
14240 * thread-db.c: Allow direct dependence on libthread_db.
14241 (thread_db_free): Adjust.
14242 * config.in: Regenerate.
14243 * configure: Likewise.
14244
14245 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14246
14247 PR gdb/10757
14248 * thread-db.c (attach_thread): New function.
14249 (maybe_attach_thread): Return success/failure.
14250 (find_new_threads_callback): Adjust.
14251 (thread_db_find_new_threads): Loop until no new threads.
14252
14253 2009-10-13 Pedro Alves <pedro@codesourcery.com>
14254
14255 * proc-service.c (ps_lgetregs): Formatting.
14256
14257 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14258
14259 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14260 * configure.ac: Adjust.
14261 * linux-low.h (struct process_info_private): Move members to struct
14262 thread_db.
14263 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14264 * linux-low.c (linux_remove_process): Adjust.
14265 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14266 * server.c (handle_query): Move code ...
14267 (handle_monitor_command): ... here. New function.
14268 * target.h (struct target_ops): New member.
14269 * thread-db.c (struct thread_db): New.
14270 (libthread_db_search_path): New variable.
14271 (thread_db_create_event, thread_db_enable_reporting)
14272 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14273 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14274 (try_thread_db_load_1, dladdr_to_soname): New functions.
14275 (try_thread_db_load, thread_db_load_search): New functions.
14276 (thread_db_init): Search for libthread_db.
14277 (thread_db_free): New function.
14278 (thread_db_handle_monitor_command): Likewise.
14279 * config.in: Regenerate.
14280 * configure: Regenerate.
14281
14282 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14283
14284 * spu-low.c (spu_kill): Wait for inferior to terminate.
14285 Call clear_inferiors.
14286 (spu_detach): Call clear_inferiors.
14287
14288 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14289
14290 * aclocal.m4: Regenerate.
14291 * config.in: Likewise.
14292 * configure: Likewise.
14293
14294 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14295
14296 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14297 (parse_spufs_run): New function.
14298 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14299 (ppc_breakpoint_at): Handle SPU breakpoints.
14300
14301 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14302
14303 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14304 (SPUFS_MAGIC): Define.
14305 (spu_enumerate_spu_ids): New function.
14306 (linux_qxfer_spu): New function.
14307 (linux_target_ops): Install linux_qxfer_spu.
14308
14309 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14310
14311 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14312 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14313 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14314 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14315 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14316 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14317 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14318 (init_registers_powerpc_cell32l): Add prototype.
14319 (init_registers_powerpc_cell64l): Likewise.
14320 (ppc_arch_setup): Detect Cell/B.E. architecture.
14321
14322 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14323
14324 * Makefile.in (datarootdir): New variable.
14325
14326 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14327
14328 * linux-low.c (linux_write_memory): Update debugging output.
14329 * Makefile.in (clean): Add new descriptions.
14330 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14331 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14332 * configure.srv: Add new files for arm*-*-linux*.
14333 * linux-arm-low.c: Add new declarations.
14334 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14335 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14336 (HWCAP_VFPv3D16): New.
14337 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14338 instead of __IWMMXT__.
14339 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14340 (arm_arch_setup): New.
14341 (target_regsets): Remove #ifdef. Add VFP regset.
14342 (the_low_target): Use arm_arch_setup.
14343
14344 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14345
14346 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14347 the main thread again.
14348
14349 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14350
14351 Adding Neutrino gdbserver.
14352 * configure: Regenerated.
14353 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14354 * configure.srv (i[34567]86-*-nto*): New target.
14355 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14356 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14357 (nto_comctrl) [__QNX__]: New function.
14358 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14359
14360 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
14361
14362 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14363 srv_tgtobj.
14364
14365 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14366 Pedro Alves <pedro@codesourcery.com>
14367
14368 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14369 don't support CONTEXT_EXTENDED_REGISTERS.
14370 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14371 (the_low_target): Install them.
14372 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14373 failing with ERROR_PIPE_NOT_CONNECTED.
14374
14375 2009-06-30 Doug Evans <dje@google.com>
14376 Pierre Muller <muller@ics.u-strasbg.fr>
14377
14378 Add h/w watchpoint support to x86-linux, win32-i386.
14379 * Makefile.in (SFILES): Add i386-low.c
14380 (i386_low_h): Define.
14381 (i386-low.o): Add dependencies.
14382 (linux-x86-low.o): Add i386-low.h dependency.
14383 (win32-i386-low.o): Ditto.
14384 * i386-low.c: New file.
14385 * i386-low.h: New file.
14386 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14387 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14388 * linux-low.c (linux_add_process): Initialize arch_private.
14389 (linux_remove_process): Free arch_private.
14390 (add_lwp): Initialize arch_private.
14391 (delete_lwp): Free arch_private.
14392 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14393 provided.
14394 * linux-low.h (process_info_private): New member arch_private.
14395 (lwp_info): New member arch_private.
14396 (linux_target_ops): New members new_process, new_thread,
14397 prepare_to_resume.
14398 (ptid_of): New macro.
14399 * linux-x86-low.c: Include stddef.h, i386-low.h.
14400 (arch_process_info): New struct.
14401 (arch_lwp_info): New struct.
14402 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14403 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14404 (i386_dr_low_get_status): New function.
14405 (x86_insert_point, x86_remove_point): New functions.
14406 (x86_stopped_by_watchpoint): New function.
14407 (x86_stopped_data_address): New function.
14408 (x86_linux_new_process, x86_linux_new_thread): New functions.
14409 (x86_linux_prepare_to_resume): New function.
14410 (the_low_target): Add entries for insert_point, remove_point,
14411 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14412 prepare_to_resume.
14413 * server.c (debug_hw_points): New global.
14414 (monitor_show_help): Document set debug-hw-points.
14415 (handle_query): Process "set debug-hw-points".
14416 * server.h (debug_hw_points): Declare.
14417 (paddress): Declare.
14418 * utils.c (NUMCELLS, CELLSIZE): New macros.
14419 (get_sell, xsnprintf, paddress): New functions.
14420 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14421 remove_point, stopped_by_watchpoint, stopped_data_address.
14422 * win32-i386-low.c: Include i386-low.h.
14423 (debug_reg_state): Replaces dr.
14424 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14425 (i386_dr_low_get_status): New function.
14426 (i386_insert_point, i386_remove_point): New functions.
14427 (i386_stopped_by_watchpoint): New function.
14428 (i386_stopped_data_address): New function.
14429 (i386_initial_stuff): Update.
14430 (get_thread_context,set_thread_context,i386_thread_added): Update.
14431 (the_low_target): Add entries for insert_point,
14432 remove_point, stopped_by_watchpoint, stopped_data_address.
14433 * win32-low.c (win32_insert_watchpoint): New function.
14434 (win32_remove_watchpoint): New function.
14435 (win32_stopped_by_watchpoint): New function.
14436 (win32_stopped_data_address): New function.
14437 (win32_target_ops): Add entries for insert_watchpoint,
14438 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14439 * win32-low.h (win32_target_ops): New members insert_point,
14440 remove_point, stopped_by_watchpoint, stopped_data_address.
14441
14442 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14443
14444 * server.c (process_serial_event): Re-return unsupported, not
14445 error, if the type isn't recognized. Re-allow supporting only
14446 insert or remove packets. Also call require_running for
14447 breakpoints. Add missing break statement to default case. Tidy.
14448 * target.h (struct target_ops): Rename insert_watchpoint to
14449 insert_point, and remove_watchpoint to remove_point.
14450
14451 * linux-low.h (struct linux_target_ops): Likewise.
14452 * linux-low.c (linux_insert_watchpoint): Rename to ...
14453 (linux_insert_point): ... this. Adjust.
14454 (linux_remove_watchpoint): Rename to ...
14455 (linux_remove_point): ... this. Adjust.
14456 (linux_target_ops): Adjust.
14457 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14458 (cris_insert_point): ... this.
14459 (cris_remove_watchpoint): Rename to ...
14460 (cris_remove_point): ... this.
14461 (the_low_target): Adjust.
14462
14463 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14464
14465 * server.c (handle_v_kill): Pass signal_pid to
14466 kill_inferior if multi_process is zero.
14467
14468 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14469
14470 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14471 * target.h (target_ops): Comment for *_watchpoint to make it clear
14472 the functions can get types '0' and '1'.
14473
14474 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14475
14476 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14477 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14478 * regcache.c (get_regcache): Likewise.
14479 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14480 * win32-low.c (child_fetch_inferior_registers): Remove check for
14481 regno 0.
14482
14483 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14484 Pedro Alves <pedro@codesourcery.com>
14485
14486 * target.h (struct target_ops) <supports_multi_process>: New
14487 callback.
14488 (target_supports_multi_process): New.
14489 * server.c (handle_query): Even if GDB reports support, only
14490 enable multi-process if the target also supports it. Report
14491 multi-process support only if the target backend supports it.
14492 * linux-low.c (linux_supports_multi_process): New function.
14493 (linux_target_ops): Install it as target_supports_multi_process
14494 callback.
14495
14496 2009-05-24 Doug Evans <dje@google.com>
14497
14498 Global renaming of find_thread_pid to find_thread_ptid.
14499 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14500 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14501 All callers updated.
14502
14503 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14504 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14505 directly.
14506
14507 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14508 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14509 (linux_resume_one_lwp): Ditto.
14510
14511 2009-05-23 Doug Evans <dje@google.com>
14512
14513 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14514 from struct inferior_list_entry * to struct lwp_info *.
14515 All callers updated.
14516
14517 2009-05-13 Doug Evans <dje@google.com>
14518
14519 * linux-x86-low.c: Don't include assert.h.
14520 (x86_siginfo_fixup): Use fatal, not assert.
14521 (x86_arch_setup): Fix comment.
14522
14523 2009-05-12 Doug Evans <dje@google.com>
14524
14525 Biarch support for i386/amd64 gdbserver.
14526 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14527 Add linux-x86-low.c.
14528 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14529 (linux-x86-low.o): Add.
14530 * linux-x86-64-low.c: Delete.
14531 * linux-i386-low.c: Delete.
14532 * linux-x86-low.c: New file.
14533 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14534 linux-x86-low.o.
14535 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14536 linux-x86-low.o.
14537 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14538 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14539 (linux_child_pid_to_exec_file): New function.
14540 (elf_64_header_p, elf_64_file_p): New functions.
14541 (siginfo_fixup): New function.
14542 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14543 give target a chance to convert layout.
14544 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14545 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14546
14547 2009-05-07 Doug Evans <dje@google.com>
14548
14549 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14550 (regsets_store_inferior_registers): Ditto.
14551
14552 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14553
14554 PR server/10048
14555
14556 * linux-low.c (must_set_ptrace_flags): Delete.
14557 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14558 of the global.
14559 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14560 `lwp->must_set_ptrace_flags' instead.
14561 (linux_wait_for_event_1): Set ptrace options here.
14562 (linux_wait_1): ... not here.
14563
14564 2009-04-30 Doug Evans <dje@google.com>
14565
14566 * inferiors.c (started_inferior_callback): New function.
14567 (attached_inferior_callback): New function.
14568 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14569 * server.c (print_started_pid, print_attached_pid): New functions.
14570 (detach_or_kill_for_exit): New function.
14571 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14572 * server.h (have_started_inferiors_p): Declare.
14573 (have_attached_inferiors_p): Declare.
14574
14575 * inferiors.c (remove_process): Fix memory leak, free process.
14576 * linux-low.c (linux_remove_process): New function.
14577 (linux_kill): Call it instead of remove_process.
14578 (linux_detach, linux_wait_1): Ditto.
14579
14580 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14581
14582 * configure.srv: Add x86 Windows CE target.
14583
14584 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14585
14586 * inferiors.c (get_thread_process): Make global.
14587 * server.h (get_thread_process): Add prototype.
14588 * thread-db.c (find_one_thread): Use get_thread_process
14589 instead of current_process.
14590 (thread_db_get_tls_address): Do not crash if called when
14591 thread layer is not yet initialized.
14592
14593 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14594
14595 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14596 * spu-low.c (current_tid): Rename to ...
14597 (current_ptid): ... this.
14598 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14599 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14600 ptid_get_lwp (current_ptid) instead of current_tid.
14601 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14602 instead of current_tid. Use find_process_pid to verify pid
14603 argument is valid. Pass proper argument to remove_process.
14604 (spu_thread_alive): Compare current_ptid instead of current_tid.
14605 (spu_resume): Likewise.
14606
14607 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14608
14609 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14610 variable.
14611
14612 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14613
14614 Implement the multiprocess extensions, and add linux multiprocess
14615 support.
14616
14617 * server.h (ULONGEST): Declare.
14618 (struct ptid, ptid_t): New.
14619 (minus_one_ptid, null_ptid): Declare.
14620 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14621 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14622 (struct inferior_list_entry): Change `id' type from unsigned from
14623 to ptid_t.
14624 (struct sym_cache, struct breakpoint, struct
14625 process_info_private): Forward declare.
14626 (struct process_info): Declare.
14627 (current_process): Declare.
14628 (all_processes): Declare.
14629 (initialize_inferiors): Declare.
14630 (add_thread): Adjust to use ptid_t.
14631 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14632 (add_process, remove_process, find_thread_pid): Declare.
14633 (find_inferior_id): Adjust to use ptid_t.
14634 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14635 (multi_process): Declare.
14636 (push_event): Adjust to use ptid_t.
14637 (read_ptid, write_ptid): Declare.
14638 (prepare_resume_reply): Adjust to use ptid_t.
14639 (clear_symbol_cache): Declare.
14640 * inferiors.c (all_processes): New.
14641 (null_ptid, minus_one_ptid): New.
14642 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14643 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14644 (add_thread): Change unsigned long to ptid. Remove gdb_id
14645 parameter. Adjust.
14646 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14647 (gdb_id_to_thread): Rename to ...
14648 (find_thread_pid): ... this. Change unsigned long to ptid.
14649 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14650 (loaded_dll, pull_pid_from_list): Adjust.
14651 (add_process, remove_process, find_process_pid)
14652 (get_thread_process, current_process, initialize_inferiors): New.
14653 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14654 (struct target_waitstatus) <related_pid>: Ditto.
14655 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14656 return type to int.
14657 (struct target_ops) <join>: Add `pid' argument.
14658 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14659 (struct target_ops) <wait>: Add `ptid' field. Change return type
14660 to ptid.
14661 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14662 (mywait): Add `ptid' argument. Change return type to ptid_t.
14663 (target_pid_to_str): Declare.
14664 * target.c (set_desired_inferior): Adjust to use ptids.
14665 (mywait): Add new `ptid' argument. Adjust.
14666 (target_pid_to_str): New.
14667 * mem-break.h (free_all_breakpoints): Declare.
14668 * mem-break.c (breakpoints): Delelete.
14669 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14670 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14671 to use per-process breakpoint list.
14672 (free_all_breakpoints): New.
14673 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14674 (symbol_cache, all_symbols_looked_up): Delete.
14675 (hexchars): New.
14676 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14677 read_ptid): New.
14678 (prepare_resume_reply): Change ptid argument's type from unsigned
14679 long to ptid_t. Adjust. Implement W;process and X;process.
14680 (free_sym_cache, clear_symbol_cache): New.
14681 (look_up_one_symbol): Adjust to per-process symbol cache. *
14682 * server.c (cont_thread, general_thread, step_thread): Change type
14683 to ptid_t.
14684 (attached): Delete.
14685 (multi_process): New.
14686 (last_ptid): Change type to ptid_t.
14687 (struct vstop_notif) <ptid>: Change type to ptid_t.
14688 (queue_stop_reply, push_event): Change `ptid' argument's type to
14689 ptid_t.
14690 (discard_queued_stop_replies): Add `pid' argument.
14691 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14692 changes. Don't reference the `attached' global.
14693 (attach_inferior): Adjust to mywait interface changes.
14694 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14695 features. Handle and report "multiprocess+". Handle
14696 "qAttached:PID".
14697 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14698 changes.
14699 (handle_v_kill): New.
14700 (handle_v_stopped): Adjust to use target_pid_to_str.
14701 (handle_v_requests): Allow multiple attaches and runs when
14702 multiprocess extensions are in effect. Handle "vKill".
14703 (myresume): Adjust to use ptids.
14704 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14705 (handle_status): Adjust to discard_queued_stop_replies interface
14706 change.
14707 (first_thread_of, kill_inferior_callback)
14708 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14709 (main): Call initialize_inferiors. Adjust to use ptids, killing
14710 and detaching from all inferiors. Handle multiprocess packet
14711 variants.
14712 * linux-low.h: Include gdb_proc_service.h.
14713 (struct process_info_private): New.
14714 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14715 <lwpid_of>: Use ptid_get_lwp.
14716 (get_lwp_thread): Adjust.
14717 (struct lwp_info): Add `dead' member.
14718 (find_lwp_pid): Declare.
14719 * linux-low.c (thread_db_active): Delete.
14720 (new_inferior): Adjust comment.
14721 (inferior_pid): Delete.
14722 (linux_add_process): New.
14723 (handle_extended_wait): Adjust.
14724 (add_lwp): Change unsigned long to ptid.
14725 (linux_create_inferior): Add process to processes table. Adjust
14726 to use ptids. Don't set new_inferior here.
14727 (linux_attach_lwp): Rename to ...
14728 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14729 it. Adjust to use ptids.
14730 (linux_attach_lwp): New.
14731 (linux_attach): Add process to processes table. Don't set
14732 new_inferior here.
14733 (struct counter): New.
14734 (second_thread_of_pid_p, last_thread_of_process_p): New.
14735 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14736 multiple processes.
14737 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14738 processes. Remove process from process table.
14739 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14740 to multiple processes.
14741 (any_thread_of): New.
14742 (linux_detach): Add `pid' argument, and handle it. Remove process
14743 from processes table.
14744 (linux_join): Add `pid' argument. Handle it.
14745 (linux_thread_alive): Change unsighed long argument to ptid_t.
14746 Consider dead lwps as not being alive.
14747 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14748 threads we're not interested in.
14749 (same_lwp, find_lwp_pid): New.
14750 (linux_wait_for_lwp): Change `pid' argument's type from int to
14751 ptid_t. Adjust.
14752 (linux_wait_for_event): Rename to ...
14753 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14754 from int to ptid_t. Adjust.
14755 (linux_wait_for_event): New.
14756 (linux_wait_1): Add `ptid' argument. Change return type to
14757 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14758 that exit from the process table.
14759 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14760 Adjust.
14761 (mark_lwp_dead): New.
14762 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14763 stopping all threads, mark its main lwp as dead.
14764 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14765 ptids.
14766 (fetch_register, usr_store_inferior_registers)
14767 (regsets_fetch_inferior_registers)
14768 (regsets_store_inferior_registers, linux_read_memory)
14769 (linux_write_memory): Inline `inferior_pid'.
14770 (linux_look_up_symbols): Adjust to use per-process
14771 `thread_db_active'.
14772 (linux_request_interrupt): Adjust to use ptids.
14773 (linux_read_auxv): Inline `inferior_pid'.
14774 (initialize_low): Don't reference thread_db_active.
14775 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14776 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14777 (ps_getpid): Return the pid of the current inferior.
14778 * thread-db.c (proc_handle, thread_agent): Delete.
14779 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14780 per-process data.
14781 (find_one_thread): Change argument type to ptid_t. Adjust to
14782 per-process data.
14783 (maybe_attach_thread): Adjust to per-process data and ptids.
14784 (thread_db_find_new_threads): Ditto.
14785 (thread_db_init): Ditto.
14786 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14787 processes table. Adjust to use ptids.
14788 (spu_kill, spu_detach): Adjust interface. Remove process from
14789 processes table.
14790 (spu_join, spu_thread_alive): Adjust interface.
14791 (spu_wait): Adjust interface. Remove process from processes
14792 table. Adjust to use ptids.
14793 * win32-low.c (current_inferior_tid): Delete.
14794 (current_inferior_ptid): New.
14795 (debug_event_ptid): New.
14796 (thread_rec): Take a ptid. Adjust.
14797 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14798 (child_delete_thread): Ditto.
14799 (do_initial_child_stuff): Add `attached' argument. Add process to
14800 processes table.
14801 (child_fetch_inferior_registers, child_store_inferior_registers):
14802 Adjust.
14803 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14804 (win32_attach): Pass 1 to do_initial_child_stuff.
14805 (win32_kill): Adjust interface. Remove process from processes
14806 table.
14807 (win32_detach): Ditto.
14808 (win32_join): Adjust interface.
14809 (win32_thread_alive): Take a ptid.
14810 (win32_resume): Adjust to use ptids.
14811 (get_child_debug_event): Ditto.
14812 (win32_wait): Adjust interface. Remove exiting process from
14813 processes table.
14814
14815 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14816
14817 Non-stop mode support.
14818
14819 * server.h (non_stop): Declare.
14820 (gdb_client_data, handler_func): Declare.
14821 (delete_file_handler, add_file_handler, start_event_loop):
14822 Declare.
14823 (handle_serial_event, handle_target_event, push_event)
14824 (putpkt_notif): Declare.
14825 * target.h (enum resume_kind): New.
14826 (struct thread_resume): Replace `step' field by `kind' field.
14827 (TARGET_WNOHANG): Define.
14828 (struct target_ops) <wait>: Add `options' argument.
14829 <supports_non_stop, async, start_non_stop>: New fields.
14830 (target_supports_non_stop, target_async): New.
14831 (start_non_stop): Declare.
14832 (mywait): Add `options' argument.
14833 * target.c (mywait): Add `options' argument. Print child exit
14834 notifications here.
14835 (start_non_stop): New.
14836 * server.c (non_stop, own_buf, mem_buf): New globals.
14837 (struct vstop_notif): New.
14838 (notif_queue): New global.
14839 (queue_stop_reply, push_event, discard_queued_stop_replies)
14840 (send_next_stop_reply): New.
14841 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14842 interface changes.
14843 (attach_inferior): In non-stop mode, don't wait for the target
14844 here.
14845 (handle_general_set): Handle QNonStop.
14846 (handle_query): When handling qC, return the current general
14847 thread, instead of the first thread of the list.
14848 (handle_query): If the backend supports non-stop mode, include
14849 QNonStop+ in the qSupported query response.
14850 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14851 and non-stop mode.
14852 (handle_v_attach, handle_v_run): Handle non-stop mode.
14853 (handle_v_stopped): New.
14854 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14855 (myresume): Adjust to use resume_kind. Handle non-stop.
14856 (queue_stop_reply_callback): New.
14857 (handle_status): Handle non-stop mode.
14858 (main): Clear non_stop flag on reconnection. Use the event-loop.
14859 Refactor serial protocol handling from here ...
14860 (process_serial_event): ... to this new function. When GDB
14861 selects any thread, select one here. In non-stop mode, wait until
14862 GDB acks all pending events before exiting.
14863 (handle_serial_event, handle_target_event): New.
14864 * remote-utils.c (remote_open): Install remote_desc in the event
14865 loop.
14866 (remote_close): Remove remote_desc from the event loop.
14867 (putpkt_binary): Rename to...
14868 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14869 (putpkt_binary): New as wrapper around putpkt_binary_1.
14870 (putpkt_notif): New.
14871 (prepare_resume_reply): In non-stop mode, don't change the
14872 general_thread.
14873 * event-loop.c: New.
14874 * Makefile.in (OBJ): Add event-loop.o.
14875 (event-loop.o): New rule.
14876
14877 * linux-low.h (pid_of): Moved here.
14878 (lwpid_of): New.
14879 (get_lwp_thread): Use lwpid_of.
14880 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14881 * linux-low.c (pid_of): Delete.
14882 (inferior_pid): Use lwpid_of.
14883 (linux_event_pipe): New.
14884 (target_is_async_p): New.
14885 (delete_lwp): New.
14886 (handle_extended_wait): Use lwpid_of.
14887 (add_lwp): Don't set lwpid field.
14888 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14889 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14890 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14891 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14892 first. Adjust to linux_wait_for_event interface changes. Use
14893 lwpid_of.
14894 (linux_detach): Don't delete the main lwp here.
14895 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14896 (status_pending_p): Don't consider explicitly suspended lwps.
14897 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14898 pointer. Add OPTIONS argument. Change return type to int. Use
14899 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14900 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14901 pointer. Add status pointer argument. Return a pid instead of a
14902 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14903 changes. In non-stop mode, don't switch to a random thread.
14904 (linux_wait): Rename to...
14905 (linux_wait_1): ... this. Add target_options argument, and handle
14906 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14907 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14908 clean exit and signal exit code. Don't stop all threads in
14909 non-stop mode. In all-stop mode, only stop all threads when
14910 reporting a stop to GDB. Handle explicit thread stop requests.
14911 (async_file_flush, async_file_mark): New.
14912 (linux_wait): New.
14913 (send_sigstop): Use lwpid_of.
14914 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14915 interface changes. In non-stop mode, don't switch to a random
14916 thread.
14917 (linux_resume_one_lwp): Use lwpid_of.
14918 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14919 (linux_resume_one_thread): ... this. Handle resume_stop. In
14920 non-stop mode, don't look for pending flag in all threads.
14921 (resume_status_pending_p): Don't consider explicitly suspended
14922 threads.
14923 (my_waitpid): Reimplement. Emulate __WALL.
14924 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14925 Use lwpid_of.
14926 (sigchld_handler, linux_supports_non_stop, linux_async)
14927 (linux_start_non_stop): New.
14928 (linux_target_ops): Register linux_supports_non_stop, linux_async
14929 and linux_start_non_stop.
14930 (initialize_low): Install SIGCHLD handler.
14931 * thread-db.c (thread_db_create_event, find_one_thread)
14932 (thread_db_get_tls_address): Use lwpid_of.
14933 * win32-low.c (win32_detach): Adjust to use resume_kind.
14934 (win32_wait): Add `options' argument.
14935 * spu-low.c (spu_resume): Adjust to use resume_kind.
14936 (spu_wait): Add `options' argument.
14937
14938 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14939
14940 Decouple target code from remote protocol.
14941
14942 * target.h (enum target_waitkind): New.
14943 (struct target_waitstatus): New.
14944 (struct target_ops) <wait>: Return an unsigned long. Take a
14945 target_waitstatus pointer instead of a char pointer.
14946 (mywait): Likewise.
14947 * target.c (mywait): Change prototype to return an unsigned long.
14948 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14949 * server.h (thread_from_wait, old_thread_from_wait): Delete
14950 declarations.
14951 (prepare_resume_reply): Change prototype to take a
14952 target_waitstatus.
14953 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14954 (last_status, last_ptid): New.
14955 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14956 pid instead of a signal.
14957 (attach_inferior): Remove "status" and "signal" parameters.
14958 Adjust.
14959 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14960 not as an address.
14961 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14962 (handle_v_requests, myresume): Remove "status" and "signal"
14963 parameters. Adjust.
14964 (handle_status): New.
14965 (main): Delete local `status'. Adjust.
14966 * remote-utils.c: Include target.h.
14967 (prepare_resume_reply): Change prototype to take a
14968 target_waitstatus. Adjust.
14969
14970 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14971 interface.
14972 * spu-low.c (spu_wait): Adjust.
14973 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14974 Delete.
14975 (win32_wait): Adjust.
14976
14977 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14978
14979 * target.h (struct thread_resume): Delete leave_stopped member.
14980 (struct target_ops): Add a `n' argument to the `resume' callback.
14981 * server.c (start_inferior): Adjust.
14982 (handle_v_cont, myresume): Adjust.
14983 * linux-low.c (check_removed_breakpoint): Adjust to resume
14984 interface change, and to removed leave_stopped field.
14985 (resume_ptr): Delete.
14986 (struct thread_resume_array): New.
14987 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14988 resume interface change.
14989 (linux_continue_one_thread, linux_queue_one_thread)
14990 (resume_status_pending_p): Check if the resume field is NULL
14991 instead of checking the leave_stopped member.
14992 (linux_resume): Adjust to the target resume interface change.
14993 * spu-low.c (spu_resume): Adjust to the target resume interface
14994 change.
14995 * win32-low.c (win32_detach, win32_resume): Ditto.
14996
14997 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14998
14999 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
15000 flag.
15001 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
15002 pending.
15003 (linux_continue_one_thread): Only preserve the stepping flag if
15004 there's a pending breakpoint.
15005
15006 2009-03-31 Pedro Alves <pedro@codesourcery.com>
15007
15008 * server.c (main): After the inferior having exited, call
15009 remote_close before exiting gdbserver.
15010
15011 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
15012
15013 Fix size of FPSCR in Power 7 processors.
15014 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
15015 (PPC_FEATURE_HAS_DFP): New #define.
15016 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
15017 size of the FPSCR.
15018
15019 2009-03-23 Pedro Alves <pedro@codesourcery.com>
15020
15021 * server.c (handle_query) Whitespace and formatting.
15022
15023 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15024
15025 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
15026 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
15027 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
15028 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
15029 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
15030 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
15031 Makefile.in, configure.ac: Fix whitespace throughout.
15032 * configure: Regenerate.
15033
15034 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15035
15036 * inferiors.c (find_inferior): Make it safe for the callback
15037 function to delete the currently iterated inferior.
15038
15039 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15040
15041 * Makefile.in (linuw_low_h): Move higher.
15042 (thread-db.o): Depend on $(linux_low_h).
15043
15044 2009-03-17 Pedro Alves <pedro@codesourcery.com>
15045
15046 Rename "process" to "lwp" throughout.
15047
15048 * linux-low.c (all_processes): Rename to...
15049 (all_lwps): ... this.
15050 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
15051 (add_process): Rename to ...
15052 (add_lwp): ... this. Adjust.
15053 (linux_create_inferior): Adjust.
15054 (linux_attach_lwp): Adjust.
15055 (linux_attach): Adjust.
15056 (linux_kill_one_process): Rename to ...
15057 (linux_kill_one_lwp): ... this. Adjust.
15058 (linux_kill): Adjust.
15059 (linux_detach_one_process): Rename to ...
15060 (linux_detach_one_lwp): ... this. Adjust.
15061 (linux_detach): Adjust.
15062 (check_removed_breakpoint): Adjust.
15063 (status_pending_p): Adjust.
15064 (linux_wait_for_process): Rename to ...
15065 (linux_wait_for_lwp): ... this. Adjust.
15066 (linux_wait_for_event): Adjust.
15067 (send_sigstop): Adjust.
15068 (wait_for_sigstop): Adjust.
15069 (stop_all_processes): Rename to ...
15070 (stop_all_lwps): ... this.
15071 (linux_resume_one_process): Rename to ...
15072 (linux_resume_one_lwp): ... this. Adjust.
15073 (linux_set_resume_request, linux_continue_one_thread)
15074 (linux_queue_one_thread, resume_status_pending_p)
15075 (usr_store_inferior_registers, regsets_store_inferior_registers)
15076 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15077 Adjust.
15078 * linux-low.h (get_process): Rename to ...
15079 (get_lwp): ... this. Adjust.
15080 (get_thread_process): Rename to ...
15081 (get_thread_lwp): ... this. Adjust.
15082 (get_process_thread): Rename to ...
15083 (get_lwp_thread): ... this. Adjust.
15084 (struct process_info): Rename to ...
15085 (struct lwp_info): ... this.
15086 (all_processes): Rename to ...
15087 (all_lwps): ... this.
15088 * proc-service.c (ps_lgetregs): Adjust.
15089 * thread-db.c (thread_db_create_event, find_one_thread)
15090 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
15091
15092 2009-03-14 Pedro Alves <pedro@codesourcery.com>
15093
15094 * server.c (handle_query): Handle "qAttached".
15095
15096 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
15097
15098 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
15099 GPLv3, update license URL.
15100
15101 2009-03-01 Doug Evans <dje@google.com>
15102
15103 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
15104 (server_h): Add gdb_signals.h.
15105 (signals.o): Update.
15106 * server.h (target_signal_from_host,target_signal_to_host_p)
15107 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
15108
15109 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
15110
15111 * remote-utils.c (getpkt): Also generate remote-debug
15112 information if noack_mode is set.
15113
15114 2009-02-06 Pedro Alves <pedro@codesourcery.com>
15115
15116 * server.c (handle_query): Report qXfer:siginfo:read and
15117 qXfer:siginfo:write as supported and handle them.
15118 * target.h (struct target_ops) <qxfer_siginfo>: New field.
15119 * linux-low.c (linux_xfer_siginfo): New.
15120 (linux_target_ops): Set it.
15121
15122 2009-01-26 Pedro Alves <pedro@codesourcery.com>
15123
15124 * server.c (gdbserver_usage): Mention --remote-debug.
15125 (main): Accept '--remote-debug' switch.
15126
15127 2009-01-18 Doug Evans <dje@google.com>
15128
15129 * regcache.c (new_register_cache): No need to check result of xcalloc.
15130 * server.c (handle_search_memory): Back out calls to xmalloc,
15131 result is checked and error is returned to user upon failure.
15132 (handle_query): Ditto. Add more checks for result of malloc.
15133 (handle_v_cont): Check result of malloc, report error back to
15134 user upon failure.
15135 (handle_v_run): Ditto. Call freeargv.
15136 * server.h (freeargv): Declare.
15137 * utils.c (freeargv): New fn.
15138
15139 2009-01-15 Doug Evans <dje@google.com>
15140
15141 * gdbreplay.c (perror_with_name): Make arg const char *.
15142 * server.h (target_signal_to_name): Make return type const char *.
15143 * thread-db.c (thread_db_err_str): Make return type const char *.
15144 * utils.c (perror_with_name): Make arg const char *.
15145
15146 2009-01-14 Pedro Alves <pedro@codesourcery.com>
15147
15148 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15149 when handling a EXIT_PROCESS_DEBUG_EVENT.
15150
15151 2009-01-06 Joel Brobecker <brobecker@adacore.com>
15152
15153 * gdbreplay.c (gdbreplay_version): Update copyright year.
15154 * server.c (gdbserver_version): Likewise.
15155
15156 2009-01-05 Doug Evans <dje@google.com>
15157
15158 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
15159 (handle_extended_wait): Improve comment.
15160
15161 2008-12-13 Doug Evans <dje@google.com>
15162
15163 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15164 * server.h (ATTR_MALLOC): New macro.
15165 (xmalloc,xcalloc,xstrdup): Declare.
15166 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15167 * inferiors.c: Ditto.
15168 * linux-low.c: Ditto.
15169 * mem-break.c: Ditto.
15170 * regcache.c: Ditto.
15171 * remote-utils.c: Ditto.
15172 * server.c: Ditto.
15173 * target.c: Ditto.
15174 * win32-low.c: Ditto.
15175
15176 2008-12-12 Doug Evans <dje@google.com>
15177
15178 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15179 in debugging printf.
15180
15181 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15182
15183 2008-12-09 Doug Evans <dje@google.com>
15184
15185 * linux-low.h (struct process_info): Delete member tid, unused.
15186 * thread-db.c (find_one_thread): Update.
15187 (maybe_attach_thread): Update.
15188
15189 2008-12-02 Pedro Alves <pedro@codesourcery.com>
15190
15191 * target.h (struct target_ops): Add qxfer_osdata member.
15192 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15193 and dirent.h.
15194 (linux_qxfer_osdata): New functions.
15195 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15196 callback.
15197 * server.c (handle_query): Handle "qXfer:osdata:read:".
15198 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15199 (buffer_xml_printf): New functions.
15200 * server.h (struct buffer): New.
15201 (buffer_grow_str, buffer_grow_str0): New macros.
15202 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15203 (buffer_xml_printf): Declare.
15204
15205 2008-11-24 Doug Evans <dje@google.com>
15206
15207 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15208
15209 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15210
15211 * server.c (handle_v_run): Always use the supplied argument list.
15212
15213 2008-11-19 Bob Wilson <bob.wilson@acm.org>
15214
15215 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15216 (xtensa_regmap_table): Add entry for scompare1.
15217
15218 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15219
15220 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15221 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15222 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15223 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15224 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15225 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15226 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15227 XML target descriptions.
15228 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15229 when inferior is running on an ISA 2.05 or later processor. Add
15230 special case to return offset for full 64-bit slot of FPSCR when
15231 in 32-bits.
15232
15233 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15234
15235 * Makefile.in (SFILES, clean): Added sparc64 files.
15236 (reg-sparc64.o, reg-sparc64.c): New.
15237 * configure.srv (sparc*-*-linux*): New configuration.
15238 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15239 syscall arguments for SPARC.
15240 (regsets_store_inferior_registers): Likewise.
15241 * linux-sparc-low.c: New file.
15242
15243 2008-10-21 Doug Evans <dje@google.com>
15244
15245 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15246 (READLINE_DIR,READLINE_DEP): Delete.
15247 (INTERNAL_CFLAGS): Update.
15248 (LINTFLAGS): Update.
15249
15250 2008-10-10 Pedro Alves <pedro@codesourcery.com>
15251
15252 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15253 whole argv from the last run, not just argv[0].
15254
15255 2008-09-08 Pedro Alves <pedro@codesourcery.com>
15256
15257 * regcache.c (new_register_cache): Return NULL if the register
15258 cache size isn't known yet.
15259 (free_register_cache): Avoid dereferencing a NULL regcache.
15260
15261 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15262
15263 * configure.srv: Merge MIPS and MIPS64.
15264
15265 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15266
15267 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15268
15269 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
15270
15271 * Makefile.in: Add required vsx dependencies.
15272
15273 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15274 Declare init_registers_powerpc_vsx32l.
15275 Declare init_registers_powerpc_vsx64l.
15276 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15277 (ppc_arch_setup): Check for VSX in hwcap.
15278 (ppc_fill_vsxregset): New function.
15279 (ppc_store_vsxregset): New function.
15280 Add new VSX entry in regset_info target_regsets.
15281
15282 * configure.srv: Add new VSX dependencies.
15283
15284 2008-08-12 Pedro Alves <pedro@codesourcery.com>
15285
15286 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15287 (remote_open): Set or clear transport_is_reliable.
15288 (putpkt_binary): Don't expect acks in noack mode.
15289 (getpkt): Don't send ack/nac in noack mode.
15290 * server.c (handle_general_set): Handle QStartNoAckMode.
15291 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15292 qSupported.
15293 (main): Reset noack_mode on every connection.
15294 * server.h (noack_mode): Declare.
15295
15296 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15297
15298 * Makefile.in (GDBREPLAY_OBS): New variable.
15299 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15300
15301 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15302 Daniel Jacobowitz <dan@codesourcery.com>
15303
15304 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15305 (usr_store_inferior_registers): Likewise.
15306 (regsets_store_inferior_registers): Likewise.
15307
15308 2008-07-31 Rolf Jansen <rj@surtec.com>
15309 Pedro Alves <pedro@codesourcery.com>
15310
15311 * configure.ac: Check for memmem declaration.
15312 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15313 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15314 (disable_packet_qfThreadInfo): Unconditionally compile.
15315 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15316 * configure, config.in: Regenerate.
15317
15318 2008-07-28 Doug Kwan <dougkwan@google.com>
15319
15320 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15321 (linux_write_memory): Remove declaration of errno.
15322
15323 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15324
15325 * linux-low.c (handle_extended_wait): Do not use "status"
15326 variable uninitialized.
15327
15328 2008-07-07 Pedro Alves <pedro@codesourcery.com>
15329
15330 * server.c (handle_v_attach): Inhibit reporting dll changes.
15331
15332 2008-06-27 Pedro Alves <pedro@codesourcery.com>
15333
15334 * remote-utils.c (prepare_resume_reply): If requested, don't
15335 output "thread:TID" in the T stop reply.
15336
15337 * server.c (disable_packet_vCont, disable_packet_Tthread)
15338 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15339 (handle_query): If requested, disable support for qC, qfThreadInfo
15340 and qsThreadInfo.
15341 (handle_v_requests): If requested, disable support for vCont.
15342 (gdbserver_show_disableable): New.
15343 (main): Handle --disable-packet and --disable-packet=LIST.
15344
15345 * server.h (disable_packet_vCont, disable_packet_Tthread)
15346 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15347
15348 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15349
15350 * server.c (gdbserver_usage): Mention --version.
15351
15352 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15353
15354 * Makefile.in (gdbreplay.o): New rule.
15355
15356 2008-06-06 Joseph Myers <joseph@codesourcery.com>
15357
15358 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15359 message, not gdbserver.
15360
15361 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
15362 Nathan Sidwell <nathan@codesourcery.com>
15363 Joseph Myers <joseph@codesourcery.com>
15364
15365 * acinclude.m4: Include ../../config/acx.m4.
15366 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15367 * configure, config.in: Regenerate.
15368 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15369 * server.c (gdbserver_version): Print PKGVERSION.
15370 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15371 (main): Adjust gdbserver_usage calls.
15372 * gdbreplay.c (version, host_name): Add declarations.
15373 (gdbreplay_version, gdbreplay_usage): New.
15374 (main): Accept --version and --help options.
15375
15376 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15377
15378 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15379 (arm_breakpoint_at): Handle Thumb.
15380 (the_low_target): Add comment.
15381
15382 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15383
15384 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15385
15386 2008-05-09 Doug Evans <dje@google.com>
15387
15388 * server.h (decode_search_memory_packet): Declare.
15389 * remote-utils.c (decode_search_memory_packet): New fn.
15390 * server.c (handle_search_memory_1): New fn.
15391 (handle_search_memory): New fn.
15392 (handle_query): Process qSearch:memory packets.
15393
15394 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15395
15396 * regcache.c (registers_length): Remove.
15397 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15398 full register packet.
15399 * regcache.h (registers_length): Remove prototype.
15400 * server.h (PBUFSIZ): Define to 16384.
15401
15402 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15403
15404 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15405 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15406 powerpc-64l.o, and powerpc-altivec64l.o.
15407 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15408 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15409 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15410 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15411 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15412 to srv_xmlfiles.
15413
15414 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15415 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15416 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15417 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15418 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15419 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15420 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15421 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15422 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15423 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15424 (clean): Update.
15425
15426 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15427 (init_registers_powerpc_32l): ... this new prototype.
15428 (init_registers_powerpc_32): Remove, replace by ...
15429 (init_registers_powerpc_altivec32l): ... this new prototype.
15430 (init_registers_powerpc_e500): Remove, replace by ...
15431 (init_registers_powerpc_e500l): ... this new prototype.
15432 (init_registers_ppc64): Remove, replace by ...
15433 (init_registers_powerpc_64l): ... this new prototype.
15434 (init_registers_powerpc_64): Remove, replace by ...
15435 (init_registers_powerpc_altivec64l): ... this new prototype.
15436 (ppc_num_regs): Set to 73.
15437 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15438 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15439 (ppc_cannot_store_register): Handle orig_r3 and trap.
15440 (ppc_arch_setup): Update init_registers_... calls.
15441 (ppc_fill_gregset): Handle orig_r3 and trap.
15442
15443 * inferiors.c (clear_inferiors): Reset current_inferior.
15444
15445 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15446
15447 * acinclude.m4: Add override.m4.
15448 * configure: Regenerate.
15449
15450 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15451
15452 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15453 initial call to init_register_ppc64.
15454
15455 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15456
15457 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15458 single powerpc*-*-linux* case.
15459 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15460
15461 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15462
15463 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15464 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15465 from reg_xmlfiles.
15466 * linux-ppc-low.c: Include <elf.h>.
15467 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15468 (ppc_hwcap): New global variable.
15469 (ppc_regmap): Remove __SPE__ #ifdef sections.
15470 (ppc_regmap_e500): New global variable.
15471 (ppc_cannot_store_register): Update __SPE__ special case.
15472 (ppc_get_hwcap): New function.
15473 (ppc_arch_setup): Use it to determine whether inferior supports
15474 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15475 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15476 Do not access registers if target does not support AltiVec.
15477 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15478 Do not access registers if target does not support SPE.
15479 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15480
15481 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15482
15483 * linux-low.c (disabled_regsets, num_regsets): New.
15484 (use_regsets_p): Delete.
15485 (linux_wait_for_process): Clear disabled_regsets.
15486 (regsets_fetch_inferior_registers): Check and set it.
15487 (regsets_store_inferior_registers): Likewise.
15488 (linux_fetch_registers, linux_store_registers): Do not use
15489 use_regsets_p.
15490 (initialize_low): Allocate disabled_regsets.
15491
15492 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15493
15494 * Makefile.in (LIBOBJS): New.
15495 (OBS): Use LIBOBJS.
15496 (memmem.o): New rule.
15497 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15498 * configure: Regenerated.
15499
15500 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15501
15502 * server.c (handle_query): Never return "unsupported" for
15503 qXfer:features:read queries.
15504
15505 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15506
15507 * server.c (get_features_xml): Fix inverted condition.
15508 (handle_query): Always support qXfer:feature:read.
15509
15510 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15511
15512 * server.c (wrapper_argv): New.
15513 (start_inferior): Handle wrapper_argv. If set, expect an extra
15514 trap.
15515 (gdbserver_usage): Document --wrapper.
15516 (main): Parse --wrapper.
15517
15518 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15519
15520 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15521 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15522 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15523 (ppc_set_pc): Likewise.
15524 (ppc_arch_setup): New function.
15525 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15526 of collect_register.
15527 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15528
15529 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15530
15531 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15532 instead of linux-ppc64-low.o.
15533 * linux-ppc64-low.c: Remove file.
15534 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15535 (linux-ppc64-low.o): Remove rule.
15536
15537 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15538 (init_registers_powerpc_64): Likewise.
15539 (ppc_regmap): Conditionally define depending on __powerpc64__.
15540 (ppc_cannot_store_register): Do not special-case "fpscr" when
15541 compiled on __powerpc64__.
15542 (ppc_collect_ptrace_register): New function.
15543 (ppc_supply_ptrace_register): New function.
15544 (ppc_breakpoint): Change type to "unsigned int".
15545 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15546 (the_low_target): Conditionally provide initializers for the
15547 arch_setup member depending on __powerpc64__. Install
15548 collect_ptrace_register and supply_ptrace_register members.
15549
15550 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15551
15552 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15553 * server.c (gdbserver_xmltarget): Define.
15554 (get_features_xml): Use it to replace "target.xml" and arch_string.
15555
15556 * configure.srv: Remove srv_xmltarget. Add XML files that were
15557 mentioned there to srv_xmlfiles instead. Remove conditional tests
15558 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15559 srv_xmlfiles and srv_regobj to include all possible choices.
15560 * configure.ac (srv_xmltarget): Remove.
15561 (srv_xmlfiles): Do not add "target.xml".
15562 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15563 checks for supplementary target information.
15564 * configure: Regenerate.
15565 * Makefile.in (XML_TARGET): Remove.
15566 (target.xml): Remove rule.
15567 (clean): Do not clean up target.xml.
15568 (.PRECIOUS): Do not mention target.xml.
15569
15570 * target.h (struct target_ops): Remove arch_string member.
15571 * linux-low.c (linux_arch_string): Remove.
15572 (linux_target_ops): Remove arch_string initializer.
15573 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15574 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15575 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15576 * spu-low.c (spu_arch_string): Remove.
15577 (spu_target_ops): Remove arch_string initializer.
15578 * win32-low.c (win32_arch_string): Remove.
15579 (win32_target_ops): Remove arch_string initializer.
15580 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15581 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15582 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15583
15584 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15585
15586 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15587 by collect_ptrace_register and supply_ptrace_register hooks.
15588 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15589 instead of checking for the_low_target.left_pad_xfer.
15590 (usr_store_inferior_registers): Use collect_ptrace_register callback
15591 instead of checking for the_low_target.left_pad_xfer.
15592
15593 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15594 (s390_supply_ptrace_register): Likewise.
15595 (s390_fill_gregset): Call s390_collect_ptrace_register.
15596 (the_low_target): Update.
15597
15598 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15599 (ppc_supply_ptrace_register): Likewise.
15600 (the_low_target): Update.
15601
15602 * linux-i386-low.c (the_low_target): Update.
15603 * linux-x86-64-low.c (the_low_target): Update.
15604
15605 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15606
15607 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15608 reg-s390.o and reg-s390x.o.
15609
15610 * linux-low.c (new_inferior): New global variable.
15611 (linux_create_inferior, linux_attach): Set it.
15612 (linux_wait_for_process): Call the_low_target.arch_setup after the
15613 target has stopped for the first time.
15614 (initialize_low): Do not call the_low_target.arch_setup.
15615
15616 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15617 (s390_set_pc): Likewise.
15618 (s390_arch_setup): New function.
15619 (the_low_target): Use s390_arch_setup as arch_setup routine.
15620
15621 * regcache.c (realloc_register_cache): New function.
15622 (set_register_cache): Call it for each existing regcache.
15623
15624 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15625
15626 * server.h (init_registers): Remove prototype.
15627
15628 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15629 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15630 instead of init_registers ().
15631 * linux-arm-low.c (init_registers_arm): Add prototype.
15632 (init_registers_arm_with_iwmmxt): Likewise.
15633 (the_low_target): Add initializer for arch_setup field.
15634 * linux-cris-low.c (init_registers_cris): Add prototype.
15635 (the_low_target): Add initializer for arch_setup field.
15636 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15637 (the_low_target): Add initializer for arch_setup field.
15638 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15639 (the_low_target): Add initializer for arch_setup field.
15640 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15641 (the_low_target): Add initializer for arch_setup field.
15642 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15643 (the_low_target): Add initializer for arch_setup field.
15644 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15645 (the_low_target): Add initializer for arch_setup field.
15646 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15647 (init_registers_mips64_linux): Likewise.
15648 (the_low_target): Add initializer for arch_setup field.
15649 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15650 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15651 (the_low_target): Add initializer for arch_setup field.
15652 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15653 (init_registers_powerpc_64): Likewise.
15654 (the_low_target): Add initializer for arch_setup field.
15655 * linux-s390-low.c (init_registers_s390): Add prototype.
15656 (init_registers_s390x): Likewise.
15657 (the_low_target): Add initializer for arch_setup field.
15658 * linux-sh-low.c (init_registers_sh): Add prototype.
15659 (the_low_target): Add initializer for arch_setup field.
15660 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15661 (the_low_target): Add initializer for arch_setup field.
15662 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15663 (the_low_target): Add initializer for arch_setup field.
15664
15665 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15666 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15667 instead of init_registers ().
15668 * win32-arm-low.c (init_registers_arm): Add prototype.
15669 (the_low_target): Add initializer for arch_setup field.
15670 * win32-i386-low.c (init_registers_i386): Add prototype.
15671 (the_low_target): Add initializer for arch_setup field.
15672
15673 * spu-low.c (init_registers_spu): Add prototype.
15674 (initialize_low): Call initialie_registers_spu () instead of
15675 initialize_registers ().
15676
15677 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15678
15679 * server.c (handle_v_requests): When handling the vRun and vAttach
15680 packets, if already debugging a process, don't kill it. Return an
15681 error instead.
15682
15683 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15684
15685 * server.c (handle_query): Correct length check.
15686
15687 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15688
15689 * win32-low.c (do_initial_child_stuff): Add process handle
15690 parameter. Set current_process_handle and current_process_id from the
15691 parameters. Clear globals.
15692 (win32_create_inferior): Don't set current_process_handle and
15693 current_process_id here. Instead pass them on the call to
15694 do_initial_child_stuff.
15695 (win32_attach): Likewise.
15696 (win32_clear_inferiors): New.
15697 (win32_kill): Don't close the current process handle or the
15698 current thread handle here. Instead call win32_clear_inferiors.
15699 (win32_detach): Don't open a new handle to the process. Call
15700 win32_clear_inferiors.
15701 (win32_join): Don't rely on current_process_handle; open a new
15702 handle using the process id.
15703 (win32_wait): Call win32_clear_inferiors when the inferior process
15704 has exited.
15705
15706 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15707
15708 * server.c (monitor_show_help): Add "exit".
15709
15710 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15711
15712 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15713 (clean): Add reg-xtensa.c.
15714 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15715 * configure.srv (xtensa*-*-linux*) New target.
15716 * linux-xtensa-low.c: New.
15717 * xtensa-xtregs.c: New.
15718
15719 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15720
15721 * hostio.c: Don't include errno.h.
15722 (errno_to_fileio_errno): Move to hostio-errno.
15723 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15724 error number outputting to the target->hostio_last_error callback.
15725 (hostio_packet_error): Use FILEIO_EINVAL directly.
15726 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15727 calls to hostio_error.
15728 * hostio-errno.c: New.
15729 * server.h (hostio_last_error_from_errno): Declare.
15730 * target.h (target_ops): Add hostio_last_error member.
15731 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15732 as hostio_last_error handler.
15733 * spu-low.c (spu_target_ops): Likewise.
15734 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15735 (wince_hostio_last_error): New functions.
15736 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15737 as hostio_last_error handler.
15738 (win32_target_ops) [!_WIN32_WCE]: Register
15739 hostio_last_error_from_errno as hostio_last_error handler.
15740 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15741 (hostio-errno.o): New rule.
15742 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15743 * configure.srv (srv_hostio_err_objs): New variable. Default to
15744 hostio-errno.o.
15745 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15746 * configure: Regenerate.
15747
15748 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15749
15750 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15751 (linux_kill, linux_detach): Clean up the process list.
15752 * remote-utils.c (remote_open): Improve port number parsing.
15753 (putpkt_binary, input_interrupt): Only send interrupts if the target
15754 is running.
15755 * server.c (extended_protocol): Make static.
15756 (attached): Define earlier.
15757 (exit_requested, response_needed, program_argv): New variables.
15758 (target_running): New.
15759 (start_inferior): Clear attached here.
15760 (attach_inferior): Set attached here.
15761 (require_running): Define.
15762 (handle_query): Use require_running and target_running. Implement
15763 "monitor exit".
15764 (handle_v_attach, handle_v_run): New.
15765 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15766 (gdbserver_usage): Update.
15767 (main): Redo argument parsing. Handle --debug and --multi. Handle
15768 --attach along with other options or after the port. Save
15769 program_argv. Support no initial program. Resynchronize
15770 communication with GDB after an error. Handle "monitor exit".
15771 Use require_running and target_running. Always allow the extended
15772 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15773 restart in extended mode.
15774 * README: Refer to the GDB manual. Update --attach usage.
15775
15776 2007-12-20 Andreas Schwab <schwab@suse.de>
15777
15778 * linux-low.c (STACK_SIZE): Define.
15779 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15780 (linux_test_for_tracefork): Likewise.
15781
15782 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15783
15784 * linux-low.c (linux_wait_for_event): Update messages. Do not
15785 reinsert auto-delete breakpoints.
15786 * mem-break.c (struct breakpoint): Change return type of handler to
15787 int.
15788 (set_breakpoint_at): Update handler type.
15789 (reinsert_breakpoint_handler): Return 1 instead of calling
15790 delete_breakpoint.
15791 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15792 setting a new one.
15793 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15794 * mem-break.h (set_breakpoint_at): Update handler type.
15795 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15796 * win32-low.c (auto_delete_breakpoint): New.
15797 (get_child_debug_event): Use it.
15798
15799 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15800
15801 * configure.ac: Check for pread and pwrite.
15802 * hostio.c (handle_pread): Fall back to lseek and read.
15803 (handle_pwrite): Fall back to lseek and write.
15804 * config.in, configure: Regenerated.
15805
15806 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15807
15808 * server.c (myresume): Add own_buf argument.
15809 (main): Update calls.
15810
15811 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15812
15813 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15814 * remote-utils.c (remote_open): Do not call disable_async_io.
15815 (block_async_io): Delete.
15816 (unblock_async_io): Make static.
15817 (initialize_async_io): New.
15818 * server.c (handle_v_cont): Handle async I/O here.
15819 (myresume): Likewise. Move other common resume tasks here...
15820 (main): ... from here. Call initialize_async_io. Disable async
15821 I/O before the main loop.
15822 * server.h (initialize_async_io): Declare.
15823 (block_async_io, unblock_async_io): Delete prototypes.
15824 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15825
15826 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15827
15828 * remote-utils.c (readchar): Allow binary data in received messages.
15829
15830 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15831
15832 * win32-low.c (attaching): New global.
15833 (win32_create_inferior): Clear the `attaching' global.
15834 (win32_attach): Set the `attaching' global.
15835 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15836 attaching. Only set a breakpoint at the entry point if not
15837 attaching.
15838
15839 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15840
15841 * server.c (main): Don't report dll events on the initial
15842 connection on attaches.
15843
15844 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15845
15846 * server.c (main): Relax numerical bases supported for the pid of
15847 the --attach command line argument.
15848
15849 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15850
15851 * win32-low.c (win32_attach): Call OpenProcess before
15852 DebugActiveProcess, not after. Add last error output to error
15853 call.
15854
15855 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15856
15857 * win32-low.c (win32_get_thread_context)
15858 (win32_set_thread_context): New functions.
15859 (thread_rec): Use win32_get_thread_context.
15860 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15861 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15862 field.
15863
15864 2007-12-03 Leo Zayas
15865 Pedro Alves <pedro_alves@portugalmail.pt>
15866
15867 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15868 global variables.
15869 (child_add_thread): Minor cleanup.
15870 (child_continue): Resume artificially suspended threads before
15871 calling ContinueDebugEvent.
15872 (suspend_one_thread): New.
15873 (fake_breakpoint_event): New.
15874 (get_child_debug_event): Change return type to int. Check here if
15875 gdb sent an interrupt request. If a soft interrupt was requested,
15876 fake a breakpoint event. Return 0 if there is no event to handle,
15877 and 1 otherwise.
15878 (win32_wait): Don't check here if gdb sent an interrupt request.
15879 Ensure there is a valid event to handle.
15880 (win32_request_interrupt): Add soft interruption method as last
15881 resort.
15882
15883 2007-12-03 Leo Zayas
15884 Pedro Alves <pedro_alves@portugalmail.pt>
15885
15886 * win32-low.h (win32_thread_info): Add descriptions to the
15887 structure members. Replace `suspend_count' counter by a
15888 `suspended' flag.
15889 * win32-low.c (thread_rec): Update condition of when to get the
15890 context from the inferior. Rely on ContextFlags being set if it
15891 has already been retrieved. Only suspend the inferior thread if
15892 we haven't already. Warn if that fails.
15893 (continue_one_thread): s/suspend_count/suspended/. Only call
15894 ResumeThread once. Warn if that fails.
15895
15896 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15897
15898 * win32-low.c (win32_wait): Don't read from the inferior when it
15899 has already exited.
15900
15901 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15902
15903 * Makefile.in (win32_low_h): New variable.
15904 (win32-low.o): Add dependency on $(win32_low_h).
15905 (win32-arm-low.o, win32-i386-low.o): New rules.
15906
15907 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15908
15909 * hostio.c: Correct copyright year.
15910
15911 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15912
15913 * Makefile.in (OBS): Add hostio.o.
15914 (hostio.o): New rule.
15915 * server.h (handle_vFile): Declare.
15916 * hostio.c: New file.
15917 * server.c (handle_v_requests): Take packet_len and new_packet_len
15918 for binary packets. Call handle_vFile.
15919 (main): Update call to handle_v_requests.
15920
15921 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15922
15923 * linux-low.c: Include <sched.h>.
15924
15925 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15926
15927 * linux-low.c (linux_tracefork_grandchild): New.
15928 (linux_tracefork_child): Use clone.
15929 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15930
15931 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15932
15933 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15934
15935 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15936
15937 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15938
15939 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15940
15941 * inferiors.c (change_inferior_id): Delete.
15942 (add_pid_to_list, pull_pid_from_list): New.
15943 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15944 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15945 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15946 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15947 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15948 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15949 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15950 (using_threads): Always set to 1.
15951 (handle_extended_wait): New.
15952 (add_process): Do not set TID.
15953 (linux_create_inferior): Set must_set_ptrace_flags.
15954 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15955 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15956 (linux_thread_alive): Rename TID argument to LWPID.
15957 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15958 (linux_wait_for_event): Do not use TID or check using_threads. Update
15959 call to dead_thread_notify. Call handle_extended_wait.
15960 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15961 (send_sigstop): Delete sigstop_sent.
15962 (wait_for_sigstop): Avoid TID.
15963 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15964 (linux_test_for_tracefork): New.
15965 (linux_lookup_signals): Use thread_db_active and
15966 linux_supports_tracefork_flag.
15967 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15968 * linux-low.h (get_process_thread): Avoid TID.
15969 (struct process_ifo): Move thread_known and tid to the end. Remove
15970 sigstop_sent.
15971 (linux_attach_lwp, thread_db_init): Update prototypes.
15972 * server.h (change_inferior_id): Delete prototype.
15973 (add_pid_to_list, pull_pid_from_list): New prototypes.
15974 * thread-db.c (thread_db_use_events): New.
15975 (find_first_thread): Rename to...
15976 (find_one_thread): ...this. Update callers and messages. Do not
15977 call fatal. Check thread_db_use_events. Do not call
15978 change_inferior_id or new_thread_notify.
15979 (maybe_attach_thread): Update. Do not call new_thread_notify.
15980 (thread_db_init): Set thread_db_use_events. Check use_events.
15981 * utils.c (fatal, warning): Correct message prefix.
15982
15983 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15984
15985 * Makefile.in (clean): Remove new files.
15986 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15987 (powerpc-64.o, powerpc-64.c): New rules.
15988 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15989 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15990 with SPE.
15991 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15992 SPE targets.
15993 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15994 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15995 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15996 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15997 (target_regsets): Add AltiVec and SPE register sets.
15998 * configure.ac: Check for AltiVec and SPE.
15999 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
16000 (ppc_fill_vrregset, ppc_store_vrregset): New.
16001 (target_regsets): Add AltiVec register set.
16002 * configure: Regenerated.
16003
16004 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
16005
16006 * linux-low.c (O_LARGEFILE): Define.
16007 (linux_read_memory): Use /proc/PID/mem.
16008 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
16009 * configure, config.in: Regenerated.
16010
16011 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16012
16013 * linux-low.c (linux_wait_for_event): Do not pass signals while
16014 single-stepping.
16015
16016 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16017
16018 * win32-low.c (create_process): New.
16019 (win32_create_inferior): Use create_process instead of
16020 CreateProcess. If create_process failed retry appending an ".exe"
16021 suffix. Store the GetLastError result immediatelly after
16022 create_process calls and use it on the call to error.
16023
16024 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16025
16026 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
16027
16028 2007-08-23 Joel Brobecker <brobecker@adacore.com>
16029
16030 * configure.ac: Switch license to GPLv3.
16031
16032 2007-08-01 Michael Snyder <msnyder@access-company.com>
16033
16034 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
16035
16036 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
16037
16038 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
16039 typedef.
16040 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
16041 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
16042 CloseToolhelp32Snapshot.
16043 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
16044 CloseToolhelp32Snapshot.
16045
16046 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
16047
16048 * server.c (main): Check for inferior exit before main loop.
16049
16050 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
16051
16052 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
16053 instead of on tmp_desc.
16054
16055 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
16056 Daniel Jacobowitz <dan@codesourcery.com>
16057
16058 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
16059 (add_thread): Minor cleanups.
16060 (clear_inferiors): Move lower in the file. Clear the DLL
16061 list.
16062 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
16063 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
16064 (xml_escape_text): New.
16065 * server.c (handle_query): Handle qXfer:libraries:read. Report it
16066 for qSupported.
16067 (handle_v_cont): Report errors.
16068 (gdbserver_version): Update.
16069 (main): Correct size of own_buf. Do not report initial DLL events.
16070 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
16071 (unloaded_dll, xml_escape_text): New.
16072 * win32-low.c (enum target_waitkind): Update comments.
16073 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
16074 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
16075 (win32_EnumProcessModules, win32_GetModuleInformation)
16076 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
16077 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
16078 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
16079 (win32_Module32First, win32_Module32Next, load_toolhelp)
16080 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
16081 (get_child_debug_event): Handle DLL events.
16082 (win32_wait): Likewise.
16083
16084 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16085
16086 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
16087 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
16088
16089 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16090
16091 * win32-low.c (handle_output_debug_string): Ignore event if not
16092 waiting.
16093
16094 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16095
16096 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
16097
16098 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
16099
16100 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
16101
16102 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
16103
16104 * inferiors.c (change_inferior_id): Add comment.
16105 * linux-low.c (check_removed_breakpoint): Add an early
16106 prototype. Improve debug output.
16107 (linux_attach): Doc update.
16108 (linux_detach_one_process, linux_detach): Clean up before releasing
16109 each process.
16110 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
16111 * linux-low.h (struct process_info): Doc improvement.
16112 * mem-break.c (delete_all_breakpoints): New.
16113 * mem-break.h (delete_all_breakpoints): New prototype.
16114 * thread-db.c (find_first_thread): New.
16115 (thread_db_create_event): Call it instead of
16116 thread_db_find_new_threads. Clean up unused variables.
16117 (maybe_attach_thread): Remove first thread handling.
16118 (thread_db_find_new_threads): Use find_first_thread.
16119 (thread_db_get_tls_address): Likewise.
16120
16121 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
16122
16123 * thread-db.c (thread_db_find_new_threads): Add prototype.
16124 (thread_db_create_event): Check for the main thread before adding
16125 a new thread.
16126 (maybe_attach_thread): Only enable event reporting if TID == 0.
16127 (thread_db_get_tls_address): Check for new threads.
16128
16129 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16130
16131 * linux-low.c (linux_create_inferior): Try execv before execvp.
16132 * spu-low.c (spu_create_inferior): Likewise.
16133
16134 2007-06-13 Mike Frysinger <vapier@gentoo.org>
16135
16136 * linux-low.c (linux_create_inferior): Change execv to execvp.
16137 * spu-low.c (spu_create_inferior): Likewies.
16138
16139 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16140
16141 * Makefile.in (clean): Clean new files instead of deleted ones.
16142 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16143 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16144 rules.
16145 * configure.srv: Specify XML files and new regformats for MIPS and
16146 MIPS64 GNU/Linux.
16147 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16148 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16149 an entry for the restart register.
16150 (mips_cannot_fetch_register, mips_cannot_store_register)
16151 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16152 register names to match the XML descriptions.
16153 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16154 restart register instead of $0.
16155
16156 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16157 Markus Deuling <deuling@de.ibm.com>
16158
16159 * remote-utils.c (decode_xfer_write): New function.
16160 * server.h (decode_xfer_write): Add prototype.
16161 * server.c (handle_query): Add PACKET_LEN argument. Support
16162 qXfer:spu:read and qXfer:spu:write packets.
16163 (main): Pass packet_len to handle_query.
16164 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16165 * target.h (target_ops): Add qxfer_spu.
16166
16167 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16168
16169 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16170 accessing non-seekable spufs files.
16171
16172 2007-05-16 Markus Deuling <deuling@de.ibm.com>
16173
16174 * server.c (handle_query): Add reply for qC packet.
16175
16176 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16177 Leo Zayas <lerele@champenstudios@com>
16178
16179 * server.h (check_remote_input_interrupt_request): New function.
16180 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16181 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16182 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16183 (check_remote_input_interrupt_request): New function.
16184 * server.h (check_remote_input_interrupt_request): Declare.
16185 * win32-low.c (winapi_DebugBreakProcess,
16186 winapi_GenerateConsoleCtrlEvent): New typedefs.
16187 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16188 to 250 ms.
16189 (win32_wait): Check for remote interrupt request
16190 with check_remote_input_interrupt_request.
16191 (win32_request_interrupt): New function.
16192 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16193
16194 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16195
16196 * win32-low.c (debug_registers_changed,
16197 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16198 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16199 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16200 (thread_rec): Get context using the low target.
16201 (child_add_thread): Call thread_added on the low target,
16202 which does the same thing.
16203 (regptr): Delete.
16204 (do_initial_child_stuff): Remove debug registers references.
16205 Set context using the low target. Resume threads after
16206 setting the contexts.
16207 (child_continue): Remove dead variable. Remove debug
16208 registers references.
16209 (child_fetch_inferior_registers): Go through the low target.
16210 (do_child_store_inferior_registers): Remove.
16211 (child_store_inferior_registers): Go through the low target.
16212 (win32_resume): Remove debug registers references.
16213 Set context using the low target.
16214 (handle_exception): Change return type to void. Don't record
16215 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16216 first chance exception.
16217 (get_child_debug_event): Change return type to void. Remove
16218 goto loop. Always return after waiting for debug event.
16219 (win32_wait): Convert to switch statement. Handle spurious
16220 events.
16221
16222 * win32-i386-low.c (debug_registers_changed,
16223 debug_registers_used): New.
16224 (initial_stuff): Rename to ...
16225 (i386_initial_stuff): ... this. Clear debug registers
16226 state variables.
16227 (store_debug_registers): Delete.
16228 (i386_get_thread_context): New.
16229 (load_debug_registers): Delete.
16230 (i386_set_thread_context): New.
16231 (i386_thread_added): New.
16232 (single_step): Rename to ...
16233 (i386_single_step): ... this.
16234 (do_fetch_inferior_registers): Rename to ...
16235 (i386_fetch_inferior_register): ... this.
16236 (i386_store_inferior_register): New.
16237 (the_low_target): Adapt to new interface.
16238
16239 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16240 (arm_get_thread_context): New.
16241 (arm_set_thread_context): New.
16242 (regptr): New.
16243 (do_fetch_inferior_registers): Rename to ...
16244 (arm_fetch_inferior_register): ... this.
16245 (arm_store_inferior_register): New.
16246 (arm_wince_breakpoint): Reimplement as unsigned long.
16247 (arm_wince_breakpoint_len): Define.
16248 (the_low_target): Adapt to new interface.
16249
16250 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16251 load_debug_registers. Add get_thread_context, set_thread_context,
16252 thread_added and store_inferior_register. Rename
16253 fetch_inferior_registers to fetch_inferior_register.
16254 (regptr): Remove declaration.
16255
16256 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16257
16258 * linux-low.c (linux_detach): Change return type to int. Return 0.
16259 * spu-low.c (spu_detach): Likewise.
16260
16261 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16262
16263 * target.h (target_ops): Change return type of detach to int.
16264 Add join.
16265 (join_inferior): New.
16266 * server.c (main): Don't skip detach support on mingw32.
16267 If the inferior doesn't support detaching return error.
16268 Call join_inferior instead of using waitpid.
16269 * linux-low.c (linux_join): New.
16270 (linux_target_op): Add linux_join.
16271 * spu-low.c (spu_join): New.
16272 (spu_target_ops): Add spu_join.
16273 * win32-low.c (win32_detach): Adapt to new interface.
16274 Reopen current_process_handle before detaching. Issue a child
16275 resume before detaching.
16276 (win32_join): New.
16277 (win32_target_op): Add win32_join.
16278
16279 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16280
16281 * win32-low.c (win32-attach): Fix return value.
16282 * target.h (target_ops): Describe ATTACH return values.
16283
16284 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16285
16286 * win32-low.c (GETPROCADDRESS): Define.
16287 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16288 (winapi_DebugSetProcessKillOnExit): Likewise.
16289 (win32_create_inferior): Force usage of ansi CreateProcessA.
16290 (win32_attach): Use GETPROCADDRESS.
16291 (win32_detach): Likewise.
16292
16293 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16294
16295 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16296
16297 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16298
16299 * win32-low.c: Commit leftover changes from 2007-03-29.
16300
16301 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16302
16303 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16304 fields short instead of int. Add explicit padding.
16305 (i387_cache_to_fsave): Remove unnecessary casts.
16306 (i387_fsave_to_cache): Doc fix.
16307 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16308
16309 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16310
16311 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16312 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16313
16314 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16315
16316 * configure.srv (arm*-*-mingw32ce*): Move near the other
16317 arm targets.
16318
16319 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16320
16321 * configure.ac: Add errno checking.
16322 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16323 sys/file.h and malloc.h.
16324 (AC_CHECK_DECLS): Add perror.
16325 (srv_mingwce): Handle.
16326 * configure.srv (i[34567]86-*-cygwin*): Add
16327 win32-i386-low.o to srv_tgtobj.
16328 (i[34567]86-*-mingw*): Likewise.
16329 (arm*-*-mingw32ce*): Add case.
16330 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16331 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16332 [__MINGW32CE__] (strerror): New function.
16333 [__MINGW32CE__] (errno): Define to GetLastError.
16334 [__MINGW32CE__] (COUNTOF): New macro.
16335 (remote_open): Remove extra close call.
16336 * mem-break.c (delete_breakpoint_at): New function.
16337 * mem-break.h (delete_breakpoint_at): Declare.
16338 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16339 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16340 [USE_WIN32API] (read, write): Add char* casts.
16341 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16342 * server.h: Include wincecompat.h on Windows CE.
16343 [HAVE_ERRNO_H]: Check.
16344 (perror): Declare if not declared.
16345 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16346 (perror_with_name): Remove errno declaration.
16347 * wincecompat.h: New.
16348 * wincecompat.c: New.
16349 * win32-low.h: New.
16350 * win32-arm-low.c: New.
16351 * win32-i386-low.c: New.
16352 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16353 (OUTMSG2): Make it safe.
16354 (_T): New macro.
16355 (COUNTOF): New macro.
16356 (NUM_REGS): Get it from the low target.
16357 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16358 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16359 (thread_rec): Let low target handle debug registers.
16360 (child_add_thread): Likewise.
16361 (child_init_thread_list): Likewise.
16362 (continue_one_thread): Likewise.
16363 (regptr): New.
16364 (do_child_fetch_inferior_registers): Move to ...
16365 * win32-i386-low.c: ... here, and rename to ...
16366 (do_fetch_inferior_registers): ... this.
16367 * win32-low.c (child_fetch_inferior_registers):
16368 Go through the low target.
16369 (do_child_store_inferior_registers): Use regptr.
16370 (strwinerror): New function.
16371 (win32_create_inferior): Handle Windows CE.
16372 Use strwinerror instead of strerror on Windows error
16373 codes. Add program to the error output.
16374 Don't close the main thread handle on Windows CE.
16375 (win32_attach): Use coredll.dll on Windows CE.
16376 (win32_kill): Close current process and current
16377 thread handles.
16378 (win32_detach): Use coredll.dll on Windows CE.
16379 (win32_resume): Let low target handle debug registers, and
16380 step request.
16381 (handle_exception): Add/Remove initial breakpoint. Avoid
16382 non-existant WSTOPSIG on Windows CE.
16383 (win32_read_inferior_memory): Cast to remove warning.
16384 (win32_arch_string): Go through the low target.
16385 (initialize_low): Call set_breakpoint_data with the low
16386 target's breakpoint.
16387 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16388 FOP_REGNUM, mappings): Move to ...
16389 * win32-i386-low.c: ... here.
16390 * win32-low.c (win32_thread_info): Move to ...
16391 * win32-low.h: ... here.
16392 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16393 win32-arm-low.c and wincecompat.c.
16394 (all:): Add $EXEEXT.
16395 (install-only:): Likewise.
16396 (gdbserver:): Likewise.
16397 (gdbreplay:): Likewise.
16398 * config.in: Regenerate.
16399 * configure: Regenerate.
16400
16401 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16402
16403 * win32-low.c: Rename typedef thread_info to
16404 win32_thread_info throughout.
16405
16406 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16407
16408 * win32-i386-low.c: Rename to ...
16409 * win32-low.c: ... this.
16410 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16411 * Makefile.in: Likewise.
16412
16413 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16414
16415 * remote-utils.c (monitor_output): Constify msg parameter.
16416 * server.h (monitor_output): Likewise.
16417 * win32-i386-low.c (handle_output_debug_string): New.
16418 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16419 handle_output_debug_string.
16420 (get_child_debug_event): Likewise.
16421
16422 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16423
16424 * server.c (main): Correct strtoul check.
16425
16426 2007-03-27 Jon Ringle <jon@ringle.org>
16427
16428 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16429
16430 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16431
16432 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16433
16434 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16435
16436 * terminal.h: Check HAVE_SGTTY_H.
16437
16438 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16439
16440 * remote-utils.c (remote_open): Print out the assigned port number.
16441
16442 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16443
16444 * remote-utils.c (monitor_output): New function.
16445 * server.c (debug_threads): Define here.
16446 (monitor_show_help): New function.
16447 (handle_query): Handle qRcmd.
16448 (main): Do not handle 'd' packet.
16449 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16450 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16451 of debug_threads.
16452
16453 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16454
16455 * Makefile.in (EXEEXT): New.
16456 (clean): Use $(EXEEXT).
16457
16458 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16459
16460 * target.h (target_ops): Rename send_signal to request_interrupt,
16461 and remove enum target_signal parameter.
16462 * linux-low.c (linux_request_interrupt): Rename from
16463 linux_send_signal, and always send SIGINT.
16464 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16465 and always send SIGINT.
16466 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16467 of send_signal.
16468 (input_interrupt): Likewise.
16469
16470 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16471
16472 * server.c (get_features_xml): Check if target implemented
16473 arch_string.
16474 * win32-i386-low.c (win32_arch_string): New.
16475 (win32_target_ops): Add win32_arch_string as arch_string member.
16476
16477 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16478
16479 * spu-low.c (spu_arch_string): New.
16480 (spu_target_ops): Add spu_arch_string.
16481
16482 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16483
16484 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16485 * configure.ac: Do not check for terminal.h.
16486 * configure, config.in: Regenerated.
16487
16488 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16489
16490 * Makefile.in (OBS): Add $(XML_BUILTIN).
16491 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16492 (clean): Update.
16493 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16494 (arm-with-iwmmxt.c): New.
16495 * config.in, configure: Regenerate.
16496 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16497 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16498 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16499 (arm*-*-linux*): Add iWMMXt and regset support.
16500 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16501 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16502 (arm_store_wmmxregset, target_regsets): New.
16503 * server.c (get_features_xml): Take annex argument. Check builtin
16504 XML documents.
16505 (handle_query): Handle multiple annexes.
16506
16507 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16508
16509 * remote-utils.c [USE_WIN32API] (read, write): Define.
16510 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16511 write.
16512
16513 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16514
16515 * linux-i386-low.c (the_low_target): Set arch_string.
16516 * linux-x86-64-low.c (the_low_target): Likewise.
16517 * linux-low.c (linux_arch_string): New.
16518 (linux_target_ops): Add it.
16519 * linux-low.h (struct linux_target_ops): Add arch_string.
16520 * server.c (write_qxfer_response): Use const void * for DATA.
16521 (get_features_xml): New.
16522 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16523 * target.h (struct target_ops): Add arch_string method.
16524
16525 2007-01-03 Denis Pilat <denis.pilat@st.com>
16526 Daniel Jacobowitz <dan@codesourcery.com>
16527
16528 * linux-low.c (linux_kill): Handle being called with no threads.
16529 * win32-i386-low.c (win32_kill): Likewise.
16530 (get_child_debug_event): Clear current_process_handle.
16531
16532 2006-12-30 Denis PILAT <denis.pilat@st.com>
16533 Daniel Jacobowitz <dan@codesourcery.com>
16534
16535 * remote-utils.c (remote_open): Check the type of specified
16536 serial port devices before opening them.
16537 * server.c (main): Kill the inferior if an error occurs during
16538 the first remote_open.
16539
16540 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16541
16542 * README: Update supported targets.
16543
16544 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16545
16546 * Makefile.in (clean): Remove reg-mips64.c.
16547 (reg-mips64.c, reg-mips64.o): New rules.
16548 * configure.srv: Handle mips64. Include regset support for mips.
16549 * linux-mips-low.c (union mips_register): New.
16550 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16551 (mips_breakpoint, mips_breakpoint_at): Use int.
16552 (mips_collect_register, mips_supply_register)
16553 (mips_collect_register_32bit, mips_supply_register_32bit)
16554 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16555 (mips_store_fpregset, target_regsets): New.
16556 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16557
16558 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16559
16560 * configure.srv: Add target "spu*-*-*".
16561 * Makefile.in (clean): Remove reg-spu.c.
16562 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16563 * spu-low.c: New file.
16564
16565 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16566
16567 * configure.ac: Correct td_thr_tls_get_addr test.
16568 * configure: Regenerated.
16569
16570 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16571
16572 * linux-low.c (linux_wait_for_event): Reformat. Use the
16573 pass_signals array.
16574 * remote-utils.c (decode_address_to_semicolon): New.
16575 * server.c (pass_signals, handle_general_set): New.
16576 (handle_query): Mention QPassSignals for qSupported.
16577 (main): Call handle_general_set.
16578 * server.h (pass_signals, decode_address_to_semicolon): New.
16579
16580 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16581
16582 * server.c (handle_query): Correct error handling for read_auxv.
16583
16584 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16585
16586 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16587 and srv_linux_thread_db to yes.
16588 * linux-s390-low.c (s390_fill_gregset): New function.
16589 (target_regsets): Define data structure.
16590
16591 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16592
16593 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16594 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16595 * config.in, configure: Regenerated.
16596 * inferiors.c (gdb_id_to_thread): New function.
16597 (gdb_id_to_thread_id): Use it.
16598 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16599 * linux-low.h (struct process_info): Add th member.
16600 (thread_db_get_tls_address): New prototype.
16601 * remote-utils.c (decode_address): Make non-static.
16602 * server.c (handle_query): Handle qGetTLSAddr.
16603 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16604 * target.h (struct target_ops): Add get_tls_address.
16605 * thread-db.c (maybe_attach_thread): Save the thread handle.
16606 (thread_db_get_tls_address): New.
16607
16608 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16609
16610 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16611 (linux_resume_one_process): Take a siginfo_t *. Update all
16612 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16613 (struct pending_signals): Add a siginfo_t.
16614 (linux_wait_for_process): Always set last_status.
16615 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16616 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16617 * linux-low.h (struct process_info): Add last_status.
16618
16619 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16620
16621 * remote-utils.c (try_rle): New function.
16622 (putpkt_binary): Use it.
16623
16624 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16625
16626 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16627 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16628 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16629 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16630 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16631 point registers.
16632
16633 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16634
16635 * server.c (terminal_fd): New variable.
16636 (old_foreground_pgrp): Likewise.
16637 (restore_old_foreground_pgrp): New function.
16638 (start_inferior): Record the terminal file descriptor in terminal_fd
16639 and its original foreground group in old_foreground_pgrp. Register
16640 restore_old_foreground_pgrp with atexit().
16641
16642 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16643
16644 * server.c (handle_query): Correct qPart to qXfer.
16645
16646 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16647
16648 * configure.ac: Check for more headers which are missing on
16649 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16650 * configure.srv: Add Cygwin and mingw32.
16651 * remote-utils.c: Don't include headers unconditionally which
16652 are missing on mingw32. Include <winsock.h> for mingw32.
16653 (remote_open): Adjust for mingw32 support. Flush
16654 standard error after writing to it.
16655 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16656 (unblock_async_io, enable_async_io, disable_async_io)
16657 (readchar, getpkt): Update for Winsock support.
16658 (prepare_resume_reply): Expect a protocol signal number.
16659 * server.c: Disable <sys/wait.h> on mingw32.
16660 (start_inferior): Adjust for mingw32 support. Flush
16661 standard error after writing to it.
16662 (attach_inferior): Likewise. Use protocol signal
16663 numbers.
16664 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16665 and names.
16666 * win32-i386-low.c: New file.
16667 * Makefile.in (XM_CLIBS): Set.
16668 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16669 (win32-i386-low.o): New dependency rule.
16670 * linux-low.c (linux_wait): Use target signal numbers.
16671 * target.h (struct target_ops): Doc fix.
16672 * server.h (target_signal_to_name): New prototype.
16673 * gdbreplay.c: Don't include headers unconditionally which
16674 are missing on mingw32. Include <winsock.h> for mingw32.
16675 (remote_close, remote_open): Adjust for Winsock support.
16676 * configure, config.in: Regenerated.
16677
16678 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16679
16680 * server.c (decode_xfer_read, write_qxfer_response): New.
16681 (handle_query): Take a packet length argument. Handle
16682 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16683 the qSupported response.
16684 (main): Update call to handle_query.
16685
16686 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16687
16688 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16689 (putpkt_binary): Renamed from putpkt and adjusted for binary
16690 data.
16691 (putpkt): New wrapper for putpkt_binary.
16692 (readchar): Don't mask off the high bit.
16693 (decode_X_packet): New function.
16694 * server.c (main): Call putpkt_binary if a handler sets the packet
16695 length. Save the length of the incoming packet. Handle 'X'.
16696 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16697
16698 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16699
16700 * server.c (handle_query): Handle qSupported.
16701
16702 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16703
16704 * remote-utils.c (all_symbols_looked_up): New variable.
16705 (look_up_one_symbol): Check it.
16706 * server.h (look_up_one_symbol): New declaration.
16707 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16708
16709 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16710
16711 * Makefile.in (linux-arm-low.o): Update dependencies.
16712 * linux-arm-low.c: Include "gdb_proc_service.h".
16713 (PTRACE_GET_THREAD_AREA): Define.
16714 (ps_get_thread_area): New function.
16715
16716 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16717
16718 * configure.srv (m68k*-*-uclinux*): New target.
16719 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16720 (linux_resume_one_process): Remove extraneous cast.
16721 (linux_read_offsets): New.
16722 (linux_target_op): Add linux_read_offsets on mmuless systems.
16723 * server.c (handle_query): Add qOffsets logic.
16724 * target.h (struct target_ops): Add read_offsets.
16725
16726 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16727
16728 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16729 (PTRACE_GET_THREAD_AREA): Define.
16730 (ps_get_thread_area): New function.
16731 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16732 (linux-x86-64-low.o): Update.
16733
16734 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16735
16736 * configure.ac: Remove checks for prfpregset_t.
16737 * gdb_proc_service.h: New file.
16738 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16739 new "gdb_proc_service.h".
16740 * proc-service.c: Likewise.
16741 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16742 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16743 * Makefile.in (gdb_proc_service_h): Updated.
16744 * configure, config.in: Regenerated.
16745
16746 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16747
16748 * remote-utils.c (prepare_resume_reply): Move declaration
16749 of gdb_id_from_wait to the top of the block.
16750
16751 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16752
16753 * linux-low.c (regsets_store_inferior_registers): Read the regset
16754 from the target before filling it.
16755
16756 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16757
16758 * server.c (attach_inferior): Return SIGTRAP for a successful
16759 attach.
16760
16761 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16762
16763 * Makefile.in (OBS): Add version.o.
16764 (STAGESTUFF): Delete.
16765 (version.o): Add dependencies.
16766 (version.c): Replace rule.
16767 (clean): Remove version.c.
16768 * server.c (gdbserver_version): New.
16769 (gdbserver_usage): Use printf.
16770 (main): Handle --version and --help.
16771 * server.h (version, host_name): Add declarations.
16772
16773 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16774
16775 * linux-arm-low.c:
16776 * linux-arm-low.c:
16777 * inferiors.c:
16778 * i387-fp.h:
16779 * i387-fp.c:
16780 * gdbreplay.c:
16781 * regcache.c:
16782 * proc-service.c:
16783 * mem-break.h:
16784 * mem-break.c:
16785 * linux-x86-64-low.c:
16786 * linux-sh-low.c:
16787 * linux-s390-low.c:
16788 * linux-ppc64-low.c:
16789 * linux-ppc-low.c:
16790 * linux-mips-low.c:
16791 * linux-m68k-low.c:
16792 * linux-m32r-low.c:
16793 * linux-low.h:
16794 * linux-low.c:
16795 * linux-ia64-low.c:
16796 * linux-i386-low.c:
16797 * linux-crisv32-low.c:
16798 * thread-db.c:
16799 * terminal.h:
16800 * target.h:
16801 * target.c:
16802 * server.h:
16803 * server.c:
16804 * remote-utils.c:
16805 * regcache.h:
16806 * utils.c:
16807 * Makefile.in:
16808 * configure.ac:
16809 * gdbserver.1: Add (C) after Copyright. Update the FSF
16810 address.
16811
16812 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16813
16814 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16815 (arm_breakpoint_at): Recognize both breakpoints.
16816 (the_low_target): Use the correct breakpoint instruction.
16817
16818 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16819
16820 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16821 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16822 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16823 (the_low_target): Update.
16824
16825 2005-10-25 Andreas Schwab <schwab@suse.de>
16826
16827 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16828
16829 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16830 (ia64_num_regs): Reduce to 462.
16831
16832 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16833
16834 * acinclude.m4: Correct quoting.
16835 * aclocal.m4: Regenerated.
16836
16837 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16838 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16839 (thread_db_init): Call thread_db_err_str.
16840 * configure.ac: Check for TD_VERSION.
16841 * config.in, configure: Regenerated.
16842
16843 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16844
16845 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16846
16847 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16848
16849 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16850 is not available. Define HAVE_PTRACE_GETREGS if it is.
16851 * config.in, configure: Regenerated.
16852 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16853 * linux-i386-low.c, linux-m68k-low.c: Update to use
16854 HAVE_PTRACE_GETREGS.
16855 * linux-low.c (regsets_fetch_inferior_registers)
16856 (regsets_store_inferior_registers): Only return 0 if we processed
16857 GENERAL_REGS.
16858 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16859 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16860
16861 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16862
16863 * inferiors.c (struct thread_info): Add gdb_id.
16864 (add_thread): Add gdb_id argument.
16865 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16866 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16867 calls to add_thread.
16868 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16869 * server.c (handle_query): Use thread_to_gdb_id.
16870 (handle_v_cont, main): Use gdb_id_to_thread_id.
16871 * server.h (add_thread): Update prototype.
16872 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16873 prototypes.
16874
16875 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16876
16877 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16878 left-padded registers.
16879 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16880 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16881
16882 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16883
16884 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16885 * configure: Regenerate.
16886 * config.in: Regenerate.
16887 * server.h (NEED_DECLARATION_STRERROR):
16888 Replace with !HAVE_DECL_STRERROR.
16889
16890 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16891
16892 * linux-low.c (linux_wait, linux_send_signal): Don't test
16893 an unsigned long variable for > 0 if it could be MAX_ULONG.
16894 * server.c (myresume): Likewise.
16895 * target.c (set_desired_inferior): Likewise.
16896
16897 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16898
16899 * configure.ac: Simplify and improve check for socklen_t.
16900 * configure, config.in: Regenerate.
16901
16902 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16903
16904 * acconfig.h: Remove.
16905 * configure.ac: Add a test for socklen_t. Use three-argument
16906 AC_DEFINE throughout.
16907 * config.in: Regenerated using autoheader 2.59.
16908 * configure: Regenerated.
16909
16910 * gdbreplay.c (socklen_t): Provide a default.
16911 (remote_open): Use socklen_t.
16912 * remote-utils.c (socklen_t): Provide a default.
16913 (remote_open): Use socklen_t.
16914 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16915 unsigned char.
16916
16917 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16918 char for buffers.
16919 * linux-low.c (linux_read_memory, linux_write_memory)
16920 (linux_read_auxv): Likewise.
16921 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16922 (check_mem_write): Likewise.
16923 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16924 Likewise.
16925 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16926 (registers_from_string, register_data): Likewise.
16927 * server.c (handle_query, main): Likewise.
16928 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16929 (decode_M_packet): Likewise.
16930 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16931 * target.h (struct target_ops): Update read_memory, write_memory,
16932 and read_auxv.
16933 (read_inferior_memory, write_inferior_memory): Update.
16934 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16935 to unsigned char *.
16936 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16937 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16938 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16939 linux-s390-low.c, linux-sh-low.c: Update for changes in
16940 read_inferior_memory and the_low_target->breakpoint.
16941
16942 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16943
16944 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16945 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16946 * configure.srv: Add powerpc64-*-linux*.
16947 * linux-ppc64-low.c: New file.
16948
16949 2005-05-23 Orjan Friberg <orjanf@axis.com>
16950
16951 * linux-cris-low.c: New file with support for CRIS.
16952 * linux-crisv32-low.c: Ditto for CRISv32.
16953 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16954 (clean): Add reg-cris.c and reg-crisv32.c.
16955 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16956 reg-crisv32.o, and reg-crisv32.c to make rules.
16957 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16958 recognized targets.
16959
16960 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16961
16962 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16963 of sizeof (PTRACE_XFER_TYPE).
16964 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16965
16966 2005-05-12 Orjan Friberg <orjanf@axis.com>
16967
16968 * target.h (struct target_ops): Add insert_watchpoint,
16969 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16970 pointers for hardware watchpoint support.
16971 * linux-low.h (struct linux_target_ops): Ditto.
16972 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16973 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16974 to linux_target_ops.
16975 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16976 reply packet.
16977 * server.c (main): Recognize 'Z' and 'z' packets.
16978
16979 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16980
16981 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16982 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16983 (the_low_target): Add new members.
16984
16985 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16986
16987 * proc-service.c (ps_lgetregs): Search all_processes instead of
16988 all_threads.
16989
16990 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16991
16992 * server.c (start_inferior): Change return type to int.
16993 (attach_inferior): Change sigptr to int *.
16994 (handle_v_cont, handle_v_requests): Change signal to int *.
16995 (main): Change signal to int.
16996
16997 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16998
16999 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
17000 * configure.srv: Add m32r*-*-linux*.
17001 * linux-m32r-low.c: New file.
17002
17003 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
17004
17005 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
17006
17007 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17008
17009 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
17010 Take unsigned long arguments for PIDs.
17011 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
17012 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
17013 (wait_for_sigstop, linux_resume_one_process)
17014 (regsets_fetch_inferior_registers, linux_send_signal)
17015 (linux_read_auxv): Likewise. Update the types of variables holding
17016 PIDs. Update format string specifiers.
17017 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
17018 * remote-utils.c (prepare_resume_reply): Likewise.
17019 * server.c (cont_thread, general_thread, step_thread)
17020 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
17021 unsigned long.
17022 (handle_query): Update format specifiers.
17023 (handle_v_cont, main): Use strtoul for thread IDs.
17024 * server.h (struct inferior_list_entry): Use unsigned long for ID.
17025 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
17026 (general_thread, step_thread, thread_from_wait)
17027 (old_thread_from_wait): Update.
17028 * target.h (struct thread_resume): Use unsigned long for THREAD.
17029 (struct target_ops): Use unsigned long for arguments to attach and
17030 thread_alive.
17031
17032 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
17033
17034 * acinclude.m4: Include bfd/bfd.m4 directly.
17035 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
17036 <agriffis@toolchain.org>.
17037 * aclocal.m4, configure: Regenerated.
17038
17039 2005-01-07 Andrew Cagney <cagney@gnu.org>
17040
17041 * configure.ac: Rename configure.in, require autoconf 2.59.
17042 * configure: Re-generate.
17043
17044 2004-12-08 Daniel Jacobowitz <dan@debian.org>
17045
17046 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
17047 LIBS when finished.
17048 * aclocal.m4: Regenerated.
17049 * configure: Regenerated.
17050
17051 2004-11-21 Andreas Schwab <schwab@suse.de>
17052
17053 * linux-m68k-low.c (m68k_num_gregs): Define.
17054 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
17055 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
17056 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
17057 (m68k_breakpoint_at): New. Add to the_low_target.
17058
17059 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
17060 srv_linux_thread_db to yes.
17061
17062 2004-10-20 Joel Brobecker <brobecker@gnat.com>
17063
17064 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
17065 (ARCH_SET_FS): Likewise.
17066 (ARCH_GET_FS): Likewise.
17067 (ARCH_GET_GS): Likewise.
17068
17069 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17070
17071 * linux-i386-low.c (ps_get_thread_area): New.
17072 * linux-x86-64-low.c (ps_get_thread_area): New.
17073 * linux-low.c: Include <sys/syscall.h>.
17074 (linux_kill_one_process): Don't kill the first thread here.
17075 (linux_kill): Kill the first thread here.
17076 (kill_lwp): New function.
17077 (send_sigstop, linux_send_signal): Use it.
17078 * proc-service.c: Clean up #ifdefs.
17079 (fpregset_info): Delete.
17080 (ps_lgetregs): Update and enable implementation.
17081 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
17082 implementations.
17083 * remote-utils.c (struct sym_cache, symbol_cache): New.
17084 (input_interrupt): Print a clearer message.
17085 (async_io_enabled): New variable.
17086 (enable_async_io, disable_async_io): Use it. Update comments.
17087 (look_up_one_symbol): Use the symbol cache.
17088 * thread-db.c (thread_db_look_up_symbols): New function.
17089 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
17090
17091 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17092
17093 * configure.in: Test for -rdynamic.
17094 * configure: Regenerated.
17095 * Makefile (INTERNAL_LDFLAGS): New.
17096 (gdbserver, gdbreplay): Use it.
17097
17098 2004-09-02 Andrew Cagney <cagney@gnu.org>
17099
17100 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
17101
17102 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
17103
17104 * linux-low.c (linux_wait): Clear all_processes list also.
17105
17106 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17107
17108 * linux-low.c: Include <errno.h>. Remove extern declaration of
17109 errno.
17110
17111 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17112
17113 * gdbreplay.c, server.h, utils.c: Update copyright years.
17114
17115 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17116
17117 * server.c (main): Print child status or termination signal from
17118 variable 'signal', not 'sig'.
17119
17120 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17121
17122 * linux-low.c (linux_read_memory): Change return type to
17123 int. Check for and return error from ptrace().
17124 * target.c (read_inferior_memory): Change return type to int. Pass
17125 back return status from the_target->read_memory().
17126 * target.h (struct target_ops): Adapt *read_memory() prototype.
17127 Update comment.
17128 (read_inferior_memory): Adapt prototype.
17129 * server.c (main): Return an error packet if
17130 read_inferior_memory() returns an error.
17131
17132 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
17133
17134 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17135 Unify with other clean targets.
17136
17137 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17138
17139 * server.c (handle_v_cont): Call set_desired_inferior.
17140
17141 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17142
17143 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17144
17145 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17146
17147 * linux-low.c (linux_wait): Unblock async I/O.
17148 (linux_resume): Block and enable async I/O.
17149 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17150 * server.h (block_async_io, unblock_async_io): Add prototypes.
17151
17152 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17153
17154 * remote-utils.c (remote_open): Print a status notice after
17155 opening a TCP port.
17156 * server.c (attach_inferior): Print a status notice after
17157 attaching.
17158
17159 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17160
17161 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17162
17163 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
17164
17165 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17166 error packet.
17167 * server.c, target.h: Update copyright years.
17168
17169 2004-02-25 Roland McGrath <roland@redhat.com>
17170
17171 * target.h (struct target_ops): New member `read_auxv'.
17172 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17173 * linux-low.c (linux_read_auxv): New function.
17174 (linux_target_ops): Initialize `read_auxv' member to that.
17175
17176 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17177
17178 Committed by Jim Blandy <jimb@redhat.com>.
17179
17180 * linux-s390-low.c (s390_num_regs): Update.
17181 (s390_regmap): Remove control registers. Use __s390x__ predefine
17182 instead of GPR_SIZE to distiguish s390 and s390x targets.
17183
17184 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
17185
17186 * linux-low.c: Update copyright year.
17187 (check_removed_breakpoint): Clear pending_is_breakpoint.
17188 (linux_set_resume_request, linux_queue_one_thread)
17189 (resume_status_pending_p): New functions.
17190 (linux_continue_one_thread): Use process->resume.
17191 (linux_resume): Only resume threads if there are no pending events.
17192 * linux-low.h (struct process_info): Add resume request
17193 pointer.
17194
17195 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
17196
17197 * regcache.c (new_register_cache): Clear the allocated register
17198 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17199
17200 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
17201
17202 * linux-low.c (linux_resume): Take a struct thread_resume *
17203 argument.
17204 (linux_wait): Update call.
17205 (resume_ptr): New static variable.
17206 (linux_continue_one_thread): Renamed from
17207 linux_continue_one_process. Use resume_ptr.
17208 (linux_resume): Use linux_continue_one_thread.
17209 * server.c (handle_v_cont, handle_v_requests): New functions.
17210 (myresume): New function.
17211 (main): Handle 'v' case.
17212 * target.h (struct thread_resume): New type.
17213 (struct target_ops): Change argument of "resume" to struct
17214 thread_resume *.
17215 (myresume): Delete macro.
17216
17217 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17218
17219 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17220 (uninstall): Support DESTDIR.
17221
17222 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17223
17224 * configure.srv: Add xscale*linux copy of arm*linux entry.
17225
17226 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
17227
17228 * linux-arm-low.c (arm_reinsert_addr): New function.
17229 (the_low_target): Add arm_reinsert_addr.
17230
17231 2003-07-08 Mark Kettenis <kettenis@gnu.org>
17232
17233 * mem-break.c: Remove whitespace at end of file.
17234
17235 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17236
17237 * configure.in: Check whether we need to prototype strerror.
17238 * server.h: Optionally prototype strerror.
17239 * gdbreplay.c (perror_with_name): Use strerror.
17240 * linux-low.c (linux_attach_lwp): Use strerror.
17241 * utils.c (perror_with_name): Use strerror.
17242 * config.in, configure: Regenerated.
17243
17244 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17245
17246 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17247 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17248
17249 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
17250
17251 * Makefile.in (SFILES): Update.
17252 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17253 low-sun3.c: Remove files.
17254
17255 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
17256
17257 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17258 (linux_detach_one_process, linux_detach): New functions.
17259 (linux_target_ops): Add linux_detach.
17260 * server.c (main): Handle 'D' packet.
17261 * target.h (struct target_ops): Add "detach" member.
17262 (detach_inferior): Define.
17263
17264 2003-06-13 Mark Kettenis <kettenis@gnu.org>
17265
17266 From Kelley Cook <kelleycook@wideopenwest.com>:
17267 * configure.srv: Accept i[34567]86 variants.
17268
17269 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
17270
17271 * linux-low.c (linux_wait_for_event): Correct comment typos.
17272 (linux_resume_one_process): Call check_removed_breakpoint.
17273 (linux_send_signal): New function.
17274 (linux_target_ops): Add linux_send_signal.
17275 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17276 of kill.
17277 * target.h (struct target_ops): Add send_signal.
17278
17279 2003-05-29 Jim Blandy <jimb@redhat.com>
17280
17281 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17282 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17283 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17284 away part of the register's value.
17285
17286 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
17287
17288 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17289 (linux_wait_for_event, linux_init_signals): Likewise.
17290
17291 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
17292
17293 * configure.in: Check for stdlib.h.
17294 * configure: Regenerated.
17295 * config.in: Regenerated.
17296
17297 2003-01-04 Andreas Schwab <schwab@suse.de>
17298
17299 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17300
17301 2003-01-02 Andrew Cagney <ac131313@redhat.com>
17302
17303 * Makefile.in: Remove obsolete code.
17304
17305 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
17306
17307 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17308 defined(PT_FPR0_HI).
17309
17310 2002-11-17 Stuart Hughes <seh@zee2.com>
17311
17312 * linux-arm-low.c (arm_num_regs): Increase.
17313 (arm_regmap): Include status register.
17314
17315 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
17316
17317 * linux-low.c (register_addr): Remove incorrect -1 check.
17318
17319 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
17320
17321 * linux-low.c (linux_create_inferior): Call setpgid. Return
17322 the new PID.
17323 (unstopped_p, linux_signal_pid): Remove.
17324 (linux_target_ops): Remove linux_signal_pid.
17325 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17326 global instead of target method.
17327 * target.h (struct target_ops): Remove signal_pid. Update comment
17328 for create_inferior.
17329 * server.c (signal_pid): New variable.
17330 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
17331 gdbserver. Set the child to be the foreground process group.
17332 (attach_inferior): Set signal_pid.
17333
17334 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
17335
17336 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17337
17338 2002-08-20 Jim Blandy <jimb@redhat.com>
17339
17340 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17341 default for this.
17342
17343 2002-08-01 Andrew Cagney <cagney@redhat.com>
17344
17345 * Makefile.in: Make chill references obsolete.
17346
17347 2002-07-24 Kevin Buettner <kevinb@redhat.com>
17348
17349 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17350 * configure: Regenerate.
17351 * config.in: Regenerate.
17352
17353 2002-07-09 David O'Brien <obrien@FreeBSD.org>
17354
17355 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17356 (perror_with_name, remote_close, remote_open, expect, play): Static.
17357
17358 2002-07-04 Michal Ludvig <mludvig@suse.cz>
17359
17360 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17361 byte offsets instead of an array of indexes.
17362 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17363
17364 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
17365
17366 * regcache.c: Add comment.
17367
17368 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
17369
17370 * thread-db.c: New file.
17371 * proc-service.c: New file.
17372 * acinclude.m4: New file.
17373 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17374 proc-service.o, and thread-db.o.
17375 (linux-low.o): Add USE_THREAD_DB.
17376 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17377 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17378 * aclocal.m4: Regenerated.
17379 * config.in: Regenerated.
17380 * configure: Regenerated.
17381 * configure.in: Check for proc_service.h, sys/procfs.h,
17382 thread_db.h, and linux/elf.h headrs.
17383 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17384 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17385 Check for -lthread_db and thread support.
17386 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17387 PowerPC, and SuperH.
17388 * i387-fp.c: Constify arguments.
17389 * i387-fp.h: Likewise.
17390 * inferiors.c: (struct thread_info): Renamed from
17391 `struct inferior_info'. Remove PID member. Use generic inferior
17392 list header. All uses updated.
17393 (inferiors, signal_pid): Removed.
17394 (all_threads): New variable.
17395 (get_thread): Define.
17396 (add_inferior_to_list): New function.
17397 (for_each_inferior): New function.
17398 (change_inferior_id): New function.
17399 (add_inferior): Removed.
17400 (remove_inferior): New function.
17401 (add_thread): New function.
17402 (free_one_thread): New function.
17403 (remove_thread): New function.
17404 (clear_inferiors): Use for_each_inferior and free_one_thread.
17405 (find_inferior): New function.
17406 (find_inferior_id): New function.
17407 (inferior_target_data): Update argument type.
17408 (set_inferior_target_data): Likewise.
17409 (inferior_regcache_data): Likewise.
17410 (set_inferior_regcache_data): Likewise.
17411 * linux-low.c (linux_bp_reinsert): Remove.
17412 (all_processes, stopping_threads, using_thrads)
17413 (struct pending_signals, debug_threads, pid_of): New.
17414 (inferior_pid): Replace with macro.
17415 (struct inferior_linux_data): Remove.
17416 (get_stop_pc, add_process): New functions.
17417 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17418 Use add_process and add_thread.
17419 (linux_attach_lwp): New function, based on old linux_attach. Use
17420 add_process and add_thread. Set stop_expected for new threads.
17421 (linux_attach): New function.
17422 (linux_kill_one_process): New function.
17423 (linux_kill): Kill all LWPs.
17424 (linux_thread_alive): Use find_inferior_id.
17425 (check_removed_breakpoints, status_pending_p): New functions.
17426 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17427 Update. Use WNOHANG. Wait for cloned processes also. Update process
17428 struct for the found process.
17429 (linux_wait_for_event): New function.
17430 (linux_wait): Use it. Support LWPs.
17431 (send_sigstop, wait_for_sigstop, stop_all_processes)
17432 (linux_resume_one_process, linux_continue_one_process): New functions.
17433 (linux_resume): Support LWPs.
17434 (REGISTER_RAW_SIZE): Remove.
17435 (fetch_register): Use register_size instead. Call supply_register.
17436 (usr_store_inferior_registers): Likewise. Call collect_register.
17437 Fix recursive case.
17438 (regsets_fetch_inferior_registers): Improve error message.
17439 (regsets_store_inferior_registers): Add debugging.
17440 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17441 (unstopped_p, linux_signal_pid): New functions.
17442 (linux_target_ops): Add linux_signal_pid.
17443 (linux_init_signals): New function.
17444 (initialize_low): Call it. Initialize using_threads.
17445 * regcache.c (inferior_regcache_data): Add valid
17446 flag.
17447 (get_regcache): Fetch registers lazily. Add fetch argument
17448 and update all callers.
17449 (regcache_invalidate_one, regcache_invalidate): New
17450 functions.
17451 (new_register_cache): Renamed from create_register_cache.
17452 Return the new regcache.
17453 (free_register_cache): Change argument to a void *.
17454 (registers_to_string, registers_from_string): Call get_regcache
17455 with fetch flag set.
17456 (register_data): Make static. Pass fetch flag to get_regcache.
17457 (supply_register): Call get_regcache with fetch flag clear.
17458 (collect_register): Call get_regcache with fetch flag set.
17459 (collect_register_as_string): New function.
17460 * regcache.h: Update.
17461 * remote-utils.c (putpkt): Flush after debug output and use
17462 stderr.
17463 Handle input interrupts while waiting for an ACK.
17464 (input_interrupt): Use signal_pid method.
17465 (getpkt): Flush after debug output and use stderr.
17466 (outreg): Use collect_register_as_string.
17467 (new_thread_notify, dead_thread_notify): New functions.
17468 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17469 and general_thread.
17470 (look_up_one_symbol): Flush after debug output.
17471 * server.c (step_thread, server_waiting): New variables.
17472 (start_inferior): Don't use signal_pid. Update call to mywait.
17473 (attach_inferior): Update call to mywait.
17474 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17475 (main): Don't fetch/store registers explicitly. Use
17476 set_desired_inferior. Support proposed ``Hs'' packet. Update
17477 calls to mywait.
17478 * server.h: Update.
17479 (struct inferior_list, struct_inferior_list_entry): New.
17480 * target.c (set_desired_inferior): New.
17481 (write_inferior_memory): Constify.
17482 (mywait): New function.
17483 * target.h: Update.
17484 (struct target_ops): New signal_pid method.
17485 (mywait): Removed macro, added prototype.
17486
17487 * linux-low.h (regset_func): Removed.
17488 (regset_fill_func, regset_store_func): New.
17489 (enum regset_type): New.
17490 (struct regset_info): Add type field. Use new operation types.
17491 (struct linux_target_ops): stop_pc renamed to get_pc.
17492 Add decr_pc_after_break and breakpoint_at.
17493 (get_process, get_thread_proess, get_process_thread)
17494 (strut process_info, all_processes, linux_attach_lwp)
17495 (thread_db_init): New.
17496
17497 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17498 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17499 (the_low_target): Add new members.
17500 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17501 (i386_store_fpxregset): Constify.
17502 (target_regsets): Add new kind identifier.
17503 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17504 (i386_set_pc): Add debugging.
17505 (i386_breakpoint_at): New function.
17506 (the_low_target): Add new members.
17507 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17508 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17509 (mips_breakpoint_at): New.
17510 (the_low_target): Add new members.
17511 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17512 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17513 (the_low_target): Add new members.
17514 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17515 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17516 (the_low_target): Add new members.
17517 * linux-x86-64-low.c (target_regsets): Add new kind
17518 identifier.
17519
17520 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17521
17522 From Martin Pool <mbp@samba.org>:
17523 * server.c (gdbserver_usage): New function.
17524 (main): Call it.
17525
17526 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17527
17528 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17529 stop_at -> stop_pc.
17530
17531 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17532
17533 * Makefile.in: Remove obsolete code.
17534
17535 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17536
17537 * linux-low.c (regsets_fetch_inferior_registers),
17538 (regsets_store_inferior_registers): Removed cast to int from
17539 ptrace() calls.
17540 * regcache.h: Added declaration of struct inferior_info.
17541
17542 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17543
17544 * inferiors.c (struct inferior_info): Add regcache_data.
17545 (add_inferior): Call create_register_cache.
17546 (clear_inferiors): Call free_register_cache.
17547 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17548 * regcache.c (struct inferior_regcache_data): New.
17549 (registers): Remove.
17550 (get_regcache): New function.
17551 (create_register_cache, free_register_cache): New functions.
17552 (set_register_cache): Don't initialize the register cache here.
17553 (registers_to_string, registers_from_string, register_data): Call
17554 get_regcache.
17555 * regcache.h: Add prototypes.
17556 * server.h: Likewise.
17557
17558 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17559
17560 * mem-break.c: New file.
17561 * mem-break.h: New file.
17562 * Makefile.in: Add mem-break.o rule; update server.h
17563 dependencies.
17564 * inferiors.c (struct inferior_info): Add target_data
17565 member.
17566 (clear_inferiors): Free target_data member if set.
17567 (inferior_target_data, set_inferior_target_data): New functions.
17568 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17569 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17570 * linux-low.c (linux_bp_reinsert): New variable.
17571 (struct inferior_linux_data): New.
17572 (linux_create_inferior): Use set_inferior_target_data.
17573 (linux_attach): Likewise. Call add_inferior.
17574 (linux_wait_for_one_inferior): New function.
17575 (linux_wait): Call it.
17576 (linux_write_memory): Add const.
17577 (initialize_low): Call set_breakpoint_data.
17578 * linux-low.h (struct linux_target_ops): Add breakpoint
17579 handling members.
17580 * server.c (attach_inferior): Remove extra add_inferior
17581 call.
17582 * server.h: Include mem-break.h. Update inferior.c
17583 prototypes.
17584 * target.c (read_inferior_memory)
17585 (write_inferior_memory): New functions.
17586 * target.h (read_inferior_memory)
17587 (write_inferior_memory): Change macros to prototypes.
17588 (struct target_ops): Update comments. Add const to write_memory
17589 definition.
17590
17591 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17592
17593 * linux-low.c (usr_store_inferior_registers): Support
17594 registers which are allowed to fail to store.
17595 * linux-low.h (linux_target_ops): Likewise.
17596 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17597 (ppc_cannot_store_register): FPSCR may not be storable.
17598
17599 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17600
17601 * server.h: Include <string.h> if HAVE_STRING_H.
17602 * ChangeLog: Correct paths in last ChangeLog entry.
17603
17604 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17605
17606 * linux-low.h: Remove obsolete prototypes.
17607 (struct linux_target_ops): New.
17608 (extern the_low_target): New.
17609 * linux-low.c (num_regs, regmap): Remove declarations.
17610 (register_addr): Use the_low_target explicitly.
17611 (fetch_register): Likewise.
17612 (usr_fetch_inferior_registers): Likewise.
17613 (usr_store_inferior_registers): Likewise.
17614 * linux-arm-low.c (num_regs): Remove.
17615 (arm_num_regs): Define.
17616 (arm_regmap): Renamed from regmap, made static.
17617 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17618 made static.
17619 (arm_cannot_store_register): Renamed from cannot_store_register,
17620 made static.
17621 (the_low_target): New.
17622 * linux-i386-low.c (num_regs): Remove.
17623 (i386_num_regs): Define.
17624 (i386_regmap): Renamed from regmap, made static.
17625 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17626 made static.
17627 (i386_cannot_store_register): Renamed from cannot_store_register,
17628 made static.
17629 (the_low_target): New.
17630 * linux-ia64-low.c (num_regs): Remove.
17631 (ia64_num_regs): Define.
17632 (ia64_regmap): Renamed from regmap, made static.
17633 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17634 made static.
17635 (ia64_cannot_store_register): Renamed from cannot_store_register,
17636 made static.
17637 (the_low_target): New.
17638 * linux-m68k-low.c (num_regs): Remove.
17639 (m68k_num_regs): Define.
17640 (m68k_regmap): Renamed from regmap, made static.
17641 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17642 made static.
17643 (m68k_cannot_store_register): Renamed from cannot_store_register,
17644 made static.
17645 (the_low_target): New.
17646 * linux-mips-low.c (num_regs): Remove.
17647 (mips_num_regs): Define.
17648 (mips_regmap): Renamed from regmap, made static.
17649 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17650 made static.
17651 (mips_cannot_store_register): Renamed from cannot_store_register,
17652 made static.
17653 (the_low_target): New.
17654 * linux-ppc-low.c (num_regs): Remove.
17655 (ppc_num_regs): Define.
17656 (ppc_regmap): Renamed from regmap, made static.
17657 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17658 made static.
17659 (ppc_cannot_store_register): Renamed from cannot_store_register,
17660 made static.
17661 (the_low_target): New.
17662 * linux-s390-low.c (num_regs): Remove.
17663 (s390_num_regs): Define.
17664 (s390_regmap): Renamed from regmap, made static.
17665 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17666 made static.
17667 (s390_cannot_store_register): Renamed from cannot_store_register,
17668 made static.
17669 (the_low_target): New.
17670 * linux-sh-low.c (num_regs): Remove.
17671 (sh_num_regs): Define.
17672 (sh_regmap): Renamed from regmap, made static.
17673 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17674 made static.
17675 (sh_cannot_store_register): Renamed from cannot_store_register,
17676 made static.
17677 (the_low_target): New.
17678 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17679 (the_low_target): New.
17680
17681 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17682
17683 * Makefile.in: Add stamp-h target.
17684 * configure.in: Create stamp-h.
17685 * configure: Regenerated.
17686
17687 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17688
17689 * inferiors.c: New file.
17690 * target.c: New file.
17691 * target.h: New file.
17692 * Makefile.in: Add target.o and inferiors.o. Update
17693 dependencies.
17694 * linux-low.c (inferior_pid): New static variable,
17695 moved from server.c.
17696 (linux_create_inferior): Renamed from create_inferior.
17697 Call add_inferior. Return 0 on success instead of a PID.
17698 (linux_attach): Renamed from myattach.
17699 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17700 (linux_thread_alive): Renamed from mythread_alive.
17701 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17702 child dies.
17703 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17704 (regsets_store_inferior_registers): Correct error message.
17705 Add missing ``return 0''.
17706 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17707 (linux_store_registers): Renamed from store_inferior_registers.
17708 (linux_read_memory): Renamed from read_inferior_memory.
17709 (linux_write_memory): Renamed from write_inferior_memory.
17710 (linux_target_ops): New structure.
17711 (initialize_low): Call set_target_ops ().
17712 * remote-utils.c (unhexify): New function.
17713 (hexify): New function.
17714 (input_interrupt): Send signals to ``signal_pid''.
17715 * server.c (inferior_pid): Remove.
17716 (start_inferior): Update create_inferior call.
17717 (attach_inferior): Call add_inferior.
17718 (handle_query): New function.
17719 (main): Call handle_query for `q' packets.
17720 * server.h: Include "target.h". Remove obsolete prototypes.
17721 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17722
17723 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17724
17725 * Makefile.in: Add WARN_CFLAGS. Update configury
17726 dependencies.
17727 * configure.in: Check for <string.h>
17728 * configure: Regenerate.
17729 * config.in: Regenerate.
17730 * gdbreplay.c: Include needed system headers.
17731 (remote_open): Remove strchr prototype.
17732 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17733 * regcache.c (supply_register): Change buf argument to const void *.
17734 (supply_register_by_name): Likewise.
17735 (collect_register): Change buf argument to void *.
17736 (collect_register_by_name): Likewise.
17737 * regcache.h: Add missing prototypes.
17738 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17739 * server.c (handle_query): New function.
17740 (attached): New static variable, moved out of main.
17741 (main): Quiet longjmp clobber warnings.
17742 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17743 * utils.c (error): Remove NORETURN.
17744 (fatal): Likewise.
This page took 0.444938 seconds and 4 git commands to generate.