Import the strerror_r-posix module and use it in GDB.
[deliverable/binutils-gdb.git] / gdb / gdbserver / ChangeLog
1 2019-11-15 Christian Biesinger <cbiesinger@google.com>
2
3 * config.in: Regenerate.
4 * configure: Regenerate.
5
6 2019-11-12 Andrew Burgess <andrew.burgess@embecosm.com>
7
8 * ax.c (ax_printf): Handle size_t_arg.
9
10 2019-11-06 Christian Biesinger <cbiesinger@google.com>
11
12 * linux-tdep.c (linux_info_proc): Use strtok_r instead of strtok.
13 * mi/mi-main.c (output_cores): Likewise.
14 * nat/linux-osdata.c (linux_xfer_osdata_cpus): Likewise.
15 (linux_xfer_osdata_modules): Likewise.
16 * remote.c (register_remote_support_xml): Likewise.
17 * sparc64-tdep.c (adi_is_addr_mapped): Likewise.
18 * xml-syscall.c (syscall_create_syscall_desc): Likewise.
19
20 2019-11-01 Christian Biesinger <cbiesinger@google.com>
21
22 * configure: Regenerate.
23 * configure.ac: Remove check for strerror_r.
24
25 2019-10-31 Christian Biesinger <cbiesinger@google.com>
26
27 * config.in: Regenerate.
28 * configure: Regenerate.
29 * configure.ac: Also check for strerror_r.
30
31 2019-10-31 Christian Biesinger <cbiesinger@google.com>
32
33 * ax.h (debug_agent): Remove duplicate declaration.
34
35 2019-10-26 Tom de Vries <tdevries@suse.de>
36
37 * linux-aarch64-low.c: Fix typos in comments.
38 * linux-arm-low.c: Same.
39 * linux-low.c: Same.
40 * linux-ppc-low.c: Same.
41 * proc-service.c: Same.
42 * regcache.h: Same.
43 * server.c: Same.
44 * tracepoint.c: Same.
45 * win32-low.c: Same.
46
47 2019-10-25 Tom Tromey <tromey@adacore.com>
48
49 * utils.c (xstrdup): Remove.
50
51 2019-10-23 Tom Tromey <tom@tromey.com>
52
53 * configure, config.in: Rebuild.
54
55 2019-10-23 Tom Tromey <tom@tromey.com>
56
57 * configure: Rebuild.
58 * acinclude.m4: Use m4_include, not sinclude.
59
60 2019-10-17 Tom Tromey <tromey@adacore.com>
61
62 * configure: Rebuild.
63 * configure.ac: Use AC_CONFIG_HEADERS. Create stamp-h there, not
64 in AC_CONFIG_FILES invocation.
65 * Makefile.in (stamp-h, Makefile): Use new-style config.status
66 invocation.
67
68 2019-10-16 Christian Biesinger <cbiesinger@google.com>
69
70 * server.c: Include xml-builtin.h.
71 (get_xml_features): Don't declare xml_builtins here.
72
73 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
74
75 * Makefile.in: Remove references to vec-ipa.o.
76
77 2019-10-15 Andrew Burgess <andrew.burgess@embecosm.com>
78
79 * Makefile.in: Remove references to vec.c.
80
81 2019-10-02 Christian Biesinger <cbiesinger@google.com>
82
83 * server.c (server_waiting): Change to bool.
84 (extended_protocol): Likewise.
85 (response_needed): Likewise.
86 (exit_requested): Likewise.
87 (run_once): Likewise.
88 (report_no_resumed): Likewise.
89 (non_stop): Likewise.
90 (disable_packet_vCont): Likewise.
91 (disable_packet_Tthread): Likewise.
92 (disable_packet_qC): Likewise.
93 (disable_packet_qfThreadInfo): Likewise.
94 (handle_general_set): Update.
95 (handle_detach): Update.
96 (handle_monitor_command): Update.
97 (handle_query): Update.
98 (captured_main): Update.
99 (process_serial_event): Update.
100 * server.h (server_waiting): Change to bool.
101 (disable_packet_vCont): Likewise.
102 (disable_packet_Tthread): Likewise.
103 (disable_packet_qC): Likewise.
104 (disable_packet_qfThreadInfo): Likewise.
105 (run_once): Likewise.
106 (non_stop): Likewise.
107 * target.c (target_stop_and_wait): Update.
108
109 2019-10-02 Tom Tromey <tromey@adacore.com>
110
111 * Makefile.in (SFILES): Add common-inferior.c.
112 (OBS): Add common-inferior.o.
113 * server.c (startup_with_shell): Don't define.
114
115 2019-10-02 Andrew Burgess <andrew.burgess@embecosm.com>
116
117 * linux-low.c (linux_low_read_btrace): Update for change to
118 std::vector.
119
120 2019-09-20 Christian Biesinger <cbiesinger@google.com>
121
122 * debug.c (debug_threads): Remove comment in favor of the header.
123 * debug.h (using_threads): Add declaration.
124 (debug_threads): Add comment.
125 * linux-aarch64-low.c: Include debug.h and remove declaration of
126 debug_threads.
127 * nto-low.c: Likewise.
128 * remote-utils.c: Likewise.
129 * thread-db.c: Likewise.
130
131 2019-09-20 Ulrich Weigand <uweigand@de.ibm.com>
132
133 * configure.srv (ipa_ppc_linux_regobj): Remove powerpc-cell32l-ipa.o
134 and powerpc-cell64l-ipa.o.
135 (powerpc*-*-linux*): Remove powerpc-cell32l.o and powerpc-cell64l.o
136 from srv_regobj. Remove rs6000/powerpc-cell32l.xml and
137 rs6000/powerpc-cell64l.xml from srv_xmlfiles.
138 (spu*-*-*): Remove.
139
140 * spu-low.c: Remove file.
141
142 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Remove.
143 (parse_spufs_run): Remove.
144 (ppc_get_pc): Remove Cell/B.E. support.
145 (ppc_set_pc): Likewise.
146 (ppc_breakpoint_at): Likewise.
147 (ppc_arch_setup): Likewise.
148 (ppc_get_ipa_tdesc_idx): Do not handle tdesc_powerpc_cell64l or
149 tdesc_powerpc_cell32l.
150 (initialize_low_arch): Do not call init_registers_powerpc_cell64l
151 or init_registers_powerpc_cell32l.
152 * linux-ppc-ipa.c (get_ipa_tdesc): Do not handle PPC_TDESC_CELL.
153 (initialize_low_tracepoint): Do not call init_registers_powerpc_cell64l
154 or init_registers_powerpc_cell32l.
155 * linux-ppc-tdesc-init.h (PPC_TDESC_CELL): Mark as unused.
156 (init_registers_powerpc_cell32l): Remove prototype.
157 (init_registers_powerpc_cell64l): Likewise.
158
159 * target.h (struct target_ops): Remove qxfer_spu member.
160 * server.c (handle_qxfer_spu): Remove.
161 (qxfer_packets): Remove entry for "spu".
162 (handle_query): No longer support qXfer:spu:read or qXfer:spu:write.
163 * linux-low.c (SPUFS_MAGIC): Remove.
164 (spu_enumerate_spu_ids): Remove.
165 (linux_qxfer_spu): Remove.
166 (linux_target_ops): Remove qxfer_spu member.
167 * lynx-low.c (lynx_target_ops): Remove qxfer_spu member.
168 * nto-low.c (nto_target_ops): Remove qxfer_spu member.
169 * win32-low.c (win32_target_ops): Remove qxfer_spu member.
170
171 2019-08-23 Sergio Durigan Junior <sergiodj@redhat.com>
172
173 * Makefile.in (SFILES): Add 'gdbsupport/gdb-dlfcn.c'.
174 (OBS): Add 'gdbsupport/gdb-dlfcn.o'.
175 * config.in: Regenerate.
176 * configure: Regenerate.
177
178 2019-08-15 Tom Tromey <tromey@adacore.com>
179
180 * target.c (target_write_memory): Use gdb::byte_vector.
181
182 2019-08-15 Tom Tromey <tromey@adacore.com>
183
184 * tracepoint.c (write_inferior_data_pointer)
185 (write_inferior_integer, write_inferior_int8)
186 (write_inferior_uinteger, m_tracepoint_action_download)
187 (r_tracepoint_action_download, x_tracepoint_action_download)
188 (l_tracepoint_action_download, clear_inferior_trace_buffer)
189 (download_agent_expr, download_tracepoint_1)
190 (download_trace_state_variables, upload_fast_traceframes): Update.
191 * server.c (gdb_write_memory): Update.
192 * remote-utils.c (relocate_instruction): Update.
193 * proc-service.c (ps_pdwrite): Update.
194 * mem-break.c (remove_memory_breakpoint)
195 (delete_fast_tracepoint_jump, set_fast_tracepoint_jump)
196 (uninsert_fast_tracepoint_jumps_at)
197 (reinsert_fast_tracepoint_jumps_at): Update.
198 * linux-x86-low.c (append_insns)
199 (i386_install_fast_tracepoint_jump_pad)
200 (amd64_write_goto_address, i386_write_goto_address): Update.
201 * linux-s390-low.c (append_insns, s390_write_goto_address):
202 Update.
203 * linux-ppc-low.c (ppc_relocate_instruction)
204 (ppc_install_fast_tracepoint_jump_pad, emit_insns)
205 (ppc_write_goto_address): Update.
206 * linux-aarch64-low.c (append_insns): Update.
207 * target.h (struct target_ops): Update.
208 (write_inferior_memory): Don't declare.
209 * target.c (target_write_memory): Rename from
210 write_inferior_memory. Remove old target_write_memory.
211
212 2019-08-15 Tom Tromey <tromey@adacore.com>
213
214 * target.c (write_inferior_memory): Use std::vector.
215
216 2019-08-06 Frank Ch. Eigler <fche@redhat.com>
217
218 PR build/24886
219 * configure.ac: Drop enable-libmcheck support.
220 * configure, config.in: Rebuild.
221 * acinclude.m4: Don't include it.
222
223 2019-07-19 Alan Hayward <alan.hayward@arm.com>
224
225 * configure.srv: Remove Arm xml files.
226
227 2019-07-19 Alan Hayward <alan.hayward@arm.com>
228
229 * configure.srv: Add new files. Remove xml generated files.
230 * linux-aarch32-low.c (initialize_low_arch_aarch32): Don't init
231 registers.
232 * linux-aarch32-low.h (tdesc_arm_with_neon): Remove.
233 * linux-aarch32-tdesc.c: New file.
234 * linux-aarch32-tdesc.h: New file.
235 * linux-aarch64-low.c (aarch64_arch_setup): Call aarch32_linux_read_description.
236 * linux-arm-low.c (init_registers_arm, tdesc_arm)
237 (init_registers_arm_with_iwmmxt, tdesc_arm_with_iwmmxt)
238 (init_registers_arm_with_vfpv2, tdesc_arm_with_vfpv2)
239 (init_registers_arm_with_vfpv3, tdesc_arm_with_vfpv3): Remove.
240 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
241 (arm_store_vfpregset): Call arm_linux_get_tdesc_fp_type.
242 (arm_read_description): Call arm_linux_read_description.
243 (initialize_low_arch): Don't init registers.
244 * linux-arm-tdesc.c: New file.
245 * linux-arm-tdesc.h: New file.
246
247 2019-07-10 Alan Hayward <alan.hayward@arm.com>
248
249 * linux-arm-low.c (arm_fill_wmmxregset, arm_store_wmmxregset):
250 Move counter inside for.
251 (arm_read_description): Check ptrace earlier.
252 (arm_arch_setup): Call arm_linux_init_hwbp_cap here.
253
254 2019-07-09 Tom Tromey <tom@tromey.com>
255
256 * configure: Rebuild.
257 * configure.ac: Change common to gdbsupport.
258 * acinclude.m4: Change common to gdbsupport.
259 * Makefile.in (SFILES, OBS, GDBREPLAY_OBS, IPA_OBJS)
260 (version-generated.c, gdbsupport/%-ipa.o, gdbsupport/%.o): Change
261 common to gdbsupport.
262 * ax.c, event-loop.c, fork-child.c, gdb_proc_service.h,
263 gdbreplay.c, gdbthread.h, hostio-errno.c, hostio.c, i387-fp.c,
264 inferiors.c, inferiors.h, linux-aarch64-tdesc-selftest.c,
265 linux-amd64-ipa.c, linux-i386-ipa.c, linux-low.c,
266 linux-tic6x-low.c, linux-x86-low.c, linux-x86-tdesc-selftest.c,
267 linux-x86-tdesc.c, lynx-i386-low.c, lynx-low.c, mem-break.h,
268 nto-x86-low.c, regcache.c, regcache.h, remote-utils.c, server.c,
269 server.h, spu-low.c, symbol.c, target.h, tdesc.c, tdesc.h,
270 thread-db.c, tracepoint.c, win32-i386-low.c, win32-low.c: Change
271 common to gdbsupport.
272
273 2019-07-04 Alan Hayward <alan.hayward@arm.com>
274
275 * linux-aarch32-low.c (arm_read_description, arm_regsets): Use new
276 defines.
277 * linux-arm-low.c (arm_read_description, arm_regsets): Likewise.
278
279 2019-07-04 Alan Hayward <alan.hayward@arm.com>
280
281 * configure.srv: Remove legacy xml.
282 * linux-aarch64-low.c (initialize_low_arch): Remove
283 initialize_low_tdesc call.
284 * linux-aarch64-tdesc-selftest.c: Remove file.
285 * linux-aarch64-tdesc.h (initialize_low_tdesc): Remove.
286 * linux-x86-low.c (initialize_low_arch): Remove
287 initialize_low_tdesc call.
288 * linux-x86-tdesc-selftest.c: Remove file.
289 * linux-x86-tdesc.h (initialize_low_tdesc): Remove.
290
291 2019-06-20 Tom de Vries <tdevries@suse.de>
292
293 * linux-s390-ipa.c (get_ipa_tdesc)[!__s390x__]: Use
294 s390_te_linux64_ft_collect_regmap for S390_TDESC_GS.
295
296 2019-06-19 Tom de Vries <tdevries@suse.de>
297
298 * debug.h (debug_write): Change return type to ssize_t.
299 * debug.c (debug_write): Same.
300
301 2019-06-14 Tom Tromey <tom@tromey.com>
302
303 * configure.ac: Use new path to gnulib.
304 * configure: Rebuild.
305 * Makefile.in (INCGNU, $(GNULIB_BUILDDIR)/Makefile): Use new path
306 to gnulib.
307
308 2019-06-11 Tom Tromey <tom@tromey.com>
309
310 * Makefile.in (SFILES): Add alloc.c.
311 (OBS): Add alloc.o.
312 (IPA_OBJS): Add alloc-ipa.o.
313 (alloc-ipa.o): New target.
314 (%.o: ../%.c): New pattern rule.
315
316 2019-06-10 Tom Tromey <tromey@adacore.com>
317
318 * remote-utils.c (look_up_one_symbol, relocate_instruction): Don't
319 end warning with a newline.
320 * linux-s390-low.c (s390_get_wordsize): Don't end warning with a
321 newline.
322 * thread-db.c (attach_thread): Don't end warning with a newline.
323 (thread_db_notice_clone): Likewise.
324 * tracepoint.c (gdb_agent_helper_thread): Don't end warning with a
325 newline.
326 * linux-x86-low.c (x86_get_min_fast_tracepoint_insn_len): Don't
327 end warning with a newline.
328
329 2019-06-04 Pedro Alves <palves@redhat.com>
330
331 * server.c (captured_main): Use make_unique_xstrdup.
332
333 2019-06-02 Tom Tromey <tom@tromey.com>
334
335 * gdbreplay.c (fromhex): Remove.
336 * Makefile.in (GDBREPLAY_OBS): Add rsp-low.o.
337
338 2019-05-29 Tom Tromey <tromey@adacore.com>
339
340 * configure: Rebuild.
341
342 2019-05-06 Kevin Buettner <kevinb@redhat.com>
343
344 * linux-x86-low.c (x86_fill_gregset): Don't compile 64-bit
345 sign extension code on 32-bit builds.
346
347 2019-05-03 Eli Zaretskii <eliz@gnu.org>
348
349 * remote-utils.c:
350 * gdbreplay.c [USE_WIN32API]: Remove the _WIN32_WINNT override.
351
352 2019-04-19 Tom Tromey <tom@tromey.com>
353
354 * server.c (struct vstop_notif): Derive from notif_event.
355 <base>: Remove.
356 (queue_stop_reply): Update.
357 (remove_all_on_match_ptid): Change type. Rewrite.
358 (discard_queued_stop_replies): Rewrite.
359 (in_queued_stop_replies_ptid): Change type.
360 (in_queued_stop_replies): Rewrite.
361 (notif_stop): Update.
362 (queue_stop_reply_callback): Update.
363 (captured_main): Don't call initialize_notif.
364 (push_stop_notification): Update.
365 * notif.c (notif_write_event, handle_notif_ack)
366 (notif_event_enque, notif_push): Update.
367 (notif_event_xfree, initialize_notif): Remove.
368 * notif.h (struct notif_event): Include <list>, not
369 "common/queue.h".
370 (struct notif_server) <queue>: Now a std::list.
371 (notif_event_p): Remove typedef.
372 (initialize_notif): Don't declare.
373 (struct notif_event): Add virtual destructor.
374
375 2019-04-17 Alan Hayward <alan.hayward@arm.com>
376
377 * ax.c (ax_vdebug): Call debug_printf.
378 * debug.c (debug_write): New function.
379 * debug.h (debug_write): New declaration.
380 * linux-low.c (sigchld_handler): Call debug_write.
381
382 2019-04-17 Alan Hayward <alan.hayward@arm.com>
383
384 * debug.c (debug_set_output): New function.
385 (debug_vprintf): Send output to debug_file.
386 (debug_flush): Likewise.
387 * debug.h (debug_set_output): New declaration.
388 * server.c (handle_monitor_command): Add debug-file option.
389 (captured_main): Likewise.
390
391 2019-04-17 Alan Hayward <alan.hayward@arm.com>
392
393 * debug.c (remote_debug): Add definition.
394 * debug.h (remote_debug): Add declaration.
395 * hostio.c (remote_debug): Remove declaration.
396 * remote-utils.c (struct ui_file): Likewise.
397 (remote_debug): Likewise.
398 * remote-utils.h (remote_debug): Likewise,
399 * server.c (remote_debug): Remove definition.
400
401 2019-04-10 Kevin Buettner <kevinb@redhat.com>
402
403 * linux-x86-low.c (x86_fill_gregset): Sign extend EAX value
404 when using a 64-bit gdbserver.
405
406 2019-04-09 Tom Tromey <tromey@adacore.com>
407
408 * linux-low.c (select_event_lwp): Use find_thread_in_random.
409
410 2019-04-08 Tom Tromey <tom@tromey.com>
411
412 * linux-low.c (linux_detach_one_lwp): Replace throw_exception with
413 throw.
414 (linux_resume_one_lwp): Likewise.
415
416 2019-04-08 Tom Tromey <tom@tromey.com>
417
418 * gdbreplay.c: Update.
419 * linux-low.c: Update.
420 * server.c: Update.
421
422 2019-04-08 Tom Tromey <tom@tromey.com>
423
424 * server.c: Use C++ exception handling.
425 * linux-low.c: Use C++ exception handling.
426 * gdbreplay.c: Use C++ exception handling.
427
428 2019-04-08 Tom Tromey <tom@tromey.com>
429
430 * server.c (handle_btrace_general_set, handle_qxfer_btrace)
431 (handle_qxfer_btrace_conf, detach_or_kill_for_exit_cleanup)
432 (captured_main, main): Update.
433 * gdbreplay.c (main): Update.
434
435 2019-04-05 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
436
437 * linux-low.c (linux_get_auxv): Remove static. Return auxv entry
438 value in argument pointer, return 1 if the entry is found and 0
439 otherwise. Move comment.
440 (linux_get_hwcap, linux_get_hwcap2): Use modified linux_get_auxv.
441 * linux-low.h (linux_get_auxv): Declare.
442 * linux-ppc-low.c (is_elfv2_inferior): Use linux_get_auxv.
443
444 2019-04-05 Tom Tromey <tromey@adacore.com>
445
446 * server.c (gdbserver_usage): Use upper-case for metasyntactic
447 variables.
448
449 2019-03-28 Alan Hayward <alan.hayward@arm.com>
450
451 * linux-low.c (AT_HWCAP2): Add define if not already included.
452
453 2019-03-26 Alan Hayward <alan.hayward@arm.com>
454
455 * linux-aarch64-low.c (aarch64_get_hwcap): Remove function.
456 (aarch64_arch_setup): Call linux_get_hwcap.
457 * linux-arm-low.c (arm_get_hwcap): Remove function.
458 (arm_read_description): Call linux_get_hwcap.
459 * linux-low.c (linux_get_auxv): New function.
460 (linux_get_hwcap): Likewise.
461 (linux_get_hwcap2): Likewise.
462 * linux-low.h (linux_get_hwcap): New declaration.
463 (linux_get_hwcap2): Likewise.
464 * linux-ppc-low.c (ppc_get_auxv): Remove function.
465 (ppc_arch_setup): Call linux_get_hwcap.
466 * linux-s390-low.c (s390_get_hwcap): Remove function.
467 (s390_arch_setup): Call linux_get_hwcap.
468
469 2019-03-22 Alan Hayward <alan.hayward@arm.com>
470 Jiong Wang <jiong.wang@arm.com>
471
472 * linux-aarch64-low.c (aarch64_store_pauthregset): New function.
473 * linux-low.c (regsets_store_inferior_registers): Allow optional reads
474 to fail.
475 * linux-low.h (enum regset_type): Add OPTIONAL_REGS.
476
477 2019-03-22 Alan Hayward <alan.hayward@arm.com>
478 Jiong Wang <jiong.wang@arm.com>
479
480 * linux-aarch64-low.c (AARCH64_HWCAP_PACA): New define.
481 (aarch64_get_hwcap): New function.
482 (aarch64_arch_setup): Read APIA hwcap.
483
484 2019-03-22 Alan Hayward <alan.hayward@arm.com>
485 Jiong Wang <jiong.wang@arm.com>
486
487 * linux-aarch64-ipa.c (get_ipa_tdesc): Add pauth param.
488 (initialize_low_tracepoint): Likewise.
489 * linux-aarch64-low.c (aarch64_arch_setup): Likewise.
490 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Likewise.
491 * linux-aarch64-tdesc.c (struct target_desc): Likewise.
492 (aarch64_linux_read_description): Likewise.
493 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Likewise.
494
495 2019-03-12 John Baldwin <jhb@FreeBSD.org>
496
497 * linux-x86-tdesc.c (i386_linux_read_description): Update call to
498 i386_create_target_description for 'segments' parameter.
499 * lynx-i386-low.c (lynx_i386_arch_setup): Likewise.
500 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
501 * win32-i386-low.c (i386_arch_setup): Likewise.
502
503 2019-03-12 Tom Tromey <tromey@adacore.com>
504
505 * linux-low.c (iterate_over_lwps): Update.
506
507 2019-03-06 Tom Tromey <tom@tromey.com>
508
509 * server.c (detach_or_kill_for_exit_cleanup): Remove parameter.
510 (captured_main): Use SCOPE_EXIT.
511
512 2019-03-04 Sergio Durigan Junior <sergiodj@redhat.com>
513
514 * configure.srv: Use '$enable_unittest' instead of '$development'
515 when checking whether to fill 'srv_regobj' on 'aarch64*-*-linux*'
516 case.
517
518 2019-02-27 Tom Tromey <tromey@adacore.com>
519
520 * gdbreplay.c (logchar): Handle \r\n.
521
522 2019-02-07 Alan Hayward <alan.hayward@arm.com>
523
524 * linux-low.c (linux_attach): Add process before lwp.
525 * server.c (attach_inferior): Check if already attached.
526
527 2019-02-07 Tom Tromey <tom@tromey.com>
528
529 * x86-tdesc.h: Rename include guard.
530 * x86-low.h: Add include guard.
531 * wincecompat.h: Rename include guard.
532 * win32-low.h: Add include guard.
533 * utils.h: Rename include guard.
534 * tracepoint.h: Rename include guard.
535 * tdesc.h: Rename include guard.
536 * target.h: Rename include guard.
537 * server.h: Rename include guard.
538 * remote-utils.h: Rename include guard.
539 * regcache.h: Rename include guard.
540 * nto-low.h: Rename include guard.
541 * notif.h: Add include guard.
542 * mem-break.h: Rename include guard.
543 * lynx-low.h: Add include guard.
544 * linux-x86-tdesc.h: Add include guard.
545 * linux-s390-tdesc.h: Add include guard.
546 * linux-ppc-tdesc-init.h: Add include guard.
547 * linux-low.h: Add include guard.
548 * linux-aarch64-tdesc.h: Add include guard.
549 * linux-aarch32-low.h: Add include guard.
550 * inferiors.h: Rename include guard.
551 * i387-fp.h: Rename include guard.
552 * hostio.h: Rename include guard.
553 * gdbthread.h: Rename include guard.
554 * gdb_proc_service.h: Rename include guard.
555 * event-loop.h: Rename include guard.
556 * dll.h: Rename include guard.
557 * debug.h: Rename include guard.
558 * ax.h: Rename include guard.
559
560 2018-01-30 Szabolcs Nagy <szabolcs.nagy@arm.com>
561
562 PR gdb/23985
563 * Makefile.in (IPAGENT_CFLAGS): Add UNDO_GNULIB_CFLAGS.
564 (UNDO_GNULIB_CFLAGS): Undo gnulib replacements.
565
566 2019-01-25 Tom Tromey <tom@tromey.com>
567
568 * Makefile.in (INCLUDE_CFLAGS): Don't add -I for common.
569
570 2019-01-25 Tom Tromey <tom@tromey.com>
571
572 * win32-low.c: Fix common/ includes.
573 * win32-i386-low.c: Fix common/ includes.
574 * tracepoint.c: Fix common/ includes.
575 * thread-db.c: Fix common/ includes.
576 * target.h: Fix common/ includes.
577 * symbol.c: Fix common/ includes.
578 * spu-low.c: Fix common/ includes.
579 * server.h: Fix common/ includes.
580 * server.c: Fix common/ includes.
581 * remote-utils.c: Fix common/ includes.
582 * regcache.h: Fix common/ includes.
583 * regcache.c: Fix common/ includes.
584 * nto-x86-low.c: Fix common/ includes.
585 * notif.h: Fix common/ includes.
586 * mem-break.h: Fix common/ includes.
587 * lynx-low.c: Fix common/ includes.
588 * lynx-i386-low.c: Fix common/ includes.
589 * linux-x86-tdesc-selftest.c: Fix common/ includes.
590 * linux-x86-low.c: Fix common/ includes.
591 * linux-low.c: Fix common/ includes.
592 * inferiors.h: Fix common/ includes.
593 * i387-fp.c: Fix common/ includes.
594 * hostio.c: Fix common/ includes.
595 * hostio-errno.c: Fix common/ includes.
596 * gdbthread.h: Fix common/ includes.
597 * gdbreplay.c: Fix common/ includes.
598 * fork-child.c: Fix common/ includes.
599 * event-loop.c: Fix common/ includes.
600 * ax.c:
601 (enum gdb_agent_op): Fix common/ includes.
602
603 2019-01-21 Tom Tromey <tom@tromey.com>
604
605 * tracepoint.c: Fix includes.
606 * remote-utils.c: Fix includes.
607 * linux-x86-low.c: Fix includes.
608
609 2019-01-01 Joel Brobecker <brobecker@adacore.com>
610
611 * gdbreplay.c (gdbreplay_version): Update copyright year in
612 version message.
613 * server.c (gdbserver_version): Likewise.
614
615 2018-12-05 Alan Hayward <alan.hayward@arm.com>
616
617 * linux-low.c (add_lwp): Switch ordering.
618
619 2018-11-29 Tom Tromey <tom@tromey.com>
620
621 * win32-low.c (win32_join): Take pid, not process.
622 * target.h (struct target_ops) <join>: Change argument type.
623 (join_inferior): Change argument name.
624 * spu-low.c (spu_join): Take pid, not process.
625 * server.c (handle_detach): Preserve pid before destroying
626 process.
627 * lynx-low.c (lynx_join): Take pid, not process.
628 * linux-low.c (linux_join): Take pid, not process.
629
630 2018-11-23 Alan Hayward <alan.hayward@arm.com>
631
632 * linux-aarch64-low.c (aarch64_cannot_store_register): Remove.
633 (aarch64_cannot_fetch_register): Likewise.
634 (struct linux_target_ops): Update references.
635
636 2018-10-31 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
637
638 * linux-ppc-low.c: Include nat/linux-ptrace.h.
639
640 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
641
642 * configure.srv (ipa_ppc_linux_regobj): Add
643 powerpc-isa207-htm-vsx32l-ipa.o and
644 powerpc-isa207-htm-vsx64l-ipa.o.
645 (powerpc*-*-linux*): Add powerpc-isa207-htm-vsx32l.o and
646 powerpc-isa207-htm-vsx64l.o to srv_regobj. Add
647 rs6000/power-htm-spr.xml, rs6000/power-htm-core.xml,
648 rs6000/power64-htm-core.xml, rs6000/power-htm-fpu.xml,
649 rs6000/power-htm-altivec.xml, rs6000/power-htm-vsx.xml,
650 rs6000/power-htm-ppr.xml, rs6000/power-htm-dscr.xml,
651 rs6000/power-htm-tar.xml, rs6000/powerpc-isa207-htm-vsx32l.xml,
652 and rs6000/powerpc-isa207-htm-vsx64l.xml to srv_xmlfiles.
653 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
654 <PPC_TDESC_ISA207_HTM_VSX>: New enum value.
655 (init_registers_powerpc_isa207_htm_vsx32l)
656 (init_registers_powerpc_isa207_htm_vsx64l): Declare.
657 * linux-ppc-low.c (ppc_fill_tm_sprregset, ppc_store_tm_sprregset)
658 (ppc_store_tm_cgprregset, ppc_store_tm_cfprregset)
659 (ppc_store_tm_cvrregset, ppc_store_tm_cvsxregset)
660 (ppc_store_tm_cpprregset, ppc_store_tm_cdscrregset)
661 (ppc_store_tm_ctarregset): New functions.
662 (ppc_regsets): Add entries for HTM regsets.
663 (ppc_arch_setup): Set htm in features struct when needed. Set
664 sizes for the HTM regsets.
665 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_HTM_VSX.
666 (initialize_low_arch): Call
667 init_registers_powerpc_isa207_htm_vsx32l and
668 init_registers_powerpc_isa207_htm_vsx64l.
669 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
670 PPC_TDESC_ISA207_HTM_VSX.
671 (initialize_low_tracepoint): Call
672 init_registers_powerpc_isa207_htm_vsx32l and
673 init_registers_powerpc_isa207_htm_vsx64l.
674
675 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
676
677 * configure.srv (powerpc*-*-linux*): Add rs6000/power-ebb.xml and
678 rs6000/power-linux-pmu.xml to srv_xmlfiles.
679 * linux-ppc-low.c (ppc_store_ebbregset, ppc_fill_pmuregset)
680 (ppc_store_pmuregset): New functions.
681 (ppc_regsets): Add entries for ebb and pmu regsets.
682 (ppc_arch_setup): Set isa207 in features struct if the ebb and
683 pmu regsets are available. Set sizes for these regsets.
684
685 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
686
687 * configure.srv (ipa_ppc_linux_regobj): Add
688 powerpc-isa207-vsx64l-ipa.o and powerpc-isa207-vsx32l-ipa.o.
689 (powerpc*-*-linux*): Add powerpc-isa207-vsx32l.o and
690 powerpc-isa207-vsx64l.o to srv_regobj, add rs6000/power-tar.xml,
691 rs6000/powerpc-isa207-vsx32l.xml, and
692 rs6000/powerpc-isa207-vsx64l.xml to srv_xmlfiles.
693 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
694 <PPC_TDESC_ISA207_VSX>: New enum value.
695 (init_registers_powerpc_isa207_vsx32l): Declare.
696 (init_registers_powerpc_isa207_vsx64l): Declare.
697 * linux-ppc-low.c (ppc_fill_tarregset): New function.
698 (ppc_store_tarregset): New function.
699 (ppc_regsets): Add entry for the TAR regset.
700 (ppc_arch_setup): Set isa207 in features struct when needed. Set
701 size for the TAR regsets.
702 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA207_VSX.
703 (initialize_low_arch): Call init_registers_powerpc_isa207_vsx32l
704 and init_registers_powerpc_isa207_vsx64l.
705 * linux-ppc-ipa.c (get_ipa_tdesc): Handle PPC_TDESC_ISA207_VSX.
706 (initialize_low_tracepoint): Call
707 init_registers_powerpc_isa207_vsx32l and
708 init_registers_powerpc_isa207_vsx64l.
709
710 2018-10-26 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
711 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
712
713 * configure.srv (ipa_ppc_linux_regobj): Add
714 powerpc-isa205-ppr-dscr-vsx32l-ipa.o and
715 powerpc-isa205-ppr-dscr-vsx64l-ipa.o.
716 (powerpc*-*-linux*): Add powerpc-isa205-ppr-dscr-vsx32l.o and
717 powerpc-isa205-ppr-dscr-vsx64l.o to srv_regobj, add
718 rs6000/power-dscr.xml, rs6000/power-ppr.xml,
719 rs6000/powerpc-isa205-ppr-dscr-vsx32l.xml and
720 rs6000/powerpc-isa205-ppr-dscr-vsx64l.xml to srv_xmlfiles.
721 * linux-ppc-tdesc-init.h (enum ppc_linux_tdesc)
722 <PPC_TDESC_ISA205_PPR_DSCR_VSX>: New enum value.
723 (init_registers_powerpc_isa205_ppr_dscr_vsx32l)
724 (init_registers_powerpc_isa205_ppr_dscr_vsx64l): Declare.
725 * linux-ppc-low.c: Include "elf/common.h" and <sys/uio.h>.
726 (ppc_hwcap): Add comment.
727 (ppc_hwcap2): New global.
728 (ppc_check_regset, ppc_fill_pprregset, ppc_store_pprregset)
729 (ppc_fill_dscrregset, ppc_store_dscrregset): New functions.
730 (ppc_regsets): Add entries for the DSCR and PPR regsets.
731 (ppc_arch_setup): Get AT_HWCAP2. Set ppr_dscr in features struct
732 when needed. Set sizes for the the DSCR and PPR regsets.
733 (ppc_get_ipa_tdesc_idx): Return PPC_TDESC_ISA205_PPR_DSCR_VSX.
734 (initialize_low_arch): Call
735 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
736 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
737 * linux-ppc-ipa.c (get_ipa_tdesc): Handle
738 PPC_TDESC_ISA205_PPR_DSCR_VSX.
739 (initialize_low_tracepoint): Call
740 init_registers_powerpc_isa205_ppr_dscr_vsx32l and
741 init_registers_powerpc_isa205_ppr_dscr_vsx64l.
742
743 2018-10-26 Pedro Franco de Carvalho <pedromfc@linux.ibm.com>
744
745 * linux-ppc-low.c (ppc_fill_vrregset): Remove memset calls.
746
747 2018-10-10 Sergio Durigan Junior <sergiodj@redhat.com>
748 Simon Marchi <simark@simark.ca>
749
750 * acinclude.m4: Include "../selftest.m4".
751 * configure: Regenerate.
752 * configure.ac: Use "GDB_AC_SELFTEST".
753 * configure.srv: Use "$enable_unittests" instead of
754 "$development" when checking whether unit tests have been
755 enabled.
756 * server.c (captured_main): Update message informing that
757 selftests have been disabled.
758
759 2018-10-04 Tom Tromey <tom@tromey.com>
760
761 * configure: Rebuild.
762
763 2018-10-04 Tom Tromey <tom@tromey.com>
764
765 * server.c (handle_status): Rename inner "thread".
766 (process_serial_event): Declare "res" in 'm' case.
767 * linux-low.c (last_thread_of_process_p, find_lwp_pid)
768 (iterate_over_lwps): Rename inner "thread".
769 (linux_qxfer_libraries_svr4): Rename inner "len".
770 * gdbthread.h (find_thread_in_random): Rename inner "thread".
771
772 2018-10-01 Gary Benson <gbenson@redhat.com>
773
774 * gdb_proc_service.h: Moved common code to
775 common/gdb_proc_service.h.
776
777 2018-10-01 Gary Benson <gbenson@redhat.com>
778
779 * gdb_proc_service.h: Synchronize comments and whitespace with
780 GDB's version of this file.
781
782 2018-09-25 Tom Tromey <tom@tromey.com>
783
784 * configure: Rebuild.
785 * configure.ac (WARN_CFLAGS): Don't remove -Wmissing-prototypes.
786
787 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
788
789 * Makefile.in (gdbserver$(EXEEXT)): Sort OBS.
790 (gdbreplay$(EXEEXT)): Sort GDBREPLAY_OBS.
791 ($(IPA_LIB)): Sort IPA_OBJS.
792
793 2018-09-16 Simon Marchi <simon.marchi@polymtl.ca>
794
795 * Makefile.in: Remove references to $(ADD_DEPS).
796
797 2018-09-16 Tom Tromey <tom@tromey.com>
798
799 * remote-utils.c (remote_open): Use GNU style for metasyntactic
800 variables.
801 * gdbreplay.c (gdbreplay_usage): Use GNU style for metasyntactic
802 variables.
803
804 2018-09-05 Tom Tromey <tom@tromey.com>
805
806 * configure: Rebuild.
807
808 2018-08-28 Simon Marchi <simon.marchi@polymtl.ca>
809
810 PR build/23399
811 * tracepoint.c (IPA_SYM_STRUCT_NAME): Define.
812
813 2018-08-27 Tom Tromey <tom@tromey.com>
814
815 PR build/23087:
816 * configure: Rebuild.
817
818 2018-08-27 Tom Tromey <tom@tromey.com>
819
820 * linux-s390-low.c (s390_emit_ext, s390_emit_litpool)
821 (s390_emit_const, s390_emit_reg, s390_emit_zero_ext)
822 (s390_emit_stack_adjust, s390_emit_set_r2, s390x_emit_ext)
823 (s390x_emit_const, s390x_emit_reg, s390x_emit_zero_ext)
824 (s390x_emit_stack_adjust): Add casts to unsigned char.
825
826 2018-08-22 Simon Marchi <simon.marchi@ericsson.com>
827
828 PR gdb/23374
829 PR gdb/23375
830 * server.h (struct client_state) <disable_randomization>:
831 Initialize to 1.
832
833 2018-07-22 Simon Marchi <simon.marchi@polymtl.ca>
834
835 * linux-mips-low.c (mips_collect_ptrace_register): Remove unused
836 variable.
837 (mips_supply_ptrace_register): Likewise.
838
839 2018-07-22 Tom Tromey <tom@tromey.com>
840
841 * configure: Rebuild.
842
843 2018-07-22 Tom Tromey <tom@tromey.com>
844
845 * win32-low.c (win32_create_inferior): Remove unused variables.
846 * gdbreplay.c (remote_open): Remove unused variable.
847 * remote-utils.c (remote_prepare): Remove unused variable.
848 * x86-tdesc.h (X86_TDESC_H): Define.
849 (amd64_expedite_regs): Define conditionally.
850 (i386_expedite_regs): Mark ATTRIBUTE_UNUSED.
851 * linux-x86-tdesc.c (i386_tdescs): Move inside #if.
852 * remote-utils.c (readchar): Remove unused variable.
853
854 2018-07-13 Pedro Alves <palves@redhat.com>
855
856 * linux-low.c (linux_kill): Change parameter to process_info
857 pointer instead of pid. Adjust.
858 * lynx-low.c (lynx_kill): Likewise.
859 * nto-low.c (nto_kill): Likewise.
860 * spu-low.c (spu_kill): Likewise.
861 * win32-low.c (win32_kill): Likewise.
862 * server.c (handle_v_kill, kill_inferior_callback)
863 (detach_or_kill_for_exit): Adjust.
864 * target.c (kill_inferior): Change parameter to process_info
865 pointer instead of pid. Adjust.
866 * target.h (struct target_ops) <kill>: Change parameter to
867 process_info pointer instead of pid. Adjust all implementations
868 and callers.
869 (kill_inferior): Likewise.
870
871 2018-07-13 Pedro Alves <palves@redhat.com>
872
873 * linux-low.c (linux_detach, linux_join): Change parameter to
874 process_info pointer instead of pid. Adjust.
875 * lynx-low.c (lynx_detach, lynx_join): Likewise.
876 * nto-low.c (nto_detach): Likewise.
877 * spu-low.c (spu_detach, spu_join): Likewise.
878 * win32-low.c (win32_detach, win32_join): Likewise.
879 * server.c (handle_detach, detach_or_kill_for_exit): Adjust.
880 * target.h (struct target_ops) <detach, join>: Change parameter to
881 process_info pointer instead of pid. Adjust all implementations
882 and callers.
883 (detach_inferior, join_inferior): Rename 'pid' parameter to
884 'proc'.
885
886 2018-07-11 Sergio Durigan Junior <sergiodj@redhat.com>
887 Jan Kratochvil <jan.kratochvil@redhat.com>
888 Paul Fertser <fercerpav@gmail.com>
889 Tsutomu Seki <sekiriki@gmail.com>
890
891 * Makefile.in (SFILES): Add '$(srcdir)/common/netstuff.c'.
892 (OBS): Add 'common/netstuff.o'.
893 (GDBREPLAY_OBS): Likewise.
894 * gdbreplay.c: Include 'wspiapi.h' and 'netstuff.h'.
895 (remote_open): Implement support for IPv6
896 connections.
897 * remote-utils.c: Include 'netstuff.h', 'filestuff.h'
898 and 'wspiapi.h'.
899 (handle_accept_event): Accept connections from IPv6 sources.
900 (remote_prepare): Handle IPv6-style hostnames; implement
901 support for IPv6 connections.
902 (remote_open): Implement support for printing connections from
903 IPv6 sources.
904
905 2018-07-11 Pedro Alves <palves@redhat.com>
906
907 PR gdb/23377
908 * mem-break.c (any_persistent_commands): Add process_info
909 parameter and use it instead of relying on the current process.
910 Change return type to bool.
911 * mem-break.h (any_persistent_commands): Add process_info
912 parameter and change return type to bool.
913 * server.c (handle_detach): Remove require_running_or_return call.
914 Look up the process_info for the process we're about to detach.
915 If not found, return back error to GDB. Adjust
916 any_persistent_commands call to pass down a process pointer.
917
918 2018-07-11 Pedro Alves <palves@redhat.com>
919
920 * i387-fp.c (i387_cache_to_fsave, cache_to_fxsave)
921 (i387_cache_to_xsave): Use regcache_raw_get_unsigned_by_name
922 instead of collect_register_by_name.
923 * regcache.c (regcache_raw_get_unsigned_by_name): New.
924 * regcache.h (regcache_raw_get_unsigned_by_name): New.
925
926 2018-07-04 Vyacheslav Barinov <v.barinov@samsung.com>
927 Pedro Alves <palves@redhat.com>
928
929 * linux-low.c (initialize_low): Call linux_proc_init_warnings.
930
931 2018-07-03 Tom Tromey <tom@tromey.com>
932
933 * linux-low.c: Update.
934 * lynx-low.c: Update.
935 * mem-break.c: Update.
936 * nto-low.c: Update.
937 * remote-utils.c: Update.
938 * server.c: Update.
939 * spu-low.c: Update.
940 * target.c: Update.
941 * win32-low.c: Update.
942
943 2018-07-03 Tom Tromey <tom@tromey.com>
944
945 * server.c: Update.
946
947 2018-07-03 Tom Tromey <tom@tromey.com>
948
949 * linux-low.c: Update.
950
951 2018-07-03 Tom Tromey <tom@tromey.com>
952
953 * target.c: Update.
954
955 2018-07-03 Tom Tromey <tom@tromey.com>
956
957 * linux-low.c: Update.
958 * linux-mips-low.c: Update.
959 * lynx-low.c: Update.
960 * nto-low.c: Update.
961 * remote-utils.c: Update.
962 * server.c: Update.
963 * spu-low.c: Update.
964 * target.c: Update.
965 * thread-db.c: Update.
966
967 2018-07-03 Tom Tromey <tom@tromey.com>
968
969 * linux-low.c: Update.
970 * linux-mips-low.c: Update.
971 * lynx-low.c: Update.
972 * mem-break.c: Update.
973 * nto-low.c: Update.
974 * remote-utils.c: Update.
975 * server.c: Update.
976 * spu-low.c: Update.
977 * target.c: Update.
978 * tracepoint.c: Update.
979
980 2018-07-03 Tom Tromey <tom@tromey.com>
981
982 * linux-low.c: Update.
983 * linux-ppc-low.c: Update.
984 * linux-x86-low.c: Update.
985 * proc-service.c: Update.
986 * server.c: Update.
987 * spu-low.c: Update.
988 * thread-db.c: Update.
989 * win32-low.c: Update.
990
991 2018-07-03 Tom Tromey <tom@tromey.com>
992
993 * linux-low.c: Update.
994 * lynx-low.c: Update.
995 * nto-low.c: Update.
996 * remote-utils.c: Update.
997 * spu-low.c: Update.
998 * thread-db.c: Update.
999 * win32-low.c: Update.
1000
1001 2018-06-29 Joel Brobecker <brobecker@adacore.com>
1002
1003 * linux-x86-tdesc.c (amd64_linux_read_description): Add missing
1004 parameter in call to 'amd64_create_target_description'.
1005
1006 2018-06-28 Jan Kratochvil <jan.kratochvil@redhat.com>
1007
1008 * x86-tdesc.h: Remove executable permission flag.
1009
1010 2018-06-19 Simon Marchi <simon.marchi@ericsson.com>
1011
1012 * configure.ac: Remove AC_PREREQ, add missing quoting.
1013 * configure: Re-generate.
1014 * config.in: Re-generate.
1015 * aclocal.m4: Re-generate.
1016
1017 2018-06-18 Simon Marchi <simon.marchi@ericsson.com>
1018
1019 * tracepoint.h (current_traceframe): Remove declaration.
1020
1021 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1022
1023 * linux-aarch64-low.c (is_sve_tdesc): New function.
1024 (aarch64_sve_regs_copy_to_regcache): Likewise.
1025 (aarch64_sve_regs_copy_from_regcache): Likewise.
1026 (aarch64_regs_info): Add SVE checks.
1027 (initialize_low_arch): Initialize SVE.
1028
1029 2018-06-18 Alan Hayward <alan.hayward@arm.com>
1030
1031 * Makefile.in: Add aarch64-sve-linux-ptrace.c.
1032
1033 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1034
1035 * linux-aarch64-ipa.c (get_ipa_tdesc): Add null VQ param.
1036 (initialize_low_tracepoint): Likewise
1037 * linux-aarch64-low.c (aarch64_arch_setup): Get VQ.
1038 * linux-aarch64-tdesc-selftest.c (aarch64_tdesc_test): Add null VQ
1039 param.
1040 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add VQ
1041 checks.
1042 * linux-aarch64-tdesc.h (aarch64_linux_read_description): Add VQ.
1043
1044 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1045
1046 * server.h (PBUFSIZ): Increase size
1047
1048 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1049
1050 * regcache.c (regcache::raw_compare): New function.
1051 * regcache.h (regcache::raw_compare): New declaration.
1052
1053 2018-06-11 Alan Hayward <alan.hayward@arm.com>
1054
1055 * regcache.c (new_register_cache): Use new.
1056 (free_register_cache): Use delete.
1057 (register_data): Use const.
1058 (supply_register): Move body inside regcache.
1059 (regcache::raw_supply): New override function.
1060 (collect_register): Move body inside regcache.
1061 (regcache::raw_collect): New override function.
1062 (regcache::get_register_status): New override function.
1063 * regcache.h (struct regcache): Inherit from reg_buffer_common.
1064
1065 2018-06-09 Tom Tromey <tom@tromey.com>
1066
1067 * event-loop.c (gdb_event, gdb_event_p): Remove typedefs. Don't
1068 declare queue.
1069 (event_queue): Use std::queue.
1070 (gdb_event_xfree): Remove.
1071 (initialize_event_loop, process_event, wait_for_event): Update.
1072
1073 2018-06-08 Stan Cox <scox@redhat.com>
1074
1075 * win32-low.c (win32_create_inferior): last_ptid and last_status
1076 moved to client_state.
1077
1078 2018-06-08 Pedro Alves <palves@redhat.com>
1079
1080 * Makefile.in (GDBREPLAY_OBS): Add common/cleanups.o,
1081 common/common-exceptions.o, common/common-utils.o,
1082 common/errors.o, common/print-utils.o and utils.o.
1083 * gdbreplay.c: Include "common-defs.h" instead of the two
1084 'config.h's here. Don't include stdio.h, errno.h, stdlib.h,
1085 string.h or alloca.h.
1086 (perror_with_name): Delete.
1087 (remote_open): Use xstrdup instead of strdup.
1088 (main): Rename to ...
1089 (captured_main): ... this.
1090 (main): New.
1091
1092 2018-06-08 Tom Tromey <tom@tromey.com>
1093
1094 * linux-low.c (linux_low_read_btrace): Update.
1095
1096 2018-06-04 Stan Cox <scox@redhat.com>
1097
1098 * server.h (struct client_state): New.
1099 * server.c (cont_thread, general_thread, multi_process)
1100 (report_fork_events, report_vfork_events, report_exec_events)
1101 (report_thread_events, swbreak_feature, hwbreak_feature)
1102 (vCont_supported, disable_randomization, pass_signals)
1103 (program_signals, program_signals_p, last_status, last_ptid, own_buf):
1104 Moved to client_state.
1105 * remote-utils.c (remote_debug, noack_mode)
1106 (transport_is_reliable): Moved to client_state.
1107 * tracepoint.c (current_traceframe): Moved to client_state.
1108
1109 Update all callers.
1110 * server.c, remote-utils.c, tracepoint.c, fork-child.c,
1111 linux-low.c, remote-utils.h, target.c: Use client_state.
1112
1113 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1114
1115 * configure.srv: Add new c/h file.
1116
1117 2018-05-31 Alan Hayward <alan.hayward@arm.com>
1118
1119 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add
1120 null VQ.
1121
1122 2018-05-25 Maciej W. Rozycki <macro@mips.com>
1123
1124 * gdb.arch/mips-fpregset-core.exp: New test.
1125 * gdb.arch/mips-fpregset-core.c: New test source.
1126
1127 2018-05-23 Erik Kurzinger <ekurzinger@nvidia.com>
1128
1129 PR server/23198
1130 * hostio.c (require_int): Do not report overflow for integers
1131 between 0xfffffff and 0x7fffffff.
1132
1133 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1134
1135 * linux-mips-low.c [HAVE_PTRACE_GETREGS] (mips_collect_register)
1136 (mips_supply_register): Move outside HAVE_PTRACE_GETREGS.
1137 (mips_collect_ptrace_register, mips_supply_ptrace_register): New
1138 functions.
1139 (the_low_target): Wire them.
1140
1141 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1142
1143 * linux-ppc-low.c (ppc_fill_vrregset): Add vscr_offset variable.
1144 Set vscr_offset to 0 in little-endian mode and 12 in big-endian
1145 mode. Call collect_register_by_name with vscr using
1146 vscr_offset. Zero-pad vscr and vrsave fields in collector buffer.
1147 (ppc_store_vrregset): Add and set vscr_offset variable as in
1148 ppc_fill_vrregset. Call supply_register_by_name with vscr using
1149 vscr_offset.
1150
1151 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1152
1153 * linux-ppc-low.c (SIZEOF_VSXREGS, SIZEOF_VRREGS): Remove.
1154 (ppc_arch_setup): Change SIZEOF_VRREGS and SIZEOF_VSXREGS to
1155 PPC_LINUX_SIZEOF_VRREGSET and PPC_LINUX_SIZEOF_VSXREGSET.
1156
1157 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1158
1159 * linux-ppc-low.c (ppc_fill_vsxregset): Remove ppc_hwcap check.
1160 (ppc_store_vsxregset): Likewise.
1161 (ppc_fill_vrregset): Likewise.
1162 (ppc_store_vrregset): Likewise.
1163 (ppc_fill_evrregset): Likewise.
1164 (ppc_store_evrregset): Likewise.
1165 (ppc_regsets): Set VSX/VR/EVR regset sizes to 0.
1166 (ppc_arch_setup): Iterate through ppc_regsets and set sizes when
1167 needed.
1168
1169 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1170
1171 * linux-ppc-low.c (ppc_arch_setup): Remove code for getting the
1172 wordsize of the inferior. Call ppc_linux_target_wordsize.
1173
1174 2018-05-22 Pedro Franco de Carvalho <pedromfc@linux.vnet.ibm.com>
1175
1176 * configure.srv (srv_tgtobj): Add arch/ppc-linux-common.o.
1177 * Makefile.in (SFILES): Add arch/ppc-linux-common.c.
1178 * linux-ppc-tdesc.h: Rename to linux-ppc-tdesc-init.h.
1179 * linux-ppc-tdesc-init.h (tdesc_powerpc_32l, tdesc_powerpc_64l)
1180 (tdesc_powerpc_altivec32l, tdesc_powerpc_altivec64l)
1181 (tdesc_powerpc_cell32l, tdesc_powerpc_cell64l)
1182 (tdesc_powerpc_vsx32l, tdesc_powerpc_vsx64l)
1183 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_64l)
1184 (tdesc_powerpc_isa205_altivec32l, tdesc_powerpc_isa205_altivec64l)
1185 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_isa205_vsx64l)
1186 (tdesc_powerpc_e500l): Remove.
1187 * linux-ppc-ipa.c: Include arch/ppc-linux-tdesc.h and
1188 linux-ppc-tdesc-init.h. Don't include linux-ppc-tdesc.h.
1189 * linux-ppc-low.c: Include arch/ppc-linux-common.h,
1190 arch/ppc-linux-tdesc.h, and linux-ppc-tdesc-init.h. Don't include
1191 linux-ppc-tdesc.h.
1192 (ppc_arch_setup): Remove target description matching code. Fill a
1193 ppc_linux_features struct and call ppc_linux_match_description
1194 with it.
1195
1196 2018-05-22 Maciej W. Rozycki <macro@mips.com>
1197
1198 * linux-mips-low.c (mips_cannot_fetch_register): Return 1 if the
1199 width of the requested register exceeds the width of the
1200 `ptrace' data type.
1201 (mips_cannot_store_register): Likewise.
1202
1203 2018-05-21 Maciej W. Rozycki <macro@mips.com>
1204
1205 * linux-mips-low.c (mips_fetch_register): New function. Update
1206 preceding comment.
1207 (mips_store_gregset): Supply 0 rather than $restart for $zero.
1208 (the_low_target): Wire `mips_fetch_register'.
1209
1210 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1211
1212 * lynx-i386-low.c (LYNXOS_178): New macro.
1213 [LYNXOS_178] (usr_fcontext_t): Provide a definition that matches
1214 the layout on LynxOS-178.
1215 (lynx_i386_fill_fpregset, lynx_i386_store_fpregset): Do not
1216 handle floating point registers that are not supported by
1217 LynxOS-178.
1218
1219 2018-05-10 Tom Tromey <tom@tromey.com>
1220
1221 * configure: Rebuild.
1222
1223 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1224
1225 PR server/23158:
1226 * tdesc.h (init_target_desc) <expedite_regs>: New parameter.
1227 * tdesc.c (init_target_desc) <expedite_regs>: New parameter.
1228 Use it to set the expedite_regs field in the given tdesc.
1229 * x86-tdesc.h: New file.
1230 * linux-aarch64-tdesc.c (aarch64_linux_read_description):
1231 Adjust following the addition of the new expedite_regs parameter
1232 to init_target_desc.
1233 * linux-tic6x-low.c (tic6x_read_description): Likewise.
1234 * linux-x86-tdesc.c: #include "x86-tdesc.h".
1235 (i386_linux_read_description, amd64_linux_read_description):
1236 Adjust following the addition of the new expedite_regs parameter
1237 to init_target_desc.
1238 * lynx-i386-low.c: #include "x86-tdesc.h".
1239 (lynx_i386_arch_setup): Adjust following the addition of the new
1240 expedite_regs parameter to init_target_desc.
1241 * nto-x86-low.c: #include "x86-tdesc.h".
1242 (nto_x86_arch_setup): Adjust following the addition of the new
1243 expedite_regs parameter to init_target_desc.
1244 * win32-i386-low.c: #include "x86-tdesc.h".
1245 (i386_arch_setup): Adjust following the addition of the new
1246 expedite_regs parameter to init_target_desc.
1247
1248 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1249
1250 PR server/23158:
1251 * win32-low.c (win32_create_inferior): Add call to my_wait
1252 setting last_status global.
1253
1254 2018-05-10 Joel Brobecker <brobecker@adacore.com>
1255
1256 PR server/23158:
1257 * win32-low.c (create_process): Only call gdb_tilde_expand if
1258 inferior_cwd is not NULL.
1259
1260 2018-05-08 Andrew Burgess <andrew.burgess@embecosm.com>
1261
1262 * i387-fp.c (i387_cache_to_xsave): Only write x87 control
1263 registers to the cache if their values have changed.
1264 (i387_xsave_to_cache): Provide default values for x87 control
1265 registers when these features are available, but disabled.
1266 * regcache.c (supply_register_by_name_zeroed): New function.
1267 * regcache.h (supply_register_by_name_zeroed): Declare new
1268 function.
1269
1270 2018-05-07 Tom Tromey <tom@tromey.com>
1271
1272 * configure: Rebuild.
1273
1274 2018-05-04 Tom Tromey <tom@tromey.com>
1275
1276 * configure: Rebuild.
1277
1278 2018-05-04 Jan Kratochvil <jan.kratochvil@redhat.com>
1279 Pedro Alves <palves@redhat.com>
1280
1281 * linux-aarch64-low.c (aarch64_stopped_data_address):
1282 Likewise.
1283
1284 2018-04-27 Tom Tromey <tom@tromey.com>
1285
1286 * configure: Rebuild.
1287
1288 2018-04-23 Tom Tromey <tom@tromey.com>
1289
1290 * configure: Rebuild.
1291
1292 2018-04-19 Simon Marchi <simon.marchi@ericsson.com>
1293
1294 * Makefile.in (depcomp): Add "..".
1295 (all_deps_files): New and use it.
1296
1297 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1298
1299 * configure.srv (aarch64*-*-linux*): Don't include xml.
1300 (i[34567]86-*-cygwin*): Likewise.
1301 (i[34567]86-*-linux*): Likewise.
1302 (i[34567]86-*-lynxos*): Likewise.
1303 (i[34567]86-*-mingw32ce*): Likewise.
1304 (i[34567]86-*-mingw*): Likewise.
1305 (i[34567]86-*-nto*): Likewise.
1306 (tic6x-*-uclinux): Likewise.
1307 (x86_64-*-linux*): Likewise.
1308 (x86_64-*-mingw*): Likewise.
1309 (x86_64-*-cygwin*): Likewise.
1310
1311 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1312
1313 * tdesc.c: Remove xml parameter.
1314
1315 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1316
1317 * server.c (get_features_xml): Remove cast.
1318 * tdesc.c (void target_desc::accept): Fill in function.
1319 (tdesc_get_features_xml): Remove old xml creation.
1320 (print_xml_feature::visit_pre): Add xml vistor.
1321 * tdesc.h (struct target_desc): Make xmltarget mutable.
1322 (tdesc_get_features_xml): Remove declaration.
1323
1324 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1325
1326 * tdesc.c (tdesc_architecture_name): Add new function.
1327 (tdesc_osabi_name): Likewise.
1328 (tdesc_get_features_xml): Use new functions.
1329
1330 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1331
1332 * tdesc.c (tdesc_create_flags): Remove.
1333 (tdesc_add_flag): Likewise.
1334 (tdesc_named_type): Likewise.
1335 (tdesc_create_union): Likewise.
1336 (tdesc_create_struct): Likewise.
1337 (tdesc_create_vector): Likewise.
1338 (tdesc_add_bitfield): Likewise.
1339 (tdesc_add_field): Likewise.
1340 (tdesc_set_struct_size): Likewise.
1341
1342 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1343
1344 * tdesc.c (~target_desc): Remove implictly deleted items.
1345 (init_target_desc): Iterate all features.
1346 (tdesc_get_features_xml): Use vector.
1347 (tdesc_create_feature): Create feature.
1348 * tdesc.h (tdesc_feature) Remove
1349 (target_desc): Add features.
1350
1351 2018-04-18 Alan Hayward <alan.hayward@arm.com>
1352
1353 * Makefile.in: Add common/tdesc.c
1354 * tdesc.c (init_target_desc): init all reg_defs from register
1355 vector.
1356 (tdesc_create_reg): Create tdesc_reg.
1357 * tdesc.h (tdesc_feature): Add register vector.
1358
1359 2018-03-30 Simon Marchi <simon.marchi@polymtl.ca>
1360
1361 * tdesc.h (struct target_desc) <features>: Change type to
1362 std::vector<std::string>.
1363 * tdesc.c (target_desc::~target_desc): Adjust to std::vector
1364 changes.
1365 (tdesc_get_features_xml): Likewise.
1366 (tdesc_create_feature): Likewise.
1367
1368 2018-03-26 Alan Hayward <alan.hayward@arm.com>
1369
1370 * regcache.c (find_register_by_number): Return a ref.
1371 (find_regno): Use references.
1372 (register_size): Likewise.
1373 (register_data): Likewise.
1374 * tdesc.c (target_desc::~target_desc): Remove free calls.
1375 (target_desc::operator==): Use std::vector compare.
1376 (init_target_desc): Use reference.
1377 (tdesc_create_reg): Use reg constructors.
1378 * tdesc.h (struct target_desc): Replace pointer with object.
1379
1380 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1381
1382 * regcache.c (find_register_by_number): Make static.
1383 (find_regno): Use find_register_by_number
1384 * regcache.h (struct reg): Remove declaration.
1385
1386 2018-03-23 Alan Hayward <alan.hayward@arm.com>
1387
1388 * tdesc.c (target_desc::~target_desc): Move to here.
1389 (target_desc::operator==): Likewise.
1390 * tdesc.h (target_desc::~target_desc): Move from here.
1391 (target_desc::operator==): Likewise.
1392
1393 2018-03-22 Andreas Arnez <arnez@linux.vnet.ibm.com>
1394
1395 * linux-s390-low.c (s390_get_wordsize): Correct brace style.
1396
1397 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1398
1399 * linux-s390-ipa.c (get_ipa_tdesc): Add handling for
1400 S390_TDESC_GS.
1401 * linux-s390-low.c (s390_get_ipa_tdesc_idx): Likewise.
1402 (initialize_low_tracepoint): Call init_registers_s390x_gs_linux64
1403 and init_registers_s390_gs_linux64.
1404
1405 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1406
1407 * linux-s390-low.c (s390_fill_gs): Remove function.
1408 (s390_fill_gsbc): Remove function.
1409 (s390_regsets): Set fill functions for the guarded storage regsets
1410 to NULL.
1411
1412 2018-03-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
1413
1414 * linux-s390-low.c (s390_get_hwcap): Replace tdesc parameter by
1415 the word size. Add comment.
1416 (s390_get_wordsize): New function.
1417 (s390_arch_setup): No longer select a temporary tdesc to fetch the
1418 pswm with it. Instead, use s390_get_wordsize to determine the
1419 word size first and derive the correct tdesc from that directly.
1420
1421 2018-03-16 Simon Marchi <simon.marchi@polymtl.ca>
1422
1423 * Makefile.in: Include silent-rules.mk.
1424 (srcdir, abs_top_srcdir, abs_srcdir, VPATH): Move up.
1425 (COMPILE): Add ECHO_CXX.
1426 (gdbserver$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1427 (gdbreplay$(EXEEXT)): Add SILENCE and ECHO_CXXLD.
1428 ($(IPA_LIB)): Add SILENCE and ECHO_CXXLD.
1429 (version-generated.c): Add ECHO_GEN.
1430 (stamp-xml): Add SILENCE and ECHO_GEN_XML_BUILTIN_GENERATED.
1431 (IPAGENT_COMPILE): Add ECHO_CXX.
1432 (%-generated.c): Add ECHO_REGDAT.
1433
1434 2018-03-14 Tom Tromey <tom@tromey.com>
1435
1436 PR cli/14977:
1437 * ax.c (ax_printf): Special case for NULL.
1438
1439 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1440
1441 * linux-low.c (linux_qxfer_libraries_svr4): Use
1442 xml_escape_text_append.
1443
1444 2018-03-08 Simon Marchi <simon.marchi@polymtl.ca>
1445
1446 * linux-low.c (linux_qxfer_libraries_svr4): Use std::string.
1447
1448 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1449
1450 * server.c (handle_general_set): Remove unnecessary xstrdup.
1451
1452 2018-03-02 Simon Marchi <simon.marchi@polymtl.ca>
1453
1454 * server.c (parse_debug_format_options): Adjust to
1455 delim_string_to_char_ptr_vec changes.
1456 * thread-db.c (thread_db_load_search): Adjust to
1457 dirnames_to_char_ptr_vec changes.
1458
1459 2018-03-01 Markus Metzger <markus.t.metzger@intel.com>
1460
1461 * target.h (target_enable_btrace, target_disable_btrace)
1462 (target_read_btrace, target_read_btrace_conf): Turn macro into
1463 inline function. Throw error if target method is not defined.
1464 * server.c (handle_qxfer_btrace handle_qxfer_btrace_conf): Remove
1465 check for btrace target method. Be prepared to handle exceptions
1466 from btrace target methods.
1467
1468 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1469
1470 * server.c (captured_main): Change order of error message printed
1471 when the current working directory cannot be found.
1472
1473 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1474
1475 * server.c: Include "filenames.h" and "pathstuff.h".
1476 (program_name): Delete variable.
1477 (program_path): New anonymous class.
1478 (get_exec_wrapper): Use "program_path" instead of
1479 "program_name".
1480 (handle_v_run): Likewise.
1481 (captured_main): Likewise.
1482 (process_serial_event): Likewise.
1483
1484 2018-02-28 Sergio Durigan Junior <sergiodj@redhat.com>
1485
1486 * Makefile.in (SFILES): Add "$(srcdir)/common/pathstuff.c".
1487 (OBJS): Add "pathstuff.o".
1488 * server.c (current_directory): New global variable.
1489 (captured_main): Initialize "current_directory".
1490
1491 2018-02-26 Alan Hayward <alan.hayward@arm.com>
1492
1493 * tdesc.c: Use common/tdesc.h.
1494 * tdesc.h: Likewise.
1495
1496 2018-02-20 Alan Hayward <alan.hayward@arm.com>
1497 Simon Marchi <simon.marchi@ericsson.com>
1498
1499 * Makefile.in: Switch order of make rules.
1500
1501 2018-02-19 Alan Hayward <alan.hayward@arm.com>
1502
1503 * Makefile.in: Add common directory in build.
1504 * configure.ac: Add common reference.
1505 * configure: Regenerate.
1506
1507 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1508
1509 * linux-low.c (linux_target_ops): Remove linux_supports_btrace.
1510 * nto-low.c (nto_target_ops): Remove NULL for supports_btrace.
1511 * spu-low.c (spu_target_ops): Likewise.
1512 * win32-low.c (win32_target_ops): Likewise.
1513 * server.c (supported_btrace_packets): Report packets unconditionally.
1514 * target.h (target_ops) <supports_btrace>: Remove.
1515 (target_supports_btrace): Remove.
1516
1517 2018-02-09 Markus Metzger <markus.t.metzger@intel.com>
1518
1519 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt)
1520 (handle_btrace_disable): Change return type to void. Use exceptions
1521 to report errors.
1522 (handle_btrace_general_set): Catch exception and copy message to
1523 return message.
1524
1525 2018-02-08 Tom Tromey <tom@tromey.com>
1526
1527 * linux-low.c (install_software_single_step_breakpoints): Use
1528 make_scoped_restore.
1529 * inferiors.c (make_cleanup_restore_current_thread): Remove.
1530 (do_restore_current_thread_cleanup): Remove.
1531 * gdbthread.h (make_cleanup_restore_current_thread): Don't
1532 declare.
1533
1534 2018-02-08 Tom Tromey <tom@tromey.com>
1535
1536 * mem-break.c (set_raw_breakpoint_at): Use
1537 gdb::unique_xmalloc_ptr.
1538
1539 2018-01-30 Pedro Alves <palves@redhat.com>
1540
1541 PR gdb/13211
1542 * target.c (target_terminal::terminal_state): Rename to ...
1543 (target_terminal::m_terminal_state): ... this.
1544
1545 2018-01-19 James Clarke <jrtc27@jrtc27.com>
1546
1547 * linux-low.c (handle_extended_wait): Surround call to
1548 thread_db_notice_clone with #ifdef USE_THREAD_DB.
1549
1550 2018-01-17 Simon Marchi <simon.marchi@ericsson.com>
1551
1552 * linux-low.c (attach_proc_task_lwp_callback): Adjust to
1553 linux_ptrace_attach_fail_reason_string now returning an
1554 std::string.
1555 (linux_attach): Likewise.
1556 * thread-db.c (attach_thread): Likewise.
1557
1558 2018-01-17 Eldar Abusalimov <eldar.abusalimov@jetbrains.com>
1559
1560 PR gdb/21559
1561 * configure.ac: Include <sys/types.h> prior to <sys/user.h> when
1562 checking for fs_base/gs_base fields in struct user_regs_struct.
1563 * configure: Regenerate.
1564
1565 2018-01-16 Yao Qi <yao.qi@linaro.org>
1566
1567 PR gdb/18749
1568 * linux-low.c (fetch_register): Call supply_register instead of
1569 error.
1570
1571 2018-01-08 Yao Qi <yao.qi@linaro.org>
1572 Simon Marchi <simon.marchi@ericsson.com>
1573
1574 * Makefile.in (OBS): Remove selftest.o.
1575 * configure.ac: Set srv_selftest_objs if $development is true.
1576 (GDBSERVER_DEPFILES): Append $srv_selftest_objs.
1577 * configure: Re-generated.
1578 * server.c (captured_main): Wrap variable selftest_filter with
1579 GDB_SELF_TEST.
1580
1581 2018-01-07 Simon Marchi <simon.marchi@polymtl.ca>
1582
1583 * server.c (parse_debug_format_options): Return std::string.
1584 (handle_monitor_command, captured_main): Adjust.
1585
1586 2018-01-05 Pedro Alves <palves@redhat.com>
1587
1588 PR gdb/18653
1589 * server.c (captured_main): Pass quiet=false to
1590 save_original_signals_state.
1591
1592 2018-01-01 Joel Brobecker <brobecker@adacore.com>
1593
1594 * gdbreplay.c (gdbreplay_version): Update copyright year in
1595 version message.
1596 * server.c (gdbserver_version): Likewise.
1597
1598 2017-12-08 Tom Tromey <tom@tromey.com>
1599
1600 * ax.c (ax_printf): Update.
1601
1602 2017-12-07 Yao Qi <yao.qi@linaro.org>
1603
1604 * linux-aarch64-ipa.c (initialize_low_tracepoint): Call
1605 aarch64_linux_read_description.
1606 * linux-amd64-ipa.c (idx2mask): New array.
1607 (get_ipa_tdesc): Move idx2mask out.
1608 (initialize_low_tracepoint): Initialize target descriptions.
1609 * linux-i386-ipa.c (idx2mask): New array.
1610 (get_ipa_tdesc): Move idx2mask out.
1611 (initialize_low_tracepoint): Initialize target descriptions.
1612
1613 2017-12-05 Simon Marchi <simon.marchi@polymtl.ca>
1614
1615 * tdesc.c (struct tdesc_type): Change return type.
1616 (tdesc_add_flag): Change parameter type.
1617 (tdesc_add_bitfield): Likewise.
1618 (tdesc_add_field): Likewise.
1619 (tdesc_set_struct_size): Likewise.
1620
1621 2017-12-05 Simon Marchi <simon.marchi@ericsson.com>
1622
1623 * regcache.c (registers_to_string): Remove unused variable.
1624
1625 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1626
1627 * inferiors.c (for_each_inferior_with_data): Remove.
1628 * inferiors.h (for_each_inferior_with_data): Remove.
1629 * server.c (handle_qxfer_threads_worker): Change parameter type.
1630 (handle_qxfer_threads_proper): Use for_each_thread.
1631
1632 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1633
1634 * inferiors.c (for_each_inferior): Remove.
1635 (clear_inferiors): Use for_each_thread.
1636 * inferiors.h (for_each_inferior): Remove.
1637 * linux-low.c (linux_wait_for_event_filtered): Use
1638 for_each_thread.
1639 (linux_stabilize_threads): Likewise.
1640 * regcache.c (regcache_release): Likewise.
1641 * server.c (gdb_wants_all_threads_stopped): Likewise.
1642 (clear_pending_status_callback): Remove.
1643 (handle_status): Use for_each_thread.
1644 (captured_main): Likewise.
1645 * win32-low.c (child_init_thread_list): Likewise.
1646 (win32_clear_inferiors): Likewise.
1647 (fake_breakpoint_event): Likewise.
1648
1649 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1650
1651 * inferiors.h (find_inferior): Remove.
1652 * inferiors.c (find_inferior): Remove.
1653
1654 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1655
1656 * linux-low.c (resume_status_pending_p): Update comment.
1657 (need_step_over_p): Update comment.
1658
1659 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1660
1661 * linux-low.c (proceed_one_lwp): Return void, change parameter
1662 type.
1663 (unsuspend_and_proceed_one_lwp): Likewise.
1664 (proceed_all_lwps): Use for_each_thread.
1665 (unstop_all_lwps): Likewise.
1666
1667 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1668
1669 * linux-low.c (linux_resume_one_thread): Return void, take
1670 parameter directly.
1671 (linux_resume): Use for_each_thread.
1672
1673 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1674
1675 * linux-low.c (send_sigstop_callback): Return void, change
1676 parameter type. Rename to...
1677 (send_sigstop): ... this.
1678 (suspend_and_send_sigstop_callback): Return void, change parameter
1679 type. Rename to...
1680 (suspend_and_send_sigstop): ... this.
1681 (stop_all_lwps): Use for_each_thread.
1682
1683 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1684
1685 * linux-low.c (lwp_running): Return bool, remove unused
1686 argument.
1687 (linux_stabilize_threads): Use find_thread.
1688
1689 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1690
1691 * linux-low.c (select_singlestep_lwp_callback): Remove.
1692 (count_events_callback): Remove.
1693 (select_event_lwp_callback): Remove.
1694 (select_event_lwp): Use find_thread/for_each_thread.
1695
1696 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1697
1698 * linux-low.c (not_stopped_callback): Return bool, take filter
1699 argument directly.
1700 (linux_wait_for_event_filtered): Use find_thread.
1701 (linux_wait_1): Likewise.
1702
1703 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1704
1705 * linux-low.c (same_lwp): Remove.
1706 (find_lwp_pid): Use find_thread.
1707
1708 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1709
1710 * linux-low.c (delete_lwp_callback): Remove.
1711 (linux_mourn): Use for_each_thread.
1712
1713 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1714
1715 * linux-low.c (linux_detach_lwp_callback): Return void, remove
1716 args parameter, don't check for pid.
1717 (linux_detach): Use for_each_thread.
1718
1719 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1720
1721 * linux-low.c (struct counter): Remove.
1722 (second_thread_of_pid_p): Remove.
1723 (last_thread_of_process_p): Use find_thread.
1724
1725 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1726
1727 * inferiors.c (find_inferior_in_random): Remove.
1728 * inferiors.h (find_inferior_in_random): Remove.
1729 * linux-low.c (status_pending_p_callback): Return bool, accept
1730 parameter ptid directly.
1731 (linux_wait_for_event_filtered): Use find_thread_in_random.
1732 (linux_wait_1): Likewise.
1733
1734 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1735
1736 * inferiors.c (find_inferior_id): Remove.
1737 (find_thread_ptid): Move implemention from find_inferior_id to
1738 here.
1739 * inferiors.h (find_inferior_id): Remove.
1740 * server.c (handle_status): Use find_thread_ptid.
1741 (process_serial_event): Likewise.
1742 * thread-db.c (find_one_thread): Likewise.
1743 (thread_db_thread_handle): Likewise.
1744 * win32-low.c (thread_rec): Likewise.
1745 (child_delete_thread): Likewise.
1746 (win32_thread_alive): Likewise.
1747 (get_child_debug_event): Likewise.
1748
1749 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1750
1751 * linux-mips-low.c (update_watch_registers_callback): Return
1752 void, remove pid_p parameter, don't check for pid.
1753 (mips_insert_point, mips_remove_point): Use for_each_thread.
1754
1755 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1756
1757 * lynx.low (lynx_delete_thread_callback): Remove.
1758 (lynx_mourn): Use for_each_thread.
1759
1760 2017-12-02 Simon Marchi <simon.marchi@polymtl.ca>
1761
1762 * regcache.c (regcache_invalidate_one): Remove.
1763 (regcache_invalidate_pid): use for_each_thread.
1764
1765 2017-11-26 Tom Tromey <tom@tromey.com>
1766
1767 * linux-low.c (linux_create_inferior): Update.
1768
1769 2017-11-24 Ulrich Weigand <uweigand@de.ibm.com>
1770
1771 * spu-low.c (spu_create_inferior): Fix typo in argument name.
1772
1773 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1774
1775 * configure.srv: Add linux-aarch64-tdesc-selftest.o.
1776 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1777 * linux-aarch64-tdesc-selftest.c: New file.
1778 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1779
1780 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1781
1782 * configure.srv: Add new file.
1783 * linux-aarch64-low.c (initialize_low_arch): Call init func.
1784 * linux-aarch64-tdesc-selftest.c: New file.
1785 * linux-aarch64-tdesc.h (initialize_low_tdesc): New declaration.
1786
1787 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1788
1789 * linux-aarch64-ipa.c (initialize_low_tracepoint): Remove init.
1790 * linux-aarch64-low.c (initialize_low_arch): Remove init.
1791 * linux-aarch64-tdesc.c (aarch64_linux_read_description): Add init.
1792
1793 2017-11-24 Alan Hayward <alan.hayward@arm.com>
1794
1795 * configure.srv: Add new files.
1796 * linux-aarch64-ipa.c (get_ipa_tdesc): Call
1797 aarch64_linux_read_description.
1798 * linux-aarch64-low.c (aarch64_linux_read_description):
1799 Merge with aarch64_arch_setup.
1800 (aarch64_arch_setup): Call aarch64_linux_read_description.
1801 * linux-aarch64-tdesc.c: New file.
1802 * linux-aarch64-tdesc.h: New file.
1803
1804 2017-11-24 Yao Qi <yao.qi@linaro.org>
1805
1806 * configure.srv: Set $srv_regobj for tic6x-linux.
1807 * linux-tic6x-low.c: Include "arch/tic6x.h" and "tdesc.h".
1808 (tic6x_read_description): Move some code to tic6x_arch_setup.
1809 (tic6x_tdesc_test): New function.
1810 (initialize_low_arch): Call selftests::register_test.
1811
1812 2017-11-22 Yao Qi <yao.qi@linaro.org>
1813
1814 * remote-utils.c (prepare_resume_reply): Use memcpy.
1815
1816 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1817
1818 * linux-low.c (kill_one_lwp_callback): Return void, take
1819 argument directly, don't filter on pid.
1820 (linux_kill): Use for_each_thread.
1821
1822 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1823
1824 * linux-low.c (need_step_over_p): Return bool, remove dummy
1825 argument.
1826 (linux_resume, proceed_all_lwps): Use find_thread.
1827
1828 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1829
1830 * linux-low.c (resume_status_pending_p): Return bool, remove
1831 flag_p argument.
1832 (linux_resume): Use find_thread.
1833
1834 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1835
1836 * linux-low.c (struct thread_resume_array): Remove.
1837 (linux_set_resume_request): Return void, take arguments
1838 directly.
1839 (linux_resume): Use for_each_thread.
1840
1841 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1842
1843 * linux-low.c (stuck_in_jump_pad_callback): Change prototype,
1844 return bool, remove data argument.
1845 (linux_stabilize_threads): Use find_thread.
1846
1847 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1848
1849 * linux-low.c (unsuspend_one_lwp): Remove.
1850 (unsuspend_all_lwps): Use for_each_thread, inline code from
1851 unsuspend_one_lwp.
1852
1853 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1854
1855 * gdbthread.h (find_thread): Add overload with ptid_t filter.
1856 * linux-low.c (struct iterate_over_lwps_args): Remove.
1857 (iterate_over_lwps_filter): Remove.
1858 (iterate_over_lwps): Use find_thread.
1859
1860 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1861
1862 * linux-low.c (reset_lwp_ptrace_options_callback): Remove.
1863 (linux_handle_new_gdb_connection): Use for_each_thread, inline
1864 code from reset_lwp_ptrace_options_callback.
1865
1866 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1867
1868 * linux-arm-low.c (struct update_registers_data): Remove.
1869 (update_registers_callback): Return void, take arguments
1870 directly, don't check thread's pid.
1871 (arm_insert_point, arm_remove_point): Use for_each_thread.
1872
1873 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1874
1875 * win32-low.c (continue_one_thread): Return void, take argument
1876 directly.
1877 (child_continue): Use for_each_thread.
1878
1879 2017-11-19 Simon Marchi <simon.marchi@ericsson.com>
1880
1881 * win32-i386-low.c (update_debug_registers_callback): Rename
1882 to ...
1883 (update_debug_registers): ... this, return void, remove pid_p arg.
1884 (x86_dr_low_set_addr, x86_dr_low_set_control): Use for_each_thread.
1885
1886 2017-11-17 Simon Marchi <simon.marchi@polymtl.ca>
1887
1888 * inferiors.h (struct process_info): Add constructor, initialize
1889 fields..
1890 <syscalls_to_catch>: Change type to std::vector<int>.
1891 * inferiors.c (add_process): Allocate process_info with new.
1892 (remove_process): Free process_info with delete.
1893 * linux-low.c (handle_extended_wait): Adjust.
1894 (gdb_catching_syscalls_p, gdb_catch_this_syscall_p): Adjust.
1895 * server.c (handle_general_set): Adjust.
1896
1897 2017-11-16 Pedro Alves <palves@redhat.com>
1898
1899 * remote-utils.c (remote_close): Block SIGIO signals instead of
1900 uninstalling the SIGIO handler.
1901
1902 2017-11-16 Alan Hayward <alan.hayward@arm.com>
1903
1904 * tdesc.c (tdesc_get_features_xml): Allow null osabi.
1905
1906 2017-11-16 Yao Qi <yao.qi@linaro.org>
1907
1908 * linux-tic6x-low.c (tic6x_fill_gregset): Cast buf.
1909 (tic6x_store_gregset): Likewise.
1910 (tic6x_usrregs_info): Move it up.
1911
1912 2017-11-15 Alan Hayward <alan.hayward@arm.com>
1913
1914 * Makefile.in: Update arch rules.
1915 * configure.srv: Explicitly mark arch/ files.
1916
1917 2017-11-13 Andreas Schwab <schwab@suse.de>
1918
1919 * linux-m68k-low.c (m68k_supports_hardware_single_step): New
1920 function.
1921 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
1922
1923 2017-11-06 Pedro Alves <palves@redhat.com>
1924
1925 * config.in, configure: Regenerate.
1926
1927 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1928
1929 * target.c (struct thread_search): Remove.
1930 (thread_search_callback): Remove.
1931 (prepare_to_access_memory): Use for_each_thread instead of
1932 find_inferior. Inline code from thread_search_callback.
1933
1934 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1935
1936 * server.c (struct visit_actioned_threads_data): Remove.
1937 (visit_actioned_threads): Change prototype to take arguments
1938 directly.
1939 (resume): Use find_thread instead of find_inferior.
1940
1941 2017-10-27 Simon Marchi <simon.marchi@ericsson.com>
1942
1943 * server.c (queue_stop_reply_callback): Change prototype, return
1944 void.
1945 (find_status_pending_thread_callback): Remove.
1946 (handle_status): Replace find_inferior with find_thread and
1947 for_each_thread.
1948
1949 2017-10-25 Alan Hayward <alan.hayward@arm.com>
1950
1951 * linux-aarch64-low.c (aarch64_fill_gregset): Replace defines
1952 with REGNO.
1953 (aarch64_store_gregset): Likewise.
1954 (aarch64_fill_fpregset): Likewise.
1955 (aarch64_store_fpregset): Likewise.
1956
1957 2017-10-21 Simon Marchi <simon.marchi@ericsson.com>
1958
1959 * gdbthread.h (find_thread, for_each_thread): New functions.
1960 * inferiors.c (thread_of_pid): Remove.
1961 (find_any_thread_of_pid): Use find_thread.
1962 * linux-low.c (num_lwps): Use for_each_thread.
1963
1964 2017-10-17 Yao Qi <yao.qi@linaro.org>
1965
1966 * Makefile.in: Remove one rule.
1967 * configure.srv: Rename aarch64-insn.o with arch/aarch64-insn.o.
1968
1969 2017-10-17 Yao Qi <yao.qi@linaro.org>
1970
1971 * configure.srv: Rename arm-linux.o with arch/arm-linux.o.
1972 Rename arm-get-next-pcs.o with arch/arm-get-next-pcs.o.
1973
1974 2017-10-17 Yao Qi <yao.qi@linaro.org>
1975
1976 * configure.srv: Rename arm.o with arch/arm.o.
1977
1978 2017-10-17 Yao Qi <yao.qi@linaro.org>
1979
1980 * Makefile.in (CONFIG_SRC_SUBDIR): New variable.
1981 (clean): Remove .o files in CONFIG_SRC_SUBDIR.
1982 (distclean): Remove DEPDIR in CONFIG_SRC_SUBDIR.
1983 (arch-i386.o, arch-amd64.o): Remove rules.
1984 (arch/%.o): New rule.
1985 Update POSTCOMPILE and COMPILE.pre.
1986 * configure.ac: Invoke AC_CONFIG_COMMANDS.
1987 * configure: Re-generated.
1988 * configure.srv: Replace arch-i386.o with arch/i386.o.
1989 Replace arch-amd64.o with arch/amd64.o.
1990
1991 2017-10-16 Yao Qi <yao.qi@linaro.org>
1992
1993 * configure: Regenerated.
1994
1995 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
1996
1997 * inferiors.h: (struct inferior_list): Remove.
1998 (struct inferior_list_entry); Remove.
1999 (add_inferior_to_list, clear_inferior_list, one_inferior_p,
2000 A_I_NEXT, ALL_INFERIORS_TYPE, ALL_INFERIORS, remove_inferior,
2001 get_first_inferior): Remove.
2002 (for_each_inferior, for_each_inferior_with_data, find_inferior,
2003 find_inferior_id, find_inferior_in_random): Change signature.
2004 * inferiors.c (all_threads): Change type to
2005 std::list<thread_info *>.
2006 (get_thread): Remove macro.
2007 (find_inferior, find_inferior_id): Change signature, implement
2008 using find_thread.
2009 (find_inferior_in_random): Change signature, implement using
2010 find_thread_in_random.
2011 (for_each_inferior, for_each_inferior_with_data): Change
2012 signature, implement using for_each_thread.
2013 (add_inferior_to_list, remove_inferior): Remove.
2014 (add_thread, get_first_thread, thread_of_pid,
2015 find_any_thread_of_pid, free_one_thread, remove_thread): Update.
2016 (get_first_inferior, one_inferior_p, clear_inferior_list):
2017 Remove.
2018 (clear_inferiors, get_thread_process): Update.
2019 * gdbthread.h: Include <list>.
2020 (struct thread_info) <entry>: Remove field.
2021 <id>: New field.
2022 (all_threads): Change type to std::list<thread_info *>.
2023 (get_first_inferior): Add doc.
2024 (find_thread, for_each_thread, find_thread_in_random): New
2025 functions.
2026 (current_ptid, pid_of, ptid_of, lwpid_of): Update.
2027 * linux-arm-low.c (update_registers_callback): Update.
2028 * linux-low.c (second_thread_of_pid_p): Update.
2029 (kill_one_lwp_callback, linux_detach_lwp_callback,
2030 delete_lwp_callback, status_pending_p_callback, same_lwp,
2031 find_lwp_pid, num_lwps, iterate_over_lwps_filter,
2032 iterate_over_lwps, not_stopped_callback,
2033 resume_stopped_resumed_lwps, count_events_callback,
2034 select_singlestep_lwp_callback, select_event_lwp_callback,
2035 unsuspend_one_lwp, linux_wait_1, send_sigstop_callback,
2036 suspend_and_send_sigstop_callback, wait_for_sigstop,
2037 stuck_in_jump_pad_callback, move_out_of_jump_pad_callback,
2038 lwp_running, linux_set_resume_request, resume_status_pending_p,
2039 need_step_over_p, start_step_over, linux_resume_one_thread,
2040 proceed_one_lwp, unsuspend_and_proceed_one_lwp,
2041 reset_lwp_ptrace_options_callback): Update.
2042 * linux-mips-low.c (update_watch_registers_callback): Update.
2043 * regcache.c (regcache_invalidate_one, regcache_invalidate):
2044 Update.
2045 (free_register_cache_thread_one): Remove.
2046 (regcache_release): Update.
2047 * server.c (handle_btrace_enable_bts, handle_btrace_enable_pt,
2048 handle_qxfer_threads_worker): Update.
2049 (handle_query): Update, use list iterator.
2050 (visit_actioned_threads, handle_pending_status,
2051 queue_stop_reply_callback, gdb_wants_all_threads_stopped,
2052 clear_pending_status_callback, set_pending_status_callback,
2053 find_status_pending_thread_callback, handle_status,
2054 process_serial_event): Update.
2055 * target.c (thread_search_callback): Update.
2056 * thread-db.c (thread_db_get_tls_address): Update.
2057 * tracepoint.c (tracepoint_finished_step, tracepoint_was_hit):
2058 Update.
2059 * win32-i386-low.c (update_debug_registers_callback): Update.
2060 * win32-low.c (delete_thread_info, child_delete_thread,
2061 continue_one_thread, suspend_one_thread,
2062 get_child_debug_event): Adjust.
2063
2064 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2065
2066 * gdbthread.h (ptid_of, pid_of, lwpid_of): New functions.
2067 * inferiors.h: Include <list>.
2068 (struct process_info) <entry>: Remove field.
2069 <pid>: New field.
2070 (pid_of): Change macro to function.
2071 (ptid_of, lwpid_of): Remove macro.
2072 (all_processes): Change type to std::list<process_info *>.
2073 (ALL_PROCESSES): Remove macro.
2074 (for_each_process, find_process): New function.
2075 * inferiors.c (all_processes): Change type to
2076 std::list<process_info *>.
2077 (find_thread_process): Adjust.
2078 (add_process): Likewise.
2079 (remove_process): Likewise.
2080 (find_process_pid): Likewise.
2081 (get_first_process): Likewise.
2082 (started_inferior_callback): Remove.
2083 (have_started_inferiors_p): Adjust.
2084 (attached_inferior_callback): Remove.
2085 (have_attached_inferiors_p): Adjust.
2086 * linux-low.c (check_zombie_leaders): Likewise.
2087 * linux-x86-low.c (x86_arch_setup_process_callback): Remove.
2088 (x86_linux_update_xmltarget): Adjust.
2089 * server.c (handle_query): Likewise.
2090 (gdb_reattached_process): Remove.
2091 (handle_status): Adjust.
2092 (kill_inferior_callback): Likewise.
2093 (detach_or_kill_inferior): Remove.
2094 (print_started_pid): Likewise.
2095 (print_attached_pid): Likewise.
2096 (detach_or_kill_for_exit): Update.
2097 (process_serial_event): Likewise.
2098 * linux-arm-low.c (arm_new_fork): Likewise.
2099
2100 2017-10-14 Simon Marchi <simon.marchi@polymtl.ca>
2101
2102 * dll.h: Include <list>.
2103 (struct dll_info): Add constructor.
2104 <entry>: Remove field.
2105 (all_dlls): Change type to std::list<dll_info>.
2106 * dll.c: Include <algorithm>.
2107 (get_dll): Remove macro.
2108 (all_dlls): Change type to std::list<dll_info *>.
2109 (free_one_dll): Remove.
2110 (match_dll): Likewise.
2111 (loaded_dll): Adjust.
2112 (unloaded_dll): Adjust to all_dlls type change, use
2113 std::find_if. Inline code from match_dll.
2114 (clear_dlls): Adjust to all_dlls type change.
2115 * server.c (emit_dll_description): Remove.
2116 (handle_qxfer_libraries): Adjust to all_dlls type change,
2117 integrate emit_dll_description's functionality.
2118
2119 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2120
2121 * linux-low.h (struct linux_target_ops) <delete_process>: New
2122 field.
2123 * linux-low.c (linux_mourn): Call the_low_target.delete_process.
2124 * linux-aarch64-low.c (aarch64_linux_delete_process): New.
2125 (struct linux_target_ops): Add delete_process callback.
2126 * linux-arm-low.c (arm_delete_process): New.
2127 (struct linux_target_ops): Add delete_process callback.
2128 * linux-bfin-low.c (struct linux_target_ops): Likewise.
2129 * linux-crisv32-low.c (struct linux_target_ops): Likewise.
2130 * linux-m32r-low.c (struct linux_target_ops): Likewise.
2131 * linux-mips-low.c (mips_linux_delete_process): New.
2132 (struct linux_target_ops): Add delete_process callback.
2133 * linux-ppc-low.c (struct linux_target_ops): Likewise.
2134 * linux-s390-low.c (struct linux_target_ops): Likewise.
2135 * linux-sh-low.c (struct linux_target_ops): Likewise.
2136 * linux-tic6x-low.c (struct linux_target_ops): Likewise.
2137 * linux-tile-low.c (struct linux_target_ops): Likewise.
2138 * linux-x86-low.c (x86_linux_delete_process): New.
2139 (struct linux_target_ops): Add delete_process callback.
2140 * linux-xtensa-low.c (struct linux_target_ops): Likewise.
2141
2142 2017-10-12 Simon Marchi <simon.marchi@ericsson.com>
2143
2144 * linux-aarch64-low.c (the_low_target): Add thread delete
2145 callback.
2146 * linux-arm-low.c (arm_delete_thread): New function.
2147 (the_low_target): Add thread delete callback.
2148 * linux-bfin-low.c (the_low_target): Likewise.
2149 * linux-crisv32-low.c (the_low_target): Likewise.
2150 * linux-low.c (delete_lwp): Invoke delete_thread callback if
2151 set.
2152 * linux-low.h (struct linux_target_ops) <delete_thread>: New
2153 field.
2154 * linux-m32r-low.c (the_low_target): Add thread delete callback.
2155 * linux-mips-low.c (mips_linux_delete_thread): New function.
2156 (the_low_target): Add thread delete callback.
2157 * linux-ppc-low.c (the_low_target): Likewise.
2158 * linux-s390-low.c (the_low_target): Likewise.
2159 * linux-sh-low.c (the_low_target): Likewise.
2160 * linux-tic6x-low.c (the_low_target): Likewise.
2161 * linux-tile-low.c (the_low_target): Likewise.
2162 * linux-x86-low.c (the_low_target): Likewise.
2163 * linux-xtensa-low.c (the_low_target): Likewise.
2164
2165 2017-10-06 Yuanhui Zhang <asmwarrior@gmail.com>
2166
2167 * win32-low.c: Include "common-inferior.h".
2168
2169 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2170
2171 * inferiors.c (set_inferior_cwd): New function.
2172 * server.c (handle_general_set): Handle QSetWorkingDir packet.
2173 (handle_query): Inform that QSetWorkingDir is supported.
2174 * win32-low.c (create_process): Pass the inferior's cwd to
2175 CreateProcess.
2176
2177 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2178
2179 * inferiors.c (current_inferior_cwd): New global variable.
2180 (get_inferior_cwd): New function.
2181 * inferiors.h (struct process_info) <cwd>: New field.
2182
2183 2017-10-04 Sergio Durigan Junior <sergiodj@redhat.com>
2184
2185 * Makefile.in (SFILES): Add $(srcdir)/common/gdb_tilde_expand.c.
2186 (OBS): Add gdb_tilde_expand.o.
2187
2188 2017-10-02 Simon Marchi <simon.marchi@ericsson.com>
2189
2190 * lynx-i386-low.c (lynx_i386_arch_setup): Call init_target_desc.
2191 * nto-x86-low.c (nto_x86_arch_setup): Likewise.
2192
2193 2017-09-29 Pedro Alves <palves@redhat.com>
2194
2195 * ax.c (gdb_parse_agent_expr): Constify.
2196 * ax.h (gdb_parse_agent_expr): Constify.
2197 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
2198 Constify.
2199 * mem-break.h (add_breakpoint_condition, add_breakpoint_commands): Constify.
2200 * remote-utils.c (hex_or_minus_one, read_ptid): Constify.
2201 * remote-utils.h (read_ptid): Constify.
2202 * server.c (handle_qxfer_exec_file, handle_query, handle_v_cont)
2203 (process_point_options, process_serial_event): Constify.
2204 * tracepoint.c (add_tracepoint_action, cmd_qtdp, cmd_qtdpsrc)
2205 (cmd_qtdv, cmd_qtenable_disable, cmd_qtro, cmd_qtframe, cmd_qtp)
2206 (cmd_qtbuffer): Constify.
2207
2208 2017-09-29 Pedro Alves <palves@redhat.com>
2209
2210 * proc-service.c (ps_pdread): Return PS_ERR if reading memory
2211 fails.
2212
2213 2017-09-29 Pedro Alves <palves@redhat.com>
2214
2215 * linux-low.c (handle_extended_wait): Pass parent thread instead
2216 of process to thread_db_notice_clone.
2217 * linux-low.h (thread_db_notice_clone): Replace parent process
2218 parameter with parent thread parameter.
2219 * thread-db.c (find_one_thread): Add comment.
2220 (thread_db_notice_clone): Replace parent process parameter with
2221 parent thread parameter. Temporarily switch to the parent thread.
2222
2223 2017-09-26 Sergio Durigan Junior <sergiodj@redhat.com>
2224
2225 * gdbthread.h: Include "common-gdbthread.h".
2226 * inferiors.c (switch_to_thread): Use "gdb_assert" instead of
2227 "if" when validating the ptid.
2228 * remote-utils.c: Include "gdbthread.h".
2229 (prepare_resume_reply): Use "switch_to_thread".
2230 * target.c (done_accessing_memory): Likewise.
2231
2232 2017-09-25 Andreas Arnez <arnez@linux.vnet.ibm.com>
2233
2234 * configure.srv (s390*-*-linux*): Add s390-gs-linux64.o and
2235 s390x-gs-linux64.o to srv_regobj. Add s390-gs-linux64.xml,
2236 s390x-gs-linux64.xml, s390-gs.xml, and s390-gsbc.xml to
2237 srv_xmlfiles. Add s390-gs-linux64-ipa.o and
2238 s390x-gs-linux64-ipa.o to ipa_obj.
2239 * linux-s390-low.c (HWCAP_S390_GS): New define.
2240 (s390_fill_gs, s390_store_gs, s390_fill_gsbc, s390_store_gsbc):
2241 New functions.
2242 (s390_regsets): Add regsets for NT_S390_GS_CB and NT_S390_GS_BC.
2243 (s390_arch_setup): Check for guarded-storage support and choose
2244 appropriate tdesc.
2245 (initialize_low_arch): Invoke init_registers_s390_gs_linux64 and
2246 init_registers_s390x_gs_linux64.
2247 * linux-s390-tdesc.h (enum s390_linux_tdesc) <S390_TDESC_GS>: New
2248 enum value.
2249 (init_registers_s390x_gs_linux64, tdesc_s390x_gs_linux64)
2250 (init_registers_s390_gs_linux64, tdesc_s390_gs_linux64): Declare.
2251
2252 2017-09-22 Simon Marchi <simon.marchi@ericsson.com>
2253
2254 * win32-i386-low.c (i386_arch_setup): Call init_target_desc.
2255
2256 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2257
2258 * linux-low.h (struct lwp_info): Add new field, thread_handle.
2259 (thread_db_thread_handle): Declare.
2260 * linux-low.c (linux_target_ops): Initialize thread_handle.
2261 * server.c (handle_qxfer_threads_worker): Add support for
2262 "handle" attribute.
2263 * target.h (struct target_ops): Add new function pointer,
2264 thread_handle.
2265 (target_thread_handle): Define.
2266 * thread-db.c (find_one_thread, attach_thread): Set thread_handle
2267 field in lwp.
2268 (thread_db_thread_handle): New function.
2269
2270 2017-09-21 Kevin Buettner <kevinb@redhat.com>
2271
2272 * linux-low.c (handle_extended_wait): Call thread_db_notice_clone().
2273 * linux-low.h (thread_db_notice_clone): Declare.
2274 * thread-db.c (thread_db_notice_clone): New function.
2275
2276 2017-09-21 Pedro Alves <palves@redhat.com>
2277
2278 * server.c (gdb_read_memory, handle_status, process_serial_event)
2279 (handle_serial_event, handle_target_event): Adjust to
2280 set_desired_thread prototype change.
2281 * target.c (set_desired_thread): Remove 'use_general' parameter
2282 and adjust.
2283 * target.h (set_desired_thread): Remove 'use_general' parameter.
2284
2285 2017-09-20 Tom Tromey <tom@tromey.com>
2286
2287 * target.c (target_terminal::terminal_state): Define.
2288 (target_terminal::init): Rename from target_terminal_init.
2289 (target_terminal::inferior): Rename from
2290 target_terminal_inferior.
2291 (target_terminal::ours): Rename from target_terminal_ours.
2292 (target_terminal::ours_for_output, target_terminal::info): New.
2293
2294 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2295
2296 * server.c (accumulate_file_name_length): Remove.
2297 (emit_dll_description): Adjust to std::string change.
2298 (handle_qxfer_libraries): Use std::string to hold document.
2299
2300 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2301
2302 * linux-low.c (linux_qxfer_libraries_svr4): Adjust to change of
2303 return type of xml_escape_text.
2304 * server.c (emit_dll_description): Likewise.
2305
2306 2017-09-16 Simon Marchi <simon.marchi@ericsson.com>
2307
2308 * server.c (captured_main): Accept argument for --selftest.
2309 Update run_tests call.
2310 * linux-x86-tdesc-selftest.c (initialize_low_tdesc): Add names
2311 when registering selftests.
2312
2313 2017-09-16 Sergio Durigan Junior <sergiodj@redhat.com>
2314
2315 * regcache.c (get_thread_regcache): Update code to use "std::vector"
2316 instead of "VEC" for "target_desc.reg_defs".
2317 (regcache_cpy): Likewise.
2318 (registers_to_string): Likewise.
2319 (registers_from_string): Likewise.
2320 (find_regno): Likewise.
2321 (supply_regblock): Likewise.
2322 (regcache_raw_read_unsigned): Likewise.
2323 * tdesc.c (init_target_desc): Likewise.
2324 (tdesc_create_reg): Likewise.
2325 * tdesc.h: Remove declaration of "tdesc_reg_p". Include <vector>.
2326 (struct target_desc) <reg_defs>: Convert to "std::vector".
2327 (target_desc): Do not initialize "reg_defs".
2328 (~target_desc): Update code to use "std::vector" instead of "VEC"
2329 for "target_desc.reg_defs".
2330 (operator==): Likewise.
2331
2332 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2333
2334 * inferiors.h (thread_to_gdb_id): Remove.
2335 * inferiors.c (thread_to_gdb_id): Remove.
2336 * server.c (handle_qxfer_threads_worker, handle_query): Adjust.
2337 * lynx-low.c (lynx_resume, lynx_wait_1, lynx_fetch_registers,
2338 lynx_store_registers, lynx_read_memory, lynx_write_memory):
2339 Likewise.
2340 * nto-low.c (nto_fetch_registers, nto_store_registers,
2341 nto_stopped_by_watchpoint, nto_stopped_data_address): Likewise.
2342
2343 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2344
2345 * inferiors.h (gdb_id_to_thread_id): Remove.
2346 * inferiors.c (gdb_id_to_thread_id): Remove.
2347 * server.c (process_serial_event): Adjust to gdb_id_to_thread_id
2348 removal. Move pid declaration closer to where it's used.
2349
2350 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2351
2352 * server.c (handle_detach): New function.
2353 (process_serial_event): Move code out, call handle_detach.
2354
2355 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2356
2357 * server.c (require_running): Rename to ...
2358 (require_running_or_return): ... this ...
2359 (require_running_or_break): ... and this.
2360 (handle_query, process_serial_event): Adjust.
2361
2362 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2363
2364 * linux-low.c (linux_set_resume_request): Remove unused
2365 variables.
2366
2367 2017-09-15 Simon Marchi <simon.marchi@ericsson.com>
2368
2369 * server.c (first_thread_of): Remove.
2370 (process_serial_event): Replace usage of first_thread_of with
2371 find_any_thread_of_pid.
2372 * tracepoint.c (same_process_p): Remove.
2373 (gdb_agent_about_to_close): Replace usage of same_process_p with
2374 find_any_thread_of_pid.
2375 * linux-x86-low.c (same_process_callback): Remove.
2376 (x86_arch_setup_process_callback): Replace usage of
2377 same_process_callback with find_any_thread_of_pid.
2378 * thread-db.c (any_thread_of): Remove.
2379 (switch_to_process): Replace usage of any_thread_of with
2380 find_any_thread_of_pid.
2381 * inferiors.c (thread_pid_matches_callback): Remove.
2382 (find_thread_process): Adjust to use find_any_thread_of_pid.
2383
2384 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2385
2386 * regcache.c (get_thread_regcache): Guard calls to "memset"
2387 with "!VEC_empty".
2388
2389 2017-09-10 Sergio Durigan Junior <sergiodj@redhat.com>
2390
2391 * linux-low.c (handle_extended_wait): Use
2392 "allocate_target_description" instead of "XNEW".
2393 * linux-x86-low.c (initialize_low_arch): Likewise.
2394
2395 2017-09-05 Yao Qi <yao.qi@linaro.org>
2396
2397 * configure.srv (srv_i386_regobj): Remove.
2398 (srv_amd64_regobj): Remove.
2399 (srv_regobj): Set it to "" for x86 non-linux targets.
2400 * linux-x86-tdesc.c (i386_linux_read_description):
2401 * lynx-i386-low.c: Include x86-xstate.h and arch/i386.h.
2402 (init_registers_i386): Remove the declaration.
2403 (tdesc_i386): Remove the declaration.
2404 (lynx_i386_arch_setup): Call i386_create_target_description.
2405 * nto-x86-low.c: Likewise.
2406 * win32-i386-low.c [__x86_64__]: include arch/amd64.h.
2407 [!__x86_64__]: include arch/i386.h.
2408 (i386_arch_setup) [__x86_64__]: Call amd64_create_target_description.
2409
2410 2017-09-05 Yao Qi <yao.qi@linaro.org>
2411
2412 * configure.srv (srv_amd64_linux_xmlfiles): Remove
2413 i386/amd64-XXX-linux from it.
2414
2415 2017-09-05 Yao Qi <yao.qi@linaro.org>
2416
2417 * configure.srv: Empty srv_amd64_linux_regobj if $development is
2418 false.
2419 (ipa_amd64_linux_regobj): Remove.
2420 (ipa_x32_linux_regobj): Remove.
2421
2422 2017-09-05 Yao Qi <yao.qi@linaro.org>
2423
2424 * Makefile.in (arch-amd64.o): New rule.
2425 * configure.srv: Append arch-amd64.o.
2426 * linux-amd64-ipa.c: Include common/x86-xstate.h.
2427 (get_ipa_tdesc): Call amd64_linux_read_description.
2428 (initialize_low_tracepoint): Don't call init_registers_x32_XXX
2429 and init_registers_amd64_XXX.
2430 * linux-x86-low.c (x86_linux_read_description): Call
2431 amd64_linux_read_description.
2432 (x86_get_ipa_tdesc_idx): Call amd64_get_ipa_tdesc_idx.
2433 (initialize_low_arch): Don't call init_registers_x32_XXX and
2434 init_registers_amd64_XXX.
2435 * linux-x86-tdesc-selftest.c: Declare init_registers_amd64_XXX
2436 and tdesc_amd64_XXX.
2437 [__x86_64__] (amd64_tdesc_test): New function.
2438 (initialize_low_tdesc) [__x86_64__]: Call init_registers_x32_XXX
2439 and init_registers_amd64_XXX.
2440 * linux-x86-tdesc.c: Include arch/amd64.h.
2441 (xcr0_to_tdesc_idx): New function.
2442 (i386_linux_read_description): New function.
2443 (amd64_get_ipa_tdesc_idx): New function.
2444 * linux-x86-tdesc.h (amd64_get_ipa_tdesc_idx): Declare.
2445 (amd64_get_ipa_tdesc): Declare.
2446
2447 2017-09-05 Yao Qi <yao.qi@linaro.org>
2448
2449 * configure.srv (srv_i386_linux_xmlfiles): Remove
2450 i386/i386-XXX-linux.xml from it.
2451
2452 2017-09-05 Yao Qi <yao.qi@linaro.org>
2453
2454 * configure.srv: Set srv_i386_linux_regobj empty if $development
2455 is false.
2456 * linux-i386-ipa.c (initialize_low_tracepoint): Don't call
2457 initialize_low_tdesc.
2458 * linux-x86-low.c (initialize_low_arch): Wrap initialize_low_tdesc
2459 with #if initialize_low_tdesc.
2460 * linux-x86-tdesc-selftest.c: New file.
2461 * linux-x86-tdesc.c: Move code to linux-x86-tdesc-selftest.c.
2462
2463 2017-09-05 Yao Qi <yao.qi@linaro.org>
2464
2465 * Makefile.in (arch-i386.o): New rule.
2466 * configure.srv (i[34567]86-*-linux*): Add arch-i386.o.
2467 (x86_64-*-linux*): Likewise.
2468 * linux-x86-tdesc.c: Don't include ../features/i386/32bit-XXX.c,
2469 include arch/i386.h.
2470 (i386_linux_read_description): Remove code and call
2471 i386_create_target_description.
2472 * tdesc.c (allocate_target_description): New function.
2473 * tdesc.h (set_tdesc_architecture): Remove declaration.
2474 (set_tdesc_osabi): Likewise.
2475
2476 2017-09-05 Yao Qi <yao.qi@linaro.org>
2477
2478 * linux-x86-tdesc.c: Don't include <inttypes.h>.
2479 (i386_linux_read_description) [!IN_PROCESS_AGENT]: Call
2480 set_tdesc_architecture and set_tdesc_osabi. Remove code setting
2481 .xmltarget.
2482 * server.c (get_features_xml): Call tdesc_get_features_xml.
2483 * tdesc.c (set_tdesc_architecture): New function.
2484 (set_tdesc_osabi): New function.
2485 (tdesc_get_features_xml): New function.
2486 (tdesc_create_feature): Add an argument.
2487 * tdesc.h (struct target_desc) <features>: New field.
2488 <arch, osabi>: New field.
2489 (~target_desc): xfree features, arch, and osabi.
2490 (target_desc::oerator==): Don't compare .xmltarget.
2491 [!IN_PROCESS_AGENT] (set_tdesc_architecture): Declare.
2492 (set_tdesc_osabi): Likewise.
2493 (tdesc_get_features_xml): Likewise.
2494
2495 2017-09-05 Yao Qi <yao.qi@linaro.org>
2496
2497 * linux-x86-tdesc.c: Include selftest.h.
2498 (i386_tdesc_test): New function.
2499 (initialize_low_tdesc): Call selftests::register_test.
2500 * tdesc.h: Include regdef.h.
2501 (target_desc): Override operator == and !=.
2502
2503 2017-09-05 Yao Qi <yao.qi@linaro.org>
2504
2505 * configure.srv (srv_tgtobj): Append linux-x86-tdesc.o.
2506 (ipa_obj): Likewise.
2507 * linux-i386-ipa.c: Include common/x86-xstate.h
2508 (get_ipa_tdesc): Call i386_linux_read_description.
2509 (initialize_low_tracepoint): Don't call init_registers_XXX
2510 functions, call initialize_low_tdesc instead.
2511 * linux-x86-low.c (x86_linux_read_description): Call
2512 i386_linux_read_description.
2513 (initialize_low_arch): Don't call init_registers_i386_XXX
2514 functions, call initialize_low_tdesc.
2515 * linux-x86-tdesc.c: New file.
2516 * linux-x86-tdesc.h (x86_linux_tdesc): New X86_TDESC_LAST.
2517 (i386_get_ipa_tdesc_idx): Declare.
2518 (i386_get_ipa_tdesc): Declare.
2519 (initialize_low_tdesc): Declare.
2520
2521 2017-09-05 Yao Qi <yao.qi@linaro.org>
2522
2523 * linux-x86-low.c (x86_get_ipa_tdesc_idx): Use X86_TDESC_MMX
2524 instead of 0.
2525
2526 2017-09-05 Yao Qi <yao.qi@linaro.org>
2527
2528 * Makefile.in (IPA_OBJS): Add vec-ipa.o
2529 * regcache.c (get_thread_regcache): Use VEC_length.
2530 (init_register_cache): Likewise.
2531 (regcache_cpy): Likewise.
2532 (registers_to_string): Iterate reg_defs via VEC_iterate.
2533 (find_regno): Likewise.
2534 (find_register_by_number): Use VEC_index.
2535 (register_size): Call find_register_by_number.
2536 (register_data): Call find_register_by_number.
2537 (supply_regblock): Use VEC_length.
2538 (regcache_raw_read_unsigned): Likewise.
2539 * tdesc.c (init_target_desc): Iterate reg_defs via
2540 VEC_iterate.
2541 (default_description): Update initializer.
2542 (copy_target_description): Don't update field num_registers.
2543 * tdesc.h (struct target_desc) <reg_defs>: Change it to VEC.
2544 <num_registers>: Remove.
2545
2546 2017-09-04 Simon Marchi <simon.marchi@ericsson.com>
2547
2548 * Makefile.in (.SECONDARY): Define target.
2549
2550 2017-09-03 Simon Marchi <simon.marchi@ericsson.com>
2551
2552 * linux-low.c (linux_wait_1): Adjust.
2553 * server.c (queue_stop_reply_callback): Adjust.
2554
2555 2017-08-31 Sergio Durigan Junior <sergiodj@redhat.com>
2556
2557 * server.c (handle_general_set): Handle QEnvironmentHexEncoded,
2558 QEnvironmentUnset and QEnvironmentReset packets.
2559 (handle_query): Inform remote that QEnvironmentHexEncoded,
2560 QEnvironmentUnset and QEnvironmentReset are supported.
2561
2562 2017-08-25 Simon Marchi <simon.marchi@ericsson.com>
2563
2564 * inferiors.h (inferior_target_data): Rename to ...
2565 (thread_target_data): ... this.
2566 (inferior_regcache_data): Rename to ...
2567 (thread_regcache_data): ... this.
2568 (set_inferior_regcache_data): Rename to ...
2569 (set_thread_regcache_data): ... this.
2570 * inferiors.c (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 (free_one_thread): Update.
2577 * linux-low.h (get_thread_lwp): Update.
2578 * regcache.c (get_thread_regcache): Update.
2579 (regcache_invalidate_thread): Update.
2580 (free_register_cache_thread): Update.
2581 * win32-i386-low.c (update_debug_registers_callback): Update.
2582 (win32_get_current_dr): Update.
2583 * win32-low.c (thread_rec): Update.
2584 (delete_thread_info): Update.
2585 (continue_one_thread): Update.
2586 (suspend_one_thread): Update.
2587
2588 2017-08-24 Simon Marchi <simon.marchi@ericsson.com>
2589
2590 * inferiors.c (set_inferior_target_data): Remove.
2591 * inferiors.h (set_inferior_target_data): Remove.
2592
2593 2017-08-18 Yao Qi <yao.qi@linaro.org>
2594
2595 * Makefile.in (OBS): Add selftest.o.
2596 * configure.ac: AC_DEFINE GDB_SELF_TEST if $development.
2597 * configure, config.in: Re-generated.
2598 * server.c: Include common/sefltest.h.
2599 (captured_main): Handle option --selftest.
2600
2601 2017-08-09 Yao Qi <yao.qi@linaro.org>
2602
2603 * configure.srv (srv_i386_regobj): Remove i386-avx.o,
2604 i386-avx-avx512.o, i386-avx-mpx-avx512-pku.o, i386-mpx.o,
2605 i386-avx-mpx.o and i386-mmx.o.
2606 (srv_amd64_regobj): Remove amd64-avx.o, amd64-avx-avx512.o,
2607 amd64-avx-mpx-avx512-pku.o, amd64-mpx.o and amd64-avx-mpx.o.
2608 (srv_i386_xmlfiles): Remove i386/i386-avx.xml,
2609 i386/i386-avx-avx512.xml, i386/i386-avx-mpx-avx512-pku.xml,
2610 i386/i386-mpx.xml, i386/i386-avx-mpx.xml and i386/i386-mmx.xml.
2611 (srv_amd64_xmlfile):i386/amd64-avx.xml, i386/amd64-avx-avx512.xml,
2612 i386/amd64-avx-mpx-avx512-pku.xml, i386/amd64-mpx.xml,
2613 i386/amd64-avx-mpx.xml.
2614
2615 2017-08-09 Yao Qi <yao.qi@linaro.org>
2616
2617 * configure.srv (srv_amd64_regobj): Remove x32.o, x32-avx.o
2618 and x32-avx-avx512.o.
2619 (srv_amd64_xmlfiles): Remove i386/x32.xml, i386/x32-avx.xml
2620 i386/x32-avx-avx512.xml.
2621
2622 2017-07-26 Simon Marchi <simon.marchi@ericsson.com>
2623
2624 * tracepoint.h (enum class fast_tpoint_collect_result): New
2625 enumeration.
2626 (fast_tracepoint_collecting): Change return type to
2627 fast_tpoint_collect_result.
2628 * tracepoint.c (fast_tracepoint_collecting): Likewise.
2629 * linux-low.h: Include tracepoint.h.
2630 (struct lwp_info) <collecting_fast_tracepoint>: Change type to
2631 fast_tpoint_collect_result.
2632 * linux-low.c (handle_tracepoints): Adjust.
2633 (linux_fast_tracepoint_collecting): Change return type to
2634 fast_tpoint_collect_result.
2635 (maybe_move_out_of_jump_pad, linux_wait_for_event_filtered,
2636 linux_wait_1, stuck_in_jump_pad_callback,
2637 lwp_signal_can_be_delivered, linux_resume_one_lwp_throw,
2638 proceed_one_lwp): Adjust to type change.
2639
2640 2017-07-10 Yao Qi <yao.qi@linaro.org>
2641
2642 * linux-x86-low.c (x86_linux_read_description): Re-indent the code.
2643
2644 2017-06-29 Yao Qi <yao.qi@linaro.org>
2645
2646 * tdesc.h (struct target_desc) [IN_PROCESS_AGENT] <expedite_regs>:
2647 Remove.
2648 [IN_PROCESS_AGENT] <xmltarget>: Likewise.
2649
2650 2017-06-20 Simon Marchi <simon.marchi@ericsson.com>
2651
2652 * Makefile.in (IPA_OBJS): Sort and format one item per line.
2653
2654 2017-06-20 Sergio Durigan Junior <sergiodj@redhat.com>
2655
2656 * linux-low.c (linux_create_inferior): Adjust code to access the
2657 environment information via 'gdb_environ' class.
2658 * lynx-low.c (lynx_create_inferior): Likewise.
2659 * server.c (our_environ): Make it an instance of 'gdb_environ'.
2660 (get_environ): Return a pointer to 'our_environ'.
2661 (captured_main): Initialize 'our_environ'.
2662 * server.h (get_environ): Adjust prototype.
2663 * spu-low.c (spu_create_inferior): Adjust code to access the
2664 environment information via 'gdb_environ' class.
2665
2666 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2667
2668 * linux-low.c (linux_read_memory, linux_write_memory): Remove
2669 usage of "register" keyword.
2670
2671 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2672
2673 * configure: Re-generate.
2674
2675 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2676
2677 * configure: Re-generate.
2678
2679 2017-06-17 Simon Marchi <simon.marchi@ericsson.com>
2680
2681 * Makefile.in (COMPILE.pre): Add "-x c++".
2682
2683 2017-06-09 Sergio Durigan Junior <sergiodj@redhat.com>
2684
2685 * fork-child.c: Conditionally include <signal.h>.
2686
2687 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2688
2689 * server.c (handle_general_set): Handle new packet
2690 "QStartupWithShell".
2691 (handle_query): Add "QStartupWithShell" to the list of supported
2692 packets.
2693 (gdbserver_usage): Add help text explaining the
2694 new "--startup-with-shell" and "--no-startup-with-shell" CLI
2695 options.
2696 (captured_main): Recognize and act upon the presence of the new
2697 CLI options.
2698
2699 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2700 Pedro Alves <palves@redhat.com>
2701
2702 * Makefile.in (SFILES): Add "nat/fork-inferior.o".
2703 * configure: Regenerate.
2704 * configure.srv (srv_linux_obj): Add "fork-child.o" and
2705 "fork-inferior.o".
2706 (i[34567]86-*-lynxos*): Likewise.
2707 (spu*-*-*): Likewise.
2708 * fork-child.c: New file.
2709 * linux-low.c: Include "common-inferior.h", "nat/fork-inferior.h"
2710 and "environ.h".
2711 (linux_ptrace_fun): New function.
2712 (linux_create_inferior): Adjust function prototype to reflect
2713 change on "target.h". Adjust function code to use
2714 "fork_inferior".
2715 (linux_request_interrupt): Delete "signal_pid".
2716 * lynx-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2717 (lynx_ptrace_fun): New function.
2718 (lynx_create_inferior): Adjust function prototype to reflect
2719 change on "target.h". Adjust function code to use
2720 "fork_inferior".
2721 * nto-low.c (nto_create_inferior): Adjust function prototype and
2722 code to reflect change on "target.h". Update comments.
2723 * server.c: Include "common-inferior.h", "nat/fork-inferior.h",
2724 "common-terminal.h" and "environ.h".
2725 (terminal_fd): Moved to fork-child.c.
2726 (old_foreground_pgrp): Likewise.
2727 (restore_old_foreground_pgrp): Likewise.
2728 (last_status): Make it global.
2729 (last_ptid): Likewise.
2730 (our_environ): New variable.
2731 (startup_with_shell): Likewise.
2732 (program_name): Likewise.
2733 (program_argv): Rename to...
2734 (program_args): ...this.
2735 (wrapper_argv): New variable.
2736 (start_inferior): Delete function.
2737 (get_exec_wrapper): New function.
2738 (get_exec_file): Likewise.
2739 (get_environ): Likewise.
2740 (prefork_hook): Likewise.
2741 (post_fork_inferior): Likewise.
2742 (postfork_hook): Likewise.
2743 (postfork_child_hook): Likewise.
2744 (handle_v_run): Update code to deal with arguments coming from the
2745 remote host. Update calls from "start_inferior" to
2746 "create_inferior".
2747 (captured_main): Likewise. Initialize environment variable. Call
2748 "have_job_control".
2749 * server.h (post_fork_inferior): New prototype.
2750 (get_environ): Likewise.
2751 (last_status): Declare.
2752 (last_ptid): Likewise.
2753 (signal_pid): Likewise.
2754 * spu-low.c: Include "common-inferior.h" and "nat/fork-inferior.h".
2755 (spu_ptrace_fun): New function.
2756 (spu_create_inferior): Adjust function prototype to reflect change
2757 on "target.h". Adjust function code to use "fork_inferior".
2758 * target.c (target_terminal_init): New function.
2759 (target_terminal_inferior): Likewise.
2760 (target_terminal_ours): Likewise.
2761 * target.h: Include <vector>.
2762 (struct target_ops) <create_inferior>: Update prototype.
2763 (create_inferior): Update macro.
2764 * utils.c (gdb_flush_out_err): New function.
2765 * win32-low.c (win32_create_inferior): Adjust function prototype
2766 and code to reflect change on "target.h".
2767
2768 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2769
2770 * inferiors.c (switch_to_thread): New function.
2771
2772 2017-06-07 Sergio Durigan Junior <sergiodj@redhat.com>
2773
2774 * Makefile.in (SFILE): Add "common/job-control.c".
2775 (OBS): Add "job-control.o".
2776
2777 2017-05-06 Sergio Durigan Junior <sergiodj@redhat.com>
2778
2779 * Makefile: Remove "@host_makefile_frag@".
2780
2781 2017-05-05 Pedro Alves <palves@redhat.com>
2782
2783 * configure: Regenerate.
2784
2785 2017-05-03 Sergio Durigan Junior <sergiodj@redhat.com>
2786
2787 * configure: Regenerate.
2788
2789 2017-05-02 Simon Marchi <simon.marchi@polymtl.ca>
2790
2791 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Adjust to
2792 software_single_step change of return type to
2793 std::vector<CORE_ADDR>.
2794 * linux-low.c (install_software_single_step_breakpoints):
2795 Likewise.
2796 * linux-low.h (install_software_single_step_breakpoints):
2797 Likewise.
2798
2799 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2800
2801 * remote-utils.c: Include "gdb_termios.h" instead of
2802 "terminal.h".
2803 * terminal.h: Delete file.
2804
2805 2017-04-12 Sergio Durigan Junior <sergiodj@redhat.com>
2806
2807 * server.c: Include <vector>.
2808 <program_argv, wrapper_argv>: Convert to std::vector.
2809 (start_inferior): Rewrite function to use C++.
2810 (handle_v_run): Likewise. Update code that calculates the argv
2811 based on the vRun packet; use C++.
2812 (captured_main): Likewise.
2813
2814 2017-04-06 Simon Marchi <simon.marchi@ericsson.com>
2815
2816 * server.c (handle_v_cont): Initialize thread_resume::thread
2817 with null_ptid.
2818
2819 2017-04-05 Pedro Alves <palves@redhat.com>
2820
2821 * configure: Regenerate.
2822
2823 2017-04-05 Pedro Alves <palves@redhat.com>
2824
2825 * gdbreplay.c (sync_error): Constify.
2826 * linux-x86-low.c (push_opcode): Constify.
2827
2828 2017-04-05 Pedro Alves <palves@redhat.com>
2829
2830 * win32-low.c (get_child_debug_event)
2831 <CREATE_PROCESS_DEBUG_EVENT>: Don't report TARGET_WAITKIND_EXECD.
2832 Report TARGET_WAITKIND_SPURIOUS instead.
2833
2834 2017-04-05 Pedro Alves <palves@redhat.com>
2835
2836 * remote-utils.c (remote_prepare, remote_open): Constify.
2837 * remote-utils.h (remote_prepare, remote_open): Constify.
2838 * server.c (captured_main): Constify 'port' handling.
2839
2840 2017-04-04 Simon Marchi <simon.marchi@ericsson.com>
2841
2842 * Makefile.in (clean): Clear .deps.
2843
2844 2017-03-31 Simon Marchi <simon.marchi@polymtl.ca>
2845
2846 * .gitignore: Remove generated files, replace with wildcard.
2847 * (clean): Replace removal of generated files with wildcard.
2848 (version.c): Replace with...
2849 (version-generated.c): ...this.
2850 (xml-builtin.c): Replace with...
2851 (xml-builtin-generated.c): ...this.
2852 (%-ipa.o: %-generated.c, %.o: %-generated.c): New rules.
2853 (%.c: *regformats*): Replace with...
2854 (%-generated.c: *regformats*): ...this.
2855
2856 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2857
2858 * linux-xtensa-low.c (regnum::R_THREADPTR): New enum member.
2859 (xtensa_fill_gregset): Call collect_register_by_name for
2860 threadptr register.
2861 (xtensa_store_gregset): Call supply_register_by_name for
2862 threadptr register.
2863
2864 2017-03-27 Max Filippov <jcmvbkbc@gmail.com>
2865
2866 * linux-xtensa-low.c (xtensa_fill_gregset): Call collect_register
2867 for all registers in a0_regnum..a0_regnum + C0_NREGS range.
2868 (xtensa_store_gregset): Call supply_register for all registers in
2869 a0_regnum..a0_regnum + C0_NREGS range.
2870
2871 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2872
2873 * Makefile.in (%-ipa.o: %-ipa.c): New rule.
2874 (ax-ipa.o: ax.c): Remove.
2875 (linux-i386-ipa.o: linux-i386-ipa.c): Remove.
2876 (linux-amd64-ipa.o: linux-amd64-ipa.c): Remove.
2877 (linux-aarch64-ipa.o: linux-aarch64-ipa.c): Remove.
2878 (linux-s390-ipa.o: linux-s390-ipa.c): Remove.
2879 (linux-ppc-ipa.o: linux-ppc-ipa.c): Remove.
2880
2881 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2882
2883 * Makefile.in (%-ipa.o: ../common/%.c): New rule.
2884 (print-utils-ipa.o: ../common/print-utils.c): Remove.
2885 (rsp-low-ipa.o: ../common/rsp-low.c): Remove.
2886 (errors-ipa.o: ../common/errors.c): Remove.
2887 (format-ipa.o: ../common/format.c): Remove.
2888 (common-utils-ipa.o: ../common/common-utils.c): Remove.
2889
2890 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2891
2892 * Makefile.in (%-ipa.o: %.c): New rule.
2893 (tracepoint-ipa.o: tracepoint.c): Remove.
2894 (utils-ipa.o: utils.c): Remove.
2895 (remote-utils-ipa.o: remote-utils.c): Remove.
2896 (regcache-ipa.o: regcache.c): Remove.
2897 (i386-linux-ipa.o: i386-linux.c): Remove.
2898 (i386-mmx-linux-ipa.o: i386-mmx-linux.c): Remove.
2899 (i386-avx-linux-ipa.o: i386-avx-linux.c): Remove.
2900 (i386-mpx-linux-ipa.o: i386-mpx-linux.c): Remove.
2901 (i386-avx-mpx-linux-ipa.o: i386-avx-mpx-linux.c): Remove.
2902 (i386-avx-avx512-linux-ipa.o: i386-avx-avx512-linux.c): Remove.
2903 (i386-avx-mpx-avx512-pku-linux-ipa.o: i386-avx-mpx-avx512-pku-linux.c): Remove.
2904 (amd64-linux-ipa.o: amd64-linux.c): Remove.
2905 (amd64-avx-linux-ipa.o: amd64-avx-linux.c): Remove.
2906 (amd64-mpx-linux-ipa.o: amd64-mpx-linux.c): Remove.
2907 (amd64-avx-mpx-linux-ipa.o: amd64-avx-mpx-linux.c): Remove.
2908 (amd64-avx-avx512-linux-ipa.o: amd64-avx-avx512-linux.c): Remove.
2909 (amd64-avx-mpx-avx512-pku-linux-ipa.o: amd64-avx-mpx-avx512-pku-linux.c): Remove.
2910 (aarch64-ipa.o: aarch64.c): Remove.
2911 (s390-linux32-ipa.o: s390-linux32.c): Remove.
2912 (s390-linux32v1-ipa.o: s390-linux32v1.c): Remove.
2913 (s390-linux32v2-ipa.o: s390-linux32v2.c): Remove.
2914 (s390-linux64-ipa.o: s390-linux64.c): Remove.
2915 (s390-linux64v1-ipa.o: s390-linux64v1.c): Remove.
2916 (s390-linux64v2-ipa.o: s390-linux64v2.c): Remove.
2917 (s390-te-linux64-ipa.o: s390-te-linux64.c): Remove.
2918 (s390-vx-linux64-ipa.o: s390-vx-linux64.c): Remove.
2919 (s390-tevx-linux64-ipa.o: s390-tevx-linux64.c): Remove.
2920 (s390x-linux64-ipa.o: s390x-linux64.c): Remove.
2921 (s390x-linux64v1-ipa.o: s390x-linux64v1.c): Remove.
2922 (s390x-linux64v2-ipa.o: s390x-linux64v2.c): Remove.
2923 (s390x-te-linux64-ipa.o: s390x-te-linux64.c): Remove.
2924 (s390x-vx-linux64-ipa.o: s390x-vx-linux64.c): Remove.
2925 (s390x-tevx-linux64-ipa.o: s390x-tevx-linux64.c): Remove.
2926 (powerpc-32l-ipa.o: powerpc-32l.c): Remove.
2927 (powerpc-altivec32l-ipa.o: powerpc-altivec32l.c): Remove.
2928 (powerpc-cell32l-ipa.o: powerpc-cell32l.c): Remove.
2929 (powerpc-vsx32l-ipa.o: powerpc-vsx32l.c): Remove.
2930 (powerpc-isa205-32l-ipa.o: powerpc-isa205-32l.c): Remove.
2931 (powerpc-isa205-altivec32l-ipa.o: powerpc-isa205-altivec32l.c): Remove.
2932 (powerpc-isa205-vsx32l-ipa.o: powerpc-isa205-vsx32l.c): Remove.
2933 (powerpc-e500l-ipa.o: powerpc-e500l.c): Remove.
2934 (powerpc-64l-ipa.o: powerpc-64l.c): Remove.
2935 (powerpc-altivec64l-ipa.o: powerpc-altivec64l.c): Remove.
2936 (powerpc-cell64l-ipa.o: powerpc-cell64l.c): Remove.
2937 (powerpc-vsx64l-ipa.o: powerpc-vsx64l.c): Remove.
2938 (powerpc-isa205-64l-ipa.o: powerpc-isa205-64l.c): Remove.
2939 (powerpc-isa205-altivec64l-ipa.o: powerpc-isa205-altivec64l.c): Remove.
2940 (powerpc-isa205-vsx64l-ipa.o: powerpc-isa205-vsx64l.c): Remove.
2941 (tdesc-ipa.o: tdesc.c): Remove.
2942 (x32-linux-ipa.o: x32-linux.c): Remove.
2943 (x32-avx-linux-ipa.o: x32-avx-linux.c): Remove.
2944 (x32-avx512-linux-ipa.o: x32-avx512-linux.c): Remove.
2945
2946 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2947
2948 * Makefile.in (%.o: ../arch/%.c): New rule.
2949 (arm.o: ../arch/arm.c): Remove.
2950 (arm-linux.o: ../arch/arm-linux.c): Remove.
2951 (arm-get-next-pcs.o: ../arch/arm-get-next-pcs.c): Remove.
2952 (aarch64-insn.o: ../arch/aarch64-insn.c): Remove.
2953
2954 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2955
2956 * Makefile.in (%.o: ../nat/%.c): New rule.
2957 (x86-dregs.o: ../nat/x86-dregs.c): Remove.
2958 (amd64-linux-siginfo.o: ../nat/amd64-linux-siginfo.c): Remove.
2959 (linux-btrace.o: ../nat/linux-btrace.c): Remove.
2960 (linux-osdata.o: ../nat/linux-osdata.c): Remove.
2961 (linux-procfs.o: ../nat/linux-procfs.c): Remove.
2962 (linux-ptrace.o: ../nat/linux-ptrace.c): Remove.
2963 (linux-waitpid.o: ../nat/linux-waitpid.c): Remove.
2964 (mips-linux-watch.o: ../nat/mips-linux-watch.c): Remove.
2965 (ppc-linux.o: ../nat/ppc-linux.c): Remove.
2966 (linux-personality.o: ../nat/linux-personality.c): Remove.
2967 (aarch64-linux-hw-point.o: ../nat/aarch64-linux-hw-point.c): Remove.
2968 (aarch64-linux.o: ../nat/aarch64-linux.c): Remove.
2969 (x86-linux.o: ../nat/x86-linux.c): Remove.
2970 (x86-linux-dregs.o: ../nat/x86-linux-dregs.c): Remove.
2971 (linux-namespaces.o: ../nat/linux-namespaces.c): Remove.
2972
2973 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
2974
2975 * Makefile.in (%.o: ../common/%.c): New rule.
2976 (signals.o: ../common/signals.c): Remove.
2977 (print-utils.o: ../common/print-utils.c): Remove.
2978 (rsp-low.o: ../common/rsp-low.c): Remove.
2979 (common-utils.o: ../common/common-utils.c): Remove.
2980 (posix-strerror.o: ../common/posix-strerror.c): Remove.
2981 (mingw-strerror.o: ../common/mingw-strerror.c): Remove.
2982 (vec.o: ../common/vec.c): Remove.
2983 (gdb_vecs.o: ../common/gdb_vecs.c): Remove.
2984 (xml-utils.o: ../common/xml-utils.c): Remove.
2985 (ptid.o: ../common/ptid.c): Remove.
2986 (buffer.o: ../common/buffer.c): Remove.
2987 (format.o: ../common/format.c): Remove.
2988 (filestuff.o: ../common/filestuff.c): Remove.
2989 (agent.o: ../common/agent.c): Remove.
2990 (errors.o: ../common/errors.c): Remove.
2991 (environ.o: ../common/environ.c): Remove.
2992 (common-debug.o: ../common/common-debug.c): Remove.
2993 (cleanups.o: ../common/cleanups.c): Remove.
2994 (common-exceptions.o: ../common/common-exceptions.c): Remove.
2995 (fileio.o: ../common/fileio.c): Remove.
2996 (common-regcache.o: ../common/common-regcache.c): Remove.
2997 (signals-state-save-restore.o: ../common/signals-state-save-restore.c): Remove.
2998 (new-op.o: ../common/new-op.c): Remove.
2999 (btrace-common.o: ../common/btrace-common.c): Remove.
3000
3001 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3002
3003 * Makefile.in (%.o: ../target/%.c): New rule.
3004 (waitstatus.o: ../target/waitstatus.c): Remove.
3005
3006 2017-03-13 Simon Marchi <simon.marchi@polymtl.ca>
3007
3008 * Makefile.in
3009 (%.c: ../regformats/%.dat,
3010 (%.c: ../regformats/arm/%.dat,
3011 (%.c: ../regformats/i386/%.dat,
3012 (%.c: ../regformats/rs6000/%.dat): New rules.
3013 (aarch64.c): Remove.
3014 (reg-arm.c): Remove.
3015 (arm-with-iwmmxt.c): Remove.
3016 (arm-with-vfpv2.c): Remove.
3017 (arm-with-vfpv3.c): Remove.
3018 (arm-with-neon.c): Remove.
3019 (reg-bfin.c): Remove.
3020 (reg-cris.c): Remove.
3021 (reg-crisv32.c): Remove.
3022 (i386.c): Remove.
3023 (i386-linux.c): Remove.
3024 (i386-avx.c): Remove.
3025 (i386-avx-linux.c): Remove.
3026 (i386-avx-avx512.c): Remove.
3027 (i386-avx-avx512-linux.c): Remove.
3028 (i386-mpx.c): Remove.
3029 (i386-mpx-linux.c): Remove.
3030 (i386-avx-mpx-avx512-pku.c): Remove.
3031 (i386-avx-mpx-avx512-pku-linux.c): Remove.
3032 (i386-avx-mpx.c): Remove.
3033 (i386-avx-mpx-linux.c): Remove.
3034 (i386-mmx.c): Remove.
3035 (i386-mmx-linux.c): Remove.
3036 (reg-ia64.c): Remove.
3037 (reg-m32r.c): Remove.
3038 (reg-m68k.c): Remove.
3039 (reg-cf.c): Remove.
3040 (mips-linux.c): Remove.
3041 (mips-dsp-linux.c): Remove.
3042 (mips64-linux.c): Remove.
3043 (mips64-dsp-linux.c): Remove.
3044 (nios2-linux.c): Remove.
3045 (powerpc-32.c): Remove.
3046 (powerpc-32l.c): Remove.
3047 (powerpc-altivec32l.c): Remove.
3048 (powerpc-cell32l.c): Remove.
3049 (powerpc-vsx32l.c): Remove.
3050 (powerpc-isa205-32l.c): Remove.
3051 (powerpc-isa205-altivec32l.c): Remove.
3052 (powerpc-isa205-vsx32l.c): Remove.
3053 (powerpc-e500l.c): Remove.
3054 (powerpc-64l.c): Remove.
3055 (powerpc-altivec64l.c): Remove.
3056 (powerpc-cell64l.c): Remove.
3057 (powerpc-vsx64l.c): Remove.
3058 (powerpc-isa205-64l.c): Remove.
3059 (powerpc-isa205-altivec64l.c): Remove.
3060 (powerpc-isa205-vsx64l.c): Remove.
3061 (s390-linux32.c): Remove.
3062 (s390-linux32v1.c): Remove.
3063 (s390-linux32v2.c): Remove.
3064 (s390-linux64.c): Remove.
3065 (s390-linux64v1.c): Remove.
3066 (s390-linux64v2.c): Remove.
3067 (s390-te-linux64.c): Remove.
3068 (s390-vx-linux64.c): Remove.
3069 (s390-tevx-linux64.c): Remove.
3070 (s390x-linux64.c): Remove.
3071 (s390x-linux64v1.c): Remove.
3072 (s390x-linux64v2.c): Remove.
3073 (s390x-te-linux64.c): Remove.
3074 (s390x-vx-linux64.c): Remove.
3075 (s390x-tevx-linux64.c): Remove.
3076 (tic6x-c64xp-linux.c): Remove.
3077 (tic6x-c64x-linux.c): Remove.
3078 (tic6x-c62x-linux.c): Remove.
3079 (reg-sh.c): Remove.
3080 (reg-sparc64.c): Remove.
3081 (reg-spu.c): Remove.
3082 (amd64.c): Remove.
3083 (amd64-linux.c): Remove.
3084 (amd64-avx.c): Remove.
3085 (amd64-avx-linux.c): Remove.
3086 (amd64-avx-avx512.c): Remove.
3087 (amd64-avx-avx512-linux.c): Remove.
3088 (amd64-mpx.c): Remove.
3089 (amd64-mpx-linux.c): Remove.
3090 (amd64-avx-mpx-avx512-pku.c): Remove.
3091 (amd64-avx-mpx-avx512-pku-linux.c): Remove.
3092 (amd64-avx-mpx.c): Remove.
3093 (amd64-avx-mpx-linux.c): Remove.
3094 (x32.c): Remove.
3095 (x32-linux.c): Remove.
3096 (x32-avx.c): Remove.
3097 (x32-avx-linux.c): Remove.
3098 (x32-avx-avx512.c): Remove.
3099 (x32-avx-avx512-linux.c): Remove.
3100 (reg-xtensa.c): Remove.
3101 (reg-tilegx.c): Remove.
3102 (reg-tilegx32.c): Remove.
3103
3104 2017-03-07 Sergio Durigan Junior <sergiodj@redhat.com>
3105
3106 * Makefile.in (SFILES): Add "common/environ.c".
3107 (OBJS): Add "common/environ.h".
3108
3109 2017-01-27 Walfred Tedeschi <walfred.tedeschi@intel.com>
3110
3111 * configure.ac: Check if the fs_base and gs_base members of
3112 `struct user_regs_struct' exist.
3113 * config.in: Regenerated.
3114 * configure: Likewise.
3115
3116 2017-01-09 Antoine Tremblay <antoine.tremblay@ericsson.com>
3117
3118 * linux-aarch32-low.c (arm_breakpoint_kind_from_pc): Use
3119 target_read_memory.
3120 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer): Likewise.
3121 (get_next_pcs_syscall_next_pc): Likewise.
3122
3123 2016-12-23 Luis Machado <lgustavo@codesourcery.com>
3124
3125 * win32-i386-low.c: Fix incorrect reference to a couple source files.
3126 * nto-x86-low.c: Likewise.
3127
3128 2016-11-30 Simon Marchi <simon.marchi@polymtl.ca>
3129
3130 * Makefile.in: Include disable-implicit-rules.mk.
3131
3132 2016-11-23 Pedro Alves <palves@redhat.com>
3133
3134 * debug.c: Include <chrono> instead of "gdb_sys_time.h".
3135 (debug_vprintf): Use std::chrono::steady_clock instead of
3136 gettimeofday. Use '.' instead of ':'.
3137 * tracepoint.c: Include <chrono> instead of "gdb_sys_time.h".
3138 (get_timestamp): Use std::chrono::steady_clock instead of
3139 gettimeofday.
3140
3141 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3142
3143 * Makefile.in: Fix whitespace formatting.
3144
3145 2016-11-22 Simon Marchi <simon.marchi@polymtl.ca>
3146
3147 * Makefile.in (SFILES, OBS): Flatten list and order
3148 alphabetically.
3149
3150 2016-11-23 Pedro Alves <palves@redhat.com>
3151
3152 * event-loop.c (handle_file_event): Use warning.
3153 * linux-low.c (linux_resume_one_lwp_throw): Use warning.
3154 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
3155 Use warning.
3156
3157 2016-11-23 Pedro Alves <palves@redhat.com>
3158
3159 * linux-low.c (check_zombie_leaders): Use debug_printf for debug
3160 output.
3161 * notif.c (handle_notif_ack, notif_event_enque): Likewise.
3162 * remote-utils.c (putpkt_binary_1, readchar, getpkt): Use
3163 debug_printf and debug_flush for debug output.
3164 * server.c (handle_general_set): Likewise.
3165 * thread-db.c (try_thread_db_load): Use debug_printf for debug
3166 output.
3167
3168 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3169
3170 * Makefile.in (.c.o): Replace rule with ...
3171 (%.o: %.c): ... this one.
3172
3173 2016-11-17 Simon Marchi <simon.marchi@polymtl.ca>
3174
3175 * Makefile.in: Remove @GMAKE_TRUE@ prefixes and removes lines
3176 prefixed with @GMAKE_FALSE@. Update comment related to non-GNU
3177 make.
3178 * configure.ac: Remove checks for the make program.
3179 * configure: Re-generate.
3180
3181 2016-10-28 Pedro Alves <palves@redhat.com>
3182
3183 * Makefile.in (CXX_DIALECT): Get from configure.
3184 (COMPILE.pre, CC_LD): Append $(CXX_DIALECT).
3185 * acinclude.m4: Include ../ax_cxx_compile_stdcxx.m4.
3186 * configure.ac: Call AX_CXX_COMPILE_STDCXX.
3187 * config.in: Regenerate.
3188 * configure: Regenerate.
3189
3190 2016-10-27 Yao Qi <yao.qi@linaro.org>
3191
3192 * linux-low.c (linux_supports_range_stepping): Return true if
3193 can_software_single_step return true.
3194
3195 2016-10-27 Yao Qi <yao.qi@linaro.org>
3196
3197 * inferiors.c (find_inferior_in_random): New function.
3198 * inferiors.h (find_inferior_in_random): Declare.
3199 * linux-low.c (linux_wait_for_event_filtered): Call
3200 find_inferior_in_random instead of find_inferior.
3201
3202 2016-10-27 Yao Qi <yao.qi@linaro.org>
3203
3204 * linux-low.c (linux_wait_1): If single-step breakpoints are
3205 inserted, remove them.
3206
3207 2016-10-26 Pedro Alves <palves@redhat.com>
3208
3209 * linux-low.c (handle_extended_wait): Link parent/child fork
3210 threads.
3211 (linux_wait_1): Unlink them.
3212 (linux_set_resume_request): Ignore resume requests for
3213 already-resumed and unhandled fork child threads.
3214 * linux-low.h (struct lwp_info) <fork_relative>: New field.
3215 * server.c (in_queued_stop_replies_ptid, in_queued_stop_replies):
3216 New functions.
3217 (handle_v_requests) <vCont>: Don't call require_running.
3218 * server.h (in_queued_stop_replies): New declaration.
3219
3220 2016-10-24 Yao Qi <yao.qi@linaro.org>
3221
3222 PR server/20733
3223 * linux-aarch64-low.c (append_insns): Cast the return value to
3224 'uint32_t *'.
3225
3226 2016-10-10 Yao Qi <yao.qi@linaro.org>
3227
3228 * linux-aarch32-low.c (enum arm_breakpoint_kinds): Remove.
3229
3230 2016-10-06 Sergio Durigan Junior <sergiodj@redhat.com>
3231
3232 * target.c (target_supports_multi_process): New function, moved
3233 from...
3234 * target.h (target_supports_multi_process): ... here. Remove
3235 macro.
3236
3237 2016-10-05 Tom Tromey <tom@tromey.com>
3238
3239 PR remote/20655:
3240 * tracepoint.c (handle_tracepoint_bkpts): Check
3241 ipa_error_tracepoint, not ipa_stopping_tracepoint.
3242
3243 2016-10-05 Yao Qi <yao.qi@linaro.org>
3244
3245 * configure.srv: Update the path of arm-*.xml files.
3246
3247 2016-10-05 Terry Guo <terry.guo@arm.com>
3248 Yao Qi <yao.qi@linaro.org>
3249
3250 * Makefile.in: Adjust the path of rules.
3251 * configure.srv: Update the path of xml files.
3252 * regformats/arm-with-iwmmxt.dat: Regenerated.
3253 * regformats/arm-with-neon.dat: Likewise.
3254 * regformats/arm-with-vfpv2.dat: Likewise.
3255 * regformats/arm-with-vfpv3.dat Likewise.
3256
3257 2016-09-30 Yao Qi <yao.qi@linaro.org>
3258
3259 PR gdbserver/20627
3260 * target.c (target_stop_and_wait): Don't call
3261 target_continue_no_signal, use resume_stop instead.
3262
3263 2016-09-26 Yao Qi <yao.qi@linaro.org>
3264
3265 * linux-low.c (linux_wait_1): Call debug_exit.
3266
3267 2016-09-23 Pedro Alves <palves@redhat.com>
3268
3269 * Makefile.in (SFILES): Add common/new-op.c.
3270 (OBS): Add common/new-op.o.
3271 (new-op.o): New rule.
3272
3273 2016-09-21 Simon Marchi <simon.marchi@ericsson.com>
3274
3275 * .gitinore: Ignore more files.
3276
3277 2016-09-21 Yao Qi <yao.qi@linaro.org>
3278
3279 * linux-aarch32-low.c (arm_fill_gregset): Keep bits 20 to
3280 23.
3281
3282 2016-09-19 Sergio Durigan Junior <sergiodj@redhat.com>
3283
3284 * server.c (start_inferior): Call target_mourn_inferior instead of
3285 mourn_inferior; pass ptid_t argument to it.
3286 (resume): Likewise.
3287 (handle_target_event): Likewise.
3288 * target.c (target_mourn_inferior): New function.
3289 * target.h (mourn_inferior): Delete macro.
3290
3291 2016-09-16 Andreas Arnez <arnez@linux.vnet.ibm.com>
3292
3293 * linux-low.c (lwp_is_stepping): New function.
3294
3295 2016-09-06 Carl Love <cel@us.ibm.com>
3296
3297 * server.c (start_inferior): Fixed comment, requested comment change
3298 didn't get updated correctly. Removed reference to ptrace () call as
3299 it is only true on Linux systems.
3300
3301 2016-09-06 Carl Love <cel@us.ibm.com>
3302
3303 * server.c (start_inferior): Do not call
3304 function target_post_create_inferior () if the
3305 inferior process has already exited.
3306
3307 2016-09-05 Pedro Alves <palves@redhat.com>
3308
3309 * Makefile.in (COMPILER, COMPILER_CFLAGS): Remove.
3310 (COMPILE.pre, CC_LD): Use CXX directly.
3311 (INTERNAL_CFLAGS_BASE): Use CXXFLAGS directly.
3312 * acinclude.m4: Don't include build-with-cxx.m4.
3313 * configure.ac: Remove GDB_AC_BUILD_WITH_CXX call.
3314 * configure: Regenerate.
3315
3316 2016-09-02 Akash Trehan <akash.trehan123@gmail.com>
3317
3318 PR gdb/19495
3319 * remote-utils.c (relocate_instruction): Remove redundant strcpy()
3320 call writing data to own_buf.
3321
3322 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3323
3324 * target.c (mywait): Call target_wait instead of
3325 the_target->wait.
3326 (target_wait): New function.
3327
3328 2016-09-01 Sergio Durigan Junior <sergiodj@redhat.com>
3329
3330 * server.c (start_inferior): New variable 'ptid'. Replace calls
3331 to the_target->resume by target_continue{,_no_signal}, depending
3332 on the case.
3333 * target.c (target_stop_and_wait): Call target_continue_no_signal
3334 instead of the_target->resume.
3335 (target_continue): New function.
3336
3337 2016-08-31 Antoine Tremblay <antoine.tremblay@ericsson.com>
3338
3339 * linux-low.c (linux_wait_1): Move event switch after unsuspend_lwps.
3340
3341 2016-08-25 Adhemerval Zanella <adhemerval.zanella@linaro.org>
3342
3343 PR server/20491
3344 * gdb_proc_service.h (ps_get_thread_area): Remove const from struct
3345 ps_prochandle.
3346 * linux-aarch64-low.c (ps_get_thread_area): Likewise.
3347 * linux-arm-low.c (ps_get_thread_area): Likewise.
3348 * linux-crisv32-low.c (ps_get_thread_area): Likewise.
3349 * linux-m68k-low.c (ps_get_thread_area): Likewise.
3350 * linux-mips-low.c (ps_get_thread_area): Likewise.
3351 * linux-nios2-low.c (ps_get_thread_area): Likewise.
3352 * linux-tic6x-low.c (ps_get_thread_area): Likewise.
3353 * linux-x86-low.c (ps_get_thread_area): Likewise.
3354 * linux-xtensa-low.c (ps_get_thread_area): Likewise.
3355
3356 2016-08-19 Pedro Alves <palves@redhat.com>
3357
3358 * linux-x86-low.c (amd64_emit_call): Emit missing call opcode.
3359
3360 2016-08-19 Pedro Alves <palves@redhat.com>
3361
3362 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Fix
3363 comment. Use memcpy instead of casting through unsigned long.
3364
3365 2016-08-19 Pedro Alves <palves@redhat.com>
3366
3367 * linux-amd64-ipa.c (alloc_jump_pad_buffer) [__ILP32__]: Try
3368 allocating around 0x80000000.
3369
3370 2016-08-19 Pedro Alves <palves@redhat.com>
3371
3372 PR gdb/20415
3373 * Makefile.in (x32-linux-ipa.o, x32-avx-linux-ipa.o)
3374 (x32-avx512-linux-ipa.o): New rules.
3375 * configure.ac (x86_64-*-linux*): New x32 check.
3376 * configure.srv (ipa_x32_linux_regobj): New.
3377 (x86_64-*-linux*): Use $ipa_x32_linux_regobj if building for x32.
3378 * linux-amd64-ipa.c (get_ipa_tdesc) [__ILP32__]: Return x32
3379 descriptions.
3380 (initialize_low_tracepoint) [__ILP32__]: Initialize x32
3381 descriptions.
3382 * configure: Regenerate.
3383
3384 2016-08-09 Pedro Alves <palves@redhat.com>
3385
3386 PR gdb/18653
3387 * Makefile.in (OBS): Add signals-state-save-restore.o.
3388 (signals-state-save-restore.o): New rule.
3389 * config.in: Regenerate.
3390 * configure: Regenerate.
3391 * linux-low.c: Include "signals-state-save-restore.h".
3392 (linux_create_inferior): Call
3393 restore_original_signals_state.
3394 * server.c: Include "dispositions-save-restore.h".
3395 (captured_main): Call save_original_signals_state.
3396
3397 2016-08-05 Pedro Alves <palves@redhat.com>
3398
3399 * configure: Regenerate.
3400
3401 2016-08-04 Yao Qi <yao.qi@linaro.org>
3402
3403 * linux-low.c (regsets_fetch_inferior_registers): Check
3404 errno is ESRCH or not.
3405
3406 2016-08-02 Yao Qi <yao.qi@linaro.org>
3407
3408 * thread-db.c (struct thread_db) <td_ta_event_getmsg_p>: Remove.
3409 <td_ta_set_event_p, td_ta_event_addr_p>: Remove.
3410 (thread_db_load_search): Update.
3411 (try_thread_db_load_1): Don't look for td_ta_event_addr,
3412 td_ta_set_event and td_ta_event_getmsg.
3413
3414 2016-07-26 Pedro Alves <palves@redhat.com>
3415
3416 PR server/20414
3417 * linux-x86-low.c (x86_get_pc, x86_set_pc): Use uint64_t instead
3418 of unsigned long for 64-bit registers and use uint32_t instead of
3419 unsigned int for 32-bit registers.
3420
3421 2016-07-26 Pedro Alves <palves@redhat.com>
3422
3423 * linux-x86-low.c (x86_siginfo_fixup): Rename 'native' parameter
3424 to 'ptrace'.
3425
3426 2016-07-21 Tom Tromey <tom@tromey.com>
3427
3428 * configure: Rebuild.
3429
3430 2016-07-21 Yao Qi <yao.qi@linaro.org>
3431
3432 * mem-break.c (find_gdb_breakpoint): Cast bp to
3433 'struct gdb_breakpoint *' rather than 'gdb_breakpoint *'.
3434
3435 2016-07-21 Yao Qi <yao.qi@linaro.org>
3436
3437 * server.c (handle_v_requests): Support s and S actions
3438 if target_supports_software_single_step return true.
3439
3440 2016-07-21 Yao Qi <yao.qi@linaro.org>
3441
3442 * linux-low.c (resume_stopped_resumed_lwps): If resume request
3443 is resume_step, call maybe_hw_step.
3444 (linux_wait_1): Stop all threads, remove reinsert breakpoints,
3445 and unstop them.
3446 (linux_resume_one_lwp_throw): Don't assert the thread has reinsert
3447 breakpoints or not.
3448 (proceed_one_lwp): If resume request is resume_step, install
3449 reinsert breakpoints and call maybe_hw_step.
3450
3451 2016-07-21 Yao Qi <yao.qi@linaro.org>
3452
3453 * linux-low.c (proceed_one_lwp): Declare.
3454 (linux_resume_one_thread): Remove local variable 'step'.
3455 Lift code enqueue signal. Call proceed_one_lwp instead of
3456 linux_resume_one_lwp.
3457
3458 2016-07-21 Yao Qi <yao.qi@linaro.org>
3459
3460 * linux-low.c (linux_resume_one_thread): Call
3461 enqueue_pending_signal.
3462
3463 2016-07-21 Yao Qi <yao.qi@linaro.org>
3464
3465 * gdbthread.h (make_cleanup_restore_current_thread): Declare.
3466 * inferiors.c (do_restore_current_thread_cleanup): New function.
3467 (make_cleanup_restore_current_thread): Likewise.
3468 * linux-low.c (install_software_single_step_breakpoints): Call
3469 make_cleanup_restore_current_thread. Switch current_thread to
3470 thread.
3471
3472 2016-07-21 Yao Qi <yao.qi@linaro.org>
3473
3474 * mem-break.c (struct reinsert_breakpoint) <ptid>: New field.
3475 (set_reinsert_breakpoint): New parameter ptid. Callers updated.
3476 (clone_one_breakpoint): Likewise.
3477 (delete_reinsert_breakpoints): Change parameter to thread.
3478 Callers updated.
3479 (has_reinsert_breakpoints): Likewise.
3480 (uninsert_reinsert_breakpoints): Likewise.
3481 (reinsert_reinsert_breakpoints): Likewise.
3482 * mem-break.h (set_reinsert_breakpoint): Update declaration.
3483 (delete_reinsert_breakpoints): Likewise.
3484 (reinsert_reinsert_breakpoints): Likewise.
3485 (uninsert_reinsert_breakpoints): Likewise.
3486 (has_reinsert_breakpoints): Likewise.
3487
3488 2016-07-21 Yao Qi <yao.qi@linaro.org>
3489
3490 * inferiors.c (get_thread_process): Make parameter const.
3491 * inferiors.h (get_thread_process): Update declaration.
3492 * mem-break.c (clone_all_breakpoints): Remove all parameters.
3493 Add new parameters child_thread and parent_thread. Callers
3494 updated.
3495 * mem-break.h (clone_all_breakpoints): Update declaration.
3496
3497 2016-07-21 Yao Qi <yao.qi@linaro.org>
3498
3499 * mem-break.c (struct breakpoint) <cond_list>: Remove.
3500 <command_list, handler>: Remove.
3501 (struct gdb_breakpoint): New.
3502 (struct other_breakpoint): New.
3503 (struct reinsert_breakpoint): New.
3504 (is_gdb_breakpoint): New function.
3505 (any_persistent_commands): Update command_list if
3506 is_gdb_breakpoint returns true.
3507 (set_breakpoint): Create breakpoints according to their types.
3508 (find_gdb_breakpoint): Return 'struct gdb_breakpoint *'.
3509 (set_gdb_breakpoint_1): Likewise.
3510 (set_gdb_breakpoint): Likewise.
3511 (clear_breakpoint_conditions): Change parameter type to
3512 'struct gdb_breakpoint *'.
3513 (clear_breakpoint_commands): Likewise.
3514 (clear_breakpoint_conditions_and_commands): Likewise.
3515 (add_condition_to_breakpoint): Likewise.
3516 (add_breakpoint_condition): Likewise.
3517 (add_commands_to_breakpoint): Likewise.
3518 (check_breakpoints): Check other_breakpoint.
3519 (clone_one_breakpoint): Clone breakpopint according to its type.
3520 * mem-break.h (struct gdb_breakpoint): Declare.
3521 (set_gdb_breakpoint): Update declaration.
3522 (clear_breakpoint_conditions_and_commands): Likewise.
3523 (add_breakpoint_condition): Likewise.
3524 (add_breakpoint_commands): Likewise.
3525 * server.c (process_point_options): Change parameter type to
3526 'struct gdb_breakpoint *'.
3527
3528 2016-07-21 Yao Qi <yao.qi@linaro.org>
3529
3530 * mem-break.c (set_breakpoint_at): Rename it to ...
3531 (set_breakpoint_type_at): ... it.
3532 (set_breakpoint_at): Call set_breakpoint_type_at.
3533 (set_reinsert_breakpoint): Call set_breakpoint_type_at.
3534 * mem-break.h (set_breakpoint_at): Update comments.
3535
3536 2016-07-12 Chung-Lin Tang <cltang@codesourcery.com>
3537
3538 * linux-nios2-low.c (nios2_fill_gregset): Add type cast
3539 to buf parameter.
3540 (nios2_store_gregset): Likewise.
3541
3542 2016-07-01 Pedro Alves <palves@redhat.com>
3543 Antoine Tremblay <antoine.tremblay@ericsson.com>
3544
3545 * linux-low.c: Change interface to take the target lwp_info
3546 pointer directly and return void. Handle detaching from a zombie
3547 thread.
3548 (linux_detach_lwp_callback): New function.
3549 (linux_detach): Detach from the leader thread after detaching from
3550 the clone threads.
3551
3552 2016-06-28 Yao Qi <yao.qi@linaro.org>
3553
3554 * linux-aarch64-low.c (aarch64_ftrace_insn_reloc_b): Use int64_t
3555 for variable new_offset.
3556 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
3557 (aarch64_ftrace_insn_reloc_cb): Likewise.
3558 (aarch64_ftrace_insn_reloc_tb): Likewise.
3559 (aarch64_install_fast_tracepoint_jump_pad): Likewise. Use
3560 PRIx64 instead of PRIx32.
3561
3562 2016-06-28 Yao Qi <yao.qi@linaro.org>
3563
3564 * linux-arm-low.c (arm_get_syscall_trapinfo): New function.
3565 (the_low_target): Install arm_get_syscall_trapinfo.
3566
3567 2016-06-28 Yao Qi <yao.qi@linaro.org>
3568
3569 * linux-aarch64-low.c (aarch64_get_syscall_trapinfo): New
3570 function.
3571 (the_low_target): Install aarch64_get_syscall_trapinfo.
3572
3573 2016-06-28 Yao Qi <yao.qi@linaro.org>
3574
3575 * linux-low.c (get_syscall_trapinfo): Remove parameter sysret.
3576 Callers updated.
3577 * linux-low.h (struct linux_target_ops) <get_syscall_trapinfo>:
3578 Remove parameter sysno.
3579 * linux-x86-low.c (x86_get_syscall_trapinfo): Remove parameter
3580 sysret.
3581
3582 2016-06-21 Andreas Arnez <arnez@linux.vnet.ibm.com>
3583
3584 * linux-s390-low.c (s390_emit_eq_goto): Mark function static.
3585 (s390_emit_ne_goto): Likewise.
3586 (s390_emit_lt_goto): Likewise.
3587 (s390_emit_le_goto): Likewise.
3588 (s390_emit_gt_goto): Likewise.
3589 (s390_emit_ge_goto): Likewise.
3590 (s390x_emit_eq_goto): Likewise.
3591 (s390x_emit_ne_goto): Likewise.
3592 (s390x_emit_lt_goto): Likewise.
3593 (s390x_emit_le_goto): Likewise.
3594 (s390x_emit_gt_goto): Likewise.
3595 (s390x_emit_ge_goto): Likewise.
3596 (s390_emit_ops_impl): Mark variable static.
3597 (s390x_emit_ops): Likewise.
3598
3599 2016-06-17 Yao Qi <yao.qi@linaro.org>
3600
3601 * linux-low.c (handle_extended_wait): Call
3602 uninsert_reinsert_breakpoints for the parent process. Remove
3603 reinsert breakpoints from the child process. Reinsert them to
3604 the parent process when vfork is done.
3605 * mem-break.c (uninsert_reinsert_breakpoints): New function.
3606 (reinsert_reinsert_breakpoints): New function.
3607 * mem-break.h (uninsert_reinsert_breakpoints): Declare
3608 (reinsert_reinsert_breakpoints): Declare.
3609
3610 2016-06-17 Yao Qi <yao.qi@linaro.org>
3611
3612 * linux-low.c (handle_extended_wait): If the parent is doing
3613 step-over, remove the reinsert breakpoints from the forked child.
3614
3615 2016-06-17 Yao Qi <yao.qi@linaro.org>
3616
3617 * linux-low.c (unsuspend_all_lwps): Declare.
3618 (linux_low_filter_event): If thread exited, call finish_step_over.
3619 If step-over is finished, unsuspend other threads.
3620
3621 2016-06-17 Yao Qi <yao.qi@linaro.org>
3622
3623 * linux-low.c (linux_resume_one_lwp_throw): Assert
3624 has_reinsert_breakpoints returns false.
3625 * mem-break.c (delete_disabled_breakpoints): Assert
3626 bp type isn't reinsert_breakpoint.
3627
3628 2016-06-17 Yao Qi <yao.qi@linaro.org>
3629
3630 * linux-low.c (maybe_hw_step): New function.
3631 (linux_resume_one_lwp_throw): Call maybe_hw_step.
3632 (finish_step_over): Switch current_thread to lwp temporarily,
3633 and assert has_reinsert_breakpoints returns true.
3634 (proceed_one_lwp): Call maybe_hw_step.
3635 * mem-break.c (has_reinsert_breakpoints): New function.
3636 * mem-break.h (has_reinsert_breakpoints): Declare.
3637
3638 2016-06-02 Jon Turney <jon.turney@dronecode.org.uk>
3639
3640 * win32-low.c (win32_create_inferior): Add pointer casts for C++.
3641
3642 2016-05-17 Yao Qi <yao.qi@linaro.org>
3643
3644 * linux-low.c (linux_stabilize_threads): Call unsuspend_all_lwps
3645 instead of find_inferior.
3646
3647 2016-05-05 Yao Qi <yao.qi@linaro.org>
3648
3649 * linux-arm-low.c (get_next_pcs_read_memory_unsigned_integer):
3650 Initialize res to zero.
3651
3652 2016-05-05 Yao Qi <yao.qi@linaro.org>
3653
3654 * linux-arm-low.c (arm_sigreturn_next_pc): Change type of cpsr
3655 to uint32_t.
3656
3657 2016-05-04 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
3658
3659 * spu-low.c (fetch_ppc_register): Cast PowerPC-Linux-specific value
3660 used as first ptrace argument to PTRACE_TYPE_ARG1 for C++.
3661 (fetch_ppc_memory_1, store_ppc_memory_1): Likewise.
3662
3663 2016-04-28 Par Olsson <par.olsson@windriver.com>
3664 Simon Marchi <simon.marchi@ericsson.com>
3665
3666 * tracepoint.c (write_inferior_int8): New function.
3667 (cmd_qtenable_disable): Write enable flag using
3668 write_inferior_int8.
3669
3670 2016-04-25 Yao Qi <yao.qi@linaro.org>
3671
3672 * linux-low.c (lwp_signal_can_be_delivered): Adjust.
3673 (need_step_over_p): Return zero if the LWP has pending signals
3674 can be delivered on software single step target.
3675
3676 2016-04-25 Yao Qi <yao.qi@linaro.org>
3677
3678 * linux-low.c (reinsert_raw_breakpoint): If bp->inserted is true
3679 return instead of error.
3680
3681 2016-04-22 Yao Qi <yao.qi@linaro.org>
3682
3683 * linux-aarch32-low.c (arm_store_gregset): Clear CPSR bits 20
3684 to 23.
3685
3686 2016-04-22 Yao Qi <yao.qi@linaro.org>
3687
3688 * linux-low.c (lwp_signal_can_be_delivered): Don't deliver
3689 signal when stepping over breakpoint with software single
3690 step.
3691
3692 2016-04-21 Pedro Alves <palves@redhat.com>
3693
3694 * linux-s390-low.c (s390_collect_ptrace_register)
3695 (s390_supply_ptrace_register, s390_get_hwcap): Use gdb_byte * and
3696 add casts.
3697 (s390_check_regset): Use void * instead of gdb_byte *.
3698
3699 2016-04-20 Pedro Alves <palves@redhat.com>
3700
3701 * configure: Renegerate.
3702
3703 2016-04-20 Yao Qi <yao.qi@linaro.org>
3704
3705 * linux-aarch32-low.c: Include "arch/arm-linux.h".
3706 (arm_fill_gregset): Use ARM_CPSR_GREGNUM rather than magic
3707 number 16.
3708 (arm_store_gregset): Likewise.
3709
3710 2016-04-16 Walfred Tedeschi <walfred.tedeschi@intel.com>
3711
3712 * Makefile.in (clean): Add removal for i386-avx-mpx.c,
3713 i386-avx-mpx-linux.c, amd64-avx-mpx.c and amd64-avx-mpx-linux.c.
3714 (i386-avx-mpx.c, i386-avx-mpx-linux.c, amd64-avx-mpx.c)
3715 (amd64-avx-mpx-linux.c): New rules.
3716 (amd64-avx-mpx-linux-ipa.o, i386-avx-mpx-linux-ipa.o): New rule.
3717 * configure.srv (srv_i386_regobj): Add i386-avx-mpx.o.
3718 (srv_i386_linux_regobj): Add i386-avx-mpx-linux.o.
3719 (srv_amd64_regobj): Add amd64-avx-mpx.o.
3720 (srv_amd64_linux_regobj): Add amd64-avx-mpx-linux.o.
3721 (srv_i386_xmlfiles): Add i386/i386-avx-mpx.xml.
3722 (srv_amd64_xmlfiles): Add i386/amd64-avx-mpx.xml.
3723 (srv_i386_linux_xmlfiles): Add i386/i386-avx-mpx-linux.xml.
3724 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-mpx-linux.xml.
3725 (ipa_i386_linux_regobj): Add i386-avx-mpx-linux-ipa.o.
3726 (ipa_amd64_linux_regobj): Add amd64-avx-mpx-linux-ipa.o.
3727 * linux-x86-low.c (x86_linux_read_description): Add case for
3728 X86_XSTATE_AVX_MPX_MASK.
3729 (x86_get_ipa_tdesc_idx): Add cases for avx_mpx.
3730 (initialize_low_arch): Call init_registers_amd64_avx_mpx_linux and
3731 init_registers_i386_avx_mpx_linux.
3732 * linux-i386-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3733 (initialize_low_tracepoint): Call
3734 init_registers_i386_avx_mpx_linux.
3735 * linux-amd64-ipa.c (get_ipa_tdesc): Add case for avx_mpx.
3736 (initialize_low_tracepoint): Call
3737 init_registers_amd64_avx_mpx_linux.
3738 * linux-x86-tdesc.h (X86_TDESC_AVX_MPX): New enum value.
3739 (init_registers_amd64_avx_mpx_linux, tdesc_amd64_avx_mpx_linux)
3740 (init_registers_i386_avx_mpx_linux, tdesc_i386_avx_mpx_linux): New
3741 declarations.
3742
3743 2016-04-18 Pedro Alves <palves@redhat.com>
3744
3745 * configure: Regenerate.
3746
3747 2016-04-13 Antoine Tremblay <antoine.tremblay@ericsson.com>
3748
3749 * linux-aarch64-low.c (aarch64_emit_add): Switch x1 and x0.
3750 (aarch64_emit_sub): Likewise.
3751
3752 2016-04-12 Pedro Alves <palves@redhat.com>
3753
3754 * utils.c (prepare_to_throw_exception): Delete.
3755
3756 2016-04-05 Simon Marchi <simon.marchi@ericsson.com>
3757
3758 * Makefile.in ($(IPA_LIB)): Set SONAME of the IPA lib.
3759
3760 2016-04-05 Marcin Kościelnicki <koriakin@0x04.net>
3761
3762 * tracepoint.c (getauxval): Move to #ifdef IN_PROCESS_AGENT.
3763
3764 2016-04-03 Marcin Kościelnicki <koriakin@0x04.net>
3765
3766 * linux-aarch64-ipa.c: Add <elf.h> include.
3767 * linux-ppc-ipa.c: Add <elf.h> include.
3768 * linux-s390-ipa.c: Add <elf.h> include.
3769
3770 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3771
3772 * tracepoint.c (gdb_collect_ptr): Remove const qualifier.
3773 (get_raw_reg_ptr): Likewise.
3774 (get_trace_state_variable_value_ptr): Likewise.
3775 (set_trace_state_variable_value_ptr): Likewise.
3776 (initialize_tracepoint): Cast alloc_jump_pad_buffer result to
3777 char *.
3778
3779 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3780 Marcin Kościelnicki <koriakin@0x04.net>
3781
3782 PR/17221
3783 * linux-ppc-low.c (emit_insns): New function.
3784 (__EMIT_ASM, _EMIT_ASM, EMIT_ASM): New macros.
3785 (ppc_emit_prologue): New function.
3786 (ppc_emit_epilogue): New function.
3787 (ppc_emit_add): New function.
3788 (ppc_emit_sub): New function.
3789 (ppc_emit_mul): New function.
3790 (ppc_emit_lsh): New function.
3791 (ppc_emit_rsh_signed): New function.
3792 (ppc_emit_rsh_unsigned): New function.
3793 (ppc_emit_ext): New function.
3794 (ppc_emit_zero_ext): New function.
3795 (ppc_emit_log_not): New function.
3796 (ppc_emit_bit_and): New function.
3797 (ppc_emit_bit_or): New function.
3798 (ppc_emit_bit_xor): New function.
3799 (ppc_emit_bit_not): New function.
3800 (ppc_emit_equal): New function.
3801 (ppc_emit_less_signed): New function.
3802 (ppc_emit_less_unsigned): New function.
3803 (ppc_emit_ref): New function.
3804 (ppc_emit_const): New function.
3805 (ppc_emit_reg): New function.
3806 (ppc_emit_pop): New function.
3807 (ppc_emit_stack_flush): New function.
3808 (ppc_emit_swap): New function.
3809 (ppc_emit_stack_adjust): New function.
3810 (ppc_emit_call): New function.
3811 (ppc_emit_int_call_1): New function.
3812 (ppc_emit_void_call_2): New function.
3813 (ppc_emit_if_goto): New function.
3814 (ppc_emit_goto): New function.
3815 (ppc_emit_eq_goto): New function.
3816 (ppc_emit_ne_goto): New function.
3817 (ppc_emit_lt_goto): New function.
3818 (ppc_emit_le_goto): New function.
3819 (ppc_emit_gt_goto): New function.
3820 (ppc_emit_ge_goto): New function.
3821 (ppc_write_goto_address): New function.
3822 (ppc_emit_ops_impl): New static variable.
3823 (ppc64v1_emit_prologue): New function.
3824 (ppc64v2_emit_prologue): New function.
3825 (ppc64_emit_epilogue): New function.
3826 (ppc64_emit_add): New function.
3827 (ppc64_emit_sub): New function.
3828 (ppc64_emit_mul): New function.
3829 (ppc64_emit_lsh): New function.
3830 (ppc64_emit_rsh_signed): New function.
3831 (ppc64_emit_rsh_unsigned): New function.
3832 (ppc64_emit_ext): New function.
3833 (ppc64_emit_zero_ext): New function.
3834 (ppc64_emit_log_not): New function.
3835 (ppc64_emit_bit_and): New function.
3836 (ppc64_emit_bit_or): New function.
3837 (ppc64_emit_bit_xor): New function.
3838 (ppc64_emit_bit_not): New function.
3839 (ppc64_emit_equal): New function.
3840 (ppc64_emit_less_signed): New function.
3841 (ppc64_emit_less_unsigned): New function.
3842 (ppc64_emit_ref): New function.
3843 (ppc64_emit_const): New function.
3844 (ppc64v1_emit_reg): New function.
3845 (ppc64v2_emit_reg): New function.
3846 (ppc64_emit_pop): New function.
3847 (ppc64_emit_stack_flush): New function.
3848 (ppc64_emit_swap): New function.
3849 (ppc64v1_emit_call): New function.
3850 (ppc64v2_emit_call): New function.
3851 (ppc64v1_emit_int_call_1): New function.
3852 (ppc64v2_emit_int_call_1): New function.
3853 (ppc64v1_emit_void_call_2): New function.
3854 (ppc64v2_emit_void_call_2): New function.
3855 (ppc64_emit_if_goto): New function.
3856 (ppc64_emit_eq_goto): New function.
3857 (ppc64_emit_ne_goto): New function.
3858 (ppc64_emit_lt_goto): New function.
3859 (ppc64_emit_le_goto): New function.
3860 (ppc64_emit_gt_goto): New function.
3861 (ppc64_emit_ge_goto): New function.
3862 (ppc64v1_emit_ops_impl): New static variable.
3863 (ppc64v2_emit_ops_impl): New static variable.
3864 (ppc_emit_ops): New function.
3865 (linux_low_target): Wire in ppc_emit_ops.
3866
3867 2016-03-31 Wei-cheng Wang <cole945@gmail.com>
3868 Marcin Kościelnicki <koriakin@0x04.net>
3869
3870 PR/17221
3871 * Makefile.in: Add powerpc-*-ipa.o
3872 * configure.srv: Add ipa_obj for powerpc*-linux.
3873 * linux-ppc-ipa.c: New file.
3874 * linux-ppc-low.c: Added linux-ppc-tdesc.h, ax.h, tracepoint.h
3875 includes.
3876 (PPC_FIELD): New macro.
3877 (PPC_SEXT): New macro.
3878 (PPC_OP6): New macro.
3879 (PPC_BO): New macro.
3880 (PPC_LI): New macro.
3881 (PPC_BD): New macro.
3882 (init_registers_*): Move prototype to linux-ppc-tdesc.h.
3883 (tdesc_*): Move declaration to linux-ppc-tdesc.h.
3884 (ppc_get_hwcap): Rename to ppc_get_auxv and add type parameter.
3885 (ppc_get_thread_area): New function.
3886 (is_elfv2_inferior): New function.
3887 (gen_ds_form): New function.
3888 (GEN_STD): New macro.
3889 (GEN_STDU): New macro.
3890 (GEN_LD): New macro.
3891 (GEN_LDU): New macro.
3892 (gen_d_form): New function.
3893 (GEN_ADDI): New macro.
3894 (GEN_ADDIS): New macro.
3895 (GEN_LI): New macro.
3896 (GEN_LIS): New macro.
3897 (GEN_ORI): New macro.
3898 (GEN_ORIS): New macro.
3899 (GEN_LWZ): New macro.
3900 (GEN_STW): New macro.
3901 (GEN_STWU): New macro.
3902 (gen_xfx_form): New function.
3903 (GEN_MFSPR): New macro.
3904 (GEN_MTSPR): New macro.
3905 (GEN_MFCR): New macro.
3906 (GEN_MTCR): New macro.
3907 (GEN_SYNC): New macro.
3908 (GEN_LWSYNC): New macro.
3909 (gen_x_form): New function.
3910 (GEN_OR): New macro.
3911 (GEN_MR): New macro.
3912 (GEN_LWARX): New macro.
3913 (GEN_STWCX): New macro.
3914 (GEN_CMPW): New macro.
3915 (gen_md_form): New function.
3916 (GEN_RLDICL): New macro.
3917 (GEN_RLDICR): New macro.
3918 (gen_i_form): New function.
3919 (GEN_B): New macro.
3920 (GEN_BL): New macro.
3921 (gen_b_form): New function.
3922 (GEN_BNE): New macro.
3923 (GEN_LOAD): New macro.
3924 (GEN_STORE): New macro.
3925 (gen_limm): New function.
3926 (gen_atomic_xchg): New function.
3927 (gen_call): New function.
3928 (ppc_relocate_instruction): New function.
3929 (ppc_install_fast_tracepoint_jump_pad): New function.
3930 (ppc_get_min_fast_tracepoint_insn_len): New function.
3931 (ppc_get_ipa_tdesc_idx): New function.
3932 (the_low_target): Wire in the new functions.
3933 (initialize_low_arch) [!__powerpc64__]: Don'it initialize 64-bit
3934 tdescs.
3935 * linux-ppc-tdesc.h: New file.
3936
3937 2016-03-31 Marcin Kościelnicki <koriakin@0x04.net>
3938
3939 * linux-aarch64-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3940 (alloc_jump_pad_buffer): New function.
3941 * linux-amd64-ipa.c: Add <sys/mman.h> include.
3942 (alloc_jump_pad_buffer): New function.
3943 * linux-i386-ipa.c (alloc_jump_pad_buffer): New function.
3944 * linux-s390-ipa.c: Add <sys/mman.h> and <sys/auxv.h> includes.
3945 (alloc_jump_pad_buffer): New function.
3946 * tracepoint.c (getauxval) [!HAVE_GETAUXVAL]: New function.
3947 (initialize_tracepoint): Delegate to alloc_jump_pad_buffer.
3948 * tracepoint.h (alloc_jump_pad_buffer): New prototype.
3949 (getauxval) [!HAVE_GETAUXVAL]: New prototype.
3950
3951 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3952
3953 * linux-aarch64-ipa.c: Rename gdb_agent_get_raw_reg to get_raw_reg.
3954 * linux-amd64-ipa.c: Likewise.
3955 * linux-i386-ipa.c: Likewise.
3956 * linux-s390-ipa.c: Likewise.
3957 * tracepoint.c: IPA-export gdb_collect_ptr instead of gdb_collect,
3958 ditto for get_raw_reg_ptr, get_trace_state_variable_value_ptr,
3959 set_trace_state_variable_value_ptr.
3960 (struct ipa_sym_addresses): Likewise.
3961 (symbol_list): Likewise.
3962 (install_fast_tracepoint): Dereference gdb_collect_ptr instead of
3963 accessing gdb_collect directly.
3964 (gdb_collect_ptr_type): New typedef.
3965 (get_raw_reg_ptr_type): New typedef.
3966 (get_trace_state_variable_value_ptr_type): New typedef.
3967 (set_trace_state_variable_value_ptr_type): New typedef.
3968 (gdb_collect_ptr): New global.
3969 (get_raw_reg_ptr): New global.
3970 (get_trace_state_variable_value_ptr): New global.
3971 (set_trace_state_variable_value_ptr): New global.
3972 (get_raw_reg_func_addr): Dereference get_raw_reg_ptr instead of
3973 accessing get_raw_reg directly.
3974 (get_get_tsv_func_addr): Likewise for
3975 get_trace_state_variable_value_ptr.
3976 (get_set_tsv_func_addr): Likewise for
3977 set_trace_state_variable_value_ptr.
3978 * tracepoint.h: Rename gdb_agent_get_raw_reg to get_raw_reg.
3979
3980 2016-03-30 Simon Marchi <simon.marchi@ericsson.com>
3981
3982 * tracepoint.c (cmd_qtenable_disable): Remove whitespace.
3983
3984 2016-03-30 Marcin Kościelnicki <koriakin@0x04.net>
3985
3986 * remote-utils.c (look_up_one_symbol): Remove own_buf, handle 'v'
3987 packets.
3988 (relocate_instruction): Remove own_buf.
3989 * server.c (own_buf): Make global.
3990 (handle_v_requests): Make global.
3991 * server.h (own_buf): New declaration.
3992 (handle_v_requests): New prototype.
3993
3994 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
3995
3996 PR 18377
3997 * linux-s390-low.c (add_insns): New function.
3998 (s390_emit_prologue): New function.
3999 (s390_emit_epilogue): New function.
4000 (s390_emit_add): New function.
4001 (s390_emit_sub): New function.
4002 (s390_emit_mul): New function.
4003 (s390_emit_lsh): New function.
4004 (s390_emit_rsh_signed): New function.
4005 (s390_emit_rsh_unsigned): New function.
4006 (s390_emit_ext): New function.
4007 (s390_emit_log_not): New function.
4008 (s390_emit_bit_and): New function.
4009 (s390_emit_bit_or): New function.
4010 (s390_emit_bit_xor): New function.
4011 (s390_emit_bit_not): New function.
4012 (s390_emit_equal): New function.
4013 (s390_emit_less_signed): New function.
4014 (s390_emit_less_unsigned): New function.
4015 (s390_emit_ref): New function.
4016 (s390_emit_if_goto): New function.
4017 (s390_emit_goto): New function.
4018 (s390_write_goto_address): New function.
4019 (s390_emit_litpool): New function.
4020 (s390_emit_const): New function.
4021 (s390_emit_call): New function.
4022 (s390_emit_reg): New function.
4023 (s390_emit_pop): New function.
4024 (s390_emit_stack_flush): New function.
4025 (s390_emit_zero_ext): New function.
4026 (s390_emit_swap): New function.
4027 (s390_emit_stack_adjust): New function.
4028 (s390_emit_set_r2): New function.
4029 (s390_emit_int_call_1): New function.
4030 (s390_emit_void_call_2): New function.
4031 (s390_emit_eq_goto): New function.
4032 (s390_emit_ne_goto): New function.
4033 (s390_emit_lt_goto): New function.
4034 (s390_emit_le_goto): New function.
4035 (s390_emit_gt_goto): New function.
4036 (s390_emit_ge_goto): New function.
4037 (s390x_emit_prologue): New function.
4038 (s390x_emit_epilogue): New function.
4039 (s390x_emit_add): New function.
4040 (s390x_emit_sub): New function.
4041 (s390x_emit_mul): New function.
4042 (s390x_emit_lsh): New function.
4043 (s390x_emit_rsh_signed): New function.
4044 (s390x_emit_rsh_unsigned): New function.
4045 (s390x_emit_ext): New function.
4046 (s390x_emit_log_not): New function.
4047 (s390x_emit_bit_and): New function.
4048 (s390x_emit_bit_or): New function.
4049 (s390x_emit_bit_xor): New function.
4050 (s390x_emit_bit_not): New function.
4051 (s390x_emit_equal): New function.
4052 (s390x_emit_less_signed): New function.
4053 (s390x_emit_less_unsigned): New function.
4054 (s390x_emit_ref): New function.
4055 (s390x_emit_if_goto): New function.
4056 (s390x_emit_const): New function.
4057 (s390x_emit_call): New function.
4058 (s390x_emit_reg): New function.
4059 (s390x_emit_pop): New function.
4060 (s390x_emit_stack_flush): New function.
4061 (s390x_emit_zero_ext): New function.
4062 (s390x_emit_swap): New function.
4063 (s390x_emit_stack_adjust): New function.
4064 (s390x_emit_int_call_1): New function.
4065 (s390x_emit_void_call_2): New function.
4066 (s390x_emit_eq_goto): New function.
4067 (s390x_emit_ne_goto): New function.
4068 (s390x_emit_lt_goto): New function.
4069 (s390x_emit_le_goto): New function.
4070 (s390x_emit_gt_goto): New function.
4071 (s390x_emit_ge_goto): New function.
4072 (s390_emit_ops): New function.
4073 (struct linux_target_ops): Fill in emit_ops hook.
4074
4075 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4076
4077 PR 18377
4078 * Makefile.in: Add s390 IPA files.
4079 * configure.srv: Build IPA for s390.
4080 * linux-s390-ipa.c: New file.
4081 * linux-s390-low.c: New includes - inttypes.h and linux-s390-tdesc.h.
4082 (init_registers_s390_linux32): Move declaration to linux-s390-tdesc.h.
4083 (tdesc_s390_linux32): Likewise.
4084 (init_registers_s390_linux32v1): Likewise.
4085 (tdesc_s390_linux32v1): Likewise.
4086 (init_registers_s390_linux32v2): Likewise.
4087 (tdesc_s390_linux32v2): Likewise.
4088 (init_registers_s390_linux64): Likewise.
4089 (tdesc_s390_linux64): Likewise.
4090 (init_registers_s390_linux64v1): Likewise.
4091 (tdesc_s390_linux64v1): Likewise.
4092 (init_registers_s390_linux64v2): Likewise.
4093 (tdesc_s390_linux64v2): Likewise.
4094 (init_registers_s390_te_linux64): Likewise.
4095 (tdesc_s390_te_linux64): Likewise.
4096 (init_registers_s390_vx_linux64): Likewise.
4097 (tdesc_s390_vx_linux64): Likewise.
4098 (init_registers_s390_tevx_linux64): Likewise.
4099 (tdesc_s390_tevx_linux64): Likewise.
4100 (init_registers_s390x_linux64): Likewise.
4101 (tdesc_s390x_linux64): Likewise.
4102 (init_registers_s390x_linux64v1): Likewise.
4103 (tdesc_s390x_linux64v1): Likewise.
4104 (init_registers_s390x_linux64v2): Likewise.
4105 (tdesc_s390x_linux64v2): Likewise.
4106 (init_registers_s390x_te_linux64): Likewise.
4107 (tdesc_s390x_te_linux64): Likewise.
4108 (init_registers_s390x_vx_linux64): Likewise.
4109 (tdesc_s390x_vx_linux64): Likewise.
4110 (init_registers_s390x_tevx_linux64): Likewise.
4111 (tdesc_s390x_tevx_linux64): Likewise.
4112 (have_hwcap_s390_vx): New static variable.
4113 (s390_arch_setup): Fill have_hwcap_s390_vx.
4114 (s390_get_thread_area): New function.
4115 (s390_ft_entry_gpr_esa): New const.
4116 (s390_ft_entry_gpr_zarch): New const.
4117 (s390_ft_entry_misc): New const.
4118 (s390_ft_entry_fr): New const.
4119 (s390_ft_entry_vr): New const.
4120 (s390_ft_main_31): New const.
4121 (s390_ft_main_64): New const.
4122 (s390_ft_exit_fr): New const.
4123 (s390_ft_exit_vr): New const.
4124 (s390_ft_exit_misc): New const.
4125 (s390_ft_exit_gpr_esa): New const.
4126 (s390_ft_exit_gpr_zarch): New const.
4127 (append_insns): New function.
4128 (s390_relocate_instruction): New function.
4129 (s390_install_fast_tracepoint_jump_pad): New function.
4130 (s390_get_min_fast_tracepoint_insn_len): New function.
4131 (s390_get_ipa_tdesc_idx): New function.
4132 (struct linux_target_ops): Wire in the above functions.
4133 (initialize_low_arch) [!__s390x__]: Don't initialize s390x tdescs.
4134 * linux-s390-tdesc.h: New file.
4135
4136 2016-03-29 Marcin Kościelnicki <koriakin@0x04.net>
4137
4138 * linux-s390-low.c (s390_supports_tracepoints): New function.
4139 (struct linux_target_ops): Fill supports_tracepoints hook.
4140
4141 2016-03-18 Yao Qi <yao.qi@linaro.org>
4142
4143 * linux-low.c (lwp_signal_can_be_delivered): New function.
4144 (linux_resume_one_lwp_throw): Use lwp_signal_can_be_delivered.
4145
4146 2016-03-18 Yao Qi <yao.qi@linaro.org>
4147
4148 * linux-low.c (linux_resume_one_lwp_throw): Set 'signal' to
4149 0 if signal is enqueued. Remove 'signal' from one debugging
4150 message. Move one debugging message to some lines below.
4151 Remove code setting 'signal' to 0.
4152
4153 2016-03-18 Yao Qi <yao.qi@linaro.org>
4154
4155 * linux-low.c (linux_low_filter_event): Remove redundant
4156 WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
4157
4158 2016-03-09 Marcin Kościelnicki <koriakin@0x04.net>
4159
4160 * linux-ppc-low.c (ppc_supports_tracepoints): New function.
4161 (struct linux_target_ops): Wire in the above.
4162
4163 2016-03-03 Yao Qi <yao.qi@linaro.org>
4164
4165 * linux-low.c: Update comments to start_step_over.
4166
4167 2016-03-03 Yao Qi <yao.qi@linaro.org>
4168
4169 PR server/19736
4170 * linux-low.c (handle_extended_wait): Set child suspended
4171 if event_lwp->bp_reinsert isn't zero.
4172
4173 2016-03-02 Yao Qi <yao.qi@linaro.org>
4174
4175 * linux-low.c (linux_resume_one_lwp_throw): Replace code with
4176 enqueue_pending_signal.
4177
4178 2016-03-02 Marcin Kościelnicki <koriakin@0x04.net>
4179
4180 * tracepoint.c (cmd_qtstart): Only set ipa_tdesc_idx if agent
4181 is actually loaded.
4182
4183 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4184
4185 * linux-s390-low.c (s390_num_regs_3264): Define on 31-bit too.
4186 (s390_regmap_3264) [!__s390x__]: New global.
4187 (s390_collect_ptrace_register): Skip map entries containing -1.
4188 (s390_supply_ptrace_register): Ditto.
4189 (s390_fill_gprs_high): New function.
4190 (s390_store_gprs_high): New function.
4191 (s390_regsets): Add NT_S390_HIGH_GPRS.
4192 (s390_get_hwcap): Enable on 31-bit.
4193 (have_hwcap_s390_high_gprs): Enable on 31-bit.
4194 (s390_arch_setup): Enable detection of high GPRs, TDB, VX on 31-bit.
4195 Detect NT_S390_HIGH_GPRS.
4196 (s390_usrregs_info_3264): Enable on 31-bit.
4197 (s390_regs_info): Enable regs_info_3264 on 31-bit.
4198 (initialize_low_arch): Initialize s390_regsets_info_3264 on 31-bit.
4199
4200 2016-02-25 Marcin Kościelnicki <koriakin@0x04.net>
4201
4202 PR gdb/13808
4203 * Makefile.in: Add i386-*-linux-ipa.o and amd64-*-linux-ipa.o.
4204 * configure.srv: Ditto.
4205 * linux-aarch64-ipa.c (get_ipa_tdesc): New function.
4206 (initialize_low_tracepoint): Remove ipa_tdesc assignment.
4207 * linux-amd64-ipa.c: Add "linux-x86-tdesc.h" include.
4208 (init_registers_amd64_linux): Remove prototype.
4209 (tdesc_amd64_linux): Remove declaration.
4210 (get_ipa_tdesc): New function.
4211 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4212 initialize remaining tdescs.
4213 * linux-i386-ipa.c: Add "linux-x86-tdesc.h" include.
4214 (init_registers_i386_linux): Remove prototype.
4215 (tdesc_i386_linux): Remove declaration.
4216 (get_ipa_tdesc): New function.
4217 (initialize_low_tracepoint): Remove ipa_tdesc assignment,
4218 initialize remaining tdescs.
4219 * linux-low.c (linux_get_ipa_tdesc_idx): New function.
4220 (linux_target_ops): wire in linux_get_ipa_tdesc_idx.
4221 * linux-low.h (struct linux_target_ops): Add get_ipa_tdesc_idx.
4222 * linux-x86-low.c: Move tdesc declarations to linux-x86-tdesc.h.
4223 (x86_get_ipa_tdesc_idx): New function.
4224 (the_low_target): Wire in x86_get_ipa_tdesc_idx.
4225 * linux-x86-tdesc.h: New file.
4226 * target.h (struct target_ops): Add get_ipa_tdesc_idx.
4227 (target_get_ipa_tdesc_idx): New macro.
4228 * tracepoint.c (ipa_tdesc_idx): New macro.
4229 (struct ipa_sym_addresses): Add addr_ipa_tdesc_idx.
4230 (symbol_list): Add ipa_tdesc_idx.
4231 (cmd_qtstart): Write ipa_tdesc_idx in the target.
4232 (ipa_tdesc): Remove.
4233 (ipa_tdesc_idx): New variable.
4234 (get_context_regcache): Use get_ipa_tdesc.
4235 (gdb_collect): Ditto.
4236 (gdb_probe): Ditto.
4237 * tracepoint.h (get_ipa_tdesc): New prototype.
4238 (ipa_tdesc): Remove.
4239
4240 2016-02-24 Pedro Alves <palves@redhat.com>
4241
4242 * linux-low.c (check_stopped_by_breakpoint): Rename to ...
4243 (save_stop_reason): ... this. Use GDB_ARCH_IS_TRAP_HWBKPT and
4244 handle ambiguous GDB_ARCH_IS_TRAP_BRKPT / GDB_ARCH_IS_TRAP_HWBKPT.
4245 Factor out common code between the USE_SIGTRAP_SIGINFO and
4246 !USE_SIGTRAP_SIGINFO blocks.
4247 (linux_low_filter_event): Call save_stop_reason instead of
4248 check_stopped_by_breakpoint and check_stopped_by_watchpoint.
4249 Update comments.
4250 (linux_wait_1): Update comments.
4251
4252 2016-02-24 Wei-cheng Wang <cole945@gmail.com>
4253
4254 * linux-ppc-low.c (ppc_supports_z_point_type): New function:
4255 (ppc_insert_point, ppc_remove_point): Insert/remove z-packet breakpoints.
4256 (ppc64_emit_ops_vector): Add target ops - ppc_supports_z_point_type,
4257 ppc_insert_point, ppc_remove_point.
4258
4259 2016-02-17 Marcin Kościelnicki <koriakin@0x04.net>
4260
4261 * linux-s390-low.c (s390_supports_z_point_type): New function.
4262 (struct linux_target_ops): Wire s390_supports_z_point_type in.
4263
4264 2016-02-16 Yao Qi <yao.qi@linaro.org>
4265
4266 * linux-arm-low.c (get_next_pcs_syscall_next_pc): Remove argument
4267 PC. Get pc from regcache_read_pc.
4268
4269 2016-02-12 Yao Qi <yao.qi@linaro.org>
4270
4271 * linux-aarch64-low.c (aarch64_get_pc): Call linux_get_pc_64bit
4272 or linux_get_pc_32bit.
4273 (aarch64_set_pc): Call linux_set_pc_64bit or linux_set_pc_32bit.
4274
4275 2016-02-12 Yao Qi <yao.qi@linaro.org>
4276
4277 * linux-arm-low.c (get_next_pcs_ops): Initialize it with
4278 arm_linux_get_next_pcs_fixup.
4279
4280 2016-02-12 Marcin Kościelnicki <koriakin@0x04.net>
4281
4282 * tracepoint.c (x_tracepoint_action_download): Change
4283 write_inferior_data_ptr to write_inferior_data_pointer.
4284 (cmd_qtstart): Likewise.
4285 (write_inferior_data_ptr): Remove.
4286 (download_agent_expr): Change write_inferior_data_ptr to
4287 write_inferior_data_pointer.
4288 (download_tracepoint_1): Likewise.
4289 (download_tracepoint): Likewise.
4290 (download_trace_state_variables): Likewise.
4291
4292 2016-02-11 Wei-cheng Wang <cole945@gmail.com>
4293 Marcin Kościelnicki <koriakin@0x04.net>
4294
4295 * tracepoint.c (struct tracepoint_action_ops): Remove.
4296 (struct tracepoint_action): Remove ops.
4297 (m_tracepoint_action_download, r_tracepoint_action_download)
4298 (x_tracepoint_action_download, l_tracepoint_action_download): Adjust
4299 size and offset accordingly.
4300 (m_tracepoint_action_ops, r_tracepoint_action_ops)
4301 (x_tracepoint_action_ops, l_tracepoint_action_ops): Remove.
4302 (tracepoint_action_send, tracepoint_action_download): New functions.
4303 Helpers for trace action handlers.
4304 (add_tracepoint_action): Remove setup actions ops.
4305 (download_tracepoint_1, tracepoint_send_agent): Call helper functions.
4306
4307 2016-02-10 Yao Qi <yao.qi@linaro.org>
4308
4309 * regcache.c (regcache_raw_read_unsigned): Clear *VAL.
4310
4311 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4312
4313 * configure.ac: Use AC_CONFIG_FILES instead of passing arguments
4314 to AC_OUTPUT.
4315 * configure: Regenerate.
4316
4317 2016-02-09 Simon Marchi <simon.marchi@ericsson.com>
4318
4319 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): Change
4320 void * to gdb_byte *.
4321 * linux-low.c (siginfo_fixup): Likewise.
4322 (linux_xfer_siginfo): Likewise.
4323 * linux-low.h (struct linux_target_ops) <siginfo_fixup>:
4324 Likewise.
4325 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
4326
4327 2016-02-02 Walfred Tedeschi <walfred.tedeschi@intel.com>
4328
4329 * configure.srv (x86_64-*-linux*): Add amd64-linux-siginfo.o
4330 to srv_tgtobj.
4331 (i[34567]86-*-linux*): Add amd64-linux-siginfo.o
4332 to srv_tgtobj.
4333 * linux-x86-low.c [__x86_64__]: Include
4334 "nat/amd64-linux-siginfo.h".
4335 (compat_siginfo_from_siginfo, siginfo_from_compat_siginfo)
4336 (compat_x32_siginfo_from_siginfo, siginfo_from_compat_x32_siginfo)
4337 (compat_timeval, compat_sigval, compat_x32_clock, cpt_si_pid)
4338 (cpt_si_uid, cpt_si_timerid, cpt_si_overrun, cpt_si_status)
4339 (cpt_si_utime, cpt_si_stime, cpt_si_ptr, cpt_si_addr, cpt_si_band)
4340 (cpt_si_fd, si_timerid, si_overrun): Move from
4341 nat/amd64-linux-siginfo.c.
4342 * Makefile.in (amd64-linux-siginfo.o:): New rule.
4343
4344 2016-01-28 Simon Marchi <simon.marchi@ericsson.com>
4345
4346 * server.c (skip_to_semicolon): Remove.
4347 (process_point_options): Use strchrnul instead of
4348 skip_to_semicolon.
4349
4350 2016-01-26 Yao Qi <yao.qi@linaro.org>
4351
4352 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Remove argument pc.
4353 * linux-low.c (install_software_single_step_breakpoints): Don't
4354 call regcache_read_pc.
4355 * linux-low.h (struct linux_target_ops) <get_next_pcs>: Remove
4356 argument pc.
4357
4358 2016-01-26 Yao Qi <yao.qi@linaro.org>
4359
4360 * linux-low.c (install_software_single_step_breakpoints): Call
4361 regcache_read_pc instead of get_pc.
4362
4363 2016-01-26 Yao Qi <yao.qi@linaro.org>
4364
4365 * remote-utils.c (remote_close) [!USE_WIN32API]: Ignore SIGIO.
4366 (unblock_async_io): Rename to ...
4367 (block_unblock_async_io): ... it. New function.
4368 (enable_async_io): Don't install SIGIO handler. Unblock it
4369 instead.
4370 (disable_async_io): Don't ignore SIGIO. Block it instead.
4371 (initialize_async_io): Install SIGIO handler. Don't call
4372 unblock_async_io.
4373
4374 2016-01-26 Yao Qi <yao.qi@linaro.org>
4375
4376 * remote-utils.c (getpkt): If the buffer isn't empty, and the
4377 first character is '\003', call *the_target->request_interrupt.
4378
4379 2016-01-25 Yao Qi <yao.qi@linaro.org>
4380
4381 * remote-utils.c (new_thread_notify): Remove.
4382 (dead_thread_notify): Likewise.
4383 * remote-utils.h (new_thread_notify): Remove declaration.
4384 (dead_thread_notify): Likewise.
4385
4386 2016-01-23 Marcin Kościelnicki <koriakin@0x04.net>
4387
4388 * gdb.trace/pending.exp: Fix expected message on continue.
4389
4390 2016-01-22 Marcin Kościelnicki <koriakin@0x04.net>
4391
4392 * tracepoint.c (write_inferior_data_ptr): Cast to uintptr_t, so that
4393 it works properly on big-endian machines where sizeof (CORE_ADDR)
4394 != sizeof (void *).
4395
4396 2016-01-21 Pedro Alves <palves@redhat.com>
4397
4398 * Makefile.in (COMPILER_CFLAGS, CXXFLAGS): New.
4399 (INTERNAL_CFLAGS_BASE): Use COMPILER_CFLAGS instead of CFLAGS.
4400 * configure: Regenerate.
4401
4402 2016-01-21 Yao Qi <yao.qi@linaro.org>
4403
4404 * linux-arm-low.c (arm_sigreturn_next_pc): Add parameter
4405 is_thumb and set it according to CPSR saved on the stack.
4406 (get_next_pcs_syscall_next_pc): Pass is_thumb to
4407 arm_sigreturn_next_pc.
4408
4409 2016-01-18 Yao Qi <yao.qi@linaro.org>
4410
4411 * linux-low.c (linux_set_pc_64bit): New function.
4412 (linux_get_pc_64bit): New function.
4413 * linux-low.h (linux_set_pc_64bit, linux_get_pc_64bit):
4414 Declare.
4415 * linux-sparc-low.c (debug_threads): Remove declaration.
4416 (sparc_get_pc): Remove.
4417 (the_low_target): Use linux_get_pc_64bit instead of
4418 sparc_get_pc.
4419 * linux-tile-low.c (tile_get_pc, tile_set_pc): Remove.
4420 (the_low_target): Use linux_get_pc_64bit and
4421 linux_set_pc_64bit.
4422
4423 2016-01-18 Yao Qi <yao.qi@linaro.org>
4424
4425 * linux-arm-low.c (debug_threads): Remove declaration.
4426 (arm_get_pc, arm_set_pc): Remove.
4427 (the_low_target): Use linux_get_pc_32bit and
4428 linux_set_pc_32bit.
4429 * linux-bfin-low.c (bfin_get_pc, bfin_set_pc): Remove.
4430 (the_low_target): Use linux_get_pc_32bit and
4431 linux_set_pc_32bit.
4432 * linux-cris-low.c (debug_threads): Remove declaration.
4433 (cris_get_pc, cris_set_pc,): Remove.
4434 (the_low_target): Use linux_get_pc_32bit and
4435 linux_set_pc_32bit.
4436 * linux-crisv32-low.c (debug_threads): Remove declaration.
4437 (cris_get_pc, cris_set_pc): Remove.
4438 (the_low_target): Use linux_get_pc_32bit and
4439 linux_set_pc_32bit.
4440 * linux-low.c: Include inttypes.h.
4441 (linux_get_pc_32bit, linux_set_pc_32bit): New functions.
4442 * linux-low.h (linux_get_pc_32bit, linux_set_pc_32bit): Declare.
4443 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Remove.
4444 (the_low_target): Use linux_get_pc_32bit and
4445 linux_set_pc_32bit.
4446 * linux-m68k-low.c (m68k_get_pc, m68k_set_pc): Remove.
4447 (the_low_target): Use linux_get_pc_32bit and
4448 linux_set_pc_32bit.
4449 * linux-nios2-low.c (nios2_get_pc, nios2_set_pc): Remove.
4450 (the_low_target): Use linux_get_pc_32bit and
4451 linux_set_pc_32bit.
4452 * linux-sh-low.c (sh_get_pc, sh_set_pc): Remove.
4453 (the_low_target): Use linux_get_pc_32bit and
4454 linux_set_pc_32bit.
4455 * linux-xtensa-low.c (xtensa_get_pc, xtensa_set_pc): Remove.
4456 (the_low_target): Use linux_get_pc_32bit and
4457 linux_set_pc_32bit.
4458
4459 2016-01-18 Gary Benson <gbenson@redhat.com>
4460
4461 * configure.ac (AC_FUNC_FORK): New check.
4462 * config.in: Regenerate.
4463 * configure: Likewise.
4464
4465 2016-01-14 Yao Qi <yao.qi@linaro.org>
4466
4467 * linux-aarch32-low.c (thumb2_breakpoint): Make it static.
4468 * linux-aarch32-low.h (thumb2_breakpoint): Remove declaration.
4469 * linux-arm-low.c (arm_gdbserver_get_next_pcs): Pass 1 to
4470 arm_get_next_pcs_ctor.
4471
4472 2016-01-12 Josh Stone <jistone@redhat.com>
4473 Philippe Waroquiers <philippe.waroquiers@skynet.be>
4474
4475 * inferiors.h: Include "gdb_vecs.h".
4476 (struct process_info): Add syscalls_to_catch.
4477 * inferiors.c (remove_process): Free syscalls_to_catch.
4478 * remote-utils.c (prepare_resume_reply): Report syscall_entry and
4479 syscall_return stops.
4480 * server.h (UNKNOWN_SYSCALL, ANY_SYSCALL): Define.
4481 * server.c (handle_general_set): Handle QCatchSyscalls.
4482 (handle_query): Report support for QCatchSyscalls.
4483 * target.h (struct target_ops): Add supports_catch_syscall.
4484 (target_supports_catch_syscall): New macro.
4485 * linux-low.h (struct linux_target_ops): Add get_syscall_trapinfo.
4486 (struct lwp_info): Add syscall_state.
4487 * linux-low.c (handle_extended_wait): Mark syscall_state as an entry.
4488 Maintain syscall_state and syscalls_to_catch across exec.
4489 (get_syscall_trapinfo): New function, proxy to the_low_target.
4490 (linux_low_ptrace_options): Enable PTRACE_O_TRACESYSGOOD.
4491 (linux_low_filter_event): Toggle syscall_state entry/return for
4492 syscall traps, and set it ignored for all others.
4493 (gdb_catching_syscalls_p): New function.
4494 (gdb_catch_this_syscall_p): New function.
4495 (linux_wait_1): Handle SYSCALL_SIGTRAP.
4496 (linux_resume_one_lwp_throw): Add PTRACE_SYSCALL possibility.
4497 (linux_supports_catch_syscall): New function.
4498 (linux_target_ops): Install it.
4499 * linux-x86-low.c (x86_get_syscall_trapinfo): New function.
4500 (the_low_target): Install it.
4501
4502 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4503
4504 * acinclude.m4: Include new ../warning.m4 file.
4505 * configure: Regenerated.
4506 * configure.ac: Replace all warning logic with AM_GDB_WARNINGS.
4507
4508 2016-01-12 Mike Frysinger <vapier@gentoo.org>
4509
4510 * ax.c (is_goto_target): Mark static.
4511 * linux-low.c (register_addr): Likewise.
4512 (linux_fetch_registers, linux_store_registers): Likewise.
4513 * mem-break.c (any_persistent_commands): Fix old prototype.
4514 (add_commands_to_breakpoint): Mark static.
4515 * regcache.c (find_register_by_name): Delete unused func.
4516 * remote-utils.c (hex_or_minus_one): Mark static.
4517 * server.c (monitor_show_help): Mark static.
4518 (handle_query, handle_v_cont, handle_v_attach, handle_v_kill,
4519 handle_v_requests): Likewise.
4520
4521 2016-01-12 Pedro Alves <palves@redhat.com>
4522
4523 Remove use of the registered trademark symbol throughout.
4524
4525 2016-01-08 Yao Qi <yao.qi@linaro.org>
4526
4527 * remote-utils.c (getpkt): If c is '\003', call target hook
4528 request_interrupt.
4529
4530 2016-01-06 Yao Qi <yao.qi@linaro.org>
4531
4532 * linux-aarch32-low.h (arm_abi_breakpoint): Move to
4533 linux-aarch32-low.c.
4534 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4535 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4536 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4537 (thumb2_breakpoint): Declare.
4538 * linux-aarch32-low.c (arm_abi_breakpoint): Moved from
4539 linux-aarch32-low.h.
4540 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4541 (arm_breakpoint_len, thumb_breakpoint_len): Likewise.
4542 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4543
4544 2016-01-01 Joel Brobecker <brobecker@adacore.com>
4545
4546 * gdbreplay.c (gdbreplay_version): Change copyright year in
4547 version message.
4548 * server.c (gdbserver_version): Likewise.
4549
4550 2015-12-28 Patrick Palka <patrick@parcs.ath.cx>
4551
4552 * server.c (crc32_table): Delete.
4553 (crc32): Use libiberty's xcrc32 function.
4554
4555 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4556
4557 * lynx-low.c (lynx_delete_thread_callback): New function.
4558 (lynx_mourn): Properly delete our process and all of its
4559 threads. Remove call to clear_inferiors.
4560
4561 2015-12-22 Joel Brobecker <brobecker@adacore.com>
4562
4563 * target.c (thread_search_callback): Add check that
4564 the thread_stopped target callback is not NULL before
4565 calling it.
4566
4567 2015-12-21 Yao Qi <yao.qi@linaro.org>
4568
4569 * linux-aarch32-low.h [__aarch64__]: Use arm_abi_breakpoint
4570 arm breakpoint.
4571
4572 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4573
4574 * server.c (handle_query): Call target_supports_software_single_step.
4575
4576 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4577
4578 * linux-low.c (single_step): New function.
4579 (linux_resume_one_lwp_throw): Call single_step.
4580 (start_step_over): Likewise.
4581
4582 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4583
4584 * Makefile.in (SFILES): Append arch/arm-linux.c,
4585 arch/arm-get-next-pcs.c.
4586 (arm-linux.o): New rule.
4587 (arm-get-next-pcs.o): New rule.
4588 * configure.srv (arm*-*-linux*): Add arm-get-next-pcs.o,
4589 arm-linux.o.
4590 * linux-aarch32-low.c (arm_abi_breakpoint): Remove macro. Moved
4591 to linux-aarch32-low.c.
4592 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4593 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4594 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4595 (thumb2_breakpoint_len): Likewise.
4596 (arm_is_thumb_mode): Make non-static.
4597 * linux-aarch32-low.h (arm_abi_breakpoint): New macro. Moved
4598 from linux-aarch32-low.c.
4599 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4600 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4601 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4602 (thumb2_breakpoint_len): Likewise.
4603 (arm_is_thumb_mode): New declaration.
4604 * linux-arm-low.c: Include arch/arm-linux.h
4605 aarch/arm-get-next-pcs.h, sys/syscall.h.
4606 (get_next_pcs_ops): New struct.
4607 (get_next_pcs_addr_bits_remove): New function.
4608 (get_next_pcs_is_thumb): New function.
4609 (get_next_pcs_read_memory_unsigned_integer): Likewise.
4610 (arm_sigreturn_next_pc): Likewise.
4611 (get_next_pcs_syscall_next_pc): Likewise.
4612 (arm_gdbserver_get_next_pcs): Likewise.
4613 (struct linux_target_ops) <arm_gdbserver_get_next_pcs>:
4614 Initialize.
4615 * linux-low.h: Move CORE_ADDR vector definition to gdb_vecs.h.
4616 * server.h: Include gdb_vecs.h.
4617
4618 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4619
4620 * Makefile.in (SFILES): Append common/common-regcache.c.
4621 (OBS): Append common-regcache.o.
4622 (common-regcache.o): New rule.
4623 * regcache.c (init_register_cache): Initialize cache to
4624 REG_UNAVAILABLE.
4625 (regcache_raw_read_unsigned): New function.
4626 * regcache.h (REG_UNAVAILABLE, REG_VALID): Replaced by shared
4627 register_status enum.
4628
4629 2015-12-18 Antoine Tremblay <antoine.tremblay@ericsson.com>
4630
4631 * linux-aarch64-low.c (the_low_targets): Rename
4632 breakpoint_reinsert_addr to get_next_pcs.
4633 * linux-arm-low.c (the_low_targets): Likewise.
4634 * linux-bfin-low.c (the_low_targets): Likewise.
4635 * linux-cris-low.c (the_low_targets): Likewise.
4636 * linux-crisv32-low.c (the_low_targets): Likewise.
4637 * linux-low.c (can_software_single_step): Likewise.
4638 (install_software_single_step_breakpoints): New function.
4639 (start_step_over): Use install_software_single_step_breakpoints.
4640 * linux-low.h: New CORE_ADDR vector.
4641 (struct linux_target_ops) Rename breakpoint_reinsert_addr to
4642 get_next_pcs.
4643 * linux-mips-low.c (the_low_targets): Likewise.
4644 * linux-nios2-low.c (the_low_targets): Likewise.
4645 * linux-sparc-low.c (the_low_targets): Likewise.
4646
4647 2015-12-17 Pedro Alves <palves@redhat.com>
4648
4649 * linux-low.c (linux_kill_one_lwp): Remove references to
4650 LinuxThreads.
4651 (kill_lwp): Remove HAVE_TKILL_SYSCALL check. No longer fall back
4652 to 'kill'.
4653 (linux_init_signals): Delete.
4654 (initialize_low): Adjust.
4655 * thread-db.c (thread_db_init): Remove LinuxThreads reference.
4656
4657 2015-12-16 Pedro Alves <palves@redhat.com>
4658
4659 * configure.ac (compiler warning flags): When testing a
4660 -Wno-foo option, check whether -Wfoo works instead.
4661 * configure: Regenerate.
4662
4663 2015-12-11 Don Breazeal <donb@codesourcery.com>
4664
4665 * server.c (process_serial_event): Don't exit from gdbserver
4666 in remote mode if there are still active inferiors.
4667
4668 2015-12-11 Yao Qi <yao.qi@linaro.org>
4669
4670 * linux-aarch64-low.c (aarch64_breakpoint_at): Call
4671 arm_breakpoint_at if the process is 32-bit.
4672
4673 2015-12-11 Yao Qi <yao.qi@linaro.org>
4674
4675 * linux-aarch32-low.c [__aarch64__]: Use arm_abi_breakpoint
4676 arm breakpoint.
4677
4678 2015-12-07 Yao Qi <yao.qi@linaro.org>
4679
4680 * configure.srv: Append arm.o to srv_tgtobj for
4681 aarch64*-*-linux* target.
4682 * linux-aarch32-low.c (arm_abi_breakpoint): New macro. Moved
4683 from linux-arm-low.c.
4684 (arm_eabi_breakpoint, arm_breakpoint): Likewise.
4685 (arm_breakpoint_len, thumb_breakpoint): Likewise.
4686 (thumb_breakpoint_len, thumb2_breakpoint): Likewise.
4687 (thumb2_breakpoint_len): Likewise.
4688 (arm_is_thumb_mode, arm_breakpoint_at): Likewise.
4689 (arm_breakpoint_kinds): Likewise.
4690 (arm_breakpoint_kind_from_pc): Likewise.
4691 (arm_sw_breakpoint_from_kind): Likewise.
4692 (arm_breakpoint_kind_from_current_state): Likewise.
4693 * linux-aarch32-low.h (arm_breakpoint_kind_from_pc): Declare.
4694 (arm_sw_breakpoint_from_kind): Declare.
4695 (arm_breakpoint_kind_from_current_state): Declare.
4696 (arm_breakpoint_at): Declare.
4697 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): Call
4698 arm_sw_breakpoint_from_kind if process is 32-bit.
4699 (aarch64_breakpoint_kind_from_pc): New function.
4700 (aarch64_breakpoint_kind_from_current_state): New function.
4701 (the_low_target): Initialize fields breakpoint_kind_from_pc
4702 and breakpoint_kind_from_current_state.
4703 * linux-arm-low.c (arm_breakpoint_kinds): Move to
4704 linux-aarch32-low.c.
4705 (arm_abi_breakpoint, arm_eabi_breakpoint): Likewise.
4706 (arm_breakpoint, arm_breakpoint_len): Likewise.
4707 (thumb_breakpoint, thumb_breakpoint_len): Likewise.
4708 (thumb2_breakpoint, thumb2_breakpoint_len): Likewise.
4709 (arm_is_thumb_mode): Likewise.
4710 (arm_breakpoint_at): Likewise.
4711 (arm_breakpoint_kind_from_pc): Likewise.
4712 (arm_sw_breakpoint_from_kind): Likewise.
4713 (arm_breakpoint_kind_from_current_state): Likewise.
4714
4715 Revert:
4716 2015-08-04 Yao Qi <yao.qi@linaro.org>
4717
4718 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
4719 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
4720 * server.c (extended_protocol): Remove "static".
4721 * server.h (extended_protocol): Declare it.
4722
4723 2015-12-04 Josh Stone <jistone@redhat.com>
4724
4725 * target.h (struct target_ops) <arch_setup>: Rename to ...
4726 (struct target_ops) <post_create_inferior>: ... this.
4727 (target_arch_setup): Rename to ...
4728 (target_post_create_inferior): ... this, calling post_create_inferior.
4729 * server.c (start_inferior): Update target_arch_setup calls to
4730 target_post_create_inferior.
4731 * linux-low.c (linux_low_ptrace_options): Forward declare.
4732 (linux_arch_setup): Update its comment for general use.
4733 (linux_post_create_inferior): New, run arch_setup and setup ptrace.
4734 (struct linux_target_ops): Use linux_post_create_inferior.
4735 * lynx-low.c (struct lynx_target_ops): Update arch_setup stub comment
4736 to post_create_inferior.
4737 * nto-low.c (struct nto_target_ops): Likewise.
4738 * spu-low.c (struct spu_target_ops): Likewise.
4739 * win32-low.c (struct win32_target_ops): Likewise.
4740
4741 2015-12-03 Antoine Tremblay <antoine.tremblay@ericsson.com>
4742
4743 * linux-arm-low.c: Remove duplicate arch/arm.h include.
4744
4745 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4746
4747 * linux-arm-low.c (arm_reinsert_addr): Remove function.
4748 (struct linux_target_ops <breakpoint_reinsert_addr>: Set to NULL.
4749 * linux-cris-low.c (cris_reinsert_addr> Remove function.
4750 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4751 * linux-crisv32-low.c (cris_reinsert_addr): Remove function.
4752 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4753 * linux-mips-low.c (mips_reinsert_addr): Remove function.
4754 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4755 * linux-nios2-low.c (nios2_reinsert_addr): Remove function.
4756 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4757 * linux-sparc-low.c (sparc_reinsert_addr): Remove function.
4758 (struct linux_target_ops) <breakpoint_reinsert_addr>: Set to NULL.
4759
4760 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4761
4762 * linux-low.c (linux_look_up_symbols): Don't call
4763 linux_supports_traceclone.
4764 * linux-low.h (thread_db_init): Remove use_events argument.
4765 * thread-db.c (thread_db_use_event): Remove global variable.
4766 (struct thread_db) <td_thr_event_enable_p>: Remove field.
4767 (struct thread_db) <td_create_bp>: Remove field.
4768 (thread_db_create_event): Remove function.
4769 (thread_db_enable_reporting): Likewise.
4770 (find_one_thread): Don't check for thread_db_use_events.
4771 (attach_thread): Likewise.
4772 (thread_db_load_search): Remove td_thr_event_enable_p initialization.
4773 (try_thread_db_load_1): Don't check for thread_db_use_events.
4774 (thread_db_init): Remove use_events argument and thread events
4775 handling.
4776 (remove_thread_event_breakpoints): Remove function.
4777 (thread_db_detach): Remove call to remove_thred_event_breakpoints.
4778
4779 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4780
4781 * linux-aarch64-low.c (aarch64_supports_hardware_single_step):
4782 New function.
4783 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4784 * linux-arm-low.c (arm_supports_hardware_single_step): New function.
4785 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4786 * linux-bfin-low.c (bfin_supports_hardware_single_step): New function.
4787 (struct linux_target_ops) <bfin_supports_hardware_single_step>:
4788 Initialize.
4789 * linux-crisv32-low.c (cris_supports_hardware_single_step):
4790 New function.
4791 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4792 * linux-low.c (can_hardware_single_step): Use
4793 supports_hardware_single_step.
4794 (can_software_single_step): New function.
4795 (start_step_over): Call can_software_single_step.
4796 (linux_supports_hardware_single_step): New function.
4797 (struct target_ops) <supports_software_single_step>: Initialize.
4798 * linux-low.h (struct linux_target_ops)
4799 <supports_hardware_single_step>: Initialize.
4800 * linux-m32r-low.c (m32r_supports_hardware_single_step): New function.
4801 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4802 * linux-ppc-low.c (ppc_supports_hardware_single_step): New function.
4803 (struct linux_target_ops) <supports_hardware_single_step> Initialize.
4804 * linux-s390-low.c (s390_supports_hardware_single_step): New function.
4805 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4806 * linux-sh-low.c (sh_supports_hardware_single_step): New function.
4807 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4808 * linux-tic6x-low.c (tic6x_supports_hardware_single_step): New function.
4809 (struct linux_target_ops) <tic6x_supports_hardware_single_step>:
4810 Initialize.
4811 * linux-tile-low.c (tile_supports_hardware_single_step): New function.
4812 (struct linux_target_ops) <tile_supports_hardware_single_step>:
4813 Initialize.
4814 * linux-x86-low.c (x86_supports_hardware_single_step) New function.
4815 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4816 * linux-xtensa-low.c (xtensa_supports_hardware_single_step):
4817 New function.
4818 (struct linux_target_ops) <supports_hardware_single_step>: Initialize.
4819 * target.h (struct target_ops): <supports_software_single_step>:
4820 New field.
4821 (target_supports_software_single_step): New macro.
4822
4823 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4824
4825 * linux-low.c (linux_wait_1): Fix pc advance condition.
4826 * mem-break.c (reinsert_breakpoint_inserted_here): New function.
4827 * mem-break.h (reinsert_breakpoint_inserted_here): New declaration.
4828
4829 2015-11-30 Antoine Tremblay <antoine.tremblay@ericsson.com>
4830
4831 * linux-arm-low.c (arm_is_thumb_mode): New function.
4832 (arm_breakpoint_at): Use arm_is_thumb_mode.
4833 (arm_breakpoint_kind_from_current_state): New function.
4834 (struct linux_target_ops) <breakpoint_kind_from_current_state>:
4835 Initialize.
4836 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_current_state.
4837 (linux_breakpoint_kind_from_current_state): New function.
4838 (struct target_ops <breakpoint_kind_from_current_state>: Initialize.
4839 * linux-low.h (struct linux_target_ops)
4840 <breakpoint_kind_from_current_state>: New field.
4841 * target.h (struct target_ops): Likewise.
4842 (target_breakpoint_kind_from_current_state): New macro.
4843
4844 2015-11-30 Pedro Alves <palves@redhat.com>
4845
4846 * linux-low.c (linux_resume): Wake up the event loop before
4847 returning.
4848
4849 2015-11-30 Pedro Alves <palves@redhat.com>
4850
4851 * mem-break.c (check_gdb_bp_preconditions): Remove current_thread
4852 check.
4853 (set_gdb_breakpoint): If prepare_to_access_memory fails, set *ERR
4854 to -1.
4855 * target.c (struct thread_search): New structure.
4856 (thread_search_callback): New function.
4857 (prev_general_thread): New global.
4858 (prepare_to_access_memory, done_accessing_memory): New functions.
4859 * target.h (prepare_to_access_memory, done_accessing_memory):
4860 Replace macros with function declarations.
4861
4862 2015-11-30 Pedro Alves <palves@redhat.com>
4863
4864 PR 14618
4865 * linux-low.c (linux_wait_1): If the last resumed thread is gone,
4866 report TARGET_WAITKIND_NO_RESUMED.
4867 * remote-utils.c (prepare_resume_reply): Handle
4868 TARGET_WAITKIND_NO_RESUMED.
4869 * server.c (report_no_resumed): New global.
4870 (handle_query) <qSupported>: Handle "no-resumed+". Report
4871 "no-resumed+" support.
4872 (resume): When the target reports TARGET_WAITKIND_NO_RESUMED, only
4873 return error if the client doesn't support no-resumed events.
4874 (push_stop_notification): New function.
4875 (handle_target_event): Use it. Report TARGET_WAITKIND_NO_RESUMED
4876 events if the client supports them.
4877
4878 2015-11-30 Pedro Alves <palves@redhat.com>
4879
4880 * linux-low.c (thread_still_has_status_pending_p): Don't check
4881 vCont;t here.
4882 (lwp_resumed): New function.
4883 (status_pending_p_callback): Return early if the LWP is not
4884 supposed to be resumed.
4885
4886 2015-11-30 Pedro Alves <palves@redhat.com>
4887
4888 * linux-low.c (handle_extended_wait): Assert that the LWP's
4889 waitstatus is TARGET_WAITKIND_IGNORE. If GDB wants to hear about
4890 thread create events, leave the new child's status pending.
4891 (linux_low_filter_event): If GDB wants to hear about thread exit
4892 events, leave the LWP marked dead and don't delete it.
4893 (linux_wait_for_event_filtered): Don't check for thread exit.
4894 (filter_exit_event): New function.
4895 (linux_wait_1): Use it, when returning an exit event.
4896 (linux_resume_one_lwp_throw): Assert that the LWP's
4897 waitstatus is TARGET_WAITKIND_IGNORE.
4898 * remote-utils.c (prepare_resume_reply): Handle
4899 TARGET_WAITKIND_THREAD_CREATED and TARGET_WAITKIND_THREAD_EXITED.
4900 * server.c (report_thread_events): New global.
4901 (handle_general_set): Handle QThreadEvents.
4902 (handle_query) <qSupported>: Handle and report QThreadEvents+;
4903 (handle_target_event): Handle TARGET_WAITKIND_THREAD_CREATED and
4904 TARGET_WAITKIND_THREAD_EXITED.
4905 * server.h (report_thread_events): Declare.
4906
4907 2015-11-30 Pedro Alves <palves@redhat.com>
4908
4909 * linux-low.c (resume_stopped_resumed_lwps): Don't check whether
4910 the thread's last_resume_kind was resume_stop.
4911
4912 2015-11-30 Pedro Alves <palves@redhat.com>
4913
4914 * linux-low.c (linux_attach): In non-stop mode, wait for one stop
4915 before returning.
4916
4917 2015-11-30 Pedro Alves <palves@redhat.com>
4918
4919 * server.c (handle_v_requests): Handle vCtrlC.
4920
4921 2015-11-30 Pedro Alves <palves@redhat.com>
4922
4923 * gdbthread.h (find_any_thread_of_pid): Declare.
4924 * inferiors.c (thread_of_pid, find_any_thread_of_pid): New
4925 functions.
4926 * server.c (handle_query): If current_thread is NULL, look for
4927 another thread of the selected process.
4928
4929 2015-11-26 Daniel Colascione <dancol@dancol.org>
4930 Simon Marchi <simon.marchi@ericsson.com>
4931
4932 * linux-low.c (linux_target_ops): Use linux_proc_tid_get_name.
4933 * server.c (handle_qxfer_threads_worker): Refactor to include thread
4934 name in reply.
4935 * target.h (struct target_ops) <thread_name>: New field.
4936 (target_thread_name): New macro.
4937
4938 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4939
4940 * regcache.h (regcache_invalidate_pid): Add declaration.
4941 * regcache.c (regcache_invalidate_pid): New function, extracted
4942 from regcache_invalidate.
4943 (regcache_invalidate): Reimplement using regcache_invalidate_pid.
4944 Add trivial documentation comment.
4945 * lynx-low.c: Use regcache_invalidate_pid instead of
4946 regcache_invalidate.
4947
4948 2015-11-23 Joel Brobecker <brobecker@adacore.com>
4949
4950 * configure.ac: Do not call AC_CHECK_TYPES for Elf32_auxv_t
4951 and Elf64_auxv_t if the target is Android.
4952
4953 2015-11-22 Doug Evans <xdje42@gmail.com>
4954
4955 * target.h: #include <sys/types.h>.
4956
4957 2015-11-19 Pedro Alves <palves@redhat.com>
4958
4959 * linux-low.c (linux_process_qsupported): Change prototype.
4960 Adjust.
4961 * linux-low.h (struct linux_target_ops) <process_qsupported>:
4962 Change prototype.
4963 * linux-x86-low.c (x86_linux_process_qsupported): Change prototype
4964 and adjust to loop over all features.
4965 * server.c (handle_query) <qSupported>: Adjust to call
4966 target_process_qsupported once, passing it a vector of unprocessed
4967 features.
4968 * target.h (struct target_ops) <process_qsupported>: Change
4969 prototype.
4970 (target_process_qsupported): Adjust.
4971
4972 2015-11-19 Pedro Alves <palves@redhat.com>
4973
4974 * configure.ac (ERROR_ON_WARNING): Don't check whether in C++
4975 mode.
4976 * configure: Regenerate.
4977
4978 2015-11-19 Pedro Alves <palves@redhat.com>
4979
4980 * configure: Regenerate.
4981
4982 2015-11-19 Yao Qi <yao.qi@linaro.org>
4983
4984 * linux-aarch64-low.c (emit_data_processing_reg): Change opcode
4985 type to uint32_t.
4986
4987 2015-11-19 Yao Qi <yao.qi@linaro.org>
4988
4989 * linux-aarch64-low.c (enum aarch64_operand_type): New.
4990 (struct aarch64_operand): Move enum out.
4991
4992 2015-11-19 Yao Qi <yao.qi@linaro.org>
4993
4994 * linux-aarch64-low.c (aarch64_fill_fpregset): Cast buf to
4995 struct user_fpsimd_state *.
4996 (aarch64_store_fpregset): Likewise.
4997
4998 2015-11-19 Yao Qi <yao.qi@linaro.org>
4999
5000 * linux-aarch64-low.c (aarch64_fill_gregset): Cast buf to
5001 struct user_pt_regs *.
5002 (aarch64_store_gregset): Likewise.
5003
5004 2015-11-18 Pedro Alves <palves@redhat.com>
5005
5006 * Makefile.in (all_object_files): Add $IPA_OBJS.
5007
5008 2015-11-17 Pedro Alves <palves@redhat.com>
5009
5010 * win32-low.c (win32_resume): Use gdb_signal_from_host,
5011 GDB_SIGNAL_0 and gdb_signal_to_string.
5012
5013 2015-11-17 Pedro Alves <palves@redhat.com>
5014
5015 * win32-low.c (handle_output_debug_string): Remove parameter.
5016 (win32_kill): Remove our_status local and adjust call to
5017 handle_output_debug_string.
5018 (get_child_debug_event): Adjust call to
5019 handle_output_debug_string.
5020
5021 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5022
5023 * linux-mips-low.c (mips_fill_gregset): Add cast.
5024 (mips_store_gregset): Likewise.
5025 (mips_fill_fpregset): Likewise.
5026 (mips_store_fpregset): Likewise.
5027
5028 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5029
5030 * linux-mips-low.c (mips_add_watchpoint): Rename private to
5031 priv.
5032
5033 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5034
5035 * linux-mips-low.c (mips_linux_new_thread): Change type of
5036 watch_type to enum target_hw_bp_type.
5037
5038 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5039
5040 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type):
5041 Change return type to arm_hwbp_type.
5042
5043 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5044
5045 * linux-aarch32-low.c (arm_fill_gregset): Add cast.
5046 (arm_store_gregset): Likewise.
5047 * linux-arm-low.c (arm_get_hwcap): Likewise.
5048 (arm_read_description): Likewise.
5049
5050 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5051
5052 * linux-aarch32-low.c (aarch32_regsets): Use NULL_REGSET.
5053
5054 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5055
5056 * linux-ppc-low.c (ppc_get_hwcap): Add cast.
5057 (ppc_fill_vsxregset): Likewise.
5058 (ppc_store_vsxregset): Likewise.
5059 (ppc_fill_vrregset): Likewise.
5060 (ppc_store_vrregset): Likewise.
5061 (ppc_fill_evrregset): Likewise.
5062 (ppc_store_evrregset): Likewise.
5063
5064 2015-11-03 Simon Marchi <simon.marchi@polymtl.ca>
5065
5066 * linux-ppc-low.c (ppc_usrregs_info): Remove
5067 forward-declaration.
5068 (ppc_arch_setup): Move lower in file.
5069
5070 2015-10-30 Simon Marchi <simon.marchi@ericsson.com>
5071
5072 * proc-service.c (ps_pdread): Change CORE_ADDR cast to uintptr_t.
5073 (ps_pdwrite): Likewise.
5074
5075 2015-10-29 Henrik Wallin <henrik.wallin@windriver.com>
5076
5077 * linux-arm-low.c (arm_new_thread): Move pointer dereference
5078 to after assert checks.
5079
5080 2015-10-29 Simon Marchi <simon.marchi@ericsson.com>
5081
5082 * proc-service.c (ps_pdread): Add/adjust casts.
5083 (ps_pdwrite): Add/adjust casts.
5084
5085 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5086
5087 * server.c (handle_search_memory_1): Cast return value of
5088 memmem.
5089
5090 2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
5091
5092 * server.c (write_qxfer_response): Change type of data to
5093 gdb_byte *.
5094
5095 2015-10-29 Pedro Alves <palves@redhat.com>
5096
5097 * mem-break.c (Z_packet_to_bkpt_type): Add cast.
5098
5099 2015-10-29 Pedro Alves <palves@redhat.com>
5100
5101 * tracepoint.c (clear_installed_tracepoints): Add casts.
5102
5103 2015-10-29 Pedro Alves <palves@redhat.com>
5104
5105 * server.c (handle_v_cont, process_serial_event): Add enum
5106 gdb_signal casts to signal parsing code.
5107
5108 2015-10-29 Pedro Alves <palves@redhat.com>
5109
5110 * linux-low.h (NULL_REGSET): Define.
5111 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5112 * linux-arm-low.c (arm_regsets): Likewise.
5113 * linux-crisv32-low.c (cris_regsets): Likewise.
5114 * linux-m68k-low.c (m68k_regsets): Likewise.
5115 * linux-mips-low.c (mips_regsets): Likewise.
5116 * linux-nios2-low.c (nios2_regsets): Likewise.
5117 * linux-ppc-low.c (ppc_regsets): Likewise.
5118 * linux-s390-low.c (s390_regsets): Likewise.
5119 * linux-sh-low.c (sh_regsets): Likewise.
5120 * linux-sparc-low.c (sparc_regsets): Likewise.
5121 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5122 * linux-tile-low.c (tile_regsets): Likewise.
5123 * linux-x86-low.c (x86_regsets): Likewise.
5124 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5125
5126 2015-10-29 Pedro Alves <palves@redhat.com>
5127
5128 * linux-low.h (NULL_REGSET): Define.
5129 * linux-aarch64-low.c (aarch64_regsets): Use NULL_REGSET.
5130 * linux-arm-low.c (arm_regsets): Likewise.
5131 * linux-crisv32-low.c (cris_regsets): Likewise.
5132 * linux-m68k-low.c (m68k_regsets): Likewise.
5133 * linux-mips-low.c (mips_regsets): Likewise.
5134 * linux-nios2-low.c (nios2_regsets): Likewise.
5135 * linux-ppc-low.c (ppc_regsets): Likewise.
5136 * linux-s390-low.c (s390_regsets): Likewise.
5137 * linux-sh-low.c (sh_regsets): Likewise.
5138 * linux-sparc-low.c (sparc_regsets): Likewise.
5139 * linux-tic6x-low.c (tic6x_regsets): Likewise.
5140 * linux-tile-low.c (tile_regsets): Likewise.
5141 * linux-x86-low.c (x86_regsets): Likewise.
5142 * linux-xtensa-low.c (xtensa_regsets): Likewise.
5143
5144 2015-10-26 Doug Evans <dje@google.com>
5145
5146 * linux-low.c (__SIGRTMIN): Move to nat/linux-nat.h.
5147
5148 2015-10-26 Doug Evans <dje@google.com>
5149
5150 * linux-low.c (W_STOPCODE): Moved to common/gdb_wait.h.
5151
5152 2015-10-26 Doug Evans <dje@google.com>
5153
5154 * thread-db.c (find_one_thread): Cast ti.ti_tid to unsigned long
5155 for debug_printf.
5156 (attach_thread, find_new_threads_callback): Ditto.
5157
5158 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5159
5160 * mem-break.h (set_breakpoint_data): Remove.
5161
5162 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5163
5164 * nto-low.c (nto_sw_breakpoint_from_kind): New function.
5165 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5166 (initialize_low): Remove set_breakpoint_data call.
5167 * spu-low.c (spu_sw_breakpoint_from_kind): New function.
5168 (struct target_ops) <sw_breakpoint_from_kind>: Iniitalize.
5169 (initialize_low): Remove set_breakpoint_data call.
5170 * win32-low.c (win32_sw_breakpoint_from_kind): New function.
5171 (struct target_ops) <sw_breakpoint_from_kind>: Initialize.
5172 (initialize_low): Remove set_breakpoint_data call.
5173
5174 2015-10-23 Antoine Tremblay <antoine.tremblay@ericsson.com>
5175
5176 * linux-low.c (default_breakpoint_kind_from_pc): Move to target.c.
5177 * mem-break.c (set_breakpoint_at): Use target_breakpoint_kind_from_pc.
5178 * target.c (default_breakpoint_kind_from_pc): Moved from linux-low.c
5179 * target.h (target_breakpoint_kind_from_pc): New macro.
5180
5181 2015-10-22 Antoine Tremblay <antoine.tremblay@ericsson.com>
5182
5183 * linux-low.c (default_breakpoint_kind_from_pc): New function.
5184 (linux_breakpoint_kind_from_pc): Use default_breakpoint_kind_from_pc for
5185 the default breakpoint kind.
5186
5187 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5188
5189 * linux-arm-low.c (arm_supports_z_point_type): Add software
5190 breakpoint support.
5191
5192 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5193
5194 * linux-arm-low.c: Refactor breakpoint definitions.
5195 (arm_breakpoint_at): Adjust for arm_abi_breakpoint.
5196 (arm_sw_breakpoint_from_kind): Adjust for arm_breakpoint.
5197
5198 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5199
5200 * Makefile.in: Add arm.c/o.
5201 * configure.srv: Likewise.
5202 * linux-arm-low.c (arm_breakpoint_kinds): New enum.
5203 (arm_breakpoint_kind_from_pc): New function.
5204 (arm_sw_breakpoint_from_kind): Return proper kind.
5205 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize.
5206
5207 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5208
5209 * linux-low.c (initialize_low): Ajdust for breakpoint global variables
5210 removal.
5211 * mem-break.c : Remove breakpoint_data/breakpoint_len global variables.
5212 (struct raw_breakpoint) <size>: Remove.
5213 (struct raw_breakpoint) <kind>: Add.
5214 (bp_size): New function.
5215 (bp_opcode): Likewise.
5216 (find_raw_breakpoint_at): Adjust for kind.
5217 (insert_memory_breakpoint): Adjust for kind call bp_size,bp_opcode.
5218 (remove_memory_breakpoint): Adjust for kind call bp_size.
5219 (set_raw_breakpoint_at): Adjust for kind.
5220 (set_breakpoint): Likewise.
5221 (set_breakpoint_at): Call breakpoint_kind_from_pc.
5222 (delete_raw_breakpoint): Adjust for kind.
5223 (delete_breakpoint): Likewise.
5224 (find_gdb_breakpoint): Likewise.
5225 (set_gdb_breakpoint_1): Likewise.
5226 (set_gdb_breakpoint): Likewise.
5227 (delete_gdb_breakpoint_1): Likewise.
5228 (delete_gdb_breakpoint): Likewise.
5229 (uninsert_raw_breakpoint): Likewise.
5230 (reinsert_raw_breakpoint): Likewise.
5231 (set_breakpoint_data): Remove.
5232 (validate_inserted_breakpoint): Adjust for kind call bp_size,bp_opcode.
5233 (check_mem_read): Adjust for kind call bp_size.
5234 (check_mem_write): Adjust for kind call bp_size,bp_opcode.
5235 (clone_one_breakpoint): Adjust for kind.
5236 * mem-break.h (set_gdb_breakpoint): Likewise.
5237 (delete_gdb_breakpoint): Likewise.
5238 * server.c (process_serial_event): Likewise.
5239
5240 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5241
5242 * linux-aarch64-low.c (aarch64_sw_breakpoint_from_kind): New function.
5243 (struct linux_target_ops) <breakpoint>: Remove.
5244 (struct linux_target_ops) <breakpoint_len>: Remove.
5245 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5246 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5247 * linux-arm-low.c (arm_breakpoint_kind_from_pc): New function.
5248 (arm_sw_breakpoint_from_kind): New function.
5249 * linux-bfin-low.c (bfin_sw_breakpoint_from_kind): New function.
5250 (struct linux_target_ops) <breakpoint>: Remove.
5251 (struct linux_target_ops) <breakpoint_len>: Remove.
5252 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5253 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5254 * linux-cris-low.c (cris_sw_breakpoint_from_kind): New function.
5255 (struct linux_target_ops) <breakpoint>: Remove.
5256 (struct linux_target_ops) <breakpoint_len>: Remove.
5257 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5258 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5259 * linux-crisv32-low.c (cris_sw_breakpoint_from_kind): New function.
5260 (struct linux_target_ops) <breakpoint>: Remove.
5261 (struct linux_target_ops) <breakpoint_len>: Remove.
5262 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5263 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5264 * linux-low.c (linux_wait_1): Call breakpoint_kind_from_pc
5265 and sw_breakpoint_from_kind to increment the pc.
5266 (linux_breakpoint_kind_from_pc): New function.
5267 (linux_sw_breakpoint_from_kind): New function.
5268 (struct target_ops) <sw_breakpoint_from_kind>: Initialize field.
5269 (initialize_low): Call breakpoint_kind_from_pc and
5270 sw_breakpoint_from_kind to replace breakpoint_data/len.
5271 * linux-low.h (struct linux_target_ops) <breakpoint_kind_from_pc>:
5272 New field.
5273 (struct linux_target_ops) <sw_breakpoint_from_kind>: Likewise.
5274 * linux-m32r-low.c (m32r_sw_breakpoint_from_kind): New function.
5275 (struct linux_target_ops) <breakpoint>: Remove.
5276 (struct linux_target_ops) <breakpoint_len>: Remove.
5277 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5278 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5279 * linux-m68k-low.c (m68k_sw_breakpoint_from_kind): New function.
5280 (struct linux_target_ops) <breakpoint>: Remove.
5281 (struct linux_target_ops) <breakpoint_len>: Remove.
5282 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5283 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5284 * linux-mips-low.c (mips_sw_breakpoint_from_kind): New function.
5285 (struct linux_target_ops) <breakpoint>: Remove.
5286 (struct linux_target_ops) <breakpoint_len>: Remove.
5287 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5288 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5289 * linux-nios2-low.c (nios2_sw_breakpoint_from_kind): New function.
5290 (struct linux_target_ops) <breakpoint>: Remove.
5291 (struct linux_target_ops) <breakpoint_len>: Remove.
5292 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5293 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5294 * linux-ppc-low.c (ppc_sw_breakpoint_from_kind): New function.
5295 (struct linux_target_ops) <breakpoint>: Remove.
5296 (struct linux_target_ops) <breakpoint_len>: Remove.
5297 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5298 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5299 * linux-s390-low.c (s390_sw_breakpoint_from_kind): New function.
5300 (struct linux_target_ops) <breakpoint>: Remove.
5301 (struct linux_target_ops) <breakpoint_len>: Remove.
5302 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5303 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5304 * linux-sh-low.c (sh_sw_breakpoint_from_kind): New function.
5305 (struct linux_target_ops) <breakpoint>: Remove.
5306 (struct linux_target_ops) <breakpoint_len>: Remove.
5307 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5308 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5309 * linux-sparc-low.c (sparc_sw_breakpoint_from_kind): New function.
5310 (struct linux_target_ops) <breakpoint>: Remove.
5311 (struct linux_target_ops) <breakpoint_len>: Remove.
5312 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5313 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5314 * linux-tic6x-low.c (tic6x_sw_breakpoint_from_kind): New function.
5315 (struct linux_target_ops) <breakpoint>: Remove.
5316 (struct linux_target_ops) <breakpoint_len>: Remove.
5317 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5318 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5319 * linux-tile-low.c (tile_sw_breakpoint_from_kind): New function.
5320 * linux-x86-low.c (x86_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-xtensa-low.c (xtensa_sw_breakpoint_from_kind) New function.
5326 (struct linux_target_ops) <breakpoint>: Remove.
5327 (struct linux_target_ops) <breakpoint_len>: Remove.
5328 (struct linux_target_ops) <breakpoint_kind_from_pc>: Initialize field.
5329 (struct linux_target_ops) <sw_breakpoint_from_kind>: Initialize field.
5330
5331 2015-10-21 Antoine Tremblay <antoine.tremblay@ericsson.com>
5332
5333 * linux-cris-low.c (cris_get_pc): Remove void arg.
5334
5335 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5336
5337 * gdbserver/nto-low.c (nto_insert_point, nto_remove_point): Fix
5338 variable name.
5339
5340 2015-10-16 Aleksandar Ristovski <aristovski@qnx.com>
5341
5342 * inferiors.c (thread_pid_matches_callback): New function.
5343 (find_thread_process): New function.
5344 (remove_thread): Reset current_thread.
5345 (remove_process): Assert threads have been removed first.
5346
5347 2015-10-15 Yao Qi <yao.qi@linaro.org>
5348
5349 * linux-aarch64-low.c (aarch64_insert_point): Set len to 2
5350 if it is 3.
5351 (aarch64_remove_point): Likewise.
5352 * regcache.c (regcache_register_size): New function.
5353
5354 2015-10-12 Yao Qi <yao.qi@linaro.org>
5355
5356 * linux-aarch64-low.c: Update all callers as emit_load_store
5357 is renamed to aarch64_emit_load_store.
5358
5359 2015-10-12 Yao Qi <yao.qi@linaro.org>
5360
5361 * linux-aarch64-low.c: Update all callers of function renaming
5362 from emit_insn to aarch64_emit_insn.
5363
5364 2015-10-12 Yao Qi <yao.qi@linaro.org>
5365
5366 * linux-aarch64-low.c (enum aarch64_opcodes): Move to
5367 arch/aarch64-insn.h.
5368 (struct aarch64_memory_operand): Likewise.
5369 (ENCODE): Likewise.
5370 (emit_insn): Move to arch/aarch64-insn.c.
5371 (emit_b, emit_bcond, emit_cb, emit_tb): Remove.
5372 (emit_load_store): Move to arch/aarch64-insn.c.
5373 (emit_ldr, emit_ldrb, emit_ldrsw, emit_nop): Remove.
5374 (can_encode_int32): Remove.
5375
5376 2015-10-12 Yao Qi <yao.qi@linaro.org>
5377
5378 * linux-aarch64-low.c (extract_signed_bitfield): Remove.
5379 (aarch64_decode_ldr_literal): Move to gdb/arch/aarch64-insn.c.
5380 (aarch64_relocate_instruction): Likewise.
5381 (struct aarch64_insn_data): Move to gdb/arch/aarch64-insn.h.
5382 (struct aarch64_insn_visitor): Likewise.
5383
5384 2015-10-12 Yao Qi <yao.qi@linaro.org>
5385
5386 * linux-aarch64-low.c (struct aarch64_insn_data): New.
5387 (struct aarch64_insn_visitor): New.
5388 (struct aarch64_insn_relocation_data): New.
5389 (aarch64_ftrace_insn_reloc_b): New function.
5390 (aarch64_ftrace_insn_reloc_b_cond): Likewise.
5391 (aarch64_ftrace_insn_reloc_cb): Likewise.
5392 (aarch64_ftrace_insn_reloc_tb): Likewise.
5393 (aarch64_ftrace_insn_reloc_adr): Likewise.
5394 (aarch64_ftrace_insn_reloc_ldr_literal): Likewise.
5395 (aarch64_ftrace_insn_reloc_others): Likewise.
5396 (visitor): New.
5397 (aarch64_relocate_instruction): Use visitor.
5398
5399 2015-10-12 Yao Qi <yao.qi@linaro.org>
5400
5401 * linux-aarch64-low.c (aarch64_relocate_instruction): Return
5402 int. Add argument buf.
5403 (aarch64_install_fast_tracepoint_jump_pad): Pass buf to
5404 aarch64_relocate_instruction.
5405
5406 2015-10-12 Yao Qi <yao.qi@linaro.org>
5407
5408 * linux-aarch64-low.c (aarch64_relocate_instruction): Add
5409 argument insn. Remove local variable insn. Don't call
5410 target_read_uint32.
5411 (aarch64_install_fast_tracepoint_jump_pad): Call
5412 target_read_uint32.
5413
5414 2015-09-30 Yao Qi <yao.qi@linaro.org>
5415
5416 * linux-aarch64-low.c (emit_movk): Shorten a long line.
5417 (emit_load_store_pair): Likewise.
5418
5419 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5420
5421 * dll.c (match_dll): Add cast(s).
5422 (unloaded_dll): Likewise.
5423 * linux-low.c (second_thread_of_pid_p): Likewise.
5424 (delete_lwp_callback): Likewise.
5425 (count_events_callback): Likewise.
5426 (select_event_lwp_callback): Likewise.
5427 (linux_set_resume_request): Likewise.
5428 * server.c (accumulate_file_name_length): Likewise.
5429 (emit_dll_description): Likewise.
5430 (handle_qxfer_threads_worker): Likewise.
5431 (visit_actioned_threads): Likewise.
5432 * thread-db.c (any_thread_of): Likewise.
5433 * tracepoint.c (same_process_p): Likewise.
5434 (match_blocktype): Likewise.
5435 (build_traceframe_info_xml): Likewise.
5436
5437 2015-09-25 Simon Marchi <simon.marchi@ericsson.com>
5438
5439 * ax.c (gdb_parse_agent_expr): Add cast to allocation result
5440 assignment.
5441 (gdb_unparse_agent_expr): Likewise.
5442 * hostio.c (require_data): Likewise.
5443 (handle_pread): Likewise.
5444 * linux-low.c (disable_regset): Likewise.
5445 (fetch_register): Likewise.
5446 (store_register): Likewise.
5447 (get_dynamic): Likewise.
5448 (linux_qxfer_libraries_svr4): Likewise.
5449 * mem-break.c (delete_fast_tracepoint_jump): Likewise.
5450 (set_fast_tracepoint_jump): Likewise.
5451 (uninsert_fast_tracepoint_jumps_at): Likewise.
5452 (reinsert_fast_tracepoint_jumps_at): Likewise.
5453 (validate_inserted_breakpoint): Likewise.
5454 (clone_agent_expr): Likewise.
5455 * regcache.c (init_register_cache): Likewise.
5456 * remote-utils.c (putpkt_binary_1): Likewise.
5457 (decode_M_packet): Likewise.
5458 (decode_X_packet): Likewise.
5459 (look_up_one_symbol): Likewise.
5460 (relocate_instruction): Likewise.
5461 (monitor_output): Likewise.
5462 * server.c (handle_search_memory): Likewise.
5463 (handle_qxfer_exec_file): Likewise.
5464 (handle_qxfer_libraries): Likewise.
5465 (handle_qxfer): Likewise.
5466 (handle_query): Likewise.
5467 (handle_v_cont): Likewise.
5468 (handle_v_run): Likewise.
5469 (captured_main): Likewise.
5470 * target.c (write_inferior_memory): Likewise.
5471 * thread-db.c (try_thread_db_load_from_dir): Likewise.
5472 * tracepoint.c (init_trace_buffer): Likewise.
5473 (add_tracepoint_action): Likewise.
5474 (add_traceframe): Likewise.
5475 (add_traceframe_block): Likewise.
5476 (cmd_qtdpsrc): Likewise.
5477 (cmd_qtdv): Likewise.
5478 (cmd_qtstatus): Likewise.
5479 (response_source): Likewise.
5480 (response_tsv): Likewise.
5481 (cmd_qtnotes): Likewise.
5482 (gdb_collect): Likewise.
5483 (initialize_tracepoint): Likewise.
5484
5485 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5486
5487 * linux-aarch64-low-.c: Include ax.h and tracepoint.h.
5488 (enum aarch64_opcodes) <RET>, <SUBS>, <AND>, <ORR>, <ORN>,
5489 <EOR>, <LSLV>, <LSRV>, <ASRV>, <SBFM>, <UBFM>, <CSINC>, <MUL>,
5490 <NOP>: New.
5491 (enum aarch64_condition_codes): New enum.
5492 (w0): New static global.
5493 (fp): Likewise.
5494 (lr): Likewise.
5495 (struct aarch64_memory_operand) <type>: New
5496 MEMORY_OPERAND_POSTINDEX type.
5497 (postindex_memory_operand): New helper function.
5498 (emit_ret): New function.
5499 (emit_load_store_pair): New function, factored out of emit_stp
5500 with support for MEMORY_OPERAND_POSTINDEX.
5501 (emit_stp): Rewrite using emit_load_store_pair.
5502 (emit_ldp): New function.
5503 (emit_load_store): Likewise.
5504 (emit_ldr): Mention post-index instruction in comment.
5505 (emit_ldrh): New function.
5506 (emit_ldrb): New function.
5507 (emit_ldrsw): Mention post-index instruction in comment.
5508 (emit_str): Likewise.
5509 (emit_subs): New function.
5510 (emit_cmp): Likewise.
5511 (emit_and): Likewise.
5512 (emit_orr): Likewise.
5513 (emit_orn): Likewise.
5514 (emit_eor): Likewise.
5515 (emit_mvn): Likewise.
5516 (emit_lslv): Likewise.
5517 (emit_lsrv): Likewise.
5518 (emit_asrv): Likewise.
5519 (emit_mul): Likewise.
5520 (emit_sbfm): Likewise.
5521 (emit_sbfx): Likewise.
5522 (emit_ubfm): Likewise.
5523 (emit_ubfx): Likewise.
5524 (emit_csinc): Likewise.
5525 (emit_cset): Likewise.
5526 (emit_nop): Likewise.
5527 (emit_ops_insns): New helper function.
5528 (emit_pop): Likewise.
5529 (emit_push): Likewise.
5530 (aarch64_emit_prologue): New function.
5531 (aarch64_emit_epilogue): Likewise.
5532 (aarch64_emit_add): Likewise.
5533 (aarch64_emit_sub): Likewise.
5534 (aarch64_emit_mul): Likewise.
5535 (aarch64_emit_lsh): Likewise.
5536 (aarch64_emit_rsh_signed): Likewise.
5537 (aarch64_emit_rsh_unsigned): Likewise.
5538 (aarch64_emit_ext): Likewise.
5539 (aarch64_emit_log_not): Likewise.
5540 (aarch64_emit_bit_and): Likewise.
5541 (aarch64_emit_bit_or): Likewise.
5542 (aarch64_emit_bit_xor): Likewise.
5543 (aarch64_emit_bit_not): Likewise.
5544 (aarch64_emit_equal): Likewise.
5545 (aarch64_emit_less_signed): Likewise.
5546 (aarch64_emit_less_unsigned): Likewise.
5547 (aarch64_emit_ref): Likewise.
5548 (aarch64_emit_if_goto): Likewise.
5549 (aarch64_emit_goto): Likewise.
5550 (aarch64_write_goto_address): Likewise.
5551 (aarch64_emit_const): Likewise.
5552 (aarch64_emit_call): Likewise.
5553 (aarch64_emit_reg): Likewise.
5554 (aarch64_emit_pop): Likewise.
5555 (aarch64_emit_stack_flush): Likewise.
5556 (aarch64_emit_zero_ext): Likewise.
5557 (aarch64_emit_swap): Likewise.
5558 (aarch64_emit_stack_adjust): Likewise.
5559 (aarch64_emit_int_call_1): Likewise.
5560 (aarch64_emit_void_call_2): Likewise.
5561 (aarch64_emit_eq_goto): Likewise.
5562 (aarch64_emit_ne_goto): Likewise.
5563 (aarch64_emit_lt_goto): Likewise.
5564 (aarch64_emit_le_goto): Likewise.
5565 (aarch64_emit_gt_goto): Likewise.
5566 (aarch64_emit_ge_got): Likewise.
5567 (aarch64_emit_ops_impl): New static global variable.
5568 (aarch64_emit_ops): New target function, return
5569 &aarch64_emit_ops_impl.
5570 (struct linux_target_ops): Install it.
5571
5572 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5573
5574 * Makefile.in (linux-aarch64-ipa.o, aarch64-ipa.o): New rules.
5575 * configure.srv (aarch64*-*-linux*): Add linux-aarch64-ipa.o and
5576 aarch64-ipa.o.
5577 * linux-aarch64-ipa.c: New file.
5578 * linux-aarch64-low.c: Include arch/aarch64-insn.h, inttypes.h
5579 and endian.h.
5580 (aarch64_get_thread_area): New target method.
5581 (extract_signed_bitfield): New helper function.
5582 (aarch64_decode_ldr_literal): New function.
5583 (enum aarch64_opcodes): New enum.
5584 (struct aarch64_register): New struct.
5585 (struct aarch64_operand): New struct.
5586 (x0): New static global.
5587 (x1): Likewise.
5588 (x2): Likewise.
5589 (x3): Likewise.
5590 (x4): Likewise.
5591 (w2): Likewise.
5592 (ip0): Likewise.
5593 (sp): Likewise.
5594 (xzr): Likewise.
5595 (aarch64_register): New helper function.
5596 (register_operand): Likewise.
5597 (immediate_operand): Likewise.
5598 (struct aarch64_memory_operand): New struct.
5599 (offset_memory_operand): New helper function.
5600 (preindex_memory_operand): Likewise.
5601 (enum aarch64_system_control_registers): New enum.
5602 (ENCODE): New macro.
5603 (emit_insn): New helper function.
5604 (emit_b): New function.
5605 (emit_bcond): Likewise.
5606 (emit_cb): Likewise.
5607 (emit_tb): Likewise.
5608 (emit_blr): Likewise.
5609 (emit_stp): Likewise.
5610 (emit_ldp_q_offset): Likewise.
5611 (emit_stp_q_offset): Likewise.
5612 (emit_load_store): Likewise.
5613 (emit_ldr): Likewise.
5614 (emit_ldrsw): Likewise.
5615 (emit_str): Likewise.
5616 (emit_ldaxr): Likewise.
5617 (emit_stxr): Likewise.
5618 (emit_stlr): Likewise.
5619 (emit_data_processing_reg): Likewise.
5620 (emit_data_processing): Likewise.
5621 (emit_add): Likewise.
5622 (emit_sub): Likewise.
5623 (emit_mov): Likewise.
5624 (emit_movk): Likewise.
5625 (emit_mov_addr): Likewise.
5626 (emit_mrs): Likewise.
5627 (emit_msr): Likewise.
5628 (emit_sevl): Likewise.
5629 (emit_wfe): Likewise.
5630 (append_insns): Likewise.
5631 (can_encode_int32_in): New helper function.
5632 (aarch64_relocate_instruction): New function.
5633 (aarch64_install_fast_tracepoint_jump_pad): Likewise.
5634 (aarch64_get_min_fast_tracepoint_insn_len): Likewise.
5635 (struct linux_target_ops): Install aarch64_get_thread_area,
5636 aarch64_install_fast_tracepoint_jump_pad and
5637 aarch64_get_min_fast_tracepoint_insn_len.
5638
5639 2015-09-21 Pierre Langlois <pierre.langlois@arm.com>
5640
5641 * Makefile.in (aarch64-insn.o): New rule.
5642 * configure.srv (aarch64*-*-linux*): Add aarch64-insn.o.
5643
5644 2015-09-21 Yao Qi <yao.qi@linaro.org>
5645
5646 * ax.c [!IN_PROCESS_AGENT] (gdb_agent_op_sizes): Define it.
5647
5648 2015-09-21 Yao Qi <yao.qi@linaro.org>
5649
5650 * tracepoint.c (max_jump_pad_size): Remove.
5651
5652 2015-09-18 Yao Qi <yao.qi@linaro.org>
5653
5654 * linux-aarch64-low.c: Don't include sys/uio.h.
5655 (ps_get_thread_area): Call aarch64_ps_get_thread_area.
5656
5657 2015-09-16 Wei-cheng Wang <cole945@gmail.com>
5658
5659 * tracepoint.c (eval_result_type): Change prototype.
5660 (condition_true_at_tracepoint): Fix argument to compiled_cond.
5661
5662 2015-09-15 Pedro Alves <palves@redhat.com>
5663
5664 * remote-utils.c (prepare_resume_reply) <TARGET_WAITKIND_EXECD>:
5665 Check whether to report exec events instead of checking whether
5666 multiprocess is enabled.
5667
5668 2015-09-15 Pedro Alves <palves@redhat.com>
5669
5670 PR remote/18965
5671 * remote-utils.c (prepare_resume_reply): Merge
5672 TARGET_WAITKIND_VFORK_DONE switch case with the
5673 TARGET_WAITKIND_FORKED case.
5674
5675 2015-09-15 Yao Qi <yao.qi@linaro.org>
5676
5677 * server.c (handle_query): Check string comparison using
5678 "else if" instead of "if".
5679
5680 2015-09-15 Yao Qi <yao.qi@linaro.org>
5681
5682 * server.c (vCont_supported): New global variable.
5683 (handle_query): Set vCont_supported to 1 if "vContSupported+"
5684 matches. Append ";vContSupported+" to own_buf.
5685 (handle_v_requests): Append ";s;S" to own_buf if target supports
5686 hardware single step or vCont_supported is false.
5687 (capture_main): Set vCont_supported to zero.
5688
5689 2015-09-15 Yao Qi <yao.qi@linaro.org>
5690
5691 * linux-low.c (linux_supports_conditional_breakpoints): Rename
5692 it to ...
5693 (linux_supports_hardware_single_step): ... New function.
5694 (linux_target_ops): Update.
5695 * lynx-low.c (lynx_target_ops): Set field
5696 supports_hardware_single_step to target_can_do_hardware_single_step.
5697 * nto-low.c (nto_target_ops): Likewise.
5698 * spu-low.c (spu_target_ops): Likewise.
5699 * win32-low.c (win32_target_ops): Likewise.
5700 * target.c (target_can_do_hardware_single_step): New function.
5701 * target.h (struct target_ops) <supports_conditional_breakpoints>:
5702 Remove. <supports_hardware_single_step>: New field.
5703 (target_supports_conditional_breakpoints): Remove.
5704 (target_supports_hardware_single_step): New macro.
5705 (target_can_do_hardware_single_step): Declare.
5706 * server.c (handle_query): Use target_supports_hardware_single_step
5707 instead of target_supports_conditional_breakpoints.
5708
5709 2015-09-15 Yao Qi <yao.qi@linaro.org>
5710
5711 * linux-aarch64-low.c (aarch64_linux_siginfo_fixup): New
5712 function.
5713 (struct linux_target_ops the_low_target): Install
5714 aarch64_linux_siginfo_fixup.
5715
5716 2015-09-11 Don Breazeal <donb@codesourcery.com>
5717 Luis Machado <lgustavo@codesourcery.com>
5718
5719 * linux-low.c (linux_mourn): Static declaration.
5720 (linux_arch_setup): Move in front of
5721 handle_extended_wait.
5722 (linux_arch_setup_thread): New function.
5723 (handle_extended_wait): Handle exec events. Call
5724 linux_arch_setup_thread. Make event_lwp argument a
5725 pointer-to-a-pointer.
5726 (check_zombie_leaders): Do not check stopped threads.
5727 (linux_low_ptrace_options): Add PTRACE_O_TRACEEXEC.
5728 (linux_low_filter_event): Add lwp and thread for exec'ing
5729 non-leader thread if leader thread has been deleted.
5730 Refactor code into linux_arch_setup_thread and call it.
5731 Pass child lwp pointer by reference to handle_extended_wait.
5732 (linux_wait_for_event_filtered): Update comment.
5733 (linux_wait_1): Prevent clobbering exec event status.
5734 (linux_supports_exec_events): New function.
5735 (linux_target_ops) <supports_exec_events>: Initialize new member.
5736 * lynx-low.c (lynx_target_ops) <supports_exec_events>: Initialize
5737 new member.
5738 * remote-utils.c (prepare_resume_reply): New stop reason 'exec'.
5739 * server.c (report_exec_events): New global variable.
5740 (handle_query): Handle qSupported query for exec-events feature.
5741 (captured_main): Initialize report_exec_events.
5742 * server.h (report_exec_events): Declare new global variable.
5743 * target.h (struct target_ops) <supports_exec_events>: New
5744 member.
5745 (target_supports_exec_events): New macro.
5746 * win32-low.c (win32_target_ops) <supports_exec_events>:
5747 Initialize new member.
5748
5749 2015-09-09 Markus Metzger <markus.t.metzger@intel.com>
5750
5751 * linux-low.c (linux_low_enable_btrace): Remove.
5752 (linux_target_ops): Replace linux_low_enable_btrace with
5753 linux_enable_btrace.
5754
5755 2015-09-03 Yao Qi <yao.qi@linaro.org>
5756
5757 * linux-aarch64-low.c (aarch64_insert_point): Call
5758 aarch64_handle_watchpoint if aarch64_linux_region_ok_for_watchpoint
5759 returns true.
5760
5761 2015-08-27 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
5762
5763 * linux-low.c (check_stopped_by_breakpoint): Use
5764 GDB_ARCH_IS_TRAP_BRKPT instead of GDB_ARCH_TRAP_BRKPT.
5765
5766 2015-08-27 Pedro Alves <palves@redhat.com>
5767
5768 * proc-service.c (ps_pdwrite): Return PS_ERR/PS_OK explicily.
5769
5770 2015-08-26 Simon Marchi <simon.marchi@ericsson.com>
5771
5772 * ax.c (gdb_parse_agent_expr): Replace xmalloc-family function with
5773 the XNEW-family equivalent.
5774 (compile_bytecodes): Likewise.
5775 * dll.c (loaded_dll): Likewise.
5776 * event-loop.c (append_callback_event): Likewise.
5777 (create_file_handler): Likewise.
5778 (create_file_event): Likewise.
5779 * hostio.c (handle_open): Likewise.
5780 * inferiors.c (add_thread): Likewise.
5781 (add_process): Likewise.
5782 * linux-aarch64-low.c (aarch64_linux_new_process): Likewise.
5783 * linux-arm-low.c (arm_new_process): Likewise.
5784 (arm_new_thread): Likewise.
5785 * linux-low.c (add_to_pid_list): Likewise.
5786 (linux_add_process): Likewise.
5787 (handle_extended_wait): Likewise.
5788 (add_lwp): Likewise.
5789 (enqueue_one_deferred_signal): Likewise.
5790 (enqueue_pending_signal): Likewise.
5791 (linux_resume_one_lwp_throw): Likewise.
5792 (linux_resume_one_thread): Likewise.
5793 (linux_read_memory): Likewise.
5794 (linux_write_memory): Likewise.
5795 * linux-mips-low.c (mips_linux_new_process): Likewise.
5796 (mips_linux_new_thread): Likewise.
5797 (mips_add_watchpoint): Likewise.
5798 * linux-x86-low.c (initialize_low_arch): Likewise.
5799 * lynx-low.c (lynx_add_process): Likewise.
5800 * mem-break.c (set_raw_breakpoint_at): Likewise.
5801 (set_breakpoint): Likewise.
5802 (add_condition_to_breakpoint): Likewise.
5803 (add_commands_to_breakpoint): Likewise.
5804 (clone_agent_expr): Likewise.
5805 (clone_one_breakpoint): Likewise.
5806 * regcache.c (new_register_cache): Likewise.
5807 * remote-utils.c (look_up_one_symbol): Likewise.
5808 * server.c (queue_stop_reply): Likewise.
5809 (start_inferior): Likewise.
5810 (queue_stop_reply_callback): Likewise.
5811 (handle_target_event): Likewise.
5812 * spu-low.c (fetch_ppc_memory): Likewise.
5813 (store_ppc_memory): Likewise.
5814 * target.c (set_target_ops): Likewise.
5815 * thread-db.c (thread_db_load_search): Likewise.
5816 (try_thread_db_load_1): Likewise.
5817 * tracepoint.c (add_tracepoint): Likewise.
5818 (add_tracepoint_action): Likewise.
5819 (create_trace_state_variable): Likewise.
5820 (cmd_qtdpsrc): Likewise.
5821 (cmd_qtro): Likewise.
5822 (add_while_stepping_state): Likewise.
5823 * win32-low.c (child_add_thread): Likewise.
5824 (get_image_name): Likewise.
5825
5826 2015-08-25 Yao Qi <yao.qi@linaro.org>
5827
5828 * linux-aarch64-low.c (aarch64_linux_new_thread): Remove.
5829
5830 2015-08-25 Yao Qi <yao.qi@linaro.org>
5831
5832 * Makefile.in (aarch64-linux.o): New rule.
5833 * configure.srv (aarch64*-*-linux*): Append aarch64-linux.o to
5834 srv_tgtobj.
5835 * linux-aarch64-low.c: Include nat/aarch64-linux.h.
5836 (aarch64_init_debug_reg_state): Make it extern.
5837 (aarch64_linux_prepare_to_resume): Remove.
5838
5839 2015-08-25 Yao Qi <yao.qi@linaro.org>
5840
5841 * linux-aarch64-low.c (aarch64_linux_prepare_to_resume): Use
5842 lwp_arch_private_info and ptid_of_lwp.
5843
5844 2015-08-25 Yao Qi <yao.qi@linaro.org>
5845
5846 * linux-aarch64-low.c (aarch64_get_debug_reg_state): Add argument pid.
5847 Find proc_info by find_process_pid. All callers updated.
5848
5849 2015-08-25 Yao Qi <yao.qi@linaro.org>
5850
5851 * linux-aarch64-low.c (struct arch64_dr_update_callback_param):
5852 Remove.
5853 (debug_reg_change_callback): Remove.
5854 (aarch64_notify_debug_reg_change): Remove.
5855
5856 2015-08-25 Yao Qi <yao.qi@linaro.org>
5857
5858 * linux-aarch64-low.c (aarch64_notify_debug_reg_change):
5859 Call current_lwp_ptid.
5860
5861 2015-08-25 Yao Qi <yao.qi@linaro.org>
5862
5863 * linux-aarch64-low.c (debug_reg_change_callback): Use
5864 debug_printf.
5865
5866 2015-08-25 Yao Qi <yao.qi@linaro.org>
5867
5868 * linux-aarch64-low.c (debug_reg_change_callback): Use phex.
5869
5870 2015-08-25 Yao Qi <yao.qi@linaro.org>
5871
5872 * linux-aarch64-low.c (debug_reg_change_callback): Remove comments.
5873
5874 2015-08-25 Yao Qi <yao.qi@linaro.org>
5875
5876 * linux-aarch64-low.c (debug_reg_change_callback): Re-indent
5877 the code.
5878
5879 2015-08-25 Yao Qi <yao.qi@linaro.org>
5880
5881 * linux-aarch64-low.c (aarch64_dr_update_callback_param) <pid>:
5882 Remove.
5883 (debug_reg_change_callback): Remove argument entry and add argument
5884 lwp. Remove local variable thread. Don't print thread id in the
5885 debugging output. Don't check whether pid of thread equals to pid.
5886 (aarch64_notify_debug_reg_change): Don't set param.pid. Call
5887 iterate_over_lwps instead find_inferior.
5888
5889 2015-08-24 Pedro Alves <palves@redhat.com>
5890
5891 * inferiors.c (get_first_process): New function.
5892 * inferiors.h (get_first_process): New declaration.
5893 * remote-utils.c (read_ptid): Default to the first process in the
5894 list, instead of to the current thread's process.
5895
5896 2015-08-24 Pedro Alves <palves@redhat.com>
5897
5898 * debug.c: Include gdb_sys_time.h instead of sys/time.h.
5899 * event-loop.c: Likewise.
5900 * remote-utils.c: Likewise.
5901 * tracepoint.c: Likewise.
5902
5903 2015-08-24 Pedro Alves <palves@redhat.com>
5904
5905 * spu-low.c (spu_request_interrupt): Use lwpid_of instead of
5906 ptid_get_lwp.
5907
5908 2015-08-21 Pedro Alves <palves@redhat.com>
5909
5910 * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
5911 instead of literal 1.
5912
5913 2015-08-21 Pedro Alves <palves@redhat.com>
5914
5915 * tdesc.c (default_description): Explicitly zero-initialize.
5916
5917 2015-08-21 Pedro Alves <palves@redhat.com>
5918
5919 PR gdb/18749
5920 * inferiors.c (remove_thread): Discard any pending stop reply for
5921 this thread.
5922 * server.c (remove_all_on_match_pid): Rename to ...
5923 (remove_all_on_match_ptid): ... this. Work with a filter ptid
5924 instead of a pid.
5925 (discard_queued_stop_replies): Change parameter to a ptid. Now
5926 extern.
5927 (handle_v_kill, kill_inferior_callback, captured_main)
5928 (process_serial_event): Adjust.
5929 * server.h (discard_queued_stop_replies): Declare.
5930
5931 2015-08-21 Pedro Alves <palves@redhat.com>
5932
5933 * linux-low.c (wait_for_sigstop): Always switch to no thread
5934 selected if the previously current thread dies.
5935 * lynx-low.c (lynx_request_interrupt): Use the first thread's
5936 process instead of the current thread's.
5937 * remote-utils.c (input_interrupt): Don't check if there's no
5938 current thread.
5939 * server.c (gdb_read_memory, gdb_write_memory): If setting the
5940 current thread to the general thread fails, error out.
5941 (handle_qxfer_auxv, handle_qxfer_libraries)
5942 (handle_qxfer_libraries_svr4, handle_qxfer_siginfo)
5943 (handle_qxfer_spu, handle_qxfer_statictrace, handle_qxfer_fdpic)
5944 (handle_query): Check if there's a thread selected instead of
5945 checking whether there's any thread in the thread list.
5946 (handle_qxfer_threads, handle_qxfer_btrace)
5947 (handle_qxfer_btrace_conf): Don't error out early if there's no
5948 thread in the thread list.
5949 (handle_v_cont, myresume): Don't set the current thread to the
5950 continue thread.
5951 (process_serial_event) <Hg handling>: Also set thread_id if the
5952 previous general thread is still alive.
5953 (process_serial_event) <g/G handling>: If setting the current
5954 thread to the general thread fails, error out.
5955 * spu-low.c (spu_resume, spu_request_interrupt): Use the first
5956 thread's lwp instead of the current thread's.
5957 * target.c (set_desired_thread): If the desired thread was not
5958 found, leave the current thread pointing to NULL. Return an int
5959 (boolean) indicating success.
5960 * target.h (set_desired_thread): Change return type to int.
5961
5962 2015-08-20 Max Filippov <jcmvbkbc@gmail.com>
5963
5964 * configure.srv (xtensa*-*-linux*): Add srv_linux_thread_db=yes.
5965 * linux-xtensa-low.c (arch/xtensa.h gdb_proc_service.h): New
5966 #includes.
5967 (ps_get_thread_area): New function.
5968
5969 2015-08-19 Gary Benson <gbenson@redhat.com>
5970
5971 * hostio.c (handle_pread): Do not attempt to read more data
5972 than hostio_reply_with_data can fit in a packet.
5973
5974 2015-08-18 Joel Brobecker <brobecker@adacore.com>
5975
5976 * linux-aarch32-low.c (NT_ARM_VFP): Define if not already defined.
5977
5978 2015-08-14 Matthew Fortune <matthew.fortune@imgtec.com>
5979
5980 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP_REL.
5981
5982 2015-08-06 Pedro Alves <palves@redhat.com>
5983
5984 * tracepoint.c (expr_eval_result): Now an int.
5985
5986 2015-08-06 Pedro Alves <palves@redhat.com>
5987
5988 * gdbthread.h (struct regcache): Forward declare.
5989 (struct thread_info) <regcache_data>: Now a struct regcache
5990 pointer.
5991 * inferiors.c (inferior_regcache_data)
5992 (set_inferior_regcache_data): Now work with struct regcache
5993 pointers.
5994 * inferiors.h (struct regcache): Forward declare.
5995 (inferior_regcache_data, set_inferior_regcache_data): Now work
5996 with struct regcache pointers.
5997 * regcache.c (get_thread_regcache, regcache_invalidate_thread)
5998 (free_register_cache_thread): Remove struct regcache pointer
5999 casts.
6000
6001 2015-08-06 Pedro Alves <palves@redhat.com>
6002
6003 * server.c (captured_main): On error, print the exception message
6004 to stderr, and if run_once is set, throw a quit.
6005
6006 2015-08-06 Pedro Alves <palves@redhat.com>
6007
6008 * linux-low.c (move_out_of_jump_pad_callback): Temporarily switch
6009 the current thread.
6010
6011 2015-08-06 Pedro Alves <palves@redhat.com>
6012
6013 * linux-low.c (linux_write_memory): Rewrite debug output to avoid
6014 reading beyond the passed in buffer length.
6015
6016 2015-08-06 Pierre Langlois <pierre.langlois@arm.com>
6017
6018 * tracepoint.c (symbol_list) <required>: Remove.
6019
6020 2015-08-06 Pedro Alves <palves@redhat.com>
6021
6022 * linux-low.c (handle_extended_wait): Set the fork child's suspend
6023 count if stopping and suspending threads.
6024 (check_stopped_by_breakpoint): If stopped by trace, set the LWP's
6025 stop reason to TARGET_STOPPED_BY_SINGLE_STEP.
6026 (linux_detach): Complete an ongoing step-over.
6027 (lwp_suspended_inc, lwp_suspended_decr): New functions. Use
6028 throughout.
6029 (resume_stopped_resumed_lwps): Don't resume a suspended thread.
6030 (linux_wait_1): If passing a signal to the inferior after
6031 finishing a step-over, unsuspend and re-resume all lwps. If we
6032 see a single-step event but the thread should be continuing, don't
6033 pass the trap to gdb.
6034 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback): Use
6035 internal_error instead of gdb_assert.
6036 (enqueue_pending_signal): New function.
6037 (check_ptrace_stopped_lwp_gone): Add debug output.
6038 (start_step_over): Use internal_error instead of gdb_assert.
6039 (complete_ongoing_step_over): New function.
6040 (linux_resume_one_thread): Don't resume a suspended thread.
6041 (proceed_one_lwp): If the LWP is stepping over a breakpoint, reset
6042 it stepping.
6043
6044 2015-08-06 Pedro Alves <palves@redhat.com>
6045
6046 * linux-low.c (add_lwp): Set waitstatus to TARGET_WAITKIND_IGNORE.
6047 (linux_thread_alive): Use lwp_is_marked_dead.
6048 (extended_event_reported): Delete.
6049 (linux_wait_1): Check if waitstatus is TARGET_WAITKIND_IGNORE
6050 instead of extended_event_reported.
6051 (mark_lwp_dead): Don't set the 'dead' flag. Store the waitstatus
6052 as well.
6053 (lwp_is_marked_dead): New function.
6054 (lwp_running): Use lwp_is_marked_dead.
6055 * linux-low.h: Delete 'dead' field, and update 'waitstatus's
6056 comment.
6057
6058 2015-08-06 Pedro Alves <palves@redhat.com>
6059
6060 * linux-low.c (linux_wait_1): Move fork event output out of the
6061 !report_to_gdb check. Pass event_child->waitstatus to
6062 target_waitstatus_to_string instead of ourstatus.
6063
6064 2015-08-04 Yao Qi <yao.qi@linaro.org>
6065
6066 * linux-aarch64-low.c (aarch64_supports_tracepoints): Return 0
6067 if current_thread is 32 bit.
6068
6069 2015-08-04 Yao Qi <yao.qi@linaro.org>
6070
6071 * linux-aarch64-low.c (aarch64_supports_z_point_type): Return
6072 0 for Z_PACKET_SW_BP if it may be used in multi-arch debugging.
6073 * server.c (extended_protocol): Remove "static".
6074 * server.h (extended_protocol): Declare it.
6075
6076 2015-08-04 Yao Qi <yao.qi@linaro.org>
6077
6078 * linux-aarch64-low.c (aarch64_get_pc): Get PC register on
6079 both aarch64 and aarch32.
6080 (aarch64_set_pc): Likewise.
6081
6082 2015-08-04 Yao Qi <yao.qi@linaro.org>
6083
6084 * configure.srv (case aarch64*-*-linux*): Append arm-with-neon.o
6085 to srv_regobj and append arm-core.xml arm-vfpv3.xml and
6086 arm-with-neon.xml to srv_xmlfiles.
6087 * linux-aarch64-low.c: Include linux-aarch32-low.h.
6088 (is_64bit_tdesc): New function.
6089 (aarch64_linux_read_description): New function.
6090 (aarch64_arch_setup): Call aarch64_linux_read_description.
6091 (regs_info): Rename to regs_info_aarch64.
6092 (aarch64_regs_info): Return right regs_info.
6093 (initialize_low_arch): Call initialize_low_arch_aarch32.
6094
6095 2015-08-04 Yao Qi <yao.qi@linaro.org>
6096
6097 * configure.srv (srv_tgtobj): Add linux-aarch32-low.o.
6098 * linux-aarch32-low.c: New file.
6099 * linux-aarch32-low.h: New file.
6100 * linux-arm-low.c (arm_fill_gregset): Move it to
6101 linux-aarch32-low.c.
6102 (arm_store_gregset): Likewise.
6103 (arm_fill_vfpregset): Call arm_fill_vfpregset_num
6104 (arm_store_vfpregset): Call arm_store_vfpregset_num.
6105 (arm_arch_setup): Check if PTRACE_GETREGSET works.
6106 (regs_info): Rename to regs_info_arm.
6107 (arm_regs_info): Return regs_info_aarch32 if
6108 have_ptrace_getregset is 1 and target description is
6109 arm_with_neon or arm_with_vfpv3.
6110 (initialize_low_arch): Don't call init_registers_arm_with_neon.
6111 Call initialize_low_arch_aarch32 instead.
6112
6113 2015-08-04 Yao Qi <yao.qi@linaro.org>
6114
6115 * linux-x86-low.c (have_ptrace_getregset): Move it to ...
6116 * linux-low.c: ... here.
6117 * linux-low.h (have_ptrace_getregset): Declare it.
6118
6119 2015-08-04 Pedro Alves <palves@redhat.com>
6120
6121 * thread-db.c (struct thread_db): Use new typedefs.
6122 (try_thread_db_load_1): Define local TDB_DLSYM macro and use it in
6123 CHK calls.
6124 (disable_thread_event_reporting): Cast result of dlsym to
6125 destination function pointer type.
6126 (thread_db_mourn): Use td_ta_delete_ftype.
6127
6128 2015-08-03 Sandra Loosemore <sandra@codesourcery.com>
6129
6130 * linux-nios2-low.c (NIOS2_BREAKPOINT): Conditionalize for
6131 arch variant.
6132 (CDX_BREAKPOINT): Define for R2.
6133 (nios2_breakpoint_at): Check for CDX_BREAKPOINT when R2.
6134 (the_low_target): Add comments.
6135
6136 2015-07-30 Yao Qi <yao.qi@linaro.org>
6137
6138 * linux-arm-low.c (arm_hwcap): Remove it.
6139 (arm_read_description): New local variable arm_hwcap. Don't
6140 set arm_hwcap to zero.
6141
6142 2015-07-30 Yao Qi <yao.qi@linaro.org>
6143
6144 * linux-arm-low.c (arm_fill_wmmxregset): Don't use arm_hwcap.
6145 Use regcache->tdesc instead.
6146 (arm_store_wmmxregset): Likewise.
6147 (arm_fill_vfpregset): Likewise.
6148 (arm_store_vfpregset): Likewise.
6149
6150 2015-07-30 Yao Qi <yao.qi@linaro.org>
6151
6152 * linux-arm-low.c: Include arch/arm.h.
6153 (arm_fill_gregset): Don't use arm_num_regs and arm_regmap.
6154 (arm_store_gregset): Likewise.
6155
6156 2015-07-29 Simon Marchi <simon.marchi@ericsson.com>
6157
6158 * linux-mips-low.c (mips_linux_prepare_to_resume): Add NULL as
6159 ptrace's 4th parameter.
6160
6161 2015-07-27 Yao Qi <yao.qi@linaro.org>
6162
6163 * configure.srv (case aarch64*-*-linux*): Don't set
6164 srv_linux_usrregs.
6165
6166 2015-07-24 Pedro Alves <palves@redhat.c: Likewise.om>
6167
6168 * linux-aarch64-low.c: Include nat/gdb_ptrace.h instead of
6169 sys/ptrace.h.
6170 * linux-arm-low.c: Likewise.
6171 * linux-cris-low.c: Likewise.
6172 * linux-crisv32-low.c: Likewise.
6173 * linux-low.c: Likewise.
6174 * linux-m68k-low.c: Likewise.
6175 * linux-mips-low.c: Likewise.
6176 * linux-nios2-low.c: Likewise.
6177 * linux-s390-low.c: Likewise.
6178 * linux-sparc-low.c: Likewise.
6179 * linux-tic6x-low.c: Likewise.
6180 * linux-tile-low.c: Likewise.
6181 * linux-x86-low.c: Likewise.
6182
6183 2015-07-24 Pedro Alves <palves@redhat.com>
6184
6185 * config.in: Regenerate.
6186 * configure: Regenerate.
6187
6188 2015-07-24 Pedro Alves <palves@redhat.com>
6189
6190 * acinclude.m4: Include ../ptrace.m4.
6191 * configure.ac: Call GDB_AC_PTRACE.
6192 * config.in, configure: Regenerate.
6193
6194 2015-07-24 Yao Qi <yao.qi@linaro.org>
6195
6196 * linux-low.c (linux_create_inferior): Remove setting to
6197 proc->priv->new_inferior.
6198 (linux_attach): Likewise.
6199 (linux_low_filter_event): Likewise.
6200 * linux-low.h (struct process_info_private) <new_inferior>: Remove.
6201
6202 2015-07-24 Yao Qi <yao.qi@linaro.org>
6203
6204 * linux-low.c (linux_arch_setup): New function.
6205 (linux_low_filter_event): If proc->tdesc is NULL and
6206 proc->attached is true, call the_low_target.arch_setup.
6207 Otherwise, keep status pending, and return.
6208 (linux_resume_one_lwp_throw): Don't call get_pc if
6209 thread->while_stepping isn't NULL. Don't call
6210 get_thread_regcache if proc->tdesc is NULL.
6211 (need_step_over_p): Return 0 if proc->tdesc is NULL.
6212 (linux_target_ops): Install arch_setup.
6213 * server.c (start_inferior): Call the_target->arch_setup.
6214 * target.h (struct target_ops) <arch_setup>: New field.
6215 (target_arch_setup): New marco.
6216 * lynx-low.c (lynx_target_ops): Update.
6217 * nto-low.c (nto_target_ops): Update.
6218 * spu-low.c (spu_target_ops): Update.
6219 * win32-low.c (win32_target_ops): Update.
6220
6221 2015-07-24 Yao Qi <yao.qi@linaro.org>
6222
6223 * linux-low.c (linux_add_process): Don't set
6224 proc->priv->new_inferior.
6225 (linux_create_inferior): Set proc->priv->new_inferior to 1.
6226 (linux_attach): Likewise.
6227
6228 2015-07-24 Yao Qi <yao.qi@linaro.org>
6229
6230 * server.c (start_inferior): Code refactor.
6231
6232 2015-07-24 Yao Qi <yao.qi@linaro.org>
6233
6234 * server.c (process_serial_event): Set general_thread.
6235
6236 2015-07-21 Yao Qi <yao.qi@linaro.org>
6237
6238 * linux-aarch64-low.c (aarch64_arch_setup): Remove code and call
6239 aarch64_linux_get_debug_reg_capacity.
6240
6241 2015-07-17 Yao Qi <yao.qi@linaro.org>
6242
6243 * Makefile.in (aarch64-linux-hw-point.o): New rule.
6244 * configure.srv (srv_tgtobj): Append aarch64-linux-hw-point.o.
6245 * linux-aarch64-low.c: Include nat/aarch64-linux-hw-point.h.
6246 (AARCH64_HBP_MAX_NUM): Move to nat/aarch64-linux-hw-point.h.
6247 (AARCH64_HWP_MAX_NUM, AARCH64_HBP_ALIGNMENT): Likewise.
6248 (AARCH64_HWP_ALIGNMENT): Likewise.
6249 (AARCH64_HWP_MAX_LEN_PER_REG): Likewise.
6250 (AARCH64_DEBUG_NUM_SLOTS, AARCH64_DEBUG_ARCH): Likewise.
6251 (aarch64_num_bp_regs, aarch64_num_wp_regs): Likewise.
6252 (AARCH64_DEBUG_ARCH_V8, DR_MARK_ALL_CHANGED): Likewise.
6253 (DR_MARK_N_CHANGED, DR_CLEAR_CHANGED): Likewise.
6254 (DR_HAS_CHANGED, DR_N_HAS_CHANGE): Likewise.
6255 (struct aarch64_debug_reg_state): Likewise.
6256 (struct arch_lwp_info): Likewise.
6257 (aarch64_align_watchpoint): Likewise.
6258 (DR_CONTROL_ENABLED, DR_CONTROL_LENGTH): Likewise.
6259 (aarch64_watchpoint_length): Likewise.
6260 (aarch64_point_encode_ctrl_reg): Likewise
6261 (aarch64_point_is_aligned): Likewise.
6262 (aarch64_align_watchpoint): Likewise.
6263 (aarch64_linux_set_debug_regs):
6264 (aarch64_dr_state_insert_one_point): Likewise.
6265 (aarch64_dr_state_remove_one_point): Likewise.
6266 (aarch64_handle_breakpoint): Likewise.
6267 (aarch64_handle_aligned_watchpoint): Likewise.
6268 (aarch64_handle_unaligned_watchpoint): Likewise.
6269 (aarch64_handle_watchpoint): Likewise.
6270
6271 2015-07-17 Yao Qi <yao.qi@linaro.org>
6272
6273 * linux-aarch64-low.c (aarch64_handle_breakpoint): Add argument state
6274 and don't aarch64_get_debug_reg_state. All callers update.
6275 (aarch64_handle_aligned_watchpoint): Likewise.
6276 (aarch64_handle_unaligned_watchpoint): Likewise.
6277 (aarch64_handle_watchpoint): Likewise.
6278 (aarch64_insert_point): Call aarch64_get_debug_reg_state earlier.
6279 (aarch64_remove_point): Likewise.
6280
6281 2015-07-17 Yao Qi <yao.qi@linaro.org>
6282
6283 * linux-aarch64-low.c (aarch64_show_debug_reg_state): Use
6284 debug_printf.
6285 (aarch64_handle_unaligned_watchpoint): Likewise.
6286
6287 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6288
6289 Revert the previous 3 commits:
6290 Move gdb_regex* to common/
6291 Move linux_find_memory_regions_full & co.
6292 gdbserver build-id attribute generator
6293
6294 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6295 Jan Kratochvil <jan.kratochvil@redhat.com>
6296
6297 gdbserver build-id attribute generator.
6298 * linux-low.c (nat/linux-maps.h, search.h, rsp-low.h): Include.
6299 (ElfXX_Ehdr, ElfXX_Phdr, ElfXX_Nhdr): New.
6300 (ELFXX_FLD, ELFXX_SIZEOF, ELFXX_ROUNDUP, BUILD_ID_INVALID): New.
6301 (find_phdr): New.
6302 (get_dynamic): Use find_pdhr to traverse program headers.
6303 (struct mapping_entry, mapping_entry_s, free_mapping_entry_vec)
6304 (compare_mapping_entry_range, struct find_memory_region_callback_data)
6305 (read_build_id, find_memory_region_callback, lrfind_mapping_entry)
6306 (get_hex_build_id): New.
6307 (linux_qxfer_libraries_svr4): Add optional build-id attribute
6308 to reply XML document.
6309
6310 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6311 Jan Kratochvil <jan.kratochvil@redhat.com>
6312
6313 * target.c: Include target/target-utils.h and fcntl.h.
6314 (target_fileio_read_stralloc_1_pread, target_fileio_read_stralloc_1)
6315 (target_fileio_read_stralloc): New functions.
6316
6317 2015-07-15 Jan Kratochvil <jan.kratochvil@redhat.com>
6318
6319 * Makefile.in (OBS): Add gdb_regex.o.
6320 (gdb_regex.o): New.
6321 * config.in: Rebuilt.
6322 * configure: Rebuilt.
6323
6324 2015-07-15 Aleksandar Ristovski <aristovski@qnx.com
6325 Jan Kratochvil <jan.kratochvil@redhat.com>
6326
6327 Create empty nat/linux-maps.[ch] and common/target-utils.[ch].
6328 * Makefile.in (OBS): Add target-utils.o.
6329 (linux-maps.o, target-utils.o): New.
6330 * configure.srv (srv_linux_obj): Add linux-maps.o.
6331
6332 2015-07-15 Pierre Langlois <pierre.langlois@arm.com>
6333
6334 * linux-aarch64-low.c (aarch64_supports_range_stepping): New
6335 function, return 1.
6336 (the_low_target): Install it.
6337
6338 2015-07-14 Pedro Alves <palves@redhat.com>
6339
6340 * linux-low.c (kill_wait_lwp): Don't assert if waitpid fails.
6341 Instead, ignore ECHILD, and throw an error for other errnos.
6342
6343 2015-07-10 Pedro Alves <palves@redhat.com>
6344
6345 * event-loop.c (struct callback_event) <data>: Change type to
6346 gdb_client_data instance instead of gdb_client_data pointer.
6347 (append_callback_event): Adjust.
6348
6349 2015-07-10 Pierre Langlois <pierre.langlois@arm.com>
6350
6351 * linux-aarch64-low.c: Add comments for each linux_target_ops
6352 method. Remove comments already covered in target_ops and
6353 linux_target_ops definitions.
6354 (the_low_target): Add comments for each unimplemented method.
6355
6356 2015-07-09 Yao Qi <yao.qi@linaro.org>
6357
6358 * linux-aarch64-low.c (aarch64_regmap): Remove.
6359 (aarch64_usrregs_info): Remove.
6360 (regs_info): Set field usrregs to NULL.
6361
6362 2015-07-02 Markus Metzger <markus.t.metzger@intel.com>
6363
6364 * linux-low.c: Include "rsp-low.h"
6365 (linux_low_encode_pt_config, linux_low_encode_raw): New.
6366 (linux_low_read_btrace): Support BTRACE_FORMAT_PT.
6367 (linux_low_btrace_conf): Support BTRACE_FORMAT_PT.
6368 (handle_btrace_enable_pt): New.
6369 (handle_btrace_general_set): Support "pt".
6370 (handle_btrace_conf_general_set): Support "pt:size".
6371
6372 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6373
6374 * linux-aarch64-low.c (aarch64_supports_z_point_type): Enable for
6375 Z_PACKET_SW_BP.
6376
6377 2015-06-29 Pierre Langlois <pierre.langlois@arm.com>
6378
6379 * linux-aarch64-low.c: Remove comment about endianness.
6380 (aarch64_breakpoint): Change type to gdb_byte[]. Set to "brk #0".
6381 (aarch64_breakpoint_at): Change type of insn to gdb_byte[]. Use
6382 memcmp.
6383
6384 2015-06-24 Gary Benson <gbenson@redhat.com>
6385
6386 * linux-i386-ipa.c (stdint.h): Do not include.
6387 * lynx-i386-low.c (stdint.h): Likewise.
6388 * lynx-ppc-low.c (stdint.h): Likewise.
6389 * mem-break.c (stdint.h): Likewise.
6390 * thread-db.c (stdint.h): Likewise.
6391 * tracepoint.c (stdint.h): Likewise.
6392 * win32-low.c (stdint.h): Likewise.
6393
6394 2015-06-18 Simon Marchi <simon.marchi@ericsson.com>
6395
6396 * server.c (write_qxfer_response): Update call to
6397 remote_escape_output.
6398
6399 2015-06-15 Aleksandar Ristovski <aristovski@qnx.com
6400 Jan Kratochvil <jan.kratochvil@redhat.com>
6401
6402 Merge multiple hex conversions.
6403 * gdbreplay.c (tohex): Rename to 'fromhex'.
6404 (logchar): Use fromhex.
6405
6406 2015-06-10 Jan Kratochvil <jan.kratochvil@redhat.com>
6407
6408 * server.c (handle_qxfer_libraries): Set `version' attribute for
6409 <library-list>.
6410
6411 2015-06-10 Gary Benson <gbenson@redhat.com>
6412
6413 * target.h (struct target_ops) <multifs_open>: New field.
6414 <multifs_unlink>: Likewise.
6415 <multifs_readlink>: Likewise.
6416 * linux-low.c (nat/linux-namespaces.h): New include.
6417 (linux_target_ops): Initialize the_target->multifs_open,
6418 the_target->multifs_unlink and the_target->multifs_readlink.
6419 * hostio.h (hostio_handle_new_gdb_connection): New declaration.
6420 * hostio.c (hostio_fs_pid): New static variable.
6421 (hostio_handle_new_gdb_connection): New function.
6422 (handle_setfs): Likewise.
6423 (handle_open): Use the_target->multifs_open as appropriate.
6424 (handle_unlink): Use the_target->multifs_unlink as appropriate.
6425 (handle_readlink): Use the_target->multifs_readlink as
6426 appropriate.
6427 (handle_vFile): Handle vFile:setfs packets.
6428 * server.c (handle_query): Call hostio_handle_new_gdb_connection
6429 after target_handle_new_gdb_connection.
6430
6431 2015-06-10 Gary Benson <gbenson@redhat.com>
6432
6433 * configure.ac (AC_CHECK_FUNCS): Add setns.
6434 * config.in: Regenerate.
6435 * configure: Likewise.
6436 * Makefile.in (SFILES): Add nat/linux-namespaces.c.
6437 (linux-namespaces.o): New rule.
6438 * configure.srv (srv_linux_obj): Add linux-namespaces.o.
6439
6440 2015-06-09 Gary Benson <gbenson@redhat.com>
6441
6442 * hostio.c (handle_open): Process mode argument with
6443 fileio_to_host_mode.
6444
6445 2015-06-01 Yao Qi <yao.qi@linaro.org>
6446
6447 * linux-s390-low.c (PTRACE_GETREGSET, PTRACE_SETREGSET): Remove.
6448 * linux-x86-low.c: Likewise.
6449
6450 2015-05-28 Don Breazeal <donb@codesourcery.com>
6451
6452 * linux-low.c (handle_extended_wait): Initialize
6453 thread_info.last_resume_kind for new fork children.
6454
6455 2015-05-15 Pedro Alves <palves@redhat.com>
6456
6457 * target.h (target_handle_new_gdb_connection): Rewrite using if
6458 wrapped in do/while.
6459
6460 2015-05-14 Joel Brobecker <brobecker@adacore.com>
6461
6462 * configure.ac: Add prfpregset_t BFD_HAVE_SYS_PROCFS_TYPE check.
6463 * configure, config.in: Regenerate.
6464 * gdb_proc_service.h [HAVE_PRFPREGSET_T] (prfpregset_t):
6465 Declare typedef.
6466
6467 2015-05-12 Don Breazeal <donb@codesourcery.com>
6468
6469 * linux-low.c (handle_extended_wait): Handle PTRACE_EVENT_FORK and
6470 PTRACE_EVENT_VFORK_DONE.
6471 (linux_low_ptrace_options, extended_event_reported): Add vfork
6472 events.
6473 * remote-utils.c (prepare_resume_reply): New stop reasons "vfork"
6474 and "vforkdone" for RSP 'T' Stop Reply Packet.
6475 * server.h (report_vfork_events): Declare
6476 global variable.
6477
6478 2015-05-12 Don Breazeal <donb@codesourcery.com>
6479
6480 * linux-aarch64-low.c (aarch64_linux_new_fork): New function.
6481 (the_low_target) <new_fork>: Initialize new member.
6482 * linux-arm-low.c (arm_new_fork): New function.
6483 (the_low_target) <new_fork>: Initialize new member.
6484 * linux-low.c (handle_extended_wait): Call new target function
6485 new_fork.
6486 * linux-low.h (struct linux_target_ops) <new_fork>: New member.
6487 * linux-mips-low.c (mips_add_watchpoint): New function
6488 extracted from mips_insert_point.
6489 (the_low_target) <new_fork>: Initialize new member.
6490 (mips_linux_new_fork): New function.
6491 (mips_insert_point): Call mips_add_watchpoint.
6492 * linux-x86-low.c (x86_linux_new_fork): New function.
6493 (the_low_target) <new_fork>: Initialize new member.
6494
6495 2015-05-12 Don Breazeal <donb@codesourcery.com>
6496
6497 * linux-low.c (handle_extended_wait): Implement return value,
6498 rename argument 'event_child' to 'event_lwp', handle
6499 PTRACE_EVENT_FORK, call internal_error for unrecognized event.
6500 (linux_low_ptrace_options): New function.
6501 (linux_low_filter_event): Call linux_low_ptrace_options,
6502 use different argument fo linux_enable_event_reporting,
6503 use return value from handle_extended_wait.
6504 (extended_event_reported): New function.
6505 (linux_wait_1): Call extended_event_reported and set
6506 status to report fork events.
6507 (linux_write_memory): Add pid to debug message.
6508 (reset_lwp_ptrace_options_callback): New function.
6509 (linux_handle_new_gdb_connection): New function.
6510 (linux_target_ops): Initialize new structure member.
6511 * linux-low.h (struct lwp_info) <waitstatus>: New member.
6512 * lynx-low.c: Initialize new structure member.
6513 * remote-utils.c (prepare_resume_reply): Implement stop reason
6514 "fork" for "T" stop message.
6515 * server.c (handle_query): Call handle_new_gdb_connection.
6516 * server.h (report_fork_events): Declare global flag.
6517 * target.h (struct target_ops) <handle_new_gdb_connection>:
6518 New member.
6519 (target_handle_new_gdb_connection): New macro.
6520 * win32-low.c: Initialize new structure member.
6521
6522 2015-05-12 Don Breazeal <donb@codesourcery.com>
6523
6524 * mem-break.c (APPEND_TO_LIST): Define macro.
6525 (clone_agent_expr): New function.
6526 (clone_one_breakpoint): New function.
6527 (clone_all_breakpoints): New function.
6528 * mem-break.h: Declare new functions.
6529
6530 2015-05-12 Don Breazeal <donb@codesourcery.com>
6531
6532 * linux-low.c (linux_supports_fork_events): New function.
6533 (linux_supports_vfork_events): New function.
6534 (linux_target_ops): Initialize new structure members.
6535 (initialize_low): Call linux_check_ptrace_features.
6536 * lynx-low.c (lynx_target_ops): Initialize new structure
6537 members.
6538 * server.c (report_fork_events, report_vfork_events):
6539 New global flags.
6540 (handle_query): Add new features to qSupported packet and
6541 response.
6542 (captured_main): Initialize new global variables.
6543 * target.h (struct target_ops) <supports_fork_events>:
6544 New member.
6545 <supports_vfork_events>: New member.
6546 (target_supports_fork_events): New macro.
6547 (target_supports_vfork_events): New macro.
6548 * win32-low.c (win32_target_ops): Initialize new structure
6549 members.
6550
6551 2015-05-12 Gary Benson <gbenson@redhat.com>
6552
6553 * server.c (handle_qxfer_exec_file): Use current process
6554 if annex is empty.
6555
6556 2015-05-08 Sandra Loosemore <sandra@codesourcery.com>
6557
6558 * linux-nios2-low.c: Include elf/common.h. Adjust comments.
6559 Remove HAVE_PTRACE_GETREGS conditionals.
6560 (nios2_regsets): Use PTRACE_GETREGSET and PTRACE_SETREGSET
6561 instead of PTRACE_GETREGS and PTRACE_SETREGS.
6562
6563 2015-05-08 Yao Qi <yao.qi@linaro.org>
6564
6565 * linux-low.c (linux_supports_conditional_breakpoints): New
6566 function.
6567 (linux_target_ops): Install new target method.
6568 * lynx-low.c (lynx_target_ops): Install NULL hook for
6569 supports_conditional_breakpoints.
6570 * nto-low.c (nto_target_ops): Likewise.
6571 * spu-low.c (spu_target_ops): Likewise.
6572 * win32-low.c (win32_target_ops): Likewise.
6573 * server.c (handle_query): Check
6574 target_supports_conditional_breakpoints.
6575 * target.h (struct target_ops) <supports_conditional_breakpoints>:
6576 New field.
6577 (target_supports_conditional_breakpoints): New macro.
6578
6579 2015-05-06 Pedro Alves <palves@redhat.com>
6580
6581 PR server/18081
6582 * server.c (start_inferior): If the process exits, mourn it.
6583
6584 2015-04-21 Gary Benson <gbenson@redhat.com>
6585
6586 * hostio.c (fileio_open_flags_to_host): Factored out to
6587 fileio_to_host_openflags in common/fileio.c. Single use
6588 updated.
6589
6590 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6591
6592 * linux-xtensa-low.c (xtensa_fill_gregset)
6593 (xtensa_store_gregset): Check XCHAL_HAVE_LOOPS instead of
6594 XCHAL_HAVE_LOOP.
6595
6596 2015-04-17 Max Filippov <jcmvbkbc@gmail.com>
6597
6598 * linux-xtensa-low.c (xtensa_usrregs_info): Remove.
6599 (regs_info): Replace usrregs pointer with NULL.
6600
6601 2015-04-17 Gary Benson <gbenson@redhat.com>
6602
6603 * target.h (struct target_ops) <pid_to_exec_file>: New field.
6604 * linux-low.c (linux_target_ops): Initialize pid_to_exec_file.
6605 * server.c (handle_qxfer_exec_file): New function.
6606 (qxfer_packets): Add exec-file entry.
6607 (handle_query): Report qXfer:exec-file:read as supported packet.
6608
6609 2015-04-14 Romain Naour <romain.naour@openwide.fr> (tiny change)
6610
6611 * linux-low.c (linux_read_offsets): Remove get_thread_lwp.
6612
6613 2015-04-09 Gary Benson <gbenson@redhat.com>
6614
6615 * hostio-errno.c (errno_to_fileio_error): Remove function.
6616 Update caller to use remote_fileio_to_fio_error.
6617
6618 2015-04-09 Yao Qi <yao.qi@linaro.org>
6619
6620 * linux-low.c (linux_insert_point): Call
6621 insert_memory_breakpoint if TYPE is raw_bkpt_type_sw.
6622 (linux_remove_point): Call remove_memory_breakpoint if type is
6623 raw_bkpt_type_sw.
6624 * linux-x86-low.c (x86_insert_point): Don't call
6625 insert_memory_breakpoint.
6626 (x86_remove_point): Don't call remove_memory_breakpoint.
6627
6628 2015-04-01 Pedro Alves <palves@redhat.com>
6629 Cleber Rosa <crosa@redhat.com>
6630
6631 * server.c (gdbserver_usage): Reorganize and extend the usage
6632 message.
6633
6634 2015-03-24 Pedro Alves <palves@redhat.com>
6635
6636 * linux-low.c (check_stopped_by_breakpoint): Tweak debug log
6637 output. Also dump TRAP_TRACE.
6638 (linux_low_filter_event): In debug output, distinguish a
6639 resume_stop SIGSTOP from a delayed SIGSTOP.
6640
6641 2015-03-24 Gary Benson <gbenson@redhat.com>
6642
6643 * linux-x86-low.c (x86_linux_new_thread): Moved to
6644 nat/x86-linux.c.
6645 (x86_linux_prepare_to_resume): Likewise.
6646
6647 2015-03-24 Gary Benson <gbenson@redhat.com>
6648
6649 * Makefile.in (x86-linux-dregs.o): New rule.
6650 * configure.srv: Add x86-linux-dregs.o to relevant targets.
6651 * linux-x86-low.c: Include nat/x86-linux-dregs.h.
6652 (u_debugreg_offset): Moved to nat/x86-linux-dregs.c.
6653 (x86_linux_dr_get): Likewise.
6654 (x86_linux_dr_set): Likewise.
6655 (update_debug_registers_callback): Likewise.
6656 (x86_linux_dr_set_addr): Likewise.
6657 (x86_linux_dr_get_addr): Likewise.
6658 (x86_linux_dr_set_control): Likewise.
6659 (x86_linux_dr_get_control): Likewise.
6660 (x86_linux_dr_get_status): Likewise.
6661 (x86_linux_update_debug_registers): Likewise.
6662
6663 2015-03-24 Gary Benson <gbenson@redhat.com>
6664
6665 * linux-x86-low.c (x86_linux_update_debug_registers):
6666 New function, factored out from...
6667 (x86_linux_prepare_to_resume): ...this.
6668
6669 2015-03-24 Gary Benson <gbenson@redhat.com>
6670
6671 * linux-x86-low.c (x86_linux_dr_get): Update comments.
6672 (x86_linux_dr_set): Likewise.
6673 (update_debug_registers_callback): Likewise.
6674 (x86_linux_dr_set_addr): Likewise.
6675 (x86_linux_dr_get_addr): Likewise.
6676 (x86_linux_dr_set_control): Likewise.
6677 (x86_linux_dr_get_control): Likewise.
6678 (x86_linux_dr_get_status): Likewise.
6679 (x86_linux_prepare_to_resume): Likewise.
6680
6681 2015-03-24 Gary Benson <gbenson@redhat.com>
6682
6683 * linux-x86-low.c (x86_linux_dr_get): Add assertion.
6684 Use perror_with_name. Pass string through gettext.
6685 (x86_linux_dr_set): Likewise.
6686
6687 2015-03-24 Gary Benson <gbenson@redhat.com>
6688
6689 * linux-x86-low.c (x86_dr_low_set_addr): Rename to...
6690 (x86_linux_dr_set_addr): ...this.
6691 (x86_dr_low_get_addr): Rename to...
6692 (x86_linux_dr_get_addr): ...this.
6693 (x86_dr_low_set_control): Rename to...
6694 (x86_linux_dr_set_control): ...this.
6695 (x86_dr_low_get_control): Rename to...
6696 (x86_linux_dr_get_control): ...this.
6697 (x86_dr_low_get_status): Rename to...
6698 (x86_linux_dr_get_status): ...this.
6699 (x86_dr_low): Update with new function names.
6700
6701 2015-03-24 Gary Benson <gbenson@redhat.com>
6702
6703 * Makefile.in (x86-linux.o): New rule.
6704 * configure.srv: Add x86-linux.o to relevant targets.
6705 * linux-low.c (lwp_set_arch_private_info): New function.
6706 (lwp_arch_private_info): Likewise.
6707 * linux-x86-low.c: Include nat/x86-linux.h.
6708 (arch_lwp_info): Removed structure.
6709 (update_debug_registers_callback):
6710 Use lwp_set_debug_registers_changed.
6711 (x86_linux_prepare_to_resume): Use lwp_debug_registers_changed
6712 and lwp_set_debug_registers_changed.
6713 (x86_linux_new_thread): Use lwp_set_debug_registers_changed.
6714
6715 2015-03-24 Gary Benson <gbenson@redhat.com>
6716
6717 * linux-low.h (linux_target_ops) <new_thread>: Changed signature.
6718 * linux-arm-low.c (arm_new_thread): Likewise.
6719 * linux-aarch64-low.c (aarch64_linux_new_thread): Likewise.
6720 * linux-mips-low.c (mips_linux_new_thread): Likewise.
6721 * linux-x86-low.c (x86_linux_new_thread): Likewise.
6722 * linux-low.c (add_lwp): Update the_low_target.new_thread call.
6723
6724 2015-03-24 Gary Benson <gbenson@redhat.com>
6725
6726 * linux-low.c (ptid_of_lwp): New function.
6727 (lwp_is_stopped): Likewise.
6728 (lwp_stop_reason): Likewise.
6729 * linux-x86-low.c (update_debug_registers_callback):
6730 Use lwp_is_stopped.
6731 (x86_linux_prepare_to_resume): Use ptid_of_lwp and
6732 lwp_stop_reason.
6733
6734 2015-03-24 Gary Benson <gbenson@redhat.com>
6735
6736 * linux-low.h (linux_stop_lwp): Remove declaration.
6737
6738 2015-03-24 Gary Benson <gbenson@redhat.com>
6739
6740 * linux-low.h: Include nat/linux-nat.h.
6741 * linux-low.c (iterate_over_lwps_args): New structure.
6742 (iterate_over_lwps_filter): New function.
6743 (iterate_over_lwps): Likewise.
6744 * linux-x86-low.c (update_debug_registers_callback):
6745 Update signature to what iterate_over_lwps expects.
6746 Remove PID check that iterate_over_lwps now performs.
6747 (x86_dr_low_set_addr): Use iterate_over_lwps.
6748 (x86_dr_low_set_control): Likewise.
6749
6750 2015-03-24 Gary Benson <gbenson@redhat.com>
6751
6752 * linux-x86-low.c (x86_debug_reg_state): New function.
6753 (x86_linux_prepare_to_resume): Use the above.
6754
6755 2015-03-24 Gary Benson <gbenson@redhat.com>
6756
6757 * linux-low.c (current_lwp_ptid): New function.
6758 * linux-x86-low.c: Include nat/linux-nat.h.
6759 (x86_dr_low_get_addr): Use current_lwp_ptid.
6760 (x86_dr_low_get_control): Likewise.
6761 (x86_dr_low_get_status): Likewise.
6762
6763 2015-03-20 Pedro Alves <palves@redhat.com>
6764
6765 * tracepoint.c (cmd_qtstatus): Make "str" const.
6766
6767 2015-03-20 Pedro Alves <palves@redhat.com>
6768
6769 * server.c (handle_general_set): Make "req_str" const.
6770
6771 2015-03-19 Pedro Alves <palves@redhat.com>
6772
6773 * linux-low.c (linux_resume_one_lwp): Rename to ...
6774 (linux_resume_one_lwp_throw): ... this. Don't handle ESRCH here,
6775 instead call perror_with_name.
6776 (check_ptrace_stopped_lwp_gone): New function.
6777 (linux_resume_one_lwp): Reimplement as wrapper around
6778 linux_resume_one_lwp_throw that swallows errors if the LWP is
6779 gone.
6780
6781 2015-03-19 Pedro Alves <palves@redhat.com>
6782
6783 * linux-low.c (count_events_callback, select_event_lwp_callback):
6784 No longer check whether the thread has resume_stop as last resume
6785 kind.
6786
6787 2015-03-19 Pedro Alves <palves@redhat.com>
6788
6789 * linux-low.c (count_events_callback, select_event_lwp_callback):
6790 Use the lwp's status_pending_p field, not the thread's.
6791
6792 2015-03-19 Pedro Alves <palves@redhat.com>
6793
6794 * linux-low.c (select_event_lwp_callback): Update comments to
6795 no longer mention SIGTRAP.
6796
6797 2015-03-18 Gary Benson <gbenson@redhat.com>
6798
6799 * server.c (handle_query): Do not report vFile:fstat as supported.
6800
6801 2015-03-11 Gary Benson <gbenson@redhat.com>
6802
6803 * hostio.c (sys/types.h): New include.
6804 (sys/stat.h): Likewise.
6805 (common-remote-fileio.h): Likewise.
6806 (handle_fstat): New function.
6807 (handle_vFile): Handle vFile:fstat packets.
6808
6809 2015-03-11 Gary Benson <gbenson@redhat.com>
6810
6811 * configure.ac (AC_CHECK_MEMBERS): Add checks for
6812 struct stat.st_blocks and struct stat.st_blksize.
6813 * configure: Regenerate.
6814 * config.in: Likewise.
6815 * Makefile.in (SFILES): Add common/common-remote-fileio.c.
6816 (OBS): Add common-remote-fileio.o.
6817 (common-remote-fileio.o): New rule.
6818
6819 2015-03-09 Pedro Alves <palves@redhat.com>
6820
6821 * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
6822 'struct sockaddr' pointer in 'accept' call.
6823
6824 2015-03-09 Pedro Alves <palves@redhat.com>
6825
6826 Revert:
6827 2015-03-07 Pedro Alves <palves@redhat.com>
6828 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6829 or <winsock2.h> here. Instead include "gdb_socket.h".
6830 (remote_open): Use union gdb_sockaddr_u.
6831 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6832 or <winsock2.h> here. Instead include "gdb_socket.h".
6833 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6834 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6835 or <sys/un.h>.
6836 (init_named_socket, gdb_agent_helper_thread): Use union
6837 gdb_sockaddr_u.
6838
6839 2015-03-07 Pedro Alves <palves@redhat.com>
6840
6841 * configure.ac (build_warnings): Move
6842 -Wdeclaration-after-statement to the C-specific set.
6843 * configure: Regenerate.
6844
6845 2015-03-07 Pedro Alves <palves@redhat.com>
6846
6847 * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>,
6848 or <winsock2.h> here. Instead include "gdb_socket.h".
6849 (remote_open): Use union gdb_sockaddr_u.
6850 * remote-utils.c: No longer include <netinet/in.h>, <sys/socket.h>
6851 or <winsock2.h> here. Instead include "gdb_socket.h".
6852 (handle_accept_event, remote_prepare): Use union gdb_sockaddr_u.
6853 * tracepoint.c: Include "gdb_socket.h" instead of <sys/socket.h>
6854 or <sys/un.h>.
6855 (init_named_socket, gdb_agent_helper_thread): Use union
6856 gdb_sockaddr_u.
6857
6858 2015-03-07 Pedro Alves <palves@redhat.com>
6859
6860 Adjust all callers of TRY_CATCH to use TRY/CATCH/END_CATCH
6861 instead.
6862
6863 2015-03-06 Yao Qi <yao.qi@linaro.org>
6864
6865 * linux-aarch64-low.c (aarch64_insert_point): Use
6866 show_debug_regs as a boolean.
6867 (aarch64_remove_point): Likewise.
6868
6869 2015-03-05 Pedro Alves <palves@redhat.com>
6870
6871 * lynx-low.c (lynx_target_ops): Install NULL hooks for
6872 stopped_by_sw_breakpoint, supports_stopped_by_sw_breakpoint,
6873 stopped_by_hw_breakpoint, supports_stopped_by_hw_breakpoint.
6874 * nto-low.c (nto_target_ops): Likewise.
6875 * spu-low.c (spu_target_ops): Likewise.
6876 * win32-low.c (win32_target_ops): Likewise.
6877
6878 2015-03-04 Pedro Alves <palves@redhat.com>
6879
6880 * linux-low.c (check_stopped_by_breakpoint) [USE_SIGTRAP_SIGINFO]:
6881 Decide whether a breakpoint triggered based on the SIGTRAP's
6882 siginfo.si_code.
6883 (thread_still_has_status_pending_p) [USE_SIGTRAP_SIGINFO]: Don't check whether a
6884 breakpoint is inserted if relying on SIGTRAP's siginfo.si_code.
6885 (linux_low_filter_event): Check for breakpoints before checking
6886 watchpoints.
6887 (linux_wait_1): Don't re-increment the PC if relying on SIGTRAP's
6888 siginfo.si_code.
6889 (linux_stopped_by_sw_breakpoint)
6890 (linux_supports_stopped_by_sw_breakpoint)
6891 (linux_stopped_by_hw_breakpoint)
6892 (linux_supports_stopped_by_hw_breakpoint): New functions.
6893 (linux_target_ops): Install new target methods.
6894
6895 2015-03-04 Pedro Alves <palves@redhat.com>
6896
6897 * remote-utils.c (prepare_resume_reply): Report swbreak/hbreak.
6898 * server.c (swbreak_feature, hwbreak_feature): New globals.
6899 (handle_query) <qSupported>: Handle "swbreak+" and "hwbreak+".
6900 (captured_main): Clear swbreak_feature and hwbreak_feature.
6901 * server.h (swbreak_feature, hwbreak_feature): Declare.
6902 * target.h (struct target_ops) <stopped_by_sw_breakpoint,
6903 supports_stopped_by_sw_breakpoint, stopped_by_hw_breakpoint,
6904 supports_stopped_by_hw_breakpoint>: New fields.
6905 (target_supports_stopped_by_sw_breakpoint)
6906 (target_stopped_by_sw_breakpoint)
6907 (target_supports_stopped_by_hw_breakpoint)
6908 (target_stopped_by_hw_breakpoint): Declare.
6909
6910 2015-03-04 Pedro Alves <palves@redhat.com>
6911
6912 enum lwp_stop_reason -> enum target_stop_reason
6913 * linux-low.c (check_stopped_by_breakpoint): Adjust.
6914 (thread_still_has_status_pending_p, check_stopped_by_watchpoint)
6915 (linux_wait_1, stuck_in_jump_pad_callback)
6916 (move_out_of_jump_pad_callback, linux_resume_one_lwp)
6917 (linux_stopped_by_watchpoint):
6918 * linux-low.h (enum lwp_stop_reason): Delete.
6919 (struct lwp_info) <stop_reason>: Now an enum target_stop_reason.
6920 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
6921
6922 2015-03-04 Yao Qi <yao.qi@linaro.org>
6923
6924 * Makefile.in (SFILES): Add linux-aarch64-low.c.
6925
6926 2015-03-03 Gary Benson <gbenson@redhat.com>
6927
6928 * hostio.c (handle_vFile): Fix prefix lengths.
6929
6930 2015-03-03 Markus Metzger <markus.t.metzger@intel.com>
6931
6932 * linux-low.c (linux_low_enable_btrace): Do not overwrite non-zero
6933 ptr_bits.
6934
6935 2015-03-02 Andreas Arnez <arnez@linux.vnet.ibm.com>
6936
6937 * Makefile.in (s390-vx-linux64.c, s390-tevx-linux64.c)
6938 (s390x-vx-linux64.c, s390x-tevx-linux64.c): New rules.
6939 (clean): Add "rm -f" for above C files.
6940 * configure.srv (srv_regobj): Add s390-vx-linux64.o,
6941 s390-tevx-linux64.o, s390x-vx-linux64.o, and s390x-tevx-linux64.o.
6942 (srv_xmlfiles): Add s390-vx-linux64.xml, s390-tevx-linux64.xml,
6943 s390x-vx-linux64.xml, s390x-tevx-linux64.xml, and s390-vx.xml.
6944 * linux-s390-low.c (HWCAP_S390_VX): New macro.
6945 (init_registers_s390_vx_linux64, init_registers_s390_tevx_linux64)
6946 (init_registers_s390x_vx_linux64)
6947 (init_registers_s390x_tevx_linux64)
6948 (tdesc_s390_vx_linux64, tdesc_s390_tevx_linux64)
6949 (tdesc_s390x_vx_linux64, tdesc_s390x_tevx_linux64): New extern
6950 declarations.
6951 (s390_fill_vxrs_low, s390_store_vxrs_low, s390_fill_vxrs_high)
6952 (s390_store_vxrs_high): New functions.
6953 (s390_regsets): Add entries for NT_S390_VXRS_LOW and
6954 NT_S390_VXRS_HIGH.
6955 (s390_arch_setup): Add logic for selecting one of the new target
6956 descriptions. Activate the new vector regsets if applicable.
6957 (initialize_low_arch): Also invoke init_registers_s390_vx_linux64,
6958 init_registers_s390_tevx_linux64, init_registers_s390x_vx_linux64,
6959 and init_registers_s390x_tevx_linux64.
6960
6961 2015-03-01 Pedro Alves <palves@redhat.com>
6962
6963 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Constify 'raw_regs'
6964 parameter.
6965
6966 2015-02-27 Pedro Alves <palves@redhat.com>
6967
6968 * linux-x86-low.c (u_debugreg_offset): New function.
6969 (x86_linux_dr_get, x86_linux_dr_set): Use it.
6970
6971 2015-02-27 Pedro Alves <palves@redhat.com>
6972
6973 * gdb_proc_service.h: Wrap with EXTERN_C_PUSH/EXTERN_C_POP.
6974 [!HAVE_PROC_SERVICE_H] (struct ps_prochandle): Forward declare.
6975 [!HAVE_PROC_SERVICE_H] (ps_pdread, ps_pdwrite, ps_ptread)
6976 ps_ptwrite, ps_lgetregs, ps_lsetregs, ps_lgetfpregs)
6977 (ps_lsetfpregs, ps_getpid)
6978 (ps_get_thread_area, ps_pglobal_lookup, ps_pstop, ps_pcontinue)
6979 (ps_lstop, ps_lcontinue, ps_lgetxregsize, ps_lgetxregs)
6980 (ps_lsetxregs, ps_plog): Declare.
6981
6982 2015-02-27 Pedro Alves <palves@redhat.com>
6983
6984 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Use
6985 IP_AGENT_EXPORT_FUNC.
6986 * linux-i386-ipa.c (gdb_agent_get_raw_reg): Use
6987 IP_AGENT_EXPORT_FUNC.
6988 * tracepoint.c (ATTR_USED, ATTR_NOINLINE, ATTR_CONSTRUCTOR)
6989 (IP_AGENT_EXPORT): Delete.
6990 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
6991 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
6992 (gdb_trampoline_buffer_error, collecting, gdb_collect)
6993 (stop_tracing, flush_trace_buffer, about_to_request_buffer_space)
6994 (trace_buffer_is_full, stopping_tracepoint, expr_eval_result)
6995 (error_tracepoint, tracepoints, tracing, trace_buffer_ctrl)
6996 (trace_buffer_ctrl_curr, trace_buffer_lo, trace_buffer_hi)
6997 (traceframe_read_count, traceframe_write_count)
6998 (traceframes_created, trace_state_variables, get_raw_reg)
6999 (get_trace_state_variable_value, set_trace_state_variable_value)
7000 (ust_loaded, helper_thread_id, cmd_buf): Use
7001 IPA_SYM_EXPORTED_NAME.
7002 (stop_tracing, flush_trace_buffer): Use IP_AGENT_EXPORT_FUNC.
7003 (tracepoints) Use IP_AGENT_EXPORT_VAR.
7004 (stopping_tracepoint, trace_buffer_is_full, expr_eval_result): Use
7005 IP_AGENT_EXPORT_VAR and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7006 (last_tracepoint): Move into !IN_PROCESS_AGENT block.
7007 (error_tracepoint): Use IP_AGENT_EXPORT_VAR and wrap in
7008 EXTERN_C_PUSH/EXTERN_C_POP.
7009 (trace_state_variables): Use IP_AGENT_EXPORT_VAR.
7010 (trace_buffer_lo, trace_buffer_hi): Use IP_AGENT_EXPORT_VAR and
7011 wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7012 (trace_buffer_ctrl, trace_buffer_ctrl_curr)
7013 (traceframe_write_count, traceframe_read_count)
7014 (traceframes_created, tracing): Use IP_AGENT_EXPORT_VAR.
7015 (about_to_request_buffer_space, get_trace_state_variable_value)
7016 (set_trace_state_variable_value): Use IP_AGENT_EXPORT_FUNC.
7017 (collecting): Use IP_AGENT_EXPORT_VAR and wrap in
7018 EXTERN_C_PUSH/EXTERN_C_POP.
7019 (gdb_collect): Use IP_AGENT_EXPORT_FUNC.
7020 (ust_loaded, cmd_buf): Use IP_AGENT_EXPORT_VAR.
7021 (helper_thread_id, gdb_agent_capability): Use IP_AGENT_EXPORT_VAR
7022 and wrap in EXTERN_C_PUSH/EXTERN_C_POP.
7023 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
7024 (gdb_trampoline_buffer, gdb_trampoline_buffer_end)
7025 (gdb_trampoline_buffer_error): Use IP_AGENT_EXPORT_VAR.
7026 * tracepoint.h (ATTR_USED, ATTR_NOINLINE, EXPORTED_SYMBOL):
7027 Define.
7028 (IP_AGENT_EXPORT_FUNC, IP_AGENT_EXPORT_VAR)
7029 (IP_AGENT_EXPORT_VAR_DECL): Define.
7030 (tracing): Declare.
7031 (gdb_agent_get_raw_reg): Declare.
7032
7033 2015-02-27 Tom Tromey <tromey@redhat.com>
7034 Pedro Alves <palves@redhat.com>
7035
7036 Rename symbols whose names are reserved C++ keywords throughout.
7037
7038 2015-02-27 Pedro Alves <palves@redhat.com>
7039
7040 * Makefile.in (COMPILER): New, get it from autoconf.
7041 (CXX): Get from autoconf instead.
7042 (COMPILE.pre): Use COMPILER.
7043 (CC-LD): Rename to ...
7044 (CC_LD): ... this. Use COMPILER.
7045 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT), $(IPA_LIB)): Adjust.
7046 (CXX_FOR_TARGET): Default to g++ instead of gcc.
7047 * acinclude.m4: Include build-with-cxx.m4.
7048 * configure.ac: Call AC_PROG_CXX and GDB_AC_BUILD_WITH_CXX.
7049 Disable -Werror by default if building in C++ mode.
7050 (build_warnings): Add -Wno-sign-compare, -Wno-write-strings and
7051 -Wno-narrowing in C++ mode. Run supported-warning-flags tests with
7052 the C++ compiler. Save/restore CXXFLAGS too.
7053 * configure: Regenerate.
7054
7055 2015-02-27 Pedro Alves <palves@redhat.com>
7056
7057 * acinclude.m4: Include libiberty.m4.
7058 * configure.ac: Call libiberty_INIT.
7059 * config.in, configure: Regenerate.
7060
7061 2015-02-26 Pedro Alves <palves@redhat.com>
7062
7063 * linux-low.c (linux_wait_1): When incrementing the PC past a
7064 program breakpoint always use the_low_target.breakpoint_len as
7065 increment, rather than the maximum between that and
7066 the_low_target.decr_pc_after_break.
7067
7068 2015-02-23 Pedro Alves <palves@redhat.com>
7069
7070 * linux-low.c (check_stopped_by_breakpoint): Don't check if the
7071 thread was doing a step-over; always adjust the PC if
7072 we stepped over a permanent breakpoint.
7073 (linux_wait_1): If we stepped over breakpoint that was on top of a
7074 permanent breakpoint, manually advance the PC past it.
7075
7076 2015-02-23 Pedro Alves <palves@redhat.com>
7077
7078 * linux-x86-low.c (REGSIZE): Define in both 32-bit and 64-bit
7079 modes.
7080 (x86_fill_gregset, x86_store_gregset): Use it when handling
7081 $orig_eax.
7082
7083 2015-02-20 Pedro Alves <palves@redhat.com>
7084
7085 * thread-db.c: Include "nat/linux-procfs.h".
7086 (thread_db_init): Skip listing new threads if the kernel supports
7087 PTRACE_EVENT_CLONE and /proc/PID/task/ is accessible.
7088
7089 2015-02-20 Pedro Alves <palves@redhat.com>
7090
7091 * linux-low.c (status_pending_p_callback): Use ptid_match.
7092
7093 2015-02-19 Antoine Tremblay <antoine.tremblay@ericsson.com>
7094
7095 PR breakpoints/16812
7096 * linux-low.c (wstatus_maybe_breakpoint): Remove.
7097 (linux_low_filter_event): Update wstatus_maybe_breakpoint name.
7098 (linux_wait_1): Report SIGTRAP,SIGILL,SIGSEGV.
7099
7100 2015-02-10 Antoine Tremblay <antoine.tremblay@ericsson.com>
7101
7102 PR breakpoints/15956
7103 * tracepoint.c (cmd_qtinit): Add check for current_thread.
7104
7105 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7106
7107 * linux-low.c (linux_low_btrace_conf): Print size.
7108 * server.c (handle_btrace_conf_general_set): New.
7109 (hanle_general_set): Call handle_btrace_conf_general_set.
7110 (handle_query): Report Qbtrace-conf:bts:size as supported.
7111
7112 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7113
7114 * linux-low.c (linux_low_enable_btrace): Update parameters.
7115 (linux_low_btrace_conf): New.
7116 (linux_target_ops)<to_btrace_conf>: Initialize.
7117 * server.c (current_btrace_conf): New.
7118 (handle_btrace_enable): Rename to ...
7119 (handle_btrace_enable_bts): ... this. Pass &current_btrace_conf
7120 to target_enable_btrace. Update comment. Update users.
7121 (handle_qxfer_btrace_conf): New.
7122 (qxfer_packets): Add btrace-conf entry.
7123 (handle_query): Report qXfer:btrace-conf:read as supported packet.
7124 * target.h (target_ops)<enable_btrace>: Update parameters and comment.
7125 (target_ops)<read_btrace_conf>: New.
7126 (target_enable_btrace): Update parameters.
7127 (target_read_btrace_conf): New.
7128
7129 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7130
7131 * server.c (handle_btrace_general_set): Remove call to
7132 target_supports_btrace.
7133 (supported_btrace_packets): New.
7134 (handle_query): Call supported_btrace_packets.
7135 * target.h: include btrace-common.h.
7136 (btrace_target_info): Removed.
7137 (supports_btrace, target_supports_btrace): Update parameters.
7138
7139 2015-02-09 Markus Metzger <markus.t.metzger@intel.com>
7140
7141 * Makefile.in (SFILES): Add common/btrace-common.c.
7142 (OBS): Add common/btrace-common.o.
7143 (btrace-common.o): Add build rules.
7144 * linux-low: Include btrace-common.h.
7145 (linux_low_read_btrace): Use struct btrace_data. Call
7146 btrace_data_init and btrace_data_fini.
7147
7148 2015-02-06 Pedro Alves <palves@redhat.com>
7149
7150 * thread-db.c (find_new_threads_callback): Add debug output.
7151
7152 2015-02-04 Pedro Alves <palves@redhat.com>
7153
7154 * linux-low.c (handle_extended_wait): Don't resume LWPs here.
7155 (resume_stopped_resumed_lwps): New function.
7156 (linux_wait_for_event_filtered): Use it.
7157
7158 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7159
7160 * Makefile.in (SFILES): Add linux-personality.c.
7161 (linux-personality.o): New rule.
7162 * configure.srv (srv_linux_obj): Add linux-personality.o to the
7163 list of objects to be built.
7164 * linux-low.c: Include nat/linux-personality.h.
7165 (linux_create_inferior): Remove code to disable address space
7166 randomization (moved to ../nat/linux-personality.c). Create
7167 cleanup to disable address space randomization.
7168
7169 2015-01-15 Sergio Durigan Junior <sergiodj@redhat.com>
7170
7171 * Makefile.in (posix-strerror.o): New rule.
7172 (mingw-strerror.o): Likewise.
7173 * configure: Regenerated.
7174 * configure.ac: Source file ../common/common.host. Initialize new
7175 variable srv_host_obs. Add srv_host_obs to GDBSERVER_DEPFILES.
7176
7177 2015-01-14 Yao Qi <yao@codesourcery.com>
7178
7179 * Makefile.in (SFILES): Add nat/ppc-linux.c.
7180 (ppc-linux.o): New rule.
7181 * configure.srv (powerpc*-*-linux*): Add ppc-linux.o.
7182 * configure.ac: AC_CHECK_FUNCS(getauxval).
7183 * config.in: Re-generated.
7184 * configure: Re-generated.
7185 * linux-ppc-low.c (ppc_arch_setup) [__powerpc64__]: Call
7186 ppc64_64bit_inferior_p
7187
7188 2015-01-14 Yao Qi <yao@codesourcery.com>
7189
7190 * linux-ppc-low.c: Include "nat/ppc-linux.h".
7191 (PPC_FEATURE_HAS_VSX): Move to nat/ppc-linux.h.
7192 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Likewise.
7193 (PT_ORIG_R3, PT_TRAP): Likewise.
7194 (PTRACE_GETVSXREGS, PTRACE_SETVSXREGS): Likewise.
7195 (PTRACE_GETVRREGS, PTRACE_SETVRREGS): Likewise.
7196 (PTRACE_GETEVRREGS, PTRACE_SETEVRREGS): Likewise.
7197
7198 2015-01-10 Joel Brobecker <brobecker@adacore.com>
7199
7200 * i387-fp.c (i387_cache_to_xsave): In look over
7201 num_avx512_zmmh_high_registers, replace use of struct i387_xsave
7202 zmmh_low_space field by use of zmmh_high_space.
7203
7204 2015-01-09 Pedro Alves <palves@redhat.com>
7205
7206 * linux-low.c (step_over_bkpt): Move higher up in the file.
7207 (handle_extended_wait): Don't store the stop_pc here.
7208 (get_stop_pc): Adjust comments and rename to ...
7209 (check_stopped_by_breakpoint): ... this. Record whether the LWP
7210 stopped for a software breakpoint or hardware breakpoint.
7211 (thread_still_has_status_pending_p): New function.
7212 (status_pending_p_callback): Use
7213 thread_still_has_status_pending_p. If the event is no longer
7214 interesting, resume the LWP.
7215 (handle_tracepoints): Add assert.
7216 (maybe_move_out_of_jump_pad): Remove cancel_breakpoints call.
7217 (wstatus_maybe_breakpoint): New function.
7218 (cancel_breakpoint): Delete function.
7219 (check_stopped_by_watchpoint): New function, factored out from
7220 linux_low_filter_event.
7221 (lp_status_maybe_breakpoint): Delete function.
7222 (linux_low_filter_event): Remove filter_ptid argument.
7223 Leave thread group exits pending here. Store the LWP's stop PC.
7224 Always leave events pending.
7225 (linux_wait_for_event_filtered): Pull all events out of the
7226 kernel, and leave them all pending.
7227 (count_events_callback, select_event_lwp_callback): Consider all
7228 events.
7229 (cancel_breakpoints_callback, linux_cancel_breakpoints): Delete.
7230 (select_event_lwp): Only give preference to the stepping LWP in
7231 all-stop mode. Adjust comments.
7232 (ignore_event): New function.
7233 (linux_wait_1): Delete 'retry' label. Use ignore_event. Remove
7234 references to cancel_breakpoints. Adjust to renames. Also give
7235 equal priority to all LWPs that have had events in non-stop mode.
7236 If reporting a software breakpoint event, unadjust the LWP's PC.
7237 (linux_wait): If linux_wait_1 returned an ignored event, retry.
7238 (stuck_in_jump_pad_callback, move_out_of_jump_pad_callback):
7239 Adjust.
7240 (linux_resume_one_lwp): Store the LWP's PC. Adjust.
7241 (resume_status_pending_p): Use thread_still_has_status_pending_p.
7242 (linux_stopped_by_watchpoint): Adjust.
7243 (linux_target_ops): Remove reference to linux_cancel_breakpoints.
7244 * linux-low.h (enum lwp_stop_reason): New.
7245 (struct lwp_info) <stop_pc>: Adjust comment.
7246 <stopped_by_watchpoint>: Delete field.
7247 <stop_reason>: New field.
7248 * linux-x86-low.c (x86_linux_prepare_to_resume): Adjust.
7249 * mem-break.c (software_breakpoint_inserted_here)
7250 (hardware_breakpoint_inserted_here): New function.
7251 * mem-break.h (software_breakpoint_inserted_here)
7252 (hardware_breakpoint_inserted_here): Declare.
7253 * target.h (struct target_ops) <cancel_breakpoints>: Remove field.
7254 (cancel_breakpoints): Delete.
7255 * tracepoint.c (clear_installed_tracepoints, stop_tracing)
7256 (upload_fast_traceframes): Remove references to
7257 cancel_breakpoints.
7258
7259 2015-01-09 Pedro Alves <palves@redhat.com>
7260
7261 * thread-db.c (find_new_threads_callback): Ignore thread if the
7262 kernel thread ID is -1.
7263
7264 2015-01-09 Pedro Alves <palves@redhat.com>
7265
7266 * linux-low.c (linux_attach_fail_reason_string): Move to
7267 nat/linux-ptrace.c, and rename.
7268 (linux_attach_lwp): Update comment.
7269 (attach_proc_task_lwp_callback): New function.
7270 (linux_attach): Adjust to rename and use
7271 linux_proc_attach_tgid_threads.
7272 (linux_attach_fail_reason_string): Delete declaration.
7273
7274 2015-01-01 Joel Brobecker <brobecker@adacore.com>
7275
7276 * gdbreplay.c (gdbreplay_version): Update copyright year to 2015.
7277 * server.c (gdbserver_version): Likewise.
7278
7279 2014-12-29 Sergio Durigan Junior <sergiodj@redhat.com>
7280
7281 * remote-utils.c: Include ctype.h.
7282 (input_interrupt): Explicitly handle the case when the char
7283 received is the NUL byte. Improve the printing of non-ASCII
7284 characters.
7285
7286 2014-12-16 Joel Brobecker <brobecker@adacore.com>
7287
7288 * linux-low.c (linux_low_filter_event): Update call to
7289 linux_enable_event_reporting following the addition of
7290 a new parameter to that function.
7291
7292 2014-12-16 Catalin Udma <catalin.udma@freescale.com>
7293
7294 PR server/17457
7295 * linux-aarch64-low.c (AARCH64_FPSR_REGNO): New define.
7296 (AARCH64_FPCR_REGNO): Likewise.
7297 (AARCH64_NUM_REGS): Update to include fpsr/fpcr registers.
7298 (aarch64_fill_fpregset): Add missing fpsr/fpcr registers.
7299 (aarch64_store_fpregset): Likewise.
7300
7301 2014-12-15 Joel Brobecker <brobecker@adacore.com>
7302
7303 * lynx-low.c (lynx_resume): Use PTRACE_SINGLESTEP_ONE if N == 1.
7304 Remove FIXME comment about assumption about N.
7305
7306 2014-12-13 Joel Brobecker <brobecker@adacore.com>
7307
7308 * configure.ac: If large-file support is disabled in GDBserver,
7309 pass --disable-largefile to ACX_CONFIGURE_DIR call for "gnulib".
7310 * configure: Regenerate.
7311
7312 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7313
7314 * linux-low.c (regsets_fetch_inferior_registers): Suppress the
7315 warning upon ENODATA from ptrace.
7316 * linux-s390-low.c (s390_store_tdb): New.
7317 (s390_regsets): Add regset for NT_S390_TDB.
7318
7319 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7320
7321 * linux-low.c (regsets_store_inferior_registers): Skip regsets
7322 without a fill_function.
7323 * linux-s390-low.c (s390_fill_last_break): Remove.
7324 (s390_regsets): Set fill_function to NULL for NT_S390_LAST_BREAK.
7325 (s390_arch_setup): Use regset's size instead of fill_function for
7326 loop end condition.
7327
7328 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7329
7330 * linux-low.c (regsets_fetch_inferior_registers): Do not invoke
7331 the regset's store function when ptrace returned an error.
7332 * regcache.c (get_thread_regcache): Invalidate register cache
7333 before fetching inferior's registers.
7334
7335 2014-12-12 Andreas Arnez <arnez@linux.vnet.ibm.com>
7336
7337 * linux-low.c (regsets_fetch_inferior_registers): Rephrase
7338 while-loop as for-loop.
7339 (regsets_store_inferior_registers): Likewise.
7340
7341 2014-11-28 Yao Qi <yao@codesourcery.com>
7342
7343 * configure.ac(AC_CHECK_FUNCS): Remove readlink.
7344 * config.in, configure: Re-generate.
7345 * hostio.c (handle_unlink): Remove code checking HAVE_READLINK
7346 is defined.
7347
7348 2014-11-21 Yao Qi <yao@codesourcery.com>
7349
7350 * configure.ac: Don't invoke AC_FUNC_ALLOCA.
7351 (AC_CHECK_HEADERS): Remove malloc.h.
7352 * configure: Re-generated.
7353 * config.in: Re-generated.
7354 * server.h: Don't include alloca.h and malloc.h.
7355 * gdbreplay.c: Don't check HAVE_ALLOCA_H is defined.
7356 Don't include malloc.h.
7357
7358 2014-11-17 Joel Brobecker <brobecker@adacore.com>
7359
7360 * lynx-low.c (lynx_write_memory): Put lynx_read_memory and
7361 corresponding ERRNO check in same block.
7362
7363 2014-11-12 Pedro Alves <palves@redhat.com>
7364
7365 * server.c (cont_thread): Update comment.
7366 (start_inferior, attach_inferior): No longer clear cont_thread.
7367 (handle_v_cont): No longer set cont_thread.
7368 (captured_main): Clear cont_thread each time a GDB connects.
7369
7370 2014-11-12 Pedro Alves <palves@redhat.com>
7371
7372 * linux-low.c (linux_wait_1): Don't force a wait for the Hc
7373 thread, and don't resume all threads if the Hc thread has exited.
7374
7375 2014-11-12 Pedro Alves <palves@redhat.com>
7376
7377 * linux-low.c (linux_request_interrupt): Always send a SIGINT to
7378 the process group instead of to a specific LWP.
7379
7380 2014-10-15 Pedro Alves <palves@redhat.com>
7381
7382 PR server/17487
7383 * win32-arm-low.c (arm_set_thread_context): Remove current_event
7384 parameter.
7385 (arm_set_thread_context): Delete.
7386 (the_low_target): Adjust.
7387 * win32-i386-low.c (debug_registers_changed)
7388 (debug_registers_used): Delete.
7389 (update_debug_registers_callback): New function.
7390 (x86_dr_low_set_addr, x86_dr_low_set_control): Mark all threads as
7391 needing to update their debug registers.
7392 (win32_get_current_dr): New function.
7393 (x86_dr_low_get_addr, x86_dr_low_get_control)
7394 (x86_dr_low_get_status): Fetch the debug register from the thread
7395 record's context.
7396 (i386_initial_stuff): Adjust.
7397 (i386_get_thread_context): Remove current_event parameter. Don't
7398 clear debug_registers_changed nor copy DR values to
7399 debug_reg_state.
7400 (i386_set_thread_context): Delete.
7401 (i386_prepare_to_resume): New function.
7402 (i386_thread_added): Mark the thread as needing to update irs
7403 debug registers.
7404 (the_low_target): Remove i386_set_thread_context and install
7405 i386_prepare_to_resume.
7406 * win32-low.c (win32_get_thread_context): Adjust.
7407 (win32_set_thread_context): Use SetThreadContext
7408 directly.
7409 (win32_prepare_to_resume): New function.
7410 (win32_require_context): New function, factored out from ...
7411 (thread_rec): ... this.
7412 (continue_one_thread): Call win32_prepare_to_resume on each thread
7413 we're about to continue.
7414 (win32_resume): Call win32_prepare_to_resume on the event thread.
7415 * win32-low.h (struct win32_thread_info)
7416 <debug_registers_changed>: New field.
7417 (struct win32_target_ops): Change prototype of set_thread_context,
7418 delete set_thread_context and add prepare_to_resume.
7419 (win32_require_context): New declaration.
7420
7421 2014-10-08 Gary Benson <gbenson@redhat.com>
7422
7423 * server.h: Do not include common-exceptions.h.
7424
7425 2014-10-08 Gary Benson <gbenson@redhat.com>
7426
7427 * server.h: Do not include cleanups.h.
7428
7429 2014-09-30 James Hogan <james.hogan@imgtec.com>
7430
7431 * Makefile.in (clean): Add rm -f commands for mips-dsp-linux.c and
7432 mips64-dsp-linux.c.
7433
7434 2014-09-23 Yao Qi <yao@codesourcery.com>
7435
7436 * linux-low.c (lp_status_maybe_breakpoint): New function.
7437 (linux_low_filter_event): Call lp_status_maybe_breakpoint.
7438 (count_events_callback): Likewise.
7439 (select_event_lwp_callback): Likewise.
7440 (cancel_breakpoints_callback): Likewise.
7441
7442 2014-09-19 Don Breazeal <donb@codesourcery.com>
7443
7444 * linux-low.c (handle_extended_wait): Call
7445 linux_ptrace_get_extended_event.
7446 (get_stop_pc, get_detach_signal, linux_low_filter_event): Call
7447 linux_is_extended_waitstatus.
7448
7449 2014-09-16 Joel Brobecker <brobecker@adacore.com>
7450
7451 * Makefile.in (CPPFLAGS): Define.
7452 (INTERNAL_CFLAGS_BASE): Add ${CPPFLAGS}.
7453 (IPAGENT_CFLAGS): Remove ${CPPFLAGS}.
7454
7455 2014-09-16 Gary Benson <gbenson@redhat.com>
7456
7457 * inferiors.h (current_inferior): Renamed as...
7458 (current_thread): New variable. All uses updated.
7459 * linux-low.c (get_pc): Renamed saved_inferior as saved_thread.
7460 (maybe_move_out_of_jump_pad): Likewise.
7461 (cancel_breakpoint): Likewise.
7462 (linux_low_filter_event): Likewise.
7463 (wait_for_sigstop): Likewise.
7464 (linux_resume_one_lwp): Likewise.
7465 (need_step_over_p): Likewise.
7466 (start_step_over): Likewise.
7467 (linux_stabilize_threads): Renamed save_inferior as saved_thread.
7468 * linux-x86-low.c (x86_linux_update_xmltarget): Likewise.
7469 * proc-service.c (ps_lgetregs): Renamed reg_inferior as reg_thread
7470 and save_inferior as saved_thread.
7471 * regcache.c (get_thread_regcache): Renamed saved_inferior as
7472 saved_thread.
7473 (regcache_invalidate_thread): Likewise.
7474 * remote-utils.c (prepare_resume_reply): Likewise.
7475 * thread-db.c (thread_db_get_tls_address): Likewise.
7476 (disable_thread_event_reporting): Likewise.
7477 (remove_thread_event_breakpoints): Likewise.
7478 * tracepoint.c (gdb_agent_about_to_close): Renamed save_inferior
7479 as saved_thread.
7480 * target.h (set_desired_inferior): Renamed as...
7481 (set_desired_thread): New declaration. All uses updated.
7482 * server.c (myresume): Updated comment to reference thread instead
7483 of inferior.
7484 (handle_serial_event): Likewise.
7485 (handle_target_event): Likewise.
7486
7487 2014-09-12 Tom Tromey <tromey@redhat.com>
7488 Gary Benson <gbenson@redhat.com>
7489
7490 * regcache.h: Include common-regcache.h.
7491 (regcache_read_pc): Don't declare.
7492 * regcache.c (get_thread_regcache_for_ptid): New function.
7493
7494 2014-09-11 Tom Tromey <tromey@redhat.com>
7495 Gary Benson <gbenson@redhat.com>
7496
7497 * symbol.c: New file.
7498 * Makefile.in (SFILES): Add symbol.c.
7499 (OBS): Add symbol.o.
7500
7501 2014-09-11 Gary Benson <gbenson@redhat.com>
7502
7503 * target.c (target_stop_ptid, target_continue_ptid): New
7504 functions.
7505
7506 2014-09-11 Tom Tromey <tromey@redhat.com>
7507 Gary Benson <gbenson@redhat.com>
7508
7509 * target.h: Include target/target.h.
7510 * target.c (target_read_memory, target_read_uint32)
7511 (target_write_memory): New functions.
7512
7513 2014-09-11 Gary Benson <gbenson@redhat.com>
7514
7515 * server.h (debug_hw_points): Don't declare.
7516 * server.c (debug_hw_points): Don't define. Replace all uses
7517 with show_debug_regs.
7518 * linux-aarch64-low.c (debug_hw_points): Don't define. Replace
7519 all uses with show_debug_regs.
7520
7521 2014-09-08 Edjunior Barbosa Machado <emachado@linux.vnet.ibm.com>
7522
7523 * linux-ppc-low.c (ppc_collect_ptrace_register): Adjust routine to take
7524 endianness into account.
7525 (ppc_supply_ptrace_register): Likewise.
7526
7527 2014-09-03 James Hogan <james.hogan@imgtec.com>
7528
7529 * linux-mips-low.c (mips_read_description): Reset errno to 0 prior
7530 to reading DSP_CONTROL with PTRACE_PEEKUSER ptrace call.
7531
7532 2014-09-03 Gary Benson <gbenson@redhat.com>
7533
7534 * linux-x86-low.c (x86_linux_prepare_to_resume): Use
7535 ALL_DEBUG_ADDRESS_REGISTERS.
7536
7537 2014-09-02 Gary Benson <gbenson@redhat.com>
7538
7539 * i386-low.h: Renamed as...
7540 * x86-low.h: New file. All type, function and variable name
7541 prefixes changed from "i386_" to "x86_". All references updated.
7542 * i386-low.c: Renamed as...
7543 * x86-low.c: New file. All type, function and variable name
7544 prefixes changed from "i386_" to "x86_". All references updated.
7545
7546 2014-09-02 Gary Benson <gbenson@redhat.com>
7547
7548 * linux-x86-low.c (x86_linux_new_process): Use XCNEW.
7549 (x86_linux_new_thread): Likewise.
7550
7551 2014-08-29 Gary Benson <gbenson@redhat.com>
7552
7553 * server.h (setjmp.h): Do not include.
7554 (toplevel): Do not declare.
7555 (common-exceptions.h): Include.
7556 (cleanups.h): Likewise.
7557 * server.c (toplevel): Do not define.
7558 (exit_code): New static global.
7559 (detach_or_kill_for_exit_cleanup): New function.
7560 (main): New function. Original main renamed to...
7561 (captured_main): New function.
7562 * utils.c (verror) [!IN_PROCESS_AGENT]: Use throw_verror.
7563
7564 2014-08-29 Gary Benson <gbenson@redhat.com>
7565
7566 * Makefile.in (SFILES): Add common/common-exceptions.c.
7567 (OBS): Add common-exceptions.o.
7568 (common-exceptions.o): New rule.
7569 * utils.c (prepare_to_throw_exception): New function.
7570
7571 2014-08-29 Gary Benson <gbenson@redhat.com>
7572
7573 * config.in: Regenerate.
7574 * configure: Likewise.
7575
7576 2014-08-29 Gary Benson <gbenson@redhat.com>
7577
7578 * Makefile.in (SFILES): Add common/cleanups.c.
7579 (OBS): cleanups.o.
7580 (cleanups.o): New rule.
7581
7582 2014-08-29 Gary Benson <gbenson@redhat.com>
7583
7584 * utils.c (internal_vwarning): New function.
7585
7586 2014-08-28 Gary Benson <gbenson@redhat.com>
7587
7588 * utils.h (fatal): Remove declaration.
7589 * utils.c (fatal): Remove function.
7590
7591 2014-08-28 Gary Benson <gbenson@redhat.com>
7592
7593 * tracepoint.c (gdb_agent_init): Replace fatal with
7594 perror_with_name.
7595 (initialize_tracepoint): Likewise.
7596
7597 2014-08-28 Gary Benson <gbenson@redhat.com>
7598
7599 * remote-utils.c (remote_prepare): Replace fatal with error.
7600
7601 2014-08-28 Gary Benson <gbenson@redhat.com>
7602
7603 * linux-low.c (linux_async): Replace fatal with warning.
7604 Tidy up and return.
7605 (linux_start_non_stop): Return -1 if linux_async failed.
7606
7607 2014-08-28 Gary Benson <gbenson@redhat.com>
7608
7609 * linux-x86-low.c (i386_dr_low_set_addr): Replace check with
7610 gdb_assert.
7611 (i386_dr_low_get_addr): Remove vague comment.
7612 * win32-i386-low.c (i386_dr_low_set_addr): Replace check with
7613 gdb_assert.
7614
7615 2014-08-28 Gary Benson <gbenson@redhat.com>
7616
7617 * inferiors.c (get_thread_process): Replace check with gdb_assert.
7618 * linux-low.c (linux_wait_for_event_filtered): Replace fatal with
7619 internal_error.
7620 (linux_resume_one_lwp): Likewise.
7621 * linux-x86-low.c (x86_siginfo_fixup): Replace checks with
7622 gdb_assert.
7623 * mem-break.c (raw_bkpt_type_to_target_hw_bp_type): Replace fatal
7624 with internal_error.
7625 * regcache.c (get_thread_regcache): Replace check with gdb_assert.
7626 (init_register_cache): Replace fatal with gdb_assert_not_reached.
7627 (find_register_by_name): Replace fatal with internal_error.
7628 (find_regno): Likewise.
7629 * tdesc.c (init_target_desc): Replace check with gdb_assert.
7630 * thread-db.c (thread_db_create_event): Likewise.
7631 (thread_db_load_search): Likewise.
7632 (try_thread_db_load_1): Likewise.
7633 * tracepoint.c (get_jump_space_head): Replace fatal with
7634 internal_error.
7635 (claim_trampoline_space): Likewise.
7636 (have_fast_tracepoint_trampoline_buffer): Likewise.
7637 (cmd_qtstart): Likewise.
7638 (stop_tracing): Likewise.
7639 (fast_tracepoint_collecting): Likewise.
7640 (target_malloc): Likewise.
7641 (download_tracepoint): Likewise.
7642 (download_trace_state_variables): Replace check with gdb_assert.
7643 (upload_fast_traceframes): Replace fatal with internal_error.
7644
7645 2014-08-19 Tom Tromey <tromey@redhat.com>
7646 Gary Benson <gbenson@redhat.com>
7647
7648 * Makefile.in (SFILES): Add common/common-debug.c.
7649 (OBS): Add common-debug.o.
7650 (common-debug.o): New rule.
7651 * debug.h (debug_printf): Don't declare.
7652 * debug.c (debug_printf): Renamed and rewritten as...
7653 (debug_vprintf): New function.
7654
7655 2014-08-19 Gary Benson <gbenson@redhat.com>
7656
7657 * utils.h: Do not include print-utils.h.
7658
7659 2014-08-19 Tom Tromey <tromey@redhat.com>
7660 Gary Benson <gbenson@redhat.com>
7661
7662 * server.h: Add static assertion.
7663 (gdb_byte, CORE_ADDR, LONGEST, ULONGEST): Remove.
7664
7665 2014-08-19 Tom Tromey <tromey@redhat.com>
7666 Gary Benson <gbenson@redhat.com>
7667
7668 * Makefile.in (SFILES): Add common/errors.c.
7669 (OBS): Add errors.o.
7670 (IPA_OBS): Add errors-ipa.o.
7671 (errors.o): New rule.
7672 (errors-ipa.o): Likewise.
7673 * utils.h (perror_with_name, error, warning): Don't declare.
7674 * utils.c (warning): Renamed and rewritten as...
7675 (vwarning): New function.
7676 (error): Renamed and rewritten as...
7677 (verror): New function.
7678 (internal_error): Renamed and rewritten as...
7679 (internal_verror): New function.
7680
7681 2014-08-07 Gary Benson <gbenson@redhat.com>
7682
7683 * configure.ac (AC_CHECK_HEADERS): Remove errno.h.
7684 * configure: Regenerate.
7685 * config.in: Likewise.
7686 * server.h: Do not include errno.h.
7687 * event-loop.c: Likewise.
7688 * hostio-errno.c: Likewise.
7689 * linux-low.c: Likewise.
7690 * remote-utils.c: Likewise.
7691 * spu-low.c: Likewise.
7692 * utils.c: Likewise.
7693 * gdbreplay.c: Unconditionally include errno.h.
7694
7695 2014-08-07 Gary Benson <gbenson@redhat.com>
7696
7697 * server.h: Do not include string.h.
7698 * event-loop.c: Likewise.
7699 * linux-low.c: Likewise.
7700 * regcache.c: Likewise.
7701 * remote-utils.c: Likewise.
7702 * spu-low.c: Likewise.
7703 * utils.c: Likewise.
7704
7705 2014-08-07 Gary Benson <gbenson@redhat.com>
7706
7707 * server.h: Do not include gdb_assert.h.
7708
7709 2014-08-07 Gary Benson <gbenson@redhat.com>
7710
7711 * server.h: Do not include common-utils.h.
7712
7713 2014-08-07 Gary Benson <gbenson@redhat.com>
7714
7715 * server.h: Do not include ptid.h.
7716 * notif.h: Likewise.
7717
7718 2014-08-07 Gary Benson <gbenson@redhat.com>
7719
7720 * server.h: Do not include gdb_locale.h.
7721
7722 2014-08-07 Gary Benson <gbenson@redhat.com>
7723
7724 * server.h: Do not include gdb/signals.h.
7725 * win32-low.c: Likewise.
7726
7727 2014-08-07 Gary Benson <gbenson@redhat.com>
7728
7729 * server.h: Do not include pathmax.h.
7730
7731 2014-08-07 Gary Benson <gbenson@redhat.com>
7732
7733 * server.h: Do not include libiberty.h.
7734 * linux-bfin-low.c: Likewise.
7735
7736 2014-08-07 Gary Benson <gbenson@redhat.com>
7737
7738 * server.h: Do not include ansidecl.h.
7739
7740 2014-08-07 Gary Benson <gbenson@redhat.com>
7741
7742 * linux-x86-low.c: Do not include stddef.h.
7743 * lynx-ppc-low.c: Likewise.
7744 * tracepoint.c: Likewise.
7745
7746 2014-08-07 Gary Benson <gbenson@redhat.com>
7747
7748 * server.h: Do not include stdarg.h.
7749 * nto-low.c: Likewise.
7750
7751 2014-08-07 Gary Benson <gbenson@redhat.com>
7752
7753 * server.h: Do not include stdlib.h.
7754 * inferiors.c: Likewise.
7755 * linux-low.c: Likewise.
7756 * regcache.c: Likewise.
7757 * spu-low.c: Likewise.
7758 * tracepoint.c: Likewise.
7759 * utils.c: Likewise.
7760
7761 2014-08-07 Gary Benson <gbenson@redhat.com>
7762
7763 * server.h: Do not include stdio.h.
7764 * linux-low.c: Likewise.
7765 * remote-utils.c: Likewise.
7766 * spu-low.c: Likewise.
7767 * utils.c: Likewise.
7768 * wincecompat.c: Likewise.
7769
7770 2014-08-06 Gary Benson <gbenson@redhat.com>
7771
7772 * regcache.c (init_register_cache): Move conditionals inside if.
7773
7774 2014-08-06 Gary Benson <gbenson@redhat.com>
7775
7776 * linux-low.c (linux_supports_non_stop): Use target_is_async_p.
7777
7778 2014-07-31 Gary Benson <gbenson@redhat.com>
7779
7780 * ax.h: Do not include server.h.
7781 * gdbthread.h: Likewise.
7782 * lynx-low.h: Likewise.
7783 * notif.h: Likewise.
7784
7785 2014-07-30 Gary Benson <gbenson@redhat.com>
7786
7787 * server.h: Include common-defs.h.
7788 Do not include config.h or build-gnulib-gdbserver/config.h.
7789
7790 2014-07-30 Gary Benson <gbenson@redhat.com>
7791
7792 * hostio-errno.c: Move server.h to top of includes list.
7793 * inferiors.c: Likewise.
7794 * linux-x86-low.c: Likewise.
7795 * notif.c: Include server.h.
7796
7797 2014-07-24 Tom Tromey <tromey@redhat.com>
7798 Gary Benson <gbenson@redhat.com>
7799
7800 * server.h (CORE_ADDR): Now unsigned.
7801
7802 2014-07-16 Pedro Alves <palves@redhat.com>
7803
7804 * linux-low.c (linux_kill_one_lwp): Use kill_lwp, not kill.
7805
7806 2014-07-15 Pedro Alves <palves@redhat.com>
7807
7808 * linux-low.c (linux_kill_one_lwp): Save errno and work with saved
7809 copy.
7810
7811 2014-07-11 Pedro Alves <palves@redhat.com>
7812
7813 * linux-low.c (kill_wait_lwp): New function, based on
7814 kill_one_lwp_callback, but use my_waitpid directly.
7815 (kill_one_lwp_callback, linux_kill): Use it.
7816
7817 2014-06-23 Pedro Alves <palves@redhat.com>
7818
7819 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR_CONTROL
7820 before setting DR0..DR3.
7821
7822 2014-06-20 Gary Benson <gbenson@redhat.com>
7823
7824 * configure.ac (AC_REPLACE_FUNCS) <vasprintf, vsnprintf>: Removed.
7825 * configure: Regenerated.
7826 * config.in: Likewise.
7827
7828 2014-06-20 Gary Benson <gbenson@redhat.com>
7829
7830 * Makefile.in (SFILES): Update locations for files moved
7831 from common to nat.
7832 (object file files): Reordered.
7833
7834 2014-06-20 Gary Benson <gbenson@redhat.com>
7835
7836 * i386-low.h (i386_dr_low_can_set_addr): Removed.
7837 (i386_dr_low_set_addr): Likewise.
7838 (i386_dr_low_get_addr): Likewise.
7839 (i386_dr_low_can_set_control): Likewise.
7840 (i386_dr_low_set_control): Likewise.
7841 (i386_dr_low_get_control): Likewise.
7842 (i386_dr_low_get_status): Likewise.
7843 (i386_get_debug_register_length): Likewise.
7844 * linux-x86-low.c (i386_dr_low_set_addr):
7845 Changed signature. Made static.
7846 (i386_dr_low_get_addr): Likewise.
7847 (i386_dr_low_set_control): Likewise.
7848 (i386_dr_low_get_control): Likewise.
7849 (i386_dr_low_get_status): Likewise.
7850 (i386_dr_low): New global variable.
7851 * win32-i386-low.c (i386_dr_low_set_addr):
7852 Changed signature. Made static.
7853 (i386_dr_low_get_addr): Likewise.
7854 (i386_dr_low_set_control): Likewise.
7855 (i386_dr_low_get_control): Likewise.
7856 (i386_dr_low_get_status): Likewise.
7857 (i386_dr_low): New global variable.
7858
7859 2014-06-20 Marcus Shawcroft <marcus.shawcroft@arm.com>
7860
7861 * configure.ac: Invoke. AC_CHECK_TOOL(AR, ar).
7862 * Makefile.in (AR, AR_FLAGS): Define.
7863 * configure: Regenerate.
7864
7865 2014-06-19 Gary Benson <gbenson@redhat.com>
7866
7867 * Makefile.in (i386-dregs.o): New rule.
7868 * configure.srv: Add i386-dregs.o to all targets using i386-low.o.
7869 * i386-low.c (target.h): Remove include.
7870 (TARGET_HAS_DR_LEN_8): Now in i386-dregs.c.
7871 (DR_CONTROL_SHIFT): Likewise.
7872 (DR_CONTROL_SIZE): Likewise.
7873 (DR_RW_EXECUTE): Likewise.
7874 (DR_RW_WRITE): Likewise.
7875 (DR_RW_READ): Likewise.
7876 (DR_RW_IORW): Likewise.
7877 (DR_LEN_1): Likewise.
7878 (DR_LEN_2): Likewise.
7879 (DR_LEN_4): Likewise.
7880 (DR_LEN_8): Likewise.
7881 (DR_LOCAL_ENABLE_SHIFT): Likewise.
7882 (DR_GLOBAL_ENABLE_SHIFT): Likewise.
7883 (DR_ENABLE_SIZE): Likewise.
7884 (DR_LOCAL_SLOWDOWN): Likewise.
7885 (DR_GLOBAL_SLOWDOWN): Likewise.
7886 (DR_CONTROL_RESERVED): Likewise.
7887 (I386_DR_CONTROL_MASK): Likewise.
7888 (I386_DR_VACANT): Likewise.
7889 (I386_DR_LOCAL_ENABLE): Likewise.
7890 (I386_DR_GLOBAL_ENABLE): Likewise.
7891 (I386_DR_DISABLE): Likewise.
7892 (I386_DR_SET_RW_LEN): Likewise.
7893 (I386_DR_GET_RW_LEN): Likewise.
7894 (I386_DR_WATCH_HIT): Likewise.
7895 (i386_wp_op_t): Likewise.
7896 (i386_show_dr): Likewise.
7897 (i386_length_and_rw_bits): Likewise.
7898 (i386_insert_aligned_watchpoint): Likewise.
7899 (i386_remove_aligned_watchpoint): Likewise.
7900 (i386_handle_nonaligned_watchpoint): Likewise.
7901 i386_update_inferior_debug_regs(): Likewise.
7902 (i386_dr_insert_watchpoint): Likewise.
7903 (i386_dr_remove_watchpoint): Likewise.
7904 (i386_dr_region_ok_for_watchpoint): Likewise.
7905 (i386_dr_stopped_data_address): Likewise.
7906 (i386_dr_stopped_by_watchpoint): Likewise.
7907
7908 2014-06-19 Gary Benson <gbenson@redhat.com>
7909
7910 * i386-low.c (i386_dr_show): Renamed to
7911 i386_show_dr and made static. All uses updated.
7912 (i386_dr_length_and_rw_bits): Renamed to
7913 i386_length_and_rw_bits and made static.
7914 All uses updated.
7915 (i386_dr_insert_aligned_watchpoint): Renamed to
7916 i386_insert_aligned_watchpoint and made static.
7917 All uses updated.
7918 (i386_dr_remove_aligned_watchpoint): Renamed to
7919 i386_remove_aligned_watchpoint and made static.
7920 All uses updated.
7921 (i386_dr_update_inferior_debug_regs): Renamed to
7922 i386_update_inferior_debug_regs and made static.
7923 All uses updated.
7924
7925 2014-06-18 Gary Benson <gbenson@redhat.com>
7926
7927 * i386-low.h (i386_dr_low_can_set_addr): New macro.
7928 (i386_dr_low_can_set_control): Likewise.
7929 (i386_get_debug_register_length): Likewise.
7930 * i386-low.c (i386_dr_low_can_set_addr): Now in i386-low.h.
7931 (i386_dr_low_can_set_control): Likewise.
7932 (i386_get_debug_register_length): Likewise.
7933
7934 2014-06-17 Gary Benson <gbenson@redhat.com>
7935
7936 * i386-low.h (i386-dregs.h): New include.
7937 (DR_FIRSTADDR): Now in i386-dregs.h.
7938 (DR_LASTADDR): Likewise.
7939 (DR_NADDR): Likewise.
7940 (DR_STATUS): Likewise.
7941 (DR_CONTROL): Likewise.
7942 (i386_debug_reg_state): Likewise.
7943 (i386_dr_insert_watchpoint): Likewise.
7944 (i386_dr_remove_watchpoint): Likewise.
7945 (i386_dr_region_ok_for_watchpoint): Likewise.
7946 (i386_dr_stopped_data_address): Likewise.
7947 (i386_dr_stopped_by_watchpoint): Likewise.
7948 * i386-low.c (ALL_DEBUG_REGISTERS): Likewise.
7949
7950 2014-06-18 Gary Benson <gbenson@redhat.com>
7951
7952 * i386-low.h (i386_low_insert_watchpoint): Renamed to
7953 i386_dr_insert_watchpoint.
7954 (i386_low_remove_watchpoint): Renamed to
7955 i386_dr_remove_watchpoint.
7956 (i386_low_region_ok_for_watchpoint): Renamed to
7957 i386_dr_region_ok_for_watchpoint.
7958 (i386_low_stopped_data_address): Renamed to
7959 i386_dr_stopped_data_address.
7960 (i386_low_stopped_by_watchpoint): Renamed to
7961 i386_dr_stopped_by_watchpoint.
7962 * i386-low.c (i386_show_dr): Renamed to
7963 i386_dr_show and made nonstatic. All uses updated.
7964 (i386_length_and_rw_bits): Renamed to
7965 i386_dr_length_and_rw_bits and made nonstatic.
7966 All uses updated.
7967 (i386_insert_aligned_watchpoint): Renamed to
7968 i386_dr_insert_aligned_watchpoint and made nonstatic.
7969 All uses updated.
7970 (i386_remove_aligned_watchpoint): Renamed to
7971 i386_dr_remove_aligned_watchpoint and made nonstatic.
7972 All uses updated.
7973 (i386_update_inferior_debug_regs): Renamed to
7974 i386_dr_update_inferior_debug_regs and made nonstatic.
7975 All uses updated.
7976 (i386_low_insert_watchpoint): Renamed to
7977 i386_dr_insert_watchpoint. All uses updated.
7978 (i386_low_remove_watchpoint): Renamed to
7979 i386_dr_remove_watchpoint. All uses updated.
7980 (i386_low_region_ok_for_watchpoint): Renamed to
7981 i386_dr_region_ok_for_watchpoint. All uses updated.
7982 (i386_low_stopped_data_address): Renamed to
7983 i386_dr_stopped_data_address. All uses updated.
7984 (i386_low_stopped_by_watchpoint): Renamed to
7985 i386_dr_stopped_by_watchpoint. All uses updated.
7986
7987 2014-06-18 Gary Benson <gbenson@redhat.com>
7988
7989 * i386-low.c (i386_dr_low_can_set_addr): New macro.
7990 (i386_dr_low_can_set_control): Likewise.
7991 (i386_insert_aligned_watchpoint): New check.
7992
7993 2014-06-18 Gary Benson <gbenson@redhat.com>
7994
7995 * i386-low.c (i386_update_inferior_debug_regs) <inf_state>:
7996 Renamed to state.
7997
7998 2014-06-18 Gary Benson <gbenson@redhat.com>
7999
8000 * i386-low.c (i386_length_and_rw_bits): Use internal_error
8001 instead of fatal and error.
8002 (i386_handle_nonaligned_watchpoint): Likewise.
8003
8004 2014-06-18 Gary Benson <gbenson@redhat.com>
8005
8006 * i386-low.c (i386_get_debug_register_length): New macro.
8007 (TARGET_HAS_DR_LEN_8): Remove conditional. Use above macro.
8008 (i386_show_dr): Use debug_printf instead of fprintf. Use
8009 phex to format values.
8010
8011 2014-06-18 Gary Benson <gbenson@redhat.com>
8012
8013 * i386-low.h: Comment changes.
8014 * i386-low.c: Likewise.
8015
8016 2014-06-18 Gary Benson <gbenson@redhat.com>
8017
8018 * i386-low.c: Whitespace changes.
8019
8020 2014-06-12 Tom Tromey <tromey@redhat.com>
8021
8022 * utils.c (freeargv): Remove.
8023
8024 2014-06-12 Tom Tromey <tromey@redhat.com>
8025
8026 * debug.c (debug_printf): Remove HAVE_GETTIMEOFDAY checks.
8027 * server.c (monitor_show_help): Remove HAVE_GETTIMEOFDAY check.
8028 (parse_debug_format_options): Likewise.
8029 (gdbserver_usage): Likewise.
8030 * Makefile.in (LIBIBERTY_BUILDDIR, LIBIBERTY): New variables.
8031 (SUBDIRS, REQUIRED_SUBDIRS): Add libiberty.
8032 (gdbserver$(EXEEXT), gdbreplay$(EXEEXT)): Depend on and link
8033 against libiberty.
8034 ($(LIBGNU)): Depend on libiberty.
8035 (all-lib): Recurse into all subdirs.
8036 (install-only): Invoke "install" target in subdirs.
8037 (vasprintf.o, vsnprintf.o, safe-ctype.o, lbasename.o): Remove
8038 targets.
8039 * configure: Rebuild.
8040 * configure.ac: Add ACX_CONFIGURE_DIR for libiberty. Don't check
8041 for vasprintf, vsnprintf, or gettimeofday.
8042 * configure.srv: Don't add safe-ctype.o or lbasename.o to
8043 srv_tgtobj.
8044
8045 2014-06-05 Joel Brobecker <brobecker@adacore.com>
8046
8047 * development.sh: Delete.
8048 * Makefile.in (config.status): Adjust dependency on development.sh.
8049 * configure.ac: Adjust development.sh source call.
8050 * configure: Regenerate.
8051
8052 2014-06-02 Pedro Alves <palves@redhat.com>
8053
8054 * ax.c (gdb_free_agent_expr): New function.
8055 * ax.h (gdb_free_agent_expr): New declaration.
8056 * mem-break.c (delete_gdb_breakpoint_1): Also clear the commands
8057 list.
8058 (clear_breakpoint_conditions, clear_breakpoint_commands): Make
8059 static.
8060 (clear_breakpoint_conditions_and_commands): New function.
8061 * mem-break.h (clear_breakpoint_conditions): Delete declaration.
8062 (clear_breakpoint_conditions_and_commands): New declaration.
8063
8064 2014-05-23 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
8065
8066 * linux-aarch64-low.c (asm/ptrace.h): Include.
8067
8068 2014-05-21 Jan Kratochvil <jan.kratochvil@redhat.com>
8069
8070 Fix TLS access for -static -pthread.
8071 * gdbserver/thread-db.c (struct thread_db): Add td_thr_tlsbase_p.
8072 (thread_db_get_tls_address): Call it if LOAD_MODULE is zero.
8073 (thread_db_load_search, try_thread_db_load_1): Initialize it.
8074
8075 2014-05-20 Pedro Alves <palves@redhat.com>
8076
8077 * linux-aarch64-low.c (aarch64_insert_point)
8078 (aarch64_remove_point): No longer check whether the type is
8079 supported here. Adjust to new interface.
8080 (the_low_target): Install aarch64_supports_z_point_type as
8081 supports_z_point_type method.
8082 * linux-arm-low.c (raw_bkpt_type_to_arm_hwbp_type): New function.
8083 (arm_linux_hw_point_initialize): Take an enum raw_bkpt_type
8084 instead of a Z packet char. Adjust.
8085 (arm_supports_z_point_type): New function.
8086 (arm_insert_point, arm_remove_point): Adjust to new interface.
8087 (the_low_target): Install arm_supports_z_point_type.
8088 * linux-crisv32-low.c (cris_supports_z_point_type): New function.
8089 (cris_insert_point, cris_remove_point): Adjust to new interface.
8090 Don't check whether the type is supported here.
8091 (the_low_target): Install cris_supports_z_point_type.
8092 * linux-low.c (linux_supports_z_point_type): New function.
8093 (linux_insert_point, linux_remove_point): Adjust to new interface.
8094 * linux-low.h (struct linux_target_ops) <insert_point,
8095 remove_point>: Take an enum raw_bkpt_type instead of a char. Add
8096 raw_breakpoint pointer parameter.
8097 <supports_z_point_type>: New method.
8098 * linux-mips-low.c (mips_supports_z_point_type): New function.
8099 (mips_insert_point, mips_remove_point): Adjust to new interface.
8100 Use mips_supports_z_point_type.
8101 (the_low_target): Install mips_supports_z_point_type.
8102 * linux-ppc-low.c (the_low_target): Install NULL as
8103 supports_z_point_type method.
8104 * linux-s390-low.c (the_low_target): Install NULL as
8105 supports_z_point_type method.
8106 * linux-sparc-low.c (the_low_target): Install NULL as
8107 supports_z_point_type method.
8108 * linux-x86-low.c (x86_supports_z_point_type): New function.
8109 (x86_insert_point): Adjust to new insert_point interface. Use
8110 insert_memory_breakpoint. Adjust to new
8111 i386_low_insert_watchpoint interface.
8112 (x86_remove_point): Adjust to remove_point interface. Use
8113 remove_memory_breakpoint. Adjust to new
8114 i386_low_remove_watchpoint interface.
8115 (the_low_target): Install x86_supports_z_point_type.
8116 * lynx-low.c (lynx_target_ops): Install NULL as
8117 supports_z_point_type callback.
8118 * nto-low.c (nto_supports_z_point_type): New.
8119 (nto_insert_point, nto_remove_point): Adjust to new interface.
8120 (nto_target_ops): Install nto_supports_z_point_type.
8121 * mem-break.c: Adjust intro comment.
8122 (struct raw_breakpoint) <raw_type, size>: New fields.
8123 <inserted>: Update comment.
8124 <shlib_disabled>: Delete field.
8125 (enum bkpt_type) <gdb_breakpoint>: Delete value.
8126 <gdb_breakpoint_Z0, gdb_breakpoint_Z1, gdb_breakpoint_Z2,
8127 gdb_breakpoint_Z3, gdb_breakpoint_Z4>: New values.
8128 (raw_bkpt_type_to_target_hw_bp_type): New function.
8129 (find_enabled_raw_code_breakpoint_at): New function.
8130 (find_raw_breakpoint_at): New type and size parameters. Use them.
8131 (insert_memory_breakpoint): New function, based off
8132 set_raw_breakpoint_at.
8133 (remove_memory_breakpoint): New function.
8134 (set_raw_breakpoint_at): Reimplement.
8135 (set_breakpoint): New, based on set_breakpoint_at.
8136 (set_breakpoint_at): Reimplement.
8137 (delete_raw_breakpoint): Go through the_target->remove_point
8138 instead of assuming memory breakpoints.
8139 (find_gdb_breakpoint_at): Delete.
8140 (Z_packet_to_bkpt_type, Z_packet_to_raw_bkpt_type): New functions.
8141 (find_gdb_breakpoint): New function.
8142 (set_gdb_breakpoint_at): Delete.
8143 (z_type_supported): New function.
8144 (set_gdb_breakpoint_1): New function, loosely based off
8145 set_gdb_breakpoint_at.
8146 (check_gdb_bp_preconditions, set_gdb_breakpoint): New functions.
8147 (delete_gdb_breakpoint_at): Delete.
8148 (delete_gdb_breakpoint_1): New function, loosely based off
8149 delete_gdb_breakpoint_at.
8150 (delete_gdb_breakpoint): New function.
8151 (clear_gdb_breakpoint_conditions): Rename to ...
8152 (clear_breakpoint_conditions): ... this. Don't handle a NULL
8153 breakpoint.
8154 (add_condition_to_breakpoint): Make static.
8155 (add_breakpoint_condition): Take a struct breakpoint pointer
8156 instead of an address. Adjust.
8157 (gdb_condition_true_at_breakpoint): Rename to ...
8158 (gdb_condition_true_at_breakpoint_z_type): ... this, and add
8159 z_type parameter.
8160 (gdb_condition_true_at_breakpoint): Reimplement.
8161 (add_breakpoint_commands): Take a struct breakpoint pointer
8162 instead of an address. Adjust.
8163 (gdb_no_commands_at_breakpoint): Rename to ...
8164 (gdb_no_commands_at_breakpoint_z_type): ... this. Add z_type
8165 parameter. Return true if no breakpoint was found. Change debug
8166 output.
8167 (gdb_no_commands_at_breakpoint): Reimplement.
8168 (run_breakpoint_commands): Rename to ...
8169 (run_breakpoint_commands_z_type): ... this. Add z_type parameter,
8170 and change return type to boolean.
8171 (run_breakpoint_commands): New function.
8172 (gdb_breakpoint_here): Also check for Z1 breakpoints.
8173 (uninsert_raw_breakpoint): Don't try to reinsert a disabled
8174 breakpoint. Go through the_target->remove_point instead of
8175 assuming memory breakpoint.
8176 (uninsert_breakpoints_at, uninsert_all_breakpoints): Uninsert
8177 software and hardware breakpoints.
8178 (reinsert_raw_breakpoint): Go through the_target->insert_point
8179 instead of assuming memory breakpoint.
8180 (reinsert_breakpoints_at, reinsert_all_breakpoints): Reinsert
8181 software and hardware breakpoints.
8182 (check_breakpoints, breakpoint_here, breakpoint_inserted_here):
8183 Check both software and hardware breakpoints.
8184 (validate_inserted_breakpoint): Assert the breakpoint is a
8185 software breakpoint. Set the inserted flag to -1 instead of
8186 setting shlib_disabled.
8187 (delete_disabled_breakpoints): Adjust.
8188 (validate_breakpoints): Only validate software breakpoints.
8189 Adjust to inserted flag change.
8190 (check_mem_read, check_mem_write): Skip breakpoint types other
8191 than software breakpoints. Adjust to inserted flag change.
8192 * mem-break.h (enum raw_bkpt_type): New enum.
8193 (raw_breakpoint, struct process_info): Forward declare.
8194 (Z_packet_to_target_hw_bp_type): Delete declaration.
8195 (raw_bkpt_type_to_target_hw_bp_type, Z_packet_to_raw_bkpt_type)
8196 (set_gdb_breakpoint, delete_gdb_breakpoint)
8197 (clear_breakpoint_conditions): New declarations.
8198 (set_gdb_breakpoint_at, clear_gdb_breakpoint_conditions): Delete.
8199 (breakpoint_inserted_here): Update comment.
8200 (add_breakpoint_condition, add_breakpoint_commands): Replace
8201 address parameter with a breakpoint pointer parameter.
8202 (gdb_breakpoint_here): Update comment.
8203 (delete_gdb_breakpoint_at): Delete.
8204 (insert_memory_breakpoint, remove_memory_breakpoint): Declare.
8205 * server.c (process_point_options): Take a struct breakpoint
8206 pointer instead of an address. Adjust.
8207 (process_serial_event) <Z/z packets>: Use set_gdb_breakpoint and
8208 delete_gdb_breakpoint.
8209 * spu-low.c (spu_target_ops): Install NULL as
8210 supports_z_point_type method.
8211 * target.h: Include mem-break.h.
8212 (struct target_ops) <prepare_to_access_memory>: Update comment.
8213 <supports_z_point_type>: New field.
8214 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8215 instead of a char. Also take a raw breakpoint pointer.
8216 * win32-arm-low.c (the_low_target): Install NULL as
8217 supports_z_point_type.
8218 * win32-i386-low.c (i386_supports_z_point_type): New function.
8219 (i386_insert_point, i386_remove_point): Adjust to new interface.
8220 (the_low_target): Install i386_supports_z_point_type.
8221 * win32-low.c (win32_supports_z_point_type): New function.
8222 (win32_insert_point, win32_remove_point): Adjust to new interface.
8223 (win32_target_ops): Install win32_supports_z_point_type.
8224 * win32-low.h (struct win32_target_ops):
8225 <supports_z_point_type>: New method.
8226 <insert_point, remove_point>: Take an enum raw_bkpt_type argument
8227 instead of a char. Also take a raw breakpoint pointer.
8228
8229 2014-05-20 Pedro Alves <palves@redhat.com>
8230
8231 * mem-break.h: Include break-common.h.
8232 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8233 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): New defines.
8234 (Z_packet_to_target_hw_bp_type): New declaration.
8235 * mem-break.c (Z_packet_to_target_hw_bp_type): New function.
8236 * i386-low.c (Z_PACKET_HW_BP, Z_PACKET_WRITE_WP, Z_PACKET_READ_WP)
8237 (Z_PACKET_ACCESS_WP): Delete macros.
8238 (Z_packet_to_hw_type): Delete function.
8239 * i386-low.h: Don't include break-common.h here.
8240 (Z_packet_to_hw_type): Delete declaration.
8241 * linux-x86-low.c (x86_insert_point, x86_insert_point): Call
8242 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8243 * win32-i386-low.c (i386_insert_point, i386_remove_point): Call
8244 Z_packet_to_target_hw_bp_type instead of Z_packet_to_hw_type.
8245 * linux-aarch64-low.c: Don't include break-common.h here.
8246 (Z_PACKET_SW_BP, Z_PACKET_HW_BP, Z_PACKET_WRITE_WP)
8247 (Z_PACKET_READ_WP, Z_PACKET_ACCESS_WP): Delete macros.
8248 (Z_packet_to_target_hw_bp_type): Delete function.
8249 * linux-mips-low.c (rsp_bp_type_to_target_hw_bp_type): Delete
8250 function.
8251 (mips_insert_point, mips_remove_point): Use
8252 Z_packet_to_target_hw_bp_type.
8253
8254 2014-05-20 Pedro Alves <palves@redhat.com>
8255
8256 * linux-aarch64-low.c: Include break-common.h.
8257 (enum target_point_type): Delete.
8258 (Z_packet_to_point_type): Rename to ...
8259 (Z_packet_to_target_hw_bp_type): ... this, and return a
8260 target_hw_bp_type instead.
8261 (aarch64_show_debug_reg_state): Take an enum target_hw_bp_type
8262 instead of an enum target_point_type.
8263 (aarch64_point_encode_ctrl_reg): Likewise. Compute type mask from
8264 breakpoint type.
8265 (aarch64_dr_state_insert_one_point)
8266 (aarch64_dr_state_remove_one_point, aarch64_handle_breakpoint)
8267 (aarch64_handle_aligned_watchpoint)
8268 (aarch64_handle_unaligned_watchpoint, aarch64_handle_watchpoint):
8269 Take an enum target_hw_bp_type instead of an enum
8270 target_point_type.
8271 (aarch64_supports_z_point_type): New function.
8272 (aarch64_insert_point, aarch64_remove_point): Use it. Adjust to
8273 use Z_packet_to_target_hw_bp_type.
8274
8275 2014-05-20 Joel Brobecker <brobecker@adacore.com>
8276
8277 * configure.ac: Only use -Werror by default when DEVELOPMENT
8278 is true.
8279 * configure: Regenerate.
8280
8281 2014-05-19 Jan Kratochvil <jan.kratochvil@redhat.com>
8282
8283 Fix gdbserver qGetTLSAddr for x86_64 -m32.
8284 * linux-x86-low.c (X86_64_USER_REGS): New.
8285 (x86_fill_gregset): Call memset for BUF first in x86_64 -m32 case.
8286
8287 2014-04-28 Yao Qi <yao@codesourcery.com>
8288
8289 * Makefile.in (i386-avx512.c): Fix the typo of generated file
8290 name.
8291
8292 2014-04-25 Pedro Alves <palves@redhat.com>
8293
8294 PR server/16255
8295 * linux-low.c (linux_attach_fail_reason_string): New function.
8296 (linux_attach_lwp): Delete.
8297 (linux_attach_lwp_1): Rename to ...
8298 (linux_attach_lwp): ... this. Take a ptid instead of a pid as
8299 argument. Remove "initial" parameter. Return int instead of
8300 void. Don't error or warn here.
8301 (linux_attach): Adjust to call linux_attach_lwp. Call error on
8302 failure to attach to the tgid. Call warning when failing to
8303 attach to an lwp.
8304 * linux-low.h (linux_attach_lwp): 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_fail_reason_string): New declaration.
8308 * thread-db.c (attach_thread): Adjust to linux_attach_lwp's
8309 interface change. Use linux_attach_fail_reason_string.
8310
8311 2014-04-24 Michael Sturm <michael.sturm@mintel.com>
8312 Walfred Tedeschi <walfred.tedeschi@intel.com>
8313
8314 * Makefile.in: Added rules to handle new files
8315 i386-avx512.c i386-avx512-linux.c amd64-avx512.c
8316 amd64-avx512-linux.c x32-avx512.c x32-avx512-linux.c.
8317 * configure.srv (srv_i386_regobj): Add i386-avx512.o.
8318 (srv_i386_linux_regobj): Add i386-avx512-linux.o.
8319 (srv_amd64_regobj): Add amd64-avx512.o and x32-avx512.o.
8320 (srv_amd64_linux_regobj): Add amd64-avx512-linux.o and
8321 x32-avx512-linux.o.
8322 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx512.xml.
8323 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx512.xml.
8324 (srv_amd64_xmlfiles): Add i386/amd64-avx512.xml and
8325 i386/x32-avx512.xml.
8326 (srv_i386_linux_xmlfiles): Add i386/i386-avx512-linux.xml.
8327 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx512-linux.xml and
8328 i386/x32-avx512-linux.xml.
8329 * i387-fp.c (num_avx512_k_registers): New constant for number
8330 of K registers.
8331 (num_avx512_zmmh_low_registers): New constant for number of
8332 lower ZMM registers (0-15).
8333 (num_avx512_zmmh_high_registers): New constant for number of
8334 higher ZMM registers (16-31).
8335 (num_avx512_ymmh_registers): New contant for number of higher
8336 YMM registers (ymm16-31 added by avx521 on x86_64).
8337 (num_avx512_xmm_registers): New constant for number of higher
8338 XMM registers (xmm16-31 added by AVX512 on x86_64).
8339 (struct i387_xsave): Add space for AVX512 registers.
8340 (i387_cache_to_xsave): Change raw buffer size to 64 characters.
8341 Add code to handle AVX512 registers.
8342 (i387_xsave_to_cache): Add code to handle AVX512 registers.
8343 * linux-x86-low.c (init_registers_amd64_avx512_linux): New
8344 prototypei from generated file.
8345 (tdesc_amd64_avx512_linux): Likewise.
8346 (init_registers_x32_avx512_linux): Likewise.
8347 (tdesc_x32_avx512_linux): Likewise.
8348 (init_registers_i386_avx512_linux): Likewise.
8349 (tdesc_i386_avx512_linux): Likewise.
8350 (x86_64_regmap): Add AVX512 registers.
8351 (x86_linux_read_description): Add code to handle AVX512 XSTATE
8352 mask.
8353 (initialize_low_arch): Add code to initialize AVX512 registers.
8354
8355 2014-04-23 Pedro Alves <palves@redhat.com>
8356
8357 * mem-break.c (find_gdb_breakpoint_at): Make static.
8358 * mem-break.h (find_gdb_breakpoint_at): Delete declaration.
8359
8360 2014-04-23 Pedro Alves <palves@redhat.com>
8361
8362 * i386-low.c: Don't include break-common.h here.
8363 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8364 prototype to take target_hw_bp_type as argument instead of a Z
8365 packet char.
8366 * i386-low.h: Include break-common.h here.
8367 (Z_packet_to_hw_type): Declare.
8368 (i386_low_insert_watchpoint, i386_low_remove_watchpoint): Change
8369 prototypes.
8370 * linux-x86-low.c (x86_insert_point): Convert the packet number to
8371 a target_hw_bp_type before calling i386_low_insert_watchpoint.
8372 (x86_remove_point): Convert the packet number to a
8373 target_hw_bp_type before calling i386_low_remove_watchpoint.
8374 * win32-i386-low.c (i386_insert_point): Convert the packet number
8375 to a target_hw_bp_type before calling i386_low_insert_watchpoint.
8376 (i386_remove_point): Convert the packet number to a
8377 target_hw_bp_type before calling i386_low_remove_watchpoint.
8378
8379 2014-04-23 Pedro Alves <palves@redhat.com>
8380
8381 * utils.h (perror_with_name): Add ATTRIBUTE_NORETURN.
8382
8383 2014-04-10 Pedro Alves <palves@redhat.com>
8384
8385 * mem-break.c (add_breakpoint_condition, add_breakpoint_commands):
8386 Check if the condition or command is NULL before checking if the
8387 breakpoint is known. On success, return true.
8388 * mem-break.h (add_breakpoint_condition): Document return.
8389 (add_breakpoint_commands): Add describing comment.
8390 * server.c (skip_to_semicolon): New function.
8391 (process_point_options): Use it.
8392
8393 2014-04-09 Pedro Alves <palves@redhat.com>
8394
8395 * linux-low.c (linux_read_loadmap): Pass current_inferior directly
8396 to lwpid_of.
8397
8398 2014-02-27 Pedro Alves <palves@redhat.com>
8399
8400 PR 12702
8401 * inferiors.h (A_I_NEXT, ALL_INFERIORS_TYPE, ALL_PROCESSES): New
8402 macros.
8403 * linux-low.c (delete_lwp, handle_extended_wait): Add debug
8404 output.
8405 (last_thread_of_process_p): Take a PID argument instead of a
8406 thread pointer.
8407 (linux_wait_for_lwp): Delete.
8408 (num_lwps, check_zombie_leaders, not_stopped_callback): New
8409 functions.
8410 (linux_low_filter_event): New function, party factored out from
8411 linux_wait_for_event.
8412 (linux_wait_for_event): Rename to ...
8413 (linux_wait_for_event_filtered): ... this. Add new filter ptid
8414 argument. Partly rewrite. Always use waitpid(-1, WNOHANG) and
8415 sigsuspend. Check for zombie leaders.
8416 (linux_wait_for_event): Reimplement as wrapper around
8417 linux_wait_for_event_filtered.
8418 (linux_wait_1): Handle TARGET_WAITKIND_NO_RESUMED. Assume that if
8419 a normal or signal exit is seen, it's the whole process exiting.
8420 (wait_for_sigstop): No longer a for_each_inferior callback.
8421 Rewrite on top of linux_wait_for_event_filtered.
8422 (stop_all_lwps): Call wait_for_sigstop directly.
8423 * server.c (resume, handle_target_event): Handle
8424 TARGET_WAITKIND_NO_RESUMED.
8425
8426 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8427
8428 * win32-low.c (psapi_get_dll_name,
8429 * win32_CreateToolhelp32Snapshot): Delete.
8430 (win32_CreateToolhelp32Snapshot, win32_Module32First)
8431 (win32_Module32Next, load_toolhelp, toolhelp_get_dll_name):
8432 Delete.
8433 (handle_load_dll): Add function description.
8434 Remove code using psapi_get_dll_name and toolhelp_get_dll_name.
8435
8436 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8437
8438 * win32-low.c (win32_add_one_solib): Add 0x1000 to load_addr.
8439 Add comment.
8440 (win32_add_all_dlls): Remove 0x1000 offset applied to DLL
8441 base address when calling win32_add_one_solib.
8442 (handle_load_dll): Delete local variable load_addr.
8443 Remove 0x1000 offset applied to DLL base address when calling
8444 win32_add_one_solib.
8445 (handle_unload_dll): Add comment.
8446
8447 2014-02-26 Joel Brobecker <brobecker@adacore.com>
8448
8449 * win32-low.c (win32_add_all_dlls): Renames
8450 win32_ensure_ntdll_loaded. Rewrite function documentation.
8451 Adjust implementation to always load all DLLs.
8452 Add 0x1000 offset to DLL base address when calling
8453 win32_add_one_solib.
8454 (child_initialization_done): New static global.
8455 (do_initial_child_stuff): Set child_initialization_done to
8456 zero during child initialization, and 1 after. Replace call
8457 to win32_ensure_ntdll_loaded by call to win32_add_all_dlls.
8458 Add comment.
8459 (match_dll_by_basename, dll_is_loaded_by_basename): Delete.
8460 (handle_unload_dll): Add function documentation.
8461 (get_child_debug_event): Ignore load and unload DLL events
8462 during child initialization.
8463
8464 2014-02-20 Doug Evans <dje@google.com>
8465
8466 Remove global all_lwps.
8467 * inferiors.h (ptid_of): Move here from linux-low.h.
8468 (pid_of, lwpid_of): Ditto.
8469 * linux-aarch64-low.c (debug_reg_change_callback): Update, "entry"
8470 parameter is a struct thread_info * now.
8471 (aarch64_notify_debug_reg_change): Fetch pid from current_inferior
8472 directly. Pass &all_threads to find_inferior instead of &all_lwps.
8473 (aarch64_stopped_data_address): Fetch lwpid from current_inferior
8474 directly.
8475 (aarch64_linux_prepare_to_resume): Fetch ptid from thread.
8476 (aarch64_arch_setup): Fetch lwpid from current_inferior directly.
8477 * linux-arm-low.c (update_registers_callback): Update, "entry"
8478 parameter is a struct thread_info * now.
8479 Fetch lwpid from current_inferior directly.
8480 (arm_insert_point): Pass &all_threads to find_inferior instead of
8481 &all_lwps.
8482 (arm_remove_point): Ditto.
8483 (arm_stopped_by_watchpoint): Fetch lwp from current_inferior.
8484 (arm_prepare_to_resume): Fetch pid from thread.
8485 (arm_read_description): Fetch lwpid from current_inferior directly.
8486 * linux-low.c (all_lwps): Delete.
8487 (delete_lwp): Delete call to remove_inferior.
8488 (handle_extended_wait): Fetch lwpid from thread.
8489 (add_lwp): Don't set lwp->entry.id. Remove call to
8490 add_inferior_to_list.
8491 (linux_attach_lwp_1): Fetch pid from current_inferior directly.
8492 (linux_kill_one_lwp): Fetch ptid,lwpid from thread.
8493 (kill_one_lwp_callback): Ditto.
8494 (linux_kill): Don't dereference NULL pointer.
8495 Fetch ptid,lwpid from thread.
8496 (get_detach_signal): Fetch ptid from thread.
8497 (linux_detach_one_lwp): Fetch ptid,lwpid from thread.
8498 Simplify call to regcache_invalidate_thread.
8499 (delete_lwp_callback): Update, "entry" parameter is a
8500 struct thread_info * now. Fetch pid from thread.
8501 (linux_mourn): Pass &all_threads to find_inferior instead of &all_lwps.
8502 (status_pending_p_callback): Update, "entry" parameter is a
8503 struct thread_info * now. Fetch ptid from thread.
8504 (find_lwp_pid): Update, "entry" parameter is a
8505 struct thread_info * now.
8506 (linux_wait_for_lwp): Fetch pid from thread.
8507 (linux_fast_tracepoint_collecting): Fetch lwpid from thread.
8508 (maybe_move_out_of_jump_pad): Fetch lwpid from current_inferior.
8509 (enqueue_one_deferred_signal): Fetch lwpid from thread.
8510 (dequeue_one_deferred_signal): Ditto.
8511 (cancel_breakpoint): Fetch ptid from current_inferior.
8512 (linux_wait_for_event): Pass &all_threads to find_inferior,
8513 not &all_lwps. Fetch ptid, lwpid from thread.
8514 (count_events_callback): Update, "entry" parameter is a
8515 struct thread_info * now.
8516 (select_singlestep_lwp_callback): Ditto.
8517 (select_event_lwp_callback): Ditto.
8518 (cancel_breakpoints_callback): Ditto.
8519 (linux_cancel_breakpoints): Pass &all_threads to find_inferior,
8520 not &all_lwps.
8521 (select_event_lwp): Ditto. Fetch ptid from event_thread.
8522 (unsuspend_one_lwp): Update, "entry" parameter is a
8523 struct thread_info * now.
8524 (unsuspend_all_lwps): Pass &all_threads to find_inferior,
8525 not &all_lwps.
8526 (linux_stabilize_threads): Ditto. And for for_each_inferior.
8527 Fetch lwpid from thread, not lwp.
8528 (linux_wait_1): Fetch ptid, lwpid from current_inferior.
8529 Pass &all_threads to find_inferior, not &all_lwps.
8530 (send_sigstop): Fetch lwpid from thread, not lwp.
8531 (send_sigstop_callback): Update, "entry" parameter is a
8532 struct thread_info * now.
8533 (suspend_and_send_sigstop_callback): Ditto.
8534 (wait_for_sigstop): Ditto. Fetch ptid, lwpid from thread, lwp.
8535 (stuck_in_jump_pad_callback): Update, "entry" parameter is a
8536 struct thread_info * now.
8537 (move_out_of_jump_pad_callback): Ditto. Fetch ptid, lwpid
8538 from thread, lwp.
8539 (lwp_running): Update, "entry" parameter is a
8540 struct thread_info * now.
8541 (stop_all_lwps): Fetch ptid from thread.
8542 Pass &all_threads to find_inferior, for_each_inferior, not &all_lwps.
8543 (linux_resume_one_lwp): Fetch lwpid from thread.
8544 (linux_set_resume_request): Update, "entry" parameter is a
8545 struct thread_info * now. Fetch pid, lwpid from thread.
8546 (resume_status_pending_p): Update, "entry" parameter is a
8547 struct thread_info * now.
8548 (need_step_over_p): Ditto. Fetch lwpid from thread.
8549 (start_step_over): Fetch lwpid from thread.
8550 (linux_resume_one_thread): Update, "entry" parameter is a
8551 struct thread_info * now. Fetch lwpid from thread.
8552 (linux_resume): Pass &all_threads to find_inferior, not &all_lwps.
8553 (proceed_one_lwp): Update, "entry" parameter is a
8554 struct thread_info * now. Fetch lwpid from thread.
8555 (unsuspend_and_proceed_one_lwp): Update, "entry" parameter is a
8556 struct thread_info * now.
8557 (proceed_all_lwps): Pass &all_threads to find_inferior, not &all_lwps.
8558 (unstop_all_lwps): Ditto. Fetch lwpid from thread.
8559 (regsets_fetch_inferior_registers): Fetch lwpid from current_inferior
8560 directly.
8561 (regsets_store_inferior_registers): Ditto.
8562 (fetch_register, store_register): Ditto.
8563 (linux_read_memory, linux_write_memory): Ditto.
8564 (linux_request_interrupt): Ditto.
8565 (linux_read_auxv): Ditto.
8566 (linux_xfer_siginfo): Ditto.
8567 (linux_qxfer_spu): Ditto.
8568 (linux_qxfer_libraries_svr4): Ditto.
8569 * linux-low.h (ptid_of, pid_of, lwpid_of): Delete,
8570 moved to inferiors.h.
8571 (get_lwp): Delete.
8572 (get_thread_lwp): Update.
8573 (struct lwp_info): Delete member "entry". Simplify comment for
8574 member "thread".
8575 (all_lwps): Delete.
8576 * linux-mips-low.c (mips_read_description): Fetch lwpid from
8577 current_inferior directly.
8578 (update_watch_registers_callback): Update, "entry" parameter is a
8579 struct thread_info * now. Fetch pid from thread.
8580 (mips_linux_prepare_to_resume): Fetch ptid from thread.
8581 (mips_insert_point): Fetch lwpid from current_inferior.
8582 Pass &all_threads to find_inferior, not &all_lwps.
8583 (mips_remove_point): Pass &all_threads to find_inferior, not &all_lwps.
8584 (mips_stopped_by_watchpoint): Fetch lwpid from current_inferior
8585 directly.
8586 (mips_stopped_data_address): Ditto.
8587 * linux-s390-low.c (s390_arch_setup): Fetch pid from current_inferior
8588 directly.
8589 * linux-tile-low.c (tile_arch_setup): Ditto.
8590 * linux-x86-low.c (x86_get_thread_area): Fetch lwpid from thread.
8591 (update_debug_registers_callback): Update, "entry" parameter is a
8592 struct thread_info * now. Fetch pid from thread.
8593 (i386_dr_low_set_addr): Fetch pid from current_inferior directly.
8594 Pass &all_threads to find_inferior, not &all_lwps.
8595 (i386_dr_low_get_addr): Fetch ptid from current_inferior directly.
8596 (i386_dr_low_set_control): Fetch pid from current_inferior directly.
8597 Pass &all_threads to find_inferior, not &all_lwps.
8598 (i386_dr_low_get_control): Fetch ptid from current_inferior directly.
8599 (i386_dr_low_get_status): Ditto.
8600 (x86_linux_prepare_to_resume): Fetch ptid from thread.
8601 (x86_siginfo_fixup): Fetch lwpid from current_inferior directly.
8602 (x86_linux_read_description): Ditto.
8603 * proc-service.c (ps_getpid): Fetch pid from current_inferior directly.
8604
8605 2014-02-20 Doug Evans <dje@google.com>
8606
8607 * inferiors.c (get_first_inferior): Fix buglet.
8608
8609 2014-02-19 Doug Evans <dje@google.com>
8610
8611 * gdbthread.h (add_thread): Change result type to struct thread_info *.
8612 * inferiors.c (add_thread): Change result type to struct thread_info *.
8613 All callers updated.
8614 (add_lwp): Call add_thread here instead of in callers.
8615 All callers updated.
8616 * linux-low.h (get_lwp_thread): Rewrite.
8617 (struct lwp_info): New member "thread".
8618
8619 2014-02-19 Doug Evans <dje@google.com>
8620
8621 * linux-low.c (add_lwp): Change result to struct lwp_info *.
8622 All callers updated.
8623
8624 2014-02-19 Doug Evans <dje@google.com>
8625
8626 * inferiors.c (add_thread): Fix whitespace.
8627
8628 2014-02-19 Doug Evans <dje@google.com>
8629
8630 * dll.c (clear_dlls): Replace accessing list implemention details
8631 with API function.
8632 * gdbthread.h (get_first_thread): Declare.
8633 * inferiors.c (for_each_inferior_with_data): New function.
8634 (get_first_thread): New function.
8635 (find_thread_ptid): Simplify.
8636 (get_first_inferior): New function.
8637 (clear_list): Delete.
8638 (one_inferior_p): New function.
8639 (clear_inferior_list): New function.
8640 (clear_inferiors): Update.
8641 * inferiors.h (for_each_inferior_with_data): Declare.
8642 (clear_inferior_list): Declare.
8643 (one_inferior_p): Declare.
8644 (get_first_inferior): Declare.
8645 * linux-low.c (linux_wait_for_event): Replace accessing list
8646 implemention details with API function.
8647 * server.c (target_running): Ditto.
8648 (accumulate_file_name_length): New function.
8649 (emit_dll_description): New function.
8650 (handle_qxfer_libraries): Replace accessing list implemention
8651 details with API function.
8652 (handle_qxfer_threads_worker): New function.
8653 (handle_qxfer_threads_proper): Replace accessing list implemention
8654 details with API function.
8655 (handle_query): Ditto.
8656 (visit_actioned_threads_callback_ftype): New typedef.
8657 (visit_actioned_threads_data): New struct.
8658 (visit_actioned_threads): Rewrite to be find_inferior callback.
8659 (resume): Call find_inferior.
8660 (handle_status): Replace accessing list implemention
8661 details with API function.
8662 (process_serial_event): Replace accessing list implemention details
8663 with API function.
8664 * target.c (set_desired_inferior): Replace accessing list implemention
8665 details with API function.
8666 * tracepoint.c (same_process_p): New function.
8667 (gdb_agent_about_to_close): Replace accessing list implemention
8668 details with API function.
8669 * win32-low.c (child_delete_thread): Replace accessing list
8670 implemention details with API function.
8671 (match_dll_by_basename): New function.
8672 (dll_is_loaded_by_basename): New function.
8673 (win32_ensure_ntdll_loaded): Replace accessing list implemention
8674 details call to dll_is_loaded_by_basename.
8675
8676 2014-02-19 Doug Evans <dje@google.com>
8677
8678 * dll.h (struct dll_info): Add comment.
8679 * gdbthread.h (struct thread_info): Add comment.
8680 (current_ptid): Simplify.
8681 * inferiors.c (add_process): Update.
8682 (remove_process): Update.
8683 * inferiors.h (struct process_info): Rename member "head" to "entry".
8684 * linux-low.c (delete_lwp): Update.
8685 (add_lwp): Update.
8686 (last_thread_of_process_p): Update.
8687 (kill_one_lwp_callback, linux_kill): Update.
8688 (status_pending_p_callback): Update.
8689 (wait_for_sigstop): Update. Simplify read of ptid.
8690 (start_step_over): Update.
8691 * linux-low.h (ptid_of, pid_of, lwpid_of): Update.
8692 (get_lwp_thread): Update.
8693 (struct lwp_info): Rename member "head" to "entry".
8694 * regcache.h (inferior_list_entry): Delete.
8695 * server.c (kill_inferior_callback): Update.
8696 (detach_or_kill_inferior_callback): Update.
8697 (print_started_pid): Update.
8698 (print_attached_pid): Update.
8699 (process_serial_event): Simplify read of ptid.
8700 * thread-db.c (thread_db_create_event): Update.
8701 (thread_db_get_tls_address): Update.
8702 * win32-low.c (current_inferior_ptid): Simplify.
8703
8704 2014-02-19 Tom Tromey <tromey@redhat.com>
8705
8706 * target.h (struct target_ops) <supports_btrace>: Add target_ops
8707 argument.
8708 (target_supports_btrace): Update.
8709
8710 2014-02-14 Yao Qi <yao@codesourcery.com>
8711
8712 * Makefile.in (IPA_OBJS): Append rsp-low-ipa.o.
8713 (rsp-low-ipa.o): New target.
8714
8715 2014-02-12 Tom Tromey <tromey@redhat.com>
8716
8717 * ax.c (gdb_parse_agent_expr): Use hex2bin, not
8718 convert_ascii_to_int.
8719 * regcache.c (registers_to_string): Likewise.
8720 * remote-utils.c (decode_M_packet): Likewise.
8721 * server.c (process_serial_event): Likewise.
8722
8723 2014-02-12 Tom Tromey <tromey@redhat.com>
8724
8725 * server.c (handle_query, handle_v_run): Use hex2bin, not
8726 unhexify.
8727 * tracepoint.c (cmd_qtdpsrc, cmd_qtdv, cmd_qtnotes): Likewise.
8728
8729 2014-02-12 Tom Tromey <tromey@redhat.com>
8730
8731 * ax.c (gdb_unparse_agent_expr): Use bin2hex, not
8732 convert_int_to_ascii.
8733 * regcache.c (registers_to_string, collect_register_as_string):
8734 Likewise.
8735 * remote-utils.c (look_up_one_symbol, relocate_instruction):
8736 Likewise.
8737 * server.c (process_serial_event): Likewise.
8738 * tracepoint.c (cmd_qtstatus, response_source, response_tsv)
8739 (cmd_qtbuffer, cstr_to_hexstr): Likewise.
8740
8741 2014-02-12 Tom Tromey <tromey@redhat.com>
8742
8743 * remote-utils.c (look_up_one_symbol, monitor_output): Use
8744 bin2hex, not hexify.
8745 * tracepoint.c (cmd_qtstatus): Likewise.
8746
8747 2014-02-12 Tom Tromey <tromey@redhat.com>
8748
8749 * remote-utils.c (monitor_output): Pass explicit length to
8750 hexify.
8751
8752 2014-02-12 Tom Tromey <tromey@redhat.com>
8753
8754 * tracepoint.c: Include rsp-low.h.
8755 * server.c: Include rsp-low.h.
8756 * remote-utils.h (convert_ascii_to_int, convert_int_to_ascii)
8757 (unhexify, hexify, remote_escape_output, unpack_varlen_hex): Don't
8758 declare.
8759 * remote-utils.c: Include rsp-low.h.
8760 (fromhex, hexchars, ishex, unhexify, tohex, hexify)
8761 (remote_escape_output, remote_unescape_input, unpack_varlen_hex)
8762 (convert_int_to_ascii, convert_ascii_to_int): Move to
8763 common/rsp-low.c.
8764 * regcache.c: Include rsp-low.h.
8765 * ax.c: Include rsp-low.h.
8766 * Makefile.in (SFILES): Add common/rsp-low.c.
8767 (OBS): Add rsp-low.o.
8768 (rsp-low.o): New target.
8769
8770 2014-02-12 Tom Tromey <tromey@redhat.com>
8771
8772 * utils.h (pulongest, plongest, phex_nz): Don't declare.
8773 Include print-utils.h.
8774 * utils.c (NUMCELLS, CELLSIZE, get_cell, decimal2str, pulongest)
8775 (plongest, thirty_two, phex_nz): Remove.
8776 * Makefile.in (SFILES): Add common/print-utils.c.
8777 (OBS): Add print-utils.o.
8778 (print-utils-ipa.o): New target.
8779 (print-utils.o): New target.
8780 (IPA_OBJS): Add print-utils-ipa.o.
8781
8782 2014-02-06 Tom Tromey <tromey@redhat.com>
8783
8784 * Makefile.in (SFILES): Fix indentation.
8785
8786 2014-02-05 Doug Evans <dje@google.com>
8787
8788 * linux-low.c (linux_wait_for_event): Improve comment.
8789 (linux_wait_1): Keep current_inferior in sync with event_child.
8790
8791 2014-01-22 Doug Evans <dje@google.com>
8792
8793 * gdbthread.h (gdb_id_to_thread): Delete, unused.
8794
8795 2014-01-22 Doug Evans <dje@google.com>
8796
8797 * configure.ac (AC_CHECK_FUNCS): Add test for gettimeofday.
8798 * configure: Regenerate.
8799 * config.in: Regenerate.
8800 * Makefile.in (SFILES): Add debug.c.
8801 (OBS): Add debug.o.
8802 * debug.c: New file.
8803 * debug.h: New file.
8804 * linux-aarch64-low.c (*): Update all debugging printfs to use
8805 debug_printf instead of fprintf.
8806 * linux-arm-low.c (*): Ditto.
8807 * linux-cris-low.c (*): Ditto.
8808 * linux-crisv32-low.c (*): Ditto.
8809 * linux-m32r-low.c (*): Ditto.
8810 * linux-sparc-low.c (*): Ditto.
8811 * linux-x86.c (*): Ditto.
8812 * linux-low.c (*): Ditto.
8813 (linux_wait_1): Add calls to debug_enter, debug_exit.
8814 (linux_wait): Remove redundant debugging printf.
8815 (stop_all_lwps): Add calls to debug_enter, debug_exit.
8816 (linux_resume, unstop_all_lwps): Ditto.
8817 * mem-break.c (*): Update all debugging printfs to use
8818 debug_printf instead of fprintf.
8819 * remote-utils.c (*): Ditto.
8820 * thread-db.c (*): Ditto.
8821 * server.c #include <ctype.h>, "gdb_vecs.h".
8822 (debug_threads): Moved to debug.c.
8823 (*): Update all debugging printfs to use debug_printf instead of
8824 fprintf.
8825 (start_inferior): Replace call to fflush with call to debug_flush.
8826 (monitor_show_help): Mention set debug-format.
8827 (parse_debug_format_options): New function.
8828 (handle_monitor_command): Handle "monitor set debug-format".
8829 (gdbserver_usage): Mention --debug-format.
8830 (main): Parse --debug-format.
8831 * server.h (debug_threads): Declaration moved to debug.h.
8832 #include "debug.h".
8833 * tracepoint.c (trace_debug_1) [!IN_PROCESS_AGENT]: Add version of
8834 trace_debug_1 that uses debug_printf.
8835 (tracepoint_look_up_symbols): Update all debugging printfs to use
8836 debug_printf instead of fprintf.
8837
8838 2014-01-20 Baruch Siach <baruch@tkos.co.il>
8839
8840 * linux-xtensa-low.c: Include asm/ptrace.h instead of
8841 sys/ptrace.h.
8842
8843 2014-01-17 Pedro Alves <palves@redhat.com>
8844
8845 PR build/16445
8846 * linux-x86-low.c: Don't include elf/common.h if ELFMAG0 is
8847 defined after including gdb_proc_service.h.
8848
8849 2014-01-16 Doug Evans <dje@google.com>
8850
8851 * dll.c (UNSPECIFIED_CORE_ADDR): New macro.
8852 (match_dll): Use it.
8853
8854 2014-01-16 Markus Metzger <markus.t.metzger@intel.com>
8855
8856 * target.h (target_ops) <read_btrace>: Change parameters and
8857 return type to allow error reporting.
8858 * server.c (handle_qxfer_btrace): Support delta reads. Pass
8859 trace reading errors on.
8860 * linux-low.c (linux_low_read_btrace): Pass trace reading
8861 errors on.
8862 (linux_low_disable_btrace): New.
8863
8864 2014-01-15 Doug Evans <dje@google.com>
8865
8866 * inferiors.c (thread_id_to_gdb_id): Delete.
8867 * inferiors.h (thread_id_to_gdb_id): Delete.
8868
8869 2014-01-13 Eli Zaretskii <eliz@gnu.org>
8870
8871 * Makefile.in (INCLUDE_CFLAGS): Remove trailing slash from
8872 "-I$(srcdir)/../". Fixes MinGW compilation errors with old GCC
8873 versions.
8874
8875 2014-01-08 Pedro Alves <palves@redhat.com>
8876
8877 * server.c (handle_status): Don't discard previous queued stop
8878 replies or thread's pending status here.
8879 (main) <disconnection>: Do it here instead.
8880
8881 2014-01-08 Pedro Alves <palves@redhat.com>
8882
8883 * gdbthread.h (struct thread_info) <status_pending_p>: New field.
8884 * server.c (visit_actioned_threads, handle_pending_status): New
8885 function.
8886 (handle_v_cont): Factor out parts to ...
8887 (resume): ... this new function. If in all-stop, and a thread
8888 being resumed has a pending status, report it without actually
8889 resuming.
8890 (myresume): Adjust to use the new 'resume' function.
8891 (clear_pending_status_callback, set_pending_status_callback)
8892 (find_status_pending_thread_callback): New functions.
8893 (handle_status): Handle the case of multiple threads having
8894 interesting statuses to report. Report threads' real last signal
8895 instead of always reporting GDB_SIGNAL_TRAP. Look for a thread
8896 with an interesting thread to report the status for, instead of
8897 always reporting the status of the first thread.
8898
8899 2014-01-01 Joel Brobecker <brobecker@adacore.com>
8900
8901 * gdbserver.c (gdbserver_version): Set copyright year to 2014.
8902 * gdbreplay.c (gdbreplay_version): Likewise.
8903
8904 2013-12-18 Yufeng Zhang <yufeng.zhang@arm.com>
8905
8906 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Set
8907 iov.iov_len with the real length in use.
8908
8909 2013-12-13 Joel Brobecker <brobecker@adacore.com>
8910
8911 * Makefile.in (safe-ctype.o, lbasename.o): New rules.
8912 * configure.srv: Add safe-ctype.o and lbasename.o to srv_tgtobj
8913 for all targets that use win32-low.c.
8914 * win32-low.c (win32_ensure_ntdll_loaded): New function.
8915 (do_initial_child_stuff): Add call to win32_ensure_ntdll_loaded.
8916
8917 2013-12-13 Pedro Alves <palves@redhat.com>
8918
8919 * target.c (mywait): Set OURSTATUS->KIND to TARGET_WAITKIND_STOPPED
8920 if equal to TARGET_WAITKIND_LOADED.
8921 * win32-low.c (cached_status): New static global.
8922 (win32_wait): Add declaration.
8923 (do_initial_child_stuff): Flush all initial pending debug events
8924 up to the initial breakpoint.
8925 (win32_wait): If CACHED_STATUS was set, return that instead
8926 of doing a real wait. Remove the code resuming the execution
8927 of the inferior after receiving a TARGET_WAITKIND_LOADED event
8928 during the initial phase. Also remove the code changing
8929 OURSTATUS->KIND from TARGET_WAITKIND_LOADED to
8930 TARGET_WAITKIND_STOPPED.
8931
8932 2013-12-11 Yao Qi <yao@codesourcery.com>
8933
8934 * notif.c (handle_notif_ack): Return 0 if no notification
8935 matches.
8936
8937 2013-11-20 Doug Evans <dje@google.com>
8938
8939 * linux-low.c (linux_set_resume_request): Fix comment.
8940
8941 2013-11-20 Doug Evans <dje@google.com>
8942
8943 * linux-low.c (resume_status_pending_p): Tweak comment.
8944
8945 2013-11-20 Walfred Tedeschi <walfred.tedeschi@intel.com>
8946
8947 * Makefile.in: Add i386-mpx.c, i386-mpx-linux.c, amd64-mpx.c,
8948 amd64-mpx-linux.c, x32-mpx.c and x32-mpx-linux.c generation.
8949 * configure.srv (srv_i386_regobj): Add i386-mpx.o.
8950 (srv_i386_linux_regobj): Add i386-mpx-linux.o.
8951 (srv_amd64_regobj): Add amd64-mpx.o.
8952 (srv_amd64_linux_regobj): Add amd64-mpx-linux.o.
8953 (srv_i386_32bit_xmlfiles): Add i386/32bit-mpx.xml.
8954 (srv_i386_64bit_xmlfiles): Add i386/64bit-mpx.xml.
8955 * i387-fp.c (num_pl_bnd_register) Added constant.
8956 (num_pl_bnd_cfg_registers) Added constant.
8957 (struct i387_xsave) Added reserved area and MPX fields.
8958 (i387_cache_to_xsave, i387_xsave_to_cache) Add MPX.
8959 * linux-x86-low.c (init_registers_i386_mpx_linux): Declare new
8960 function.
8961 (tdesc_i386_mpx_linux): Add MPX amd64 target.
8962 (init_registers_amd64_mpx_linux): Declare new function.
8963 (tdesc_amd64_mpx_linux): Add MPX amd64 target.
8964 (x86_64_regmap): Add MPX registers.
8965 (x86_linux_read_description): Add MPX case.
8966 (initialize_low_arch): Initialize MPX targets.
8967
8968 2013-11-18 Tom Tromey <tromey@redhat.com>
8969
8970 * configure: Rebuild.
8971 * configure.ac: Don't check for stdlib.h.
8972 * gdbreplay.c: Unconditionally include stdlib.h.
8973
8974 2013-11-18 Tom Tromey <tromey@redhat.com>
8975
8976 * config.in: Rebuild.
8977 * configure: Rebuild.
8978 * configure.ac: Don't use AC_HEADER_DIRENT.
8979
8980 2013-11-18 Tom Tromey <tromey@redhat.com>
8981
8982 * server.h: Don't check HAVE_STRING_H.
8983 * gdbreplay.c: Don't check HAVE_STRING_H.
8984 * configure: Rebuild.
8985
8986 2013-11-18 Tom Tromey <tromey@redhat.com>
8987
8988 * Makefile.in (gdbreplay$(EXEEXT)): Depend on and link against
8989 LIBGNU.
8990
8991 2013-11-08 Tom Tromey <tromey@redhat.com>
8992
8993 * configure, config.in: Rebuild.
8994 * configure.ac: Remove unused configury.
8995
8996 2013-11-08 Tom Tromey <tromey@redhat.com>
8997
8998 * acinclude.m4: Include common.m4, codeset.m4.
8999 * configure, config.in: Rebuild.
9000 * configure.ac: Use GDB_AC_COMMON.
9001
9002 2013-11-06 Andreas Arnez <arnez@linux.vnet.ibm.com>
9003
9004 * linux-s390-low.c (HWCAP_S390_TE): New define.
9005 (s390_arch_setup): Consider the TE field in the HWCAP for
9006 determining 'have_regset_tdb'.
9007
9008 2013-10-16 Sergio Durigan Junior <sergiodj@redhat.com>
9009
9010 PR gdb/16014
9011 * tracepoint.c (download_tracepoint_1): Remove unnecessary double
9012 call to sizeof.
9013
9014 2013-10-02 Pedro Alves <palves@redhat.com>
9015
9016 * server.c (process_serial_event): Don't output "GDBserver
9017 exiting" if GDB is connected through stdio.
9018 * target.c (mywait): Likewise, be silent if GDB is connected
9019 through stdio.
9020
9021 2013-10-01 Joel Brobecker <brobecker@adacore.com>
9022
9023 * lynx-low.c (lynx_add_threads_after_attach): New function.
9024 (lynx_attach): Remove call to add_thread. Add call to
9025 lynx_add_threads_after_attach instead.
9026
9027 2013-09-28 Mike Frysinger <vapier@gentoo.org>
9028
9029 * configure.ac (AC_CHECK_HEADERS): Add sys/syscall.h
9030 * config.in, configure: Regenerated.
9031
9032 2013-09-18 Yao Qi <yao@codesourcery.com>
9033
9034 PR server/15959
9035 * server.c (start_inferior): Clear 'resume_info'.
9036
9037 2013-09-16 Jiong Wang <jiwang@tilera.com>
9038
9039 * linux-tile-low.c (tile_regsets): Modify the size field to 64-bit
9040 for each register.
9041
9042 2013-09-16 Jiong Wang <jiwang@tilera.com>
9043
9044 * configure.srv <tilegx*-*-linux*>: Remove linux-osdata.o from and add
9045 linux-tile-low.o to srv_tgtobj.
9046
9047 2013-09-16 Will Newton <will.newton@linaro.org>
9048
9049 * linux-aarch64-low.c (aarch64_linux_set_debug_regs): Zero
9050 out regs.
9051
9052 2013-09-06 Pedro Alves <palves@redhat.com>
9053
9054 * Makefile.in (gdb_proc_service_h, regdef_h, regcache_h)
9055 (signals_def, signals_h, ptid_h, ax_h, agent_h, linux_btrace_h)
9056 (linux_osdata_h, vec_h, gdb_vecs_h, host_defs_h, libiberty_h)
9057 (server_h, gdbthread_h, linux_low_h, linux_ptrace_h)
9058 (gdb_thread_db_h, linux_procfs_h, lynx_low_h, nto_low_h)
9059 (mips_linux_watch_h, i386_low_h, win32_low_h): Delete.
9060
9061 2013-09-06 Pedro Alves <palves@redhat.com>
9062
9063 * Makefile.in (linux-btrace.o, mips-linux-watch.o): Remove
9064 explicit header dependencies and use $COMPILE/$POSTCOMPILE.
9065
9066 2013-09-06 Pedro Alves <palves@redhat.com>
9067
9068 * linux-amd64-ipa.c: Include tracepoint.h.
9069 * linux-i386-ipa.c: Include tracepoint.h.
9070
9071 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9072
9073 * linux-crisv32-low.c (PTRACE_GET_THREAD_AREA): New macro.
9074 (ps_get_thread_area): New function.
9075
9076 2013-09-06 Ricard Wanderlof <ricardw@axis.com>
9077
9078 * linux-crisv32-low.c (elf_gregset_t): Delete typedef.
9079 (initialize_low_arch): Call init_registers_crisv32 rather than
9080 init_register_crisv32.
9081
9082 2013-09-05 Pedro Alves <palves@redhat.com>
9083
9084 * server.h (handle_vFile, hostio_last_error_from_errno): Move
9085 to ...
9086 * hostio.h: ... this new file.
9087 * hostio.c, server.c, linux-low.c, nto-low.c, spu-low,
9088 win32-low.c: Include hostio.h.
9089
9090 2013-09-05 Pedro Alves <palves@redhat.com>
9091
9092 * server.h (gdb_client_data, handler_func, callback_handler_func)
9093 (delete_file_handler, add_file_handler, append_callback_event)
9094 (delete_callback_event, start_event_loop, initialize_event_loop):
9095 Move to event-loop.h and include it.
9096 * event-loop.h: New file.
9097
9098 2013-09-05 Pedro Alves <palves@redhat.com>
9099
9100 * dll.c, inferiors.c, remote-utils.c, server.c: Include "dll.h".
9101 * server.h (struct dll_info, all_dlls, dlls_changed, clear_dlls)
9102 (loaded_dll, unloaded_dll): Move to ...
9103 * dll.h: ... this new file.
9104 * inferiors.c, remote-utils.c, win32-low.c: Include "dll.h".
9105
9106 2013-09-05 Pedro Alves <palves@redhat.com>
9107
9108 * server.h (current_process, get_thread_process, all_processes)
9109 (add_inferior_to_list, for_each_inferior, current_inferior)
9110 (remove_inferior, add_process, remove_process, find_process_pid)
9111 (have_started_inferiors_p, have_attached_inferiors_p)
9112 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id)
9113 (clear_inferiors, find_inferior, find_inferior_id)
9114 (inferior_target_data, set_inferior_target_data)
9115 (inferior_regcache_data, set_inferior_regcache_data): Move to
9116 inferiors.h, and include it.
9117 * inferiors.h: New file.
9118
9119 2013-09-05 Pedro Alves <palves@redhat.com>
9120
9121 * server.h (struct emit_ops, current_insn_ptr, emit_error):
9122 Move ...
9123 * ax.h: ... here.
9124
9125 2013-09-05 Pedro Alves <palves@redhat.com>
9126
9127 * ax.c, linux-low.c, linux-x86-low.c, server.c: Include
9128 tracepoint.h.
9129 * server.h (IPA_BUFSIZ, initialize_tracepoint, tracing)
9130 (disconnected_tracing, tracepoint_look_up_symbols, stop_tracing
9131 (handle_tracepoint_general_set, handle_tracepoint_query)
9132 (tracepoint_finished_step, tracepoint_was_hit)
9133 (release_while_stepping_state_list, current_traceframe)
9134 (in_readonly_region, traceframe_read_mem)
9135 (fetch_traceframe_registers, traceframe_read_sdata)
9136 (traceframe_read_info, struct fast_tpoint_collect_status)
9137 (fast_tracepoint_collecting, force_unlock_trace_buffer)
9138 (handle_tracepoit_bkpts, initialize_low_tracepoint)
9139 (supply_fast_tracepoint_registers)
9140 (supply_static_tracepoint_registers, set_trampoline_buffer_space)
9141 (ipa_tdesc, claim_trampoline_space)
9142 (have_fast_tracepoint_trampoline_buffer, gdb_agent_about_to_close)
9143 (agent_mem_read, agent_get_trace_state_variable_value)
9144 (agent_set_trace_state_variable_value, agent_tsv_read)
9145 (agent_mem_read_string, get_raw_reg_func_addr)
9146 (get_get_tsv_func_addr, get_set_tsv_func_addr): Move to ...
9147 * tracepoint.h: ... this new file.
9148
9149 2013-09-05 Pedro Alves <palves@redhat.com>
9150
9151 * server.h (perror_with_name, error, fatal, warning, paddress)
9152 (pulongest, plongest, phex_nz, pfildes): Move to utils.h, and
9153 include it.
9154 * utils.h: New file.
9155
9156 2013-09-05 Pedro Alves <palves@redhat.com>
9157
9158 * server.h (remote_debug, noack_mode, transport_is_reliable)
9159 (gdb_connected, STDIO_CONNECTION_NAME, remote_connection_is_stdio)
9160 (read_ptid, write_ptid, putpkt, putpkt_binary, putpkt_notif)
9161 (getpkt, remote_prepare, remote_open, remote_close, write_ok)
9162 (write_enn, initialize_async_io, enable_async_io)
9163 (disable_async_io, check_remote_input_interrupt_request)
9164 (convert_ascii_to_int, convert_int_to_ascii, new_thread_notify)
9165 (dead_thread_notify, prepare_resume_reply)
9166 (decode_address_to_semicolon, decode_address, decode_m_packet)
9167 (decode_M_packet, decode_X_packet, decode_xfer_write)
9168 (decode_search_memory_packet, unhexify, hexify)
9169 (remote_escape_output, unpack_varlen_hex, clear_symbol_cache)
9170 (look_up_one_symbol, relocate_instruction)
9171 (monitor_output): Move to remote-utils.h, and include it.
9172 * remote-utils.h: New file.
9173
9174 2013-09-05 Pedro Alves <palves@redhat.com>
9175
9176 * server.h (_): Delete.
9177
9178 2013-09-02 Pedro Alves <palves@redhat.com>
9179
9180 * tracepoint.c (TRACEFRAME_EOB_MARKER_SIZE): New macro.
9181 (init_trace_buffer): Ensure at least TRACEFRAME_EOB_MARKER_SIZE is
9182 allocated.
9183 (trace_buffer_alloc): Use TRACEFRAME_EOB_MARKER_SIZE.
9184
9185 2013-09-02 Pierre Muller <muller@sourceware.org>
9186
9187 * win32-low.c (child_xfer_memory): Check if ReadProcessMemory
9188 or WriteProcessMemory complete successfully and handle
9189 ERROR_PARTIAL_COPY error.
9190
9191 2013-09-02 Pedro Alves <palves@redhat.com>
9192
9193 * server.c (gdb_read_memory): Return -1 on traceframe memory read
9194 error instead of EIO.
9195
9196 2013-08-28 Jan Kratochvil <jan.kratochvil@redhat.com>
9197
9198 PR server/15604
9199 * linux-low.c: Include filestuff.h.
9200 (linux_create_inferior) <pid == 0>: Call close_most_fds.
9201 * lynx-low.c: Include filestuff.h.
9202 (lynx_create_inferior) <pid == 0>: Call close_most_fds.
9203 * server.c: Include filestuff.h.
9204 (main): Call notice_open_fds.
9205 * spu-low.c: Include filestuff.h.
9206 (spu_create_inferior) <pid == 0>: Call close_most_fds.
9207
9208 2013-08-22 Luis Machado <lgustavo@codesourcery.com>
9209
9210 * Makefile.in: Explain why ../target and ../nat are not
9211 listed as include file search paths.
9212 (linux-waitpid.o): New object file rule.
9213 * configure.srv (srv_native_linux_obj): New variable.
9214 Replace all occurrences of linux native object files with
9215 $srv_native_linux_obj.
9216 * linux-low.c: Include nat/linux-nat.h and nat/linux-waitpid.h.
9217 (HAS_NOMMU): Move defining logic to common/linux-ptrace.c.
9218 (linux_enable_event_reporting): Remove declaration.
9219 (my_waitpid): Moved to common/linux-waitpid.c.
9220 (linux_wait_for_event): Pass ptid when calling
9221 linux_enable_event_reporting.
9222 (linux_supports_tracefork_flag): Remove.
9223 (linux_enable_event_reporting): Likewise.
9224 (linux_tracefork_grandchild): Remove.
9225 (STACK_SIZE): Moved to common/linux-ptrace.c.
9226 (linux_tracefork_child): Remove.
9227 (linux_test_for_tracefork): Remove.
9228 (linux_look_up_symbols): Call linux_supports_traceclone.
9229 (initialize_low): Remove call to linux_test_for_tracefork.
9230 * linux-low.h (PTRACE_TYPE_ARG3): Move to
9231 common/linux-ptrace.h.
9232 (PTRACE_TYPE_ARG4): Likewise.
9233 Include linux-ptrace.h.
9234
9235 2013-08-21 Pedro Alves <palves@redhat.com>
9236
9237 * config.in: Renegerate.
9238
9239 2013-08-19 Luis Machado <lgustavo@codesourcery.com>
9240
9241 * Makefile.in (INCLUDE_CFLAGS): Include -I$(srcdir)/../.
9242 (SFILES): Remove $(srcdir)/common/target-common.c and
9243 add $(srcdir)/target/waitstatus.c.
9244 (OBS): Remove target-common.o and add waitstatus.o.
9245 (server_h): Remove $(srcdir)/../common/target-common.h and
9246 add $(srcdir)/../target/resume.h, $(srcdir)/../target/wait.h
9247 and $(srcdir)/../target/waitstatus.h.
9248 (target-common.o): Remove.
9249 (waitstatus.o): New target object file.
9250 * target.h: Do not include target-common.h and
9251 include target/resume.h, target/wait.h and
9252 target/waitstatus.h.
9253
9254 2013-08-13 Luis Machado <lgustavo@codesourcery.com>
9255
9256 * linux-arm-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9257 to PTRACE_TYPE_ARG3.
9258 * linux-low.c: Rename all occurrences of PTRACE_ARG3_TYPE
9259 to PTRACE_TYPE_ARG3 and PTRACE_ARG4_TYPE to
9260 PTRACE_TYPE_ARG4.
9261 * linux-low.h (PTRACE_ARG3_TYPE): Rename to PTRACE_TYPE_ARG3.
9262 (PTRACE_ARG4_TYPE): Rename to PTRACE_TYPE_ARG4.
9263
9264 2013-07-27 Jie Zhang <jie@codesourcery.com>
9265 Daniel Jacobowitz <dan@codesourcery.com>
9266 Yao Qi <yao@codesourcery.com>
9267
9268 * Makefile.in (SFILES): Add common/mips-linux-watch.c.
9269 (mips-linux-watch.o): New rule.
9270 (mips_linux_watch_h): New variable.
9271 * configure.srv <mips*-*-linux*>: Add mips-linux-watch.o to
9272 srv_tgtobj.
9273 * linux-mips-low.c: Include mips-linux-watch.h.
9274 (struct arch_process_info, struct arch_lwp_info): New.
9275 (update_watch_registers_callback): New function.
9276 (mips_linux_new_process, mips_linux_new_thread) New functions.
9277 (mips_linux_prepare_to_resume, mips_insert_point): New
9278 functions.
9279 (mips_remove_point, mips_stopped_by_watchpoint): New
9280 functions.
9281 (rsp_bp_type_to_target_hw_bp_type): New function.
9282 (mips_stopped_data_address): New function.
9283 (the_low_target): Add watchpoint support functions.
9284
9285 2013-07-27 Yao Qi <yao@codesourcery.com>
9286
9287 * i386-low.c: Include break-common.h.
9288 (enum target_hw_bp_type): Remove.
9289
9290 2013-07-24 Luis Machado <lgustavo@codesourcery.com>
9291
9292 * Makefile.in (SFILES): /common/target-common.c.
9293 (OBS): Add target-common.o.
9294 (server_h): Add $(srcdir)/../common/target-common.h.
9295 (target-common.o): New target.
9296 * server.c (queue_stop_reply_callback): Free
9297 status string after use.
9298 * target.c (target_waitstatus_to_string): Remove.
9299 * target.h: Include target-common.h.
9300 (resume_kind): Likewise.
9301 (target_waitkind): Likewise.
9302 (target_waitstatus): Likewise.
9303 (TARGET_WNOHANG): Likewise.
9304
9305 2013-07-04 Yao Qi <yao@codesourcery.com>
9306
9307 * Makefile.in (host_alias): Use @host_noncanonical@.
9308 (target_alias): Use @target_noncanonical@.
9309 * configure.ac: Use ACX_NONCANONICAL_TARGET and
9310 ACX_NONCANONICAL_HOST.
9311 * configure: Regenerated.
9312
9313 Revert:
9314 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9315
9316 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9317 * configure: Rebuild.
9318 * Makefile.in (version_host, version_target): Get from configure.
9319 (version.c): Use $(version_host) and $(version_target).
9320
9321 2013-07-03 Pedro Alves <palves@redhat.com>
9322
9323 * Makefile.in (config.status): Depend on development.sh.
9324 * acinclude.m4: Include libmcheck.m4.
9325 * configure: Regenerate.
9326
9327 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9328
9329 * win32-low.c (winapi_DebugActiveProcessStop): Move the WINAPI
9330 attribute inside the parentheses.
9331 (winapi_DebugSetProcessKillOnExit): Ditto.
9332 (winapi_DebugBreakProcess): Ditto.
9333 (winapi_GenerateConsoleCtrlEvent): Ditto.
9334
9335 2013-07-02 Mircea Gherzan <mircea.gherzan@intel.com>
9336
9337 * notif.h (notif_event): Add a dummy member to avoid compiler
9338 errors.
9339
9340 2013-07-01 Pedro Alves <palves@redhat.com>
9341
9342 * hostio.c (HOSTIO_PATH_MAX): Define.
9343 (require_filename, handle_open, handle_unlink, handle_readlink):
9344 Use it.
9345
9346 2013-07-01 Pedro Alves <palves@redhat.com>
9347
9348 * server.h: Include "pathmax.h".
9349 * linux-low.c: Don't include sys/param.h.
9350 (linux_pid_exe_is_elf_64_file): Use PATH_MAX instead of
9351 MAXPATHLEN.
9352 * win32-low.c: Don't include sys/param.h.
9353 (win32_create_inferior): Use PATH_MAX instead of MAXPATHLEN.
9354
9355 2013-07-01 Pedro Alves <palves@redhat.com>
9356
9357 * event-loop.c: Don't check HAVE_UNISTD_H before including
9358 <unistd.h>.
9359 * gdbreplay.c: Likewise.
9360 * remote-utils.c: Likewise.
9361 * server.c: Likewise.
9362 * configure.ac: Don't check for unistd.h.
9363 * configure: Regenerate.
9364
9365 2013-06-28 Tom Tromey <tromey@redhat.com>
9366
9367 * Makefile.in (version.c): Use version.in, not
9368 common/version.in.
9369
9370 2013-06-28 Mircea Gherzan <mircea.gherzan@intel.com>
9371
9372 * configure.ac (version_host, version_target): Set and AC_SUBST them.
9373 * configure: Rebuild.
9374 * Makefile.in (version_host, version_target): Get from configure.
9375 (version.c): Use $(version_host) and $(version_target).
9376
9377 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9378
9379 Fix trace-status to output user name without trailing colon.
9380 * tracepoint.c (cmd_qtstatus): Remove unnecessary colon from user name.
9381
9382 2013-06-10 Dmitry Kozlov <ddk@codesourcery.com>
9383
9384 Fix trace-status to output proper start-time and stop-time.
9385 * tracepoint.c (cmd_qtstatus): Modify trace-status output to
9386 output start time and stop time in hex as gdb expects.
9387
9388 2013-06-26 Pedro Alves <pedro@codesourcery.com>
9389
9390 * tracepoint.c (build_traceframe_info_xml): Output trace state
9391 variables present in the trace buffer.
9392
9393 2013-06-24 Tom Tromey <tromey@redhat.com>
9394
9395 * Makefile.in (version.c): Use bfd/version.h, common/version.in,
9396 create-version.sh.
9397 (version.o): Remove.
9398 * gdbreplay.c: Include version.h.
9399 (version, host_name): Don't declare.
9400 * server.h: Include version.h.
9401 (version, host_name): Don't declare.
9402
9403 2013-06-12 Pedro Alves <palves@redhat.com>
9404
9405 * linux-x86-low.c (linux_is_elf64): Delete global.
9406 (x86_siginfo_fixup): Replace reference to `linux_is_elf64' global
9407 with local linux_pid_exe_is_elf_64_file use.
9408
9409 2013-06-11 Pedro Alves <palves@redhat.com>
9410
9411 * linux-low.c (regset_disabled, disable_regset): New functions.
9412 (regsets_fetch_inferior_registers)
9413 (regsets_store_inferior_registers): Use them.
9414 (initialize_regsets_info); Don't allocate the disabled_regsets
9415 array here.
9416 * linux-low.h (struct regsets_info) <disabled_regsets>: Extend
9417 comment.
9418
9419 2013-06-11 Pedro Alves <palves@redhat.com>
9420
9421 * linux-low.c (initialize_regsets_info): Use xcalloc instead of
9422 xmalloc.
9423
9424 2013-06-11 Pedro Alves <palves@redhat.com>
9425
9426 * linux-x86-low.c (initialize_low_arch): Call
9427 init_registers_x32_avx_linux.
9428
9429 2013-06-09 Jan Kratochvil <jan.kratochvil@redhat.com>
9430
9431 Fix compatibility with Android Bionic.
9432 * linux-low.c (linux_qxfer_libraries_svr4): Ignore first entry even if
9433 it is not empty.
9434
9435 2013-06-07 Pedro Alves <palves@redhat.com>
9436
9437 PR server/14823
9438 * Makefile.in (OBS): Add tdesc.o.
9439 (IPA_OBJS): Add tdesc-ipa.o.
9440 (tdesc-ipa.o): New rule.
9441 * ax.c (gdb_eval_agent_expr): Adjust register_size call to new
9442 interface.
9443 * linux-low.c (new_inferior): Delete.
9444 (disabled_regsets, num_regsets): Delete.
9445 (linux_add_process): Adjust to set the new per-process
9446 new_inferior flag.
9447 (linux_detach_one_lwp): Adjust to call regcache_invalidate_thread.
9448 (linux_wait_for_lwp): Adjust. Only call arch_setup if the event
9449 was a stop. When calling arch_setup, switch the current inferior
9450 to the thread that got an event.
9451 (linux_resume_one_lwp): Adjust to call regcache_invalidate_thread.
9452 (regsets_fetch_inferior_registers)
9453 (regsets_store_inferior_registers): New regsets_info parameter.
9454 Adjust to use it.
9455 (linux_register_in_regsets): New regs_info parameter. Adjust to
9456 use it.
9457 (register_addr, fetch_register, store_register): New usrregs_info
9458 parameter. Adjust to use it.
9459 (usr_fetch_inferior_registers, usr_store_inferior_registers): New
9460 parameter regs_info. Adjust to use it.
9461 (linux_fetch_registers): Get the current inferior's regs_info, and
9462 adjust to use it.
9463 (linux_store_registers): Ditto.
9464 [HAVE_LINUX_REGSETS] (initialize_regsets_info): New.
9465 (initialize_low): Don't initialize the target_regsets here. Call
9466 initialize_low_arch.
9467 * linux-low.h (target_regsets): Delete declaration.
9468 (struct regsets_info): New.
9469 (struct usrregs_info): New.
9470 (struct regs_info): New.
9471 (struct process_info_private) <new_inferior>: New field.
9472 (struct linux_target_ops): Delete the num_regs, regmap, and
9473 regset_bitmap fields. New field regs_info.
9474 [HAVE_LINUX_REGSETS] (initialize_regsets_info): Declare.
9475 * i387-fp.c (num_xmm_registers): Delete.
9476 (i387_cache_to_fsave, i387_fsave_to_cache): Adjust find_regno
9477 calls to new interface.
9478 (i387_cache_to_fxsave, i387_cache_to_xsave, i387_fxsave_to_cache)
9479 (i387_xsave_to_cache): Adjust find_regno calls to new interface.
9480 Infer the number of xmm registers from the regcache's target
9481 description.
9482 * i387-fp.h (num_xmm_registers): Delete.
9483 * inferiors.c (add_thread): Don't install the thread's regcache
9484 here.
9485 * proc-service.c (gregset_info): Fetch the current inferior's
9486 regs_info. Adjust to use it.
9487 * regcache.c: Include tdesc.h.
9488 (register_bytes, reg_defs, num_registers)
9489 (gdbserver_expedite_regs): Delete.
9490 (get_thread_regcache): If the thread doesn't have a regcache yet,
9491 create one, instead of aborting gdbserver.
9492 (regcache_invalidate_one): Rename to ...
9493 (regcache_invalidate_thread): ... this.
9494 (regcache_invalidate_one): New.
9495 (regcache_invalidate): Only invalidate registers of the current
9496 process.
9497 (init_register_cache): Add target_desc parameter, and use it.
9498 (new_register_cache): Ditto. Assert the target description has a
9499 non zero registers_size.
9500 (regcache_cpy): Add assertions. Adjust.
9501 (realloc_register_cache, set_register_cache): Delete.
9502 (registers_to_string, registers_from_string): Adjust.
9503 (find_register_by_name, find_regno, find_register_by_number)
9504 (register_cache_size): Add target_desc parameter, and use it.
9505 (free_register_cache_thread, free_register_cache_thread_one)
9506 (regcache_release, register_cache_size): New.
9507 (register_size): Add target_desc parameter, and use it.
9508 (register_data, supply_register, supply_register_zeroed)
9509 (supply_regblock, supply_register_by_name, collect_register)
9510 (collect_register_as_string, collect_register_by_name): Adjust.
9511 * regcache.h (struct target_desc): Forward declare.
9512 (struct regcache) <tdesc>: New field.
9513 (init_register_cache, new_register_cache): Add target_desc
9514 parameter.
9515 (regcache_invalidate_thread): Declare.
9516 (regcache_invalidate_one): Delete declaration.
9517 (regcache_release): Declare.
9518 (find_register_by_number, register_cache_size, register_size)
9519 (find_regno): Add target_desc parameter.
9520 (gdbserver_expedite_regs, gdbserver_xmltarget): Delete
9521 declarations.
9522 * remote-utils.c: Include tdesc.h.
9523 (outreg, prepare_resume_reply): Adjust.
9524 * server.c: Include tdesc.h.
9525 (gdbserver_xmltarget): Delete declaration.
9526 (get_features_xml, process_serial_event): Adjust.
9527 * server.h [IN_PROCESS_AGENT] (struct target_desc): Forward
9528 declare.
9529 (struct process_info) <tdesc>: New field.
9530 (ipa_tdesc): Declare.
9531 * tdesc.c: New file.
9532 * tdesc.h: New file.
9533 * tracepoint.c: Include tdesc.h.
9534 [IN_PROCESS_AGENT] (ipa_tdesc): Define.
9535 (get_context_regcache): Adjust to pass ipa_tdesc down.
9536 (do_action_at_tracepoint): Adjust to get the register cache size
9537 from the context regcache's description.
9538 (traceframe_walk_blocks): Adjust to get the register cache size
9539 from the current trace frame's description.
9540 (traceframe_get_pc): Adjust to get current trace frame's
9541 description and pass it down.
9542 (gdb_collect): Adjust to get the register cache size from the
9543 IPA's description.
9544 * linux-amd64-ipa.c (tdesc_amd64_linux): Declare.
9545 (gdbserver_xmltarget): Delete.
9546 (initialize_low_tracepoint): Set the ipa's target description.
9547 * linux-i386-ipa.c (tdesc_i386_linux): Declare.
9548 (initialize_low_tracepoint): Set the ipa's target description.
9549 * linux-x86-low.c: Include tdesc.h.
9550 [__x86_64__] (is_64bit_tdesc): New.
9551 (ps_get_thread_area, x86_get_thread_area): Use it.
9552 (i386_cannot_store_register): Rename to ...
9553 (x86_cannot_store_register): ... this. Use is_64bit_tdesc.
9554 (i386_cannot_fetch_register): Rename to ...
9555 (x86_cannot_fetch_register): ... this. Use is_64bit_tdesc.
9556 (x86_fill_gregset, x86_store_gregset): Adjust register_size calls
9557 to new interface.
9558 (target_regsets): Rename to ...
9559 (x86_regsets): ... this.
9560 (x86_get_pc, x86_set_pc): Adjust register_size calls to new
9561 interface.
9562 (x86_siginfo_fixup): Use is_64bit_tdesc.
9563 [__x86_64__] (tdesc_amd64_linux, tdesc_amd64_avx_linux)
9564 (tdesc_x32_avx_linux, tdesc_x32_linux)
9565 (tdesc_i386_linux, tdesc_i386_mmx_linux, tdesc_i386_avx_linux):
9566 Declare.
9567 (x86_linux_update_xmltarget): Delete.
9568 (I386_LINUX_XSAVE_XCR0_OFFSET): Define.
9569 (have_ptrace_getfpxregs, have_ptrace_getregset): New.
9570 (AMD64_LINUX_USER64_CS): New.
9571 (x86_linux_read_description): New, based on
9572 x86_linux_update_xmltarget.
9573 (same_process_callback): New.
9574 (x86_arch_setup_process_callback): New.
9575 (x86_linux_update_xmltarget): New.
9576 (x86_regsets_info): New.
9577 (amd64_linux_regs_info): New.
9578 (i386_linux_usrregs_info): New.
9579 (i386_linux_regs_info): New.
9580 (x86_linux_regs_info): New.
9581 (x86_arch_setup): Reimplement.
9582 (x86_install_fast_tracepoint_jump_pad): Use is_64bit_tdesc.
9583 (x86_emit_ops): Ditto.
9584 (the_low_target): Adjust. Install x86_linux_regs_info,
9585 x86_cannot_fetch_register, and x86_cannot_store_register.
9586 (initialize_low_arch): New.
9587 * linux-ia64-low.c (tdesc_ia64): Declare.
9588 (ia64_fetch_register): Adjust.
9589 (ia64_usrregs_info, regs_info): New globals.
9590 (ia64_regs_info): New function.
9591 (the_low_target): Adjust.
9592 (initialize_low_arch): New function.
9593 * linux-sparc-low.c (tdesc_sparc64): Declare.
9594 (sparc_fill_gregset_to_stack, sparc_store_gregset_from_stack):
9595 Adjust.
9596 (sparc_arch_setup): New function.
9597 (sparc_regsets_info, sparc_usrregs_info, regs_info): New globals.
9598 (the_low_target): Adjust.
9599 (initialize_low_arch): New function.
9600 * linux-ppc-low.c (tdesc_powerpc_32l, tdesc_powerpc_altivec32l)
9601 (tdesc_powerpc_cell32l, tdesc_powerpc_vsx32l)
9602 (tdesc_powerpc_isa205_32l, tdesc_powerpc_isa205_altivec32l)
9603 (tdesc_powerpc_isa205_vsx32l, tdesc_powerpc_e500l)
9604 (tdesc_powerpc_64l, tdesc_powerpc_altivec64l)
9605 (tdesc_powerpc_cell64l, tdesc_powerpc_vsx64l)
9606 (tdesc_powerpc_isa205_64l, tdesc_powerpc_isa205_altivec64l)
9607 (tdesc_powerpc_isa205_vsx64l): Declare.
9608 (ppc_cannot_store_register, ppc_collect_ptrace_register)
9609 (ppc_supply_ptrace_register, parse_spufs_run, ppc_get_pc)
9610 (ppc_set_pc, ppc_get_hwcap): Adjust.
9611 (ppc_usrregs_info): Forward declare.
9612 (!__powerpc64__) ppc_regmap_adjusted: New global.
9613 (ppc_arch_setup): Adjust to the current process'es target
9614 description.
9615 (ppc_fill_vsxregset, ppc_store_vsxregset, ppc_fill_vrregset)
9616 (ppc_store_vrregset, ppc_fill_evrregset, ppc_store_evrregse)
9617 (ppc_store_evrregset): Adjust.
9618 (target_regsets): Rename to ...
9619 (ppc_regsets): ... this, and make static.
9620 (ppc_usrregs_info, ppc_regsets_info, regs_info): New globals.
9621 (ppc_regs_info): New function.
9622 (the_low_target): Adjust.
9623 (initialize_low_arch): New function.
9624 * linux-s390-low.c (tdesc_s390_linux32, tdesc_s390_linux32v1)
9625 (tdesc_s390_linux32v2, tdesc_s390_linux64, tdesc_s390_linux64v1)
9626 (tdesc_s390_linux64v2, tdesc_s390x_linux64, tdesc_s390x_linux64v1)
9627 (tdesc_s390x_linux64v2): Declare.
9628 (s390_collect_ptrace_register, s390_supply_ptrace_register)
9629 (s390_fill_gregset, s390_store_last_break): Adjust.
9630 (target_regsets): Rename to ...
9631 (s390_regsets): ... this, and make static.
9632 (s390_get_pc, s390_set_pc): Adjust.
9633 (s390_get_hwcap): New target_desc parameter, and use it.
9634 [__s390x__] (have_hwcap_s390_high_gprs): New global.
9635 (s390_arch_setup): Adjust to set the current process'es target
9636 description. Don't adjust the regmap.
9637 (s390_usrregs_info, s390_regsets_info, regs_info): New globals.
9638 [__s390x__] (s390_usrregs_info_3264, s390_regsets_info_3264)
9639 (regs_info_3264): New globals.
9640 (s390_regs_info): New function.
9641 (the_low_target): Adjust.
9642 (initialize_low_arch): New function.
9643 * linux-mips-low.c (tdesc_mips_linux, tdesc_mips_dsp_linux)
9644 (tdesc_mips64_linux, tdesc_mips64_dsp_linux): Declare.
9645 [__mips64] (init_registers_mips_linux)
9646 (init_registers_mips_dsp_linux): Delete defines.
9647 [__mips64] (tdesc_mips_linux, tdesc_mips_dsp_linux): New defines.
9648 (have_dsp): New global.
9649 (mips_read_description): New, based on mips_arch_setup.
9650 (mips_arch_setup): Reimplement.
9651 (get_usrregs_info): New function.
9652 (mips_cannot_fetch_register, mips_cannot_store_register)
9653 (mips_get_pc, mips_set_pc, mips_fill_gregset, mips_store_gregset)
9654 (mips_fill_fpregset, mips_store_fpregset): Adjust.
9655 (target_regsets): Rename to ...
9656 (mips_regsets): ... this, and make static.
9657 (mips_regsets_info, mips_dsp_usrregs_info, mips_usrregs_info)
9658 (dsp_regs_info, regs_info): New globals.
9659 (mips_regs_info): New function.
9660 (the_low_target): Adjust.
9661 (initialize_low_arch): New function.
9662 * linux-arm-low.c (tdesc_arm, tdesc_arm_with_iwmmxt)
9663 (tdesc_arm_with_vfpv2, tdesc_arm_with_vfpv3, tdesc_arm_with_neon):
9664 Declare.
9665 (arm_fill_vfpregset, arm_store_vfpregset): Adjust.
9666 (arm_read_description): New, with bits factored from
9667 arm_arch_setup.
9668 (arm_arch_setup): Reimplement.
9669 (target_regsets): Rename to ...
9670 (arm_regsets): ... this, and make static.
9671 (arm_regsets_info, arm_usrregs_info, regs_info): New globals.
9672 (arm_regs_info): New function.
9673 (the_low_target): Adjust.
9674 (initialize_low_arch): New function.
9675 * linux-m68k-low.c (tdesc_m68k): Declare.
9676 (target_regsets): Rename to ...
9677 (m68k_regsets): ... this, and make static.
9678 (m68k_regsets_info, m68k_usrregs_info, regs_info): New globals.
9679 (m68k_regs_info): New function.
9680 (m68k_arch_setup): New function.
9681 (the_low_target): Adjust.
9682 (initialize_low_arch): New function.
9683 * linux-sh-low.c (tdesc_sharch): Declare.
9684 (target_regsets): Rename to ...
9685 (sh_regsets): ... this, and make static.
9686 (sh_regsets_info, sh_usrregs_info, regs_info): New globals.
9687 (sh_regs_info, sh_arch_setup): New functions.
9688 (the_low_target): Adjust.
9689 (initialize_low_arch): New function.
9690 * linux-bfin-low.c (tdesc_bfin): Declare.
9691 (bfin_arch_setup): New function.
9692 (bfin_usrregs_info, regs_info): New globals.
9693 (bfin_regs_info): New function.
9694 (the_low_target): Adjust.
9695 (initialize_low_arch): New function.
9696 * linux-cris-low.c (tdesc_cris): Declare.
9697 (cris_arch_setup): New function.
9698 (cris_usrregs_info, regs_info): New globals.
9699 (cris_regs_info): New function.
9700 (the_low_target): Adjust.
9701 (initialize_low_arch): New function.
9702 * linux-cris-low.c (tdesc_crisv32): Declare.
9703 (cris_arch_setup): New function.
9704 (cris_regsets_info, 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-m32r-low.c (tdesc_m32r): Declare.
9709 (m32r_arch_setup): New function.
9710 (m32r_usrregs_info, regs_info): New globals.
9711 (m32r_regs_info): Adjust.
9712 (initialize_low_arch): New function.
9713 * linux-tic6x-low.c (tdesc_tic6x_c64xp_linux)
9714 (tdesc_tic6x_c64x_linux, tdesc_tic6x_c62x_linux): Declare.
9715 (tic6x_usrregs_info): Forward declare.
9716 (tic6x_read_description): New function, based on ...
9717 (tic6x_arch_setup): ... this. Reimplement.
9718 (target_regsets): Rename to ...
9719 (tic6x_regsets): ... this, and make static.
9720 (tic6x_regsets_info, tic6x_usrregs_info, regs_info): New globals.
9721 (tic6x_regs_info): New function.
9722 (the_low_target): Adjust.
9723 (initialize_low_arch): New function.
9724 * linux-xtensa-low.c (tdesc_xtensa): Declare.
9725 (xtensa_fill_gregset, xtensa_store_gregset): Adjust.
9726 (target_regsets): Rename to ...
9727 (xtensa_regsets): ... this, and make static.
9728 (xtensa_regsets_info, xtensa_usrregs_info, regs_info): New
9729 globals.
9730 (xtensa_arch_setup, xtensa_regs_info): New functions.
9731 (the_low_target): Adjust.
9732 (initialize_low_arch): New function.
9733 * linux-nios2-low.c (tdesc_nios2_linux): Declare.
9734 (nios2_arch_setup): Set the current process'es tdesc.
9735 (target_regsets): Rename to ...
9736 (nios2_regsets): ... this.
9737 (nios2_regsets_info, nios2_usrregs_info, regs_info): New globals.
9738 (nios2_regs_info): New function.
9739 (the_low_target): Adjust.
9740 (initialize_low_arch): New function.
9741 * linux-aarch64-low.c (tdesc_aarch64): Declare.
9742 (aarch64_arch_setup): Set the current process'es tdesc.
9743 (target_regsets): Rename to ...
9744 (aarch64_regsets): ... this.
9745 (aarch64_regsets_info, aarch64_usrregs_info, regs_info): New globals.
9746 (aarch64_regs_info): New function.
9747 (the_low_target): Adjust.
9748 (initialize_low_arch): New function.
9749 * linux-tile-low.c (tdesc_tilegx, tdesc_tilegx32): Declare
9750 globals.
9751 (target_regsets): Rename to ...
9752 (tile_regsets): ... this.
9753 (tile_regsets_info, tile_usrregs_info, regs_info): New globals.
9754 (tile_regs_info): New function.
9755 (tile_arch_setup): Set the current process'es tdesc.
9756 (the_low_target): Adjust.
9757 (initialize_low_arch): New function.
9758 * spu-low.c (tdesc_spu): Declare.
9759 (spu_create_inferior, spu_attach): Set the new process'es tdesc.
9760 * win32-arm-low.c (tdesc_arm): Declare.
9761 (arm_arch_setup): New function.
9762 (the_low_target): Install arm_arch_setup instead of
9763 init_registers_arm.
9764 * win32-i386-low.c (tdesc_i386, tdesc_amd64): Declare.
9765 (init_windows_x86): Rename to ...
9766 (i386_arch_setup): ... this. Set `win32_tdesc'.
9767 (the_low_target): Adjust.
9768 * win32-low.c (win32_tdesc): New global.
9769 (child_add_thread): Don't create the thread cache here.
9770 (do_initial_child_stuff): Set the new process'es tdesc.
9771 * win32-low.h (struct target_desc): Forward declare.
9772 (win32_tdesc): Declare.
9773 * lynx-i386-low.c (tdesc_i386): Declare global.
9774 (lynx_i386_arch_setup): Set `lynx_tdesc'.
9775 * lynx-low.c (lynx_tdesc): New global.
9776 (lynx_add_process): Set the new process'es tdesc.
9777 * lynx-low.h (struct target_desc): Forward declare.
9778 (lynx_tdesc): Declare global.
9779 * lynx-ppc-low.c (tdesc_powerpc_32): Declare global.
9780 (lynx_ppc_arch_setup): Set `lynx_tdesc'.
9781 * nto-low.c (nto_tdesc): New global.
9782 (do_attach): Set the new process'es tdesc.
9783 * nto-low.h (struct target_desc): Forward declare.
9784 (nto_tdesc): Declare.
9785 * nto-x86-low.c (tdesc_i386): Declare.
9786 (nto_x86_arch_setup): Set `nto_tdesc'.
9787
9788 2013-06-04 Gary Benson <gbenson@redhat.com>
9789
9790 * server.c (handle_query): Add "augmented-libraries-svr4-read+"
9791 to qSupported response when appropriate.
9792 (handle_qxfer_libraries_svr4): Allow qXfer:libraries-svr4:read
9793 with nonzero-length annex.
9794 * linux-low.c (linux_qxfer_libraries_svr4): Parse and handle
9795 arguments supplied in annex.
9796
9797 2013-05-31 Doug Evans <dje@google.com>
9798
9799 PR server/15594
9800 * linux-x86-low.c (ps_get_thread_area): Properly extend address to
9801 64 bits in 64-cross-32 environment.
9802
9803 2013-05-28 Pedro Alves <palves@redhat.com>
9804
9805 * Makefile.in (clean): Remove reference to aarch64-without-fpu.c.
9806 (aarch64-without-fpu.c): Delete rule.
9807 * configure.srv (aarch64*-*-linux*): Remove references to
9808 aarch64-without-fpu.o and aarch64-without-fpu.xml.
9809 * linux-aarch64-low.c (init_registers_aarch64_without_fpu): Remove
9810 declaration.
9811
9812 2013-05-24 Pedro Alves <palves@redhat.com>
9813
9814 * server.c (handle_v_cont) <vCont;r>: Use unpack_varlen_hex
9815 instead of strchr/decode_address. Error if the range isn't split
9816 with a ','. Don't assume there's be a ':' in the action.
9817
9818 2013-05-23 Yao Qi <yao@codesourcery.com>
9819 Pedro Alves <palves@redhat.com>
9820
9821 * linux-low.c (lwp_in_step_range): New function.
9822 (linux_wait_1): If the thread was range stepping and stopped
9823 outside the stepping range, report the stop to GDB. Otherwise,
9824 continue stepping. Add range stepping debug output.
9825 (linux_set_resume_request): Copy the step range from the resume
9826 request to the lwp.
9827 (linux_supports_range_stepping): New.
9828 (linux_target_ops) <supports_range_stepping>: Set to
9829 linux_supports_range_stepping.
9830 * linux-low.h (struct linux_target_ops)
9831 <supports_range_stepping>: New field.
9832 (struct lwp_info) <step_range_start, step_range_end>: New fields.
9833 * linux-x86-low.c (x86_supports_range_stepping): New.
9834 (the_low_target) <supports_range_stepping>: Set to
9835 x86_supports_range_stepping.
9836 * server.c (handle_v_cont): Handle 'r' action.
9837 (handle_v_requests): Append ";r" if the target supports range
9838 stepping.
9839 * target.h (struct thread_resume) <step_range_start,
9840 step_range_end>: New fields.
9841 (struct target_ops) <supports_range_stepping>:
9842 New field.
9843 (target_supports_range_stepping): New macro.
9844
9845 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9846
9847 * lynx-low.c (lynx_resume): Fix null_ptid/minus_one_ptid
9848 confusion in comment.
9849
9850 2013-05-17 Joel Brobecker <brobecker@adacore.com>
9851
9852 * lynx-low.c (struct process_info_private): New type.
9853 (lynx_add_process): New function.
9854 (lynx_create_inferior, lynx_attach): Replace calls to
9855 add_process by calls to lynx_add_process.
9856 (lynx_resume): If PTID is null, then try using
9857 current_process()->private->last_wait_event_ptid.
9858 Add comments.
9859 (lynx_clear_inferiors): Delete. The contents of that function
9860 has been inlined in lynx_mourn;
9861 (lynx_wait_1): Save the ptid in the process's private data.
9862 (lynx_mourn): Free the process' private data. Replace call
9863 to lynx_clear_inferiors by call to clear_inferiors.
9864
9865 2013-05-17 Yao Qi <yao@codesourcery.com>
9866
9867 * i386-low.c (i386_length_and_rw_bits): Move the comment to
9868 the right place.
9869
9870 2013-05-16 Luis Machado <lgustavo@codesourcery.com>
9871
9872 * linux-low.c: Move definition checks upwards for PT_TEXT_ADDR,
9873 PT_DATA_ADDR and PT_TEXT_END_ADDR. Update comments.
9874 (linux_read_offsets): Remove PT_TEXT_ADDR, PT_DATA_ADDR and
9875 PT_TEXT_END_ADDR guards. Update comments.
9876 (linux_target_op) <read_offsets>: Conditionally define to
9877 linux_read_offsets if the target is UCLIBC and if it defines
9878 PT_TEXT_ADDR, PT_DATA_ADDR and PT_TEXT_END_ADDR.
9879
9880 2013-05-06 Sandra Loosemore <sandra@codesourcery.com>
9881 Andrew Jenner <andrew@codesourcery.com>
9882
9883 * Makefile.in (SFILES): Add linux-nios2-low.c.
9884 (clean): Add action to delete nios2-linux.c.
9885 (nios2-linux.c): New rule.
9886 * configure.srv: Add nios2*-*-linux*.
9887 * linux-nios2-low.c: New.
9888
9889 2013-05-03 Hafiz Abid Qadeer <abidh@codesourcery.com>
9890
9891 * tracepoint.c (cmd_qtinit): Call 'stop_tracing'.
9892
9893 2013-04-25 Hui Zhu <hui@codesourcery.com>
9894
9895 PR gdb/15186
9896 * ax.c (ax_printf): Add fflush.
9897
9898 2013-04-22 Tom Tromey <tromey@redhat.com>
9899
9900 * Makefile.in (SFILES): Add filestuff.c.
9901 (OBS): Add filestuff.o.
9902 (filestuff.o): New target.
9903 * config.in, configure: Rebuild.
9904 * configure.ac: Check for fdwalk, pipe2.
9905
9906 2013-04-17 Pedro Alves <palves@redhat.com>
9907
9908 * configure.ac (USE_THREAD_DB): Delete variable.
9909 (if test "$srv_linux_thread_db" = "yes"): AC_DEFINE USE_THREAD_DB.
9910 Don't AC_SUBST USE_THREAD_DB.
9911 * Makefile.in (INTERNAL_CFLAGS): Remove @USE_THREAD_DB@.
9912 * config.in, configure: Regenerate.
9913
9914 2013-04-16 Pedro Alves <palves@redhat.com>
9915
9916 * linux-low.h (struct lwp_info) <thread_known>: Move under
9917 the USE_THREAD_DB #ifdef.
9918
9919 2013-04-16 Pedro Alves <palves@redhat.com>
9920
9921 * Makefile.in (INTERNAL_CFLAGS): Add @USE_THREAD_DB@.
9922 (linux-low.o): Delete rule.
9923 * linux-low.h: Always include "gdb_thread_db.h" instead of
9924 conditionally including thread_db.h.
9925 (struct lwp_info) <th>: Guard with #ifdef USE_THREAD_DB instead of
9926 HAVE_THREAD_DB_H.
9927
9928 2013-04-07 Jan Kratochvil <jan.kratochvil@redhat.com>
9929
9930 * Makefile.in (install-only): Fix make install regression.
9931
9932 2013-04-05 Jan Kratochvil <jan.kratochvil@redhat.com>
9933
9934 Convert man pages to texinfo, new gdbinit.5 texinfo page.
9935 * Makefile.in (install-only): Remove $(man1dir) and gdbserver.1
9936 installation.
9937 * gdbserver.1: Remove.
9938
9939 2013-03-22 Pedro Alves <palves@redhat.com>
9940
9941 * linux-low.c (handle_extended_wait): Don't call
9942 linux_enable_event_reporting.
9943
9944 2013-03-15 Tony Theodore <tonyt@logyst.com>
9945
9946 PR build/9098:
9947 * Makefile.in (SHELL): Use @SHELL@.
9948
9949 2013-03-14 Sergio Durigan Junior <sergiodj@redhat.com>
9950
9951 * tracepoint.c (cmd_qtv): Initialize `val' with zero, silencing
9952 compiler warning.
9953
9954 2013-03-13 Joel Brobecker <brobecker@adacore.com>
9955
9956 * linux-low.c (linux_target_ops) [!HAVE_LINUX_BTRACE]:
9957 Remove extraneous NULL element.
9958
9959 2013-03-13 Yao Qi <yao@codesourcery.com>
9960
9961 * tracepoint.c (traceframe_read_tsv): Look for the last matched
9962 'V' block in trace frame.
9963
9964 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9965
9966 * target.h (struct target_ops): Add btrace ops.
9967 (target_supports_btrace): New macro.
9968 (target_enable_btrace): New macro.
9969 (target_disable_btrace): New macro.
9970 (target_read_btrace): New macro.
9971 * gdbthread.h (struct thread_info): Add btrace field.
9972 * server.c: Include btrace-common.h.
9973 (handle_btrace_general_set): New function.
9974 (handle_btrace_enable): New function.
9975 (handle_btrace_disable): New function.
9976 (handle_general_set): Call handle_btrace_general_set.
9977 (handle_qxfer_btrace): New function.
9978 (struct qxfer qxfer_packets[]): Add btrace entry.
9979 * inferiors.c (remove_thread): Disable btrace.
9980 * linux-low: Include linux-btrace.h.
9981 (linux_low_enable_btrace): New function.
9982 (linux_low_read_btrace): New function.
9983 (linux_target_ops): Add btrace ops.
9984 * configure.srv (i[34567]86-*-linux*): Add linux-btrace.o.
9985 Add srv_linux_btrace=yes.
9986 (x86_64-*-linux*): Add linux-btrace.o.
9987 Add srv_linux_btrace=yes.
9988 * configure.ac: Define HAVE_LINUX_BTRACE.
9989 * config.in: Regenerated.
9990 * configure: Regenerated.
9991
9992 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9993
9994 * server.c (handle_qxfer): Preserve error message if -3 is
9995 returned.
9996 (qxfer): Document the -3 return value.
9997
9998 2013-03-11 Markus Metzger <markus.t.metzger@intel.com>
9999
10000 * Makefile.in (SFILES): Add $(srcdir)/common/linux-btrace.c.
10001 (linux_btrace_h): New variable.
10002 (linux-btrace.o): New rule.
10003
10004 2013-03-08 Stan Shebs <stan@codesourcery.com>
10005 Hafiz Abid Qadeer <abidh@codesourcery.com>
10006
10007 * tracepoint.c (trace_buffer_size): New global.
10008 (DEFAULT_TRACE_BUFFER_SIZE): New define.
10009 (init_trace_buffer): Change to one-argument function. Allocate
10010 trace buffer memory.
10011 (handle_tracepoint_general_set): Call cmd_bigqtbuffer_size to
10012 handle QTBuffer:size packet.
10013 (cmd_bigqtbuffer_size): New function.
10014 (initialize_tracepoint): Call init_trace_buffer with
10015 DEFAULT_TRACE_BUFFER_SIZE.
10016 * server.c (handle_query): Add QTBuffer:size in the
10017 supported packets.
10018
10019 2013-03-07 Yao Qi <yao@codesourcery.com>
10020
10021 * tracepoint.c (cur_action, cur_step_action): Make them unsigned.
10022 (cmd_qtfp): Initialize cur_action and cur_step_action 0 instead
10023 of -1.
10024 (cmd_qtsp): Adjust condition. Do post increment.
10025 Set cur_action and cur_step_action back to 0.
10026
10027 2013-03-07 Jeremy Bennett <jeremy.bennett@embecosm.com>
10028
10029 PR server/15236
10030 * linux-low.c (linux_write_memory): Return early success if LEN is
10031 zero.
10032
10033 2013-03-05 Corinna Vinschen <vinschen@redhat.de>
10034
10035 * configure.srv: Add x86_64-*-cygwin* as target.
10036
10037 2013-02-28 Tom Tromey <tromey@redhat.com>
10038
10039 * configure.ac: Invoke AC_SYS_LARGEFILE.
10040 * configure, config.in: Rebuild.
10041
10042 2013-02-28 Corinna Vinschen <vinschen@redhat.com>
10043
10044 * win32-low.c: Throughout, fix format strings and casts of
10045 printf-like functions to avoid type related warnings on all
10046 platforms.
10047 (get_child_debug_event): Print dwDebugEventCode as hex since
10048 that's how it's usually documented.
10049
10050 2013-02-28 Yao Qi <yao@codesourcery.com>
10051
10052 * tracepoint.c (cmd_qtbuffer): Call phex_nz instead of
10053 pulongest.
10054
10055 2013-02-27 Jiong Wang <jiwang@tilera.com>
10056
10057 * Makefile.in (clean): Remove reg-tilegx.c, reg-tilegx32.c.
10058 (reg-tilegx32.c): New rule.
10059 * configure.srv (tilegx-*-linux*): Add reg-tilegx32.o to srv_regobj.
10060 * linux-tile-low.c (tile_arch_setup): New function. Invoke
10061 different register info initializer according to elf class.
10062 (init_registers_tilgx32): New function. The tilegx32 register info
10063 initializer.
10064 (tile_fill_gregset): Use "uint_reg_t" to represent register size.
10065 (tile_store_gregset): Likewise.
10066
10067 2013-02-27 Yao Qi <yao@codesourcery.com>
10068
10069 * server.c (process_point_options): Print debug message when
10070 debug_threads is true.
10071
10072 2013-02-26 Yao Qi <yao@codesourcery.com>
10073
10074 * tracepoint.c (cmd_qtbuffer): Don't set '\0' in OWN_BUF.
10075
10076 2013-02-19 Pedro Alves <palves@redhat.com>
10077 Kai Tietz <ktietz@redhat.com>
10078
10079 PR gdb/15161
10080
10081 * server.c (handle_query) <CRC check>: Use unpack_varlen_hex
10082 instead of strtoul to extract address from packet.
10083 (process_serial_event) <'z'>: Likewise.
10084
10085 2013-02-18 Yao Qi <yao@codesourcery.com>
10086
10087 * linux-bfin-low.c (the_low_target): Use NULL instead of 0.
10088
10089 2013-02-14 Pedro Alves <palves@redhat.com>
10090
10091 Plug memory leak.
10092
10093 * tracepoint.c (cmd_qtnotes): Free TRACING_USER_NAME,
10094 TRACING_NOTES and TRACING_STOP_NOTE before clobbering.
10095
10096 2013-02-14 Pedro Alves <palves@redhat.com>
10097
10098 * tracepoint.c (cmd_qtdpsrc): Use savestring.
10099
10100 2013-02-14 Pedro Alves <palves@redhat.com>
10101
10102 * tracepoint.c (save_string): Delete.
10103 (add_tracepoint_action): Use savestring instead of save_string.
10104
10105 2013-02-12 Pedro Alves <palves@redhat.com>
10106
10107 * linux-xtensa-low.c: Ditto.
10108 * xtensa-xtregs.c: Ditto.
10109
10110 2013-02-12 Sanimir Agovic <sanimir.agovic@intel.com>
10111
10112 * thread-db.c (thread_db_get_tls_address): NULL pointer check
10113 thread_db.
10114
10115 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10116
10117 * linux-aarch64-low.c (aarch64_arch_setup): Clamp
10118 aarch64_num_wp_regs and aarch64_num_bp_regs to
10119 AARCH64_HWP_MAX_NUM and AARCH64_HBP_MAX_NUM respectively.
10120
10121 2013-02-07 Marcus Shawcroft <marcus.shawcroft@arm.com>
10122
10123 * linux-aarch64-low.c (ps_get_thread_area): Replace
10124 PTRACE_GET_THREAD_AREA with PTRACE_GETREGSET.
10125
10126 2013-02-04 Jim MacArthur <jim.macarthur@arm.com>
10127 Marcus Shawcroft <marcus.shawcroft@arm.com>
10128 Nigel Stephens <nigel.stephens@arm.com>
10129 Yufeng Zhang <yufeng.zhang@arm.com>
10130
10131 * Makefile.in (clean): Remove aarch64.c and aarch64-without-fpu.c.
10132 (aarch64.c, aarch64-without-fpu.c): New targets.
10133 * configure.srv (aarch64*-*-linux*): New.
10134 * linux-aarch64-low.c: New file.
10135
10136 2013-02-04 Marcus Shawcroft <marcus.shawcroft@arm.com>
10137
10138 * linux-low.c (handle_extended_wait, linux_create_inferior)
10139 (linux_attach_lwp_1, linux_kill_one_lwp, linux_attach_one_lwp)
10140 (dequeue_one_deferred_signal, linux_resume_one_thread)
10141 (fetch_register, linux_write_memory, linux_enable_event_reporting)
10142 (linux_tracefork_grandchild, linux_test_for_tracefork)
10143 (linux_read_offsets, linux_xfer_siginfo, linux_xfer_siginfo): Add
10144 PTRACE_ARG3_TYPE and PTRACE_ARG4_TYPE cast to ptrace arguments
10145 where the argument is 0.
10146
10147 2013-01-25 Yao Qi <yao@codesourcery.com>
10148
10149 * event-loop.c: Include "queue.h".
10150 (gdb_event_p): New typedef.
10151 (struct gdb_event) <next_event>: Remove.
10152 (event_queue): Change to QUEUE(gdb_event_p).
10153 (async_queue_event): Remove.
10154 (gdb_event_xfree): New.
10155 (initialize_event_loop): New.
10156 (process_event): Use API from QUEUE.
10157 (wait_for_event): Likewise.
10158 * server.c (main): Call initialize_event_loop.
10159 * server.h (initialize_event_loop): Declare.
10160
10161 2013-01-18 Yao Qi <yao@codesourcery.com>
10162
10163 * ax.h (struct eval_agent_expr_context): New.
10164 (gdb_eval_agent_expr): Update declaration.
10165 * ax.c (gdb_eval_agent_expr): Remove argument REGCACHE and
10166 TFRAME. Add new argument CTX.
10167 * server.h (struct eval_agent_expr_context): Declare.
10168 (agent_mem_read, agent_tsv_read): Update declaration.
10169 (agent_mem_read_string): Likewise.
10170 * tracepoint.c (eval_tracepoint_agent_expr): Remove.
10171 (add_traceframe_block): Add new argument TPOINT.
10172 Increase TPOINT->traceframe_usage.
10173 (do_action_at_tracepoint): Call gdb_eval_agent_expr instead of
10174 eval_tracepoint_agent_expr.
10175 (condition_true_at_tracepoint): Likewise.
10176 (agent_mem_read): Remove argument TFRAME. Add argument CTX.
10177 (agent_mem_read_string, agent_tsv_read): Likewise.
10178
10179 2013-01-16 Yao Qi <yao@codesourcery.com>
10180
10181 * linux-low.c (linux_resume_one_lwp): Don't check
10182 'lwp->bp_reinsert != 0'.
10183
10184 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10185 Pedro Alves <palves@redhat.com>
10186
10187 * lynx-low.c (ptrace_request_to_str): Define a temporary
10188 macro and use it to simplify this function's implementation.
10189
10190 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10191
10192 * lynx-low.c (lynx_resume): Call perror_with_name if lynx_ptrace
10193 sets errno.
10194
10195 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10196
10197 * configure.srv (i[34567]86-*-lynxos*): Set srv_xmlfiles.
10198
10199 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10200
10201 * configure.srv (powerpc-*-lynxos*): Set srv_xmlfiles.
10202
10203 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10204
10205 * lynx-low.c (lynx_resume): Use the resume_info parameter
10206 to determine the ptid for the lynx_ptrace call, unless
10207 it is equal to minus_one_ptid, in which case we use the
10208 ptid of the current_inferior.
10209 (lynx_wait_1): After having received a thread create/exit
10210 event, resume the inferior's execution using the signaling
10211 thread's ptid, rather than the old ptid.
10212
10213 2013-01-07 Joel Brobecker <brobecker@adacore.com>
10214
10215 * lynx-low.c (lynx_resume): Delete variable ret.
10216
10217 2013-01-01 Joel Brobecker <brobecker@adacore.com>
10218
10219 * gdbreplay.c (gdbreplay_version): Update copyright year.
10220 * server.c (gdbserver_version): Likewise.
10221
10222 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10223
10224 * lynx-low.c (lynx_wait_1): Add debug trace before adding
10225 new thread.
10226
10227 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10228
10229 * lynx-low.c (ptrace_request_to_str): Add handling for
10230 PTRACE_GETTRACESIG.
10231
10232 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10233
10234 * lynx-low.c (lynx_attach): Delete variable new_process.
10235
10236 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10237
10238 * lynx-low.c (lynx_create_inferior): Delete variable
10239 new_process.
10240
10241 2012-12-17 Joel Brobecker <brobecker@adacore.com>
10242
10243 * lynx-low.c (ptrace_request_to_str): Do not handle
10244 PTRACE_GETTHREADLIST if this macro does not exist.
10245
10246 2012-12-15 Yao Qi <yao@codesourcery.com>
10247
10248 * Makefile.in (OBS): Add notif.o.
10249 * notif.c, notif.h: New.
10250 * server.c: Include "notif.h".
10251 (struct vstop_notif) <next>: Remove.
10252 <base>: New field.
10253 (queue_stop_reply): Update.
10254 (push_event, send_next_stop_reply): Remove.
10255 (discard_queued_stop_replies): Update.
10256 (notif_stop): New variable.
10257 (handle_v_stopped): Remove.
10258 (handle_v_requests): Don't call handle_v_stopped. Call
10259 handle_ack_notif instead.
10260 (queue_stop_reply_callback): Call notif_event_enque instead
10261 of queue_stop_reply.
10262 (handle_status): Don't call send_next_stop_reply, call
10263 notif_write_event instead.
10264 (kill_inferior_callback): Likewise.
10265 (detach_or_kill_inferior_callback): Likewise.
10266 (main): Call initialize_notif.
10267 (process_serial_event): Call QUEUE_is_empty.
10268 (handle_target_event): Call notif_push instead of push event.
10269 * server.h (push_event): Remove declaration.
10270
10271 2012-12-10 Tom Tromey <tromey@redhat.com>
10272
10273 * Makefile.in (DEPMODE, DEPDIR, depcomp, COMPILE.pre)
10274 (COMPILE.post, COMPILE, POSTCOMPILE, IPAGENT_COMPILE): New
10275 macros.
10276 (.c.o): Rewrite.
10277 (ax-ipa.o, tracepoint-ipa.o, utils-ipa.o, format-ipa.o)
10278 (common-utils-ipa.o, remote-utils-ipa.o, regcache-ipa.o)
10279 (i386-linux-ipa.o, linux-i386-ipa.o, linux-amd64-ipa.o)
10280 (amd64-linux-ipa.o, ax.o): Rewrite.
10281 (event-loop.o, hostio.o, hostio-errno.o, inferiors.o, mem-break.o)
10282 (proc-service.o, regcache.o, remote-utils.o, server.o, target.o)
10283 (thread-db.o, tracepoint.o, utils.o, gdbreplay.o, dll.o): Remove.
10284 (signals.o, linux-procfs.o, linux-ptrace.o, common-utils.o, vec.o)
10285 (gdb_vecs.o, xml-utils.o, linux-osdata.o, ptid.o, buffer.o)
10286 (format.o, agent.o, vasprintf.o, vsnprintf.o): Rewrite.
10287 (i386-low.o, i387-fp.o, linux-low.o, linux-arm-low.o)
10288 (linux-bfin-low.o, linux-cris-low.o, linux-crisv32-low.o)
10289 (linux-ia64-low.o, linux-m32r-low.o, linux-mips-low.o)
10290 (linux-ppc-low.o, linux-s390-low.o, linux-sh-low.o)
10291 (linux-tic6x-low.o, linux-x86-low.o, linux-xtensa-low.o)
10292 (linux-tile-low.o, lynx-low.o, lynx-ppc-low.o, nto-low.o)
10293 (nto-x86-low.o, linux-low.o, win32-low.o, win32-arm-low.o)
10294 (win32-i386-low.o, spu-low.o, reg-arm.o, arm-with-iwmmxt.o)
10295 (arm-with-vfpv2.o, arm-with-vfpv3.o, arm-with-neon.o, reg-bfin.o)
10296 (reg-cris.o, reg-crisv32.o, i386.o, i386-linux.o, i386-avx.o)
10297 (i386-avx-linux.o, i386-mmx.o, i386-mmx-linux.o, reg-ia64.o)
10298 (reg-m32r.o, reg-m68k.o, reg-cf.o, mips-linux.o, mips-dsp-linux.o)
10299 (mips64-linux.o, mips64-dsp-linux.o, powerpc-32.o, powerpc-32l.o)
10300 (powerpc-altivec32l.o, powerpc-cell32l.o, powerpc-vsx32l.o)
10301 (powerpc-isa205-32l.o, powerpc-isa205-altivec32l.o)
10302 (powerpc-isa205-vsx32l.o, powerpc-e500l.o, powerpc-64l.o)
10303 (powerpc-altivec64l.o, powerpc-cell64l.o, powerpc-vsx64l.o)
10304 (powerpc-isa205-64l.o, powerpc-isa205-altivec64l.o)
10305 (powerpc-isa205-vsx64l.o, s390-linux32.o, s390-linux32v1.o)
10306 (s390-linux32v2.o, s390-linux64.o, s390-linux64v1.o)
10307 (s390-linux64v2.o, s390x-linux64.o, s390x-linux64v1.o)
10308 (s390x-linux64v2.o, tic6x-c64xp-linux.o, tic6x-c64x-linux.o)
10309 (tic6x-c62x-linux.o, reg-sh.o, reg-sparc64.o, reg-spu.o, amd64.o)
10310 (amd64-linux.o, amd64-avx.o, amd64-avx-linux.o, x32.o)
10311 (x32-linux.o, x32-avx.o, x32-avx-linux.o, reg-xtensa.o)
10312 (reg-tilegx.o): Remove.
10313 (all_object_files): New macro.
10314 Include .deps files.
10315 * aclocal.m4, configure: Rebuild.
10316 * acinclude.m4: Include depstand.m4, lead-dot.m4.
10317 * configure.ac: Invoke ZW_CREATE_DEPDIR,
10318 ZW_PROG_COMPILER_DEPENDENCIES. Compute GMAKE condition.
10319
10320 2012-12-05 Tom Tromey <tromey@redhat.com>
10321
10322 PR gdb/14917:
10323 * server.h (current_insn_ptr, emit_error): Declare 'extern'.
10324
10325 2012-11-28 Markus Metzger <markus.t.metzger@intel.com>
10326
10327 * configure.ac: Check for linux/perf_event.h.
10328 * config.in: Regenerated.
10329 * configure: Regenerated.
10330
10331 2012-11-26 Maxime Villard <rustyBSD@gmx.fr>
10332
10333 * hostio.c (handle_readlink): Decrease buffer size
10334 parameter passed to readlink by one byte.
10335
10336 2012-11-26 Yao Qi <yao@codesourcery.com>
10337
10338 * configure.ac (build_warnings): Append '-Wempty-body'.
10339 * configure: Regenerated.
10340 * linux-low.c (linux_create_inferior): Use braces for empty 'if'
10341 body.
10342
10343 2012-11-15 Pierre Muller <muller@sourceware.org>
10344
10345 * configure.ac (AC_CHECK_HEADERS): Add wait.h header.
10346 * config.in: Regenerate.
10347 * configure: Regenerate.
10348 * linux-low.c: Use "gdb_stat.h" header instead of <sys/stat.h> header.
10349 Use "gdb_wait.h" header instead of <sys/wait.h> header.
10350 * lynx-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10351 * remote-utils.c: Use "gdb_stat.h" header instead of <sys/stat.h>
10352 header.
10353 * server.c: Remove HAVE_WAIT_H conditional. Use "gdb_wait.h" header
10354 instead of <sys/wait.h> header.
10355 * spu-low.c: Use "gdb_wait.h" header instead of <sys/wait.h> header.
10356
10357 2012-11-13 Markus Metzger <markus.t.metzger@intel.com>
10358
10359 * Makefile.in: (INTERNAL_CFLAGS): Add -DGDBSERVER
10360 (various make rules): Remove -DGDBSERVER
10361
10362 2012-11-09 Yao Qi <yao@codesourcery.com>
10363
10364 * spu-low.c (current_ptid): Move it to ..
10365 * gdbthread.h: ... here. New.
10366 * remote-utils.c (read_ptid): Use macro 'current_ptid'.
10367 * server.c (myresume, process_serial_event): Likewise.
10368 * thread-db.c (thread_db_find_new_threads): Likewise.
10369 * tracepoint.c (run_inferior_command): Likewise.
10370
10371 2012-10-01 Andrew Burgess <aburgess@broadcom.com>
10372
10373 * server.c (handle_search_memory_1): Include access length in
10374 warning message.
10375
10376 2012-09-05 Michael Brandt <michael.brandt@axis.com>
10377
10378 * linux-crisv32-low.c: Fix compile errors.
10379
10380 2012-09-04 Yao Qi <yao@codesourcery.com>
10381
10382 * tracepoint.c (cmd_qtsv): Adjust debug message.
10383 Don't check CUR_TPOINT.
10384
10385 2012-08-28 Yao Qi <yao@codesourcery.com>
10386
10387 * ax.c, tracepoint.c: Replace ATTR_FORMAT with ATTRIBUTE_PRINTF.
10388 * server.h: Include 'libiberty.h' and 'ansidecl.h'.
10389 (ATTR_NORETURN, ATTR_FORMAT, ATTR_MALLOC): Remove.
10390 Remove declarations of xmalloc, xreallloc, xstrdup and
10391 freeargv.
10392 * Makefile.in (libiberty_h): New.
10393 (server_h): Append dependencies 'libiberty.h' and 'ansidecl.h'.
10394 (linux-bfin-low.o): Append dependency 'libiberty.h'.
10395
10396 2012-08-23 Yao Qi <yao@codesourcery.com>
10397
10398 * server.h: Remove declaration of 'xsnprintf'.
10399
10400 2012-08-22 Keith Seitz <keiths@redhat.com>
10401
10402 * server.h: Include build-gnulib-gbserver/config.h.
10403 * gdbreplay.c: Likewise.
10404
10405 2012-08-08 Doug Evans <dje@google.com>
10406
10407 * Makefile.in (SFILES): Add gdb_vecs.c.
10408 (OBS): Add gdb_vecs.o.
10409 (gdb_vecs_h, host_defs_h): New variables.
10410 (thread-db.o): Add $(gdb_vecs_h) dependency.
10411 (gdb_vecs.o): New rule.
10412 * thread-db.c: #include "gdb_vecs.h".
10413 (thread_db_load_search): Use a vector to iterate over path elements.
10414 Handle text appearing after "$pdir".
10415
10416 * configure.ac: Add check for strstr.
10417 * config.in: Regenerate.
10418 * configure: Regenerate.
10419
10420 2012-08-02 Ulrich Weigand <ulrich.weigand@linaro.org>
10421
10422 * hostio.c (handle_pread): If pread fails, fall back to attempting
10423 lseek/read.
10424 (handle_pwrite): Likewise for pwrite.
10425
10426 2012-08-01 Ulrich Weigand <ulrich.weigand@linaro.org>
10427
10428 * linux-arm-low.c (arm_linux_hw_point_initialize): Distinguish
10429 between unsupported TYPE and unimplementable ADDR/LEN combination.
10430 (arm_insert_point): Act on new return value.
10431
10432 2012-07-31 Pedro Alves <palves@redhat.com>
10433
10434 * server.c (process_point_options): Only skip tokens if we find
10435 one that is unrecognized. Don't treat 'X' specially while
10436 skipping unrecognized tokens.
10437
10438 2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
10439
10440 * linux-arm-low.c (arm_linux_hw_point_initialize): Do not attempt
10441 to 4-byte-align HW breakpoint addresses for Thumb.
10442
10443 2012-07-27 Yao Qi <yao@codesourcery.com>
10444
10445 PR remote/14161.
10446
10447 * server.h: Declare gdb_agent_about_to_close.
10448 * target.c (kill_inferior): Include "agent.h".
10449 New. Send command 'kill'.
10450 * target.h (kill_inferior): Removed macro.
10451 * tracepoint.c (gdb_agent_about_to_close): New.
10452 (gdb_agent_helper_thread): Handle command 'close'.
10453 Wait endlessly until the inferior stops.
10454 Install gdb_agent_remove_socket to atexit hook.
10455 (agent_socket_name): New static variable.
10456 (gdb_agent_socket_init): Replace local variable 'name' with
10457 'agent_socket_name'.
10458 (gdb_agent_remove_socket): New.
10459
10460 2012-07-27 Yao Qi <yao@codesourcery.com>
10461
10462 * server.c (process_point_options): Stop at 'X' when parsing.
10463
10464 2012-07-19 Michael Eager <eager@eagercon.com>
10465
10466 * i386-low.c (Z_packet_to_hw_type): Add Z_PACKET_HW_BP, translate
10467 to hw_execute.
10468 * linux-x86-low.c (x86_insert_point, x86_remove_point):
10469 Call i386_low_insert_watchpoint, i386_low_remove_watchpoint to add/del
10470 hardware breakpoint.
10471
10472 2012-07-07 Jan Kratochvil <jan.kratochvil@redhat.com>
10473
10474 * gdbserver/linux-low.c (initialize_low): Call
10475 linux_ptrace_init_warnings.
10476
10477 2012-07-02 Doug Evans <dje@google.com>
10478
10479 * mem-break.c (gdb_no_commands_at_breakpoint): Fix cast from
10480 pointer to int.
10481
10482 2012-07-02 Stan Shebs <stan@codesourcery.com>
10483
10484 * Makefile.in (WARN_CFLAGS_NO_FORMAT): Define.
10485 (ax.o): Add it to build rule.
10486 (ax-ipa.o): Ditto.
10487 (OBS): Add format.o.
10488 (IPA_OBS): Add format.o.
10489 * server.c (handle_query): Claim support for breakpoint commands.
10490 (process_point_options): Add command case.
10491 (process_serial_event): Leave running if there are printfs in
10492 effect.
10493 * mem-break.h (any_persistent_commands): Declare.
10494 (add_breakpoint_commands): Declare.
10495 (gdb_no_commands_at_breakpoint): Declare.
10496 (run_breakpoint_commands): Declare.
10497 * mem-break.c (struct point_command_list): New struct.
10498 (struct breakpoint): New field command_list.
10499 (any_persistent_commands): New function.
10500 (add_commands_to_breakpoint): New function.
10501 (add_breakpoint_commands): New function.
10502 (gdb_no_commands_at_breakpoint): New function.
10503 (run_breakpoint_commands): New function.
10504 * linux-low.c (linux_wait_1): Test for and run breakpoint commands
10505 locally.
10506 * ax.c: Include format.h.
10507 (ax_printf): New function.
10508 (gdb_eval_agent_expr): Add printf opcode.
10509
10510 2012-06-13 Yao Qi <yao@codesourcery.com>
10511
10512 * server.c (start_inferior): Remove duplicated writes to fields
10513 'last_resume_kind' and 'last_status' of 'current_inferior'.
10514
10515 2012-06-12 Yao Qi <yao@codesourcery.com>
10516 Pedro Alves <palves@redhat.com>
10517
10518 * linux-low.c (linux_set_resume_request): Simplify predicate. Add
10519 comment.
10520 * server.c (handle_v_cont): Extend comment.
10521
10522 2012-06-11 Yao Qi <yao@codesourcery.com>
10523
10524 * linux-low.c (linux_attach): Add 'static'.
10525
10526 2012-06-06 Yao Qi <yao@codesourcery.com>
10527
10528 * ax.c (gdb_eval_agent_expr): Print `top' in hex.
10529
10530 2012-06-01 Jan Kratochvil <jan.kratochvil@redhat.com>
10531
10532 Fix gcc -flto compilation warning.
10533 * server.c (main): Make variable multi_mode and attach volatile.
10534
10535 2012-05-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10536
10537 * linux-low.c (get_r_debug): Disable code using DT_MIPS_RLD_MAP
10538 if the platform doesn't know about it.
10539
10540 2012-05-30 Jeff Kenton <jkenton@tilera.com>
10541
10542 * Makefile.in (SFILES): Add linux-tile-low.c.
10543 (linux-tile-low.o, reg-tilegx.o, reg-tilegx.c): New rules.
10544 * configure.srv: Handle tilegx-*-linux*.
10545 * linux-tile-low.c: New file.
10546
10547 2012-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
10548
10549 * linux-low.c (linux_qxfer_libraries_svr4): Return -1 if R_DEBUG is -1.
10550
10551 2012-05-24 Pedro Alves <palves@redhat.com>
10552
10553 PR gdb/7205
10554
10555 Replace TARGET_SIGNAL_ with GDB_SIGNAL_ throughout.
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-22 Maciej W. Rozycki <macro@codesourcery.com>
10564
10565 * linux-low.c (linux_store_registers): Avoid the copying sequence
10566 when no data has been retrieved by ptrace.
10567
10568 2012-05-22 Will Deacon <will.deacon@arm.com>
10569
10570 * linux-low (__UCLIBC__ && !(__UCLIBC_HAS_MMU__ || __ARCH_HAS_MMU__)):
10571 Include asm/ptrace.h.
10572 (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define only if not
10573 already defined.
10574
10575 2012-05-21 Maciej W. Rozycki <macro@codesourcery.com>
10576
10577 * linux-low.c (linux_store_registers): Don't re-retrieve data
10578 with ptrace that has already been obtained from /proc. Always
10579 copy any data retrieved with ptrace to the buffer supplied.
10580
10581 2012-05-11 Yao Qi <yao@codesourcery.com>
10582 Pedro Alves <palves@redhat.com>
10583
10584 * linux-low.c (enum stopping_threads_kind): New.
10585 (stopping_threads): Change type to `enum stopping_threads_kind'.
10586 (handle_extended_wait): If stopping and suspending threads, leave
10587 the new_lwp suspended too.
10588 (linux_wait_for_event): Adjust.
10589 (stop_all_lwps): Set `stopping_threads' to
10590 STOPPING_AND_SUSPENDING_THREADS or STOPPING_THREADS depending on
10591 whether we're suspending threads or just stopping them. Assert no
10592 recursion happens.
10593
10594 2012-04-29 Yao Qi <yao@codesourcery.com>
10595
10596 * server.h: Move some code to ...
10597 * gdbthread.h: ... here. New.
10598 * Makefile.in (inferiors.o, regcache.o): Depends on gdbthread.h
10599 (remote-utils.o, server.o, target.o tracepoint.o): Likewise.
10600 (nto-low.o, win32-low.o): Likewise.
10601 * inferiors.c, linux-low.h, nto-low.c: Include gdbthread.h.
10602 * regcache.c, remote-utils.c, server.c: Likewise.
10603 * target.c, tracepoint.c, win32-low.c: Likewise.
10604
10605 2012-04-24 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10606
10607 * linux-low.h (PTRACE_ARG3_TYPE): Move macro from linux-low.c.
10608 (PTRACE_ARG4_TYPE): Likewise.
10609 (PTRACE_XFER_TYPE): Likewise.
10610 * linux-arm-low.c (arm_prepare_to_resume): Cast third argument of
10611 ptrace to PTRACE_ARG3_TYPE.
10612 * linux-low.c (PTRACE_ARG3_TYPE): Move macro to linux-low.h.
10613 (PTRACE_ARG4_TYPE): Likewise.
10614 (PTRACE_XFER_TYPE): Likewise.
10615 (linux_detach_one_lwp): Cast fourth argument of
10616 ptrace to long then PTRACE_ARG4_TYPE.
10617 (regsets_fetch_inferior_registers): Cast third argument of
10618 ptrace to long then PTRACE_ARG3_TYPE.
10619 (regsets_store_inferior_registers): Likewise.
10620
10621 2012-04-20 Pedro Alves <palves@redhat.com>
10622
10623 * configure: Regenerate.
10624
10625 2012-04-19 Pedro Alves <palves@redhat.com>
10626
10627 * Makefile.in (GNULIB_BUILDDIR): New.
10628 (LIBGNU, INCGNU, GNULIB_H): Adjust.
10629 (SUBDIRS, CLEANDIRS, REQUIRED_SUBDIRS): New.
10630 (all, install-only, uninstall, clean-info, all-lib, clean): No
10631 longer pass GNULIB_FLAGS_TO_PASS. Use subdir_do.
10632 (maintainer-clean realclean distclean): Use subdir_do.
10633 (subdir_do): New.
10634 (gnulib/import/Makefile): Adjust. Replace gnulib/import with
10635 $(GNULIB_BUILDDIR). Don't pass argument to config.status.
10636 * acinclude.m4: Include acx_configure_dir.m4.
10637 * configure.ac: Remove gl_EARLY, gl_INIT, and AM_INIT_AUTOMAKE
10638 calls. Call AC_PROG_RANLIB. Configure gnulib using
10639 ACX_CONFIGURE_DIR.
10640 (GNULIB): New.
10641 (GNULIB_STDINT_H): Adjust.
10642 (AC_OUTPUT): Don't output gnulib/Makefile anymore.
10643 * gdbreplay.c: Include build-gnulib/config.h.
10644 * server.h: Likewise.
10645 * aclocal.m4: Regenerate.
10646 * config.in: Regenerate.
10647 * configure: Regenerate.
10648
10649 2012-04-19 Pedro Alves <palves@redhat.com>
10650
10651 * Makefile.in (LIBGNU, INCGNU): Adjust.
10652 (GNULIB_FLAGS_TO_PASS, GNULIB_H): Adjust.
10653 (all, install-only, uninstall, clean-info, all-lib, clean)
10654 (maintainer-clean, Makefile, gnulib/Makefile): Adjust.
10655 * configure.ac: Adjust AC_OUTPUT output.
10656 * aclocal.m4: Regenerate.
10657 * configure: Regenerate.
10658
10659 2012-04-19 Pedro Alves <palves@redhat.com>
10660
10661 * Makefile.in (generated_files): New.
10662 (server_h): Remove the explicit dependency on config.h, and depend
10663 on $generated_files.
10664
10665 2012-04-19 Pedro Alves <palves@redhat.com>
10666
10667 * Makefile.in (INCGNU): Add -Ignulib.
10668
10669 2012-04-19 Pedro Alves <palves@redhat.com>
10670
10671 * Makefile.in (GNULIB_INCLUDE_DIR): Rename to ...
10672 (INCGNU): ... this, and spell out -I here.
10673 (GNULIB_LIB): Rename to ...
10674 (LIBGNU): ... this.
10675 (INCLUDE_CFLAGS, gdbserver$(EXEEXT), $(GNULIB_LIB) rule): Adjust.
10676
10677 2012-04-19 Pedro Alves <palves@redhat.com>
10678
10679 * config.in: Regenerate.
10680
10681 2012-04-19 Pedro Alves <palves@redhat.com>
10682
10683 * configure.ac: Remove AC_CHECK_DECLS check for memmem.
10684 * server.h (memmem): Remove declaration.
10685 * config.in: Regenerate.
10686 * configure: Regenerate.
10687
10688 2012-04-19 Yao Qi <yao@codesourcery.com>
10689
10690 * Makefile.in (SFILES): Add common/vec.c.
10691 (OBS): Add vec.o.
10692 (vec.o): New rule.
10693
10694 2012-04-19 Yao Qi <yao@codesourcery.com>
10695
10696 * remote-utils.c (prepare_resume_reply): Replace with macro
10697 target_core_of_thread.
10698 * server.c (handle_qxfer_threads_proper): Likewise.
10699 * target.h (traget_core_of_thread): New macro.
10700
10701 2012-04-18 Pedro Alves <palves@redhat.com>
10702
10703 * aclocal.m4: Regenerate.
10704 * configure: Regenerate.
10705
10706 2012-04-16 Yao Qi <yao@codesourcery.com>
10707
10708 * tracepoint.c (cmd_qtstart): Download tracepoints even when they are
10709 duplicated on address.
10710
10711 2012-04-16 Yao Qi <yao@codesourcery.com>
10712
10713 * tracepoint.c (COPY_FIELD_TO_BUF): New macro.
10714 (struct tracepoint_action_ops) <send>: New field.
10715 (m_tracepoint_action_send, r_tracepoint_action_send): New.
10716 (agent_expr_send, x_tracepoint_action_send): New.
10717 (l_tracepoint_action_send): New.
10718 (cmd_qtdp): Download and install tracepoint
10719 according to `use_agent'.
10720 (run_inferior_command): Add one more parameter `len'.
10721 Update callers.
10722 (tracepoint_send_agent): New.
10723 (cmd_qtdp, cmd_qtstart): Call tracepoint_send_agent.
10724
10725 2012-04-16 Yao Qi <yao@codesourcery.com>
10726
10727 * tracepoint.c (download_tracepoints): Moved to ...
10728 (cmd_qtstart): ... here.
10729
10730 2012-04-14 Yao Qi <yao@codesourcery.com>
10731
10732 * tracepoint.c: Include inttypes.h.
10733 (struct collect_memory_action): Use sized types.
10734 (struct tracepoint): Likewise.
10735 (cmd_qtdp, stop_tracing): Update print specifiers.
10736 (cmd_qtp, response_tracepoint): Likewise.
10737 (collect_data_at_tracepoint): Likewise.
10738 (collect_data_at_step): Likewise.
10739
10740 2012-04-14 Yao Qi <yao@codesourcery.com>
10741
10742 Import gnulib module inttypes.
10743 * aclocal.m4, config.in, configure: Regenerated.
10744
10745 2012-04-14 Yao Qi <yao@codesourcery.com>
10746
10747 * Makefile.in (maintainer-clean, realclean, distclean): Remove
10748 Makefile and config.status at last.
10749
10750 2012-04-13 Yao Qi <yao@codesourcery.com>
10751
10752 * tracepoint.c: Include stdint.h unconditionally.
10753
10754 2012-04-13 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10755
10756 * acinclude.m4 (GDBSERVER_HAVE_THREAD_DB_TYPE): New macro based
10757 on BFD_HAVE_SYS_PROCFS_TYPE.
10758 * configure.ac: Look for lwpid_t and psaddr_t in libthread_db.h.
10759 * configure: Regenerate.
10760 * config.in: Likewise.
10761
10762 2012-04-13 H.J. Lu <hongjiu.lu@intel.com>
10763
10764 * Makefile.in (clean): Also remove x32.c x32-linux.c
10765 x32-avx.c x32-avx-linux.c.
10766 (x32.o): New target.
10767 (x32.c): Likewise.
10768 (x32-linux.o): Likewise.
10769 (x32-linux.c): Likewise.
10770 (x32-avx.o): Likewise.
10771 (x32-avx.c): Likewise.
10772 (x32-avx-linux.o): Likewise.
10773 (x32-avx-linux.c): Likewise.
10774
10775 * configure.srv (srv_amd64_regobj): Add x32.o x32-avx.o.
10776 (srv_amd64_linux_regobj): Add x32-linux.o x32-avx-linux.o.
10777 (srv_i386_64bit_xmlfiles): Add i386/x32-core.xml.
10778 (srv_amd64_xmlfiles): Add i386/x32.xml i386/x32-avx.xml.
10779 (srv_amd64_linux_xmlfiles): Add i386/x32-linux.xml
10780 i386/x32-avx-linux.xml.
10781
10782 * linux-x86-low.c (init_registers_x32_linux): New prototype.
10783 (init_registers_x32_avx_linux): Likwise.
10784 (x86_linux_update_xmltarget): Call init_registers_x32_linux
10785 or init_registers_x32_avx_linux if linux_is_elf64 is false.
10786
10787 2012-04-13 Pedro Alves <palves@redhat.com>
10788
10789 * Makefile.in (GNULIB_FLAGS_TO_PASS): New.
10790 (FLAGS_TO_PASS): Don't change or set $top_srcdir, $srcdir and VPATH.
10791 (all, uninstall, clean-info, all-lib, clean, maintainer-clean)
10792 (realclean, distclean): Explicitly pass $GNULIB_FLAGS_TO_PASS to
10793 the sub-make.
10794
10795 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10796
10797 * linux-x86-low.c (compat_x32_clock_t): New.
10798 (compat_x32_siginfo_t): Likewise.
10799 (compat_x32_siginfo_from_siginfo): Likewise.
10800 (siginfo_from_compat_x32_siginfo): Likewise.
10801 (linux_is_elf64): Likewise.
10802 (x86_siginfo_fixup): Call compat_x32_siginfo_from_siginfo
10803 and siginfo_from_compat_x32_siginfo for x32.
10804 (x86_arch_setup): Set linux_is_elf64.
10805
10806 2012-04-12 H.J. Lu <hongjiu.lu@intel.com>
10807
10808 PR gdb/13969
10809 * linux-low.c (linux_pid_exe_is_elf_64_file): Also return the
10810 e_machine field.
10811 (linux_qxfer_libraries_svr4): Update call to elf_64_file_p.
10812 * linux-low.h (linux_pid_exe_is_elf_64_file): Updated.
10813 * linux-x86-low.c (x86_arch_setup): Check if GDBserver is
10814 compatible with process.
10815
10816 2012-04-12 Yao Qi <yao@codesourcery.com>
10817
10818 * Makefile.in: Define abs_top_srcdir and abs_srcdir.
10819 (INCLUDE_CFLAGS): Append GNULIB_INCLUDE_DIR.
10820 (install-only, install-info, clean): Handle sub dir gnulib.
10821 (all-lib, am--refresh): New targets.
10822 (memmem.o): Remove target.
10823 * configure.ac: Remove AC_CONFIG_LIBOBJ_DIR.
10824 Invoke gl_EARLY. Invoke AC_CHECK_PROGS for make.
10825 (AC_REPLACE_FUNCS): Remove memmem.
10826 Invoke gl_INIT and AM_INIT_AUTOMAKE.
10827 (AC_OUTPUT): Generate Makefile in gnulib/.
10828 * aclocal.m4, config.in, configure: Regenerated.
10829
10830 2012-04-10 Maciej W. Rozycki <macro@codesourcery.com>
10831
10832 * linux-low.c (get_r_debug): Handle DT_MIPS_RLD_MAP.
10833
10834 2012-04-05 Pedro Alves <palves@redhat.com>
10835
10836 -Werror=strict-aliasing
10837
10838 * spu-low.c (parse_spufs_run): Avoid dereferencing type-punned
10839 pointer.
10840
10841 2012-04-04 Pedro Alves <palves@redhat.com>
10842
10843 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
10844 (sparc_store_gregset_from_stack, sparc_store_gregset)
10845 (sparc_breakpoint_at): Fix formatting.
10846
10847 2012-03-30 Thiago Jung Bauermann <thiago.bauermann@linaro.org>
10848
10849 * configure.ac: Check whether Elf32_auxv_t and Elf64_auxv_t
10850 are available.
10851 * linux-low.c [HAVE_ELF32_AUXV_T] (Elf32_auxv_t): Add typedef.
10852 [HAVE_ELF64_AUXV_T] (Elf64_auxv_t): Likewise.
10853 * config.in: Regenerate.
10854 * configure: Likewise.
10855
10856 2012-03-29 Pedro Alves <palves@redhat.com>
10857
10858 * linux-low.c (regsets_store_inferior_registers) [__sparc__]:
10859 Correct ptrace arguments.
10860
10861 2012-03-28 Pedro Alves <palves@redhat.com>
10862
10863 * linux-ia64-low.c (ia64_regmap): Map IA64_EC_REGNUM to PT_AR_EC.
10864 (IA64_GR0_REGNUM, IA64_FR0_REGNUM)
10865 (IA64_FR1_REGNUM): New defines.
10866 (ia64_fetch_register): New.
10867 (the_low_target): Install it.
10868 * linux-low.h (struct linux_target_ops) <fetch_register>: New
10869 field.
10870 * linux-low.c (linux_fetch_registers): Try the
10871 the_low_target.fetch_register hook first.
10872
10873 * linux-arm-low.c (the_low_target): Adjust.
10874 * linux-bfin-low.c (the_low_target): Adjust.
10875 * linux-cris-low.c (the_low_target): Adjust.
10876 * linux-crisv32-low.c (the_low_target): Adjust.
10877 * linux-m32r-low.c (the_low_target): Adjust.
10878 * linux-m68k-low.c (the_low_target): Adjust.
10879 * linux-mips-low.c (the_low_target): Adjust.
10880 * linux-ppc-low.c (the_low_target): Adjust.
10881 * linux-s390-low.c (the_low_target): Adjust.
10882 * linux-sh-low.c (the_low_target): Adjust.
10883 * linux-sparc-low.c (the_low_target): Adjust.
10884 * linux-tic6x-low.c (the_low_target): Adjust.
10885 * linux-x86-low.c (the_low_target): Adjust.
10886 * linux-xtensa-low.c (the_low_target): Adjust.
10887
10888 2012-03-26 Pedro Alves <palves@redhat.com>
10889
10890 * server.c (handle_qxfer_libraries): Don't bail early if
10891 the_target->qxfer_libraries_svr4 is not NULL.
10892
10893 2012-03-26 Pedro Alves <palves@redhat.com>
10894
10895 * linux-low.c (linux_qxfer_libraries_svr4): Fix pasto in comment.
10896
10897 2012-03-23 Pedro Alves <palves@redhat.com>
10898
10899 * linux-low.c (linux_qxfer_libraries_svr4): Terminate the
10900 "library-list-svr4" element's start tag when the the DSO list is
10901 empty.
10902
10903 2012-03-23 Pedro Alves <palves@redhat.com>
10904
10905 * linux-low.c (read_one_ptr): Read the inferior's pointer through
10906 a variable whose type size is the same as the inferior's pointer
10907 size.
10908
10909 2012-03-21 Thomas Schwinge <thomas@codesourcery.com>
10910
10911 * linux-arm-low.c (arm_stopped_by_watchpoint): Use siginfo_t instead of
10912 struct siginfo.
10913 * linux-low.c (siginfo_fixup, linux_xfer_siginfo): Likewise.
10914 * linux-x86-low.c (x86_siginfo_fixup): Likewise.
10915 * linux-low.h: Include <signal.h>.
10916 (struct siginfo): Remove forward declaration.
10917 (struct linux_target_ops) <siginfo_fixup>: Use siginfo_t instead of
10918 struct siginfo.
10919
10920 2012-03-21 Mike Frysinger <vapier@gentoo.org>
10921
10922 * .gitignore: Ignore more files.
10923
10924 2012-03-19 Pedro Alves <palves@redhat.com>
10925 Jan Kratochvil <jan.kratochvil@redhat.com>
10926
10927 * server.c (cont_thread, general_thread): Add describing comments.
10928 (start_inferior): Clear `cont_thread'.
10929 (handle_v_cont): Don't set `cont_thread' if resuming all threads
10930 of a process.
10931
10932 2012-03-15 Yao Qi <yao@codesourcery.com>
10933
10934 * tracepoint.c (install_tracepoint): Move duplicated tracepoint
10935 handling to ...
10936 (cmd_qtdp): ... here.
10937
10938 2012-03-15 Yao Qi <yao@codesourcery.com>
10939
10940 * tracepoint.c (struct tracepoint_action_ops): New.
10941 (struct tracepoint_action) [!IN_PROCESS_AGENT] <ops>: New field.
10942 (m_tracepoint_action_download): New.
10943 (r_tracepoint_action_download): New.
10944 (x_tracepoint_action_download): New.
10945 (l_tracepoint_action_download): New.
10946 (add_tracepoint_action): Install `action->ops' according type.
10947 (download_tracepoint_1): Move code `download' function pointer
10948 of various tracepoint_action_ops.
10949
10950 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10951
10952 * linux-low.c (linux_attach_lwp_1): New variable buffer. Call
10953 linux_ptrace_attach_warnings.
10954
10955 2012-03-13 Jan Kratochvil <jan.kratochvil@redhat.com>
10956
10957 * Makefile.in (linux-ptrace.o): New.
10958 * configure.srv (arm*-*-linux*, bfin-*-*linux*, crisv32-*-linux*)
10959 (cris-*-linux*, i[34567]86-*-linux*, ia64-*-linux*, m32r*-*-linux*)
10960 (m68*-*-linux*, m68*-*-uclinux*, mips*-*-linux*, powerpc*-*-linux*)
10961 (s390*-*-linux*, sh*-*-linux*, sparc*-*-linux*, tic6x-*-uclinux)
10962 (x86_64-*-linux*, xtensa*-*-linux*): Add linux-ptrace.o to SRV_TGTOBJ
10963 of these targets.
10964 * linux-low.c (linux_attach_lwp_1): Remove redundent else clause.
10965
10966 2012-03-08 Yao Qi <yao@codesourcery.com>
10967 Pedro Alves <palves@redhat.com>
10968
10969 Fix PR server/13392.
10970 * linux-x86-low.c (amd64_install_fast_tracepoint_jump_pad): Check
10971 offset of JMP insn.
10972 * tracepoint.c (remove_tracepoint): New.
10973 (cmd_qtdp): Call remove_tracepoint when failed to install.
10974
10975 2012-03-07 Pedro Alves <palves@redhat.com>
10976
10977 * linux-low.c (get_detach_signal): New.
10978 (linux_detach_one_lwp): Get rid of a pending SIGSTOP with SIGCONT.
10979 Pass on pending signals to PTRACE_DETACH. Check the result of the
10980 ptrace call.
10981 * server.c (program_signals, program_signals_p): New.
10982 (handle_general_set): Handle QProgramSignals.
10983 * server.h (program_signals, program_signals_p): Declare.
10984
10985 2012-03-05 Pedro Alves <palves@redhat.com>
10986 Jan Kratochvil <jan.kratochvil@redhat.com>
10987
10988 * linux-low.c (get_dynamic): Don't warn when PT_PHDR isn't found.
10989 New comment why.
10990
10991 2012-03-03 Yao Qi <yao@codesourcery.com>
10992
10993 * tracepoint.c (tracepoint_look_up_symbols): Update call to
10994 agent_look_up_symbols.
10995
10996 2012-03-03 Yao Qi <yao@codesourcery.com>
10997
10998 * Makefile.in (linux-low.o): Keep dependence on agent.h.
10999 (linux-x86-low.o): Likewise.
11000 * server.h: Remove in_process_agent_loaded.
11001 * tracepoint.c (in_process_agent_loaded): Removed. Moved it
11002 common/agent.c.
11003 Update callers.
11004
11005 2012-03-03 Yao Qi <yao@codesourcery.com>
11006
11007 * tracepoint.c (gdb_agent_capability): New global.
11008 (in_process_agent_loaded_ust): Renamed to
11009 `in_process_agent_supports_ust'.
11010 Update callers.
11011 (in_process_agent_supports_ust): Call agent_capability_check.
11012 (clear_installed_tracepoints): Assert that agent supports
11013 agent.
11014
11015 2012-03-03 Yao Qi <yao@codesourcery.com>
11016
11017 * linux-low.c (linux_supports_agent): New.
11018 (linux_target_ops): Initialize field `supports_agent' with
11019 linux_supports_agent.
11020 * target.h (struct target_ops) <supports_agent>: New.
11021 (target_supports_agent): New macro.
11022 * server.c (handle_general_set): Handle packet 'QAgent'.
11023 (handle_query): Send `QAgent+'.
11024 * Makefile.in (server.o): Depends on agent.h.
11025
11026 2012-03-03 Yao Qi <yao@codesourcery.com>
11027
11028 * Makefile.in (OBS): Add agent.o.
11029 Add new rule for agent.o.
11030 Track dependence of tracepoint.c on agent.h.
11031 * tracepoint.c (run_inferior_command_1):
11032 (run_inferior_command): Call agent_run_command.
11033 (gdb_ust_connect_sync_socket): Deleted. Move it to
11034 common/agent.c.
11035 (resume_thread, stop_thread): Likewise.
11036 (gdb_ust_socket_init): Renamed to ...
11037 (gdb_agent_socket_init): ... New.
11038 (gdb_ust_thread): Renamed to ...
11039 (gdb_agent_helper_thread): ... New.
11040 (gdb_ust_init): Move some code to ...
11041 (gdb_agent_init): ... here. New.
11042 [HAVE_UST]: Call gdb_ust_init.
11043 (initialize_tracepoint_ftlib): Call gdb_agent_init.
11044 * configure.ac: Add `sys/un.h' to AC_CHECK_HEADERS.
11045 * config.in, configure: Regenerated.
11046
11047 2012-03-02 Pedro Alves <palves@redhat.com>
11048
11049 * inferiors.c (add_pid_to_list, pull_pid_from_list): Delete.
11050 * linux-low.c (struct simple_pid_list): New.
11051 (stopped_pids): New a struct simple_pid_list pointer.
11052 (add_to_pid_list, pull_pid_from_list): New.
11053 (handle_extended_wait): Don't assume the first signal new children
11054 report is SIGSTOP. Adjust call to pull_pid_from_list.
11055 (linux_wait_for_lwp): Adjust.
11056
11057 2012-03-02 Yao Qi <yao@codesourcery.com>
11058
11059 * tracepoint.c (do_action_at_tracepoint): Write `stop_pc' in
11060 debug log.
11061
11062 2012-03-02 Yao Qi <yao@codesourcery.com>
11063
11064 * tracepoint.c (collect_ust_data_at_tracepoint): Remove parameters
11065 `stop_pc' and `tpoint'. Update caller.
11066
11067 2012-03-01 Maciej W. Rozycki <macro@codesourcery.com>
11068
11069 * linux-low.h (linux_target_ops): Add regset_bitmap member.
11070 * linux-low.c (use_linux_regsets): New macro.
11071 [!HAVE_LINUX_REGSETS] (regsets_fetch_inferior_registers): Likewise.
11072 [!HAVE_LINUX_REGSETS] (regsets_store_inferior_registers): Likewise.
11073 (linux_register_in_regsets): New function.
11074 (usr_fetch_inferior_registers): Skip registers covered by
11075 regsets.
11076 (usr_store_inferior_registers): Likewise.
11077 (usr_fetch_inferior_registers): New macro.
11078 (usr_store_inferior_registers): Likewise.
11079 (linux_fetch_registers): Handle mixed regset/non-regset targets.
11080 (linux_store_registers): Likewise.
11081 * linux-mips-low.c (init_registers_mips_dsp_linux): New
11082 prototype.
11083 (init_registers_mips64_dsp_linux): Likewise.
11084 (init_registers_mips_linux): New macro.
11085 (init_registers_mips_dsp_linux): Likewise.
11086 (mips_dsp_num_regs): Likewise.
11087 (DSP_BASE, DSP_CONTROL): New fallback macros.
11088 (mips_base_regs): New macro.
11089 (mips_regmap): Use it. Fix the size.
11090 (mips_dsp_regmap): New variable.
11091 (mips_dsp_regset_bitmap): Likewise.
11092 (mips_arch_setup): New function.
11093 (mips_cannot_fetch_register): Use the_low_target.regmap rather
11094 than mips_regmap.
11095 (mips_cannot_store_register): Likewise.
11096 (the_low_target): Update .arch_setup, .num_regs and .regmap
11097 initializers. Add .regset_bitmap initializer.
11098 * linux-arm-low.c (the_low_target): Add .regset_bitmap
11099 initializer.
11100 * linux-bfin-low.c (the_low_target): Likewise.
11101 * linux-cris-low.c (the_low_target): Likewise.
11102 * linux-crisv32-low.c (the_low_target): Likewise.
11103 * linux-ia64-low.c (the_low_target): Likewise.
11104 * linux-m32r-low.c (the_low_target): Likewise.
11105 * linux-m68k-low.c (the_low_target): Likewise.
11106 * linux-ppc-low.c (the_low_target): Likewise.
11107 * linux-s390-low.c (the_low_target): Likewise.
11108 * linux-sh-low.c (the_low_target): Likewise.
11109 * linux-sparc-low.c (the_low_target): Likewise.
11110 * linux-tic6x-low.c (the_low_target): Likewise.
11111 * linux-x86-low.c (the_low_target): Likewise.
11112 * linux-xtensa-low.c (the_low_target): Likewise.
11113 * configure.srv <mips*-*-linux*>: Add mips-dsp-linux.o and
11114 mips64-dsp-linux.o to srv_regobj. Add mips-dsp-linux.xml,
11115 mips64-dsp-linux.xml, mips-dsp.xml and mips64-dsp.xml to
11116 srv_xmlfiles.
11117 * Makefile.in (mips-dsp-linux.o, mips-dsp-linux.c): New targets.
11118 (mips64-dsp-linux.o, mips64-dsp-linux.c): Likewise.
11119
11120 2012-02-29 Yao Qi <yao@codesourcery.com>
11121 Pedro Alves <palves@redhat.com>
11122
11123 * linux-low.c: (linux_wait_1): Call unsuspend_all_lwps when
11124 `step_over_finished' is true.
11125
11126 2012-02-27 Pedro Alves <palves@redhat.com>
11127
11128 * linux-low.c (pid_is_stopped): Delete, moved to common/.
11129 (linux_attach_lwp_1): Adjust to use linux_proc_pid_is_stopped.
11130
11131 2012-02-27 Pedro Alves <palves@redhat.com>
11132
11133 PR server/9684
11134 * linux-low.c (pid_is_stopped): New.
11135 (linux_attach_lwp_1): Handle attaching to 'T (stopped)' processes.
11136
11137 2012-02-25 Luis Machado <lgustavo@codesourcery.com>
11138
11139 * mem-break.c (clear_gdb_breakpoint_conditions): Fix de-allocation
11140 of conditions.
11141
11142 2012-02-24 Maciej W. Rozycki <macro@codesourcery.com>
11143
11144 * linux-mips-low.c (mips_regmap): Correct the index of $f9.
11145
11146 2012-02-24 Luis Machado <lgustavo@codesourcery>
11147
11148 * server.c (handle_query): Advertise support for target-side
11149 breakpoint condition evaluation.
11150 (process_point_options): New function.
11151 (process_serial_event): When inserting a breakpoint, check for
11152 a target-side condition that should be evaluated.
11153
11154 * mem-break.c: Include regcache.h and ax.h.
11155 (point_cond_list_t): New data structure.
11156 (breakpoint) <cond_list>: New field.
11157 (find_gdb_breakpoint_at): Make non-static.
11158 (delete_gdb_breakpoint_at): Clear any target-side
11159 conditions.
11160 (clear_gdb_breakpoint_conditions): New function.
11161 (add_condition_to_breakpoint): Likewise.
11162 (add_breakpoint_condition): Likewise.
11163 (gdb_condition_true_at_breakpoint): Likewise.
11164 (gdb_breakpoint_here): Return result directly instead
11165 of going through a local variable.
11166
11167 * mem-break.h (find_gdb_breakpoint_at): New prototype.
11168 (clear_gdb_breakpoint_conditions): Likewise.
11169 (add_breakpoint_condition): Likewise.
11170 (gdb_condition_true_at_breakpoint): Likewise.
11171
11172 * linux-low.c (linux_wait_1): Evaluate target-side breakpoint condition.
11173 (need_step_over_p): Take target-side breakpoint condition into
11174 consideration.
11175
11176 2012-02-24 Luis Machado <lgustavo@codesourcery>
11177
11178 * server.h: Include tracepoint.h.
11179 (agent_mem_read, agent_get_trace_state_variable_value,
11180 agent_set_trace_state_variable_value,
11181 agent_tsv_read, agent_mem_read_string, get_get_tsv_func_addr,
11182 get_set_tsv_func_addr): New prototypes.
11183
11184 * ax.h: New include file.
11185 * ax.c: New source file.
11186
11187 * tracepoint.c: Include ax.h.
11188 (gdb_agent_op, gdb_agent_op_names, gdb_agent_op_sizes,
11189 agent_expr, eval_result_type): Move to ax.h.
11190 (parse_agent_expr): Rename to ...
11191 (gdb_parse_agent_expr): ... this, make it non-static and move
11192 to ax.h.
11193 (unparse_agent_expr) Rename to ...
11194 (gdb_unparse_agent_expr): ... this, make it non-static and move
11195 to ax.h.
11196 (eval_agent_expr): Rename to ...
11197 (eval_tracepoint_agent_expr): ... this.
11198 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Remove
11199 forward declarations.
11200 (add_tracepoint_action): Call gdb_parse_agent_expr (...).
11201 (agent_get_trace_state_variable_value): New function.
11202 (agent_set_trace_state_variable_value): New function.
11203 (cmd_qtdp): Call gdb_parse_agent_expr (...).
11204 (response_tracepoint): Call gdb_unparse_agent_expr (...).
11205 (do_action_at_tracepoint): Call eval_tracepoint_agent_expr (...).
11206 (condition_true_at_tracepoint): Likewise.
11207 (parse_agent_expr): Rename to ...
11208 (gdb_parse_agent_expr): ... this and move to ax.c.
11209 (unparse_agent_expr): Rename to ...
11210 (gdb_unparse_agent_expr): ... this and move to ax.c.
11211 (gdb_agent_op_name): Move to ax.c.
11212 (eval_agent_expr): Rename to ...
11213 (gdb_eval_agent_expr): ... this, use regcache passed as parameter
11214 and move to ax.c.
11215 (eval_tracepoint_agent_expr): New function.
11216 (agent_mem_read, agent_mem_read_string, agent_tsv_read): Make
11217 non-static.
11218 (current_insn_ptr, emit_error, struct bytecode_address): Move to
11219 ax.c.
11220 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul, emit_lsh,
11221 emit_rsh_signed, emit_rsh_unsigned, emit_ext, emit_log_not,
11222 emit_bit_and, emit_bit_or, emit_bit_xor, emit_bit_not, emit_equal,
11223 emit_less_signed, emit_less_unsigned, emit_ref, emit_if_goto,
11224 emit_goto, write_goto_address, emit_const, emit_reg, emit_pop,
11225 emit_stack, emit_zero_ext, emit_swap, emit_stack_adjust,
11226 emit_int_call_1, emit_void_call_2, emit_eq_goto, emit_ne_goto,
11227 emit_lt_goto, emit_ge_goto, emit_gt_goto, emit_le_goto): Move to ax.c.
11228 (get_get_tsv_func_addr, get_set_tsv_func_addr): New functions.
11229 (compile_bytecodes): Remove forward declaration.
11230 (is_goto_target): Move to ax.c.
11231 (compile_bytecodes): Move to ax.c and call
11232 agent_get_trace_state_variable_value (...) and
11233 agent_set_trace_state_variable_value (...).
11234
11235 * Makefile.in: Update ax.c and IPA dependencies.
11236
11237 2012-02-24 Pedro Alves <palves@redhat.com>
11238
11239 * tracepoint.c (cmd_bigqtbuffer): Rename as ...
11240 (cmd_bigqtbuffer_circular): ... this. Only handle
11241 'QTBuffer:circular:'.
11242 (handle_tracepoint_general_set): Adjust.
11243
11244 2012-02-16 Yao Qi <yao@codesourcery.com>
11245
11246 * inferiors.c: Move code to ...
11247 * dll.c: .... here. New.
11248 * server.h: Declare clear_dlls.
11249 * Makefile.in (SFILES): Add dll.c.
11250 (OBS): Add dll.o
11251 (dll.o): New rule.
11252
11253 2012-02-11 Yao Qi <yao@codesourcery.com>
11254
11255 * server.c: (handle_monitor_command): Add a new parameter
11256 `own_buf'.
11257 (handle_query): Update caller.
11258
11259 2012-02-09 Joel Brobecker <brobecker@adacore.com>
11260
11261 * configure.ac: Add readlink to AC_CHECK_FUNCS list.
11262 * configure, config.in: Regenerate.
11263 * hostio.c: Provide an alternate implementation if HAVE_READLINK
11264 is not defined.
11265
11266 2012-02-02 Pedro Alves <palves@redhat.com>
11267
11268 Try SIGKILL first, then PTRACE_KILL.
11269 * linux-low.c (linux_kill_one_lwp): New.
11270 (linux_kill_one_lwp): Rename to ...
11271 (kill_one_lwp_callback): ... this. Use the new
11272 linux_kill_one_lwp.
11273
11274 2012-02-02 Pedro Alves <palves@redhat.com>
11275
11276 * tracepoint.c (cmd_qtminftpilen): Return 0 if there's no current
11277 inferior.
11278
11279 2012-01-27 Pedro Alves <palves@redhat.com>
11280
11281 * linux-low.c (linux_child_pid_to_exec_file): Delete.
11282 (elf_64_file_p): Make static.
11283 (linux_pid_exe_is_elf_64_file): New.
11284 * linux-low.h (linux_child_pid_to_exec_file, elf_64_file_p):
11285 Delete declarations.
11286 (linux_pid_exe_is_elf_64_file): Declare.
11287 * linux-x86-low.c (x86_arch_setup): Use
11288 linux_pid_exe_is_elf_64_file.
11289
11290 2012-01-25 Jan Kratochvil <jan.kratochvil@redhat.com>
11291
11292 * linux-low.c (linux_wait_for_event_1): Rename to ...
11293 (linux_wait_for_event): ... here and merge it with former
11294 linux_wait_for_event - new variable wait_ptid, use it.
11295 (linux_wait_for_event): Remove - merge it to linux_wait_for_event_1.
11296
11297 2012-01-23 Pedro Alves <palves@redhat.com>
11298
11299 * server.c (main): Avoid yet another case of infinite loop while
11300 detaching/killing after a longjmp.
11301
11302 2012-01-20 Jan Kratochvil <jan.kratochvil@redhat.com>
11303
11304 Code cleanup.
11305 * linux-low.c (linux_wait_for_event_1): Use ptid_is_pid.
11306
11307 2012-01-20 Ulrich Weigand <ulrich.weigand@linaro.org>
11308
11309 * hostio.c (handle_readlink): New function.
11310 (handle_vFile): Call it to handle "vFile:readlink" packets.
11311
11312 2012-01-20 Pedro Alves <palves@redhat.com>
11313 Ulrich Weigand <ulrich.weigand@linaro.org>
11314
11315 * server.c (handle_v_requests): Only support vAttach and vRun to
11316 start multiple processes when in extended protocol mode.
11317
11318 2012-01-17 Pedro Alves <palves@redhat.com>
11319
11320 * tracepoint.c (initialize_tracepoint): Use mmap instead of
11321 memalign plus mprotect to allocate the scratch buffer.
11322
11323 2012-01-13 Pedro Alves <palves@redhat.com>
11324
11325 * server.c (attach_inferior): Clear `cont_thread'.
11326
11327 2012-01-13 Pedro Alves <palves@redhat.com>
11328
11329 * server.c (main): Avoid infinite loop while detaching/killing
11330 after a longjmp.
11331
11332 2012-01-09 Doug Evans <dje@google.com>
11333
11334 * server.c (start_inferior): Set last_ptid in --wrapper case.
11335
11336 2012-01-06 Yao Qi <yao@codesourcery.com>
11337
11338 * tracepoint.c [IN_PROCESS_AGENT] (debug_threads): Macro
11339 defined.
11340 [IN_PROCESS_AGENT] (debug_agent): New global variable.
11341
11342 2012-01-04 Yao Qi <yao@codesourcery.com>
11343
11344 * tracepoint.c (cmd_qtdp): Print debug message
11345 for static tracepoint.
11346
11347 2012-01-04 Yao Qi <yao@codesourcery.com>
11348
11349 * tracepoint.c (trace_vdebug): Differentiate debug message
11350 between gdbserver and IPA.
11351
11352 2012-01-03 Yao Qi <yao@codesourcery.com>
11353
11354 * tracepoint.c (tracepoint_was_hit): Don't collect for
11355 static tracepoint.
11356
11357 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11358
11359 * terminal.h: Reformat copyright header.
11360
11361 2012-01-02 Joel Brobecker <brobecker@adacore.com>
11362
11363 * server.c (gdbserver_version): Update copyright year.
11364 * gdbreplay.c (gdbreplay_version): Likewise.
11365
11366 2011-12-18 Jan Kratochvil <jan.kratochvil@redhat.com>
11367
11368 * linux-low.c (linux_create_inferior): Put empty if clause for write.
11369
11370 Revert:
11371 2011-12-18 Hui Zhu <teawater@gmail.com>
11372 * linux-low.c (linux_create_inferior): Save return value to ret.
11373
11374 2011-12-18 Hui Zhu <teawater@gmail.com>
11375
11376 * linux-low.c (linux_create_inferior): Save return value to ret.
11377
11378 2011-12-16 Doug Evans <dje@google.com>
11379
11380 * linux-low.c (linux_create_inferior): If stdio connection,
11381 redirect stdin from /dev/null, stdout to stderr.
11382 * remote-utils.c (remote_is_stdio): New static global.
11383 (remote_connection_is_stdio): New function.
11384 (remote_prepare): Handle stdio connection.
11385 (remote_open): Ditto.
11386 (remote_close): Don't close stdin for stdio connections.
11387 (read_prim,write_prim): New functions. Replace all calls to
11388 read/write to these.
11389 * server.c (main): Watch for "-" argument. Move call to
11390 remote_prepare before start_inferior.
11391 * server.h (STDIO_CONNECTION_NAME): New macro.
11392 (remote_connection_is_stdio): Declare.
11393
11394 * remote-utils.c (prepare_resume_reply): Remove extraneous \n
11395 in debugging output.
11396
11397 2011-12-15 Yao Qi <yao@codesourcery.com>
11398
11399 * tracepoint.c: Include sys/syscall.h.
11400 (gdb_ust_thread): Remove preprocessor conditional.
11401
11402 2011-12-14 Pedro Alves <pedro@codesourcery.com>
11403
11404 * linux-low.c (linux_detach_one_lwp): Call
11405 the_low_target.prepare_to_resume before detaching.
11406
11407 2011-12-14 Yao Qi <yao@codesourcery.com>
11408
11409 * tracepoint.c (gdb_ust_thread): Don't ignore return value
11410 of write.
11411
11412 2011-12-14 Yao Qi <yao@codesourcery.com>
11413
11414 * i386-low.c (i386_low_stopped_data_address): Initialize local
11415 variable `control'.
11416
11417 2011-12-13 Pedro Alves <pedro@codesourcery.com>
11418
11419 PR remote/13492
11420
11421 * i386-low.c (i386_low_stopped_data_address): Avoid fetching
11422 DR_CONTROL unless necessary. Extend comments.
11423 * linux-x86-low.c (x86_linux_prepare_to_resume): Don't write to
11424 DR0-3 if not used. If any watchpoint was set, clear DR_STATUS.
11425
11426 2011-12-13 Yao Qi <yao@codesourcery.com>
11427
11428 * tracepoint.c (trace_buffer_alloc): Replace magic numbers with
11429 macros.
11430 (upload_fast_traceframes, upload_fast_traceframes): Likewise.
11431
11432 2011-12-08 Jan Kratochvil <jan.kratochvil@redhat.com>
11433
11434 * linux-low.c (linux_kill): Skip PTRACE_KILL if LWP does not exist.
11435 Print new debug message for such case.
11436
11437 2011-12-06 Jan Kratochvil <jan.kratochvil@redhat.com>
11438
11439 Fix overlapping memcpy.
11440 * mem-break.c (set_raw_breakpoint_at): New variable buf. Use it for
11441 the read_inferior_memory transfer.
11442 (delete_fast_tracepoint_jump): New variable buf. Use it for the
11443 write_inferior_memory transfer.
11444 (set_fast_tracepoint_jump): New variable buf. Use it for the
11445 read_inferior_memory and write_inferior_memory transfers.
11446 (uninsert_fast_tracepoint_jumps_at, reinsert_fast_tracepoint_jumps_at)
11447 (delete_raw_breakpoint, uninsert_raw_breakpoint): New variable buf.
11448 Use it for the write_inferior_memory transfer.
11449 (check_mem_read, check_mem_write): New gdb_asserts for overlapping
11450 buffers.
11451
11452 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11453
11454 * linux-low.c (fetch_register, store_register): Make code
11455 consistent, fix formatting.
11456
11457 2011-12-06 Maciej W. Rozycki <macro@codesourcery.com>
11458
11459 * linux-low.c (usr_store_inferior_registers): Factor out code
11460 to handle individual registers into...
11461 (store_register): ... this new function.
11462
11463 2011-12-06 Ulrich Weigand <uweigand@de.ibm.com>
11464
11465 * Makefile.in (s390-linux32v1.o, s390-linux32v1.c): New rules.
11466 (s390-linux32v2.o, s390-linux32v2.c): Likewise.
11467 (s390-linux64v1.o, s390-linux64v1.c): Likewise.
11468 (s390-linux64v2.o, s390-linux64v2.c): Likewise.
11469 (s390x-linux64v1.o, s390x-linux64v1.c): Likewise.
11470 (s390x-linux64v2.o, s390x-linux64v2.c): Likewise.
11471 * configure.srv [s390*-*-linux*] (srv_regobj): Add new objects.
11472 (srv_xmlfiles): Add new XML files.
11473
11474 * linux-s390-low.c: Include "elf/common.h", <sys/ptrace.h>,
11475 and <sys/uio.h>.
11476 (PTRACE_GETREGSET, PTRACE_SETREGSET): Define if undefined.
11477 (init_registers_s390_linux32v1): Add prototype.
11478 (init_registers_s390_linux32v2): Likewise.
11479 (init_registers_s390_linux64v1): Likewise.
11480 (init_registers_s390_linux64v2): Likewise.
11481 (init_registers_s390x_linux64v1): Likewise.
11482 (init_registers_s390x_linux64v2): Likewise.
11483 (s390_num_regs): Increment to 52.
11484 (s390_regmap): Add orig_r2 register.
11485 (s390_num_regs_3264): Increment to 68.
11486 (s390_regmap_3264): Add orig_r2 register.
11487 (s390_collect_ptrace_register): Handle orig_r2 register.
11488 (s390_supply_ptrace_register): Likewise.
11489 (s390_fill_last_break): New function.
11490 (s390_store_last_break): Likewise.
11491 (s390_fill_system_call): New function.
11492 (s390_store_system_call): Likewise.
11493 (target_regsets): Handle NT_S390_LAST_BREAK and NT_S390_SYSTEM_CALL
11494 register sets.
11495 (s390_check_regset): New function.
11496 (s390_arch_setup): Check for presence of NT_S390_LAST_BREAK and
11497 NT_S390_SYSTEM_CALL regsets and use appropriate description.
11498 Update target_regsets for available register sets.
11499
11500 2011-12-02 Paul Pluzhnikov <ppluzhnikov@google.com>
11501 Jan Kratochvil <jan.kratochvil@redhat.com>
11502
11503 * linux-low.c (get_phdr_phnum_from_proc_auxv, get_dynamic, get_r_debug)
11504 (read_one_ptr, struct link_map_offsets, linux_qxfer_libraries_svr4):
11505 New.
11506 (struct linux_target_ops): Install linux_qxfer_libraries_svr4.
11507 * linux-low.h (struct process_info_private): New member r_debug.
11508 * server.c (handle_qxfer_libraries): Call
11509 the_target->qxfer_libraries_svr4.
11510 (handle_qxfer_libraries_svr4): New function.
11511 (qxfer_packets): New entry "libraries-svr4".
11512 (handle_query): Check QXFER_LIBRARIES_SVR4 and report libraries-svr4.
11513 * target.h (struct target_ops): New member qxfer_libraries_svr4.
11514 * remote.c (remote_xfer_partial): Call add_packet_config_cmd for
11515 PACKET_qXfer_libraries_svr4.
11516
11517 2011-11-30 Ulrich Weigand <uweigand@de.ibm.com>
11518
11519 * linux-s390-low.c (s390_collect_ptrace_register): Fully convert
11520 PSW address/mask between 8-byte and 16-byte formats.
11521 (s390_supply_ptrace_register): Likewise.
11522 (s390_get_pc, s390_set_pc): 4-byte PSW address always includes
11523 basic addressing mode bit.
11524
11525 2011-11-24 Stan Shebs <stan@codesourcery.com>
11526
11527 * tracepoint.c (cmd_qtstatus): Use plongest instead of %llx.
11528
11529 2011-11-17 Stan Shebs <stan@codesourcery.com>
11530
11531 * tracepoint.c (struct tracepoint): New field traceframe_usage.
11532 (tracing_start_time): New global.
11533 (tracing_stop_time): New global.
11534 (tracing_user_name): New global.
11535 (tracing_notes): New global.
11536 (tracing_stop_note): New global.
11537 (cmd_qtstart): Set traceframe_usage, start_time.
11538 (stop_tracing): Set stop_time.
11539 (cmd_qtstatus): Report additional status.
11540 (cmd_qtp): New function.
11541 (handle_tracepoint_query): Call it.
11542 (cmd_qtnotes): New function.
11543 (handle_tracepoint_general_set): Call it.
11544 (get_timestamp): Rename from tsv_get_timestamp.
11545
11546 2011-11-14 Stan Shebs <stan@codesourcery.com>
11547 Kwok Cheung Yeung <kcy@codesourcery.com>
11548
11549 * linux-x86-low.c (small_jump_insn): New.
11550 (i386_install_fast_tracepoint_jump_pad): Add arguments for
11551 trampoline and error message, build a trampoline and issue a small
11552 jump instruction to it.
11553 (x86_install_fast_tracepoint_jump_pad): Add arguments for
11554 trampoline and error message.
11555 (x86_get_min_fast_tracepoint_insn_len): New.
11556 (the_low_target): Add call to x86_get_min_fast_tracepoint_insn_len.
11557 * linux-low.h (struct linux_target_ops): Add arguments to
11558 install_fast_tracepoint_jump_pad operation, add new operation.
11559 * linux-low.c (linux_install_fast_tracepoint_jump_pad): Add
11560 arguments.
11561 (linux_get_min_fast_tracepoint_insn_len): New function.
11562 (linux_target_op): Add new operation.
11563 * tracepoint.c (gdb_trampoline_buffer): New IPA variable.
11564 (gdb_trampoline_buffer_end): Ditto.
11565 (gdb_trampoline_buffer_error): Ditto.
11566 (struct ipa_sym_addresses): Add fields for new IPA variables.
11567 (symbol_list): Add entries for new IPA variables.
11568 (struct tracepoint): Add fields to hold the address range of the
11569 trampoline used by the tracepoint.
11570 (trampoline_buffer_head): New static variable.
11571 (trampoline_buffer_tail): Ditto.
11572 (claim_trampoline_space): New function.
11573 (have_fast_tracepoint_trampoline_buffer): New function.
11574 (clone_fast_tracepoint): Fill in trampoline fields of tracepoint
11575 structure.
11576 (install_fast_tracepoint): Ditto, also add error buffer argument.
11577 (cmd_qtminftpilen): New function.
11578 (handle_tracepoint_query): Add response to qTMinFTPILen packet.
11579 (fast_tracepoint_from_trampoline_address): New function.
11580 (fast_tracepoint_collecting): Handle trampoline as part of jump
11581 pad space.
11582 (set_trampoline_buffer_space): New function.
11583 (initialize_tracepoint): Initialize new IPA variables.
11584 * target.h (struct target_ops): Add arguments to
11585 install_fast_tracepoint_jump_pad operation, add new
11586 get_min_fast_tracepoint_insn_len operation.
11587 (target_get_min_fast_tracepoint_insn_len): New.
11588 (install_fast_tracepoint_jump_pad): Add arguments.
11589 * server.h (IPA_BUFSIZ): Define.
11590 * linux-i386-ipa.c: Include extra header files.
11591 (initialize_fast_tracepoint_trampoline_buffer): New function.
11592 (initialize_low_tracepoint): Call it.
11593 * server.h (set_trampoline_buffer_space): Declare.
11594 (claim_trampoline_space): Ditto.
11595 (have_fast_tracepoint_trampoline_buffer): Ditto.
11596
11597 2011-11-14 Yao Qi <yao@codesourcery.com>
11598
11599 * server.c (handle_query): Handle InstallInTrace for qSupported.
11600 * tracepoint.c (add_tracepoint): Sort list.
11601 (install_tracepoint, download_tracepoint): New.
11602 (cmd_qtdp): Call them to install and download tracepoints.
11603 (sort_tracepoints): Removed.
11604 (cmd_qtstart): Update.
11605
11606 2011-11-14 Yao Qi <yao@codesourcery.com>
11607
11608 * mem-break.c (inc_ref_fast_tracepoint_jump): New.
11609 * mem-break.h: Declare.
11610 * tracepoint.c (cmd_qtstart): Move some code to ...
11611 (clone_fast_tracepoint, install_fast_tracepoint): ... here.
11612 New.
11613 (download_tracepoints): Move some code to ...
11614 (download_tracepoint_1): ... here. New.
11615
11616 2011-11-08 Yao Qi <yao@codesourcery.com>
11617
11618 * remote-utils.c (relocate_instruction): A comment fix.
11619
11620 2011-11-07 Joel Brobecker <brobecker@adacore.com>
11621
11622 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): Delete.
11623 (i386_dr_low_get_control, i386_dr_low_get_status): Use
11624 dr_status_mirror and dr_control_mirror from debug_reg_state.
11625 (i386_dr_low_get_status): Use debug_reg_state.dr_status_mirror
11626 (i386_initial_stuff): Remove use of deleted globals.
11627 (i386_get_thread_context, i386_set_thread_context,
11628 i386_thread_added): Use dr_status_mirror and dr_control_mirror
11629 from debug_reg_state.
11630
11631 2011-11-05 Yao Qi <yao@codesourcery.com>
11632
11633 * tracepoint.c (gdb_collect): Loop over tracepoints of same
11634 address as TPOINT's.
11635
11636 2011-11-02 Stan Shebs <stan@codesourcery.com>
11637
11638 * tracepoint.c (agent_mem_read_string): New function.
11639 (eval_agent_expr): Call it for tracenz.
11640 * server.c (handle_query): Report support for tracenz.
11641
11642 2011-11-02 Yao Qi <yao@codesourcery.com>
11643
11644 * tracepoint.c (cmd_qtstart): Remove unused local variables.
11645
11646 2011-11-02 Yao Qi <yao@codesourcery.com>
11647
11648 * target.h: Fix a typo in comment.
11649
11650 2011-10-31 Pedro Alves <pedro@codesourcery.com>
11651
11652 * mem-break.c (check_mem_write): Add `myaddr' parameter. Don't
11653 clobber the breakpoints' shadows with fast tracepoint jumps.
11654 * mem-break.h (check_mem_write): Add `myaddr' parameter.
11655 * target.c (write_inferior_memory): Also pass MYADDR down to
11656 check_mem_write.
11657
11658 2011-10-07 Ulrich Weigand <ulrich.weigand@linaro.org>
11659
11660 * configure.ac: Check support for personality routine.
11661 * configure: Regenerate.
11662 * config.in: Likewise.
11663 * linux-low.c: Include <sys/personality.h>.
11664 Define ADDR_NO_RANDOMIZE if necessary.
11665 (linux_create_inferior): Disable address space randomization when
11666 forking inferior, if requested.
11667 (linux_supports_disable_randomization): New function.
11668 (linux_target_ops): Install it.
11669 * server.h (disable_randomization): Declare.
11670 * server.c (disable_randomization): New global variable.
11671 (handle_general_set): Handle QDisableRandomization.
11672 (handle_query): Likewise for qSupported.
11673 (main): Support --disable-randomization and --no-disable-randomization
11674 command line arguments.
11675 * target.h (struct target_ops): Add supports_disable_randomization.
11676 (target_supports_disable_randomization): New macro.
11677
11678 2011-09-29 Mike Frysinger <vapier@gentoo.org>
11679
11680 * linux-low.c (target_loadseg): Add defined PTRACE_GETFDPIC to the
11681 ifdef check.
11682 [PT_GETDSBT] (target_loadmap): Wrap in a defined PT_GETDSBT check.
11683 [!PT_GETDSBT] (target_loadmap): New definition.
11684 (LINUX_LOADMAP, LINUX_LOADMAP_EXEC, LINUX_LOADMAP_INTERP): Define.
11685 (linux_read_loadmap): Change PTRACE_GETDSBT_EXEC to
11686 LINUX_LOADMAP_EXEC, PTRACE_GETDSBT_INTERP to LINUX_LOADMAP_INTERP,
11687 and PT_GETDSBT to LINUX_LOADMAP.
11688 [!PT_GETDSBT] (linux_read_loadmap): Define to NULL.
11689 (linux_target_ops): Delete unnecessary ifdef PT_GETDSBT check.
11690
11691 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11692
11693 * linux-arm-low.c (struct arm_linux_hwbp_cap): Remove.
11694 (arm_linux_hwbp_cap): New static variable.
11695 (arm_linux_get_hwbp_cap): Replace by ...
11696 (arm_linux_init_hwbp_cap): ... this new function.
11697 (arm_linux_get_hw_breakpoint_count): Use arm_linux_hwbp_cap.
11698 (arm_linux_get_hw_watchpoint_count): Likewise.
11699 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11700 (arm_arch_setup): Call arm_linux_init_hwbp_cap.
11701 (arm_prepare_to_resume): Use perror_with_name instead of error.
11702
11703 2011-09-21 Ulrich Weigand <ulrich.weigand@linaro.org>
11704
11705 * linux-arm-low.c: Include <signal.h>.
11706 (PTRACE_GETHBPREGS, PTRACE_SETHBPREGS): Define if necessary.
11707 (struct arm_linux_hwbp_cap): New data type.
11708 (arm_hwbp_type, arm_hwbp_control_t): New typedefs.
11709 (struct arm_linux_hw_breakpoint): New data type.
11710 (MAX_BPTS, MAX_WPTS): Define.
11711 (struct arch_process_info, struct arch_lwp_info): New data types.
11712 (arm_linux_get_hwbp_cap): New function.
11713 (arm_linux_get_hw_breakpoint_count): Likewise.
11714 (arm_linux_get_hw_watchpoint_count): Likewise.
11715 (arm_linux_get_hw_watchpoint_max_length): Likewise.
11716 (arm_hwbp_control_initialize): Likewise.
11717 (arm_hwbp_control_is_enabled): Likewise.
11718 (arm_hwbp_control_is_initialized): Likewise.
11719 (arm_hwbp_control_disable): Likewise.
11720 (arm_linux_hw_breakpoint_equal): Likewise.
11721 (arm_linux_hw_point_initialize): Likewise.
11722 (struct update_registers_data): New data structure.
11723 (update_registers_callback: New function.
11724 (arm_insert_point): Likewise.
11725 (arm_remove_point): Likewise.
11726 (arm_stopped_by_watchpoint): Likewise.
11727 (arm_stopped_data_address): Likewise.
11728 (arm_new_process): Likewise.
11729 (arm_new_thread): Likewise.
11730 (arm_prepare_to_resume): Likewise.
11731 (the_low_target): Register arm_insert_point, arm_remove_point,
11732 arm_stopped_by_watchpoint, arm_stopped_data_address, arm_new_process,
11733 arm_new_thread, and arm_prepare_to_resume.
11734
11735 2011-09-15 Stan Shebs <stan@codesourcery.com>
11736
11737 * server.h (struct emit_ops): Add compare-goto fields.
11738 * tracepoint.c (gdb_agent_op_sizes): New table.
11739 (emit_eq_goto): New function.
11740 (emit_ne_goto): New function.
11741 (emit_lt_goto): New function.
11742 (emit_le_goto): New function.
11743 (emit_gt_goto): New function.
11744 (emit_ge_goto): New function.
11745 (is_goto_target): New function.
11746 (compile_bytecodes): Recognize special cases of compare-goto
11747 combinations and call specialized emitters for them.
11748 * linux-x86-low.c (amd64_emit_eq_goto): New function.
11749 (amd64_emit_ne_goto): New function.
11750 (amd64_emit_lt_goto): New function.
11751 (amd64_emit_le_goto): New function.
11752 (amd64_emit_gt_goto): New function.
11753 (amd64_emit_ge_goto): New function.
11754 (amd64_emit_ops): Add the new functions.
11755 (i386_emit_eq_goto): New function.
11756 (i386_emit_ne_goto): New function.
11757 (i386_emit_lt_goto): New function.
11758 (i386_emit_le_goto): New function.
11759 (i386_emit_gt_goto): New function.
11760 (i386_emit_ge_goto): New function.
11761 (i386_emit_ops): Add the new functions.
11762
11763 2011-09-08 Stan Shebs <stan@codesourcery.com>
11764
11765 * linux-x86-low.c (i386_emit_prologue): Save %ebx.
11766 (i386_emit_epilogue): Restore %ebx.
11767
11768 2011-08-31 Jie Zhang <jzhang918@gmail.com>
11769
11770 * server.c (step_thread): Remove definition.
11771 (process_serial_event): Don't handle Hs.
11772 * server.h (step_thread): Remove declaration.
11773 * target.c (set_desired_inferior): Remove use of step_thread.
11774
11775 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11776
11777 * linux-low.c: Include linux-procfs.h.
11778 (linux_attach_lwp_1): Update comments.
11779 (linux_attach): Scan for existing threads when attaching to a
11780 process that is the tgid.
11781 * Makefile.in: Update dependencies.
11782
11783 2011-08-24 Luis Machado <lgustavo@codesourcery.com>
11784
11785 * configure.srv: Add linux-procfs.o dependencies.
11786
11787 2011-08-14 Yao Qi <yao@codesourcery.com>
11788
11789 * target.h (struct target_ops): Fix indent.
11790 * win32-low.c (win32_target_ops): Fix comment.
11791
11792 2011-08-14 Andrew Jenner <andrew@codesourcery.com>
11793 Yao Qi <yao@codesourcery.com>
11794
11795 * Makefile.in (clean): Remove tic6x-*.c files.
11796 (linux-tic6x-low.o, tic6x-c62x-linux.o, tic6x-c64x-linux.o): New rules.
11797 (tic6x-c64xp-linux.o, tic6x-c62x-linux.c, tic6x-c64x-linux.c): Likewise.
11798 (tic6x-c64xp-linux.c): Likewise.
11799 * configure.srv: Add support for tic6x-*-uclinux.
11800 * linux-tic6x-low.c: New.
11801 * linux-low.c (PT_TEXT_ADDR, PT_DATA_ADDR, PT_TEXT_END_ADDR): Define.
11802
11803 2011-08-14 Andrew Stubbs <ams@codesourcery.com>
11804 Yao Qi <yao@codesourcery.com>
11805
11806 * target.h (struct target_ops): Add read_loadmap.
11807 * linux-low.c (struct target_loadseg): New type.
11808 (struct target_loadmap): New type.
11809 (linux_read_loadmap): New function.
11810 (linux_target_ops): Add linux_read_loadmap.
11811 * server.c (handle_query): Support qXfer:fdpic:read packet.
11812 * win32-low.c (win32_target_ops): Initialize field `read_loadmap'
11813 to NULL.
11814
11815 2011-08-05 Eli Zaretskii <eliz@gnu.org>
11816
11817 * win32-low.c: Include <stdint.h>.
11818
11819 2011-07-22 Pedro Alves <pedro@codesourcery.com>
11820
11821 * i386-low.c (i386_insert_aligned_watchpoint): Don't pass the info
11822 to the inferior here.
11823 (i386_remove_aligned_watchpoint): Ditto.
11824 (i386_handle_nonaligned_watchpoint): Return immediate on fail to
11825 fit part of the watchpoint in the debug registers.
11826 (i386_update_inferior_debug_regs): New.
11827 (i386_low_insert_watchpoint): Work on a local mirror of the debug
11828 registers, and only update the inferior on success.
11829 (i386_low_remove_watchpoint): Ditto.
11830
11831 2011-07-22 Kwok Cheung Yeung <kcy@codesourcery.com>
11832
11833 * linux-low.c (compare_ints, unique, list_threads, show_process,
11834 linux_core_of_thread): Delete.
11835 (linux_target_ops): Change linux_core_of_thread to
11836 linux_common_core_of_thread.
11837 (linux_qxfer_osdata): Defer to linux_common_xfer_osdata.
11838 * utils.c (malloc_failure): Change type of argument.
11839 (xmalloc, xrealloc, xcalloc, xsnprintf): Delete.
11840 * Makefile.in (SFILES): Add common/common-utils.c, common/xml-utils.c,
11841 common/linux-osdata.c, common/ptid.c and common/buffer.c.
11842 (OBS): Add xml-utils.o, common-utils.o, ptid.o and buffer.o.
11843 (IPA_OBJS): Add common-utils-ipa.o.
11844 (ptid_h, linux_osdata_h): New macros.
11845 (server_h): Add common/common-utils.h, common/xml-utils.h,
11846 common/buffer.h, common/gdb_assert.h, common/gdb_locale.h and
11847 common/ptid.h.
11848 (common-utils-ipa.o, common-utils.o, xml-utils.o, linux-osdata.o,
11849 ptid.o, buffer.o): New rules.
11850 (linux-low.o): Add common/linux-osdata.h as a dependency.
11851 * configure.srv (srv_tgtobj): Add linux-osdata.o to Linux targets.
11852 * configure.ac: Add AC_HEADER_DIRENT check.
11853 * config.in: Regenerate.
11854 * configure: Regenerate.
11855 * remote-utils.c (xml_escape_text): Delete.
11856 (buffer_grow, buffer_free, buffer_init, buffer_finish,
11857 buffer_xml_printf): Move to common/buffer.c.
11858 * server.c (main): Remove call to initialize_inferiors.
11859 * server.h (struct ptid, ptid_t, minus_one_ptid, null_ptid,
11860 ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp, ptid_get_tid,
11861 ptid_equal, ptid_is_pid, initialize_inferiors, xml_escape_text,
11862 internal_error, gdb_assert, gdb_assert_fail): Delete.
11863 (struct buffer, buffer_grow, buffer_free, buffer_init, buffer_finish,
11864 buffer_xml_printf, buffer_grow_str, buffer_grow_str0): Move to
11865 common/buffer.h.
11866 * inferiors.c (null_ptid, minus_one_ptid, ptid_build, pid_to_ptid,
11867 ptid_get_pid, ptid_get_lwp, ptid_get_tid, ptid_equal, ptid_is_pid,
11868 initialize_inferiors): Delete.
11869
11870 2011-07-20 Pedro Alves <pedro@codesourcery.com>
11871
11872 * tracepoint.c (tracepoint_look_up_symbols): Return upon the first
11873 symbol error.
11874
11875 2011-05-31 Pedro Alves <pedro@codesourcery.com>
11876
11877 * linux-x86-low.c (i386_dr_low_get_addr): Fix off by one in
11878 assertion.
11879 * win32-i386-low.c (i386_dr_low_get_addr): Ditto.
11880
11881 2011-05-26 Yao Qi <yao@codesourcery.com>
11882
11883 * Makefile.in (thread-db.o): Track dependence to
11884 common/gdb_thread_db.h.
11885 * thread-db.c: include gdb_thread_db.h from right place.
11886
11887 2011-05-16 Adrian Cornish <gnu@bluedreamer.com>
11888
11889 * linux-i386-ipa.c (supply_static_tracepoint_registers): Pass
11890 __FILE__ and __LINE__ to internal_error.
11891
11892 2011-05-13 Doug Evans <dje@google.com>
11893
11894 * thread-db.c (try_thread_db_load_from_sdir): New function.
11895 (try_thread_db_load_from_dir): New function.
11896 (thread_db_load_search): Handle $sdir, ignore $pdir.
11897 Remove trying of system directories if search of
11898 libthread-db-search-path fails, that is now done via $sdir.
11899
11900 2011-05-12 Kwok Cheung Yeung <kcy@codesourcery.com>
11901
11902 * server.c (handle_query): Add EnableDisableTracepoints to the list
11903 of supported features.
11904 * tracepoint.c (clear_installed_tracepoints): Uninstall disabled
11905 tracepoints.
11906 (cmd_qtenable_disable): New.
11907 (cmd_qtstart): Install tracepoints even if disabled.
11908 (handle_tracepoint_general_set): Add call to cmd_qtenable_disable on
11909 receiving a QTEnable or QTDisable packet.
11910 (gdb_collect): Skip data collection if fast tracepoint is disabled.
11911 (ust_marker_to_static_tracepoint): Do not ignore disabled static
11912 tracepoints.
11913 (gdb_probe): Skip data collection if static tracepoint is disabled.
11914
11915 2011-05-10 Doug Evans <dje@google.com>
11916
11917 * thread-db.c (thread_db_handle_monitor_command): Handle elided path.
11918
11919 2011-05-04 Doug Evans <dje@google.com>
11920
11921 * linux-low.c (linux_join): Skip process lookup.
11922 * spu-low.c (spu_join): Ditto.
11923 * server.c (join_inferiors_callback): Delete.
11924 (process_serial_event): For 'D' packet (detach) call join_inferior
11925 directly.
11926
11927 2011-05-04 Joseph Myers <joseph@codesourcery.com>
11928
11929 * README: Don't mention xscale*-*-linux*.
11930 * configure.srv (xscale*-*-linux*): Don't handle target.
11931
11932 2011-04-27 Nathan Froyd <froydnj@codesourcery.com>
11933
11934 * linux-x86-low.c (amd64_emit_const): Call memcpy instead of
11935 casting pointers.
11936 (amd64_emit_reg, amd64_emit_int_call_1, amd64_emit_void_call_2):
11937 (i386_emit_const, i386_emit_reg, i386_emit_int_call_1):
11938 (i386_emit_void_call_2): Likewise.
11939
11940 2011-04-26 Yao Qi <yao@codesourcery.com>
11941
11942 * linux-low.c: Move common macros to linux-ptrace.h.
11943 Include linux-ptrace.h.
11944 * Makefile.in (linux_ptrace_h): New.
11945 (linux-low.o): Depends on linux-ptrace.h.
11946
11947 2011-04-24 Jan Kratochvil <jan.kratochvil@redhat.com>
11948
11949 * remote-utils.c (handle_accept_event): Close LISTEN_DESC only if
11950 RUN_ONCE. Comment for the LISTEN_DESC delete_file_handler call.
11951 (remote_prepare): New function with most of the TCP code from ...
11952 (remote_open): ... here. Detect PORT here unconditionally. Move also
11953 setting transport_is_reliable.
11954 * server.c (run_once): New variable.
11955 (gdbserver_usage): Document it.
11956 (main): Set run_once for `--once'. Call remote_prepare. Exit after
11957 the first run if RUN_ONCE.
11958 * server.h (run_once, remote_prepare): New declarations.
11959
11960 2011-04-19 Tom Tromey <tromey@redhat.com>
11961
11962 * win32-low.c (handle_load_dll): Remove duplicate "the".
11963
11964 2011-04-07 Pierre Muller <muller@ics.u-strasbg.fr>
11965
11966 Remove support for old Cygwin 1.5 versions.
11967 * win32-low.c (win32_create_inferior): Use new cygwin_path_list
11968 function to avoid warning.
11969 (win32_add_one_solib): Use cygwin_conv_path function to avoid
11970 warning.
11971
11972 2011-03-18 Pierre Muller <muller@ics.u-strasbg.fr>
11973
11974 * gdbserver/server.h (Macro _): Define it if not available.
11975
11976 2011-03-14 Michael Snyder <msnyder@vmware.com>
11977
11978 * hostio.c (handle_close): Remove unnecessary null test.
11979
11980 2011-03-10 Joel Brobecker <brobecker@adacore.com>
11981
11982 * Makefile.in (maintainer-clean realclean distclean): Remove
11983 "make ... subdir_do" command.
11984
11985 2011-03-10 Michael Snyder <msnyder@vmware.com>
11986
11987 * tracepoint.c (tracepoint_finish_step): Fix loop variable.
11988
11989 * server.c (handle_v_run): Free alloced buffer on early return.
11990
11991 2011-03-09 Yao Qi <yao@codesourcery.com>
11992
11993 Revert:
11994 2011-03-04 Yao Qi <yao@codesourcery.com>
11995
11996 * Makefile.in: Remove GNU make feature --directory.
11997
11998 2011-03-05 Yao Qi <yao@codesourcery.com>
11999
12000 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12001 (subdir_do): New make target. Copied from gdb/Makefile.
12002 (maintainer-clean, realclean, distclean, clean): Call corresponding
12003 make targets in common/Makefile.
12004
12005 2011-02-11 Yao Qi <yao@codesourcery.com>
12006
12007 * configure.ac: Call AC_PROG_RANLIB.
12008 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12009 * configure: Regenerate.
12010
12011 2011-03-07 Jan Kratochvil <jan.kratochvil@redhat.com>
12012
12013 * remote-utils.c (putpkt_binary_1): Calculate BUF2 size dynamically.
12014
12015 2011-03-06 Yao Qi <yao@codesourcery.com>
12016
12017 * Makefile.in (REQUIRED_SUBDIRS): Remove $(LIBCOMMON_DIR).
12018
12019 2011-03-05 Yao Qi <yao@codesourcery.com>
12020
12021 * Makefile.in (CLEANDIRS, REQUIRED_SUBDIRS): New variable.
12022 (subdir_do): New make target. Copied from gdb/Makefile.
12023 (maintainer-clean, realclean, distclean, clean): Call corresponding
12024 make targets in common/Makefile.
12025
12026 2011-03-04 Yao Qi <yao@codesourcery.com>
12027
12028 * Makefile.in: Remove GNU make feature --directory.
12029
12030 2011-03-04 Michael Snyder <msnyder@vmware.com>
12031
12032 * server.c (queue_stop_reply): Call xmalloc not malloc.
12033
12034 2011-03-02 Michael Snyder <msnyder@vmware.com>
12035
12036 * linux-arm-low.c (arm_arch_setup): Replace malloc with xmalloc.
12037
12038 2011-02-28 Michael Snyder <msnyder@vmware.com>
12039
12040 * tracepoint.c (cmd_qtv): Discard unused value 'packet'.
12041 (cmd_qtframe): Ditto.
12042 (cmd_qtbuffer): Ditto.
12043 (cmd_bigqtbuffer): Ditto.
12044
12045 * utils.c (decimal2str): Initialize 'width' to nine, then
12046 don't mess with it.
12047
12048 2011-02-28 Ulrich Weigand <uweigand@de.ibm.com>
12049
12050 * hostio.c (require_data): Free *data, not data.
12051
12052 2011-02-28 Jan Kratochvil <jan.kratochvil@redhat.com>
12053
12054 * hostio.c (require_data): Use free, not xfree.
12055
12056 2011-02-27 Michael Snyder <msnyder@vmware.com>
12057
12058 * server.c (handle_query): Discard unused value.
12059
12060 * hostio.c (require_data): Free malloc memory before returning
12061 error.
12062
12063 2011-02-26 Michael Snyder <msnyder@vmware.com>
12064
12065 * linux-low.c (list_threads): Call closedir for dirent.
12066
12067 2011-02-27 Michael Snyder <msnyder@vmware.com>
12068
12069 * i386-low.c (i386-length_and_rw_bits): Comment the fact that
12070 a case statement falls through.
12071
12072 * linux-low.c (linux_xfer_siginfo): Fix fencepost error.
12073
12074 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): Fix fencepost error
12075 in comparison.
12076
12077 2011-02-26 Michael Snyder <msnyder@vmware.com>
12078
12079 * utils.c (decimal2str): Eliminate dead code and dead param.
12080 (pulongest): Drop dead param from call to decimal2str.
12081 (plongest): Ditto.
12082
12083 2011-02-24 Joel Brobecker <brobecker@adacore.com>
12084
12085 Revert the following patch (not approved yet):
12086 2011-02-21 Hui Zhu <teawater@gmail.com>
12087 * tracepoint.c (tp_printf): New function.
12088 (eval_agent_expr): Handle gdb_agent_op_printf.
12089
12090 2011-02-21 Hui Zhu <teawater@gmail.com>
12091
12092 * tracepoint.c (tp_printf): New function.
12093 (eval_agent_expr): Handle gdb_agent_op_printf.
12094
12095 2011-02-18 Tom Tromey <tromey@redhat.com>
12096
12097 * Makefile.in (tracepoint-ipa.o): Depend on ax.def.
12098 (tracepoint.o): Likewise.
12099 * tracepoint.c (enum gdb_agent_op): Use ax.def.
12100 (gdb_agent_op_names): Likewise.
12101
12102 2011-02-18 Tom Tromey <tromey@redhat.com>
12103
12104 * tracepoint.c (enum gdb_agent_op) <gdb_agent_op_pick,
12105 gdb_agent_op_rot>: New constants.
12106 (gdb_agent_op_names): Add pick and roll.
12107 (eval_agent_expr) <gdb_agent_op_pick, gdb_agent_op_rot>: New
12108 cases.
12109
12110 2011-02-15 Jan Kratochvil <jan.kratochvil@redhat.com>
12111
12112 * aclocal.m4: Regenerated with aclocal-1.11.1.
12113
12114 2011-02-14 Pedro Alves <pedro@codesourcery.com>
12115
12116 * server.c (handle_qxfer_traceframe_info): New.
12117 (qxfer_packets): Register "traceframe-info".
12118 (handle_query): Report support for qXfer:traceframe-info:read+.
12119 * tracepoint.c (match_blocktype): New.
12120 (traceframe_find_block_type): Rename to ...
12121 (traceframe_walk_blocks): ... this. Add callback filter argument,
12122 and use it.
12123 (traceframe_find_block_type): New, reimplemented on top of
12124 traceframe_walk_blocks.
12125 (build_traceframe_info_xml): New.
12126 (traceframe_read_info): New.
12127 * server.h (traceframe_read_info): Declare.
12128
12129 2011-02-11 Yao Qi <yao@codesourcery.com>
12130
12131 * configure.ac: Call AC_PROG_RANLIB.
12132 * Makefile.in: Remove signals.o from OBS. Link libcommon.a.
12133 * configure: Regenerate.
12134
12135 2011-02-07 Pedro Alves <pedro@codesourcery.com>
12136
12137 * server.c (gdb_read_memory): Change return semantics to allow
12138 partial transfers.
12139 (handle_search_memory_1): Adjust.
12140 (process_serial_event) <'m' packet>: Handle partial transfers.
12141 * tracepoint.c (traceframe_read_mem): Handle partial transfers.
12142
12143 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12144
12145 * regcache.c (init_register_cache): Initialize
12146 regcache->register_status.
12147 (free_register_cache): Release regcache->register_status.
12148 (regcache_cpy): Copy register_status.
12149 (registers_to_string): Print 'x's for unavailable registers.
12150 (supply_register): Mark the register's status valid or
12151 unavailable, depending on whether a buffer was passed in or not.
12152 (supply_register_zeroed): New.
12153 (supply_regblock): Mark the registers' status valid or
12154 unavailable, depending on whether a buffer was passed in or not.
12155 * regcache.h (REG_UNAVAILABLE, REG_VALID): New defines.
12156 (struct regcache): New `register_status' field.
12157 (supply_register_zeroed): Declare.
12158 * i387-fp.c (i387_xsave_to_cache): Zero out registers using
12159 supply_register_zeroed, rather than passing a NULL buffer to
12160 supply_register.
12161 * tracepoint.c (fetch_traceframe_registers): Update comment.
12162
12163 2011-01-28 Pedro Alves <pedro@codesourcery.com>
12164
12165 * i387-fp.c (i387_xsave_to_cache): Make passing NULL as register
12166 buffer explicit.
12167
12168 2011-01-25 Pedro Alves <pedro@codesourcery.com>
12169
12170 * server.h (decode_xfer_write): Change prototype.
12171 * remote-utils.c (decode_xfer_write): Remove `annex' parameter,
12172 and don't extract the annex here.
12173 * server.c (decode_xfer_read): Remove `annex' parameter,
12174 and don't extract the annex here.
12175 (decode_xfer): New.
12176 (struct qxfer): New.
12177 (handle_qxfer_auxv, handle_qxfer_features, handle_qxfer_libraries)
12178 (handle_qxfer_osdata, handle_qxfer_siginfo, handle_qxfer_spu)
12179 (handle_qxfer_statictrace): New functions, abstracted out from
12180 handle_query, and made to use the struct qxfer interface.
12181 (handle_threads_qxfer_proper): Rename to ...
12182 (handle_qxfer_threads_proper): ... this.
12183 (handle_threads_qxfer): Rename to ...
12184 (handle_qxfer_threads): ... this. Adjust.
12185 (qxfer_packets): New array.
12186 (handle_qxfer): New function.
12187 (handle_query): Use handle_qxfer.
12188
12189 2011-01-05 Michael Snyder <msnyder@msnyder-server.eng.vmware.com>
12190
12191 * gdbreplay.c: Shorten lines of >= 80 columns.
12192 * linux-low.c: Ditto.
12193 * linux-ppc-low.c: Ditto.
12194 * linux-s390-low.c: Ditto.
12195 * linux-sparc-low.c: Ditto.
12196 * linux-x86-low.c: Ditto.
12197 * linux-xtensa-low.c: Ditto.
12198 * mem-break.c: Ditto.
12199 * nto-low.c: Ditto.
12200 * regcache.h: Ditto.
12201 * remote-utils.c: Ditto.
12202 * server.c: Ditto.
12203 * server.h: Ditto.
12204 * thread-db.c: Ditto.
12205 * tracepoint.c: Ditto.
12206 * utils.c: Ditto.
12207 * win32-low.h: Ditto.
12208
12209 2011-01-05 Joel Brobecker <brobecker@adacore.com>
12210
12211 * gdbserver/configure.ac, gdbserver/gdbserver.1: Copyright year
12212 update.
12213
12214 2011-01-01 Joel Brobecker <brobecker@adacore.com>
12215
12216 * server.c (gdbserver_version): Update copyright year in version
12217 output.
12218 * gdbreplay.c (gdbreplay_version): Ditto.
12219
12220 2010-12-29 Jie Zhang <jie.zhang@analog.com>
12221
12222 * configure.srv (bfin-*-*linux*): Handle Blackfin/Linux targets.
12223 * linux-bfin-low.c: New file.
12224 * linux-low.c: Define PT_TEXT_ADDR, PT_TEXT_END_ADDR, and
12225 PT_DATA_ADDR for BFIN targets.
12226 * Makefile.in (SFILES): Add linux-bfin-low.c.
12227 (clean): Remove reg-bfin.c.
12228 (linux-bfin-low.o, reg-bfin.o, reg-bfin.c): New targets.
12229 * README: Mention supported Blackfin targets.
12230
12231 2010-12-23 Mike Frysinger <vapier@gentoo.org>
12232
12233 * .gitignore: New file.
12234
12235 2010-11-16 Mike Frysinger <vapier@gentoo.org>
12236
12237 * linux-low.c (linux_tracefork_child): Add char* cast to arg.
12238
12239 2010-10-22 Jie Zhang <jie@codesourcery.com>
12240
12241 * Makefile.in: Add FLAGS_TO_PASS variable.
12242 (install): Remove dependency of install-only and recursively
12243 invoke make for install-only.
12244
12245 2010-10-04 Doug Evans <dje@google.com>
12246
12247 * Makefile.in (uninstall): Use $(DESTDIR).
12248
12249 2010-09-24 Pedro Alves <pedro@codesourcery.com>
12250
12251 PR gdb/11842
12252
12253 * linux-x86-low.c (compat_siginfo_from_siginfo)
12254 (siginfo_from_compat_siginfo): Also copy si_pid and si_uid when
12255 si_code is < 0. Check for si_code == SI_TIMER before checking for
12256 si_code < 0.
12257
12258 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12259
12260 * lynx-i386-low.c: New file.
12261 * configure.srv: Add handling of i[34567]86-*-lynxos* targets.
12262
12263 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12264
12265 * lynx-low.c (ptrace_request_to_str): Remove handling for
12266 request values that have been removed in LynxOS 5.x.
12267
12268 2010-09-13 Joel Brobecker <brobecker@adacore.com>
12269
12270 * lynx-low.c, lynx-ppc-loc.c: Include <sys/ptrace.h> instead of
12271 <ptrace.h>
12272
12273 2010-09-09 Nathan Sidwell <nathan@codesourcery.com>
12274
12275 * configure.ac: Add --enable-inprocess-agent option.
12276 * configure: Rebuilt.
12277
12278 2010-09-06 Yao Qi <yao@codesourcery.com>
12279
12280 * linux-low.c (linux_kill): Remove unused variable.
12281 (linux_stabilize_threads): Likewise.
12282 * server.c (start_inferior): Likewise.
12283 (queue_stop_reply_callback): Likewise.
12284 * tracepoint.c (do_action_at_tracepoint): Likewise.
12285
12286 2010-09-06 Yao Qi <yao@codesourcery.com>
12287
12288 * linux-low.c (maybe_move_out_of_jump_pad): Restore current_inferior
12289 on return.
12290
12291 2010-09-06 Jan Kratochvil <jan.kratochvil@redhat.com>
12292
12293 * target.c (mywait) <TARGET_WAITKIND_EXITED>: Fix to use INTEGER.
12294
12295 2010-09-06 Pedro Alves <pedro@codesourcery.com>
12296
12297 * Makefile.in (install-only): Replace $IPA_DEPFILES with
12298 "$(IPA_DEPFILES)".
12299
12300 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12301
12302 * gdbserver/lynx-low.c, gdbserver/lynx-low.h,
12303 gdbserver/lynx-ppc-low.c: New files.
12304 * Makefile.in (lynx_low_h): New variable.
12305 (lynx-low.o, lynx-ppc-low.o): New rules.
12306 * configure.ac: On LynxOS, link with -lnetinet.
12307 * configure.srv: Add handling of powerpc-*-lynxos* targets.
12308 * configure: regenerate.
12309
12310 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12311
12312 * Makefile.in (vasprintf.o, vsnprintf.o): New rules.
12313 * configure.ac: Add check for vasprintf and vsnprintf.
12314 * configure, config.in: Regenerate.
12315 * server.h (vasprintf, vsnprintf): Add conditional declarations.
12316
12317 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12318
12319 * gdbreplay.c: Move include of alloca.h up, next to include of
12320 malloc.h.
12321 * server.h: Add include of malloc.h.
12322 * mem-break.c: Remove include of malloc.h.
12323 * server.c, tracepoint.c, utils.c, win32-low.c: Likewise.
12324
12325 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12326
12327 * Makefile.in (memmem.o): Build with -Wno-error.
12328
12329 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12330
12331 * utils.c (xsnprintf): Make non-static.
12332 * server.h: Add xsnprintf declaration.
12333 * linux-low.c, nto-low.c, target.c, thread-db.c, tracepoint.c:
12334 replace calls to snprintf by calls to xsnprintf throughout.
12335
12336 2010-09-01 Joel Brobecker <brobecker@adacore.com>
12337
12338 * configure.ac: Add configure check for alloca.
12339 * configure, config.in: Regenerate.
12340 * server.h: Include alloca.h if it exists.
12341 * gdbreplay.c: Include alloca.h if it exists.
12342
12343 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12344
12345 * linux-low.c (__SIGRTMIN): Define if not already defined.
12346 (linux_create_inferior): Check for __ANDROID__ rather than
12347 __SIGRTMIN.
12348 (enqueue_one_deferred_signal): Don't requeue non-RT signals that
12349 are already deferred.
12350 (linux_wait_1): Check for __ANDROID__ rather than __SIGRTMIN.
12351 (linux_resume_one_thread): Don't queue a SIGSTOP if the lwp is
12352 stopped and already has a pending signal to report.
12353 (proceed_one_lwp): : Don't queue a SIGSTOP if the lwp already has
12354 a pending signal to report or is moving out of a jump pad.
12355 (linux_init_signals): Check for __ANDROID__ rather than
12356 __SIGRTMIN.
12357
12358 2010-08-28 Pedro Alves <pedro@codesourcery.com>
12359
12360 * linux-low.c (linux_stabilize_threads): Wrap debug output in a
12361 debug_threads check. Avoid a linear search when not doing debug
12362 output.
12363
12364 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12365
12366 * event-loop.c (event_handle_func): Adjust to use gdb_fildes_t.
12367 (struct gdb_event) <fd>: Change type to gdb_fildes_t.
12368 (struct file_handler) <fd>: Change type to gdb_fildes_t.
12369 (process_event): Change local fd's type to gdb_fildes_t.
12370 (create_file_handler): Adjust prototype.
12371 (delete_file_handler): Adjust prototype.
12372 (handle_file_event): Adjust prototype. Use pfildes.
12373 (create_file_event): Adjsut prototype.
12374 * remote-utils.c (remote_desc, listen_desc): Change type to
12375 gdb_fildes_t.
12376 * server.h: New gdb_fildes_t typedef.
12377 [USE_WIN32API]: Include winsock2.h.
12378 (delete_file_handler, add_file_handler): Adjust prototypes.
12379 (pfildes): Declare.
12380 * utils.c (pfildes): New.
12381
12382 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12383
12384 * configure.ac (build_warnings): Add -Wno-char-subscripts.
12385 * configure: Regenerate.
12386
12387 2010-08-27 Pedro Alves <pedro@codesourcery.com>
12388
12389 * linux-low.c (linux_unprepare_to_access_memory): Rename to ...
12390 (linux_done_accessing_memory): ... this.
12391 (linux_target_ops): Adjust.
12392 * linux-x86-low.c (x86_insert_point, x86_remove_point): Adjust.
12393 * nto-low.c (nto_target_ops): Adjust comment.
12394 * server.c (gdb_read_memory, gdb_write_memory): Adjust.
12395 * spu-low.c (spu_target_ops): Adjust comment.
12396 * target.h (target_ops): Rename unprepare_to_access_memory field
12397 to done_accessing_memory.
12398 (unprepare_to_access_memory): Rename to ...
12399 (done_accessing_memory): ... this.
12400
12401 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12402
12403 * linux-low.c (linux_prepare_to_access_memory): New.
12404 (linux_unprepare_to_access_memory): New.
12405 (linux_target_ops): Install them.
12406 * server.c (read_memory): Rename to ...
12407 (gdb_read_memory): ... this. Use
12408 prepare_to_access_memory/prepare_to_access_memory.
12409 (write_memory): Rename to ...
12410 (gdb_write_memory): ... this. Use
12411 prepare_to_access_memory/prepare_to_access_memory.
12412 (handle_search_memory_1): Adjust.
12413 (process_serial_event): Adjust.
12414 * target.h (struct target_ops): New fields
12415 prepare_to_access_memory and unprepare_to_access_memory.
12416 (prepare_to_access_memory, unprepare_to_access_memory): New.
12417 * linux-x86-low.c (x86_insert_point, x86_remove_point): Use
12418 prepare_to_access_memory/prepare_to_access_memory.
12419 * nto-low.c (nto_target_ops): Adjust.
12420 * spu-low.c (spu_target_ops): Adjust.
12421 * win32-low.c (win32_target_ops): Adjust.
12422
12423 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12424
12425 * Makefile.in (WARN_CFLAGS): Get it from configure.
12426 (WERROR_CFLAGS): New.
12427 (INTERNAL_CFLAGS): Add WERROR_CFLAGS.
12428 * configure.ac: Introduce --enable-werror, which adds -Werror to
12429 the compiler command line. Enabled by default. Disable with
12430 --disable-werror. Add -Wdeclaration-after-statement
12431 Wpointer-arith and -Wformat-nonliteral to warning flags.
12432 * configure: Regenerate.
12433
12434 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12435
12436 * mem-break.c [HAVE_MALLOC_H]: Include malloc.h.
12437
12438 2010-08-26 Pedro Alves <pedro@codesourcery.com>
12439
12440 * gdbreplay.c (remote_error): New.
12441 (gdbchar): New.
12442 (expect): Use gdbchar. Check for error reading from GDB.
12443 Clarify sync error output.
12444 (play): Check for errors writing to GDB.
12445 * linux-low.c (sigchld_handler): Really ignore `write' errors.
12446 * remote-utils.c (getpkt): Check for errors writing to the remote
12447 descriptor.
12448
12449 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12450
12451 * linux-low.c (linux_wait_1): Move non-debugging code out of
12452 `debug_threads' control.
12453
12454 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12455
12456 * linux-low.c (linux_wait_1): Don't set last_status here.
12457 * server.c (push_event, queue_stop_reply_callback): Assert we're
12458 not pushing a TARGET_WAITKIND_IGNORE event.
12459 (start_inferior, start_inferior, attach_inferior, handle_v_cont)
12460 (myresume, handle_target_event): Set the thread's last_resume_kind
12461 and last_status from the target returned status.
12462
12463 2010-08-25 Pedro Alves <pedro@codesourcery.com>
12464
12465 PR threads/10729
12466
12467 * linux-x86-low.c (update_debug_registers_callback): New.
12468 (i386_dr_low_set_addr): Use it.
12469 (i386_dr_low_get_addr): New.
12470 (i386_dr_low_set_control): Use update_debug_registers_callback.
12471 (i386_dr_low_get_control): New.
12472 (i386_dr_low_get_status): Adjust.
12473 * linux-low.c (linux_stop_lwp): New.
12474 * linux-low.h (linux_stop_lwp): Declare.
12475
12476 * i386-low.c (I386_DR_GET_RW_LEN): Take the dr7 contents as
12477 argument instead of a i386_debug_reg_state.
12478 (I386_DR_WATCH_HIT): Take the dr6 contents as argument instead of
12479 a i386_debug_reg_state.
12480 (i386_insert_aligned_watchpoint): Adjust.
12481 (i386_remove_aligned_watchpoint): Adjust.
12482 (i386_low_stopped_data_address): Read the debug registers from the
12483 inferior instead of from the mirrors.
12484 * i386-low.h (struct i386_debug_reg_state): Extend comment.
12485 (i386_dr_low_get_addr): Declare.
12486 (i386_dr_low_get_control): Declare.
12487 (i386_dr_low_get_status): Change prototype.
12488
12489 * win32-i386-low.c (dr_status_mirror, dr_control_mirror): New globals.
12490 (i386_dr_low_get_addr): New.
12491 (i386_dr_low_get_control): New.
12492 (i386_dr_low_get_status): Adjust prototype. Return
12493 dr_status_mirror.
12494 (i386_initial_stuff): Clear dr_status_mirror and
12495 dr_control_mirror.
12496 (i386_get_thread_context): Adjust.
12497 (i386_set_thread_context): Adjust.
12498 (i386_thread_added): Adjust.
12499
12500 2010-08-24 Pedro Alves <pedro@codesourcery.com>
12501
12502 * linux-low.h (linux_thread_area): Delete declaration.
12503
12504 2010-08-11 Thomas Schwinge <thomas@codesourcery.com>
12505
12506 * linux-low.c (linux_wait_1): Correctly return the ptid of the child
12507 after its termination.
12508
12509 2010-08-09 Pedro Alves <pedro@codesourcery.com>
12510
12511 * linux-low.c (gdb_wants_lwp_stopped): Delete.
12512 (gdb_wants_all_stopped): Delete.
12513 (linux_wait_1): Don't call them.
12514 * server.c (handle_v_cont): Tag all threads as want-stopped.
12515 (gdb_wants_thread_stopped): Fix comments. Tag the thread that
12516 stopped as "client-wants-stopped".
12517
12518 2010-07-31 Pedro Alves <pedro@codesourcery.com>
12519
12520 * Makefile.in (signals_h): New.
12521 (server_h): Depend on it.
12522 (server.o): Don't depend on $(signals_def).
12523 (signals.o): Depend on $(signals_def).
12524
12525 2010-07-31 Jan Kratochvil <jan.kratochvil@redhat.com>
12526
12527 * Makefile.in (signals_def): New.
12528 (server_h): Append include/gdb/signals.h and signals_def.
12529 (server.o): Append signals_def.
12530
12531 2010-07-25 Jan Kratochvil <jan.kratochvil@redhat.com>
12532
12533 * server.c (handle_target_event): Use target_signal_to_host for
12534 resume_info.sig initialization.
12535 * target.h (struct thread_resume) <sig>: New comment.
12536
12537 2010-07-20 Ozkan Sezer <sezeroz@gmail.com>
12538
12539 * server.c (handle_query): strcpy() the returned string from paddress()
12540 instead of sprintf().
12541 * utils.c (paddress): Return phex_nz().
12542
12543 2010-07-07 Joel Brobecker <brobecker@adacore.com>
12544
12545 * server.c (handle_v_cont): Call mourn_inferior if process
12546 just exited.
12547 (myresume): Likewise.
12548
12549 2010-07-01 Pedro Alves <pedro@codesourcery.com>
12550
12551 Static tracepoints, and integration with UST.
12552
12553 * configure.ac: Handle --with-ust. substitute ustlibs and ustinc.
12554 * mem-break.c (uninsert_all_breakpoints)
12555 (reinsert_all_breakpoints): New.
12556 * mem-break.h (reinsert_all_breakpoints, uninsert_all_breakpoints):
12557 * tracepoint.c (ust_loaded, helper_thread_id, cmd_buf): New.
12558 (gdb_agent_ust_loaded, helper_thread_id)
12559 (gdb_agent_helper_thread_id): New macros.
12560 (struct ipa_sym_addresses): Add addr_ust_loaded,
12561 addr_helper_thread_id, addr_cmd_buf.
12562 (symbol_list): Add ust_loaded, helper_thread_id, cmd_buf.
12563 (in_process_agent_loaded_ust): New.
12564 (write_e_ust_not_loaded): New.
12565 (maybe_write_ipa_ust_not_loaded): New.
12566 (struct collect_static_trace_data_action): New.
12567 (enum tracepoint_type) <static_tracepoint>: New.
12568 (struct tracepoint) <handle>: Mention static tracepoints.
12569 (struct static_tracepoint_ctx): New.
12570 (CMD_BUF_SIZE): New.
12571 (add_tracepoint_action): Handle static tracepoint actions.
12572 (unprobe_marker_at): New.
12573 (clear_installed_tracepoints): Handle static tracepoints.
12574 (cmd_qtdp): Handle static tracepoints.
12575 (probe_marker_at): New.
12576 (cmd_qtstart): Handle static tracepoints.
12577 (response_tracepoint): Handle static tracepoints.
12578 (cmd_qtfstm, cmd_qtsstm, cmd_qtstmat): New.
12579 (handle_tracepoint_query): Handle qTfSTM, qTsSTM and qTSTMat.
12580 (get_context_regcache): Handle static tracepoints.
12581 (do_action_at_tracepoint): Handle static tracepoint actions.
12582 (traceframe_find_block_type): Handle static trace data blocks.
12583 (traceframe_read_sdata): New.
12584 (download_tracepoints): Download static tracepoint actions.
12585 [HAVE_UST] Include ust/ust.h, dlfcn.h, sys/socket.h, and sys/un.h.
12586 (GDB_PROBE_NAME): New.
12587 (ust_ops): New.
12588 (GET_UST_SYM): New.
12589 (USTF): New.
12590 (dlsym_ust): New.
12591 (ust_marker_to_static_tracepoint): New.
12592 (gdb_probe): New.
12593 (collect_ust_data_at_tracepoint): New.
12594 (gdb_ust_probe): New.
12595 (UNIX_PATH_MAX, SOCK_DIR): New.
12596 (gdb_ust_connect_sync_socket): New.
12597 (resume_thread, stop_thread): New.
12598 (run_inferior_command): New.
12599 (init_named_socket): New.
12600 (gdb_ust_socket_init): New.
12601 (cstr_to_hexstr): New.
12602 (next_st): New.
12603 (first_marker, next_marker): New.
12604 (response_ust_marker): New.
12605 (cmd_qtfstm, cmd_qtsstm): New.
12606 (unprobe_marker_at, probe_marker_at): New.
12607 (cmd_qtstmat, gdb_ust_thread): New.
12608 (gdb_ust_init): New.
12609 (initialize_tracepoint_ftlib): Call gdb_ust_init.
12610 * linux-amd64-ipa.c [HAVE_UST]: Include ust/processor.h
12611 (ST_REGENTRY): New.
12612 (x86_64_st_collect_regmap): New.
12613 (X86_64_NUM_ST_COLLECT_GREGS): New.
12614 (AMD64_RIP_REGNUM): New.
12615 (supply_static_tracepoint_registers): New.
12616 * linux-i386-ipa.c [HAVE_UST]: Include ust/processor.h
12617 (ST_REGENTRY): New.
12618 (i386_st_collect_regmap): New.
12619 (i386_NUM_ST_COLLECT_GREGS): New.
12620 (supply_static_tracepoint_registers): New.
12621 * server.c (handle_query): Handle qXfer:statictrace:read.
12622 <qSupported>: Report support for StaticTracepoints, and
12623 qXfer:statictrace:read features.
12624 * server.h (traceframe_read_sdata)
12625 (supply_static_tracepoint_registers): Declare.
12626 * remote-utils.c (convert_int_to_ascii, hexchars, ishex, tohex)
12627 (unpack_varlen_hex): Include in IPA build.
12628 * Makefile.in (ustlibs, ustinc): New.
12629 (IPA_OBJS): Add remote-utils-ipa.o.
12630 ($(IPA_LIB)): Link -ldl and -lpthread.
12631 (UST_CFLAGS): New.
12632 (IPAGENT_CFLAGS): Add UST_CFLAGS.
12633 * config.in, configure: Regenerate.
12634
12635 2010-06-20 Ian Lance Taylor <iant@google.com>
12636 Pedro Alves <pedro@codesourcery.com>
12637
12638 * linux-x86-low.c (always_true): Delete.
12639 (EMIT_ASM, EMIT_ASM32): Use an uncondition asm jmp instead of
12640 trying to fool the compiler with always_true.
12641
12642 2010-06-20 Pedro Alves <pedro@codesourcery.com>
12643
12644 * tracepoint.c (condition_true_at_tracepoint): Don't run compiled
12645 conditions in gdbserver.
12646
12647 2010-06-19 Ulrich Weigand <uweigand@de.ibm.com>
12648
12649 * spu-low.c (spu_read_memory): Wrap around local store limit.
12650 (spu_write_memory): Likewise.
12651
12652 2010-06-15 Pedro Alves <pedro@codesourcery.com>
12653
12654 * linux-x86-low.c (amd64_emit_const, amd64_emit_void_call_2)
12655 (i386_emit_const, i386_emit_void_call_2): Replace int64_t uses with
12656 LONGEST uses.
12657 * server.h (struct emit_ops): Replace int64_t uses with LONGEST
12658 uses.
12659 * tracepoint.c (emit_const, emit_void_call_2): Replace int64_t
12660 uses with LONGEST uses.
12661
12662 2010-06-14 Stan Shebs <stan@codesourcery.com>
12663 Pedro Alves <pedro@codesourcery.com>
12664
12665 Bytecode compiler.
12666
12667 * linux-x86-low.c: Include limits.h.
12668 (add_insns): New.
12669 (always_true): New.
12670 (EMIT_ASM): New.
12671 (EMIT_ASM32): New.
12672 (amd64_emit_prologue, amd64_emit_epilogue, amd64_emit_add)
12673 (amd64_emit_sub, amd64_emit_mul, amd64_emit_lsh)
12674 (amd64_emit_rsh_signed, amd64_emit_rsh_unsigned, amd64_emit_ext,
12675 (amd64_emit_log_not, amd64_emit_bit_and, amd64_emit_bit_or)
12676 (amd64_emit_bit_xor, amd64_emit_bit_not, amd64_emit_equal,
12677 (amd64_emit_less_signed, amd64_emit_less_unsigned, amd64_emit_ref,
12678 (amd64_emit_if_goto, amd64_emit_goto, amd64_write_goto_address)
12679 (amd64_emit_const, amd64_emit_call, amd64_emit_reg)
12680 (amd64_emit_pop, amd64_emit_stack_flush, amd64_emit_zero_ext)
12681 (amd64_emit_swap, amd64_emit_stack_adjust, amd64_emit_int_call_1)
12682 (amd64_emit_void_call_2): New.
12683 (amd64_emit_ops): New.
12684 (i386_emit_prologue, i386_emit_epilogue, i386_emit_add)
12685 (i386_emit_sub,i386_emit_mul, i386_emit_lsh, i386_emit_rsh_signed)
12686 (i386_emit_rsh_unsigned, i386_emit_ext, i386_emit_log_not)
12687 (i386_emit_bit_and, i386_emit_bit_or, i386_emit_bit_xor)
12688 (i386_emit_bit_not, i386_emit_equal, i386_emit_less_signed)
12689 (i386_emit_less_unsigned, i386_emit_ref, i386_emit_if_goto)
12690 (i386_emit_goto, i386_write_goto_address, i386_emit_const)
12691 (i386_emit_call, i386_emit_reg, i386_emit_pop)
12692 (i386_emit_stack_flush, i386_emit_zero_ext, i386_emit_swap)
12693 (i386_emit_stack_adjust, i386_emit_int_call_1)
12694 (i386_emit_void_call_2): New.
12695 (i386_emit_ops): New.
12696 (x86_emit_ops): New.
12697 (the_low_target): Install x86_emit_ops.
12698 * server.h (struct emit_ops): New.
12699 (get_raw_reg_func_addr): Declare.
12700 (current_insn_ptr, emit_error): Declare.
12701 * tracepoint.c (get_raw_reg, get_trace_state_variable_value)
12702 (set_trace_state_variable_value): New defines.
12703 (struct ipa_sym_addresses): New fields addr_get_raw_reg,
12704 addr_get_trace_state_variable_value and
12705 addr_set_trace_state_variable_value.
12706 (symbol_list): New fields for get_raw_reg,
12707 get_trace_state_variable_value and set_trace_state_variable_value.
12708 (condfn): New typedef.
12709 (struct tracepoint): New field `compiled_cond'.
12710 (do_action_at_tracepoint): Clear compiled_cond.
12711 (get_trace_state_variable_value, set_trace_state_variable_value):
12712 Export in the IPA.
12713 (condition_true_at_tracepoint): If there's a compiled condition,
12714 run that.
12715 (current_insn_ptr, emit_error): New globals.
12716 (struct bytecode_address): New.
12717 (get_raw_reg_func_addr): New.
12718 (emit_prologue, emit_epilogue, emit_add, emit_sub, emit_mul)
12719 (emit_lsh, emit_rsh_signed, emit_rsh_unsigned, emit_ext)
12720 (emit_log_not, emit_bit_and, emit_bit_or, emit_bit_xor)
12721 (emit_bit_not, emit_equal, emit_less_signed, emit_less_unsigned)
12722 (emit_ref, emit_if_goto, emit_goto, write_goto_address, emit_const)
12723 (emit_reg, emit_pop, emit_stack_flush, emit_zero_ext, emit_swap)
12724 (emit_stack_adjust, emit_int_call_1, emit_void_call_2): New.
12725 (compile_tracepoint_condition, compile_bytecodes): New.
12726 * target.h (emit_ops): Forward declare.
12727 (struct target_ops): New field emit_ops.
12728 (target_emit_ops): New.
12729 * linux-amd64-ipa.c (gdb_agent_get_raw_reg): New.
12730 * linux-i386-ipa.c (gdb_agent_get_raw_reg): New.
12731 * linux-low.c (linux_emit_ops): New.
12732 (linux_target_ops): Install it.
12733 * linux-low.h (struct linux_target_ops): New field emit_ops.
12734
12735 2010-06-14 Ulrich Weigand <uweigand@de.ibm.com>
12736
12737 * linux-ppc-low.c (ppc_arch_setup): Use private regcache to test MSR.
12738 * linux-s390-low.c (ppc_arch_setup): Use private regcache to test PSW.
12739
12740 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12741 Stan Shebs <stan@codesourcery.com>
12742
12743 * Makefile.in (IPA_DEPFILES, extra_libraries): New.
12744 (all): Depend on $(extra_libraries).
12745 (install-only): Install the IPA.
12746 (IPA_OBJS, IPA_LIB): New.
12747 (clean): Remove the IPA lib.
12748 (IPAGENT_CFLAGS): New.
12749 (tracepoint-ipa.o, utils-ipa.o, remote-utils-ipa.o)
12750 (regcache-ipa.o, i386-linux-ipa.o, linux-i386-ipa.o)
12751 (linux-amd64-ipa.o, amd64-linux-ipa.o): New rules.
12752 * linux-amd64-ipa.c, linux-i386-ipa.c: New files.
12753 * configure.ac: Check for atomic builtins support in the compiler.
12754 (IPA_DEPFILES, extra_libraries): Define.
12755 * configure.srv (ipa_obj): Add description.
12756 (ipa_i386_linux_regobj, ipa_amd64_linux_regobj): Define.
12757 (i[34567]86-*-linux*): Set ipa_obj.
12758 (x86_64-*-linux*): Set ipa_obj.
12759 * linux-low.c (stabilizing_threads): New.
12760 (supports_fast_tracepoints): New.
12761 (linux_detach): Stabilize threads before detaching.
12762 (handle_tracepoints): Handle internal tracing breakpoints. Assert
12763 the lwp is either not stabilizing, or is moving out of a jump pad.
12764 (linux_fast_tracepoint_collecting): New.
12765 (maybe_move_out_of_jump_pad): New.
12766 (enqueue_one_deferred_signal): New.
12767 (dequeue_one_deferred_signal): New.
12768 (linux_wait_for_event_1): If moving out of a jump pad, defer
12769 pending signals to later.
12770 (linux_stabilize_threads): New.
12771 (linux_wait_1): Check if threads need moving out of jump pads, and
12772 do it if so.
12773 (stuck_in_jump_pad_callback): New.
12774 (move_out_of_jump_pad_callback): New.
12775 (lwp_running): New.
12776 (linux_resume_one_lwp): Handle moving out of jump pads.
12777 (linux_set_resume_request): Dequeue deferred signals.
12778 (need_step_over_p): Also step over fast tracepoint jumps.
12779 (start_step_over): Also uninsert fast tracepoint jumps.
12780 (finish_step_over): Also reinsert fast tracepoint jumps.
12781 (linux_install_fast_tracepoint_jump): New.
12782 (linux_target_ops): Install linux_stabilize_threads and
12783 linux_install_fast_tracepoint_jump_pad.
12784 * linux-low.h (linux_target_ops) <get_thread_area,
12785 install_fast_tracepoint_jump_pad>: New fields.
12786 (struct lwp_info) <collecting_fast_tracepoint,
12787 pending_signals_to_report, exit_jump_pad_bkpt>: New fields.
12788 (linux_get_thread_area): Declare.
12789 * linux-x86-low.c (jump_insn): New.
12790 (x86_get_thread_area): New.
12791 (append_insns): New.
12792 (push_opcode): New.
12793 (amd64_install_fast_tracepoint_jump_pad): New.
12794 (i386_install_fast_tracepoint_jump_pad): New.
12795 (x86_install_fast_tracepoint_jump_pad): New.
12796 (the_low_target): Install x86_get_thread_area and
12797 x86_install_fast_tracepoint_jump_pad.
12798 * mem-break.c (set_raw_breakpoint_at): Use read_inferior_memory.
12799 (struct fast_tracepoint_jump): New.
12800 (fast_tracepoint_jump_insn): New.
12801 (fast_tracepoint_jump_shadow): New.
12802 (find_fast_tracepoint_jump_at): New.
12803 (fast_tracepoint_jump_here): New.
12804 (delete_fast_tracepoint_jump): New.
12805 (set_fast_tracepoint_jump): New.
12806 (uninsert_fast_tracepoint_jumps_at): New.
12807 (reinsert_fast_tracepoint_jumps_at): New.
12808 (set_breakpoint_at): Use write_inferior_memory.
12809 (uninsert_raw_breakpoint): Use write_inferior_memory.
12810 (check_mem_read): Mask out fast tracepoint jumps.
12811 (check_mem_write): Mask out fast tracepoint jumps.
12812 * mem-break.h (struct fast_tracepoint_jump): Forward declare.
12813 (set_fast_tracepoint_jump): Declare.
12814 (delete_fast_tracepoint_jump)
12815 (fast_tracepoint_jump_here, uninsert_fast_tracepoint_jumps_at)
12816 (reinsert_fast_tracepoint_jumps_at): Declare.
12817 * regcache.c: Don't compile many functions when building the
12818 in-process agent library.
12819 (init_register_cache) [IN_PROCESS_AGENT]: Don't allow allocating
12820 the register buffer in the heap.
12821 (free_register_cache): If the register buffer isn't owned by the
12822 regcache, don't free it.
12823 (set_register_cache) [IN_PROCESS_AGENT]: Don't re-alocate
12824 pre-existing register caches.
12825 * remote-utils.c (convert_int_to_ascii): Constify `from' parameter
12826 type.
12827 (convert_ascii_to_int): : Constify `from' parameter type.
12828 (decode_M_packet, decode_X_packet): Replace the `to' parameter by
12829 a `to_p' pointer to pointer parameter. If TO_P is NULL, malloc
12830 the needed buffer in-place.
12831 (relocate_instruction): New.
12832 * server.c (handle_query) <qSymbols>: If the target supports
12833 tracepoints, give it a chance of looking up symbols. Report
12834 support for fast tracepoints.
12835 (handle_status): Stabilize threads.
12836 (process_serial_event): Adjust.
12837 * server.h (struct fast_tracepoint_jump): Forward declare.
12838 (struct process_info) <fast_tracepoint_jumps>: New field.
12839 (convert_ascii_to_int, convert_int_to_ascii): Adjust.
12840 (decode_X_packet, decode_M_packet): Adjust.
12841 (relocate_instruction): Declare.
12842 (in_process_agent_loaded): Declare.
12843 (tracepoint_look_up_symbols): Declare.
12844 (struct fast_tpoint_collect_status): Declare.
12845 (fast_tracepoint_collecting): Declare.
12846 (force_unlock_trace_buffer): Declare.
12847 (handle_tracepoint_bkpts): Declare.
12848 (initialize_low_tracepoint)
12849 (supply_fast_tracepoint_registers) [IN_PROCESS_AGENT]: Declare.
12850 * target.h (struct target_ops) <stabilize_threads,
12851 install_fast_tracepoint_jump_pad>: New fields.
12852 (stabilize_threads, install_fast_tracepoint_jump_pad): New.
12853 * tracepoint.c [HAVE_MALLOC_H]: Include malloc.h.
12854 [HAVE_STDINT_H]: Include stdint.h.
12855 (trace_debug_1): Rename to ...
12856 (trace_vdebug): ... this.
12857 (trace_debug): Rename to ...
12858 (trace_debug_1): ... this. Add `level' parameter.
12859 (trace_debug): New.
12860 (ATTR_USED, ATTR_NOINLINE): New.
12861 (IP_AGENT_EXPORT): New.
12862 (gdb_tp_heap_buffer, gdb_jump_pad_buffer, gdb_jump_pad_buffer_end)
12863 (collecting, gdb_collect, stop_tracing, flush_trace_buffer)
12864 (about_to_request_buffer_space, trace_buffer_is_full)
12865 (stopping_tracepoint, expr_eval_result, error_tracepoint)
12866 (tracepoints, tracing, trace_buffer_ctrl, trace_buffer_ctrl_curr)
12867 (trace_buffer_lo, trace_buffer_hi, traceframe_read_count)
12868 (traceframe_write_count, traceframes_created)
12869 (trace_state_variables)
12870 New renaming defines.
12871 (struct ipa_sym_addresses): New.
12872 (STRINGIZE_1, STRINGIZE, IPA_SYM): New.
12873 (symbol_list): New.
12874 (ipa_sym_addrs): New.
12875 (all_tracepoint_symbols_looked_up): New.
12876 (in_process_agent_loaded): New.
12877 (write_e_ipa_not_loaded): New.
12878 (maybe_write_ipa_not_loaded): New.
12879 (tracepoint_look_up_symbols): New.
12880 (debug_threads) [IN_PROCESS_AGENT]: New.
12881 (read_inferior_memory) [IN_PROCESS_AGENT]: New.
12882 (UNKNOWN_SIDE_EFFECTS): New.
12883 (stop_tracing): New.
12884 (flush_trace_buffer): New.
12885 (stop_tracing_bkpt): New.
12886 (flush_trace_buffer_bkpt): New.
12887 (read_inferior_integer): New.
12888 (read_inferior_uinteger): New.
12889 (read_inferior_data_pointer): New.
12890 (write_inferior_data_pointer): New.
12891 (write_inferior_integer): New.
12892 (write_inferior_uinteger): New.
12893 (struct collect_static_trace_data_action): Delete.
12894 (enum tracepoint_type): New.
12895 (struct tracepoint) <type>: New field `type'.
12896 <actions_str, step_actions, step_actions_str>: Only include in
12897 GDBserver.
12898 <orig_size, obj_addr_on_target, adjusted_insn_addr>
12899 <adjusted_insn_addr_end, jump_pad, jump_pad_end>: New fields.
12900 (tracepoints): Use IP_AGENT_EXPORT.
12901 (last_tracepoint): Don't include in the IPA.
12902 (stopping_tracepoint): Use IP_AGENT_EXPORT.
12903 (trace_buffer_is_full): Use IP_AGENT_EXPORT.
12904 (alloced_trace_state_variables): New.
12905 (trace_state_variables): Use IP_AGENT_EXPORT.
12906 (traceframe_t): Delete unused variable.
12907 (circular_trace_buffer): Don't include in the IPA.
12908 (trace_buffer_start): Delete.
12909 (struct trace_buffer_control): New.
12910 (trace_buffer_free): Delete.
12911 (struct ipa_trace_buffer_control): New.
12912 (GDBSERVER_FLUSH_COUNT_MASK, GDBSERVER_FLUSH_COUNT_MASK_PREV)
12913 (GDBSERVER_FLUSH_COUNT_MASK_CURR, GDBSERVER_UPDATED_FLUSH_COUNT_BIT):
12914 New.
12915 (trace_buffer_ctrl): New.
12916 (TRACE_BUFFER_CTRL_CURR): New.
12917 (trace_buffer_start, trace_buffer_free, trace_buffer_end_free):
12918 Reimplement as macros.
12919 (trace_buffer_wrap): Delete.
12920 (traceframe_write_count, traceframe_read_count)
12921 (traceframes_created, tracing): Use IP_AGENT_EXPORT.
12922 (struct tracepoint_hit_ctx) <type>: New field.
12923 (struct fast_tracepoint_ctx): New.
12924 (memory_barrier): New.
12925 (cmpxchg): New.
12926 (record_tracepoint_error): Update atomically in the IPA.
12927 (clear_inferior_trace_buffer): New.
12928 (about_to_request_buffer_space): New.
12929 (trace_buffer_alloc): Handle GDBserver and inferior simulatenous
12930 updating the same buffer.
12931 (add_tracepoint): Default the tracepoint's type to trap
12932 tracepoint, and orig_size to -1.
12933 (get_trace_state_variable) [IN_PROCESS_AGENT]: Handle allocated
12934 internal variables.
12935 (create_trace_state_variable): New parameter `gdb'. Handle it.
12936 (clear_installed_tracepoints): Clear fast tracepoint jumps.
12937 (cmd_qtdp): Handle fast tracepoints.
12938 (cmd_qtdv): Adjust.
12939 (max_jump_pad_size): New.
12940 (gdb_jump_pad_head): New.
12941 (get_jump_space_head): New.
12942 (claim_jump_space): New.
12943 (sort_tracepoints): New.
12944 (MAX_JUMP_SIZE): New.
12945 (cmd_qtstart): Handle fast tracepoints. Sync tracepoints with the
12946 IPA.
12947 (stop_tracing) [IN_PROCESS_AGENT]: Don't include the tdisconnected
12948 support. Upload fast traceframes, and delete internal IPA
12949 breakpoints.
12950 (stop_tracing_handler): New.
12951 (flush_trace_buffer_handler): New.
12952 (cmd_qtstop): Upload fast tracepoints.
12953 (response_tracepoint): Handle fast tracepoints.
12954 (tracepoint_finished_step): Upload fast traceframes. Set the
12955 tracepoint hit context's tracepoint type.
12956 (handle_tracepoint_bkpts): New.
12957 (tracepoint_was_hit): Set the tracepoint hit context's tracepoint
12958 type. Add comment about fast tracepoints.
12959 (collect_data_at_tracepoint) [IN_PROCESS_AGENT]: Don't access the
12960 non-existing action_str field.
12961 (get_context_regcache): Handle fast tracepoints.
12962 (do_action_at_tracepoint) [!IN_PROCESS_AGENT]: Don't write the PC
12963 to the regcache.
12964 (fast_tracepoint_from_jump_pad_address): New.
12965 (fast_tracepoint_from_ipa_tpoint_address): New.
12966 (collecting_t): New.
12967 (force_unlock_trace_buffer): New.
12968 (fast_tracepoint_collecting): New.
12969 (collecting): New.
12970 (gdb_collect): New.
12971 (write_inferior_data_ptr): New.
12972 (target_tp_heap): New.
12973 (target_malloc): New.
12974 (download_agent_expr): New.
12975 (UALIGN): New.
12976 (download_tracepoints): New.
12977 (download_trace_state_variables): New.
12978 (upload_fast_traceframes): New.
12979 (IPA_FIRST_TRACEFRAME): New.
12980 (IPA_NEXT_TRACEFRAME_1): New.
12981 (IPA_NEXT_TRACEFRAME): New.
12982 [IN_PROCESS_AGENT]: Include sys/mman.h and fcntl.h.
12983 [IN_PROCESS_AGENT] (gdb_tp_heap_buffer, gdb_jump_pad_buffer)
12984 (gdb_jump_pad_buffer_end): New.
12985 [IN_PROCESS_AGENT] (initialize_tracepoint_ftlib): New.
12986 (initialize_tracepoint): Adjust.
12987 [IN_PROCESS_AGENT]: Allocate the IPA heap, and jump pad scratch
12988 buffer. Initialize the low module.
12989 * utils.c (PREFIX, TOOLNAME): New.
12990 (malloc_failure): Use PREFIX.
12991 (error): In the IPA, an error causes an exit.
12992 (fatal, warning): Use PREFIX.
12993 (internal_error): Use TOOLNAME.
12994 (NUMCELLS): Increase to 10.
12995 * configure, config.in: Regenerate.
12996
12997 2010-06-01 Pedro Alves <pedro@codesourcery.com>
12998
12999 * server.c (handle_query) <qSupported>: Do two passes over the
13000 qSupported string to avoid nesting strtok.
13001
13002 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13003
13004 * Makefile.in (SFILES): Add $(srcdir)/proc-service.list.
13005 (CDEPS): New.
13006 * configure.ac (RDYNAMIC): New AC_MSG_CHECKING wrapping. Test also
13007 -Wl,--dynamic-list.
13008 * configure: Regenerate.
13009 * proc-service.list: New.
13010
13011 2010-05-28 Jan Kratochvil <jan.kratochvil@redhat.com>
13012
13013 * linux-low.c (linux_core_of_thread): Fix crash on invalid CONTENT.
13014 New comment.
13015
13016 2010-05-26 Ozkan Sezer <sezeroz@gmail.com>
13017
13018 * gdbreplay.c (remote_open): Check error return from socket() call by
13019 its equality to -1 not by it being negative.
13020 * remote-utils.c (remote_open): Likewise.
13021
13022 2010-05-23 Pedro Alves <pedro@codesourcery.com>
13023
13024 * config.h: Regenerate.
13025
13026 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13027
13028 * linux-m68k-low.c (ps_get_thread_area): Don't define if kernel
13029 doesn't provide PTRACE_GET_THREAD_AREA.
13030
13031 2010-05-19 Maxim Kuvyrkov <maxim@codesourcery.com>
13032
13033 * linux-m68k-low.c: Include <asm/ptrace.h>
13034 (ps_get_thread_area): Implement.
13035
13036 2010-05-03 Doug Evans <dje@google.com>
13037
13038 * event-loop.c (struct callback_event): New struct.
13039 (callback_list): New global.
13040 (append_callback_event, delete_callback_event): New functions.
13041 (process_callback): New function.
13042 (start_event_loop): Call it.
13043 * remote-utils.c (NOT_SCHEDULED): Define.
13044 (readchar_buf, readchar_bufcnt, readchar_bufp): New static globals,
13045 moved out of readchar.
13046 (readchar): Rewrite. Call reschedule before returning.
13047 (reset_readchar): New function.
13048 (remote_close): Call it.
13049 (process_remaining, reschedule): New functions.
13050 * server.h (callback_handler_func): New typedef.
13051 (append_callback_event, delete_callback_event): Declare.
13052
13053 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13054
13055 * proc-service.c (ps_pglobal_lookup): Use
13056 thread_db_look_up_one_symbol.
13057 * remote-utils.c (look_up_one_symbol): Add new `may_ask_gdb'
13058 parameter. Use it instead of all_symbols_looked_up.
13059 * server.h (struct process_info) <all_symbols_looked_up>: Delete
13060 field.
13061 (all_symbols_looked_up): Don't declare.
13062 (look_up_one_symbol): Add new `may_ask_gdb' parameter.
13063 * thread-db.c (struct thread_db) <all_symbols_looked_up>: New
13064 field.
13065 (thread_db_look_up_symbols): Adjust call to look_up_one_symbol.
13066 Set all_symbols_looked_up here.
13067 (thread_db_look_up_one_symbol): New.
13068 (thread_db_get_tls_address): Adjust.
13069 (thread_db_load_search, try_thread_db_load_1): Always allocate the
13070 thread_db object on the heap, and tentatively set it in the
13071 process structure.
13072 (thread_db_init): Don't set all_symbols_looked_up here.
13073 * linux-low.h (thread_db_look_up_one_symbol): Declare.
13074
13075 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13076
13077 * linux-low.c (linux_kill, linux_detach): Adjust.
13078 (status_pending_p_callback): Remove redundant statement. Check
13079 for !TARGET_WAITIKIND_IGNORE, instead of
13080 TARGET_WAITKIND_STOPPED.
13081 (handle_tracepoints): Make sure LWP is locked. Adjust.
13082 (linux_wait_for_event_1): Adjust.
13083 (linux_cancel_breakpoints): New.
13084 (unsuspend_one_lwp): New.
13085 (unsuspend_all_lwps): New.
13086 (linux_wait_1): If finishing a step-over, unsuspend all lwps.
13087 (send_sigstop_callback): Change return type to int, add new
13088 `except' parameter and handle it.
13089 (suspend_and_send_sigstop_callback): New.
13090 (stop_all_lwps): Add new `suspend' and `expect' parameters, and
13091 pass them down. If SUSPEND, also increment the lwp's suspend
13092 count.
13093 (linux_resume_one_lwp): Add notice about resuming a suspended LWP.
13094 (need_step_over_p): Don't consider suspended LWPs.
13095 (start_step_over): Adjust.
13096 (proceed_one_lwp): Change return type to int, add new `except'
13097 parameter and handle it.
13098 (unsuspend_and_proceed_one_lwp): New.
13099 (proceed_all_lwps): Use find_inferior instead of
13100 for_each_inferior.
13101 (unstop_all_lwps): Add `unsuspend' parameter. If UNSUSPEND, them
13102 also decrement the suspend count of LWPs. Pass `except' down,
13103 instead of hacking its suspend count.
13104 (linux_pause_all): Add `freeze' parameter. Adjust.
13105 (linux_unpause_all): New.
13106 (linux_target_ops): Install linux_unpause_all.
13107 * server.c (handle_status): Adjust.
13108 * target.h (struct target_ops): New fields `unpause_all' and
13109 `cancel_breakpoints'. Add new parameter to `pause_all'.
13110 (pause_all): Add new `freeze' parameter.
13111 (unpause_all): New.
13112 (cancel_breakpoints): New.
13113 * tracepoint.c (clear_installed_tracepoints): Pause threads, and
13114 cancel breakpoints.
13115 (cmd_qtstart): Pause threads.
13116 (stop_tracing): Pause threads, and cancel breakpoints.
13117 * win32-low.c (win32_target_ops): Adjust.
13118
13119 2010-05-03 Pedro Alves <pedro@codesourcery.com>
13120
13121 * linux-low.c (linux_wait_for_event_1): Move passing the signal to
13122 the inferior right away from here...
13123 (linux_wait_1): ... to here, and adjust to check the thread's
13124 last_resume_kind instead of the lwp's step or stop_expected flags.
13125
13126 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13127
13128 * README: Use consistent `GDB' and `GDBserver' spellings.
13129
13130 2010-05-02 Pedro Alves <pedro@codesourcery.com>
13131
13132 * linux-low.c (linux_kill_one_lwp): Assume the lwp is stopped.
13133 (linux_kill): Stop all lwps here. Don't delete the main lwp here.
13134 (linux_detach_one_lwp): Assume the lwp is stopped.
13135 (any_thread_of): Delete.
13136 (linux_detach): Stop all lwps here. Don't blindly delete all
13137 breakpoints.
13138 (delete_lwp_callback): New.
13139 (linux_mourn): Delete all lwps of the process that is gone.
13140 (linux_wait_1): Don't delete the last lwp of the process here.
13141 * mem-break.h (mark_breakpoints_out): Declare.
13142 * mem-break.c (mark_breakpoints_out): New.
13143 (free_all_breakpoints): Use it.
13144 * server.c (handle_target_event): If the process is gone, mark
13145 breakpoints out.
13146 * thread-db.c (struct thread_db) <create_bp>: New field.
13147 (thread_db_enable_reporting): Fix prototype. Store a thread event
13148 breakpoint reference in the thread_db struct.
13149 (thread_db_load_search): Clear the thread_db object.
13150 (try_thread_db_load_1): Ditto.
13151 (switch_to_process): New.
13152 (disable_thread_event_reporting): Use it.
13153 (remove_thread_event_breakpoints): New.
13154 (thread_db_detach, thread_db_mourn): Use it.
13155
13156 2010-05-01 Pedro Alves <pedro@codesourcery.com>
13157
13158 * linux-low.c (linux_enable_event_reporting): New.
13159 (linux_wait_for_event_1, handle_extended_wait): Use it.
13160
13161 2010-04-30 Pedro Alves <pedro@codesourcery.com>
13162
13163 * linux-low.c (linux_kill_one_lwp, linux_kill)
13164 (linux_detach_one_lwp): Adjust to send_sigstop interface change.
13165 (send_sigstop): Take an lwp_info as parameter instead. Queue a
13166 SIGSTOP even if the LWP is stopped.
13167 (send_sigstop_callback): New.
13168 (stop_all_lwps): Use send_sigstop_callback instead.
13169 (linux_resume_one_thread): Adjust.
13170 (proceed_one_lwp): Still proceed an LWP that the client has
13171 requested to stop, if we haven't reported it as stopped yet. Make
13172 sure that LWPs the client want stopped, have a pending SIGSTOP.
13173
13174 2010-04-26 Doug Evans <dje@google.com>
13175
13176 * server.c (handle_general_set): Make static.
13177
13178 * remote-utils.c (putpkt_binary_1): Call readchar instead of read.
13179 Print received char after testing for error/eof instead of before.
13180 (input_interrupt): Tweak comment.
13181
13182 2010-04-23 Doug Evans <dje@google.com>
13183
13184 * server.c (start_inferior): Print inferior argv if --debug.
13185
13186 2010-04-21 Aleksandar Ristovski <aristovski@qnx.com>
13187
13188 * Makefile.in (nto_low_h nto-low.o nto-x86-low.o): New dependency lists.
13189 * nto-x86-low.c: Include server.h
13190
13191 2010-04-20 Pierre Muller <muller@ics.u-strasbg.fr>
13192
13193 * win32-i386-low.c: Use __x86_64__ macro instead of __x86_64 to
13194 be consistent with other sources of this directory.
13195 (init_registers_amd64): Correct name of source file of this function
13196 in the comment.
13197
13198 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13199
13200 * configure.srv (x86_64-*-mingw*): New configuration for Windows
13201 64-bit executables.
13202
13203 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13204
13205 * win32-i386-low.c: Add 64-bit support.
13206 (CONTEXT_EXTENDED_REGISTERS): Set macro to zero if not exisiting.
13207 (init_registers_amd64): Declare.
13208 (mappings): Add 64-bit version of array.
13209 (init_windows_x86): New function.
13210 (the_low_target): Change init_arch field to init_windows_x86.
13211
13212 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13213
13214 * win32-low.c: Adapt to support also 64-bit architecture.
13215 (child_xfer_memory): Use uintptr_t type for local variable `addr'.
13216 (get_image_name): Use SIZE_T type for local variable `done'.
13217 (psapi_get_dll_name): Use LPVOID type for parameter `BaseAddress'.
13218 (toolhelp_get_dll_name): Idem.
13219 (handle_load_dll): Use CORE_ADDR type for local variable `load_addr'.
13220 Use uintptr_t typecast to avoid warning.
13221 (handle_unload_dll): Use uintptr_t typecast to avoid warning.
13222 (handle_exception): Use phex_nz to avoid warning.
13223 (win32_wait): Remove unused local variable `process'.
13224
13225 2010-04-19 Pierre Muller <muller@ics.u-strasbg.fr>
13226
13227 * configure.srv (srv_amd64_regobj): Replace `x86-64-avx.o' by
13228 `amd64-avx.o'.
13229
13230 2010-04-17 Pierre Muller <muller@ics.u-strasbg.fr>
13231
13232 * configure.ac: Use `ws2_32' library for srv_mingw.
13233 * configure: Regenerate.
13234 * gdbreplay.c: Include winsock2.h instead of winsock.h.
13235 * remote-utils.c: Likewise.
13236
13237 2010-04-17 H.J. Lu <hongjiu.lu@intel.com>
13238
13239 * linux-x86-low.c (xmltarget_amd64_linux_no_xml): Define only
13240 if __x86_64__ is defined.
13241
13242 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13243
13244 * configure: Regenerate.
13245
13246 2010-04-16 Pierre Muller <muller@ics.u-strasbg.fr>
13247
13248 * server.c (handle_query): Handle 'qGetTIBAddr' query.
13249 * target.h (target_ops): New get_tib_address field.
13250 * win32-low.h (win32_thread_info): Add thread_local_base field.
13251 * win32-low.c (child_add_thread): Add tlb argument.
13252 Set thread_local_base field to TLB.
13253 (get_child_debug_event): Adapt to child_add_thread change.
13254 (win32_get_tib_address): New function.
13255 (win32_target_ops): Set get_tib_address field to
13256 win32_get_tib_address.
13257 * linux-low.c (linux_target_ops): Set get_tib_address field to NULL.
13258
13259 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13260
13261 * linux-low.c (linux_mourn): Also remove the process.
13262 * server.c (handle_target_event): Don't remove the process here.
13263 * nto-low.c (nto_mourn): New.
13264 (nto_target_ops): Install it.
13265 * spu-low.c (spu_mourn): New.
13266 (spu_target_ops): Install it.
13267 * win32-low.c (win32_mourn): New.
13268 (win32_target_ops): Install it.
13269
13270 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13271
13272 * server.h (buffer_xml_printf): Remove redundant `;'.
13273
13274 2010-04-12 Pedro Alves <pedro@codesourcery.com>
13275
13276 * regcache.c (set_register_cache): Invalidate regcaches before
13277 changing the register cache layout.
13278 (regcache_invalidate_one): Allow a NULL regcache.
13279 * linux-x86-low.c (x86_linux_update_xmltarget): Invalidate
13280 regcaches before changing the register cache layout or the target
13281 regsets.
13282
13283 2010-04-12 H.J. Lu <hongjiu.lu@intel.com>
13284
13285 * linux-x86-low.c (x86_linux_update_xmltarget): Avoid unused
13286 variable warning on Linux/x86-64.
13287
13288 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13289
13290 GDBserver disconnected tracing support.
13291
13292 * linux-low.c (linux_remove_process): Delete.
13293 (add_lwp): Don't set last_resume_kind here.
13294 (linux_kill): Use `mourn'.
13295 (linux_detach): Use `thread_db_detach', and `mourn'.
13296 (linux_mourn): New.
13297 (linux_attach_lwp_1): Adjust comment.
13298 (linux_attach): last_resume_kind moved the thread_info; adjust.
13299 (status_pending_p_callback): Adjust.
13300 (linux_wait_for_event_1): Adjust.
13301 (count_events_callback, select_singlestep_lwp_callback)
13302 (select_event_lwp_callback, cancel_breakpoints_callback)
13303 (db_wants_lwp_stopped, linux_wait_1, need_step_over_p)
13304 (proceed_one_lwp): Adjust.
13305 (linux_async): Add debug output.
13306 (linux_thread_stopped): New.
13307 (linux_pause_all): New.
13308 (linux_target_ops): Install linux_mourn, linux_thread_stopped and
13309 linux_pause_all.
13310 * linux-low.h (struct lwp_info): Delete last_resume_kind field.
13311 (thread_db_free): Delete declaration.
13312 (thread_db_detach, thread_db_mourn): Declare.
13313 * thread-db.c (thread_db_init): Use thread_db_mourn.
13314 (thread_db_free): Delete, split in two.
13315 (disable_thread_event_reporting): New.
13316 (thread_db_detach): New.
13317 (thread_db_mourn): New.
13318
13319 * server.h (struct thread_info) <last_resume_kind>: New field.
13320 <attached>: Add comment.
13321 <gdb_detached>: New field.
13322 (handler_func): Change return type to int.
13323 (handle_serial_event, handle_target_event): Ditto.
13324 (gdb_connected): Declare.
13325 (tracing): Delete.
13326 (disconnected_tracing): Declare.
13327 (stop_tracing): Declare.
13328
13329 * server.c (handle_query) <qSupported>: Report support for
13330 disconnected tracing.
13331 (queue_stop_reply_callback): Account for running threads.
13332 (gdb_wants_thread_stopped): New.
13333 (gdb_wants_all_threads_stopped): New.
13334 (gdb_reattached_process): New.
13335 (handle_status): Clear the `gdb_detached' flag of all processes.
13336 In all-stop, stop all threads.
13337 (main): Be sure to leave tfind mode. Handle disconnected tracing.
13338 (process_serial_event): If the remote connection breaks, or if an
13339 exit was forced with "monitor exit", force an event loop exit.
13340 Handle disconnected tracing on detach.
13341 (handle_serial_event): Adjust.
13342 (handle_target_event): If GDB isn't connected, forward events back
13343 to the inferior, unless the last process exited, in which case,
13344 exit gdbserver. Adjust interface.
13345
13346 * remote-utils.c (remote_open): Don't block in accept. Instead
13347 register an event loop source on the listen socket file
13348 descriptor. Refactor bits into ...
13349 (listen_desc): ... this new global.
13350 (gdb_connected): ... this new function.
13351 (enable_async_notification): ... this new function.
13352 (handle_accept_event): ... this new function.
13353 (remote_close): Clear remote_desc.
13354
13355 * inferiors.c (add_thread): Set the new thread's last_resume_kind.
13356
13357 * target.h (struct target_ops) <mourn, thread_stopped, pause_all>:
13358 New fields.
13359 (mourn_inferior): Define.
13360 (target_process_qsupported): Avoid the dangling else problem.
13361 (thread_stopped): Define.
13362 (pause_all): Define.
13363 (target_waitstatus_to_string): Declare.
13364 * target.c (target_waitstatus_to_string): New.
13365
13366 * tracepoint.c (tracing): Make extern.
13367 (disconnected_tracing): New.
13368 (stop_tracing): Make extern. Handle tracing stops due to GDB
13369 disconnecting.
13370 (cmd_qtdisconnected): New.
13371 (cmd_qtstatus): Report disconnected tracing status in trace reply.
13372 (handle_tracepoint_general_set): Handle QTDisconnected.
13373
13374 * event-loop.c (event_handler_func): Change return type to int.
13375 (process_event): Bail out if the event handler wants the event
13376 loop to stop.
13377 (handle_file_event): Ditto.
13378 (start_event_loop): Bail out if the event handler wants the event
13379 loop to stop.
13380
13381 * nto-low.c (nto_target_ops): Adjust.
13382 * spu-low.c (spu_wait): Don't remove the process here.
13383 (spu_target_ops): Adjust.
13384 * win32-low.c (win32_wait): Don't remove the process here.
13385 (win32_target_ops): Adjust.
13386
13387 2010-04-11 Pedro Alves <pedro@codesourcery.com>
13388
13389 * regcache.c (realloc_register_cache): Invalidate inferior's
13390 regcache before recreating it.
13391
13392 2010-04-09 Pedro Alves <pedro@codesourcery.com>
13393
13394 * tracepoint.c (cmd_qtstatus): Report trace buffer circularity.
13395
13396 2010-04-09 Stan Shebs <stan@codesourcery.com>
13397 Pedro Alves <pedro@codesourcery.com>
13398
13399 * server.h (LONGEST): New.
13400 (struct thread_info) <while_stepping>: New field.
13401 (unpack_varlen_hex, xrealloc, pulongest, plongest, phex_nz):
13402 Declare.
13403 (initialize_tracepoint, handle_tracepoint_general_set)
13404 (handle_tracepoint_query, tracepoint_finished_step)
13405 (tracepoint_was_hit, release_while_stepping_state_list):
13406 (current_traceframe): Declare.
13407 * server.c (handle_general_set): Handle tracepoint packets.
13408 (read_memory): New.
13409 (write_memory): New.
13410 (handle_search_memory_1): Use read_memory.
13411 (handle_query): Report support for conditional tracepoints, trace
13412 state variables, and tracepoint sources. Handle tracepoint
13413 queries.
13414 (main): Initialize the tracepoints module.
13415 (process_serial_event): Handle traceframe reads/writes.
13416
13417 * linux-low.c (handle_tracepoints): New.
13418 (linux_wait_1): Call it.
13419 (linux_resume_one_lwp): Handle while-stepping.
13420 (linux_supports_tracepoints, linux_read_pc, linux_write_pc): New.
13421 (linux_target_ops): Install them.
13422 * linux-low.h (struct linux_target_ops) <supports_tracepoints>:
13423 New field.
13424 * linux-x86-low.c (x86_supports_tracepoints): New.
13425 (the_low_target). Install it.
13426
13427 * mem-break.h (delete_breakpoint): Declare.
13428 * mem-break.c (delete_breakpoint): Make external.
13429
13430 * target.h (struct target_ops): Add `supports_tracepoints',
13431 `read_pc', and `write_pc' fields.
13432 (target_supports_tracepoints): Define.
13433 * utils.c (xrealloc, decimal2str, pulongest, plongest, thirty_two)
13434 (phex_nz): New.
13435
13436 * regcache.h (struct regcache) <registers_owned>: New field.
13437 (init_register_cache, regcache_cpy): Declare.
13438 (regcache_read_pc, regcache_write_pc): Declare.
13439 (register_cache_size): Declare.
13440 (supply_regblock): Declare.
13441 * regcache.c (init_register_cache): New.
13442 (new_register_cache): Use it.
13443 (regcache_cpy): New.
13444 (register_cache_size): New.
13445 (supply_regblock): New.
13446 (regcache_read_pc, regcache_write_pc): New.
13447
13448 * tracepoint.c: New.
13449
13450 * Makefile.in (OBS): Add tracepoint.o.
13451 (tracepoint.o): New rule.
13452
13453 2010-04-08 H.J. Lu <hongjiu.lu@intel.com>
13454
13455 * Makefile.in (clean): Also remove i386-mmx.c i386-mmx-linux.c.
13456 (i386-mmx.o): New.
13457 (i386-mmx.c): Likewise.
13458 (i386-mmx-linux.o): Likewise.
13459 (i386-mmx-linux.c): Likewise.
13460
13461 * configure.srv (srv_i386_regobj): Add i386-mmx.o.
13462 (srv_i386_linux_regobj): Add i386-mmx-linux.o.
13463 (srv_i386_xmlfiles): Add i386/i386-mmx.xml.
13464 (srv_i386_linux_xmlfiles): Add i386/i386-mmx-linux.xml.
13465
13466 * linux-x86-low.c (init_registers_i386_mmx_linux): New.
13467 (x86_linux_update_xmltarget): Call init_registers_i386_mmx_linux
13468 and return if ptrace PTRACE_GETFPXREGS failed in 32bit.
13469
13470 2010-04-07 H.J. Lu <hongjiu.lu@intel.com>
13471
13472 * Makefile.in (clean): Updated.
13473 (i386-avx.o): New.
13474 (i386-avx.c): Likewise.
13475 (i386-avx-linux.o): Likewise.
13476 (i386-avx-linux.c): Likewise.
13477 (amd64-avx.o): Likewise.
13478 (amd64-avx.c): Likewise.
13479 (amd64-avx-linux.o): Likewise.
13480 (amd64-avx-linux.c): Likewise.
13481
13482 * configure.srv (srv_i386_regobj): Add i386-avx.o.
13483 (srv_i386_linux_regobj): Add i386-avx-linux.o.
13484 (srv_amd64_regobj): Add amd64-avx.o.
13485 (srv_amd64_linux_regobj): Add amd64-avx-linux.o.
13486 (srv_i386_32bit_xmlfiles): Add i386/32bit-avx.xml.
13487 (srv_i386_64bit_xmlfiles): Add i386/64bit-avx.xml.
13488 (srv_i386_xmlfiles): Add i386/i386-avx.xml.
13489 (srv_amd64_xmlfiles): Add i386/amd64-avx.xml.
13490 (srv_i386_linux_xmlfiles): Add i386/i386-avx-linux.xml.
13491 (srv_amd64_linux_xmlfiles): Add i386/amd64-avx-linux.xml.
13492
13493 * i387-fp.c: Include "i386-xstate.h".
13494 (i387_xsave): New.
13495 (i387_cache_to_xsave): Likewise.
13496 (i387_xsave_to_cache): Likewise.
13497 (x86_xcr0): Likewise.
13498
13499 * i387-fp.h (i387_cache_to_xsave): Likewise.
13500 (i387_xsave_to_cache): Likewise.
13501 (x86_xcr0): Likewise.
13502
13503 * linux-arm-low.c (target_regsets): Initialize nt_type to 0.
13504 * linux-crisv32-low.c (target_regsets): Likewise.
13505 * linux-m68k-low.c (target_regsets): Likewise.
13506 * linux-mips-low.c (target_regsets): Likewise.
13507 * linux-ppc-low.c (target_regsets): Likewise.
13508 * linux-s390-low.c (target_regsets): Likewise.
13509 * linux-sh-low.c (target_regsets): Likewise.
13510 * linux-sparc-low.c (target_regsets): Likewise.
13511 * linux-xtensa-low.c (target_regsets): Likewise.
13512
13513 * linux-low.c: Include <sys/uio.h>.
13514 (regsets_fetch_inferior_registers): Support nt_type.
13515 (regsets_store_inferior_registers): Likewise.
13516 (linux_process_qsupported): New.
13517 (linux_target_ops): Add linux_process_qsupported.
13518
13519 * linux-low.h (regset_info): Add nt_type.
13520 (linux_target_ops): Add process_qsupported.
13521
13522 * linux-x86-low.c: Include "i386-xstate.h", "elf/common.h"
13523 and <sys/uio.h>.
13524 (init_registers_i386_avx_linux): New.
13525 (init_registers_amd64_avx_linux): Likewise.
13526 (xmltarget_i386_linux_no_xml): Likewise.
13527 (xmltarget_amd64_linux_no_xml): Likewise.
13528 (PTRACE_GETREGSET): Likewise.
13529 (PTRACE_SETREGSET): Likewise.
13530 (x86_fill_xstateregset): Likewise.
13531 (x86_store_xstateregset): Likewise.
13532 (use_xml): Likewise.
13533 (x86_linux_update_xmltarget): Likewise.
13534 (x86_linux_process_qsupported): Likewise.
13535 (target_regsets): Add NT_X86_XSTATE entry and Initialize nt_type.
13536 (x86_arch_setup): Don't call init_registers_amd64_linux nor
13537 init_registers_i386_linux here. Call
13538 x86_linux_update_xmltarget.
13539 (the_low_target): Add x86_linux_process_qsupported.
13540
13541 * server.c (handle_query): Call target_process_qsupported.
13542
13543 * target.h (target_ops): Add process_qsupported.
13544 (target_process_qsupported): New.
13545
13546 2010-04-03 Pedro Alves <pedro@codesourcery.com>
13547
13548 * inferiors.c (add_thread): Set last_status kind to
13549 TARGET_WAITKIND_IGNORE.
13550 * linux-low.c (cancel_breakpoint): Remove unnecessary regcache
13551 fetch. Use ptid_of. Avoid unnecessary get_lwp_thread calls.
13552 (linux_wait_1): Move `thread' local definition to block that uses
13553 it. Don't NULL initialize `event_child'.
13554 (linux_resume_one_thread): Avoid unnecessary get_lwp_thread calls.
13555 Alway set the thread's last_status to TARGET_WAITKIND_IGNORE.
13556 * linux-x86-low.c (x86_breakpoint_at): Read raw memory.
13557
13558 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13559
13560 * linux-low.c (get_stop_pc): Don't adjust the PC if stopped with
13561 an extended waitstatus, or by a watchpoint.
13562 (cancel_breakpoints_callback): Don't cancel a breakpoint if the
13563 thread was stepping or has been stopped by a watchpoint.
13564
13565 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13566
13567 * mem-break.c (struct raw_breakpoint): New field shlib_disabled.
13568 (set_gdb_breakpoint_at): If GDB is inserting a breakpoint on top
13569 of another, then delete the previous, and validate all
13570 breakpoints.
13571 (validate_inserted_breakpoint): New.
13572 (delete_disabled_breakpoints): New.
13573 (validate_breakpoints): New.
13574 (check_mem_read): Validate breakpoints before trusting their
13575 shadow. Delete disabled breakpoints.
13576 (check_mem_write): Validate breakpoints before trusting they
13577 should be inserted. Delete disabled breakpoints.
13578 * mem-break.h (validate_breakpoints):
13579 * server.c (handle_query): Validate breakpoints when we see a
13580 qSymbol query.
13581
13582 2010-04-01 Pedro Alves <pedro@codesourcery.com>
13583
13584 * linux-low.c (linux_wait_1): Avoid setting need_step_over is
13585 there's a GDB breakpoint at stop_pc. Always report a trap to GDB
13586 if we could tell there's a GDB breakpoint at stop_pc.
13587 (need_step_over_p): Don't do a step over if we find a GDB
13588 breakpoint at the resume PC.
13589
13590 * mem-break.c (struct raw_breakpoint): New.
13591 (enum bkpt_type): New type `gdb_breakpoint'.
13592 (struct breakpoint): Delete the `PC', `old_data' and `inserted'
13593 fields. New field `raw'.
13594 (find_raw_breakpoint_at): New.
13595 (set_raw_breakpoint_at): Handle refcounting. Create a raw
13596 breakpoint instead.
13597 (set_breakpoint_at): Adjust.
13598 (delete_raw_breakpoint): New.
13599 (release_breakpoint): New.
13600 (delete_breakpoint): Rename to...
13601 (delete_breakpoint_1): ... this. Add proc parameter. Use
13602 release_breakpoint. Return ENOENT.
13603 (delete_breakpoint): Reimplement.
13604 (find_breakpoint_at): Delete.
13605 (find_gdb_breakpoint_at): New.
13606 (delete_breakpoint_at): Delete.
13607 (set_gdb_breakpoint_at): New.
13608 (delete_gdb_breakpoint_at): New.
13609 (gdb_breakpoint_here): New.
13610 (set_reinsert_breakpoint): Use release_breakpoint.
13611 (uninsert_breakpoint): Rename to ...
13612 (uninsert_raw_breakpoint): ... this.
13613 (uninsert_breakpoints_at): Adjust to handle raw breakpoints.
13614 (reinsert_raw_breakpoint): Change parameter type to
13615 raw_breakpoint.
13616 (reinsert_breakpoints_at): Adjust to handle raw breakpoints
13617 instead.
13618 (check_breakpoints): Adjust. Use release_breakpoint.
13619 (breakpoint_here): Rewrite using find_raw_breakpoint_at.
13620 (breakpoint_inserted_here): Ditto.
13621 (check_mem_read): Adjust to iterate over raw breakpoints instead.
13622 Don't trust the breakpoint's shadow if it is not inserted.
13623 (check_mem_write): Adjust to iterate over raw breakpoints instead.
13624 (delete_all_breakpoints): Adjust.
13625 (free_all_breakpoints): Mark all breakpoints as uninserted, and
13626 use delete_breakpoint_1.
13627
13628 * mem-break.h (breakpoints_supported): Delete declaration.
13629 (set_gdb_breakpoint_at): Declare.
13630 (gdb_breakpoint_here): Declare.
13631 (delete_breakpoint_at): Delete.
13632 (delete_gdb_breakpoint_at): Declare.
13633
13634 * server.h (struct raw_breakpoint): Forward declare.
13635 (struct process_info): New field `raw_breakpoints'.
13636
13637 * linux-x86-low.c (x86_insert_point, x86_remote_point): Handle Z0
13638 breakpoints.
13639
13640 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13641
13642 * linux-low.c (status_pending_p_callback): Fix comment.
13643 (linux_wait_for_event_1): Move most of the internal breakpoint
13644 handling from here...
13645 (linux_wait_1): ... to here.
13646 (count_events_callback): New.
13647 (select_singlestep_lwp_callback): New.
13648 (select_event_lwp_callback): New.
13649 (cancel_breakpoints_callback): New.
13650 (select_event_lwp): New.
13651 (linux_wait_1): Simplify internal breakpoint handling. Give equal
13652 priority to all LWPs that have had events that should be reported
13653 to the client. Cancel breakpoints when about to reporting the
13654 event to the client, not while stopping lwps. No longer cancel
13655 finished single-steps here.
13656 (cancel_finished_single_step): Delete.
13657 (cancel_finished_single_steps): Delete.
13658
13659 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13660
13661 * mem-break.c (enum bkpt_type): New.
13662 (struct breakpoint): New field `type'.
13663 (set_breakpoint_at): Change return type to struct breakpoint
13664 pointer. Set type to `other_breakpoint' by default.
13665 (delete_breakpoint): Rewrite, supporting more than one breakpoint
13666 in the breakpoint list.
13667 (delete_reinsert_breakpoints): Only delete reinsert breakpoints.
13668 (reinsert_breakpoint): Rename to ...
13669 (reinsert_raw_breakpoint): ... this.
13670 (reinsert_breakpoints_at): Adjust.
13671 * mem-break.h (struct breakpoint): Declare.
13672 (set_breakpoint_at): Change return type to struct breakpoint
13673 pointer.
13674
13675 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13676
13677 * server.c (handle_query): Assign, not compare.
13678
13679 2010-03-24 Pedro Alves <pedro@codesourcery.com>
13680
13681 Teach linux gdbserver to step-over-breakpoints.
13682
13683 * linux-low.c (can_hardware_single_step): New.
13684 (supports_breakpoints): New.
13685 (handle_extended_wait): If stopping threads, read the stop pc of
13686 the new cloned LWP.
13687 (get_pc): New.
13688 (get_stop_pc): Add `lwp' parameter. Handle it. Bail out if the
13689 low target doesn't support retrieving the PC.
13690 (add_lwp): Set last_resume_kind to resume_continue.
13691 (linux_attach_lwp_1): Adjust comments. Always set stop_expected.
13692 (linux_attach): Don't clear stop_expected. Set the lwp's
13693 last_resume_kind to resume_stop.
13694 (linux_detach_one_lwp): Don't check for removed breakpoints.
13695 (check_removed_breakpoint): Delete.
13696 (status_pending_p): Rename to ...
13697 (status_pending_p_callback): ... this. Don't check for removed
13698 breakpoints. Don't consider threads that are stopped from GDB's
13699 perspective.
13700 (linux_wait_for_lwp): Always read the stop_pc here.
13701 (cancel_breakpoint): New.
13702 (step_over_bkpt): New global.
13703 (linux_wait_for_event_1): Implement stepping over breakpoints.
13704 (gdb_wants_lwp_stopped): New.
13705 (gdb_wants_all_stopped): New.
13706 (linux_wait_1): Tag threads as gdb-wants-stopped. Cancel finished
13707 single-step traps here. Store the thread's last reported target
13708 wait status.
13709 (send_sigstop): Don't clear stop_expected. Always set it,
13710 instead.
13711 (mark_lwp_dead): Remove reference to pending_is_breakpoint.
13712 (cancel_finished_single_step): New.
13713 (cancel_finished_single_steps): New.
13714 (wait_for_sigstop): Don't cancel finished single-step traps here.
13715 (linux_resume_one_lwp): Don't check for removed breakpoints.
13716 Don't set `step' on non-hardware step archs.
13717 (linux_set_resume_request): Ignore resume_stop requests if already
13718 stopping or stopped. Set the lwp's last_resume_kind.
13719 (resume_status_pending_p): Don't check for removed breakpoints.
13720 (need_step_over_p): New.
13721 (start_step_over): New.
13722 (finish_step_over): New.
13723 (linux_resume_one_thread): Always queue a sigstop for resume_stop
13724 requests. Clear the thread's last reported target waitstatus.
13725 Don't use the `suspended' flag. Don't consider pending breakpoints.
13726 (linux_resume): Start a step-over if necessary.
13727 (proceed_one_lwp): New.
13728 (proceed_all_lwps): New.
13729 (unstop_all_lwps): New.
13730 * linux-low.h (struct lwp_info): Rewrite comment for the
13731 `suspended' flag. Add the `stop_pc' field. Delete the
13732 `pending_stop_pc' field. Tweak the `stepping' flag's comment.
13733 Add `'last_resume_kind' and `need_step_over' fields.
13734 * inferiors.c (struct thread_info): Delete, moved elsewhere.
13735 * mem-break.c (struct breakpoint): Delete `reinserting' flag.
13736 Delete `breakpoint_to_reinsert' field. New flag `inserted'.
13737 (set_raw_breakpoint_at): New.
13738 (set_breakpoint_at): Rewrite to use it.
13739 (reinsert_breakpoint_handler): Delete.
13740 (set_reinsert_breakpoint): New.
13741 (reinsert_breakpoint_by_bp): Delete.
13742 (delete_reinsert_breakpoints): New.
13743 (uninsert_breakpoint): Rewrite.
13744 (uninsert_breakpoints_at): New.
13745 (reinsert_breakpoint): Rewrite.
13746 (reinsert_breakpoints_at): New.
13747 (check_breakpoints): Rewrite.
13748 (breakpoint_here): New.
13749 (breakpoint_inserted_here): New.
13750 (check_mem_read): Adjust.
13751 * mem-break.h (breakpoints_supported, breakpoint_here)
13752 (breakpoint_inserted_here, set_reinsert_breakpoint): Declare.
13753 (reinsert_breakpoint_by_bp): Delete declaration.
13754 (delete_reinsert_breakpoints): Declare.
13755 (reinsert_breakpoint): Delete declaration.
13756 (reinsert_breakpoints_at): Declare.
13757 (uninsert_breakpoint): Delete declaration.
13758 (uninsert_breakpoints_at): Declare.
13759 (check_breakpoints): Adjust prototype.
13760 * server.h: Adjust include order.
13761 (struct thread_info): Declare here. Add a `last_status' field.
13762
13763 2010-03-23 Michael Snyder <msnyder@vmware.com>
13764
13765 * server.c (crc32): New function.
13766 (handle_query): Add handling for 'qCRC:' request.
13767
13768 2010-03-23 Pedro Alves <pedro@codesourcery.com>
13769
13770 * linux-x86-low.c (x86_linux_prepare_to_resume): Clear DR6 if the
13771 lwp had been stopped by a watchpoint.
13772
13773 2010-03-16 Pedro Alves <pedro@codesourcery.com>
13774
13775 * server.h (internal_error): Declare.
13776 (gdb_assert, ASSERT_FUNCTION, gdb_assert_fail): Define.
13777 * utils.c (internal_error): New function.
13778
13779 2010-03-15 Andreas Schwab <schwab@redhat.com>
13780
13781 * configure.srv: Fix typo setting srv_regobj.
13782
13783 2010-03-15 Pedro Alves <pedro@codesourcery.com>
13784
13785 * linux-low.c (fetch_register): Avoid passing a non string literal
13786 format to `error'.
13787 (usr_store_inferior_registers): Ditto.
13788
13789 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13790
13791 * linux-low.c (linux_write_memory): Bail out early if peeking
13792 memory failed.
13793
13794 2010-03-14 Pedro Alves <pedro@codesourcery.com>
13795
13796 * linux-low.h (struct lwp_info): New fields
13797 `stopped_by_watchpoint' and `stopped_data_address'.
13798 * linux-low.c (linux_wait_for_lwp): Check for watchpoint triggers
13799 here, and cache them in the lwp object.
13800 (wait_for_sigstop): Check stopped_by_watchpoint lwp field
13801 directly.
13802 (linux_resume_one_lwp): Clear the lwp's stopped_by_watchpoint
13803 field.
13804 (linux_stopped_by_watchpoint): Rewrite.
13805 (linux_stopped_data_address): Rewrite.
13806
13807 2010-03-06 Simo Melenius <simo.melenius@iki.fi>
13808
13809 * linux-low.c (linux_wait_for_lwp): Fetch the regcache after
13810 switching the current inferior, not before.
13811
13812 2010-03-01 H.J. Lu <hongjiu.lu@intel.com>
13813
13814 * Makefile.in (clean): Replace reg-i386.c, reg-x86-64.c,
13815 reg-i386-linux.c and reg-x86-64-linux.c with i386.c, amd64.c,
13816 i386-linux.c and amd64-linux.c.
13817 (reg-i386.o): Removed.
13818 (reg-i386.c): Likewise.
13819 (reg-i386-linux.o): Likewise.
13820 (reg-i386-linux.c): Likewise.
13821 (reg-x86-64.o): Likewise.
13822 (reg-x86-64.c): Likewise.
13823 (reg-x86-64-linux.o): Likewise.
13824 (reg-x86-64-linux.c): Likewise.
13825 (i386.o): New.
13826 (i386.c): Likewise.
13827 (i386-linux.o): Likewise.
13828 (i386-linux.c): Likewise.
13829 (amd64.o): Likewise.
13830 (amd64.c): Likewise.
13831 (amd64-linux.o): Likewise.
13832 (amd64-linux.c): Likewise.
13833
13834 * configure.srv (srv_i386_regobj): New.
13835 (srv_i386_linux_regobj): Likewise.
13836 (srv_amd64_regobj): Likewise.
13837 (srv_amd64_linux_regobj): Likewise.
13838 (srv_i386_32bit_xmlfiles): Likewise.
13839 (srv_i386_64bit_xmlfiles): Likewise.
13840 (srv_i386_xmlfiles): Likewise.
13841 (srv_amd64_xmlfiles): Likewise.
13842 (srv_i386_linux_xmlfiles): Likewise.
13843 (srv_amd64_linux_xmlfiles): Likewise.
13844 (i[34567]86-*-cygwin*): Set srv_regobj to $srv_i386_regobj. Set
13845 srv_xmlfiles to $srv_i386_xmlfiles.
13846 (i[34567]86-*-mingw32ce*): Likewise.
13847 (i[34567]86-*-mingw*): Likewise.
13848 (i[34567]86-*-nto*): Likewise.
13849 (i[34567]86-*-linux*): Set srv_regobj to $srv_i386_linux_regobj
13850 and $srv_amd64_linux_regobj. Set srv_xmlfiles to
13851 $srv_i386_linux_xmlfiles and $srv_amd64_linux_xmlfiles.
13852 (x86_64-*-linux*): Likewise.
13853
13854 * linux-x86-low.c (init_registers_x86_64_linux): Removed.
13855 (init_registers_amd64_linux): New.
13856 (x86_arch_setup): Replace init_registers_x86_64_linux with
13857 init_registers_amd64_linux.
13858
13859 2010-02-23 Maxim Kuvyrkov <maxim@codesourcery.com>
13860
13861 * configure.ac: Check for libdl. If it is not available link against
13862 static libthread_db.
13863 * configure: Regenerate.
13864
13865 2010-02-22 Pedro Alves <pedro@codesourcery.com>
13866
13867 PR9605
13868
13869 * i386-low.c (i386_length_and_rw_bits): Throw a fatal error if
13870 handing a read watchpoint.
13871 (i386_low_insert_watchpoint): Read watchpoints aren't supported.
13872
13873 2010-02-12 Doug Evans <dje@google.com>
13874
13875 * linux-low.c (linux_supports_tracefork_flag): Document.
13876 (linux_look_up_symbols): Add comment.
13877
13878 2010-02-03 H.J. Lu <hongjiu.lu@intel.com>
13879
13880 * regcache.c (supply_register): Clear regcache if buf is NULL.
13881
13882 2010-02-02 Nicolas Roche <roche@sourceware.org>
13883 Joel Brobecker <brobecker@adacore.com>
13884
13885 * inferiors.c (find_inferior): Add function documentation.
13886 (unloaded_dll): Handle the case where the unloaded dll has not
13887 been previously registered in the dll list.
13888
13889 2010-02-01 Daniel Jacobowitz <dan@codesourcery.com>
13890
13891 * linux-arm-low.c (thumb_breakpoint_len): Delete.
13892 (thumb2_breakpoint): New.
13893 (arm_breakpoint_at): Check for Thumb-2 breakpoints.
13894
13895 2010-01-29 Daniel Jacobowitz <dan@codesourcery.com>
13896
13897 * linux-low.c (get_stop_pc): Check for SIGTRAP.
13898 (linux_wait_for_event_1): Handle SIGILL and SIGSEGV as possible
13899 breakpoints.
13900
13901 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13902
13903 * linux-ppc-low.c (ppc_arch_setup): Adjust to regcache changes.
13904
13905 2010-01-21 Jan Kratochvil <jan.kratochvil@redhat.com>
13906
13907 * linux-s390-low.c (s390_collect_ptrace_register)
13908 (s390_supply_ptrace_register): Adjust it for the new regcache parameter.
13909
13910 2010-01-21 Doug Evans <dje@google.com>
13911
13912 * linux-low.c (PTRACE_ARG3_TYPE): Change from long to void*.
13913 (PTRACE_ARG4_TYPE): New macro.
13914 (handle_extended_wait): Cast ptrace arg4 to PTRACE_ARG4_TYPE.
13915 (linux_wait_for_event_1, linux_resume_one_lwp): Ditto.
13916 (fetch_register): Cast to uintptr_t before casting to PTRACE_ARG3_TYPE.
13917 (usr_store_inferior_registers): Ditto.
13918 (linux_read_memory, linux_write_memory): Ditto.
13919 (linux_test_for_tracefork): Ditto.
13920
13921 * linux-arm-low.c: Remove redundant include of gdb_proc_service.h.
13922 Only include elf.h if gdb_proc_service.h didn't include linux/elf.h.
13923
13924 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13925
13926 * proc-service.c (ps_lgetregs): Don't refetch registers from the
13927 target.
13928
13929 2010-01-21 Pedro Alves <pedro@codesourcery.com>
13930
13931 * spu-low.c (spu_fetch_registers, spu_store_registers): Change
13932 prototype to take a regcache. Adjust.
13933
13934 2010-01-20 Pedro Alves <pedro@codesourcery.com>
13935
13936 * regcache.h (struct thread_info): Forward declare.
13937 (struct regcache): New.
13938 (new_register_cache): Adjust prototype.
13939 (get_thread_regcache): Declare.
13940 (free_register_cache): Adjust prototype.
13941 (registers_to_string, registers_from_string): Ditto.
13942 (supply_register, supply_register_by_name, collect_register)
13943 (collect_register_as_string, collect_register_by_name): Ditto.
13944 * regcache.c (struct inferior_regcache_data): Delete.
13945 (get_regcache): Rename to ...
13946 (get_thread_regcache): ... this. Adjust. Switch inferior before
13947 fetching registers.
13948 (regcache_invalidate_one): Adjust.
13949 (regcache_invalidate): Fix prototype.
13950 (new_register_cache): Return the new register cache.
13951 (free_register_cache): Change prototype.
13952 (realloc_register_cache): Adjust.
13953 (registers_to_string): Change prototype to take a regcache. Adjust.
13954 (registers_from_string): Ditto.
13955 (register_data): Ditto.
13956 (supply_register): Ditto.
13957 (supply_register_by_name): Ditto.
13958 (collect_register): Ditto.
13959 (collect_register_as_string): Ditto.
13960 (collect_register_by_name): Ditto.
13961 * server.c (process_serial_event): Adjust.
13962 * linux-low.h (regset_fill_func, regset_store_func): Change
13963 prototype.
13964 (get_pc, set_pc, collect_ptrace_register, supply_ptrace_register):
13965 Change prototype.
13966 * linux-low.c (get_stop_pc): Adjust.
13967 (check_removed_breakpoint): Adjust.
13968 (linux_wait_for_event): Adjust.
13969 (linux_resume_one_lwp): Adjust.
13970 (fetch_register): Add regcache parameter. Adjust.
13971 (usr_store_inferior_registers): Ditto.
13972 (regsets_fetch_inferior_registers): Ditto.
13973 (regsets_store_inferior_registers): Ditto.
13974 (linux_fetch_registers, linux_store_registers): Ditto.
13975 * i387-fp.c (i387_cache_to_fsave): Change prototype to take a
13976 regcache. Adjust.
13977 (i387_fsave_to_cache, i387_cache_to_fxsave, i387_fxsave_to_cache):
13978 Ditto.
13979 * i387-fp.h (i387_cache_to_fsave, i387_fsave_to_cache): Change
13980 prototype to take a regcache.
13981 (i387_cache_to_fxsave, i387_fxsave_to_cache): Ditto.
13982 * remote-utils.c (convert_ascii_to_int, outreg)
13983 (prepare_resume_reply): Change prototype to take a regcache.
13984 Adjust.
13985 * target.h (struct target_ops) <fetch_registers, store_registers>:
13986 Change prototype to take a regcache.
13987 (fetch_inferior_registers, store_inferior_registers): Change
13988 prototype to take a regcache. Adjust.
13989 * proc-service.c (ps_lgetregs): Adjust.
13990 * linux-x86-low.c (x86_fill_gregset, x86_store_gregset)
13991 (x86_fill_fpregset, x86_store_fpregset, x86_fill_fpxregset)
13992 (x86_store_fpxregset, x86_get_pc, x86_set_pc): Change prototype to
13993 take a regcache. Adjust.
13994 * linux-arm-low.c (arm_fill_gregset, arm_store_gregset)
13995 (arm_fill_wmmxregset, arm_store_wmmxregset, arm_fill_vfpregset)
13996 (arm_store_vfpregset, arm_get_pc, arm_set_pc):
13997 (arm_breakpoint_at): Change prototype to take a regcache. Adjust.
13998 * linux-cris-low.c (cris_get_pc, cris_set_pc)
13999 (cris_cannot_fetch_register):
14000 (cris_breakpoint_at): Change prototype to take a regcache.
14001 Adjust.
14002 * linux-crisv32-low.c (cris_get_pc, cris_set_pc,
14003 cris_reinsert_addr, cris_write_data_breakpoint): Change prototype
14004 to take a regcache. Adjust.
14005 (cris_breakpoint_at, cris_insert_point, cris_remove_point):
14006 Adjust.
14007 * linux-m32r-low.c (m32r_get_pc, m32r_set_pc): Change prototype to
14008 take a regcache. Adjust.
14009 * linux-m68k-low.c (m68k_fill_gregset, m68k_store_gregset)
14010 (m68k_fill_fpregset, m68k_store_fpregset, m68k_get_pc,
14011 (m68k_set_pc): Change prototype to take a regcache. Adjust.
14012 * linux-mips-low.c (mips_get_pc):
14013 (mips_set_pc): Change prototype to take a regcache. Adjust.
14014 (mips_reinsert_addr): Adjust.
14015 (mips_collect_register): Change prototype to take a regcache.
14016 Adjust.
14017 (mips_supply_register):
14018 (mips_collect_register_32bit, mips_supply_register_32bit)
14019 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
14020 (mips_store_fpregset): Ditto.
14021 * linux-ppc-low.c (ppc_supply_ptrace_register)
14022 (ppc_supply_ptrace_register): Ditto.
14023 (parse_spufs_run): Adjust.
14024 (ppc_get_pc, ppc_set_pc, ppc_fill_gregset, ppc_fill_vsxregset)
14025 (ppc_store_vsxregset, ppc_fill_vrregset, ppc_store_vrregset)
14026 (ppc_fill_evrregset, ppc_store_evrregset): Change prototype to
14027 take a regcache. Adjust.
14028 * linux-s390-low.c (s390_collect_ptrace_register)
14029 (s390_supply_ptrace_register, s390_fill_gregset, s390_get_pc)
14030 (s390_set_pc): Change prototype to take a regcache. Adjust.
14031 (s390_arch_setup): Adjust.
14032 * linux-sh-low.c (sh_get_pc, sh_breakpoint_at)
14033 (sh_fill_gregset): Change prototype to take a regcache. Adjust.
14034 * linux-sparc-low.c (sparc_fill_gregset_to_stack)
14035 (sparc_fill_gregset, sparc_store_gregset_from_stack)
14036 (sparc_store_gregset, sparc_get_pc): Change prototype to take a
14037 regcache. Adjust.
14038 (sparc_breakpoint_at): Adjust.
14039 * linux-xtensa-low.c (xtensa_fill_gregset):
14040 (xtensa_store_gregset):
14041 (xtensa_fill_xtregset, xtensa_store_xtregset, xtensa_get_pc)
14042 (xtensa_set_pc): Change prototype to take a regcache. Adjust.
14043 * nto-low.c (nto_fetch_registers, nto_store_registers): Change
14044 prototype to take a regcache. Adjust.
14045 * win32-arm-low.c (arm_fetch_inferior_register)
14046 (arm_store_inferior_register): Change prototype to take a
14047 regcache. Adjust.
14048 * win32-i386-low.c (i386_fetch_inferior_register)
14049 (i386_store_inferior_register): Change prototype to take a
14050 regcache. Adjust.
14051 * win32-low.c (child_fetch_inferior_registers)
14052 (child_store_inferior_registers): Change prototype to take a
14053 regcache. Adjust.
14054 (win32_wait): Adjust.
14055 (win32_fetch_inferior_registers): Change prototype to take a
14056 regcache. Adjust.
14057 (win32_store_inferior_registers): Adjust.
14058 * win32-low.h (struct win32_target_ops) <fetch_inferior_register,
14059 store_inferior_register>: Change prototype to take a regcache.
14060
14061 2010-01-20 Doug Evans <dje@google.com>
14062
14063 * linux-low.c (linux_create_inferior): Wrap use of __SIGRTMIN in
14064 #ifdef.
14065 (linux_wait_for_event1, linux_init_signals): Ditto.
14066 (W_STOPCODE): Provide definition if missing.
14067
14068 2010-01-13 Vladimir Prus <vladimir@codesourcery.com>
14069
14070 * linux-low.c (linux_core_of_thread): New.
14071 (compare_ints, show_process, list_threads): New.
14072 (linux_qxfer_osdata): Report threads and cores.
14073 (linux_target_op): Register linux_core_of_thread.
14074 * remote-utils.c (prepare_resume_reply): Report the core.
14075 (buffer_xml_printf): Support %d specifier.
14076 * server.c (handle_threads_qxfer_proper, handle_threads_qxfer):
14077 New.
14078 (handle_query): Handle qXfer:threads. Announce availability
14079 thereof.
14080 * target.h (struct target_ops): New field core_of_thread.
14081
14082 2010-01-04 Ulrich Weigand <uweigand@de.ibm.com>
14083
14084 * Makefile.in (clean): Remove new generated files.
14085 (reg-s390.o, reg-s390.c): Remove rules.
14086 (reg-s390x.o, reg-s390x.c): Likewise.
14087 (s390-linux32.o, s390-linux32.c): Add rules.
14088 (s390-linux64.o, s390-linux64.c): Likewise.
14089 (s390x-linux64.o, s390x-linux64.c): Likewise.
14090 * configure.srv (s390*-*-linux*): Update srv_regobj and srv_xmlfiles.
14091 * linux-s390-low.c: Include <elf.h>.
14092 (HWCAP_S390_HIGH_GPRS): Define if undefined.
14093 (init_registers_s390): Remove prototype.
14094 (init_registers_s390x): Likewise.
14095 (init_registers_s390_linux32): Add prototype.
14096 (init_registers_s390_linux64): Likewise.
14097 (init_registers_s390x_linux64): Likewise.
14098 (s390_num_regs_3264): New define.
14099 (s390_regmap_3264): New global variable.
14100 (s390_cannot_fetch_register): Remove obsolete check.
14101 (s390_cannot_store_register): Likewise.
14102 (s390_collect_ptrace_register): Handle upper/lower register halves.
14103 (s390_supply_ptrace_register): Likewise.
14104 (s390_fill_gregset): Update to register number changes.
14105 (s390_get_hwcap): New routine.
14106 (s390_arch_setup): Detect 32-bit process running on 64-bit system.
14107 Install appropriate regmap and register set.
14108
14109 2010-01-01 Joel Brobecker <brobecker@adacore.com>
14110
14111 * server.c (gdbserver_version): Update copyright year to 2010.
14112 * gdbreplay.c (gdbreplay_version): Likewise.
14113
14114 2009-12-28 Doug Evans <dje@google.com>
14115
14116 * linux-low.c: Delete inclusion of ansidecl.h, elf/common.h,
14117 elf/external.h. Include <elf.h> instead but only if necessary.
14118
14119 2009-12-28 Pedro Alves <pedro@codesourcery.com>
14120
14121 * linux-low.c (linux_remove_process): Remove `detaching'
14122 parameter. Don't release/detach from thread_db here.
14123 (linux_kill): Release/detach from thread_db here, ...
14124 (linux_detach): ... and here, before actually detaching.
14125 (linux_wait_1): ... and here, when a process exits.
14126 * thread-db.c (any_thread_of): New.
14127 (thread_db_free): Switch the current inferior to a thread of the
14128 passed in process.
14129
14130 2009-12-21 Doug Evans <dje@google.com>
14131
14132 * linux-x86-low.c: Delete outdated comment about Elf32_Phdr.
14133
14134 * linux-low.c (kill_lwp): Use __NR_tkill instead of SYS_tkill.
14135 Move definition of tkill_failed to ifdef __NR_tkill to avoid gcc
14136 warning ifndef __NR_tkill. Move setting of errno there too.
14137 Delete unnecessary resetting of errno after syscall.
14138 Minor comment changes to match gdb/linux-nat.c:kill_lwp.
14139
14140 * configure.ac: Check for dladdr.
14141 * config.in: Regenerate.
14142 * configure: Regenerate.
14143 * thread-db.c (dladdr_to_soname): Only define ifdef HAVE_DLADDR.
14144 (try_thread_db_load): Update.
14145
14146 * linux-low.c (my_waitpid): Delete unnecessary prototype.
14147
14148 2009-12-18 Doug Evans <dje@google.com>
14149
14150 * event-loop.c: Include unistd.h if it exists.
14151
14152 * linux-low.c (my_waitpid): Move definition away from being in
14153 between linux_tracefork_child/linux_test_for_tracefork.
14154
14155 * gdb_proc_service.h (psaddr_t): Fix type.
14156 * thread-db.c (thread_db_info.td_thr_tls_get_addr_p): Fix
14157 signature to match glibc.
14158
14159 2009-12-16 Doug Evans <dje@google.com>
14160
14161 * linux-low.c (linux_read_memory): Fix argument to read.
14162
14163 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14164
14165 * win32-low.c (get_child_debug_event): On EXIT_THREAD_DEBUG_EVENT
14166 events, don't leave current_inferior pointing at null.
14167
14168 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14169
14170 * win32-low.c (LOG): Delete.
14171 (OUTMSG): Output to stderr.
14172 (OUTMSG2): Conditionalize on `debug_threads' variable, instead of
14173 on compile time LOG macro.
14174 (win32_wait): Fix debug output.
14175
14176 2009-11-26 Pedro Alves <pedro@codesourcery.com>
14177
14178 * win32-low.c (win32_add_one_solib): If the dll name is
14179 "ntdll.dll", prepend the system directory to the dll path.
14180
14181 2009-11-17 Daniel Jacobowitz <dan@codesourcery.com>
14182
14183 * m68k-tdep.c (m68k_gdbarch_init): Reuse previous initialization.
14184
14185 2009-11-17 Nathan Sidwell <nathan@codesourcery.com>
14186 Vladimir Prus <vladimir@codesourcery.com>
14187
14188 * Makefile.in (reg-cf.o, reg-cf.c): New targets.
14189 * configure.ac: Check for __mcoldfire__ and set
14190 gdb_cv_m68k_is_coldfire.
14191 * configure.srv: Use gdb_cv_m68k_is_coldfire to select between
14192 reg-cf.o and reg-m68k.o.
14193 * configure: Regenerated.
14194
14195 2009-11-16 Pedro Alves <pedro@codesourcery.com>
14196
14197 * linux-low.c (linux_remove_process): Add `detaching' parameter.
14198 Pass it to thread_db_free.
14199 (linux_kill, linux_detach, linux_wait_1): Adjust to pass the
14200 proper `detaching' argument to linux_remove_process.
14201 * linux-low.h (thread_db_free): Add `detaching' parameter.
14202 * thread-db.c (thread_db_init): Pass false as `detaching' argument
14203 to thread_db_free.
14204 (thread_db_free): Add `detaching' parameter. Only
14205 call td_ta_clear_event if detaching from process.
14206
14207 2009-11-12 Maxim Kuvyrkov <maxim@codesourcery.com>
14208
14209 * thread-db.c (thread_db_free): Fix typo.
14210
14211 2009-11-11 Paul Pluzhnikov <ppluzhnikov@google.com>
14212
14213 PR gdb/10838
14214 * thread-db.c (thread_db_free): Call td_ta_clear_event.
14215
14216 2009-11-03 Nathan Sidwell <nathan@codesourcery.com>
14217
14218 * configure.ac (i[34567]86-*): Check if we're targetting x86-64
14219 with an i686 compiler.
14220 * configure.srv (i[34567]86-*-linux*): Pull in x86-64 handling if
14221 needed.
14222 * configure: Rebuilt.
14223
14224 2009-10-29 Sandra Loosemore <sandra@codesourcery.com>
14225
14226 PR gdb/10783
14227
14228 * server.c (handle_search_memory_1): Correct read_addr initialization
14229 in loop for searching subsequent chunks.
14230
14231 2009-10-29 Paul Pluzhnikov <ppluzhnikov@google.com>
14232
14233 * configure.ac: New --with-libthread-db option.
14234 * thread-db.c: Allow direct dependence on libthread_db.
14235 (thread_db_free): Adjust.
14236 * config.in: Regenerate.
14237 * configure: Likewise.
14238
14239 2009-10-28 Paul Pluzhnikov <ppluzhnikov@google.com>
14240
14241 PR gdb/10757
14242 * thread-db.c (attach_thread): New function.
14243 (maybe_attach_thread): Return success/failure.
14244 (find_new_threads_callback): Adjust.
14245 (thread_db_find_new_threads): Loop until no new threads.
14246
14247 2009-10-13 Pedro Alves <pedro@codesourcery.com>
14248
14249 * proc-service.c (ps_lgetregs): Formatting.
14250
14251 2009-10-08 Paul Pluzhnikov <ppluzhnikov@google.com>
14252
14253 * acinclude.m4: (SRV_CHECK_THREAD_DB, SRV_CHECK_TLS_GET_ADDR): Remove.
14254 * configure.ac: Adjust.
14255 * linux-low.h (struct process_info_private): Move members to struct
14256 thread_db.
14257 (thread_db_free, thread_db_handle_monitor_command): New prototype.
14258 * linux-low.c (linux_remove_process): Adjust.
14259 (linux_wait_for_event_1, linux_look_up_symbols): Likewise.
14260 * server.c (handle_query): Move code ...
14261 (handle_monitor_command): ... here. New function.
14262 * target.h (struct target_ops): New member.
14263 * thread-db.c (struct thread_db): New.
14264 (libthread_db_search_path): New variable.
14265 (thread_db_create_event, thread_db_enable_reporting)
14266 (find_one_thread, maybe_attach_thread, find_new_threads_callback)
14267 (thread_db_find_new_threads, (thread_db_get_tls_address): Adjust.
14268 (try_thread_db_load_1, dladdr_to_soname): New functions.
14269 (try_thread_db_load, thread_db_load_search): New functions.
14270 (thread_db_init): Search for libthread_db.
14271 (thread_db_free): New function.
14272 (thread_db_handle_monitor_command): Likewise.
14273 * config.in: Regenerate.
14274 * configure: Regenerate.
14275
14276 2009-09-27 Ulrich Weigand <uweigand@de.ibm.com>
14277
14278 * spu-low.c (spu_kill): Wait for inferior to terminate.
14279 Call clear_inferiors.
14280 (spu_detach): Call clear_inferiors.
14281
14282 2009-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14283
14284 * aclocal.m4: Regenerate.
14285 * config.in: Likewise.
14286 * configure: Likewise.
14287
14288 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14289
14290 * linux-ppc-low.c (INSTR_SC, NR_spu_run): Define.
14291 (parse_spufs_run): New function.
14292 (ppc_get_pc, ppc_set_pc): Detect and handle SPU PC.
14293 (ppc_breakpoint_at): Handle SPU breakpoints.
14294
14295 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14296
14297 * linux-low.c: Include <sys/stat.h> and <sys/vfs.h>.
14298 (SPUFS_MAGIC): Define.
14299 (spu_enumerate_spu_ids): New function.
14300 (linux_qxfer_spu): New function.
14301 (linux_target_ops): Install linux_qxfer_spu.
14302
14303 2009-07-31 Ulrich Weigand <uweigand@de.ibm.com>
14304
14305 * configure.srv (powerpc*-*-linux*): Add powerpc-cell32l.o
14306 and powerpc-cell64l.o to srv_regobj. Add rs6000/powerpc-cell32l.xml
14307 and rs6000/powerpc-cell64l.xml to srv_xmlfiles.
14308 * Makefile.in (powerpc-cell32l.o, powerpc-cell32l.c): New rules.
14309 (powerpc-cell64l.o, powerpc-cell64l.c): Likewise.
14310 (clean): Handle powerpc-cell32l.c and powerpc-cell64l.c.
14311 * linux-ppc-low.c (PPC_FEATURE_CELL): Define.
14312 (init_registers_powerpc_cell32l): Add prototype.
14313 (init_registers_powerpc_cell64l): Likewise.
14314 (ppc_arch_setup): Detect Cell/B.E. architecture.
14315
14316 2009-07-30 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
14317
14318 * Makefile.in (datarootdir): New variable.
14319
14320 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14321
14322 * linux-low.c (linux_write_memory): Update debugging output.
14323 * Makefile.in (clean): Add new descriptions.
14324 (arm-with-vfpv2.o, arm-with-vfpv2.c, arm-with-vfpv3.o)
14325 (arm-with-vfpv3.c, arm-with-neon.o, arm-with-neon.c): New rules.
14326 * configure.srv: Add new files for arm*-*-linux*.
14327 * linux-arm-low.c: Add new declarations.
14328 (PTRACE_GETVFPREGS, PTRACE_SETVFPREGS): Define if undefined.
14329 (arm_hwcap, HWCAP_VFP, HWCAP_IWMMXT, HWCAP_NEON, HWCAP_VFPv3)
14330 (HWCAP_VFPv3D16): New.
14331 (arm_fill_wmmxregset, arm_store_wmmxregset): Check HWCAP_IWMMXT
14332 instead of __IWMMXT__.
14333 (arm_fill_vfpregset, arm_store_vfpregset, arm_get_hwcap)
14334 (arm_arch_setup): New.
14335 (target_regsets): Remove #ifdef. Add VFP regset.
14336 (the_low_target): Use arm_arch_setup.
14337
14338 2009-07-28 Daniel Jacobowitz <dan@codesourcery.com>
14339
14340 * linux-low.c (linux_kill_one_lwp): Adjust kernel workaround to skip
14341 the main thread again.
14342
14343 2009-07-06 Aleksandar Ristovski <aristovski@qnx.com>
14344
14345 Adding Neutrino gdbserver.
14346 * configure: Regenerated.
14347 * configure.ac: Add case for srv_qnx and set LIBS accordingly.
14348 * configure.srv (i[34567]86-*-nto*): New target.
14349 * nto-low.c, nto-low.h, nto-x86-low.c: New files.
14350 * remote-utils.c [__QNX__]: Include sys/iomgr.h
14351 (nto_comctrl) [__QNX__]: New function.
14352 (enable_async_io, disable_async_io) [__QNX__]: Call nto_comctrl.
14353
14354 2009-07-05 Danny Backx <dannybackx@users.sourceforge.net>
14355
14356 * configure.srv (i[34567]86-*-mingw32ce*): Add i386-low.o to
14357 srv_tgtobj.
14358
14359 2009-07-04 Danny Backx <dannybackx@users.sourceforge.net>
14360 Pedro Alves <pedro@codesourcery.com>
14361
14362 * win32-i386-low.c (i386_get_thread_context): Handle systems that
14363 don't support CONTEXT_EXTENDED_REGISTERS.
14364 (i386_win32_breakpoint, i386_win32_breakpoint_len): New.
14365 (the_low_target): Install them.
14366 * win32-low.c (get_child_debug_event): Handle WaitForDebugEvent
14367 failing with ERROR_PIPE_NOT_CONNECTED.
14368
14369 2009-06-30 Doug Evans <dje@google.com>
14370 Pierre Muller <muller@ics.u-strasbg.fr>
14371
14372 Add h/w watchpoint support to x86-linux, win32-i386.
14373 * Makefile.in (SFILES): Add i386-low.c
14374 (i386_low_h): Define.
14375 (i386-low.o): Add dependencies.
14376 (linux-x86-low.o): Add i386-low.h dependency.
14377 (win32-i386-low.o): Ditto.
14378 * i386-low.c: New file.
14379 * i386-low.h: New file.
14380 * configure.srv (i[34567]86-*-cygwin*): Add i386-low.o to srv_tgtobj.
14381 (i[34567]86-*-linux*, i[34567]86-*-mingw*, x86_64-*-linux*): Ditto.
14382 * linux-low.c (linux_add_process): Initialize arch_private.
14383 (linux_remove_process): Free arch_private.
14384 (add_lwp): Initialize arch_private.
14385 (delete_lwp): Free arch_private.
14386 (linux_resume_one_lwp): Call the_low_target.prepare_to_resume if
14387 provided.
14388 * linux-low.h (process_info_private): New member arch_private.
14389 (lwp_info): New member arch_private.
14390 (linux_target_ops): New members new_process, new_thread,
14391 prepare_to_resume.
14392 (ptid_of): New macro.
14393 * linux-x86-low.c: Include stddef.h, i386-low.h.
14394 (arch_process_info): New struct.
14395 (arch_lwp_info): New struct.
14396 (x86_linux_dr_get, x86_linux_dr_set): New functions.
14397 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14398 (i386_dr_low_get_status): New function.
14399 (x86_insert_point, x86_remove_point): New functions.
14400 (x86_stopped_by_watchpoint): New function.
14401 (x86_stopped_data_address): New function.
14402 (x86_linux_new_process, x86_linux_new_thread): New functions.
14403 (x86_linux_prepare_to_resume): New function.
14404 (the_low_target): Add entries for insert_point, remove_point,
14405 stopped_by_watchpoint, stopped_data_address, new_process, new_thread,
14406 prepare_to_resume.
14407 * server.c (debug_hw_points): New global.
14408 (monitor_show_help): Document set debug-hw-points.
14409 (handle_query): Process "set debug-hw-points".
14410 * server.h (debug_hw_points): Declare.
14411 (paddress): Declare.
14412 * utils.c (NUMCELLS, CELLSIZE): New macros.
14413 (get_sell, xsnprintf, paddress): New functions.
14414 * win32-arm-low.c (the_low_target): Add entries for insert_point,
14415 remove_point, stopped_by_watchpoint, stopped_data_address.
14416 * win32-i386-low.c: Include i386-low.h.
14417 (debug_reg_state): Replaces dr.
14418 (i386_dr_low_set_addr, i386_dr_low_set_control): New functions.
14419 (i386_dr_low_get_status): New function.
14420 (i386_insert_point, i386_remove_point): New functions.
14421 (i386_stopped_by_watchpoint): New function.
14422 (i386_stopped_data_address): New function.
14423 (i386_initial_stuff): Update.
14424 (get_thread_context,set_thread_context,i386_thread_added): Update.
14425 (the_low_target): Add entries for insert_point,
14426 remove_point, stopped_by_watchpoint, stopped_data_address.
14427 * win32-low.c (win32_insert_watchpoint): New function.
14428 (win32_remove_watchpoint): New function.
14429 (win32_stopped_by_watchpoint): New function.
14430 (win32_stopped_data_address): New function.
14431 (win32_target_ops): Add entries for insert_watchpoint,
14432 remove_watchpoint, stopped_by_watchpoint, stopped_data_address.
14433 * win32-low.h (win32_target_ops): New members insert_point,
14434 remove_point, stopped_by_watchpoint, stopped_data_address.
14435
14436 2009-06-25 Pedro Alves <pedro@codesourcery.com>
14437
14438 * server.c (process_serial_event): Re-return unsupported, not
14439 error, if the type isn't recognized. Re-allow supporting only
14440 insert or remove packets. Also call require_running for
14441 breakpoints. Add missing break statement to default case. Tidy.
14442 * target.h (struct target_ops): Rename insert_watchpoint to
14443 insert_point, and remove_watchpoint to remove_point.
14444
14445 * linux-low.h (struct linux_target_ops): Likewise.
14446 * linux-low.c (linux_insert_watchpoint): Rename to ...
14447 (linux_insert_point): ... this. Adjust.
14448 (linux_remove_watchpoint): Rename to ...
14449 (linux_remove_point): ... this. Adjust.
14450 (linux_target_ops): Adjust.
14451 * linux-crisv32-low.c (cris_insert_watchpoint): Rename to ...
14452 (cris_insert_point): ... this.
14453 (cris_remove_watchpoint): Rename to ...
14454 (cris_remove_point): ... this.
14455 (the_low_target): Adjust.
14456
14457 2009-06-24 Pierre Muller <muller@ics.u-strasbg.fr>
14458
14459 * server.c (handle_v_kill): Pass signal_pid to
14460 kill_inferior if multi_process is zero.
14461
14462 2009-06-23 Aleksandar Ristovski <aristovski@qnx.com>
14463
14464 * server.c (process_serial_event): Add support for Z0 and Z1 packet.
14465 * target.h (target_ops): Comment for *_watchpoint to make it clear
14466 the functions can get types '0' and '1'.
14467
14468 2009-06-22 Aleksandar Ristovski <aristovski@qnx.com>
14469
14470 * linux-low.c (usr_fetch_inferior_registers): Remove check for regno 0.
14471 * proc-service.c (ps_lgetregs): Pass -1 to fetch all registers.
14472 * regcache.c (get_regcache): Likewise.
14473 * spu-low.c (spu_fetch_registers): Remove 0 to -1 conversion.
14474 * win32-low.c (child_fetch_inferior_registers): Remove check for
14475 regno 0.
14476
14477 2009-06-19 Aleksandar Ristovski <aristovski@qnx.com>
14478 Pedro Alves <pedro@codesourcery.com>
14479
14480 * target.h (struct target_ops) <supports_multi_process>: New
14481 callback.
14482 (target_supports_multi_process): New.
14483 * server.c (handle_query): Even if GDB reports support, only
14484 enable multi-process if the target also supports it. Report
14485 multi-process support only if the target backend supports it.
14486 * linux-low.c (linux_supports_multi_process): New function.
14487 (linux_target_ops): Install it as target_supports_multi_process
14488 callback.
14489
14490 2009-05-24 Doug Evans <dje@google.com>
14491
14492 Global renaming of find_thread_pid to find_thread_ptid.
14493 * server.h (find_thread_ptid): Renamed from find_thread_pid.
14494 * inferiors.c (find_thread_ptid): Renamed from find_thread_pid.
14495 All callers updated.
14496
14497 * linux-low.c (handle_extended_wait): Use linux_resume_one_lwp
14498 to resume the newly created thread, don't call ptrace (PTRACE_CONT)
14499 directly.
14500
14501 * linux-low.c (get_stop_pc): Print pc if debug_threads.
14502 (check_removed_breakpoint, linux_wait_for_lwp): Ditto.
14503 (linux_resume_one_lwp): Ditto.
14504
14505 2009-05-23 Doug Evans <dje@google.com>
14506
14507 * linux-low.c (linux_resume_one_lwp): Change type of first arg
14508 from struct inferior_list_entry * to struct lwp_info *.
14509 All callers updated.
14510
14511 2009-05-13 Doug Evans <dje@google.com>
14512
14513 * linux-x86-low.c: Don't include assert.h.
14514 (x86_siginfo_fixup): Use fatal, not assert.
14515 (x86_arch_setup): Fix comment.
14516
14517 2009-05-12 Doug Evans <dje@google.com>
14518
14519 Biarch support for i386/amd64 gdbserver.
14520 * Makefile.in (SFILES): Remove linux-i386-low.c, linux-x86-64-low.c.
14521 Add linux-x86-low.c.
14522 (linux-i386-low.o, linux-x86-64-low.o): Delete.
14523 (linux-x86-low.o): Add.
14524 * linux-x86-64-low.c: Delete.
14525 * linux-i386-low.c: Delete.
14526 * linux-x86-low.c: New file.
14527 * configure.srv (i?86-linux srv_tgtobj): Replace linux-i386-low.o with
14528 linux-x86-low.o.
14529 (x86_64-linux srv_tgtobj): Replace linux-x86-64-low.o with
14530 linux-x86-low.o.
14531 (x86_64-linux srv_regobj): Add reg-i386-linux.o.
14532 * linux-low.c: Include ansidecl.h, elf/common.h, elf/external.h.
14533 (linux_child_pid_to_exec_file): New function.
14534 (elf_64_header_p, elf_64_file_p): New functions.
14535 (siginfo_fixup): New function.
14536 (linux_xfer_siginfo): New local inf_siginfo. Call siginfo_fixup to
14537 give target a chance to convert layout.
14538 * linux-low.h (linux_target_ops): New member siginfo_fixup.
14539 (linux_child_pid_to_exec_file, elf_64_file_p): Declare.
14540
14541 2009-05-07 Doug Evans <dje@google.com>
14542
14543 * linux-low.c (regsets_fetch_inferior_registers): Fix memory leak.
14544 (regsets_store_inferior_registers): Ditto.
14545
14546 2009-05-06 Pedro Alves <pedro@codesourcery.com>
14547
14548 PR server/10048
14549
14550 * linux-low.c (must_set_ptrace_flags): Delete.
14551 (linux_create_inferior): Set `lwp->must_set_ptrace_flags' instead
14552 of the global.
14553 (linux_attach_lwp_1): Don't set PTRACE_SETOPTIONS here. Set
14554 `lwp->must_set_ptrace_flags' instead.
14555 (linux_wait_for_event_1): Set ptrace options here.
14556 (linux_wait_1): ... not here.
14557
14558 2009-04-30 Doug Evans <dje@google.com>
14559
14560 * inferiors.c (started_inferior_callback): New function.
14561 (attached_inferior_callback): New function.
14562 (have_started_inferiors_p, have_attached_inferiors_p): New functions.
14563 * server.c (print_started_pid, print_attached_pid): New functions.
14564 (detach_or_kill_for_exit): New function.
14565 (main): Call it instead of for_each_inferior (kill_inferior_callback).
14566 * server.h (have_started_inferiors_p): Declare.
14567 (have_attached_inferiors_p): Declare.
14568
14569 * inferiors.c (remove_process): Fix memory leak, free process.
14570 * linux-low.c (linux_remove_process): New function.
14571 (linux_kill): Call it instead of remove_process.
14572 (linux_detach, linux_wait_1): Ditto.
14573
14574 2009-04-19 Danny Backx <dannybackx@users.sourceforge.net>
14575
14576 * configure.srv: Add x86 Windows CE target.
14577
14578 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14579
14580 * inferiors.c (get_thread_process): Make global.
14581 * server.h (get_thread_process): Add prototype.
14582 * thread-db.c (find_one_thread): Use get_thread_process
14583 instead of current_process.
14584 (thread_db_get_tls_address): Do not crash if called when
14585 thread layer is not yet initialized.
14586
14587 2009-04-03 Ulrich Weigand <uweigand@de.ibm.com>
14588
14589 * remote-utils.c (prepare_resume_reply): Null-terminate packet.
14590 * spu-low.c (current_tid): Rename to ...
14591 (current_ptid): ... this.
14592 (fetch_ppc_register, fetch_ppc_memory, store_ppc_memory,
14593 spu_proc_xfer_spu, spu_resume, spu_request_interrupt): Use
14594 ptid_get_lwp (current_ptid) instead of current_tid.
14595 (spu_kill, spu_detach, spu_join, spu_wait): Use pid argument
14596 instead of current_tid. Use find_process_pid to verify pid
14597 argument is valid. Pass proper argument to remove_process.
14598 (spu_thread_alive): Compare current_ptid instead of current_tid.
14599 (spu_resume): Likewise.
14600
14601 2009-04-02 Pedro Alves <pedro@codesourcery.com>
14602
14603 * linux-low.c (usr_store_inferior_registers): Declare local `pid'
14604 variable.
14605
14606 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14607
14608 Implement the multiprocess extensions, and add linux multiprocess
14609 support.
14610
14611 * server.h (ULONGEST): Declare.
14612 (struct ptid, ptid_t): New.
14613 (minus_one_ptid, null_ptid): Declare.
14614 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14615 (ptid_get_tid, ptid_equal, ptid_is_pid): Declare.
14616 (struct inferior_list_entry): Change `id' type from unsigned from
14617 to ptid_t.
14618 (struct sym_cache, struct breakpoint, struct
14619 process_info_private): Forward declare.
14620 (struct process_info): Declare.
14621 (current_process): Declare.
14622 (all_processes): Declare.
14623 (initialize_inferiors): Declare.
14624 (add_thread): Adjust to use ptid_t.
14625 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): Ditto.
14626 (add_process, remove_process, find_thread_pid): Declare.
14627 (find_inferior_id): Adjust to use ptid_t.
14628 (cont_thread, general_thread, step_thread): Change type to ptid_t.
14629 (multi_process): Declare.
14630 (push_event): Adjust to use ptid_t.
14631 (read_ptid, write_ptid): Declare.
14632 (prepare_resume_reply): Adjust to use ptid_t.
14633 (clear_symbol_cache): Declare.
14634 * inferiors.c (all_processes): New.
14635 (null_ptid, minus_one_ptid): New.
14636 (ptid_build, pid_to_ptid, ptid_get_pid, ptid_get_lwp)
14637 (ptid_get_tid, ptid_equal, ptid_is_pid): New.
14638 (add_thread): Change unsigned long to ptid. Remove gdb_id
14639 parameter. Adjust.
14640 (thread_id_to_gdb_id, thread_to_gdb_id): Change unsigned long to ptid.
14641 (gdb_id_to_thread): Rename to ...
14642 (find_thread_pid): ... this. Change unsigned long to ptid.
14643 (gdb_id_to_thread_id, find_inferior_id): Change unsigned long to ptid.
14644 (loaded_dll, pull_pid_from_list): Adjust.
14645 (add_process, remove_process, find_process_pid)
14646 (get_thread_process, current_process, initialize_inferiors): New.
14647 * target.h (struct thread_resume) <thread>: Change type to ptid_t.
14648 (struct target_waitstatus) <related_pid>: Ditto.
14649 (struct target_ops) <kill, detach>: Add `pid' argument. Change
14650 return type to int.
14651 (struct target_ops) <join>: Add `pid' argument.
14652 (struct target_ops) <thread_alive>: Change pid's type to ptid_t.
14653 (struct target_ops) <wait>: Add `ptid' field. Change return type
14654 to ptid.
14655 (kill_inferior, detach_inferior, join_inferior): Add `pid' argument.
14656 (mywait): Add `ptid' argument. Change return type to ptid_t.
14657 (target_pid_to_str): Declare.
14658 * target.c (set_desired_inferior): Adjust to use ptids.
14659 (mywait): Add new `ptid' argument. Adjust.
14660 (target_pid_to_str): New.
14661 * mem-break.h (free_all_breakpoints): Declare.
14662 * mem-break.c (breakpoints): Delelete.
14663 (set_breakpoint_at, delete_breakpoint, find_breakpoint_at)
14664 (check_mem_read, check_mem_write, delete_all_breakpoints): Adjust
14665 to use per-process breakpoint list.
14666 (free_all_breakpoints): New.
14667 * remote-utils.c (struct sym_cache) <name>: Drop `const'.
14668 (symbol_cache, all_symbols_looked_up): Delete.
14669 (hexchars): New.
14670 (ishex, unpack_varlen_hex, write_ptid, hex_or_minus_one,
14671 read_ptid): New.
14672 (prepare_resume_reply): Change ptid argument's type from unsigned
14673 long to ptid_t. Adjust. Implement W;process and X;process.
14674 (free_sym_cache, clear_symbol_cache): New.
14675 (look_up_one_symbol): Adjust to per-process symbol cache. *
14676 * server.c (cont_thread, general_thread, step_thread): Change type
14677 to ptid_t.
14678 (attached): Delete.
14679 (multi_process): New.
14680 (last_ptid): Change type to ptid_t.
14681 (struct vstop_notif) <ptid>: Change type to ptid_t.
14682 (queue_stop_reply, push_event): Change `ptid' argument's type to
14683 ptid_t.
14684 (discard_queued_stop_replies): Add `pid' argument.
14685 (start_inferior): Adjust to use ptids. Adjust to mywait interface
14686 changes. Don't reference the `attached' global.
14687 (attach_inferior): Adjust to mywait interface changes.
14688 (handle_query): Adjust to use ptids. Parse GDB's qSupported
14689 features. Handle and report "multiprocess+". Handle
14690 "qAttached:PID".
14691 (handle_v_cont): Adjust to use ptids. Adjust to mywait interface
14692 changes.
14693 (handle_v_kill): New.
14694 (handle_v_stopped): Adjust to use target_pid_to_str.
14695 (handle_v_requests): Allow multiple attaches and runs when
14696 multiprocess extensions are in effect. Handle "vKill".
14697 (myresume): Adjust to use ptids.
14698 (queue_stop_reply_callback): Add `arg' parameter. Handle it.
14699 (handle_status): Adjust to discard_queued_stop_replies interface
14700 change.
14701 (first_thread_of, kill_inferior_callback)
14702 (detach_or_kill_inferior_callback, join_inferiors_callback): New.
14703 (main): Call initialize_inferiors. Adjust to use ptids, killing
14704 and detaching from all inferiors. Handle multiprocess packet
14705 variants.
14706 * linux-low.h: Include gdb_proc_service.h.
14707 (struct process_info_private): New.
14708 (struct linux_target_ops) <pid_of>: Use ptid_get_pid.
14709 <lwpid_of>: Use ptid_get_lwp.
14710 (get_lwp_thread): Adjust.
14711 (struct lwp_info): Add `dead' member.
14712 (find_lwp_pid): Declare.
14713 * linux-low.c (thread_db_active): Delete.
14714 (new_inferior): Adjust comment.
14715 (inferior_pid): Delete.
14716 (linux_add_process): New.
14717 (handle_extended_wait): Adjust.
14718 (add_lwp): Change unsigned long to ptid.
14719 (linux_create_inferior): Add process to processes table. Adjust
14720 to use ptids. Don't set new_inferior here.
14721 (linux_attach_lwp): Rename to ...
14722 (linux_attach_lwp_1): ... this. Add `initial' argument. Handle
14723 it. Adjust to use ptids.
14724 (linux_attach_lwp): New.
14725 (linux_attach): Add process to processes table. Don't set
14726 new_inferior here.
14727 (struct counter): New.
14728 (second_thread_of_pid_p, last_thread_of_process_p): New.
14729 (linux_kill_one_lwp): Add `args' parameter. Handle it. Adjust to
14730 multiple processes.
14731 (linux_kill): Add `pid' argument. Handle it. Adjust to multiple
14732 processes. Remove process from process table.
14733 (linux_detach_one_lwp): Add `args' parameter. Handle it. Adjust
14734 to multiple processes.
14735 (any_thread_of): New.
14736 (linux_detach): Add `pid' argument, and handle it. Remove process
14737 from processes table.
14738 (linux_join): Add `pid' argument. Handle it.
14739 (linux_thread_alive): Change unsighed long argument to ptid_t.
14740 Consider dead lwps as not being alive.
14741 (status_pending_p): Rename `dummy' argument to `arg'. Filter out
14742 threads we're not interested in.
14743 (same_lwp, find_lwp_pid): New.
14744 (linux_wait_for_lwp): Change `pid' argument's type from int to
14745 ptid_t. Adjust.
14746 (linux_wait_for_event): Rename to ...
14747 (linux_wait_for_event_1): ... this. Change `pid' argument's type
14748 from int to ptid_t. Adjust.
14749 (linux_wait_for_event): New.
14750 (linux_wait_1): Add `ptid' argument. Change return type to
14751 ptid_t. Adjust. Use last_thread_of_process_p. Remove processes
14752 that exit from the process table.
14753 (linux_wait): Add `ptid' argument. Change return type to ptid_t.
14754 Adjust.
14755 (mark_lwp_dead): New.
14756 (wait_for_sigstop): Adjust to use ptids. If a process exits while
14757 stopping all threads, mark its main lwp as dead.
14758 (linux_set_resume_request, linux_resume_one_thread): Adjust to use
14759 ptids.
14760 (fetch_register, usr_store_inferior_registers)
14761 (regsets_fetch_inferior_registers)
14762 (regsets_store_inferior_registers, linux_read_memory)
14763 (linux_write_memory): Inline `inferior_pid'.
14764 (linux_look_up_symbols): Adjust to use per-process
14765 `thread_db_active'.
14766 (linux_request_interrupt): Adjust to use ptids.
14767 (linux_read_auxv): Inline `inferior_pid'.
14768 (initialize_low): Don't reference thread_db_active.
14769 * gdb_proc_service.h (struct ps_prochandle) <pid>: Remove.
14770 * proc-service.c (ps_lgetregs): Use find_lwp_pid.
14771 (ps_getpid): Return the pid of the current inferior.
14772 * thread-db.c (proc_handle, thread_agent): Delete.
14773 (thread_db_create_event, thread_db_enable_reporting): Adjust to
14774 per-process data.
14775 (find_one_thread): Change argument type to ptid_t. Adjust to
14776 per-process data.
14777 (maybe_attach_thread): Adjust to per-process data and ptids.
14778 (thread_db_find_new_threads): Ditto.
14779 (thread_db_init): Ditto.
14780 * spu-low.c (spu_create_inferior, spu_attach): Add process to
14781 processes table. Adjust to use ptids.
14782 (spu_kill, spu_detach): Adjust interface. Remove process from
14783 processes table.
14784 (spu_join, spu_thread_alive): Adjust interface.
14785 (spu_wait): Adjust interface. Remove process from processes
14786 table. Adjust to use ptids.
14787 * win32-low.c (current_inferior_tid): Delete.
14788 (current_inferior_ptid): New.
14789 (debug_event_ptid): New.
14790 (thread_rec): Take a ptid. Adjust.
14791 (child_add_thread): Add `pid' argument. Adjust to use ptids.
14792 (child_delete_thread): Ditto.
14793 (do_initial_child_stuff): Add `attached' argument. Add process to
14794 processes table.
14795 (child_fetch_inferior_registers, child_store_inferior_registers):
14796 Adjust.
14797 (win32_create_inferior): Pass 0 to do_initial_child_stuff.
14798 (win32_attach): Pass 1 to do_initial_child_stuff.
14799 (win32_kill): Adjust interface. Remove process from processes
14800 table.
14801 (win32_detach): Ditto.
14802 (win32_join): Adjust interface.
14803 (win32_thread_alive): Take a ptid.
14804 (win32_resume): Adjust to use ptids.
14805 (get_child_debug_event): Ditto.
14806 (win32_wait): Adjust interface. Remove exiting process from
14807 processes table.
14808
14809 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14810
14811 Non-stop mode support.
14812
14813 * server.h (non_stop): Declare.
14814 (gdb_client_data, handler_func): Declare.
14815 (delete_file_handler, add_file_handler, start_event_loop):
14816 Declare.
14817 (handle_serial_event, handle_target_event, push_event)
14818 (putpkt_notif): Declare.
14819 * target.h (enum resume_kind): New.
14820 (struct thread_resume): Replace `step' field by `kind' field.
14821 (TARGET_WNOHANG): Define.
14822 (struct target_ops) <wait>: Add `options' argument.
14823 <supports_non_stop, async, start_non_stop>: New fields.
14824 (target_supports_non_stop, target_async): New.
14825 (start_non_stop): Declare.
14826 (mywait): Add `options' argument.
14827 * target.c (mywait): Add `options' argument. Print child exit
14828 notifications here.
14829 (start_non_stop): New.
14830 * server.c (non_stop, own_buf, mem_buf): New globals.
14831 (struct vstop_notif): New.
14832 (notif_queue): New global.
14833 (queue_stop_reply, push_event, discard_queued_stop_replies)
14834 (send_next_stop_reply): New.
14835 (start_inferior): Adjust to use resume_kind. Adjust to mywait
14836 interface changes.
14837 (attach_inferior): In non-stop mode, don't wait for the target
14838 here.
14839 (handle_general_set): Handle QNonStop.
14840 (handle_query): When handling qC, return the current general
14841 thread, instead of the first thread of the list.
14842 (handle_query): If the backend supports non-stop mode, include
14843 QNonStop+ in the qSupported query response.
14844 (handle_v_cont): Adjust to use resume_kind. Handle resume_stop
14845 and non-stop mode.
14846 (handle_v_attach, handle_v_run): Handle non-stop mode.
14847 (handle_v_stopped): New.
14848 (handle_v_requests): Report support for vCont;t. Handle vStopped.
14849 (myresume): Adjust to use resume_kind. Handle non-stop.
14850 (queue_stop_reply_callback): New.
14851 (handle_status): Handle non-stop mode.
14852 (main): Clear non_stop flag on reconnection. Use the event-loop.
14853 Refactor serial protocol handling from here ...
14854 (process_serial_event): ... to this new function. When GDB
14855 selects any thread, select one here. In non-stop mode, wait until
14856 GDB acks all pending events before exiting.
14857 (handle_serial_event, handle_target_event): New.
14858 * remote-utils.c (remote_open): Install remote_desc in the event
14859 loop.
14860 (remote_close): Remove remote_desc from the event loop.
14861 (putpkt_binary): Rename to...
14862 (putpkt_binary_1): ... this. Add `is_notic' argument. Handle it.
14863 (putpkt_binary): New as wrapper around putpkt_binary_1.
14864 (putpkt_notif): New.
14865 (prepare_resume_reply): In non-stop mode, don't change the
14866 general_thread.
14867 * event-loop.c: New.
14868 * Makefile.in (OBJ): Add event-loop.o.
14869 (event-loop.o): New rule.
14870
14871 * linux-low.h (pid_of): Moved here.
14872 (lwpid_of): New.
14873 (get_lwp_thread): Use lwpid_of.
14874 (struct lwp_info): Delete `lwpid' field. Add `suspended' field.
14875 * linux-low.c (pid_of): Delete.
14876 (inferior_pid): Use lwpid_of.
14877 (linux_event_pipe): New.
14878 (target_is_async_p): New.
14879 (delete_lwp): New.
14880 (handle_extended_wait): Use lwpid_of.
14881 (add_lwp): Don't set lwpid field.
14882 (linux_attach_lwp): Adjust debug output. Use lwpid_of.
14883 (linux_kill_one_lwp): If killing a running lwp, stop it first.
14884 Use lwpid_of. Adjust to linux_wait_for_event interface changes.
14885 (linux_detach_one_lwp): If detaching from a running lwp, stop it
14886 first. Adjust to linux_wait_for_event interface changes. Use
14887 lwpid_of.
14888 (linux_detach): Don't delete the main lwp here.
14889 (linux_join): Use my_waitpid. Avoid signal_pid. Use lwpid_of.
14890 (status_pending_p): Don't consider explicitly suspended lwps.
14891 (linux_wait_for_lwp): Take an integer pid instead of a lwp_info
14892 pointer. Add OPTIONS argument. Change return type to int. Use
14893 my_waitpid instead of sleeping. Handle WNOHANG. Use lwpid_of.
14894 (linux_wait_for_event): Take an integer pid instead of a lwp_info
14895 pointer. Add status pointer argument. Return a pid instead of a
14896 status. Use lwpid_of. Adjust to linux_wait_for_lwp interface
14897 changes. In non-stop mode, don't switch to a random thread.
14898 (linux_wait): Rename to...
14899 (linux_wait_1): ... this. Add target_options argument, and handle
14900 it. Adjust to use resume_kind. Use lwpid_of. In non-stop mode,
14901 don't handle the continue thread. Handle TARGET_WNOHANG. Merge
14902 clean exit and signal exit code. Don't stop all threads in
14903 non-stop mode. In all-stop mode, only stop all threads when
14904 reporting a stop to GDB. Handle explicit thread stop requests.
14905 (async_file_flush, async_file_mark): New.
14906 (linux_wait): New.
14907 (send_sigstop): Use lwpid_of.
14908 (wait_for_sigstop): Use lwpid_of. Adjust to linux_wait_for_event
14909 interface changes. In non-stop mode, don't switch to a random
14910 thread.
14911 (linux_resume_one_lwp): Use lwpid_of.
14912 (linux_continue_one_thread, linux_queue_one_thread): Merge into ...
14913 (linux_resume_one_thread): ... this. Handle resume_stop. In
14914 non-stop mode, don't look for pending flag in all threads.
14915 (resume_status_pending_p): Don't consider explicitly suspended
14916 threads.
14917 (my_waitpid): Reimplement. Emulate __WALL.
14918 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
14919 Use lwpid_of.
14920 (sigchld_handler, linux_supports_non_stop, linux_async)
14921 (linux_start_non_stop): New.
14922 (linux_target_ops): Register linux_supports_non_stop, linux_async
14923 and linux_start_non_stop.
14924 (initialize_low): Install SIGCHLD handler.
14925 * thread-db.c (thread_db_create_event, find_one_thread)
14926 (thread_db_get_tls_address): Use lwpid_of.
14927 * win32-low.c (win32_detach): Adjust to use resume_kind.
14928 (win32_wait): Add `options' argument.
14929 * spu-low.c (spu_resume): Adjust to use resume_kind.
14930 (spu_wait): Add `options' argument.
14931
14932 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14933
14934 Decouple target code from remote protocol.
14935
14936 * target.h (enum target_waitkind): New.
14937 (struct target_waitstatus): New.
14938 (struct target_ops) <wait>: Return an unsigned long. Take a
14939 target_waitstatus pointer instead of a char pointer.
14940 (mywait): Likewise.
14941 * target.c (mywait): Change prototype to return an unsigned long.
14942 Take a target_waitstatus pointer instead of a char pointer. Adjust.
14943 * server.h (thread_from_wait, old_thread_from_wait): Delete
14944 declarations.
14945 (prepare_resume_reply): Change prototype to take a
14946 target_waitstatus.
14947 * server.c (thread_from_wait, old_thread_from_wait): Delete.
14948 (last_status, last_ptid): New.
14949 (start_inferior): Remove "statusptr" argument. Adjust. Return a
14950 pid instead of a signal.
14951 (attach_inferior): Remove "status" and "signal" parameters.
14952 Adjust.
14953 (handle_query): For qGetTLSAddr, parse the thread id with strtol,
14954 not as an address.
14955 (handle_v_cont, handle_v_attach, handle_v_run, handle_v_kill)
14956 (handle_v_requests, myresume): Remove "status" and "signal"
14957 parameters. Adjust.
14958 (handle_status): New.
14959 (main): Delete local `status'. Adjust.
14960 * remote-utils.c: Include target.h.
14961 (prepare_resume_reply): Change prototype to take a
14962 target_waitstatus. Adjust.
14963
14964 * linux-low.c (linux_wait): Adjust to new target_ops->wait
14965 interface.
14966 * spu-low.c (spu_wait): Adjust.
14967 * win32-low.c (enum target_waitkind, struct target_waitstatus):
14968 Delete.
14969 (win32_wait): Adjust.
14970
14971 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14972
14973 * target.h (struct thread_resume): Delete leave_stopped member.
14974 (struct target_ops): Add a `n' argument to the `resume' callback.
14975 * server.c (start_inferior): Adjust.
14976 (handle_v_cont, myresume): Adjust.
14977 * linux-low.c (check_removed_breakpoint): Adjust to resume
14978 interface change, and to removed leave_stopped field.
14979 (resume_ptr): Delete.
14980 (struct thread_resume_array): New.
14981 (linux_set_resume_request): Add new `arg' parameter. Adjust to
14982 resume interface change.
14983 (linux_continue_one_thread, linux_queue_one_thread)
14984 (resume_status_pending_p): Check if the resume field is NULL
14985 instead of checking the leave_stopped member.
14986 (linux_resume): Adjust to the target resume interface change.
14987 * spu-low.c (spu_resume): Adjust to the target resume interface
14988 change.
14989 * win32-low.c (win32_detach, win32_resume): Ditto.
14990
14991 2009-04-01 Pedro Alves <pedro@codesourcery.com>
14992
14993 * linux-low.c (linux_wait_for_event): Don't clear the `stepping'
14994 flag.
14995 (wait_for_sigstop): Don't leave a finished single-step SIGTRAP
14996 pending.
14997 (linux_continue_one_thread): Only preserve the stepping flag if
14998 there's a pending breakpoint.
14999
15000 2009-03-31 Pedro Alves <pedro@codesourcery.com>
15001
15002 * server.c (main): After the inferior having exited, call
15003 remote_close before exiting gdbserver.
15004
15005 2009-03-25 Thiago Jung Bauermann <bauerman@br.ibm.com>
15006
15007 Fix size of FPSCR in Power 7 processors.
15008 * linux-ppc-low.c (PPC_FEATURE_ARCH_2_05): Remove #define.
15009 (PPC_FEATURE_HAS_DFP): New #define.
15010 (ppc_arch_setup): Check for DFP feature instead of ISA 2.05 to decide on
15011 size of the FPSCR.
15012
15013 2009-03-23 Pedro Alves <pedro@codesourcery.com>
15014
15015 * server.c (handle_query) Whitespace and formatting.
15016
15017 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15018
15019 * i387-fp.c, linux-arm-low.c, linux-cris-low.c,
15020 linux-crisv32-low.c, linux-i386-low.c, linux-low.c,
15021 linux-mips-low.c, linux-s390-low.c, linux-sparc-low.c,
15022 linux-x86-64-low.c, linux-xtensa-low.c, proc-service.c,
15023 regcache.c, remote-utils.c, server.c, spu-low.c, target.h,
15024 thread-db.c, win32-low.c, xtensa-xtregs.c, gdbreplay.c,
15025 Makefile.in, configure.ac: Fix whitespace throughout.
15026 * configure: Regenerate.
15027
15028 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15029
15030 * inferiors.c (find_inferior): Make it safe for the callback
15031 function to delete the currently iterated inferior.
15032
15033 2009-03-22 Pedro Alves <pedro@codesourcery.com>
15034
15035 * Makefile.in (linuw_low_h): Move higher.
15036 (thread-db.o): Depend on $(linux_low_h).
15037
15038 2009-03-17 Pedro Alves <pedro@codesourcery.com>
15039
15040 Rename "process" to "lwp" throughout.
15041
15042 * linux-low.c (all_processes): Rename to...
15043 (all_lwps): ... this.
15044 (inferior_pid, handle_extended_wait, get_stop_pc): Adjust.
15045 (add_process): Rename to ...
15046 (add_lwp): ... this. Adjust.
15047 (linux_create_inferior): Adjust.
15048 (linux_attach_lwp): Adjust.
15049 (linux_attach): Adjust.
15050 (linux_kill_one_process): Rename to ...
15051 (linux_kill_one_lwp): ... this. Adjust.
15052 (linux_kill): Adjust.
15053 (linux_detach_one_process): Rename to ...
15054 (linux_detach_one_lwp): ... this. Adjust.
15055 (linux_detach): Adjust.
15056 (check_removed_breakpoint): Adjust.
15057 (status_pending_p): Adjust.
15058 (linux_wait_for_process): Rename to ...
15059 (linux_wait_for_lwp): ... this. Adjust.
15060 (linux_wait_for_event): Adjust.
15061 (send_sigstop): Adjust.
15062 (wait_for_sigstop): Adjust.
15063 (stop_all_processes): Rename to ...
15064 (stop_all_lwps): ... this.
15065 (linux_resume_one_process): Rename to ...
15066 (linux_resume_one_lwp): ... this. Adjust.
15067 (linux_set_resume_request, linux_continue_one_thread)
15068 (linux_queue_one_thread, resume_status_pending_p)
15069 (usr_store_inferior_registers, regsets_store_inferior_registers)
15070 (linux_request_interrupt, linux_read_offsets, linux_xfer_siginfo):
15071 Adjust.
15072 * linux-low.h (get_process): Rename to ...
15073 (get_lwp): ... this. Adjust.
15074 (get_thread_process): Rename to ...
15075 (get_thread_lwp): ... this. Adjust.
15076 (get_process_thread): Rename to ...
15077 (get_lwp_thread): ... this. Adjust.
15078 (struct process_info): Rename to ...
15079 (struct lwp_info): ... this.
15080 (all_processes): Rename to ...
15081 (all_lwps): ... this.
15082 * proc-service.c (ps_lgetregs): Adjust.
15083 * thread-db.c (thread_db_create_event, find_one_thread)
15084 (maybe_attach_thread, thread_db_get_tls_address): Adjust.
15085
15086 2009-03-14 Pedro Alves <pedro@codesourcery.com>
15087
15088 * server.c (handle_query): Handle "qAttached".
15089
15090 2009-03-13 Nathan Sidwell <nathan@codesourcery.com>
15091
15092 * Makefile.in, hostio-errno.c, errno.c, xtensa-xtregs.c: Change to
15093 GPLv3, update license URL.
15094
15095 2009-03-01 Doug Evans <dje@google.com>
15096
15097 * Makefile.in (INCLUDE_CFLAGS): Add -I$(srcdir)/../common.
15098 (server_h): Add gdb_signals.h.
15099 (signals.o): Update.
15100 * server.h (target_signal_from_host,target_signal_to_host_p)
15101 (target_signal_to_host,target_signal_to_name): Moved to gdb_signals.h.
15102
15103 2009-02-14 Pierre Muller <muller@ics.u-strasbg.fr>
15104
15105 * remote-utils.c (getpkt): Also generate remote-debug
15106 information if noack_mode is set.
15107
15108 2009-02-06 Pedro Alves <pedro@codesourcery.com>
15109
15110 * server.c (handle_query): Report qXfer:siginfo:read and
15111 qXfer:siginfo:write as supported and handle them.
15112 * target.h (struct target_ops) <qxfer_siginfo>: New field.
15113 * linux-low.c (linux_xfer_siginfo): New.
15114 (linux_target_ops): Set it.
15115
15116 2009-01-26 Pedro Alves <pedro@codesourcery.com>
15117
15118 * server.c (gdbserver_usage): Mention --remote-debug.
15119 (main): Accept '--remote-debug' switch.
15120
15121 2009-01-18 Doug Evans <dje@google.com>
15122
15123 * regcache.c (new_register_cache): No need to check result of xcalloc.
15124 * server.c (handle_search_memory): Back out calls to xmalloc,
15125 result is checked and error is returned to user upon failure.
15126 (handle_query): Ditto. Add more checks for result of malloc.
15127 (handle_v_cont): Check result of malloc, report error back to
15128 user upon failure.
15129 (handle_v_run): Ditto. Call freeargv.
15130 * server.h (freeargv): Declare.
15131 * utils.c (freeargv): New fn.
15132
15133 2009-01-15 Doug Evans <dje@google.com>
15134
15135 * gdbreplay.c (perror_with_name): Make arg const char *.
15136 * server.h (target_signal_to_name): Make return type const char *.
15137 * thread-db.c (thread_db_err_str): Make return type const char *.
15138 * utils.c (perror_with_name): Make arg const char *.
15139
15140 2009-01-14 Pedro Alves <pedro@codesourcery.com>
15141
15142 * win32-low.c (get_child_debug_event): Issue a final DBG_CONTINUE
15143 when handling a EXIT_PROCESS_DEBUG_EVENT.
15144
15145 2009-01-06 Joel Brobecker <brobecker@adacore.com>
15146
15147 * gdbreplay.c (gdbreplay_version): Update copyright year.
15148 * server.c (gdbserver_version): Likewise.
15149
15150 2009-01-05 Doug Evans <dje@google.com>
15151
15152 * linux-low.c (linux_attach_lwp): Add some comments/fixmes.
15153 (handle_extended_wait): Improve comment.
15154
15155 2008-12-13 Doug Evans <dje@google.com>
15156
15157 * utils.c (xmalloc,xcalloc,xstrdup): New fns.
15158 * server.h (ATTR_MALLOC): New macro.
15159 (xmalloc,xcalloc,xstrdup): Declare.
15160 * hostio.c: Replace malloc,calloc,strdup with xmalloc,xcalloc,xstrdup.
15161 * inferiors.c: Ditto.
15162 * linux-low.c: Ditto.
15163 * mem-break.c: Ditto.
15164 * regcache.c: Ditto.
15165 * remote-utils.c: Ditto.
15166 * server.c: Ditto.
15167 * target.c: Ditto.
15168 * win32-low.c: Ditto.
15169
15170 2008-12-12 Doug Evans <dje@google.com>
15171
15172 * linux-low.c (linux_wait_for_process): Don't clobber current_inferior
15173 in debugging printf.
15174
15175 * linux-low.c (handle_extended_wait): Simplify, use my_waitpid.
15176
15177 2008-12-09 Doug Evans <dje@google.com>
15178
15179 * linux-low.h (struct process_info): Delete member tid, unused.
15180 * thread-db.c (find_one_thread): Update.
15181 (maybe_attach_thread): Update.
15182
15183 2008-12-02 Pedro Alves <pedro@codesourcery.com>
15184
15185 * target.h (struct target_ops): Add qxfer_osdata member.
15186 * linux-low.c: Include ctype.h and pwd.h and sys/types.h
15187 and dirent.h.
15188 (linux_qxfer_osdata): New functions.
15189 (linux_target_ops): Register linux_qxfer_osdata as qxfer_osdata
15190 callback.
15191 * server.c (handle_query): Handle "qXfer:osdata:read:".
15192 * remote-utils.c (buffer_grow, buffer_free, buffer_init, buffer_finish)
15193 (buffer_xml_printf): New functions.
15194 * server.h (struct buffer): New.
15195 (buffer_grow_str, buffer_grow_str0): New macros.
15196 (buffer_grow, buffer_free, buffer_init, buffer_finish)
15197 (buffer_xml_printf): Declare.
15198
15199 2008-11-24 Doug Evans <dje@google.com>
15200
15201 * Makefile.in (VERSION,DIST,LINT,LINTFLAGS): Delete, unused.
15202
15203 2008-11-24 Daniel Jacobowitz <dan@codesourcery.com>
15204
15205 * server.c (handle_v_run): Always use the supplied argument list.
15206
15207 2008-11-19 Bob Wilson <bob.wilson@acm.org>
15208
15209 * xtensa-xtregs.c (XTENSA_ELF_XTREG_SIZE): Change to 4.
15210 (xtensa_regmap_table): Add entry for scompare1.
15211
15212 2008-11-18 Thiago Jung Bauermann <bauerman@br.ibm.com>
15213
15214 * Makefile.in (powerpc-isa205-32l.o, powerpc-isa205-32l.c,
15215 powerpc-isa205-altivec32l.o, powerpc-isa205-altivec32l.c,
15216 powerpc-isa205-vsx32l.o, powerpc-isa205-vsx32l.c,
15217 powerpc-isa205-64l.o, powerpc-isa205-64l.c,
15218 powerpc-isa205-altivec64l.o, powerpc-isa205-altivec64l.c,
15219 powerpc-isa205-vsx64l.o, powerpc-isa205-vsx64l.c): New targets.
15220 * configure.srv (powerpc*-*-linux*): Add ISA 2.05 object files and
15221 XML target descriptions.
15222 * linux-ppc-low.c (ppc_arch_setup): Init registers with 64-bit FPSCR
15223 when inferior is running on an ISA 2.05 or later processor. Add
15224 special case to return offset for full 64-bit slot of FPSCR when
15225 in 32-bits.
15226
15227 2008-11-14 Daniel Gutson <dgutson@codesourcery.com>
15228
15229 * Makefile.in (SFILES, clean): Added sparc64 files.
15230 (reg-sparc64.o, reg-sparc64.c): New.
15231 * configure.srv (sparc*-*-linux*): New configuration.
15232 * linux-low.c (regsets_fetch_inferior_registers): Swap ptrace
15233 syscall arguments for SPARC.
15234 (regsets_store_inferior_registers): Likewise.
15235 * linux-sparc-low.c: New file.
15236
15237 2008-10-21 Doug Evans <dje@google.com>
15238
15239 * Makefile.in (BFD_DIR,BFD,BFD_SRC,BFD_CFLAGS): Delete.
15240 (READLINE_DIR,READLINE_DEP): Delete.
15241 (INTERNAL_CFLAGS): Update.
15242 (LINTFLAGS): Update.
15243
15244 2008-10-10 Pedro Alves <pedro@codesourcery.com>
15245
15246 * server.c (handle_v_run): If GDB didn't specify an argv, use the
15247 whole argv from the last run, not just argv[0].
15248
15249 2008-09-08 Pedro Alves <pedro@codesourcery.com>
15250
15251 * regcache.c (new_register_cache): Return NULL if the register
15252 cache size isn't known yet.
15253 (free_register_cache): Avoid dereferencing a NULL regcache.
15254
15255 2008-09-04 Daniel Jacobowitz <dan@codesourcery.com>
15256
15257 * configure.srv: Merge MIPS and MIPS64.
15258
15259 2008-08-24 Maciej W. Rozycki <macro@linux-mips.org>
15260
15261 * Makefile.in (uninstall): Apply $(EXEEXT) too.
15262
15263 2008-08-18 Luis Machado <luisgpm@br.ibm.com>
15264
15265 * Makefile.in: Add required vsx dependencies.
15266
15267 * linux-ppc-low: Define PPC_FEATURE_HAS_VSX.
15268 Declare init_registers_powerpc_vsx32l.
15269 Declare init_registers_powerpc_vsx64l.
15270 Define PTRACE_GETVSXREGS and PTRACE_SETVSXREGS.
15271 (ppc_arch_setup): Check for VSX in hwcap.
15272 (ppc_fill_vsxregset): New function.
15273 (ppc_store_vsxregset): New function.
15274 Add new VSX entry in regset_info target_regsets.
15275
15276 * configure.srv: Add new VSX dependencies.
15277
15278 2008-08-12 Pedro Alves <pedro@codesourcery.com>
15279
15280 * remote-utils.c (noack_mode, transport_is_reliable): New globals.
15281 (remote_open): Set or clear transport_is_reliable.
15282 (putpkt_binary): Don't expect acks in noack mode.
15283 (getpkt): Don't send ack/nac in noack mode.
15284 * server.c (handle_general_set): Handle QStartNoAckMode.
15285 (handle_query): If connected by tcp pass QStartNoAckMode+ in
15286 qSupported.
15287 (main): Reset noack_mode on every connection.
15288 * server.h (noack_mode): Declare.
15289
15290 2008-08-07 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
15291
15292 * Makefile.in (GDBREPLAY_OBS): New variable.
15293 (gdbreplay$(EXEEXT)): Use it to avoid unportable $^.
15294
15295 2008-08-05 Ulrich Weigand <uweigand@de.ibm.com>
15296 Daniel Jacobowitz <dan@codesourcery.com>
15297
15298 * linux-low.c (linux_resume_one_process): Ignore ESRCH.
15299 (usr_store_inferior_registers): Likewise.
15300 (regsets_store_inferior_registers): Likewise.
15301
15302 2008-07-31 Rolf Jansen <rj@surtec.com>
15303 Pedro Alves <pedro@codesourcery.com>
15304
15305 * configure.ac: Check for memmem declaration.
15306 * server.c [HAVE_MALLOC_H]: Include malloc.h.
15307 (disable_packet_vCont, disable_packet_Tthread, disable_packet_qC)
15308 (disable_packet_qfThreadInfo): Unconditionally compile.
15309 * server.h [!HAVE_DECL_MEMMEM]: Declare memmem.
15310 * configure, config.in: Regenerate.
15311
15312 2008-07-28 Doug Kwan <dougkwan@google.com>
15313
15314 * linux-low.c (sys/dir.h, sys/user.h): Remove includes.
15315 (linux_write_memory): Remove declaration of errno.
15316
15317 2008-07-12 Ulrich Weigand <uweigand@de.ibm.com>
15318
15319 * linux-low.c (handle_extended_wait): Do not use "status"
15320 variable uninitialized.
15321
15322 2008-07-07 Pedro Alves <pedro@codesourcery.com>
15323
15324 * server.c (handle_v_attach): Inhibit reporting dll changes.
15325
15326 2008-06-27 Pedro Alves <pedro@codesourcery.com>
15327
15328 * remote-utils.c (prepare_resume_reply): If requested, don't
15329 output "thread:TID" in the T stop reply.
15330
15331 * server.c (disable_packet_vCont, disable_packet_Tthread)
15332 (disable_packet_qC, disable_packet_qfThreadInfo): New globals.
15333 (handle_query): If requested, disable support for qC, qfThreadInfo
15334 and qsThreadInfo.
15335 (handle_v_requests): If requested, disable support for vCont.
15336 (gdbserver_show_disableable): New.
15337 (main): Handle --disable-packet and --disable-packet=LIST.
15338
15339 * server.h (disable_packet_vCont, disable_packet_Tthread)
15340 (disable_packet_qC, disable_packet_qfThreadInfo): Declare.
15341
15342 2008-06-20 Carlos O'Donell <carlos@codesourcery.com>
15343
15344 * server.c (gdbserver_usage): Mention --version.
15345
15346 2008-06-06 Daniel Jacobowitz <dan@codesourcery.com>
15347
15348 * Makefile.in (gdbreplay.o): New rule.
15349
15350 2008-06-06 Joseph Myers <joseph@codesourcery.com>
15351
15352 * gdbreplay.c (gdbreplay_version): Say gdbreplay in version
15353 message, not gdbserver.
15354
15355 2008-06-05 Vladimir Prus <vladimir@codesourcery.com>
15356 Nathan Sidwell <nathan@codesourcery.com>
15357 Joseph Myers <joseph@codesourcery.com>
15358
15359 * acinclude.m4: Include ../../config/acx.m4.
15360 * configure.ac: Use ACX_PKGVERSION and ACX_BUGURL.
15361 * configure, config.in: Regenerate.
15362 * Makefile.in (gdbreplay$(EXEEXT)): Add version.o.
15363 * server.c (gdbserver_version): Print PKGVERSION.
15364 (gdbsrever_usage): Add stream parameter. Print REPORT_BUGS_TO.
15365 (main): Adjust gdbserver_usage calls.
15366 * gdbreplay.c (version, host_name): Add declarations.
15367 (gdbreplay_version, gdbreplay_usage): New.
15368 (main): Accept --version and --help options.
15369
15370 2008-06-04 Daniel Jacobowitz <dan@codesourcery.com>
15371
15372 * linux-arm-low.c (thumb_breakpoint, thumb_breakpoint_len): New.
15373 (arm_breakpoint_at): Handle Thumb.
15374 (the_low_target): Add comment.
15375
15376 2008-05-29 Ulrich Weigand <uweigand@de.ibm.com>
15377
15378 * linux-ppc-low.c (ppc_collect_ptrace_register): Clear buffer.
15379
15380 2008-05-09 Doug Evans <dje@google.com>
15381
15382 * server.h (decode_search_memory_packet): Declare.
15383 * remote-utils.c (decode_search_memory_packet): New fn.
15384 * server.c (handle_search_memory_1): New fn.
15385 (handle_search_memory): New fn.
15386 (handle_query): Process qSearch:memory packets.
15387
15388 2008-05-08 Ulrich Weigand <uweigand@de.ibm.com>
15389
15390 * regcache.c (registers_length): Remove.
15391 (set_register_cache): Verify that PBUFSIZ is large enough to hold a
15392 full register packet.
15393 * regcache.h (registers_length): Remove prototype.
15394 * server.h (PBUFSIZ): Define to 16384.
15395
15396 2008-05-03 Ulrich Weigand <uweigand@de.ibm.com>
15397
15398 * configure.srv (powerpc*-*-linux*): Set srv_regobj to
15399 powerpc-32l.o, powerpc-altivec32l.o, powerpc-e500l.o,
15400 powerpc-64l.o, and powerpc-altivec64l.o.
15401 Remove rs6000/powerpc-32.xml, rs6000/powerpc-64.xml, and
15402 rs6000/powerpc-e500.xml; add rs6000/powerpc-32l.xml,
15403 rs6000/powerpc-altivec32l.xml, rs6000/powerpc-e500l.xml,
15404 rs6000/powerpc-64l.xml, rs6000/powerpc-altivec64l.xml,
15405 rs6000/power-linux.xml, and rs6000/power64-linux.xml
15406 to srv_xmlfiles.
15407
15408 * Makefile.in (reg-ppc.o, reg-ppc.c): Remove, replace by ...
15409 (powerpc-32l.o, powerpc-32l.c): ... these new rules.
15410 (powerpc-32.o, powerpc-32.c): Remove, replace by ...
15411 (powerpc-altivec32l.o, powerpc-altivec32l.c): ... these new rules.
15412 (powerpc-e500.o, powerpc-e500.c): Remove, replace by ...
15413 (powerpc-e500l.o, powerpc-e500l.c): ... these new rules.
15414 (reg-ppc64.o, reg-ppc64.c): Remove, replace by ...
15415 (powerpc-64l.o, powerpc-64l.c): ... these new rules.
15416 (powerpc-64.o, powerpc-64.c): Remove, replace by ...
15417 (powerpc-altivec64l.o, powerpc-altivec64l.c): ... these new rules.
15418 (clean): Update.
15419
15420 * linux-ppc-low.c (init_registers_ppc): Remove, replace by ...
15421 (init_registers_powerpc_32l): ... this new prototype.
15422 (init_registers_powerpc_32): Remove, replace by ...
15423 (init_registers_powerpc_altivec32l): ... this new prototype.
15424 (init_registers_powerpc_e500): Remove, replace by ...
15425 (init_registers_powerpc_e500l): ... this new prototype.
15426 (init_registers_ppc64): Remove, replace by ...
15427 (init_registers_powerpc_64l): ... this new prototype.
15428 (init_registers_powerpc_64): Remove, replace by ...
15429 (init_registers_powerpc_altivec64l): ... this new prototype.
15430 (ppc_num_regs): Set to 73.
15431 (PT_ORIG_R3, PT_TRAP): Define if necessary.
15432 (ppc_regmap, ppc_regmap_e500): Add values for orig_r3 and trap.
15433 (ppc_cannot_store_register): Handle orig_r3 and trap.
15434 (ppc_arch_setup): Update init_registers_... calls.
15435 (ppc_fill_gregset): Handle orig_r3 and trap.
15436
15437 * inferiors.c (clear_inferiors): Reset current_inferior.
15438
15439 2008-04-23 Paolo Bonzini <bonzini@gnu.org>
15440
15441 * acinclude.m4: Add override.m4.
15442 * configure: Regenerate.
15443
15444 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15445
15446 * linux-ppc-low.c (ppc_arch_setup): Reset ppc_hwcap after the
15447 initial call to init_register_ppc64.
15448
15449 2008-04-21 Ulrich Weigand <uweigand@de.ibm.com>
15450
15451 * configure.srv (powerpc64-*-linux*, powerpc-*-linux*): Merge into
15452 single powerpc*-*-linux* case.
15453 (s390-*-linux*, s390x-*-linux*): Merge into single s390*-*-linux* case.
15454
15455 2008-04-17 Ulrich Weigand <uweigand@de.ibm.com>
15456
15457 * configure.srv [powerpc64-*-linux*]: Remove powerpc-e500.o from
15458 srv_regobj. Remove rs6000/powerpc-e500.xml and rs6000/power-spe.xml
15459 from reg_xmlfiles.
15460 * linux-ppc-low.c: Include <elf.h>.
15461 (PPC_FEATURE_HAS_ALTIVEC, PPC_FEATURE_HAS_SPE): Define.
15462 (ppc_hwcap): New global variable.
15463 (ppc_regmap): Remove __SPE__ #ifdef sections.
15464 (ppc_regmap_e500): New global variable.
15465 (ppc_cannot_store_register): Update __SPE__ special case.
15466 (ppc_get_hwcap): New function.
15467 (ppc_arch_setup): Use it to determine whether inferior supports
15468 AltiVec or SPE registers. Set the_low_target.regmap if appropriate.
15469 (ppc_fill_vrregset, ppc_store_vrregset): Define unconditionally.
15470 Do not access registers if target does not support AltiVec.
15471 (ppc_fill_evrregset, ppc_store_evrregset): Define unconditionally.
15472 Do not access registers if target does not support SPE.
15473 (target_regsets): Unconditionally include AltiVec and SPE regsets.
15474
15475 2008-04-17 Daniel Jacobowitz <dan@codesourcery.com>
15476
15477 * linux-low.c (disabled_regsets, num_regsets): New.
15478 (use_regsets_p): Delete.
15479 (linux_wait_for_process): Clear disabled_regsets.
15480 (regsets_fetch_inferior_registers): Check and set it.
15481 (regsets_store_inferior_registers): Likewise.
15482 (linux_fetch_registers, linux_store_registers): Do not use
15483 use_regsets_p.
15484 (initialize_low): Allocate disabled_regsets.
15485
15486 2008-04-14 Daniel Jacobowitz <dan@codesourcery.com>
15487
15488 * Makefile.in (LIBOBJS): New.
15489 (OBS): Use LIBOBJS.
15490 (memmem.o): New rule.
15491 * configure.ac: Use AC_CONFIG_LIBOBJ_DIR and check for memmem.
15492 * configure: Regenerated.
15493
15494 2008-04-04 Ulrich Weigand <uweigand@de.ibm.com>
15495
15496 * server.c (handle_query): Never return "unsupported" for
15497 qXfer:features:read queries.
15498
15499 2008-03-27 Ulrich Weigand <uweigand@de.ibm.com>
15500
15501 * server.c (get_features_xml): Fix inverted condition.
15502 (handle_query): Always support qXfer:feature:read.
15503
15504 2008-03-10 Daniel Jacobowitz <dan@codesourcery.com>
15505
15506 * server.c (wrapper_argv): New.
15507 (start_inferior): Handle wrapper_argv. If set, expect an extra
15508 trap.
15509 (gdbserver_usage): Document --wrapper.
15510 (main): Parse --wrapper.
15511
15512 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15513
15514 * configure.srv [powerpc64-*-linux*]: Add all files mentioned for
15515 powerpc-*-linux* to srv_regobj and reg_xmlfiles.
15516 * linux-ppc-low.c (ppc_get_pc): Support bi-arch operation.
15517 (ppc_set_pc): Likewise.
15518 (ppc_arch_setup): New function.
15519 (ppc_fill_gregset): Call ppc_collect_ptrace_register instead
15520 of collect_register.
15521 (the_low_target): Use ppc_arch_setup as arch_setup initializer.
15522
15523 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15524
15525 * configure.srv [powerpc64-*-linux*]: Use linux-ppc-low.o
15526 instead of linux-ppc64-low.o.
15527 * linux-ppc64-low.c: Remove file.
15528 * Makefile.in (SFILES): Remove linux-ppc64-low.c.
15529 (linux-ppc64-low.o): Remove rule.
15530
15531 * linux-ppc-low.c (init_registers_ppc64): Add prototype.
15532 (init_registers_powerpc_64): Likewise.
15533 (ppc_regmap): Conditionally define depending on __powerpc64__.
15534 (ppc_cannot_store_register): Do not special-case "fpscr" when
15535 compiled on __powerpc64__.
15536 (ppc_collect_ptrace_register): New function.
15537 (ppc_supply_ptrace_register): New function.
15538 (ppc_breakpoint): Change type to "unsigned int".
15539 (ppc_breakpoint_at): Change type of "insn" to "unsigned int".
15540 (the_low_target): Conditionally provide initializers for the
15541 arch_setup member depending on __powerpc64__. Install
15542 collect_ptrace_register and supply_ptrace_register members.
15543
15544 2008-02-28 Ulrich Weigand <uweigand@de.ibm.com>
15545
15546 * regcache.h (gdbserver_xmltarget): Add extern declaration.
15547 * server.c (gdbserver_xmltarget): Define.
15548 (get_features_xml): Use it to replace "target.xml" and arch_string.
15549
15550 * configure.srv: Remove srv_xmltarget. Add XML files that were
15551 mentioned there to srv_xmlfiles instead. Remove conditional tests
15552 on gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe; set
15553 srv_xmlfiles and srv_regobj to include all possible choices.
15554 * configure.ac (srv_xmltarget): Remove.
15555 (srv_xmlfiles): Do not add "target.xml".
15556 (gdb_cv_arm_iwmmxt, gdb_cv_ppc_altivec, gdb_cv_ppc_spe): Remove
15557 checks for supplementary target information.
15558 * configure: Regenerate.
15559 * Makefile.in (XML_TARGET): Remove.
15560 (target.xml): Remove rule.
15561 (clean): Do not clean up target.xml.
15562 (.PRECIOUS): Do not mention target.xml.
15563
15564 * target.h (struct target_ops): Remove arch_string member.
15565 * linux-low.c (linux_arch_string): Remove.
15566 (linux_target_ops): Remove arch_string initializer.
15567 * linux-low.h (struct linux_target_ops): Remove arch_string member.
15568 * linux-i386-low.c (the_low_target): Remove arch_string initializer.
15569 * linux-x86-64-low.c (the_low_target): Remove arch_string initializer.
15570 * spu-low.c (spu_arch_string): Remove.
15571 (spu_target_ops): Remove arch_string initializer.
15572 * win32-low.c (win32_arch_string): Remove.
15573 (win32_target_ops): Remove arch_string initializer.
15574 * win32-low.h (struct win32_target_ops): Remove arch_string member.
15575 * win32-arm-low.c (the_low_target): Remove arch_string initializer.
15576 * win32-i368-low.c (the_low_target): Remove arch_string initializer.
15577
15578 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15579
15580 * linux-low.h (struct linux_target_ops): Replace left_pad_xfer field
15581 by collect_ptrace_register and supply_ptrace_register hooks.
15582 * linux-low.c (fetch_register): Use supply_ptrace_register callback
15583 instead of checking for the_low_target.left_pad_xfer.
15584 (usr_store_inferior_registers): Use collect_ptrace_register callback
15585 instead of checking for the_low_target.left_pad_xfer.
15586
15587 * linux-s390-low.c (s390_collect_ptrace_register): New function.
15588 (s390_supply_ptrace_register): Likewise.
15589 (s390_fill_gregset): Call s390_collect_ptrace_register.
15590 (the_low_target): Update.
15591
15592 * linux-ppc64-low.c (ppc_collect_ptrace_register): New function.
15593 (ppc_supply_ptrace_register): Likewise.
15594 (the_low_target): Update.
15595
15596 * linux-i386-low.c (the_low_target): Update.
15597 * linux-x86-64-low.c (the_low_target): Update.
15598
15599 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15600
15601 * configure.srv [s390x-*-linux*]: Set srv_regobj to include both
15602 reg-s390.o and reg-s390x.o.
15603
15604 * linux-low.c (new_inferior): New global variable.
15605 (linux_create_inferior, linux_attach): Set it.
15606 (linux_wait_for_process): Call the_low_target.arch_setup after the
15607 target has stopped for the first time.
15608 (initialize_low): Do not call the_low_target.arch_setup.
15609
15610 * linux-s390-low.c (s390_get_pc): Support bi-arch operation.
15611 (s390_set_pc): Likewise.
15612 (s390_arch_setup): New function.
15613 (the_low_target): Use s390_arch_setup as arch_setup routine.
15614
15615 * regcache.c (realloc_register_cache): New function.
15616 (set_register_cache): Call it for each existing regcache.
15617
15618 2008-02-27 Ulrich Weigand <uweigand@de.ibm.com>
15619
15620 * server.h (init_registers): Remove prototype.
15621
15622 * linux-low.h (struct linux_target_ops): Add arch_setup field.
15623 * linux-low.c (initialize_low): Call the_low_target.arch_setup ()
15624 instead of init_registers ().
15625 * linux-arm-low.c (init_registers_arm): Add prototype.
15626 (init_registers_arm_with_iwmmxt): Likewise.
15627 (the_low_target): Add initializer for arch_setup field.
15628 * linux-cris-low.c (init_registers_cris): Add prototype.
15629 (the_low_target): Add initializer for arch_setup field.
15630 * linux-crisv32-low.c (init_registers_crisv32): Add prototype.
15631 (the_low_target): Add initializer for arch_setup field.
15632 * linux-i386-low.c (init_registers_i386_linux): Add prototype.
15633 (the_low_target): Add initializer for arch_setup field.
15634 * linux-ia64-low.c (init_registers_ia64): Add prototype.
15635 (the_low_target): Add initializer for arch_setup field.
15636 * linux-m32r-low.c (init_registers_m32r): Add prototype.
15637 (the_low_target): Add initializer for arch_setup field.
15638 * linux-m68k-low.c (init_registers_m68k): Add prototype.
15639 (the_low_target): Add initializer for arch_setup field.
15640 * linux-mips-low.c (init_registers_mips_linux): Add prototype.
15641 (init_registers_mips64_linux): Likewise.
15642 (the_low_target): Add initializer for arch_setup field.
15643 * linux-ppc-low.c (init_registers_ppc): Add prototype.
15644 (init_registers_powerpc_32, init_registers_powerpc_e500): Likewise.
15645 (the_low_target): Add initializer for arch_setup field.
15646 * linux-ppc64-low.c (init_registers_ppc64): Add prototype.
15647 (init_registers_powerpc_64): Likewise.
15648 (the_low_target): Add initializer for arch_setup field.
15649 * linux-s390-low.c (init_registers_s390): Add prototype.
15650 (init_registers_s390x): Likewise.
15651 (the_low_target): Add initializer for arch_setup field.
15652 * linux-sh-low.c (init_registers_sh): Add prototype.
15653 (the_low_target): Add initializer for arch_setup field.
15654 * linux-x86-64-low.c (init_registers_x86_64_linux): Add prototype.
15655 (the_low_target): Add initializer for arch_setup field.
15656 * linux-xtensa-low.c (init_registers_xtensa): Add prototype.
15657 (the_low_target): Add initializer for arch_setup field.
15658
15659 * win32-low.h (struct win32_target_ops): Add arch_setup field.
15660 * win32-low.c (initialize_low): Call the_low_target.arch_setup ()
15661 instead of init_registers ().
15662 * win32-arm-low.c (init_registers_arm): Add prototype.
15663 (the_low_target): Add initializer for arch_setup field.
15664 * win32-i386-low.c (init_registers_i386): Add prototype.
15665 (the_low_target): Add initializer for arch_setup field.
15666
15667 * spu-low.c (init_registers_spu): Add prototype.
15668 (initialize_low): Call initialie_registers_spu () instead of
15669 initialize_registers ().
15670
15671 2008-02-19 Pedro Alves <pedro@codesourcery.com>
15672
15673 * server.c (handle_v_requests): When handling the vRun and vAttach
15674 packets, if already debugging a process, don't kill it. Return an
15675 error instead.
15676
15677 2008-02-17 Daniel Jacobowitz <dan@codesourcery.com>
15678
15679 * server.c (handle_query): Correct length check.
15680
15681 2008-02-14 Pedro Alves <pedro_alves@portugalmail.pt>
15682
15683 * win32-low.c (do_initial_child_stuff): Add process handle
15684 parameter. Set current_process_handle and current_process_id from the
15685 parameters. Clear globals.
15686 (win32_create_inferior): Don't set current_process_handle and
15687 current_process_id here. Instead pass them on the call to
15688 do_initial_child_stuff.
15689 (win32_attach): Likewise.
15690 (win32_clear_inferiors): New.
15691 (win32_kill): Don't close the current process handle or the
15692 current thread handle here. Instead call win32_clear_inferiors.
15693 (win32_detach): Don't open a new handle to the process. Call
15694 win32_clear_inferiors.
15695 (win32_join): Don't rely on current_process_handle; open a new
15696 handle using the process id.
15697 (win32_wait): Call win32_clear_inferiors when the inferior process
15698 has exited.
15699
15700 2008-02-14 Daniel Jacobowitz <dan@codesourcery.com>
15701
15702 * server.c (monitor_show_help): Add "exit".
15703
15704 2008-02-11 Maxim Grigoriev <maxim2405@gmail.com>
15705
15706 * Makefile.in (SFILES): Add linux-xtensa-low.c.
15707 (clean): Add reg-xtensa.c.
15708 (linux-xtensa-low.o, reg-xtensa.o, reg-xtensa.c): New dependencies.
15709 * configure.srv (xtensa*-*-linux*) New target.
15710 * linux-xtensa-low.c: New.
15711 * xtensa-xtregs.c: New.
15712
15713 2008-02-01 Pedro Alves <pedro_alves@portugalmail.pt>
15714
15715 * hostio.c: Don't include errno.h.
15716 (errno_to_fileio_errno): Move to hostio-errno.
15717 * hostio.c: (hostio_error): Remove the error parameter. Defer the
15718 error number outputting to the target->hostio_last_error callback.
15719 (hostio_packet_error): Use FILEIO_EINVAL directly.
15720 (handle_open, handle_pread, hostio_error, handle_unlink): Update
15721 calls to hostio_error.
15722 * hostio-errno.c: New.
15723 * server.h (hostio_last_error_from_errno): Declare.
15724 * target.h (target_ops): Add hostio_last_error member.
15725 * linux-low.c (linux_target_op): Register hostio_last_error_from_errno
15726 as hostio_last_error handler.
15727 * spu-low.c (spu_target_ops): Likewise.
15728 * win32-low.c [_WIN32_WCE] (win32_error_to_fileio_error)
15729 (wince_hostio_last_error): New functions.
15730 (win32_target_ops) [_WIN32_WCE]: Register wince_hostio_last_error
15731 as hostio_last_error handler.
15732 (win32_target_ops) [!_WIN32_WCE]: Register
15733 hostio_last_error_from_errno as hostio_last_error handler.
15734 * Makefile.in (SFILES): Add hostio.c and hostio-errno.c.
15735 (hostio-errno.o): New rule.
15736 * configure.ac (GDBSERVER_DEPFILES): Add $srv_hostio_err_objs.
15737 * configure.srv (srv_hostio_err_objs): New variable. Default to
15738 hostio-errno.o.
15739 (arm*-*-mingw32ce*): Set srv_hostio_err_objs to "".
15740 * configure: Regenerate.
15741
15742 2008-01-29 Daniel Jacobowitz <dan@codesourcery.com>
15743
15744 * linux-low.c (linux_attach_lwp): Do not _exit after errors.
15745 (linux_kill, linux_detach): Clean up the process list.
15746 * remote-utils.c (remote_open): Improve port number parsing.
15747 (putpkt_binary, input_interrupt): Only send interrupts if the target
15748 is running.
15749 * server.c (extended_protocol): Make static.
15750 (attached): Define earlier.
15751 (exit_requested, response_needed, program_argv): New variables.
15752 (target_running): New.
15753 (start_inferior): Clear attached here.
15754 (attach_inferior): Set attached here.
15755 (require_running): Define.
15756 (handle_query): Use require_running and target_running. Implement
15757 "monitor exit".
15758 (handle_v_attach, handle_v_run): New.
15759 (handle_v_requests): Use require_running. Handle vAttach and vRun.
15760 (gdbserver_usage): Update.
15761 (main): Redo argument parsing. Handle --debug and --multi. Handle
15762 --attach along with other options or after the port. Save
15763 program_argv. Support no initial program. Resynchronize
15764 communication with GDB after an error. Handle "monitor exit".
15765 Use require_running and target_running. Always allow the extended
15766 protocol. Do not error out for Hc0 or Hc-1. Do not automatically
15767 restart in extended mode.
15768 * README: Refer to the GDB manual. Update --attach usage.
15769
15770 2007-12-20 Andreas Schwab <schwab@suse.de>
15771
15772 * linux-low.c (STACK_SIZE): Define.
15773 (linux_tracefork_child): Use it. Use __clone2 on ia64.
15774 (linux_test_for_tracefork): Likewise.
15775
15776 2007-12-18 Daniel Jacobowitz <dan@codesourcery.com>
15777
15778 * linux-low.c (linux_wait_for_event): Update messages. Do not
15779 reinsert auto-delete breakpoints.
15780 * mem-break.c (struct breakpoint): Change return type of handler to
15781 int.
15782 (set_breakpoint_at): Update handler type.
15783 (reinsert_breakpoint_handler): Return 1 instead of calling
15784 delete_breakpoint.
15785 (reinsert_breakpoint_by_bp): Check for the original breakpoint before
15786 setting a new one.
15787 (check_breakpoints): Delete auto-delete breakpoints and return 2.
15788 * mem-break.h (set_breakpoint_at): Update handler type.
15789 * thread-db.c (thread_db_create_event, thread_db_create_event): Update.
15790 * win32-low.c (auto_delete_breakpoint): New.
15791 (get_child_debug_event): Use it.
15792
15793 2007-12-16 Daniel Jacobowitz <dan@codesourcery.com>
15794
15795 * configure.ac: Check for pread and pwrite.
15796 * hostio.c (handle_pread): Fall back to lseek and read.
15797 (handle_pwrite): Fall back to lseek and write.
15798 * config.in, configure: Regenerated.
15799
15800 2007-12-07 Daniel Jacobowitz <dan@codesourcery.com>
15801
15802 * server.c (myresume): Add own_buf argument.
15803 (main): Update calls.
15804
15805 2007-12-06 Daniel Jacobowitz <dan@codesourcery.com>
15806
15807 * linux-low.c (linux_wait, linux_resume): Do not handle async I/O.
15808 * remote-utils.c (remote_open): Do not call disable_async_io.
15809 (block_async_io): Delete.
15810 (unblock_async_io): Make static.
15811 (initialize_async_io): New.
15812 * server.c (handle_v_cont): Handle async I/O here.
15813 (myresume): Likewise. Move other common resume tasks here...
15814 (main): ... from here. Call initialize_async_io. Disable async
15815 I/O before the main loop.
15816 * server.h (initialize_async_io): Declare.
15817 (block_async_io, unblock_async_io): Delete prototypes.
15818 * spu-low.c (spu_resume, spu_wait): Do not handle async I/O here.
15819
15820 2007-12-06 Mick Davis <mickd@goanna.iinet.net.au>
15821
15822 * remote-utils.c (readchar): Allow binary data in received messages.
15823
15824 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15825
15826 * win32-low.c (attaching): New global.
15827 (win32_create_inferior): Clear the `attaching' global.
15828 (win32_attach): Set the `attaching' global.
15829 (get_child_debug_event) [_WIN32_WCE]: Stop the inferior when
15830 attaching. Only set a breakpoint at the entry point if not
15831 attaching.
15832
15833 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15834
15835 * server.c (main): Don't report dll events on the initial
15836 connection on attaches.
15837
15838 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15839
15840 * server.c (main): Relax numerical bases supported for the pid of
15841 the --attach command line argument.
15842
15843 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15844
15845 * win32-low.c (win32_attach): Call OpenProcess before
15846 DebugActiveProcess, not after. Add last error output to error
15847 call.
15848
15849 2007-12-03 Pedro Alves <pedro_alves@portugalmail.pt>
15850
15851 * win32-low.c (win32_get_thread_context)
15852 (win32_set_thread_context): New functions.
15853 (thread_rec): Use win32_get_thread_context.
15854 (continue_one_thread, win32_resume): Use win32_set_thread_context.
15855 * win32-low.h (win32_thread_info) [_WIN32_WCE]: Add `base_context'
15856 field.
15857
15858 2007-12-03 Leo Zayas
15859 Pedro Alves <pedro_alves@portugalmail.pt>
15860
15861 * win32-low.c (soft_interrupt_requested, faked_breakpoint): New
15862 global variables.
15863 (child_add_thread): Minor cleanup.
15864 (child_continue): Resume artificially suspended threads before
15865 calling ContinueDebugEvent.
15866 (suspend_one_thread): New.
15867 (fake_breakpoint_event): New.
15868 (get_child_debug_event): Change return type to int. Check here if
15869 gdb sent an interrupt request. If a soft interrupt was requested,
15870 fake a breakpoint event. Return 0 if there is no event to handle,
15871 and 1 otherwise.
15872 (win32_wait): Don't check here if gdb sent an interrupt request.
15873 Ensure there is a valid event to handle.
15874 (win32_request_interrupt): Add soft interruption method as last
15875 resort.
15876
15877 2007-12-03 Leo Zayas
15878 Pedro Alves <pedro_alves@portugalmail.pt>
15879
15880 * win32-low.h (win32_thread_info): Add descriptions to the
15881 structure members. Replace `suspend_count' counter by a
15882 `suspended' flag.
15883 * win32-low.c (thread_rec): Update condition of when to get the
15884 context from the inferior. Rely on ContextFlags being set if it
15885 has already been retrieved. Only suspend the inferior thread if
15886 we haven't already. Warn if that fails.
15887 (continue_one_thread): s/suspend_count/suspended/. Only call
15888 ResumeThread once. Warn if that fails.
15889
15890 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15891
15892 * win32-low.c (win32_wait): Don't read from the inferior when it
15893 has already exited.
15894
15895 2007-12-02 Pedro Alves <pedro_alves@portugalmail.pt>
15896
15897 * Makefile.in (win32_low_h): New variable.
15898 (win32-low.o): Add dependency on $(win32_low_h).
15899 (win32-arm-low.o, win32-i386-low.o): New rules.
15900
15901 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15902
15903 * hostio.c: Correct copyright year.
15904
15905 2007-11-30 Daniel Jacobowitz <dan@codesourcery.com>
15906
15907 * Makefile.in (OBS): Add hostio.o.
15908 (hostio.o): New rule.
15909 * server.h (handle_vFile): Declare.
15910 * hostio.c: New file.
15911 * server.c (handle_v_requests): Take packet_len and new_packet_len
15912 for binary packets. Call handle_vFile.
15913 (main): Update call to handle_v_requests.
15914
15915 2007-11-05 Daniel Jacobowitz <dan@codesourcery.com>
15916
15917 * linux-low.c: Include <sched.h>.
15918
15919 2007-11-01 Daniel Jacobowitz <dan@codesourcery.com>
15920
15921 * linux-low.c (linux_tracefork_grandchild): New.
15922 (linux_tracefork_child): Use clone.
15923 (linux_test_for_tracefork): Use clone; allocate and free a stack.
15924
15925 2007-10-31 Joel Brobecker <brobecker@adacore.com>
15926
15927 * Makefile.in: Use $(SHELL) instead of "sh" to call regdat.sh.
15928
15929 2007-10-24 Daniel Jacobowitz <dan@codesourcery.com>
15930
15931 * linux-low.c (handle_extended_wait): Handle unexpected signals.
15932
15933 2007-10-23 Daniel Jacobowitz <dan@codesourcery.com>
15934
15935 * inferiors.c (change_inferior_id): Delete.
15936 (add_pid_to_list, pull_pid_from_list): New.
15937 * linux-low.c (PTRACE_SETOPTIONS, PTRACE_GETEVENTMSG)
15938 (PTRACE_O_TRACESYSGOOD, PTRACE_O_TRACEFORK, PTRACE_O_TRACEVFORK)
15939 (PTRACE_O_TRACECLONE, PTRACE_O_TRACEEXEC, PTRACE_O_TRACEVFORKDONE)
15940 (PTRACE_O_TRACEEXIT, PTRACE_EVENT_FORK, PTRACE_EVENT_VFORK)
15941 (PTRACE_EVENT_CLONE, PTRACE_EVENT_EXEC, PTRACE_EVENT_VFORK_DONE)
15942 (PTRACE_EVENT_EXIT, __WALL): Provide default definitions.
15943 (stopped_pids, thread_db_active, must_set_ptrace_flags): New variables.
15944 (using_threads): Always set to 1.
15945 (handle_extended_wait): New.
15946 (add_process): Do not set TID.
15947 (linux_create_inferior): Set must_set_ptrace_flags.
15948 (linux_attach_lwp): Remove TID argument. Do not check using_threads.
15949 Use PTRACE_SETOPTIONS. Call new_thread_notify. Update all callers.
15950 (linux_thread_alive): Rename TID argument to LWPID.
15951 (linux_wait_for_process): Handle unknown processes. Do not use TID.
15952 (linux_wait_for_event): Do not use TID or check using_threads. Update
15953 call to dead_thread_notify. Call handle_extended_wait.
15954 (linux_create_inferior): Use PTRACE_SETOPTIONS.
15955 (send_sigstop): Delete sigstop_sent.
15956 (wait_for_sigstop): Avoid TID.
15957 (linux_supports_tracefork_flag, linux_tracefork_child, my_waitpid)
15958 (linux_test_for_tracefork): New.
15959 (linux_lookup_signals): Use thread_db_active and
15960 linux_supports_tracefork_flag.
15961 (initialize_low): Use thread_db_active and linux_test_for_tracefork.
15962 * linux-low.h (get_process_thread): Avoid TID.
15963 (struct process_ifo): Move thread_known and tid to the end. Remove
15964 sigstop_sent.
15965 (linux_attach_lwp, thread_db_init): Update prototypes.
15966 * server.h (change_inferior_id): Delete prototype.
15967 (add_pid_to_list, pull_pid_from_list): New prototypes.
15968 * thread-db.c (thread_db_use_events): New.
15969 (find_first_thread): Rename to...
15970 (find_one_thread): ...this. Update callers and messages. Do not
15971 call fatal. Check thread_db_use_events. Do not call
15972 change_inferior_id or new_thread_notify.
15973 (maybe_attach_thread): Update. Do not call new_thread_notify.
15974 (thread_db_init): Set thread_db_use_events. Check use_events.
15975 * utils.c (fatal, warning): Correct message prefix.
15976
15977 2007-10-15 Daniel Jacobowitz <dan@codesourcery.com>
15978
15979 * Makefile.in (clean): Remove new files.
15980 (powerpc-32.o, powerpc-32.c, powerpc-e500.o, powerpc-e500.c)
15981 (powerpc-64.o, powerpc-64.c): New rules.
15982 * configure.srv: Use alternate register sets for powerpc64-*-linux*
15983 with AltiVec, powerpc-*-linux* with AltiVec, and powerpc-*-linux*
15984 with SPE.
15985 * linux-ppc-low.c (ppc_regmap): Do not fetch the FP registers for
15986 SPE targets.
15987 (ppc_cannot_store_register): Do not check for FPSCR for SPE targets.
15988 (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS, ppc_fill_vrregset)
15989 (ppc_store_vrregset, PTRACE_GETEVRREGS, PTRACE_SETEVRREGS)
15990 (struct gdb_evrregset_t, ppc_fill_evrregset, ppc_store_evrregset): New.
15991 (target_regsets): Add AltiVec and SPE register sets.
15992 * configure.ac: Check for AltiVec and SPE.
15993 * linux-ppc64-low.c (PTRACE_GETVRREGS, PTRACE_SETVRREGS, SIZEOF_VRREGS)
15994 (ppc_fill_vrregset, ppc_store_vrregset): New.
15995 (target_regsets): Add AltiVec register set.
15996 * configure: Regenerated.
15997
15998 2007-09-19 Daniel Jacobowitz <dan@codesourcery.com>
15999
16000 * linux-low.c (O_LARGEFILE): Define.
16001 (linux_read_memory): Use /proc/PID/mem.
16002 * configure.ac: Use AC_GNU_SOURCE. Check for pread64.
16003 * configure, config.in: Regenerated.
16004
16005 2007-09-04 Daniel Jacobowitz <dan@codesourcery.com>
16006
16007 * linux-low.c (linux_wait_for_event): Do not pass signals while
16008 single-stepping.
16009
16010 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16011
16012 * win32-low.c (create_process): New.
16013 (win32_create_inferior): Use create_process instead of
16014 CreateProcess. If create_process failed retry appending an ".exe"
16015 suffix. Store the GetLastError result immediatelly after
16016 create_process calls and use it on the call to error.
16017
16018 2007-09-03 Pedro Alves <pedro_alves@portugalmail.pt>
16019
16020 * win32-low.c (handle_load_dll): Don't use toolhelp when waiting.
16021
16022 2007-08-23 Joel Brobecker <brobecker@adacore.com>
16023
16024 * configure.ac: Switch license to GPLv3.
16025
16026 2007-08-01 Michael Snyder <msnyder@access-company.com>
16027
16028 * remote-utils.c (putpkt_binary): Memory leak, free buf2.
16029
16030 2007-07-31 Pedro Alves <pedro_alves@portugalmail.pt>
16031
16032 * win32-low.c (winapi_CloseToolhelp32Snapshot) [_WIN32_WCE]: New
16033 typedef.
16034 (win32_CloseToolhelp32Snapshot) [_WIN32_WCE]: New global var.
16035 (load_toolhelp) [_WIN32_WCE]: Load TOOLHELP.DLL. Get
16036 CloseToolhelp32Snapshot.
16037 (toolhelp_get_dll_name) [_WIN32_WCE]: Close the snapshot with
16038 CloseToolhelp32Snapshot.
16039
16040 2007-07-27 Michael Snyder <michael.snyder@access-company.com>
16041
16042 * server.c (main): Check for inferior exit before main loop.
16043
16044 2007-07-18 Pedro Alves <pedro_alves@portugalmail.pt>
16045
16046 * remote-utils.c (remote_open): Set SO_KEEPALIVE on remote_desc
16047 instead of on tmp_desc.
16048
16049 2007-07-17 Pedro Alves <pedro_alves@portugalmail.pt>
16050 Daniel Jacobowitz <dan@codesourcery.com>
16051
16052 * inferiors.c (all_dlls, dlls_changed, get_dll): New.
16053 (add_thread): Minor cleanups.
16054 (clear_inferiors): Move lower in the file. Clear the DLL
16055 list.
16056 (free_one_dll, match_dll, loaded_dll, unloaded_dll, clear_list): New.
16057 * remote-utils.c (prepare_resume_reply): Check dlls_changed.
16058 (xml_escape_text): New.
16059 * server.c (handle_query): Handle qXfer:libraries:read. Report it
16060 for qSupported.
16061 (handle_v_cont): Report errors.
16062 (gdbserver_version): Update.
16063 (main): Correct size of own_buf. Do not report initial DLL events.
16064 * server.h (struct dll_info, all_dlls, dlls_changed, loaded_dll)
16065 (unloaded_dll, xml_escape_text): New.
16066 * win32-low.c (enum target_waitkind): Update comments.
16067 (win32_add_one_solib, get_image_name, winapi_EnumProcessModules)
16068 (winapi_GetModuleInformation, winapi_GetModuleFileNameExA)
16069 (win32_EnumProcessModules, win32_GetModuleInformation)
16070 (win32_GetModuleFileNameExA, load_psapi, psapi_get_dll_name)
16071 (winapi_CreateToolhelp32Snapshot, winapi_Module32First)
16072 (winapi_Module32Next, win32_CreateToolhelp32Snapshot)
16073 (win32_Module32First, win32_Module32Next, load_toolhelp)
16074 (toolhelp_get_dll_name, handle_load_dll, handle_unload_dll): New.
16075 (get_child_debug_event): Handle DLL events.
16076 (win32_wait): Likewise.
16077
16078 2007-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16079
16080 * configure.srv: Set srv_linux_regsets for sh*-*-linux*.
16081 * linux-sh-low.c (sh_fill_gregset, target_regsets): New.
16082
16083 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16084
16085 * win32-low.c (handle_output_debug_string): Ignore event if not
16086 waiting.
16087
16088 2007-07-08 Pedro Alves <pedro_alves@portugalmail.pt>
16089
16090 * win32-arm-low.c (arm_wince_breakpoint): Fix typo.
16091
16092 2007-07-03 Daniel Jacobowitz <dan@codesourcery.com>
16093
16094 * remote-utils.c (look_up_one_symbol): Handle 'm' packets.
16095
16096 2007-07-02 Daniel Jacobowitz <dan@codesourcery.com>
16097
16098 * inferiors.c (change_inferior_id): Add comment.
16099 * linux-low.c (check_removed_breakpoint): Add an early
16100 prototype. Improve debug output.
16101 (linux_attach): Doc update.
16102 (linux_detach_one_process, linux_detach): Clean up before releasing
16103 each process.
16104 (send_sigstop, wait_for_sigstop): Improve comments and debug output.
16105 * linux-low.h (struct process_info): Doc improvement.
16106 * mem-break.c (delete_all_breakpoints): New.
16107 * mem-break.h (delete_all_breakpoints): New prototype.
16108 * thread-db.c (find_first_thread): New.
16109 (thread_db_create_event): Call it instead of
16110 thread_db_find_new_threads. Clean up unused variables.
16111 (maybe_attach_thread): Remove first thread handling.
16112 (thread_db_find_new_threads): Use find_first_thread.
16113 (thread_db_get_tls_address): Likewise.
16114
16115 2007-06-27 Daniel Jacobowitz <dan@codesourcery.com>
16116
16117 * thread-db.c (thread_db_find_new_threads): Add prototype.
16118 (thread_db_create_event): Check for the main thread before adding
16119 a new thread.
16120 (maybe_attach_thread): Only enable event reporting if TID == 0.
16121 (thread_db_get_tls_address): Check for new threads.
16122
16123 2007-06-20 Daniel Jacobowitz <dan@codesourcery.com>
16124
16125 * linux-low.c (linux_create_inferior): Try execv before execvp.
16126 * spu-low.c (spu_create_inferior): Likewise.
16127
16128 2007-06-13 Mike Frysinger <vapier@gentoo.org>
16129
16130 * linux-low.c (linux_create_inferior): Change execv to execvp.
16131 * spu-low.c (spu_create_inferior): Likewies.
16132
16133 2007-06-13 Daniel Jacobowitz <dan@codesourcery.com>
16134
16135 * Makefile.in (clean): Clean new files instead of deleted ones.
16136 (reg-mips.o, reg-mips.c, reg-mips64.o, reg-mips64.c): Delete.
16137 (mips-linux.o, mips-linux.c, mips64-linux.o, mips64-linux.c): New
16138 rules.
16139 * configure.srv: Specify XML files and new regformats for MIPS and
16140 MIPS64 GNU/Linux.
16141 * linux-mips-low.c (mips_num_regs): Set to only used registers.
16142 (mips_regmap): Do not fetch $0. Remove unused registers. Add
16143 an entry for the restart register.
16144 (mips_cannot_fetch_register, mips_cannot_store_register)
16145 (mips_reinsert_addr, mips_fill_fpregset, mips_store_fpregset): Update
16146 register names to match the XML descriptions.
16147 (mips_fill_gregset, mips_store_gregset): Likewise. Handle the
16148 restart register instead of $0.
16149
16150 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16151 Markus Deuling <deuling@de.ibm.com>
16152
16153 * remote-utils.c (decode_xfer_write): New function.
16154 * server.h (decode_xfer_write): Add prototype.
16155 * server.c (handle_query): Add PACKET_LEN argument. Support
16156 qXfer:spu:read and qXfer:spu:write packets.
16157 (main): Pass packet_len to handle_query.
16158 * spu-low.c (spu_target_ops): Add spu_proc_xfer_spu.
16159 * target.h (target_ops): Add qxfer_spu.
16160
16161 2007-06-12 Ulrich Weigand <uweigand@de.ibm.com>
16162
16163 * spu-low.c (spu_proc_xfer_spu): Do not return failure when
16164 accessing non-seekable spufs files.
16165
16166 2007-05-16 Markus Deuling <deuling@de.ibm.com>
16167
16168 * server.c (handle_query): Add reply for qC packet.
16169
16170 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16171 Leo Zayas <lerele@champenstudios@com>
16172
16173 * server.h (check_remote_input_interrupt_request): New function.
16174 * remote_utils.c (INVALID_DESCRIPTOR): New define.
16175 (remote_desc): Initialize with INVALID_DESCRIPTOR.
16176 (input_interrupt): Expose on USE_WIN32API too. Fix whitespace.
16177 (check_remote_input_interrupt_request): New function.
16178 * server.h (check_remote_input_interrupt_request): Declare.
16179 * win32-low.c (winapi_DebugBreakProcess,
16180 winapi_GenerateConsoleCtrlEvent): New typedefs.
16181 (get_child_debug_event): Lower Win32 debug event polling from 1 sec
16182 to 250 ms.
16183 (win32_wait): Check for remote interrupt request
16184 with check_remote_input_interrupt_request.
16185 (win32_request_interrupt): New function.
16186 (win32_target_op): Set request_interrupt to win32_request_interrupt.
16187
16188 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16189
16190 * win32-low.c (debug_registers_changed,
16191 debug_registers_used, CONTEXT_EXTENDED_REGISTERS,
16192 CONTEXT_FLOATING_POINT, CONTEXT_DEBUG_REGISTERS,
16193 CONTEXT_DEBUGGER, CONTEXT_DEBUGGER_DR): Delete.
16194 (thread_rec): Get context using the low target.
16195 (child_add_thread): Call thread_added on the low target,
16196 which does the same thing.
16197 (regptr): Delete.
16198 (do_initial_child_stuff): Remove debug registers references.
16199 Set context using the low target. Resume threads after
16200 setting the contexts.
16201 (child_continue): Remove dead variable. Remove debug
16202 registers references.
16203 (child_fetch_inferior_registers): Go through the low target.
16204 (do_child_store_inferior_registers): Remove.
16205 (child_store_inferior_registers): Go through the low target.
16206 (win32_resume): Remove debug registers references.
16207 Set context using the low target.
16208 (handle_exception): Change return type to void. Don't record
16209 context here. Set status to TARGET_WAITKIND_SPURIOUS on a
16210 first chance exception.
16211 (get_child_debug_event): Change return type to void. Remove
16212 goto loop. Always return after waiting for debug event.
16213 (win32_wait): Convert to switch statement. Handle spurious
16214 events.
16215
16216 * win32-i386-low.c (debug_registers_changed,
16217 debug_registers_used): New.
16218 (initial_stuff): Rename to ...
16219 (i386_initial_stuff): ... this. Clear debug registers
16220 state variables.
16221 (store_debug_registers): Delete.
16222 (i386_get_thread_context): New.
16223 (load_debug_registers): Delete.
16224 (i386_set_thread_context): New.
16225 (i386_thread_added): New.
16226 (single_step): Rename to ...
16227 (i386_single_step): ... this.
16228 (do_fetch_inferior_registers): Rename to ...
16229 (i386_fetch_inferior_register): ... this.
16230 (i386_store_inferior_register): New.
16231 (the_low_target): Adapt to new interface.
16232
16233 * win32-arm-low.c (CONTEXT_FLOATING_POINT): Define.
16234 (arm_get_thread_context): New.
16235 (arm_set_thread_context): New.
16236 (regptr): New.
16237 (do_fetch_inferior_registers): Rename to ...
16238 (arm_fetch_inferior_register): ... this.
16239 (arm_store_inferior_register): New.
16240 (arm_wince_breakpoint): Reimplement as unsigned long.
16241 (arm_wince_breakpoint_len): Define.
16242 (the_low_target): Adapt to new interface.
16243
16244 * win32-low.h (target_ops): Remove regmap, store_debug_registers and
16245 load_debug_registers. Add get_thread_context, set_thread_context,
16246 thread_added and store_inferior_register. Rename
16247 fetch_inferior_registers to fetch_inferior_register.
16248 (regptr): Remove declaration.
16249
16250 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16251
16252 * linux-low.c (linux_detach): Change return type to int. Return 0.
16253 * spu-low.c (spu_detach): Likewise.
16254
16255 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16256
16257 * target.h (target_ops): Change return type of detach to int.
16258 Add join.
16259 (join_inferior): New.
16260 * server.c (main): Don't skip detach support on mingw32.
16261 If the inferior doesn't support detaching return error.
16262 Call join_inferior instead of using waitpid.
16263 * linux-low.c (linux_join): New.
16264 (linux_target_op): Add linux_join.
16265 * spu-low.c (spu_join): New.
16266 (spu_target_ops): Add spu_join.
16267 * win32-low.c (win32_detach): Adapt to new interface.
16268 Reopen current_process_handle before detaching. Issue a child
16269 resume before detaching.
16270 (win32_join): New.
16271 (win32_target_op): Add win32_join.
16272
16273 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16274
16275 * win32-low.c (win32-attach): Fix return value.
16276 * target.h (target_ops): Describe ATTACH return values.
16277
16278 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16279
16280 * win32-low.c (GETPROCADDRESS): Define.
16281 (winapi_DebugActiveProcessStop): Add WINAPI. typedef as pointer.
16282 (winapi_DebugSetProcessKillOnExit): Likewise.
16283 (win32_create_inferior): Force usage of ansi CreateProcessA.
16284 (win32_attach): Use GETPROCADDRESS.
16285 (win32_detach): Likewise.
16286
16287 2007-05-10 Pedro Alves <pedro_alves@portugalmail.pt>
16288
16289 * win32-low.c (win32_wait): Don't use WSTOPSIG.
16290
16291 2007-03-30 Pedro Alves <pedro_alves@portugalmail.pt>
16292
16293 * win32-low.c: Commit leftover changes from 2007-03-29.
16294
16295 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16296
16297 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Make 16-bit
16298 fields short instead of int. Add explicit padding.
16299 (i387_cache_to_fsave): Remove unnecessary casts.
16300 (i387_fsave_to_cache): Doc fix.
16301 (i387_cache_to_fxsave): Remove unnecessary casts and masking.
16302
16303 2007-03-30 Daniel Jacobowitz <dan@codesourcery.com>
16304
16305 * i387-fp.c (i387_cache_to_fxsave): Reinitialize val2 before use.
16306 (i387_fxsave_to_cache): Check fp->ftag while building ftag value.
16307
16308 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16309
16310 * configure.srv (arm*-*-mingw32ce*): Move near the other
16311 arm targets.
16312
16313 2007-03-29 Pedro Alves <pedro_alves@portugalmail.pt>
16314
16315 * configure.ac: Add errno checking.
16316 (AC_CHECK_HEADERS): Add errno.h, fcntl.h, signal.h,
16317 sys/file.h and malloc.h.
16318 (AC_CHECK_DECLS): Add perror.
16319 (srv_mingwce): Handle.
16320 * configure.srv (i[34567]86-*-cygwin*): Add
16321 win32-i386-low.o to srv_tgtobj.
16322 (i[34567]86-*-mingw*): Likewise.
16323 (arm*-*-mingw32ce*): Add case.
16324 * gdbreplay.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16325 HAVE_FCNTL_H, HAVE_ERRNO_H, HAVE_MALLOC_H]: Check.
16326 [__MINGW32CE__] (strerror): New function.
16327 [__MINGW32CE__] (errno): Define to GetLastError.
16328 [__MINGW32CE__] (COUNTOF): New macro.
16329 (remote_open): Remove extra close call.
16330 * mem-break.c (delete_breakpoint_at): New function.
16331 * mem-break.h (delete_breakpoint_at): Declare.
16332 * remote-utils.c [HAVE_SYS_FILE_H, HAVE_SIGNAL_H,
16333 HAVE_FCNTL_H, HAVE_UNISTD_H, HAVE_ERRNO_H]: Check.
16334 [USE_WIN32API] (read, write): Add char* casts.
16335 * server.c [HAVE_UNISTD_H, HAVE_SIGNAL_H]: Check.
16336 * server.h: Include wincecompat.h on Windows CE.
16337 [HAVE_ERRNO_H]: Check.
16338 (perror): Declare if not declared.
16339 * utils.c: Add stdlib.h, errno.h and malloc.h includes.
16340 (perror_with_name): Remove errno declaration.
16341 * wincecompat.h: New.
16342 * wincecompat.c: New.
16343 * win32-low.h: New.
16344 * win32-arm-low.c: New.
16345 * win32-i386-low.c: New.
16346 (win32-low.c): Include mem-break.h and win32-low.h, and winnt.h.
16347 (OUTMSG2): Make it safe.
16348 (_T): New macro.
16349 (COUNTOF): New macro.
16350 (NUM_REGS): Get it from the low target.
16351 (CONTEXT_EXTENDED_REGISTERS, CONTEXT_FLOATING_POINT,
16352 CONTEXT_DEBUG_REGISTERS): Add fallbacks to 0.
16353 (thread_rec): Let low target handle debug registers.
16354 (child_add_thread): Likewise.
16355 (child_init_thread_list): Likewise.
16356 (continue_one_thread): Likewise.
16357 (regptr): New.
16358 (do_child_fetch_inferior_registers): Move to ...
16359 * win32-i386-low.c: ... here, and rename to ...
16360 (do_fetch_inferior_registers): ... this.
16361 * win32-low.c (child_fetch_inferior_registers):
16362 Go through the low target.
16363 (do_child_store_inferior_registers): Use regptr.
16364 (strwinerror): New function.
16365 (win32_create_inferior): Handle Windows CE.
16366 Use strwinerror instead of strerror on Windows error
16367 codes. Add program to the error output.
16368 Don't close the main thread handle on Windows CE.
16369 (win32_attach): Use coredll.dll on Windows CE.
16370 (win32_kill): Close current process and current
16371 thread handles.
16372 (win32_detach): Use coredll.dll on Windows CE.
16373 (win32_resume): Let low target handle debug registers, and
16374 step request.
16375 (handle_exception): Add/Remove initial breakpoint. Avoid
16376 non-existant WSTOPSIG on Windows CE.
16377 (win32_read_inferior_memory): Cast to remove warning.
16378 (win32_arch_string): Go through the low target.
16379 (initialize_low): Call set_breakpoint_data with the low
16380 target's breakpoint.
16381 * win32-low.c (dr, FLAG_TRACE_BIT, FCS_REGNUM,
16382 FOP_REGNUM, mappings): Move to ...
16383 * win32-i386-low.c: ... here.
16384 * win32-low.c (win32_thread_info): Move to ...
16385 * win32-low.h: ... here.
16386 * Makefile.in (SFILES): Add win32-low.c, win32-i386-low.c,
16387 win32-arm-low.c and wincecompat.c.
16388 (all:): Add $EXEEXT.
16389 (install-only:): Likewise.
16390 (gdbserver:): Likewise.
16391 (gdbreplay:): Likewise.
16392 * config.in: Regenerate.
16393 * configure: Regenerate.
16394
16395 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16396
16397 * win32-low.c: Rename typedef thread_info to
16398 win32_thread_info throughout.
16399
16400 2007-03-28 Pedro Alves <pedro_alves@portugalmail.pt>
16401
16402 * win32-i386-low.c: Rename to ...
16403 * win32-low.c: ... this.
16404 * configure.srv: Replace win32-i386-low.o with win32-low.o.
16405 * Makefile.in: Likewise.
16406
16407 2007-03-27 Pedro Alves <pedro_alves@portugalmail.pt>
16408
16409 * remote-utils.c (monitor_output): Constify msg parameter.
16410 * server.h (monitor_output): Likewise.
16411 * win32-i386-low.c (handle_output_debug_string): New.
16412 (win32_kill): Handle OUTPUT_DEBUG_STRING_EVENT events using
16413 handle_output_debug_string.
16414 (get_child_debug_event): Likewise.
16415
16416 2007-03-27 Mat Hostetter <mat@lcs.mit.edu>
16417
16418 * server.c (main): Correct strtoul check.
16419
16420 2007-03-27 Jon Ringle <jon@ringle.org>
16421
16422 * linux-low.c: Check __ARCH_HAS_MMU__ also.
16423
16424 2007-03-27 Brooks Moses <brooks.moses@codesourcery.com>
16425
16426 * Makefile.in: Add dummy "pdf" and "install-pdf" targets.
16427
16428 2007-02-27 Daniel Jacobowitz <dan@codesourcery.com>
16429
16430 * terminal.h: Check HAVE_SGTTY_H.
16431
16432 2007-02-27 Mat Hostetter <mat@lcs.mit.edu>
16433
16434 * remote-utils.c (remote_open): Print out the assigned port number.
16435
16436 2007-02-26 Daniel Jacobowitz <dan@codesourcery.com>
16437
16438 * remote-utils.c (monitor_output): New function.
16439 * server.c (debug_threads): Define here.
16440 (monitor_show_help): New function.
16441 (handle_query): Handle qRcmd.
16442 (main): Do not handle 'd' packet.
16443 * server.h (debug_threads, remote_debug, monitor_output): Declare.
16444 * linux-low.c, spu-low.c, win32-i386-low.c: Remove definitions
16445 of debug_threads.
16446
16447 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16448
16449 * Makefile.in (EXEEXT): New.
16450 (clean): Use $(EXEEXT).
16451
16452 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16453
16454 * target.h (target_ops): Rename send_signal to request_interrupt,
16455 and remove enum target_signal parameter.
16456 * linux-low.c (linux_request_interrupt): Rename from
16457 linux_send_signal, and always send SIGINT.
16458 * spu-low.c (spu_request_interrupt): Rename from spu_send_signal,
16459 and always send SIGINT.
16460 * remote-utils.c (putpkt_binary): Call request_interrupt, instead
16461 of send_signal.
16462 (input_interrupt): Likewise.
16463
16464 2007-02-25 Pedro Alves <pedro_alves@portugalmail.pt>
16465
16466 * server.c (get_features_xml): Check if target implemented
16467 arch_string.
16468 * win32-i386-low.c (win32_arch_string): New.
16469 (win32_target_ops): Add win32_arch_string as arch_string member.
16470
16471 2007-02-22 Markus Deuling <deuling@de.ibm.com>
16472
16473 * spu-low.c (spu_arch_string): New.
16474 (spu_target_ops): Add spu_arch_string.
16475
16476 2007-02-16 Daniel Jacobowitz <dan@codesourcery.com>
16477
16478 * remote-utils.c: Remove HAVE_TERMINAL_H check.
16479 * configure.ac: Do not check for terminal.h.
16480 * configure, config.in: Regenerated.
16481
16482 2007-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16483
16484 * Makefile.in (OBS): Add $(XML_BUILTIN).
16485 (XML_DIR, XML_TARGET, XML_FILES, XML_BUILTIN): New.
16486 (clean): Update.
16487 (target.xml, xml-builtin.c, stamp-xml, arm-with-iwmmxt.o)
16488 (arm-with-iwmmxt.c): New.
16489 * config.in, configure: Regenerate.
16490 * configure.ac: Check for iWMMXt. Handle srv_xmltarget,
16491 srv_xmlbuiltin, and srv_xmlfiles. Define USE_XML.
16492 * configure.srv: Mention srv_xmltarget and srv_xmlfiles.
16493 (arm*-*-linux*): Add iWMMXt and regset support.
16494 * linux-arm-low.c (PTRACE_GETWMMXREGS, PTRACE_SETWMMXREGS): Define.
16495 (arm_fill_gregset, arm_store_gregset, arm_fill_wmmxregset)
16496 (arm_store_wmmxregset, target_regsets): New.
16497 * server.c (get_features_xml): Take annex argument. Check builtin
16498 XML documents.
16499 (handle_query): Handle multiple annexes.
16500
16501 2007-01-29 Daniel Jacobowitz <dan@codesourcery.com>
16502
16503 * remote-utils.c [USE_WIN32API] (read, write): Define.
16504 (putpkt_binary, input_interrupt, readchar, getpkt): Use read and
16505 write.
16506
16507 2007-01-09 Daniel Jacobowitz <dan@codesourcery.com>
16508
16509 * linux-i386-low.c (the_low_target): Set arch_string.
16510 * linux-x86-64-low.c (the_low_target): Likewise.
16511 * linux-low.c (linux_arch_string): New.
16512 (linux_target_ops): Add it.
16513 * linux-low.h (struct linux_target_ops): Add arch_string.
16514 * server.c (write_qxfer_response): Use const void * for DATA.
16515 (get_features_xml): New.
16516 (handle_query): Handle qXfer:features:read. Report it for qSupported.
16517 * target.h (struct target_ops): Add arch_string method.
16518
16519 2007-01-03 Denis Pilat <denis.pilat@st.com>
16520 Daniel Jacobowitz <dan@codesourcery.com>
16521
16522 * linux-low.c (linux_kill): Handle being called with no threads.
16523 * win32-i386-low.c (win32_kill): Likewise.
16524 (get_child_debug_event): Clear current_process_handle.
16525
16526 2006-12-30 Denis PILAT <denis.pilat@st.com>
16527 Daniel Jacobowitz <dan@codesourcery.com>
16528
16529 * remote-utils.c (remote_open): Check the type of specified
16530 serial port devices before opening them.
16531 * server.c (main): Kill the inferior if an error occurs during
16532 the first remote_open.
16533
16534 2006-12-05 Markus Deuling <deuling@de.ibm.com>
16535
16536 * README: Update supported targets.
16537
16538 2006-11-28 Daniel Jacobowitz <dan@codesourcery.com>
16539
16540 * Makefile.in (clean): Remove reg-mips64.c.
16541 (reg-mips64.c, reg-mips64.o): New rules.
16542 * configure.srv: Handle mips64. Include regset support for mips.
16543 * linux-mips-low.c (union mips_register): New.
16544 (mips_get_pc, mips_set_pc, mips_reinsert_addr): Use it.
16545 (mips_breakpoint, mips_breakpoint_at): Use int.
16546 (mips_collect_register, mips_supply_register)
16547 (mips_collect_register_32bit, mips_supply_register_32bit)
16548 (mips_fill_gregset, mips_store_gregset, mips_fill_fpregset)
16549 (mips_store_fpregset, target_regsets): New.
16550 * thread-db.c (thread_db_get_tls_address): Use uintptr_t.
16551
16552 2006-11-22 Ulrich Weigand <uweigand@de.ibm.com>
16553
16554 * configure.srv: Add target "spu*-*-*".
16555 * Makefile.in (clean): Remove reg-spu.c.
16556 (reg-spu.c, reg-spu.o, spu-low.o): Add dependencies.
16557 * spu-low.c: New file.
16558
16559 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16560
16561 * configure.ac: Correct td_thr_tls_get_addr test.
16562 * configure: Regenerated.
16563
16564 2006-11-16 Daniel Jacobowitz <dan@codesourcery.com>
16565
16566 * linux-low.c (linux_wait_for_event): Reformat. Use the
16567 pass_signals array.
16568 * remote-utils.c (decode_address_to_semicolon): New.
16569 * server.c (pass_signals, handle_general_set): New.
16570 (handle_query): Mention QPassSignals for qSupported.
16571 (main): Call handle_general_set.
16572 * server.h (pass_signals, decode_address_to_semicolon): New.
16573
16574 2006-11-06 Daniel Jacobowitz <dan@codesourcery.com>
16575
16576 * server.c (handle_query): Correct error handling for read_auxv.
16577
16578 2005-10-19 Ulrich Weigand <uweigand@de.ibm.com>
16579
16580 * configure.srv [s390-*-linux*, s390x-*-linux*]: Set srv_linux_regsets
16581 and srv_linux_thread_db to yes.
16582 * linux-s390-low.c (s390_fill_gregset): New function.
16583 (target_regsets): Define data structure.
16584
16585 2006-10-17 Daniel Jacobowitz <dan@codesourcery.com>
16586
16587 * acinclude.m4 (SRV_CHECK_TLS_GET_ADDR): New.
16588 * configure.ac: Use it. Define HAVE_TD_THR_TLS_GET_ADDR.
16589 * config.in, configure: Regenerated.
16590 * inferiors.c (gdb_id_to_thread): New function.
16591 (gdb_id_to_thread_id): Use it.
16592 * linux-low.c (linux_target_ops): Use thread_db_get_tls_address.
16593 * linux-low.h (struct process_info): Add th member.
16594 (thread_db_get_tls_address): New prototype.
16595 * remote-utils.c (decode_address): Make non-static.
16596 * server.c (handle_query): Handle qGetTLSAddr.
16597 * server.h (gdb_id_to_thread, decode_address): New prototypes.
16598 * target.h (struct target_ops): Add get_tls_address.
16599 * thread-db.c (maybe_attach_thread): Save the thread handle.
16600 (thread_db_get_tls_address): New.
16601
16602 2006-09-28 Daniel Jacobowitz <dan@codesourcery.com>
16603
16604 * linux-low.c (PTRACE_GETSIGINFO, PTRACE_SETSIGINFO): Define.
16605 (linux_resume_one_process): Take a siginfo_t *. Update all
16606 callers. Queue it if necessary. Use PTRACE_SETSIGINFO.
16607 (struct pending_signals): Add a siginfo_t.
16608 (linux_wait_for_process): Always set last_status.
16609 (linux_wait_for_event): Use PTRACE_GETSIGINFO.
16610 (linux_queue_one_thread): Use PTRACE_GETSIGINFO.
16611 * linux-low.h (struct process_info): Add last_status.
16612
16613 2006-09-21 Daniel Jacobowitz <dan@codesourcery.com>
16614
16615 * remote-utils.c (try_rle): New function.
16616 (putpkt_binary): Use it.
16617
16618 2006-08-19 Daniel Jacobowitz <dan@codesourcery.com>
16619
16620 * Makefile.in (clean): Clean reg-x86-64-linux.c.
16621 (reg-x86-64-linux.o, reg-x86-64-linux.c): New.
16622 * configure.srv (x86_64-*-linux*): Use reg-x86-64-linux.o.
16623 * linux-x86-64-low.c (x86_64_regmap): Include ORIG_RAX.
16624 (x86_64_fill_gregset, x86_64_store_gregset): Skip floating
16625 point registers.
16626
16627 2006-08-08 Richard Sandiford <richard@codesourcery.com>
16628
16629 * server.c (terminal_fd): New variable.
16630 (old_foreground_pgrp): Likewise.
16631 (restore_old_foreground_pgrp): New function.
16632 (start_inferior): Record the terminal file descriptor in terminal_fd
16633 and its original foreground group in old_foreground_pgrp. Register
16634 restore_old_foreground_pgrp with atexit().
16635
16636 2006-07-26 Daniel Jacobowitz <dan@codesourcery.com>
16637
16638 * server.c (handle_query): Correct qPart to qXfer.
16639
16640 2006-07-22 Daniel Jacobowitz <dan@codesourcery.com>
16641
16642 * configure.ac: Check for more headers which are missing on
16643 Windows. Automatically supply -lwsock32 and USE_WIN32API.
16644 * configure.srv: Add Cygwin and mingw32.
16645 * remote-utils.c: Don't include headers unconditionally which
16646 are missing on mingw32. Include <winsock.h> for mingw32.
16647 (remote_open): Adjust for mingw32 support. Flush
16648 standard error after writing to it.
16649 (remote_close, putpkt_binary, input_interrupt, block_async_io)
16650 (unblock_async_io, enable_async_io, disable_async_io)
16651 (readchar, getpkt): Update for Winsock support.
16652 (prepare_resume_reply): Expect a protocol signal number.
16653 * server.c: Disable <sys/wait.h> on mingw32.
16654 (start_inferior): Adjust for mingw32 support. Flush
16655 standard error after writing to it.
16656 (attach_inferior): Likewise. Use protocol signal
16657 numbers.
16658 (main): Skip 'D' packet on mingw32. Use protocol signal numbers
16659 and names.
16660 * win32-i386-low.c: New file.
16661 * Makefile.in (XM_CLIBS): Set.
16662 (gdbserver, gdbreplay): Use $(INTERNAL_CFLAGS).
16663 (win32-i386-low.o): New dependency rule.
16664 * linux-low.c (linux_wait): Use target signal numbers.
16665 * target.h (struct target_ops): Doc fix.
16666 * server.h (target_signal_to_name): New prototype.
16667 * gdbreplay.c: Don't include headers unconditionally which
16668 are missing on mingw32. Include <winsock.h> for mingw32.
16669 (remote_close, remote_open): Adjust for Winsock support.
16670 * configure, config.in: Regenerated.
16671
16672 2006-07-12 Daniel Jacobowitz <dan@codesourcery.com>
16673
16674 * server.c (decode_xfer_read, write_qxfer_response): New.
16675 (handle_query): Take a packet length argument. Handle
16676 qXfer:auxv:read instead of qPart:auxv:read. Mention it in
16677 the qSupported response.
16678 (main): Update call to handle_query.
16679
16680 2006-06-22 Daniel Jacobowitz <dan@codesourcery.com>
16681
16682 * remote-utils.c (remote_escape_output, remote_unescape_input): New.
16683 (putpkt_binary): Renamed from putpkt and adjusted for binary
16684 data.
16685 (putpkt): New wrapper for putpkt_binary.
16686 (readchar): Don't mask off the high bit.
16687 (decode_X_packet): New function.
16688 * server.c (main): Call putpkt_binary if a handler sets the packet
16689 length. Save the length of the incoming packet. Handle 'X'.
16690 * server.h (gdb_byte, remote_escape_output, decode_X_packet): New.
16691
16692 2006-06-21 Daniel Jacobowitz <dan@codesourcery.com>
16693
16694 * server.c (handle_query): Handle qSupported.
16695
16696 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16697
16698 * remote-utils.c (all_symbols_looked_up): New variable.
16699 (look_up_one_symbol): Check it.
16700 * server.h (look_up_one_symbol): New declaration.
16701 * thread-db.c (thread_db_init): Set all_symbols_looked_up.
16702
16703 2006-05-30 Daniel Jacobowitz <dan@codesourcery.com>
16704
16705 * Makefile.in (linux-arm-low.o): Update dependencies.
16706 * linux-arm-low.c: Include "gdb_proc_service.h".
16707 (PTRACE_GET_THREAD_AREA): Define.
16708 (ps_get_thread_area): New function.
16709
16710 2006-05-09 Nathan Sidwell <nathan@codesourcery.com>
16711
16712 * configure.srv (m68k*-*-uclinux*): New target.
16713 * linux-low.c (linux_create_inferior): Use vfork on mmuless systems.
16714 (linux_resume_one_process): Remove extraneous cast.
16715 (linux_read_offsets): New.
16716 (linux_target_op): Add linux_read_offsets on mmuless systems.
16717 * server.c (handle_query): Add qOffsets logic.
16718 * target.h (struct target_ops): Add read_offsets.
16719
16720 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16721
16722 * linux-mips-low.c: Include <sys/ptrace.h> and "gdb_proc_service.h".
16723 (PTRACE_GET_THREAD_AREA): Define.
16724 (ps_get_thread_area): New function.
16725 * Makefile.in (linux-i386-low.o, linux-mips-low.o)
16726 (linux-x86-64-low.o): Update.
16727
16728 2006-03-15 Daniel Jacobowitz <dan@codesourcery.com>
16729
16730 * configure.ac: Remove checks for prfpregset_t.
16731 * gdb_proc_service.h: New file.
16732 * linux-i386-low.c, linux-x86-64-low.c, thread-db.c: Use the
16733 new "gdb_proc_service.h".
16734 * proc-service.c: Likewise.
16735 (ps_pglobal_lookup, ps_pdread, ps_pdwrite): Use psaddr_t.
16736 (ps_lgetfpregs, ps_lsetfpregs): Use a void* argument.
16737 * Makefile.in (gdb_proc_service_h): Updated.
16738 * configure, config.in: Regenerated.
16739
16740 2006-03-03 Daniel Jacobowitz <dan@codesourcery.com>
16741
16742 * remote-utils.c (prepare_resume_reply): Move declaration
16743 of gdb_id_from_wait to the top of the block.
16744
16745 2006-02-15 Daniel Jacobowitz <dan@codesourcery.com>
16746
16747 * linux-low.c (regsets_store_inferior_registers): Read the regset
16748 from the target before filling it.
16749
16750 2006-02-08 Daniel Jacobowitz <dan@codesourcery.com>
16751
16752 * server.c (attach_inferior): Return SIGTRAP for a successful
16753 attach.
16754
16755 2006-02-01 Daniel Jacobowitz <dan@codesourcery.com>
16756
16757 * Makefile.in (OBS): Add version.o.
16758 (STAGESTUFF): Delete.
16759 (version.o): Add dependencies.
16760 (version.c): Replace rule.
16761 (clean): Remove version.c.
16762 * server.c (gdbserver_version): New.
16763 (gdbserver_usage): Use printf.
16764 (main): Handle --version and --help.
16765 * server.h (version, host_name): Add declarations.
16766
16767 2005-12-23 Eli Zaretskii <eliz@gnu.org>
16768
16769 * linux-arm-low.c:
16770 * linux-arm-low.c:
16771 * inferiors.c:
16772 * i387-fp.h:
16773 * i387-fp.c:
16774 * gdbreplay.c:
16775 * regcache.c:
16776 * proc-service.c:
16777 * mem-break.h:
16778 * mem-break.c:
16779 * linux-x86-64-low.c:
16780 * linux-sh-low.c:
16781 * linux-s390-low.c:
16782 * linux-ppc64-low.c:
16783 * linux-ppc-low.c:
16784 * linux-mips-low.c:
16785 * linux-m68k-low.c:
16786 * linux-m32r-low.c:
16787 * linux-low.h:
16788 * linux-low.c:
16789 * linux-ia64-low.c:
16790 * linux-i386-low.c:
16791 * linux-crisv32-low.c:
16792 * thread-db.c:
16793 * terminal.h:
16794 * target.h:
16795 * target.c:
16796 * server.h:
16797 * server.c:
16798 * remote-utils.c:
16799 * regcache.h:
16800 * utils.c:
16801 * Makefile.in:
16802 * configure.ac:
16803 * gdbserver.1: Add (C) after Copyright. Update the FSF
16804 address.
16805
16806 2005-11-13 Daniel Jacobowitz <dan@codesourcery.com>
16807
16808 * linux-arm-low.c (arm_eabi_breakpoint): New variable.
16809 (arm_breakpoint_at): Recognize both breakpoints.
16810 (the_low_target): Use the correct breakpoint instruction.
16811
16812 2005-11-02 Daniel Jacobowitz <dan@codesourcery.com>
16813
16814 * configure.srv (x86_64-*-linux*): Turn on thread_db support.
16815 * linux-x86-64-low.c (x86_64_breakpoint, x86_64_breakpoint_len)
16816 (x86_64_get_pc, x86_64_set_pc, x86_64_breakpoint_at): New.
16817 (the_low_target): Update.
16818
16819 2005-10-25 Andreas Schwab <schwab@suse.de>
16820
16821 * server.c (main): Allocate mem_buf with PBUFSIZ bytes.
16822
16823 * linux-ia64-low.c (ia64_regmap): Remove NAT registers.
16824 (ia64_num_regs): Reduce to 462.
16825
16826 2005-09-17 Daniel Jacobowitz <dan@codesourcery.com>
16827
16828 * acinclude.m4: Correct quoting.
16829 * aclocal.m4: Regenerated.
16830
16831 Suggested by SZOKOVACS Robert <szo@ies.hu>:
16832 * thread-db.c (thread_db_err_str): Handle TD_VERSION.
16833 (thread_db_init): Call thread_db_err_str.
16834 * configure.ac: Check for TD_VERSION.
16835 * config.in, configure: Regenerated.
16836
16837 2005-07-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
16838
16839 * server.h (error, fatal, warning): Add ATTR_FORMAT.
16840
16841 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16842
16843 * configure.ac: Define HAVE_LINUX_REGSETS even if PTRACE_GETREGS
16844 is not available. Define HAVE_PTRACE_GETREGS if it is.
16845 * config.in, configure: Regenerated.
16846 * configure.srv: Set srv_linux_regsets for PowerPC and PowerPC64.
16847 * linux-i386-low.c, linux-m68k-low.c: Update to use
16848 HAVE_PTRACE_GETREGS.
16849 * linux-low.c (regsets_fetch_inferior_registers)
16850 (regsets_store_inferior_registers): Only return 0 if we processed
16851 GENERAL_REGS.
16852 * linux-ppc-low.c (ppc_fill_gregset, target_regsets): New.
16853 * linux-ppc64-low.c (ppc_fill_gregset, target_regsets): New.
16854
16855 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16856
16857 * inferiors.c (struct thread_info): Add gdb_id.
16858 (add_thread): Add gdb_id argument.
16859 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New.
16860 * linux-low.c (linux_create_inferior, linux_attach_lwp): Update
16861 calls to add_thread.
16862 * remote-utils.c (prepare_resume_reply: Use thread_to_gdb_id.
16863 * server.c (handle_query): Use thread_to_gdb_id.
16864 (handle_v_cont, main): Use gdb_id_to_thread_id.
16865 * server.h (add_thread): Update prototype.
16866 (thread_id_to_gdb_id, thread_to_gdb_id, gdb_id_to_thread_id): New
16867 prototypes.
16868
16869 2005-07-13 Daniel Jacobowitz <dan@codesourcery.com>
16870
16871 * linux-low.c (fetch_register, usr_store_inferior_registers): Handle
16872 left-padded registers.
16873 * linux-low.h (struct linux_target_ops): Add left_pad_xfer.
16874 * linux-ppc64-low.c (the_low_target): Set left_pad_xfer.
16875
16876 2005-07-01 Steve Ellcey <sje@cup.hp.com>
16877
16878 * configure.ac (BFD_NEED_DECLARATION): Replace with AC_CHECK_DECLS.
16879 * configure: Regenerate.
16880 * config.in: Regenerate.
16881 * server.h (NEED_DECLARATION_STRERROR):
16882 Replace with !HAVE_DECL_STRERROR.
16883
16884 2005-06-16 Daniel Jacobowitz <dan@codesourcery.com>
16885
16886 * linux-low.c (linux_wait, linux_send_signal): Don't test
16887 an unsigned long variable for > 0 if it could be MAX_ULONG.
16888 * server.c (myresume): Likewise.
16889 * target.c (set_desired_inferior): Likewise.
16890
16891 2005-06-13 Mark Kettenis <kettenis@gnu.org>
16892
16893 * configure.ac: Simplify and improve check for socklen_t.
16894 * configure, config.in: Regenerate.
16895
16896 2005-06-12 Daniel Jacobowitz <dan@codesourcery.com>
16897
16898 * acconfig.h: Remove.
16899 * configure.ac: Add a test for socklen_t. Use three-argument
16900 AC_DEFINE throughout.
16901 * config.in: Regenerated using autoheader 2.59.
16902 * configure: Regenerated.
16903
16904 * gdbreplay.c (socklen_t): Provide a default.
16905 (remote_open): Use socklen_t.
16906 * remote-utils.c (socklen_t): Provide a default.
16907 (remote_open): Use socklen_t.
16908 (convert_int_to_ascii, convert_ascii_to_int, decode_M_packet): Use
16909 unsigned char.
16910
16911 * i387-fp.c (struct i387_fsave, struct i387_fxsave): Use unsigned
16912 char for buffers.
16913 * linux-low.c (linux_read_memory, linux_write_memory)
16914 (linux_read_auxv): Likewise.
16915 * mem-break.c (breakpoint_data, set_breakpoint_data, check_mem_read)
16916 (check_mem_write): Likewise.
16917 * mem-break.h (set_breakpoint_data, check_mem_read, check_mem_write):
16918 Likewise.
16919 * regcache.c (struct inferior_rgcache_data, registers_to_string)
16920 (registers_from_string, register_data): Likewise.
16921 * server.c (handle_query, main): Likewise.
16922 * server.h (convert_ascii_to_int, convert_int_to_ascii)
16923 (decode_M_packet): Likewise.
16924 * target.c (read_inferior_memory, write_inferior_memory): Likewise.
16925 * target.h (struct target_ops): Update read_memory, write_memory,
16926 and read_auxv.
16927 (read_inferior_memory, write_inferior_memory): Update.
16928 * linux-low.h (struct linux_target_ops): Change type of breakpoint
16929 to unsigned char *.
16930 * linux-arm-low.c, linux-cris-low.c, linux-crisv32-low.c,
16931 linux-i386-low.c, linux-m32r-low.c, linux-m68k-low.c,
16932 linux-mips-low.c, linux-ppc-low.c, linux-ppc64-low.c,
16933 linux-s390-low.c, linux-sh-low.c: Update for changes in
16934 read_inferior_memory and the_low_target->breakpoint.
16935
16936 2005-05-28 Daniel Jacobowitz <dan@codesourcery.com>
16937
16938 * Makefile.in (SFILES): Add linux-ppc64-low.c.
16939 (linux-ppc64-low.o, reg-ppc64.c, reg-ppc64.o): New targets.
16940 * configure.srv: Add powerpc64-*-linux*.
16941 * linux-ppc64-low.c: New file.
16942
16943 2005-05-23 Orjan Friberg <orjanf@axis.com>
16944
16945 * linux-cris-low.c: New file with support for CRIS.
16946 * linux-crisv32-low.c: Ditto for CRISv32.
16947 * Makefile.in (SFILES): Add linux-cris-low.c, linux-crisv32-low.c.
16948 (clean): Add reg-cris.c and reg-crisv32.c.
16949 Add linux-cris-low.o, linux-crisv32-low.o, reg-cris.o, reg-cris.c,
16950 reg-crisv32.o, and reg-crisv32.c to make rules.
16951 * configure.srv: Add cris-*-linux* and crisv32-*-linux* to list of
16952 recognized targets.
16953
16954 2005-05-16 Ulrich Weigand <uweigand@de.ibm.com>
16955
16956 * linux-low.c (fetch_register): Ensure buffer size is a multiple
16957 of sizeof (PTRACE_XFER_TYPE).
16958 (usr_store_inferior_registers): Likewise. Zero out excess bytes.
16959
16960 2005-05-12 Orjan Friberg <orjanf@axis.com>
16961
16962 * target.h (struct target_ops): Add insert_watchpoint,
16963 remove_watchpoint, stopped_by_watchpoint, stopped_data_address function
16964 pointers for hardware watchpoint support.
16965 * linux-low.h (struct linux_target_ops): Ditto.
16966 * linux-low.c (linux_insert_watchpoint, linux_remove_watchpoint)
16967 (linux_stopped_by_watchpoint, linux_stopped_data_address): New. Add
16968 to linux_target_ops.
16969 * remote-utils.c (prepare_resume_reply): Add watchpoint information to
16970 reply packet.
16971 * server.c (main): Recognize 'Z' and 'z' packets.
16972
16973 2005-05-10 Ulrich Weigand <uweigand@de.ibm.com>
16974
16975 * linux-s390-low.c (s390_breakpoint, s390_breakpoint_len): Define.
16976 (s390_get_pc, s390_set_pc, s390_breakpoint_at): New functions.
16977 (the_low_target): Add new members.
16978
16979 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16980
16981 * proc-service.c (ps_lgetregs): Search all_processes instead of
16982 all_threads.
16983
16984 2005-05-04 Daniel Jacobowitz <dan@codesourcery.com>
16985
16986 * server.c (start_inferior): Change return type to int.
16987 (attach_inferior): Change sigptr to int *.
16988 (handle_v_cont, handle_v_requests): Change signal to int *.
16989 (main): Change signal to int.
16990
16991 2005-04-15 Kei Sakamoto <sakamoto.kei@renesas.com>
16992
16993 * Makefile.in: Add linux-m32r-low.o, reg-m32r.c and reg-m32r.o.
16994 * configure.srv: Add m32r*-*-linux*.
16995 * linux-m32r-low.c: New file.
16996
16997 2005-03-04 Daniel Jacobowitz <dan@codesourcery.com>
16998
16999 * Makefile.in (stamp-h): Set CONFIG_HEADERS explicitly.
17000
17001 2005-03-03 Daniel Jacobowitz <dan@codesourcery.com>
17002
17003 * inferiors.c (change_inferior_id, add_thread, find_inferior_id):
17004 Take unsigned long arguments for PIDs.
17005 * linux-low.c (add_process, linux_attach_lwp, linux_attach)
17006 (linux_thread_alive, linux_wait_for_event, kill_lwp, send_sigstop)
17007 (wait_for_sigstop, linux_resume_one_process)
17008 (regsets_fetch_inferior_registers, linux_send_signal)
17009 (linux_read_auxv): Likewise. Update the types of variables holding
17010 PIDs. Update format string specifiers.
17011 * linux-low.h (struct process_info, linux_attach_lwp): Likewise.
17012 * remote-utils.c (prepare_resume_reply): Likewise.
17013 * server.c (cont_thread, general_thread, step_thread)
17014 (thread_from_wait, old_thread_from_wait, signal_pid): Change type to
17015 unsigned long.
17016 (handle_query): Update format specifiers.
17017 (handle_v_cont, main): Use strtoul for thread IDs.
17018 * server.h (struct inferior_list_entry): Use unsigned long for ID.
17019 (add_thread, find_inferior_id, change_inferior_id, cont_thread)
17020 (general_thread, step_thread, thread_from_wait)
17021 (old_thread_from_wait): Update.
17022 * target.h (struct thread_resume): Use unsigned long for THREAD.
17023 (struct target_ops): Use unsigned long for arguments to attach and
17024 thread_alive.
17025
17026 2005-02-24 Daniel Jacobowitz <dan@codesourcery.com>
17027
17028 * acinclude.m4: Include bfd/bfd.m4 directly.
17029 * configure.ac: Use AC_ARG_PROGRAM. Suggested by Aron Griffis
17030 <agriffis@toolchain.org>.
17031 * aclocal.m4, configure: Regenerated.
17032
17033 2005-01-07 Andrew Cagney <cagney@gnu.org>
17034
17035 * configure.ac: Rename configure.in, require autoconf 2.59.
17036 * configure: Re-generate.
17037
17038 2004-12-08 Daniel Jacobowitz <dan@debian.org>
17039
17040 * acinclude.m4 (SRV_CHECK_THREAD_DB): Add ps_get_thread_area. Reset
17041 LIBS when finished.
17042 * aclocal.m4: Regenerated.
17043 * configure: Regenerated.
17044
17045 2004-11-21 Andreas Schwab <schwab@suse.de>
17046
17047 * linux-m68k-low.c (m68k_num_gregs): Define.
17048 (m68k_fill_gregset, m68k_store_gregset, m68k_fill_fpregset)
17049 (m68k_store_fpregset, target_regsets) [HAVE_LINUX_REGSETS]: New.
17050 (m68k_breakpoint, m68k_breakpoint_len, m68k_get_pc, m68k_set_pc)
17051 (m68k_breakpoint_at): New. Add to the_low_target.
17052
17053 * configure.srv (m68*-*-linux*): Set srv_linux_regsets and
17054 srv_linux_thread_db to yes.
17055
17056 2004-10-20 Joel Brobecker <brobecker@gnat.com>
17057
17058 * linux-x86-64-low.c (ARCH_SET_GS): Add definition if missing.
17059 (ARCH_SET_FS): Likewise.
17060 (ARCH_GET_FS): Likewise.
17061 (ARCH_GET_GS): Likewise.
17062
17063 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17064
17065 * linux-i386-low.c (ps_get_thread_area): New.
17066 * linux-x86-64-low.c (ps_get_thread_area): New.
17067 * linux-low.c: Include <sys/syscall.h>.
17068 (linux_kill_one_process): Don't kill the first thread here.
17069 (linux_kill): Kill the first thread here.
17070 (kill_lwp): New function.
17071 (send_sigstop, linux_send_signal): Use it.
17072 * proc-service.c: Clean up #ifdefs.
17073 (fpregset_info): Delete.
17074 (ps_lgetregs): Update and enable implementation.
17075 (ps_lsetregs, ps_lgetfpregs, ps_lsetfpregs): Remove disabled
17076 implementations.
17077 * remote-utils.c (struct sym_cache, symbol_cache): New.
17078 (input_interrupt): Print a clearer message.
17079 (async_io_enabled): New variable.
17080 (enable_async_io, disable_async_io): Use it. Update comments.
17081 (look_up_one_symbol): Use the symbol cache.
17082 * thread-db.c (thread_db_look_up_symbols): New function.
17083 (thread_db_init): Update comments. Call thread_db_look_up_symbols.
17084
17085 2004-10-16 Daniel Jacobowitz <dan@debian.org>
17086
17087 * configure.in: Test for -rdynamic.
17088 * configure: Regenerated.
17089 * Makefile (INTERNAL_LDFLAGS): New.
17090 (gdbserver, gdbreplay): Use it.
17091
17092 2004-09-02 Andrew Cagney <cagney@gnu.org>
17093
17094 * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE.
17095
17096 2004-03-23 Daniel Jacobowitz <drow@mvista.com>
17097
17098 * linux-low.c (linux_wait): Clear all_processes list also.
17099
17100 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17101
17102 * linux-low.c: Include <errno.h>. Remove extern declaration of
17103 errno.
17104
17105 2004-03-12 Daniel Jacobowitz <drow@mvista.com>
17106
17107 * gdbreplay.c, server.h, utils.c: Update copyright years.
17108
17109 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17110
17111 * server.c (main): Print child status or termination signal from
17112 variable 'signal', not 'sig'.
17113
17114 2004-03-04 Nathan J. Williams <nathanw@wasabisystems.com>
17115
17116 * linux-low.c (linux_read_memory): Change return type to
17117 int. Check for and return error from ptrace().
17118 * target.c (read_inferior_memory): Change return type to int. Pass
17119 back return status from the_target->read_memory().
17120 * target.h (struct target_ops): Adapt *read_memory() prototype.
17121 Update comment.
17122 (read_inferior_memory): Adapt prototype.
17123 * server.c (main): Return an error packet if
17124 read_inferior_memory() returns an error.
17125
17126 2004-03-04 Daniel Jacobowitz <drow@mvista.com>
17127
17128 * Makefile.in (distclean): Remove config.h, stamp-h, and config.log.
17129 Unify with other clean targets.
17130
17131 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17132
17133 * server.c (handle_v_cont): Call set_desired_inferior.
17134
17135 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17136
17137 * remote-utils.c (prepare_resume_reply): Always supply "thread:".
17138
17139 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17140
17141 * linux-low.c (linux_wait): Unblock async I/O.
17142 (linux_resume): Block and enable async I/O.
17143 * remote-utils.c (block_async_io, unblock_async_io): New functions.
17144 * server.h (block_async_io, unblock_async_io): Add prototypes.
17145
17146 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17147
17148 * remote-utils.c (remote_open): Print a status notice after
17149 opening a TCP port.
17150 * server.c (attach_inferior): Print a status notice after
17151 attaching.
17152
17153 2004-02-29 Daniel Jacobowitz <drow@mvista.com>
17154
17155 * linux-arm-low.c (arm_get_pc): Print out stop PC in debug mode.
17156
17157 2004-02-26 Daniel Jacobowitz <drow@mvista.com>
17158
17159 * remote-utils.c (write_enn): Use "E01" instead of "ENN" for the
17160 error packet.
17161 * server.c, target.h: Update copyright years.
17162
17163 2004-02-25 Roland McGrath <roland@redhat.com>
17164
17165 * target.h (struct target_ops): New member `read_auxv'.
17166 * server.c (handle_query): Handle qPart:auxv:read: query using that.
17167 * linux-low.c (linux_read_auxv): New function.
17168 (linux_target_ops): Initialize `read_auxv' member to that.
17169
17170 2004-02-17 Ulrich Weigand <Ulrich.Weigand@de.ibm.com>
17171
17172 Committed by Jim Blandy <jimb@redhat.com>.
17173
17174 * linux-s390-low.c (s390_num_regs): Update.
17175 (s390_regmap): Remove control registers. Use __s390x__ predefine
17176 instead of GPR_SIZE to distiguish s390 and s390x targets.
17177
17178 2004-01-31 Daniel Jacobowitz <drow@mvista.com>
17179
17180 * linux-low.c: Update copyright year.
17181 (check_removed_breakpoint): Clear pending_is_breakpoint.
17182 (linux_set_resume_request, linux_queue_one_thread)
17183 (resume_status_pending_p): New functions.
17184 (linux_continue_one_thread): Use process->resume.
17185 (linux_resume): Only resume threads if there are no pending events.
17186 * linux-low.h (struct process_info): Add resume request
17187 pointer.
17188
17189 2004-01-30 Daniel Jacobowitz <drow@mvista.com>
17190
17191 * regcache.c (new_register_cache): Clear the allocated register
17192 buffer. Suggested by Atsushi Nemoto <anemo@mba.ocn.ne.jp>.
17193
17194 2003-10-13 Daniel Jacobowitz <drow@mvista.com>
17195
17196 * linux-low.c (linux_resume): Take a struct thread_resume *
17197 argument.
17198 (linux_wait): Update call.
17199 (resume_ptr): New static variable.
17200 (linux_continue_one_thread): Renamed from
17201 linux_continue_one_process. Use resume_ptr.
17202 (linux_resume): Use linux_continue_one_thread.
17203 * server.c (handle_v_cont, handle_v_requests): New functions.
17204 (myresume): New function.
17205 (main): Handle 'v' case.
17206 * target.h (struct thread_resume): New type.
17207 (struct target_ops): Change argument of "resume" to struct
17208 thread_resume *.
17209 (myresume): Delete macro.
17210
17211 2003-08-08 H.J. Lu <hongjiu.lu@intel.com>
17212
17213 * Makefile.in (install-only): Create dest dir. Support DESTDIR.
17214 (uninstall): Support DESTDIR.
17215
17216 Mon Jul 21 20:09:34 UTC 2003 Brendan Conoboy <blc@redhat.com>
17217
17218 * configure.srv: Add xscale*linux copy of arm*linux entry.
17219
17220 2003-07-24 Daniel Jacobowitz <drow@mvista.com>
17221
17222 * linux-arm-low.c (arm_reinsert_addr): New function.
17223 (the_low_target): Add arm_reinsert_addr.
17224
17225 2003-07-08 Mark Kettenis <kettenis@gnu.org>
17226
17227 * mem-break.c: Remove whitespace at end of file.
17228
17229 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17230
17231 * configure.in: Check whether we need to prototype strerror.
17232 * server.h: Optionally prototype strerror.
17233 * gdbreplay.c (perror_with_name): Use strerror.
17234 * linux-low.c (linux_attach_lwp): Use strerror.
17235 * utils.c (perror_with_name): Use strerror.
17236 * config.in, configure: Regenerated.
17237
17238 2003-06-28 Daniel Jacobowitz <drow@mvista.com>
17239
17240 * linux-sh-low.c (sh_regmap): Fix FP register offsets, reported by
17241 SUGIOKA Toshinobu <sugioka@itonet.co.jp>.
17242
17243 2003-06-20 Daniel Jacobowitz <drow@mvista.com>
17244
17245 * Makefile.in (SFILES): Update.
17246 * low-hppabsd.c, low-lynx.c, low-nbsd.c, low-sim.c, low-sparc.c,
17247 low-sun3.c: Remove files.
17248
17249 2003-06-17 Daniel Jacobowitz <drow@mvista.com>
17250
17251 * linux-low.c: Move comment to linux_thread_alive where it belonged.
17252 (linux_detach_one_process, linux_detach): New functions.
17253 (linux_target_ops): Add linux_detach.
17254 * server.c (main): Handle 'D' packet.
17255 * target.h (struct target_ops): Add "detach" member.
17256 (detach_inferior): Define.
17257
17258 2003-06-13 Mark Kettenis <kettenis@gnu.org>
17259
17260 From Kelley Cook <kelleycook@wideopenwest.com>:
17261 * configure.srv: Accept i[34567]86 variants.
17262
17263 2003-06-05 Daniel Jacobowitz <drow@mvista.com>
17264
17265 * linux-low.c (linux_wait_for_event): Correct comment typos.
17266 (linux_resume_one_process): Call check_removed_breakpoint.
17267 (linux_send_signal): New function.
17268 (linux_target_ops): Add linux_send_signal.
17269 * remote-utils.c (putpkt, input_interrupt): Use send_signal instead
17270 of kill.
17271 * target.h (struct target_ops): Add send_signal.
17272
17273 2003-05-29 Jim Blandy <jimb@redhat.com>
17274
17275 * linux-low.c (usr_store_inferior_registers): Transfer buf in
17276 PTRACE_XFER_TYPE-sized chunks, not int-sized chunks. Otherwise,
17277 if 'int' is smaller than PTRACE_XFER_TYPE, you end up throwing
17278 away part of the register's value.
17279
17280 2003-03-26 Daniel Jacobowitz <drow@mvista.com>
17281
17282 * linux-low.c (linux_create_inferior): Use __SIGRTMIN.
17283 (linux_wait_for_event, linux_init_signals): Likewise.
17284
17285 2003-03-17 Daniel Jacobowitz <drow@mvista.com>
17286
17287 * configure.in: Check for stdlib.h.
17288 * configure: Regenerated.
17289 * config.in: Regenerated.
17290
17291 2003-01-04 Andreas Schwab <schwab@suse.de>
17292
17293 * linux-m68k-low.c (m68k_num_regs): Define to 29 instead of 31.
17294
17295 2003-01-02 Andrew Cagney <ac131313@redhat.com>
17296
17297 * Makefile.in: Remove obsolete code.
17298
17299 2002-11-20 Daniel Jacobowitz <drow@mvista.com>
17300
17301 * linux-s390-low.c (s390_regmap): Check GPR_SIZE instead of
17302 defined(PT_FPR0_HI).
17303
17304 2002-11-17 Stuart Hughes <seh@zee2.com>
17305
17306 * linux-arm-low.c (arm_num_regs): Increase.
17307 (arm_regmap): Include status register.
17308
17309 2002-11-17 Daniel Jacobowitz <drow@mvista.com>
17310
17311 * linux-low.c (register_addr): Remove incorrect -1 check.
17312
17313 2002-08-29 Daniel Jacobowitz <drow@mvista.com>
17314
17315 * linux-low.c (linux_create_inferior): Call setpgid. Return
17316 the new PID.
17317 (unstopped_p, linux_signal_pid): Remove.
17318 (linux_target_ops): Remove linux_signal_pid.
17319 * remote-utils.c (putpkt, input_interrupt): Use signal_pid
17320 global instead of target method.
17321 * target.h (struct target_ops): Remove signal_pid. Update comment
17322 for create_inferior.
17323 * server.c (signal_pid): New variable.
17324 (create_inferior): Set signal_pid. Block SIGTTOU and SIGTTIN in
17325 gdbserver. Set the child to be the foreground process group.
17326 (attach_inferior): Set signal_pid.
17327
17328 2002-08-23 Daniel Jacobowitz <drow@mvista.com>
17329
17330 * ChangeLog: New file, with entries from gdb/ChangeLog after GDB 5.2.
17331
17332 2002-08-20 Jim Blandy <jimb@redhat.com>
17333
17334 * Makefile.in (LDFLAGS): Allow the configure script to establish a
17335 default for this.
17336
17337 2002-08-01 Andrew Cagney <cagney@redhat.com>
17338
17339 * Makefile.in: Make chill references obsolete.
17340
17341 2002-07-24 Kevin Buettner <kevinb@redhat.com>
17342
17343 * configure.in (unistd.h): Add to AC_CHECK_HEADERS list.
17344 * configure: Regenerate.
17345 * config.in: Regenerate.
17346
17347 2002-07-09 David O'Brien <obrien@FreeBSD.org>
17348
17349 * gdbreplay.c (stdlib.h, unistd.h): Conditionaly include.
17350 (perror_with_name, remote_close, remote_open, expect, play): Static.
17351
17352 2002-07-04 Michal Ludvig <mludvig@suse.cz>
17353
17354 * linux-x86-64-low.c (x86_64_regmap): Make it an array of
17355 byte offsets instead of an array of indexes.
17356 (x86_64_store_gregset, x86_64_store_fpregset): Parameter made const.
17357
17358 2002-06-13 Daniel Jacobowitz <drow@mvista.com>
17359
17360 * regcache.c: Add comment.
17361
17362 2002-06-11 Daniel Jacobowitz <drow@mvista.com>
17363
17364 * thread-db.c: New file.
17365 * proc-service.c: New file.
17366 * acinclude.m4: New file.
17367 * Makefile.in: Add GDBSERVER_LIBS, gdb_proc_service_h,
17368 proc-service.o, and thread-db.o.
17369 (linux-low.o): Add USE_THREAD_DB.
17370 * acconfig.h: Add HAVE_PRGREGSET_T, HAVE_PRFPREGSET_T,
17371 HAVE_LWPID_T, HAVE_PSADDR_T, and PRFPREGSET_T_BROKEN.
17372 * aclocal.m4: Regenerated.
17373 * config.in: Regenerated.
17374 * configure: Regenerated.
17375 * configure.in: Check for proc_service.h, sys/procfs.h,
17376 thread_db.h, and linux/elf.h headrs.
17377 Check for lwpid_t, psaddr_t, prgregset_t, prfpregset_t, and
17378 PRFPREGSET_T_BROKEN. Introduce srv_thread_depfiles and USE_THREAD_DB.
17379 Check for -lthread_db and thread support.
17380 * configure.srv: Enable thread_db support for ARM, i386, MIPS,
17381 PowerPC, and SuperH.
17382 * i387-fp.c: Constify arguments.
17383 * i387-fp.h: Likewise.
17384 * inferiors.c: (struct thread_info): Renamed from
17385 `struct inferior_info'. Remove PID member. Use generic inferior
17386 list header. All uses updated.
17387 (inferiors, signal_pid): Removed.
17388 (all_threads): New variable.
17389 (get_thread): Define.
17390 (add_inferior_to_list): New function.
17391 (for_each_inferior): New function.
17392 (change_inferior_id): New function.
17393 (add_inferior): Removed.
17394 (remove_inferior): New function.
17395 (add_thread): New function.
17396 (free_one_thread): New function.
17397 (remove_thread): New function.
17398 (clear_inferiors): Use for_each_inferior and free_one_thread.
17399 (find_inferior): New function.
17400 (find_inferior_id): New function.
17401 (inferior_target_data): Update argument type.
17402 (set_inferior_target_data): Likewise.
17403 (inferior_regcache_data): Likewise.
17404 (set_inferior_regcache_data): Likewise.
17405 * linux-low.c (linux_bp_reinsert): Remove.
17406 (all_processes, stopping_threads, using_thrads)
17407 (struct pending_signals, debug_threads, pid_of): New.
17408 (inferior_pid): Replace with macro.
17409 (struct inferior_linux_data): Remove.
17410 (get_stop_pc, add_process): New functions.
17411 (linux_create_inferior): Restore SIGRTMIN+1 before calling exec.
17412 Use add_process and add_thread.
17413 (linux_attach_lwp): New function, based on old linux_attach. Use
17414 add_process and add_thread. Set stop_expected for new threads.
17415 (linux_attach): New function.
17416 (linux_kill_one_process): New function.
17417 (linux_kill): Kill all LWPs.
17418 (linux_thread_alive): Use find_inferior_id.
17419 (check_removed_breakpoints, status_pending_p): New functions.
17420 (linux_wait_for_process): Renamed from linux_wait_for_one_inferior.
17421 Update. Use WNOHANG. Wait for cloned processes also. Update process
17422 struct for the found process.
17423 (linux_wait_for_event): New function.
17424 (linux_wait): Use it. Support LWPs.
17425 (send_sigstop, wait_for_sigstop, stop_all_processes)
17426 (linux_resume_one_process, linux_continue_one_process): New functions.
17427 (linux_resume): Support LWPs.
17428 (REGISTER_RAW_SIZE): Remove.
17429 (fetch_register): Use register_size instead. Call supply_register.
17430 (usr_store_inferior_registers): Likewise. Call collect_register.
17431 Fix recursive case.
17432 (regsets_fetch_inferior_registers): Improve error message.
17433 (regsets_store_inferior_registers): Add debugging.
17434 (linux_look_up_symbols): Call thread_db_init if USE_THREAD_DB.
17435 (unstopped_p, linux_signal_pid): New functions.
17436 (linux_target_ops): Add linux_signal_pid.
17437 (linux_init_signals): New function.
17438 (initialize_low): Call it. Initialize using_threads.
17439 * regcache.c (inferior_regcache_data): Add valid
17440 flag.
17441 (get_regcache): Fetch registers lazily. Add fetch argument
17442 and update all callers.
17443 (regcache_invalidate_one, regcache_invalidate): New
17444 functions.
17445 (new_register_cache): Renamed from create_register_cache.
17446 Return the new regcache.
17447 (free_register_cache): Change argument to a void *.
17448 (registers_to_string, registers_from_string): Call get_regcache
17449 with fetch flag set.
17450 (register_data): Make static. Pass fetch flag to get_regcache.
17451 (supply_register): Call get_regcache with fetch flag clear.
17452 (collect_register): Call get_regcache with fetch flag set.
17453 (collect_register_as_string): New function.
17454 * regcache.h: Update.
17455 * remote-utils.c (putpkt): Flush after debug output and use
17456 stderr.
17457 Handle input interrupts while waiting for an ACK.
17458 (input_interrupt): Use signal_pid method.
17459 (getpkt): Flush after debug output and use stderr.
17460 (outreg): Use collect_register_as_string.
17461 (new_thread_notify, dead_thread_notify): New functions.
17462 (prepare_resume_reply): Check using_threads. Set thread_from_wait
17463 and general_thread.
17464 (look_up_one_symbol): Flush after debug output.
17465 * server.c (step_thread, server_waiting): New variables.
17466 (start_inferior): Don't use signal_pid. Update call to mywait.
17467 (attach_inferior): Update call to mywait.
17468 (handle_query): Handle qfThreadInfo and qsThreadInfo.
17469 (main): Don't fetch/store registers explicitly. Use
17470 set_desired_inferior. Support proposed ``Hs'' packet. Update
17471 calls to mywait.
17472 * server.h: Update.
17473 (struct inferior_list, struct_inferior_list_entry): New.
17474 * target.c (set_desired_inferior): New.
17475 (write_inferior_memory): Constify.
17476 (mywait): New function.
17477 * target.h: Update.
17478 (struct target_ops): New signal_pid method.
17479 (mywait): Removed macro, added prototype.
17480
17481 * linux-low.h (regset_func): Removed.
17482 (regset_fill_func, regset_store_func): New.
17483 (enum regset_type): New.
17484 (struct regset_info): Add type field. Use new operation types.
17485 (struct linux_target_ops): stop_pc renamed to get_pc.
17486 Add decr_pc_after_break and breakpoint_at.
17487 (get_process, get_thread_proess, get_process_thread)
17488 (strut process_info, all_processes, linux_attach_lwp)
17489 (thread_db_init): New.
17490
17491 * linux-arm-low.c (arm_get_pc, arm_set_pc,
17492 arm_breakpoint, arm_breakpoint_len, arm_breakpoint_at): New.
17493 (the_low_target): Add new members.
17494 * linux-i386-low.c (i386_store_gregset, i386_store_fpregset)
17495 (i386_store_fpxregset): Constify.
17496 (target_regsets): Add new kind identifier.
17497 (i386_get_pc): Renamed from i386_stop_pc. Simplify.
17498 (i386_set_pc): Add debugging.
17499 (i386_breakpoint_at): New function.
17500 (the_low_target): Add new members.
17501 * linux-mips-low.c (mips_get_pc, mips_set_pc)
17502 (mips_breakpoint, mips_breakpoint_len, mips_reinsert_addr)
17503 (mips_breakpoint_at): New.
17504 (the_low_target): Add new members.
17505 * linux-ppc-low.c (ppc_get_pc, ppc_set_pc)
17506 (ppc_breakpoint, ppc_breakpoint_len, ppc_breakpoint_at): New.
17507 (the_low_target): Add new members.
17508 * linux-sh-low.c (sh_get_pc, sh_set_pc)
17509 (sh_breakpoint, sh_breakpoint_len, sh_breakpoint_at): New.
17510 (the_low_target): Add new members.
17511 * linux-x86-64-low.c (target_regsets): Add new kind
17512 identifier.
17513
17514 2002-05-15 Daniel Jacobowitz <drow@mvista.com>
17515
17516 From Martin Pool <mbp@samba.org>:
17517 * server.c (gdbserver_usage): New function.
17518 (main): Call it.
17519
17520 2002-05-14 Daniel Jacobowitz <drow@mvista.com>
17521
17522 * mem-break.c (reinsert_breakpoint_by_bp): Correct typo
17523 stop_at -> stop_pc.
17524
17525 2002-05-04 Andrew Cagney <ac131313@redhat.com>
17526
17527 * Makefile.in: Remove obsolete code.
17528
17529 2002-04-24 Michal Ludvig <mludvig@suse.cz>
17530
17531 * linux-low.c (regsets_fetch_inferior_registers),
17532 (regsets_store_inferior_registers): Removed cast to int from
17533 ptrace() calls.
17534 * regcache.h: Added declaration of struct inferior_info.
17535
17536 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17537
17538 * inferiors.c (struct inferior_info): Add regcache_data.
17539 (add_inferior): Call create_register_cache.
17540 (clear_inferiors): Call free_register_cache.
17541 (inferior_regcache_data, set_inferior_regcache_data): New functions.
17542 * regcache.c (struct inferior_regcache_data): New.
17543 (registers): Remove.
17544 (get_regcache): New function.
17545 (create_register_cache, free_register_cache): New functions.
17546 (set_register_cache): Don't initialize the register cache here.
17547 (registers_to_string, registers_from_string, register_data): Call
17548 get_regcache.
17549 * regcache.h: Add prototypes.
17550 * server.h: Likewise.
17551
17552 2002-04-20 Daniel Jacobowitz <drow@mvista.com>
17553
17554 * mem-break.c: New file.
17555 * mem-break.h: New file.
17556 * Makefile.in: Add mem-break.o rule; update server.h
17557 dependencies.
17558 * inferiors.c (struct inferior_info): Add target_data
17559 member.
17560 (clear_inferiors): Free target_data member if set.
17561 (inferior_target_data, set_inferior_target_data): New functions.
17562 * linux-i386-low.c (i386_breakpoint, i386_breakpoint_len)
17563 (i386_stop_pc, i386_set_pc): New. Add to the_low_target.
17564 * linux-low.c (linux_bp_reinsert): New variable.
17565 (struct inferior_linux_data): New.
17566 (linux_create_inferior): Use set_inferior_target_data.
17567 (linux_attach): Likewise. Call add_inferior.
17568 (linux_wait_for_one_inferior): New function.
17569 (linux_wait): Call it.
17570 (linux_write_memory): Add const.
17571 (initialize_low): Call set_breakpoint_data.
17572 * linux-low.h (struct linux_target_ops): Add breakpoint
17573 handling members.
17574 * server.c (attach_inferior): Remove extra add_inferior
17575 call.
17576 * server.h: Include mem-break.h. Update inferior.c
17577 prototypes.
17578 * target.c (read_inferior_memory)
17579 (write_inferior_memory): New functions.
17580 * target.h (read_inferior_memory)
17581 (write_inferior_memory): Change macros to prototypes.
17582 (struct target_ops): Update comments. Add const to write_memory
17583 definition.
17584
17585 2002-04-11 Daniel Jacobowitz <drow@mvista.com>
17586
17587 * linux-low.c (usr_store_inferior_registers): Support
17588 registers which are allowed to fail to store.
17589 * linux-low.h (linux_target_ops): Likewise.
17590 * linux-ppc-low.c (ppc_regmap): Support FPSCR.
17591 (ppc_cannot_store_register): FPSCR may not be storable.
17592
17593 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17594
17595 * server.h: Include <string.h> if HAVE_STRING_H.
17596 * ChangeLog: Correct paths in last ChangeLog entry.
17597
17598 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17599
17600 * linux-low.h: Remove obsolete prototypes.
17601 (struct linux_target_ops): New.
17602 (extern the_low_target): New.
17603 * linux-low.c (num_regs, regmap): Remove declarations.
17604 (register_addr): Use the_low_target explicitly.
17605 (fetch_register): Likewise.
17606 (usr_fetch_inferior_registers): Likewise.
17607 (usr_store_inferior_registers): Likewise.
17608 * linux-arm-low.c (num_regs): Remove.
17609 (arm_num_regs): Define.
17610 (arm_regmap): Renamed from regmap, made static.
17611 (arm_cannot_fetch_register): Renamed from cannot_fetch_register,
17612 made static.
17613 (arm_cannot_store_register): Renamed from cannot_store_register,
17614 made static.
17615 (the_low_target): New.
17616 * linux-i386-low.c (num_regs): Remove.
17617 (i386_num_regs): Define.
17618 (i386_regmap): Renamed from regmap, made static.
17619 (i386_cannot_fetch_register): Renamed from cannot_fetch_register,
17620 made static.
17621 (i386_cannot_store_register): Renamed from cannot_store_register,
17622 made static.
17623 (the_low_target): New.
17624 * linux-ia64-low.c (num_regs): Remove.
17625 (ia64_num_regs): Define.
17626 (ia64_regmap): Renamed from regmap, made static.
17627 (ia64_cannot_fetch_register): Renamed from cannot_fetch_register,
17628 made static.
17629 (ia64_cannot_store_register): Renamed from cannot_store_register,
17630 made static.
17631 (the_low_target): New.
17632 * linux-m68k-low.c (num_regs): Remove.
17633 (m68k_num_regs): Define.
17634 (m68k_regmap): Renamed from regmap, made static.
17635 (m68k_cannot_fetch_register): Renamed from cannot_fetch_register,
17636 made static.
17637 (m68k_cannot_store_register): Renamed from cannot_store_register,
17638 made static.
17639 (the_low_target): New.
17640 * linux-mips-low.c (num_regs): Remove.
17641 (mips_num_regs): Define.
17642 (mips_regmap): Renamed from regmap, made static.
17643 (mips_cannot_fetch_register): Renamed from cannot_fetch_register,
17644 made static.
17645 (mips_cannot_store_register): Renamed from cannot_store_register,
17646 made static.
17647 (the_low_target): New.
17648 * linux-ppc-low.c (num_regs): Remove.
17649 (ppc_num_regs): Define.
17650 (ppc_regmap): Renamed from regmap, made static.
17651 (ppc_cannot_fetch_register): Renamed from cannot_fetch_register,
17652 made static.
17653 (ppc_cannot_store_register): Renamed from cannot_store_register,
17654 made static.
17655 (the_low_target): New.
17656 * linux-s390-low.c (num_regs): Remove.
17657 (s390_num_regs): Define.
17658 (s390_regmap): Renamed from regmap, made static.
17659 (s390_cannot_fetch_register): Renamed from cannot_fetch_register,
17660 made static.
17661 (s390_cannot_store_register): Renamed from cannot_store_register,
17662 made static.
17663 (the_low_target): New.
17664 * linux-sh-low.c (num_regs): Remove.
17665 (sh_num_regs): Define.
17666 (sh_regmap): Renamed from regmap, made static.
17667 (sh_cannot_fetch_register): Renamed from cannot_fetch_register,
17668 made static.
17669 (sh_cannot_store_register): Renamed from cannot_store_register,
17670 made static.
17671 (the_low_target): New.
17672 * linux-x86-64-low.c (x86_64_regmap): Renamed from regmap.
17673 (the_low_target): New.
17674
17675 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17676
17677 * Makefile.in: Add stamp-h target.
17678 * configure.in: Create stamp-h.
17679 * configure: Regenerated.
17680
17681 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17682
17683 * inferiors.c: New file.
17684 * target.c: New file.
17685 * target.h: New file.
17686 * Makefile.in: Add target.o and inferiors.o. Update
17687 dependencies.
17688 * linux-low.c (inferior_pid): New static variable,
17689 moved from server.c.
17690 (linux_create_inferior): Renamed from create_inferior.
17691 Call add_inferior. Return 0 on success instead of a PID.
17692 (linux_attach): Renamed from myattach.
17693 (linux_kill): Renamed from kill_inferior. Call clear_inferiors ().
17694 (linux_thread_alive): Renamed from mythread_alive.
17695 (linux_wait): Renamed from mywait. Call clear_inferiors () if the
17696 child dies.
17697 (linux_resume): Renamed from myresume. Add missing ``return 0''.
17698 (regsets_store_inferior_registers): Correct error message.
17699 Add missing ``return 0''.
17700 (linux_fetch_registers): Renamed from fetch_inferior_registers.
17701 (linux_store_registers): Renamed from store_inferior_registers.
17702 (linux_read_memory): Renamed from read_inferior_memory.
17703 (linux_write_memory): Renamed from write_inferior_memory.
17704 (linux_target_ops): New structure.
17705 (initialize_low): Call set_target_ops ().
17706 * remote-utils.c (unhexify): New function.
17707 (hexify): New function.
17708 (input_interrupt): Send signals to ``signal_pid''.
17709 * server.c (inferior_pid): Remove.
17710 (start_inferior): Update create_inferior call.
17711 (attach_inferior): Call add_inferior.
17712 (handle_query): New function.
17713 (main): Call handle_query for `q' packets.
17714 * server.h: Include "target.h". Remove obsolete prototypes.
17715 Add prototypes for "inferiors.c", "target.c", hexify, and unhexify.
17716
17717 2002-04-09 Daniel Jacobowitz <drow@mvista.com>
17718
17719 * Makefile.in: Add WARN_CFLAGS. Update configury
17720 dependencies.
17721 * configure.in: Check for <string.h>
17722 * configure: Regenerate.
17723 * config.in: Regenerate.
17724 * gdbreplay.c: Include needed system headers.
17725 (remote_open): Remove strchr prototype.
17726 * linux-low.h: Correct #ifdef to HAVE_LINUX_USRREGS.
17727 * regcache.c (supply_register): Change buf argument to const void *.
17728 (supply_register_by_name): Likewise.
17729 (collect_register): Change buf argument to void *.
17730 (collect_register_by_name): Likewise.
17731 * regcache.h: Add missing prototypes.
17732 * remote-utils.c: Include <arpa/inet.h> for inet_ntoa.
17733 * server.c (handle_query): New function.
17734 (attached): New static variable, moved out of main.
17735 (main): Quiet longjmp clobber warnings.
17736 * server.h: Add ATTR_NORETURN and ATTR_FORMAT. Update prototypes.
17737 * utils.c (error): Remove NORETURN.
17738 (fatal): Likewise.
This page took 0.489996 seconds and 4 git commands to generate.